diff --git a/client-java-contrib/admissionreview/pom.xml b/client-java-contrib/admissionreview/pom.xml index edacab243e..651be59770 100644 --- a/client-java-contrib/admissionreview/pom.xml +++ b/client-java-contrib/admissionreview/pom.xml @@ -37,7 +37,7 @@ com.diffplug.spotless spotless-maven-plugin - 2.17.2 + 2.20.0 true diff --git a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionRequest.java b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionRequest.java index 1afa977dd4..0d9c5d78f0 100644 --- a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionRequest.java +++ b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionRequest.java @@ -1,440 +1,441 @@ /* - * k8s.io/api/admission/v1 - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 1.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.admissionreview.models; -import java.util.Objects; -import java.util.Arrays; -import java.util.Map; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.kubernetes.client.admissionreview.models.GroupVersionKind; -import io.kubernetes.client.admissionreview.models.GroupVersionResource; -import io.kubernetes.client.admissionreview.models.UserInfo; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; +import java.util.Map; +import java.util.Objects; -/** - * AdmissionRequest describes the admission.Attributes for the admission request. - */ -@ApiModel(description = "AdmissionRequest describes the admission.Attributes for the admission request.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2021-07-01T14:30:02.888Z[Etc/UTC]") +/** AdmissionRequest describes the admission.Attributes for the admission request. */ +@ApiModel( + description = "AdmissionRequest describes the admission.Attributes for the admission request.") +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + date = "2021-07-01T14:30:02.888Z[Etc/UTC]") public class AdmissionRequest { public static final String SERIALIZED_NAME_DRY_RUN = "dryRun"; + @SerializedName(SERIALIZED_NAME_DRY_RUN) private Boolean dryRun; public static final String SERIALIZED_NAME_KIND = "kind"; + @SerializedName(SERIALIZED_NAME_KIND) private GroupVersionKind kind; public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) private String name; public static final String SERIALIZED_NAME_NAMESPACE = "namespace"; + @SerializedName(SERIALIZED_NAME_NAMESPACE) private String namespace; public static final String SERIALIZED_NAME_OBJECT = "object"; + @SerializedName(SERIALIZED_NAME_OBJECT) private Map _object = null; public static final String SERIALIZED_NAME_OLD_OBJECT = "oldObject"; + @SerializedName(SERIALIZED_NAME_OLD_OBJECT) private Map oldObject = null; public static final String SERIALIZED_NAME_OPERATION = "operation"; + @SerializedName(SERIALIZED_NAME_OPERATION) private String operation; public static final String SERIALIZED_NAME_OPTIONS = "options"; + @SerializedName(SERIALIZED_NAME_OPTIONS) private Map options = null; public static final String SERIALIZED_NAME_REQUEST_KIND = "requestKind"; + @SerializedName(SERIALIZED_NAME_REQUEST_KIND) private GroupVersionKind requestKind; public static final String SERIALIZED_NAME_REQUEST_RESOURCE = "requestResource"; + @SerializedName(SERIALIZED_NAME_REQUEST_RESOURCE) private GroupVersionResource requestResource; public static final String SERIALIZED_NAME_REQUEST_SUB_RESOURCE = "requestSubResource"; + @SerializedName(SERIALIZED_NAME_REQUEST_SUB_RESOURCE) private String requestSubResource; public static final String SERIALIZED_NAME_RESOURCE = "resource"; + @SerializedName(SERIALIZED_NAME_RESOURCE) private GroupVersionResource resource; public static final String SERIALIZED_NAME_SUB_RESOURCE = "subResource"; + @SerializedName(SERIALIZED_NAME_SUB_RESOURCE) private String subResource; public static final String SERIALIZED_NAME_UID = "uid"; + @SerializedName(SERIALIZED_NAME_UID) private String uid; public static final String SERIALIZED_NAME_USER_INFO = "userInfo"; + @SerializedName(SERIALIZED_NAME_USER_INFO) private UserInfo userInfo; - public AdmissionRequest dryRun(Boolean dryRun) { - + this.dryRun = dryRun; return this; } - /** - * DryRun indicates that modifications will definitely not be persisted for this request. Defaults to false. + /** + * DryRun indicates that modifications will definitely not be persisted for this request. Defaults + * to false. + * * @return dryRun - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "DryRun indicates that modifications will definitely not be persisted for this request. Defaults to false.") - + @ApiModelProperty( + value = + "DryRun indicates that modifications will definitely not be persisted for this request. Defaults to false.") public Boolean getDryRun() { return dryRun; } - public void setDryRun(Boolean dryRun) { this.dryRun = dryRun; } - public AdmissionRequest kind(GroupVersionKind kind) { - + this.kind = kind; return this; } - /** + /** * Get kind + * * @return kind - **/ + */ @ApiModelProperty(required = true, value = "") - public GroupVersionKind getKind() { return kind; } - public void setKind(GroupVersionKind kind) { this.kind = kind; } - public AdmissionRequest name(String name) { - + this.name = name; return this; } - /** - * Name is the name of the object as presented in the request. On a CREATE operation, the client may omit name and rely on the server to generate the name. If that is the case, this field will contain an empty string. + /** + * Name is the name of the object as presented in the request. On a CREATE operation, the client + * may omit name and rely on the server to generate the name. If that is the case, this field will + * contain an empty string. + * * @return name - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "Name is the name of the object as presented in the request. On a CREATE operation, the client may omit name and rely on the server to generate the name. If that is the case, this field will contain an empty string.") - + @ApiModelProperty( + value = + "Name is the name of the object as presented in the request. On a CREATE operation, the client may omit name and rely on the server to generate the name. If that is the case, this field will contain an empty string.") public String getName() { return name; } - public void setName(String name) { this.name = name; } - public AdmissionRequest namespace(String namespace) { - + this.namespace = namespace; return this; } - /** + /** * Namespace is the namespace associated with the request (if any). + * * @return namespace - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "Namespace is the namespace associated with the request (if any).") - public String getNamespace() { return namespace; } - public void setNamespace(String namespace) { this.namespace = namespace; } - public AdmissionRequest _object(Map _object) { - + this._object = _object; return this; } - /** + /** * Get _object + * * @return _object - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "") - public Map getObject() { return _object; } - public void setObject(Map _object) { this._object = _object; } - public AdmissionRequest oldObject(Map oldObject) { - + this.oldObject = oldObject; return this; } - /** + /** * Get oldObject + * * @return oldObject - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "") - public Map getOldObject() { return oldObject; } - public void setOldObject(Map oldObject) { this.oldObject = oldObject; } - public AdmissionRequest operation(String operation) { - + this.operation = operation; return this; } - /** - * Operation is the operation being performed. This may be different than the operation requested. e.g. a patch can result in either a CREATE or UPDATE Operation. + /** + * Operation is the operation being performed. This may be different than the operation requested. + * e.g. a patch can result in either a CREATE or UPDATE Operation. + * * @return operation - **/ - @ApiModelProperty(required = true, value = "Operation is the operation being performed. This may be different than the operation requested. e.g. a patch can result in either a CREATE or UPDATE Operation.") - + */ + @ApiModelProperty( + required = true, + value = + "Operation is the operation being performed. This may be different than the operation requested. e.g. a patch can result in either a CREATE or UPDATE Operation.") public String getOperation() { return operation; } - public void setOperation(String operation) { this.operation = operation; } - public AdmissionRequest options(Map options) { - + this.options = options; return this; } - /** + /** * Get options + * * @return options - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "") - public Map getOptions() { return options; } - public void setOptions(Map options) { this.options = options; } - public AdmissionRequest requestKind(GroupVersionKind requestKind) { - + this.requestKind = requestKind; return this; } - /** + /** * Get requestKind + * * @return requestKind - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "") - public GroupVersionKind getRequestKind() { return requestKind; } - public void setRequestKind(GroupVersionKind requestKind) { this.requestKind = requestKind; } - public AdmissionRequest requestResource(GroupVersionResource requestResource) { - + this.requestResource = requestResource; return this; } - /** + /** * Get requestResource + * * @return requestResource - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "") - public GroupVersionResource getRequestResource() { return requestResource; } - public void setRequestResource(GroupVersionResource requestResource) { this.requestResource = requestResource; } - public AdmissionRequest requestSubResource(String requestSubResource) { - + this.requestSubResource = requestSubResource; return this; } - /** - * RequestSubResource is the name of the subresource of the original API request, if any (for example, \"status\" or \"scale\") If this is specified and differs from the value in \"subResource\", an equivalent match and conversion was performed. See documentation for the \"matchPolicy\" field in the webhook configuration type. + /** + * RequestSubResource is the name of the subresource of the original API request, if any (for + * example, \"status\" or \"scale\") If this is specified and differs from the + * value in \"subResource\", an equivalent match and conversion was performed. See + * documentation for the \"matchPolicy\" field in the webhook configuration type. + * * @return requestSubResource - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "RequestSubResource is the name of the subresource of the original API request, if any (for example, \"status\" or \"scale\") If this is specified and differs from the value in \"subResource\", an equivalent match and conversion was performed. See documentation for the \"matchPolicy\" field in the webhook configuration type.") - + @ApiModelProperty( + value = + "RequestSubResource is the name of the subresource of the original API request, if any (for example, \"status\" or \"scale\") If this is specified and differs from the value in \"subResource\", an equivalent match and conversion was performed. See documentation for the \"matchPolicy\" field in the webhook configuration type.") public String getRequestSubResource() { return requestSubResource; } - public void setRequestSubResource(String requestSubResource) { this.requestSubResource = requestSubResource; } - public AdmissionRequest resource(GroupVersionResource resource) { - + this.resource = resource; return this; } - /** + /** * Get resource + * * @return resource - **/ + */ @ApiModelProperty(required = true, value = "") - public GroupVersionResource getResource() { return resource; } - public void setResource(GroupVersionResource resource) { this.resource = resource; } - public AdmissionRequest subResource(String subResource) { - + this.subResource = subResource; return this; } - /** - * SubResource is the subresource being requested, if any (for example, \"status\" or \"scale\") + /** + * SubResource is the subresource being requested, if any (for example, \"status\" or + * \"scale\") + * * @return subResource - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "SubResource is the subresource being requested, if any (for example, \"status\" or \"scale\")") - + @ApiModelProperty( + value = + "SubResource is the subresource being requested, if any (for example, \"status\" or \"scale\")") public String getSubResource() { return subResource; } - public void setSubResource(String subResource) { this.subResource = subResource; } - public AdmissionRequest uid(String uid) { - + this.uid = uid; return this; } - /** - * UID is an identifier for the individual request/response. It allows us to distinguish instances of requests which are otherwise identical (parallel requests, requests when earlier requests did not modify etc) The UID is meant to track the round trip (request/response) between the KAS and the WebHook, not the user request. It is suitable for correlating log entries between the webhook and apiserver, for either auditing or debugging. + /** + * UID is an identifier for the individual request/response. It allows us to distinguish instances + * of requests which are otherwise identical (parallel requests, requests when earlier requests + * did not modify etc) The UID is meant to track the round trip (request/response) between the KAS + * and the WebHook, not the user request. It is suitable for correlating log entries between the + * webhook and apiserver, for either auditing or debugging. + * * @return uid - **/ - @ApiModelProperty(required = true, value = "UID is an identifier for the individual request/response. It allows us to distinguish instances of requests which are otherwise identical (parallel requests, requests when earlier requests did not modify etc) The UID is meant to track the round trip (request/response) between the KAS and the WebHook, not the user request. It is suitable for correlating log entries between the webhook and apiserver, for either auditing or debugging.") - + */ + @ApiModelProperty( + required = true, + value = + "UID is an identifier for the individual request/response. It allows us to distinguish instances of requests which are otherwise identical (parallel requests, requests when earlier requests did not modify etc) The UID is meant to track the round trip (request/response) between the KAS and the WebHook, not the user request. It is suitable for correlating log entries between the webhook and apiserver, for either auditing or debugging.") public String getUid() { return uid; } - public void setUid(String uid) { this.uid = uid; } - public AdmissionRequest userInfo(UserInfo userInfo) { - + this.userInfo = userInfo; return this; } - /** + /** * Get userInfo + * * @return userInfo - **/ + */ @ApiModelProperty(required = true, value = "") - public UserInfo getUserInfo() { return userInfo; } - public void setUserInfo(UserInfo userInfo) { this.userInfo = userInfo; } - @Override public boolean equals(Object o) { if (this == o) { @@ -444,29 +445,43 @@ public boolean equals(Object o) { return false; } AdmissionRequest admissionRequest = (AdmissionRequest) o; - return Objects.equals(this.dryRun, admissionRequest.dryRun) && - Objects.equals(this.kind, admissionRequest.kind) && - Objects.equals(this.name, admissionRequest.name) && - Objects.equals(this.namespace, admissionRequest.namespace) && - Objects.equals(this._object, admissionRequest._object) && - Objects.equals(this.oldObject, admissionRequest.oldObject) && - Objects.equals(this.operation, admissionRequest.operation) && - Objects.equals(this.options, admissionRequest.options) && - Objects.equals(this.requestKind, admissionRequest.requestKind) && - Objects.equals(this.requestResource, admissionRequest.requestResource) && - Objects.equals(this.requestSubResource, admissionRequest.requestSubResource) && - Objects.equals(this.resource, admissionRequest.resource) && - Objects.equals(this.subResource, admissionRequest.subResource) && - Objects.equals(this.uid, admissionRequest.uid) && - Objects.equals(this.userInfo, admissionRequest.userInfo); + return Objects.equals(this.dryRun, admissionRequest.dryRun) + && Objects.equals(this.kind, admissionRequest.kind) + && Objects.equals(this.name, admissionRequest.name) + && Objects.equals(this.namespace, admissionRequest.namespace) + && Objects.equals(this._object, admissionRequest._object) + && Objects.equals(this.oldObject, admissionRequest.oldObject) + && Objects.equals(this.operation, admissionRequest.operation) + && Objects.equals(this.options, admissionRequest.options) + && Objects.equals(this.requestKind, admissionRequest.requestKind) + && Objects.equals(this.requestResource, admissionRequest.requestResource) + && Objects.equals(this.requestSubResource, admissionRequest.requestSubResource) + && Objects.equals(this.resource, admissionRequest.resource) + && Objects.equals(this.subResource, admissionRequest.subResource) + && Objects.equals(this.uid, admissionRequest.uid) + && Objects.equals(this.userInfo, admissionRequest.userInfo); } @Override public int hashCode() { - return Objects.hash(dryRun, kind, name, namespace, _object, oldObject, operation, options, requestKind, requestResource, requestSubResource, resource, subResource, uid, userInfo); + return Objects.hash( + dryRun, + kind, + name, + namespace, + _object, + oldObject, + operation, + options, + requestKind, + requestResource, + requestSubResource, + resource, + subResource, + uid, + userInfo); } - @Override public String toString() { StringBuilder sb = new StringBuilder(); @@ -491,8 +506,7 @@ public String toString() { } /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). + * Convert the given object to string with each line indented by 4 spaces (except the first line). */ private String toIndentedString(Object o) { if (o == null) { @@ -500,6 +514,4 @@ private String toIndentedString(Object o) { } return o.toString().replace("\n", "\n "); } - } - diff --git a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionResponse.java b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionResponse.java index 8246712697..fa06ac9de6 100644 --- a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionResponse.java +++ b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionResponse.java @@ -1,93 +1,92 @@ /* - * k8s.io/api/admission/v1 - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 1.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.admissionreview.models; -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.kubernetes.client.admissionreview.models.Status; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; import java.util.ArrayList; +import java.util.Arrays; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.Objects; -/** - * AdmissionResponse describes an admission response. - */ +/** AdmissionResponse describes an admission response. */ @ApiModel(description = "AdmissionResponse describes an admission response.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2021-07-01T14:30:02.888Z[Etc/UTC]") +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + date = "2021-07-01T14:30:02.888Z[Etc/UTC]") public class AdmissionResponse { public static final String SERIALIZED_NAME_ALLOWED = "allowed"; + @SerializedName(SERIALIZED_NAME_ALLOWED) private Boolean allowed; public static final String SERIALIZED_NAME_AUDIT_ANNOTATIONS = "auditAnnotations"; + @SerializedName(SERIALIZED_NAME_AUDIT_ANNOTATIONS) private Map auditAnnotations = null; public static final String SERIALIZED_NAME_PATCH = "patch"; + @SerializedName(SERIALIZED_NAME_PATCH) private byte[] patch; public static final String SERIALIZED_NAME_PATCH_TYPE = "patchType"; + @SerializedName(SERIALIZED_NAME_PATCH_TYPE) private String patchType; public static final String SERIALIZED_NAME_STATUS = "status"; + @SerializedName(SERIALIZED_NAME_STATUS) private Status status; public static final String SERIALIZED_NAME_UID = "uid"; + @SerializedName(SERIALIZED_NAME_UID) private String uid; public static final String SERIALIZED_NAME_WARNINGS = "warnings"; + @SerializedName(SERIALIZED_NAME_WARNINGS) private List warnings = null; - public AdmissionResponse allowed(Boolean allowed) { - + this.allowed = allowed; return this; } - /** + /** * Allowed indicates whether or not the admission request was permitted. + * * @return allowed - **/ - @ApiModelProperty(required = true, value = "Allowed indicates whether or not the admission request was permitted.") - + */ + @ApiModelProperty( + required = true, + value = "Allowed indicates whether or not the admission request was permitted.") public Boolean getAllowed() { return allowed; } - public void setAllowed(Boolean allowed) { this.allowed = allowed; } - public AdmissionResponse auditAnnotations(Map auditAnnotations) { - + this.auditAnnotations = auditAnnotations; return this; } @@ -100,116 +99,117 @@ public AdmissionResponse putAuditAnnotationsItem(String key, String auditAnnotat return this; } - /** - * AuditAnnotations is an unstructured key value map set by remote admission controller (e.g. error=image-blacklisted). MutatingAdmissionWebhook and ValidatingAdmissionWebhook admission controller will prefix the keys with admission webhook name (e.g. imagepolicy.example.com/error=image-blacklisted). AuditAnnotations will be provided by the admission webhook to add additional context to the audit log for this request. + /** + * AuditAnnotations is an unstructured key value map set by remote admission controller (e.g. + * error=image-blacklisted). MutatingAdmissionWebhook and ValidatingAdmissionWebhook + * admission controller will prefix the keys with admission webhook name (e.g. + * imagepolicy.example.com/error=image-blacklisted). AuditAnnotations will be provided by the + * admission webhook to add additional context to the audit log for this request. + * * @return auditAnnotations - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "AuditAnnotations is an unstructured key value map set by remote admission controller (e.g. error=image-blacklisted). MutatingAdmissionWebhook and ValidatingAdmissionWebhook admission controller will prefix the keys with admission webhook name (e.g. imagepolicy.example.com/error=image-blacklisted). AuditAnnotations will be provided by the admission webhook to add additional context to the audit log for this request.") - + @ApiModelProperty( + value = + "AuditAnnotations is an unstructured key value map set by remote admission controller (e.g. error=image-blacklisted). MutatingAdmissionWebhook and ValidatingAdmissionWebhook admission controller will prefix the keys with admission webhook name (e.g. imagepolicy.example.com/error=image-blacklisted). AuditAnnotations will be provided by the admission webhook to add additional context to the audit log for this request.") public Map getAuditAnnotations() { return auditAnnotations; } - public void setAuditAnnotations(Map auditAnnotations) { this.auditAnnotations = auditAnnotations; } - public AdmissionResponse patch(byte[] patch) { - + this.patch = patch; return this; } - /** + /** * The patch body. Currently we only support \"JSONPatch\" which implements RFC 6902. + * * @return patch - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "The patch body. Currently we only support \"JSONPatch\" which implements RFC 6902.") - + @ApiModelProperty( + value = "The patch body. Currently we only support \"JSONPatch\" which implements RFC 6902.") public byte[] getPatch() { return patch; } - public void setPatch(byte[] patch) { this.patch = patch; } - public AdmissionResponse patchType(String patchType) { - + this.patchType = patchType; return this; } - /** + /** * The type of Patch. Currently we only allow \"JSONPatch\". + * * @return patchType - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "The type of Patch. Currently we only allow \"JSONPatch\".") - public String getPatchType() { return patchType; } - public void setPatchType(String patchType) { this.patchType = patchType; } - public AdmissionResponse status(Status status) { - + this.status = status; return this; } - /** + /** * Get status + * * @return status - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "") - public Status getStatus() { return status; } - public void setStatus(Status status) { this.status = status; } - public AdmissionResponse uid(String uid) { - + this.uid = uid; return this; } - /** - * UID is an identifier for the individual request/response. This must be copied over from the corresponding AdmissionRequest. + /** + * UID is an identifier for the individual request/response. This must be copied over from the + * corresponding AdmissionRequest. + * * @return uid - **/ - @ApiModelProperty(required = true, value = "UID is an identifier for the individual request/response. This must be copied over from the corresponding AdmissionRequest.") - + */ + @ApiModelProperty( + required = true, + value = + "UID is an identifier for the individual request/response. This must be copied over from the corresponding AdmissionRequest.") public String getUid() { return uid; } - public void setUid(String uid) { this.uid = uid; } - public AdmissionResponse warnings(List warnings) { - + this.warnings = warnings; return this; } @@ -222,23 +222,26 @@ public AdmissionResponse addWarningsItem(String warningsItem) { return this; } - /** - * warnings is a list of warning messages to return to the requesting API client. Warning messages describe a problem the client making the API request should correct or be aware of. Limit warnings to 120 characters if possible. Warnings over 256 characters and large numbers of warnings may be truncated. + /** + * warnings is a list of warning messages to return to the requesting API client. Warning messages + * describe a problem the client making the API request should correct or be aware of. Limit + * warnings to 120 characters if possible. Warnings over 256 characters and large numbers of + * warnings may be truncated. + * * @return warnings - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "warnings is a list of warning messages to return to the requesting API client. Warning messages describe a problem the client making the API request should correct or be aware of. Limit warnings to 120 characters if possible. Warnings over 256 characters and large numbers of warnings may be truncated.") - + @ApiModelProperty( + value = + "warnings is a list of warning messages to return to the requesting API client. Warning messages describe a problem the client making the API request should correct or be aware of. Limit warnings to 120 characters if possible. Warnings over 256 characters and large numbers of warnings may be truncated.") public List getWarnings() { return warnings; } - public void setWarnings(List warnings) { this.warnings = warnings; } - @Override public boolean equals(Object o) { if (this == o) { @@ -248,21 +251,21 @@ public boolean equals(Object o) { return false; } AdmissionResponse admissionResponse = (AdmissionResponse) o; - return Objects.equals(this.allowed, admissionResponse.allowed) && - Objects.equals(this.auditAnnotations, admissionResponse.auditAnnotations) && - Arrays.equals(this.patch, admissionResponse.patch) && - Objects.equals(this.patchType, admissionResponse.patchType) && - Objects.equals(this.status, admissionResponse.status) && - Objects.equals(this.uid, admissionResponse.uid) && - Objects.equals(this.warnings, admissionResponse.warnings); + return Objects.equals(this.allowed, admissionResponse.allowed) + && Objects.equals(this.auditAnnotations, admissionResponse.auditAnnotations) + && Arrays.equals(this.patch, admissionResponse.patch) + && Objects.equals(this.patchType, admissionResponse.patchType) + && Objects.equals(this.status, admissionResponse.status) + && Objects.equals(this.uid, admissionResponse.uid) + && Objects.equals(this.warnings, admissionResponse.warnings); } @Override public int hashCode() { - return Objects.hash(allowed, auditAnnotations, Arrays.hashCode(patch), patchType, status, uid, warnings); + return Objects.hash( + allowed, auditAnnotations, Arrays.hashCode(patch), patchType, status, uid, warnings); } - @Override public String toString() { StringBuilder sb = new StringBuilder(); @@ -279,8 +282,7 @@ public String toString() { } /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). + * Convert the given object to string with each line indented by 4 spaces (except the first line). */ private String toIndentedString(Object o) { if (o == null) { @@ -288,6 +290,4 @@ private String toIndentedString(Object o) { } return o.toString().replace("\n", "\n "); } - } - diff --git a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionReview.java b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionReview.java index 6e4342044f..d9aca69c41 100644 --- a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionReview.java +++ b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/AdmissionReview.java @@ -1,146 +1,142 @@ /* - * k8s.io/api/admission/v1 - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 1.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.admissionreview.models; -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.kubernetes.client.admissionreview.models.AdmissionRequest; -import io.kubernetes.client.admissionreview.models.AdmissionResponse; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; +import java.util.Objects; -/** - * AdmissionReview describes an admission review request/response. - */ +/** AdmissionReview describes an admission review request/response. */ @ApiModel(description = "AdmissionReview describes an admission review request/response.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2021-07-01T14:30:02.888Z[Etc/UTC]") +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + date = "2021-07-01T14:30:02.888Z[Etc/UTC]") public class AdmissionReview { public static final String SERIALIZED_NAME_API_VERSION = "apiVersion"; + @SerializedName(SERIALIZED_NAME_API_VERSION) private String apiVersion; public static final String SERIALIZED_NAME_KIND = "kind"; + @SerializedName(SERIALIZED_NAME_KIND) private String kind; public static final String SERIALIZED_NAME_REQUEST = "request"; + @SerializedName(SERIALIZED_NAME_REQUEST) private AdmissionRequest request; public static final String SERIALIZED_NAME_RESPONSE = "response"; + @SerializedName(SERIALIZED_NAME_RESPONSE) private AdmissionResponse response; - public AdmissionReview apiVersion(String apiVersion) { - + this.apiVersion = apiVersion; return this; } - /** - * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should + * convert recognized schemas to the latest internal value, and may reject unrecognized values. + * More info: + * https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + * * @return apiVersion - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources") - + @ApiModelProperty( + value = + "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources") public String getApiVersion() { return apiVersion; } - public void setApiVersion(String apiVersion) { this.apiVersion = apiVersion; } - public AdmissionReview kind(String kind) { - + this.kind = kind; return this; } - /** - * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer + * this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More + * info: + * https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + * * @return kind - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds") - + @ApiModelProperty( + value = + "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds") public String getKind() { return kind; } - public void setKind(String kind) { this.kind = kind; } - public AdmissionReview request(AdmissionRequest request) { - + this.request = request; return this; } - /** + /** * Get request + * * @return request - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "") - public AdmissionRequest getRequest() { return request; } - public void setRequest(AdmissionRequest request) { this.request = request; } - public AdmissionReview response(AdmissionResponse response) { - + this.response = response; return this; } - /** + /** * Get response + * * @return response - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "") - public AdmissionResponse getResponse() { return response; } - public void setResponse(AdmissionResponse response) { this.response = response; } - @Override public boolean equals(Object o) { if (this == o) { @@ -150,10 +146,10 @@ public boolean equals(Object o) { return false; } AdmissionReview admissionReview = (AdmissionReview) o; - return Objects.equals(this.apiVersion, admissionReview.apiVersion) && - Objects.equals(this.kind, admissionReview.kind) && - Objects.equals(this.request, admissionReview.request) && - Objects.equals(this.response, admissionReview.response); + return Objects.equals(this.apiVersion, admissionReview.apiVersion) + && Objects.equals(this.kind, admissionReview.kind) + && Objects.equals(this.request, admissionReview.request) + && Objects.equals(this.response, admissionReview.response); } @Override @@ -161,7 +157,6 @@ public int hashCode() { return Objects.hash(apiVersion, kind, request, response); } - @Override public String toString() { StringBuilder sb = new StringBuilder(); @@ -175,8 +170,7 @@ public String toString() { } /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). + * Convert the given object to string with each line indented by 4 spaces (except the first line). */ private String toIndentedString(Object o) { if (o == null) { @@ -184,6 +178,4 @@ private String toIndentedString(Object o) { } return o.toString().replace("\n", "\n "); } - } - diff --git a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/GroupVersionKind.java b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/GroupVersionKind.java index d0484449d5..6329259ae0 100644 --- a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/GroupVersionKind.java +++ b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/GroupVersionKind.java @@ -1,114 +1,108 @@ /* - * k8s.io/api/admission/v1 - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 1.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.admissionreview.models; -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; +import java.util.Objects; /** - * GroupVersionKind unambiguously identifies a kind. It doesn't anonymously include GroupVersion to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling + * GroupVersionKind unambiguously identifies a kind. It doesn't anonymously include GroupVersion + * to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling */ -@ApiModel(description = "GroupVersionKind unambiguously identifies a kind. It doesn't anonymously include GroupVersion to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2021-07-01T14:30:02.888Z[Etc/UTC]") +@ApiModel( + description = + "GroupVersionKind unambiguously identifies a kind. It doesn't anonymously include GroupVersion to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling") +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + date = "2021-07-01T14:30:02.888Z[Etc/UTC]") public class GroupVersionKind { public static final String SERIALIZED_NAME_GROUP = "group"; + @SerializedName(SERIALIZED_NAME_GROUP) private String group; public static final String SERIALIZED_NAME_KIND = "kind"; + @SerializedName(SERIALIZED_NAME_KIND) private String kind; public static final String SERIALIZED_NAME_VERSION = "version"; + @SerializedName(SERIALIZED_NAME_VERSION) private String version; - public GroupVersionKind group(String group) { - + this.group = group; return this; } - /** + /** * Get group + * * @return group - **/ + */ @ApiModelProperty(required = true, value = "") - public String getGroup() { return group; } - public void setGroup(String group) { this.group = group; } - public GroupVersionKind kind(String kind) { - + this.kind = kind; return this; } - /** + /** * Get kind + * * @return kind - **/ + */ @ApiModelProperty(required = true, value = "") - public String getKind() { return kind; } - public void setKind(String kind) { this.kind = kind; } - public GroupVersionKind version(String version) { - + this.version = version; return this; } - /** + /** * Get version + * * @return version - **/ + */ @ApiModelProperty(required = true, value = "") - public String getVersion() { return version; } - public void setVersion(String version) { this.version = version; } - @Override public boolean equals(Object o) { if (this == o) { @@ -118,9 +112,9 @@ public boolean equals(Object o) { return false; } GroupVersionKind groupVersionKind = (GroupVersionKind) o; - return Objects.equals(this.group, groupVersionKind.group) && - Objects.equals(this.kind, groupVersionKind.kind) && - Objects.equals(this.version, groupVersionKind.version); + return Objects.equals(this.group, groupVersionKind.group) + && Objects.equals(this.kind, groupVersionKind.kind) + && Objects.equals(this.version, groupVersionKind.version); } @Override @@ -128,7 +122,6 @@ public int hashCode() { return Objects.hash(group, kind, version); } - @Override public String toString() { StringBuilder sb = new StringBuilder(); @@ -141,8 +134,7 @@ public String toString() { } /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). + * Convert the given object to string with each line indented by 4 spaces (except the first line). */ private String toIndentedString(Object o) { if (o == null) { @@ -150,6 +142,4 @@ private String toIndentedString(Object o) { } return o.toString().replace("\n", "\n "); } - } - diff --git a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/GroupVersionResource.java b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/GroupVersionResource.java index 0af5c55685..746d0262dc 100644 --- a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/GroupVersionResource.java +++ b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/GroupVersionResource.java @@ -1,114 +1,109 @@ /* - * k8s.io/api/admission/v1 - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 1.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.admissionreview.models; -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; +import java.util.Objects; /** - * GroupVersionResource unambiguously identifies a resource. It doesn't anonymously include GroupVersion to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling + * GroupVersionResource unambiguously identifies a resource. It doesn't anonymously include + * GroupVersion to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom + * marshalling */ -@ApiModel(description = "GroupVersionResource unambiguously identifies a resource. It doesn't anonymously include GroupVersion to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2021-07-01T14:30:02.888Z[Etc/UTC]") +@ApiModel( + description = + "GroupVersionResource unambiguously identifies a resource. It doesn't anonymously include GroupVersion to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling") +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + date = "2021-07-01T14:30:02.888Z[Etc/UTC]") public class GroupVersionResource { public static final String SERIALIZED_NAME_GROUP = "group"; + @SerializedName(SERIALIZED_NAME_GROUP) private String group; public static final String SERIALIZED_NAME_RESOURCE = "resource"; + @SerializedName(SERIALIZED_NAME_RESOURCE) private String resource; public static final String SERIALIZED_NAME_VERSION = "version"; + @SerializedName(SERIALIZED_NAME_VERSION) private String version; - public GroupVersionResource group(String group) { - + this.group = group; return this; } - /** + /** * Get group + * * @return group - **/ + */ @ApiModelProperty(required = true, value = "") - public String getGroup() { return group; } - public void setGroup(String group) { this.group = group; } - public GroupVersionResource resource(String resource) { - + this.resource = resource; return this; } - /** + /** * Get resource + * * @return resource - **/ + */ @ApiModelProperty(required = true, value = "") - public String getResource() { return resource; } - public void setResource(String resource) { this.resource = resource; } - public GroupVersionResource version(String version) { - + this.version = version; return this; } - /** + /** * Get version + * * @return version - **/ + */ @ApiModelProperty(required = true, value = "") - public String getVersion() { return version; } - public void setVersion(String version) { this.version = version; } - @Override public boolean equals(Object o) { if (this == o) { @@ -118,9 +113,9 @@ public boolean equals(Object o) { return false; } GroupVersionResource groupVersionResource = (GroupVersionResource) o; - return Objects.equals(this.group, groupVersionResource.group) && - Objects.equals(this.resource, groupVersionResource.resource) && - Objects.equals(this.version, groupVersionResource.version); + return Objects.equals(this.group, groupVersionResource.group) + && Objects.equals(this.resource, groupVersionResource.resource) + && Objects.equals(this.version, groupVersionResource.version); } @Override @@ -128,7 +123,6 @@ public int hashCode() { return Objects.hash(group, resource, version); } - @Override public String toString() { StringBuilder sb = new StringBuilder(); @@ -141,8 +135,7 @@ public String toString() { } /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). + * Convert the given object to string with each line indented by 4 spaces (except the first line). */ private String toIndentedString(Object o) { if (o == null) { @@ -150,6 +143,4 @@ private String toIndentedString(Object o) { } return o.toString().replace("\n", "\n "); } - } - diff --git a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/ListMeta.java b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/ListMeta.java index 6105794b40..df29a96f22 100644 --- a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/ListMeta.java +++ b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/ListMeta.java @@ -1,144 +1,163 @@ /* - * k8s.io/api/admission/v1 - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 1.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.admissionreview.models; -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; +import java.util.Objects; /** - * ListMeta describes metadata that synthetic resources must have, including lists and various status objects. A resource may have only one of {ObjectMeta, ListMeta}. + * ListMeta describes metadata that synthetic resources must have, including lists and various + * status objects. A resource may have only one of {ObjectMeta, ListMeta}. */ -@ApiModel(description = "ListMeta describes metadata that synthetic resources must have, including lists and various status objects. A resource may have only one of {ObjectMeta, ListMeta}.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2021-07-01T14:30:02.888Z[Etc/UTC]") +@ApiModel( + description = + "ListMeta describes metadata that synthetic resources must have, including lists and various status objects. A resource may have only one of {ObjectMeta, ListMeta}.") +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + date = "2021-07-01T14:30:02.888Z[Etc/UTC]") public class ListMeta { public static final String SERIALIZED_NAME_CONTINUE = "continue"; + @SerializedName(SERIALIZED_NAME_CONTINUE) private String _continue; public static final String SERIALIZED_NAME_REMAINING_ITEM_COUNT = "remainingItemCount"; + @SerializedName(SERIALIZED_NAME_REMAINING_ITEM_COUNT) private Long remainingItemCount; public static final String SERIALIZED_NAME_RESOURCE_VERSION = "resourceVersion"; + @SerializedName(SERIALIZED_NAME_RESOURCE_VERSION) private String resourceVersion; public static final String SERIALIZED_NAME_SELF_LINK = "selfLink"; + @SerializedName(SERIALIZED_NAME_SELF_LINK) private String selfLink; - public ListMeta _continue(String _continue) { - + this._continue = _continue; return this; } - /** - * continue may be set if the user set a limit on the number of items returned, and indicates that the server has more data available. The value is opaque and may be used to issue another request to the endpoint that served this list to retrieve the next set of available objects. Continuing a consistent list may not be possible if the server configuration has changed or more than a few minutes have passed. The resourceVersion field returned when using this continue value will be identical to the value in the first response, unless you have received this token from an error message. + /** + * continue may be set if the user set a limit on the number of items returned, and indicates that + * the server has more data available. The value is opaque and may be used to issue another + * request to the endpoint that served this list to retrieve the next set of available objects. + * Continuing a consistent list may not be possible if the server configuration has changed or + * more than a few minutes have passed. The resourceVersion field returned when using this + * continue value will be identical to the value in the first response, unless you have received + * this token from an error message. + * * @return _continue - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "continue may be set if the user set a limit on the number of items returned, and indicates that the server has more data available. The value is opaque and may be used to issue another request to the endpoint that served this list to retrieve the next set of available objects. Continuing a consistent list may not be possible if the server configuration has changed or more than a few minutes have passed. The resourceVersion field returned when using this continue value will be identical to the value in the first response, unless you have received this token from an error message.") - + @ApiModelProperty( + value = + "continue may be set if the user set a limit on the number of items returned, and indicates that the server has more data available. The value is opaque and may be used to issue another request to the endpoint that served this list to retrieve the next set of available objects. Continuing a consistent list may not be possible if the server configuration has changed or more than a few minutes have passed. The resourceVersion field returned when using this continue value will be identical to the value in the first response, unless you have received this token from an error message.") public String getContinue() { return _continue; } - public void setContinue(String _continue) { this._continue = _continue; } - public ListMeta remainingItemCount(Long remainingItemCount) { - + this.remainingItemCount = remainingItemCount; return this; } - /** - * remainingItemCount is the number of subsequent items in the list which are not included in this list response. If the list request contained label or field selectors, then the number of remaining items is unknown and the field will be left unset and omitted during serialization. If the list is complete (either because it is not chunking or because this is the last chunk), then there are no more remaining items and this field will be left unset and omitted during serialization. Servers older than v1.15 do not set this field. The intended use of the remainingItemCount is *estimating* the size of a collection. Clients should not rely on the remainingItemCount to be set or to be exact. + /** + * remainingItemCount is the number of subsequent items in the list which are not included in this + * list response. If the list request contained label or field selectors, then the number of + * remaining items is unknown and the field will be left unset and omitted during serialization. + * If the list is complete (either because it is not chunking or because this is the last chunk), + * then there are no more remaining items and this field will be left unset and omitted during + * serialization. Servers older than v1.15 do not set this field. The intended use of the + * remainingItemCount is *estimating* the size of a collection. Clients should not rely on the + * remainingItemCount to be set or to be exact. + * * @return remainingItemCount - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "remainingItemCount is the number of subsequent items in the list which are not included in this list response. If the list request contained label or field selectors, then the number of remaining items is unknown and the field will be left unset and omitted during serialization. If the list is complete (either because it is not chunking or because this is the last chunk), then there are no more remaining items and this field will be left unset and omitted during serialization. Servers older than v1.15 do not set this field. The intended use of the remainingItemCount is *estimating* the size of a collection. Clients should not rely on the remainingItemCount to be set or to be exact.") - + @ApiModelProperty( + value = + "remainingItemCount is the number of subsequent items in the list which are not included in this list response. If the list request contained label or field selectors, then the number of remaining items is unknown and the field will be left unset and omitted during serialization. If the list is complete (either because it is not chunking or because this is the last chunk), then there are no more remaining items and this field will be left unset and omitted during serialization. Servers older than v1.15 do not set this field. The intended use of the remainingItemCount is *estimating* the size of a collection. Clients should not rely on the remainingItemCount to be set or to be exact.") public Long getRemainingItemCount() { return remainingItemCount; } - public void setRemainingItemCount(Long remainingItemCount) { this.remainingItemCount = remainingItemCount; } - public ListMeta resourceVersion(String resourceVersion) { - + this.resourceVersion = resourceVersion; return this; } - /** - * String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency + /** + * String that identifies the server's internal version of this object that can be used by + * clients to determine when objects have changed. Value must be treated as opaque by clients and + * passed unmodified back to the server. Populated by the system. Read-only. More info: + * https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency + * * @return resourceVersion - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency") - + @ApiModelProperty( + value = + "String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency") public String getResourceVersion() { return resourceVersion; } - public void setResourceVersion(String resourceVersion) { this.resourceVersion = resourceVersion; } - public ListMeta selfLink(String selfLink) { - + this.selfLink = selfLink; return this; } - /** - * selfLink is a URL representing this object. Populated by the system. Read-only. DEPRECATED Kubernetes will stop propagating this field in 1.20 release and the field is planned to be removed in 1.21 release. + /** + * selfLink is a URL representing this object. Populated by the system. Read-only. DEPRECATED + * Kubernetes will stop propagating this field in 1.20 release and the field is planned to be + * removed in 1.21 release. + * * @return selfLink - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "selfLink is a URL representing this object. Populated by the system. Read-only. DEPRECATED Kubernetes will stop propagating this field in 1.20 release and the field is planned to be removed in 1.21 release.") - + @ApiModelProperty( + value = + "selfLink is a URL representing this object. Populated by the system. Read-only. DEPRECATED Kubernetes will stop propagating this field in 1.20 release and the field is planned to be removed in 1.21 release.") public String getSelfLink() { return selfLink; } - public void setSelfLink(String selfLink) { this.selfLink = selfLink; } - @Override public boolean equals(Object o) { if (this == o) { @@ -148,10 +167,10 @@ public boolean equals(Object o) { return false; } ListMeta listMeta = (ListMeta) o; - return Objects.equals(this._continue, listMeta._continue) && - Objects.equals(this.remainingItemCount, listMeta.remainingItemCount) && - Objects.equals(this.resourceVersion, listMeta.resourceVersion) && - Objects.equals(this.selfLink, listMeta.selfLink); + return Objects.equals(this._continue, listMeta._continue) + && Objects.equals(this.remainingItemCount, listMeta.remainingItemCount) + && Objects.equals(this.resourceVersion, listMeta.resourceVersion) + && Objects.equals(this.selfLink, listMeta.selfLink); } @Override @@ -159,7 +178,6 @@ public int hashCode() { return Objects.hash(_continue, remainingItemCount, resourceVersion, selfLink); } - @Override public String toString() { StringBuilder sb = new StringBuilder(); @@ -173,8 +191,7 @@ public String toString() { } /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). + * Convert the given object to string with each line indented by 4 spaces (except the first line). */ private String toIndentedString(Object o) { if (o == null) { @@ -182,6 +199,4 @@ private String toIndentedString(Object o) { } return o.toString().replace("\n", "\n "); } - } - diff --git a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/Status.java b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/Status.java index 0c4fd1dea6..393763dcd3 100644 --- a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/Status.java +++ b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/Status.java @@ -1,254 +1,253 @@ /* - * k8s.io/api/admission/v1 - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 1.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.admissionreview.models; -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.kubernetes.client.admissionreview.models.ListMeta; -import io.kubernetes.client.admissionreview.models.StatusDetails; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; +import java.util.Objects; -/** - * Status is a return value for calls that don't return other objects. - */ +/** Status is a return value for calls that don't return other objects. */ @ApiModel(description = "Status is a return value for calls that don't return other objects.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2021-07-01T14:30:02.888Z[Etc/UTC]") +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + date = "2021-07-01T14:30:02.888Z[Etc/UTC]") public class Status { public static final String SERIALIZED_NAME_API_VERSION = "apiVersion"; + @SerializedName(SERIALIZED_NAME_API_VERSION) private String apiVersion; public static final String SERIALIZED_NAME_CODE = "code"; + @SerializedName(SERIALIZED_NAME_CODE) private Integer code; public static final String SERIALIZED_NAME_DETAILS = "details"; + @SerializedName(SERIALIZED_NAME_DETAILS) private StatusDetails details; public static final String SERIALIZED_NAME_KIND = "kind"; + @SerializedName(SERIALIZED_NAME_KIND) private String kind; public static final String SERIALIZED_NAME_MESSAGE = "message"; + @SerializedName(SERIALIZED_NAME_MESSAGE) private String message; public static final String SERIALIZED_NAME_METADATA = "metadata"; + @SerializedName(SERIALIZED_NAME_METADATA) private ListMeta metadata; public static final String SERIALIZED_NAME_REASON = "reason"; + @SerializedName(SERIALIZED_NAME_REASON) private String reason; public static final String SERIALIZED_NAME_STATUS = "status"; + @SerializedName(SERIALIZED_NAME_STATUS) private String status; - public Status apiVersion(String apiVersion) { - + this.apiVersion = apiVersion; return this; } - /** - * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + /** + * APIVersion defines the versioned schema of this representation of an object. Servers should + * convert recognized schemas to the latest internal value, and may reject unrecognized values. + * More info: + * https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + * * @return apiVersion - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources") - + @ApiModelProperty( + value = + "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources") public String getApiVersion() { return apiVersion; } - public void setApiVersion(String apiVersion) { this.apiVersion = apiVersion; } - public Status code(Integer code) { - + this.code = code; return this; } - /** + /** * Suggested HTTP return code for this status, 0 if not set. + * * @return code - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "Suggested HTTP return code for this status, 0 if not set.") - public Integer getCode() { return code; } - public void setCode(Integer code) { this.code = code; } - public Status details(StatusDetails details) { - + this.details = details; return this; } - /** + /** * Get details + * * @return details - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "") - public StatusDetails getDetails() { return details; } - public void setDetails(StatusDetails details) { this.details = details; } - public Status kind(String kind) { - + this.kind = kind; return this; } - /** - * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + /** + * Kind is a string value representing the REST resource this object represents. Servers may infer + * this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More + * info: + * https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + * * @return kind - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds") - + @ApiModelProperty( + value = + "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds") public String getKind() { return kind; } - public void setKind(String kind) { this.kind = kind; } - public Status message(String message) { - + this.message = message; return this; } - /** + /** * A human-readable description of the status of this operation. + * * @return message - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "A human-readable description of the status of this operation.") - public String getMessage() { return message; } - public void setMessage(String message) { this.message = message; } - public Status metadata(ListMeta metadata) { - + this.metadata = metadata; return this; } - /** + /** * Get metadata + * * @return metadata - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "") - public ListMeta getMetadata() { return metadata; } - public void setMetadata(ListMeta metadata) { this.metadata = metadata; } - public Status reason(String reason) { - + this.reason = reason; return this; } - /** - * A machine-readable description of why this operation is in the \"Failure\" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it. + /** + * A machine-readable description of why this operation is in the \"Failure\" status. If + * this value is empty there is no information available. A Reason clarifies an HTTP status code + * but does not override it. + * * @return reason - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "A machine-readable description of why this operation is in the \"Failure\" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it.") - + @ApiModelProperty( + value = + "A machine-readable description of why this operation is in the \"Failure\" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it.") public String getReason() { return reason; } - public void setReason(String reason) { this.reason = reason; } - public Status status(String status) { - + this.status = status; return this; } - /** - * Status of the operation. One of: \"Success\" or \"Failure\". More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status + /** + * Status of the operation. One of: \"Success\" or \"Failure\". More info: + * https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status + * * @return status - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "Status of the operation. One of: \"Success\" or \"Failure\". More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status") - + @ApiModelProperty( + value = + "Status of the operation. One of: \"Success\" or \"Failure\". More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status") public String getStatus() { return status; } - public void setStatus(String status) { this.status = status; } - @Override public boolean equals(Object o) { if (this == o) { @@ -258,14 +257,14 @@ public boolean equals(Object o) { return false; } Status status = (Status) o; - return Objects.equals(this.apiVersion, status.apiVersion) && - Objects.equals(this.code, status.code) && - Objects.equals(this.details, status.details) && - Objects.equals(this.kind, status.kind) && - Objects.equals(this.message, status.message) && - Objects.equals(this.metadata, status.metadata) && - Objects.equals(this.reason, status.reason) && - Objects.equals(this.status, status.status); + return Objects.equals(this.apiVersion, status.apiVersion) + && Objects.equals(this.code, status.code) + && Objects.equals(this.details, status.details) + && Objects.equals(this.kind, status.kind) + && Objects.equals(this.message, status.message) + && Objects.equals(this.metadata, status.metadata) + && Objects.equals(this.reason, status.reason) + && Objects.equals(this.status, status.status); } @Override @@ -273,7 +272,6 @@ public int hashCode() { return Objects.hash(apiVersion, code, details, kind, message, metadata, reason, status); } - @Override public String toString() { StringBuilder sb = new StringBuilder(); @@ -291,8 +289,7 @@ public String toString() { } /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). + * Convert the given object to string with each line indented by 4 spaces (except the first line). */ private String toIndentedString(Object o) { if (o == null) { @@ -300,6 +297,4 @@ private String toIndentedString(Object o) { } return o.toString().replace("\n", "\n "); } - } - diff --git a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/StatusCause.java b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/StatusCause.java index a459e8411f..c5bd7dff50 100644 --- a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/StatusCause.java +++ b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/StatusCause.java @@ -1,117 +1,124 @@ /* - * k8s.io/api/admission/v1 - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 1.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.admissionreview.models; -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; +import java.util.Objects; /** - * StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered. + * StatusCause provides more information about an api.Status failure, including cases when multiple + * errors are encountered. */ -@ApiModel(description = "StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2021-07-01T14:30:02.888Z[Etc/UTC]") +@ApiModel( + description = + "StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered.") +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + date = "2021-07-01T14:30:02.888Z[Etc/UTC]") public class StatusCause { public static final String SERIALIZED_NAME_FIELD = "field"; + @SerializedName(SERIALIZED_NAME_FIELD) private String field; public static final String SERIALIZED_NAME_MESSAGE = "message"; + @SerializedName(SERIALIZED_NAME_MESSAGE) private String message; public static final String SERIALIZED_NAME_REASON = "reason"; + @SerializedName(SERIALIZED_NAME_REASON) private String reason; - public StatusCause field(String field) { - + this.field = field; return this; } - /** - * The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional. Examples: \"name\" - the field \"name\" on the current resource \"items[0].name\" - the field \"name\" on the first array entry in \"items\" + /** + * The field of the resource that has caused this error, as named by its JSON serialization. May + * include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may + * appear more than once in an array of causes due to fields having multiple errors. Optional. + * Examples: \"name\" - the field \"name\" on the current resource + * \"items[0].name\" - the field \"name\" on the first array entry in + * \"items\" + * * @return field - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional. Examples: \"name\" - the field \"name\" on the current resource \"items[0].name\" - the field \"name\" on the first array entry in \"items\"") - + @ApiModelProperty( + value = + "The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional. Examples: \"name\" - the field \"name\" on the current resource \"items[0].name\" - the field \"name\" on the first array entry in \"items\"") public String getField() { return field; } - public void setField(String field) { this.field = field; } - public StatusCause message(String message) { - + this.message = message; return this; } - /** - * A human-readable description of the cause of the error. This field may be presented as-is to a reader. + /** + * A human-readable description of the cause of the error. This field may be presented as-is to a + * reader. + * * @return message - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "A human-readable description of the cause of the error. This field may be presented as-is to a reader.") - + @ApiModelProperty( + value = + "A human-readable description of the cause of the error. This field may be presented as-is to a reader.") public String getMessage() { return message; } - public void setMessage(String message) { this.message = message; } - public StatusCause reason(String reason) { - + this.reason = reason; return this; } - /** - * A machine-readable description of the cause of the error. If this value is empty there is no information available. + /** + * A machine-readable description of the cause of the error. If this value is empty there is no + * information available. + * * @return reason - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "A machine-readable description of the cause of the error. If this value is empty there is no information available.") - + @ApiModelProperty( + value = + "A machine-readable description of the cause of the error. If this value is empty there is no information available.") public String getReason() { return reason; } - public void setReason(String reason) { this.reason = reason; } - @Override public boolean equals(Object o) { if (this == o) { @@ -121,9 +128,9 @@ public boolean equals(Object o) { return false; } StatusCause statusCause = (StatusCause) o; - return Objects.equals(this.field, statusCause.field) && - Objects.equals(this.message, statusCause.message) && - Objects.equals(this.reason, statusCause.reason); + return Objects.equals(this.field, statusCause.field) + && Objects.equals(this.message, statusCause.message) + && Objects.equals(this.reason, statusCause.reason); } @Override @@ -131,7 +138,6 @@ public int hashCode() { return Objects.hash(field, message, reason); } - @Override public String toString() { StringBuilder sb = new StringBuilder(); @@ -144,8 +150,7 @@ public String toString() { } /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). + * Convert the given object to string with each line indented by 4 spaces (except the first line). */ private String toIndentedString(Object o) { if (o == null) { @@ -153,6 +158,4 @@ private String toIndentedString(Object o) { } return o.toString().replace("\n", "\n "); } - } - diff --git a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/StatusDetails.java b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/StatusDetails.java index 56e7025ab4..b407c9c5e9 100644 --- a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/StatusDetails.java +++ b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/StatusDetails.java @@ -1,65 +1,69 @@ /* - * k8s.io/api/admission/v1 - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 1.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.admissionreview.models; -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; -import io.kubernetes.client.admissionreview.models.StatusCause; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; import java.util.ArrayList; import java.util.List; +import java.util.Objects; /** - * StatusDetails is a set of additional properties that MAY be set by the server to provide additional information about a response. The Reason field of a Status object defines what attributes will be set. Clients must ignore fields that do not match the defined type of each attribute, and should assume that any attribute may be empty, invalid, or under defined. + * StatusDetails is a set of additional properties that MAY be set by the server to provide + * additional information about a response. The Reason field of a Status object defines what + * attributes will be set. Clients must ignore fields that do not match the defined type of each + * attribute, and should assume that any attribute may be empty, invalid, or under defined. */ -@ApiModel(description = "StatusDetails is a set of additional properties that MAY be set by the server to provide additional information about a response. The Reason field of a Status object defines what attributes will be set. Clients must ignore fields that do not match the defined type of each attribute, and should assume that any attribute may be empty, invalid, or under defined.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2021-07-01T14:30:02.888Z[Etc/UTC]") +@ApiModel( + description = + "StatusDetails is a set of additional properties that MAY be set by the server to provide additional information about a response. The Reason field of a Status object defines what attributes will be set. Clients must ignore fields that do not match the defined type of each attribute, and should assume that any attribute may be empty, invalid, or under defined.") +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + date = "2021-07-01T14:30:02.888Z[Etc/UTC]") public class StatusDetails { public static final String SERIALIZED_NAME_CAUSES = "causes"; + @SerializedName(SERIALIZED_NAME_CAUSES) private List causes = null; public static final String SERIALIZED_NAME_GROUP = "group"; + @SerializedName(SERIALIZED_NAME_GROUP) private String group; public static final String SERIALIZED_NAME_KIND = "kind"; + @SerializedName(SERIALIZED_NAME_KIND) private String kind; public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) private String name; public static final String SERIALIZED_NAME_RETRY_AFTER_SECONDS = "retryAfterSeconds"; + @SerializedName(SERIALIZED_NAME_RETRY_AFTER_SECONDS) private Integer retryAfterSeconds; public static final String SERIALIZED_NAME_UID = "uid"; + @SerializedName(SERIALIZED_NAME_UID) private String uid; - public StatusDetails causes(List causes) { - + this.causes = causes; return this; } @@ -72,138 +76,144 @@ public StatusDetails addCausesItem(StatusCause causesItem) { return this; } - /** - * The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes. + /** + * The Causes array includes more details associated with the StatusReason failure. Not all + * StatusReasons may provide detailed causes. + * * @return causes - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes.") - + @ApiModelProperty( + value = + "The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes.") public List getCauses() { return causes; } - public void setCauses(List causes) { this.causes = causes; } - public StatusDetails group(String group) { - + this.group = group; return this; } - /** + /** * The group attribute of the resource associated with the status StatusReason. + * * @return group - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "The group attribute of the resource associated with the status StatusReason.") - + @ApiModelProperty( + value = "The group attribute of the resource associated with the status StatusReason.") public String getGroup() { return group; } - public void setGroup(String group) { this.group = group; } - public StatusDetails kind(String kind) { - + this.kind = kind; return this; } - /** - * The kind attribute of the resource associated with the status StatusReason. On some operations may differ from the requested resource Kind. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + /** + * The kind attribute of the resource associated with the status StatusReason. On some operations + * may differ from the requested resource Kind. More info: + * https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + * * @return kind - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "The kind attribute of the resource associated with the status StatusReason. On some operations may differ from the requested resource Kind. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds") - + @ApiModelProperty( + value = + "The kind attribute of the resource associated with the status StatusReason. On some operations may differ from the requested resource Kind. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds") public String getKind() { return kind; } - public void setKind(String kind) { this.kind = kind; } - public StatusDetails name(String name) { - + this.name = name; return this; } - /** - * The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described). + /** + * The name attribute of the resource associated with the status StatusReason (when there is a + * single name which can be described). + * * @return name - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described).") - + @ApiModelProperty( + value = + "The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described).") public String getName() { return name; } - public void setName(String name) { this.name = name; } - public StatusDetails retryAfterSeconds(Integer retryAfterSeconds) { - + this.retryAfterSeconds = retryAfterSeconds; return this; } - /** - * If specified, the time in seconds before the operation should be retried. Some errors may indicate the client must take an alternate action - for those errors this field may indicate how long to wait before taking the alternate action. + /** + * If specified, the time in seconds before the operation should be retried. Some errors may + * indicate the client must take an alternate action - for those errors this field may indicate + * how long to wait before taking the alternate action. + * * @return retryAfterSeconds - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "If specified, the time in seconds before the operation should be retried. Some errors may indicate the client must take an alternate action - for those errors this field may indicate how long to wait before taking the alternate action.") - + @ApiModelProperty( + value = + "If specified, the time in seconds before the operation should be retried. Some errors may indicate the client must take an alternate action - for those errors this field may indicate how long to wait before taking the alternate action.") public Integer getRetryAfterSeconds() { return retryAfterSeconds; } - public void setRetryAfterSeconds(Integer retryAfterSeconds) { this.retryAfterSeconds = retryAfterSeconds; } - public StatusDetails uid(String uid) { - + this.uid = uid; return this; } - /** - * UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids + /** + * UID of the resource. (when there is a single resource which can be described). More info: + * http://kubernetes.io/docs/user-guide/identifiers#uids + * * @return uid - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids") - + @ApiModelProperty( + value = + "UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids") public String getUid() { return uid; } - public void setUid(String uid) { this.uid = uid; } - @Override public boolean equals(Object o) { if (this == o) { @@ -213,12 +223,12 @@ public boolean equals(Object o) { return false; } StatusDetails statusDetails = (StatusDetails) o; - return Objects.equals(this.causes, statusDetails.causes) && - Objects.equals(this.group, statusDetails.group) && - Objects.equals(this.kind, statusDetails.kind) && - Objects.equals(this.name, statusDetails.name) && - Objects.equals(this.retryAfterSeconds, statusDetails.retryAfterSeconds) && - Objects.equals(this.uid, statusDetails.uid); + return Objects.equals(this.causes, statusDetails.causes) + && Objects.equals(this.group, statusDetails.group) + && Objects.equals(this.kind, statusDetails.kind) + && Objects.equals(this.name, statusDetails.name) + && Objects.equals(this.retryAfterSeconds, statusDetails.retryAfterSeconds) + && Objects.equals(this.uid, statusDetails.uid); } @Override @@ -226,7 +236,6 @@ public int hashCode() { return Objects.hash(causes, group, kind, name, retryAfterSeconds, uid); } - @Override public String toString() { StringBuilder sb = new StringBuilder(); @@ -242,8 +251,7 @@ public String toString() { } /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). + * Convert the given object to string with each line indented by 4 spaces (except the first line). */ private String toIndentedString(Object o) { if (o == null) { @@ -251,6 +259,4 @@ private String toIndentedString(Object o) { } return o.toString().replace("\n", "\n "); } - } - diff --git a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/UserInfo.java b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/UserInfo.java index d121b26132..ed70aac09f 100644 --- a/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/UserInfo.java +++ b/client-java-contrib/admissionreview/src/main/java/io/kubernetes/client/admissionreview/models/UserInfo.java @@ -1,58 +1,56 @@ /* - * k8s.io/api/admission/v1 - * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) - * - * The version of the OpenAPI document: 1.0 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.admissionreview.models; -import java.util.Objects; -import java.util.Arrays; -import com.google.gson.TypeAdapter; -import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; -import com.google.gson.stream.JsonReader; -import com.google.gson.stream.JsonWriter; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; -import java.io.IOException; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.Objects; -/** - * UserInfo holds the information about the user needed to implement the user.Info interface. - */ -@ApiModel(description = "UserInfo holds the information about the user needed to implement the user.Info interface.") -@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2021-07-01T14:30:02.888Z[Etc/UTC]") +/** UserInfo holds the information about the user needed to implement the user.Info interface. */ +@ApiModel( + description = + "UserInfo holds the information about the user needed to implement the user.Info interface.") +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + date = "2021-07-01T14:30:02.888Z[Etc/UTC]") public class UserInfo { public static final String SERIALIZED_NAME_EXTRA = "extra"; + @SerializedName(SERIALIZED_NAME_EXTRA) private Map> extra = null; public static final String SERIALIZED_NAME_GROUPS = "groups"; + @SerializedName(SERIALIZED_NAME_GROUPS) private List groups = null; public static final String SERIALIZED_NAME_UID = "uid"; + @SerializedName(SERIALIZED_NAME_UID) private String uid; public static final String SERIALIZED_NAME_USERNAME = "username"; + @SerializedName(SERIALIZED_NAME_USERNAME) private String username; - public UserInfo extra(Map> extra) { - + this.extra = extra; return this; } @@ -65,25 +63,23 @@ public UserInfo putExtraItem(String key, List extraItem) { return this; } - /** + /** * Any additional information provided by the authenticator. + * * @return extra - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "Any additional information provided by the authenticator.") - public Map> getExtra() { return extra; } - public void setExtra(Map> extra) { this.extra = extra; } - public UserInfo groups(List groups) { - + this.groups = groups; return this; } @@ -96,69 +92,66 @@ public UserInfo addGroupsItem(String groupsItem) { return this; } - /** + /** * The names of groups this user is a part of. + * * @return groups - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "The names of groups this user is a part of.") - public List getGroups() { return groups; } - public void setGroups(List groups) { this.groups = groups; } - public UserInfo uid(String uid) { - + this.uid = uid; return this; } - /** - * A unique value that identifies this user across time. If this user is deleted and another user by the same name is added, they will have different UIDs. + /** + * A unique value that identifies this user across time. If this user is deleted and another user + * by the same name is added, they will have different UIDs. + * * @return uid - **/ + */ @javax.annotation.Nullable - @ApiModelProperty(value = "A unique value that identifies this user across time. If this user is deleted and another user by the same name is added, they will have different UIDs.") - + @ApiModelProperty( + value = + "A unique value that identifies this user across time. If this user is deleted and another user by the same name is added, they will have different UIDs.") public String getUid() { return uid; } - public void setUid(String uid) { this.uid = uid; } - public UserInfo username(String username) { - + this.username = username; return this; } - /** + /** * The name that uniquely identifies this user among all active users. + * * @return username - **/ + */ @javax.annotation.Nullable @ApiModelProperty(value = "The name that uniquely identifies this user among all active users.") - public String getUsername() { return username; } - public void setUsername(String username) { this.username = username; } - @Override public boolean equals(Object o) { if (this == o) { @@ -168,10 +161,10 @@ public boolean equals(Object o) { return false; } UserInfo userInfo = (UserInfo) o; - return Objects.equals(this.extra, userInfo.extra) && - Objects.equals(this.groups, userInfo.groups) && - Objects.equals(this.uid, userInfo.uid) && - Objects.equals(this.username, userInfo.username); + return Objects.equals(this.extra, userInfo.extra) + && Objects.equals(this.groups, userInfo.groups) + && Objects.equals(this.uid, userInfo.uid) + && Objects.equals(this.username, userInfo.username); } @Override @@ -179,7 +172,6 @@ public int hashCode() { return Objects.hash(extra, groups, uid, username); } - @Override public String toString() { StringBuilder sb = new StringBuilder(); @@ -193,8 +185,7 @@ public String toString() { } /** - * Convert the given object to string with each line indented by 4 spaces - * (except the first line). + * Convert the given object to string with each line indented by 4 spaces (except the first line). */ private String toIndentedString(Object o) { if (o == null) { @@ -202,6 +193,4 @@ private String toIndentedString(Object o) { } return o.toString().replace("\n", "\n "); } - } - diff --git a/fluent/pom.xml b/fluent/pom.xml index 8a534d2c8b..64361212ac 100644 --- a/fluent/pom.xml +++ b/fluent/pom.xml @@ -40,7 +40,7 @@ com.diffplug.spotless spotless-maven-plugin - 2.17.2 + 2.20.0 true diff --git a/fluent/src/main/java/io/kubernetes/client/fluent/BaseFluent.java b/fluent/src/main/java/io/kubernetes/client/fluent/BaseFluent.java index 0bcd5db483..591898d7c6 100644 --- a/fluent/src/main/java/io/kubernetes/client/fluent/BaseFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/fluent/BaseFluent.java @@ -1,111 +1,157 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.fluent; -import java.util.LinkedHashSet; -import java.util.stream.Collectors; -import java.util.Set; import java.util.ArrayList; -import java.lang.String; -import java.util.Objects; -import java.lang.Class; -import java.util.List; -import java.lang.Boolean; import java.util.Arrays; -public class BaseFluent> implements io.kubernetes.client.fluent.Fluent,io.kubernetes.client.fluent.Visitable{ +import java.util.LinkedHashSet; +import java.util.Objects; +import java.util.stream.Collectors; + +public class BaseFluent> + implements io.kubernetes.client.fluent.Fluent, io.kubernetes.client.fluent.Visitable { public static final java.lang.String VISIT = "visit"; public final io.kubernetes.client.fluent.VisitableMap _visitables = new VisitableMap(); - public static io.kubernetes.client.fluent.VisitableBuilder builderOf(T item) { - if (item instanceof Editable) { - Object editor = ((Editable) item).edit(); - if (editor instanceof VisitableBuilder) { - return (VisitableBuilder) editor; - } -} -try { - return (VisitableBuilder) Class.forName(item.getClass().getName() + "Builder").getConstructor(item.getClass()) - .newInstance(item); -} catch (Exception e) { - throw new IllegalStateException("Failed to create builder for: " + item.getClass(), e); -} + public static io.kubernetes.client.fluent.VisitableBuilder builderOf(T item) { + if (item instanceof Editable) { + Object editor = ((Editable) item).edit(); + if (editor instanceof VisitableBuilder) { + return (VisitableBuilder) editor; + } + } + try { + return (VisitableBuilder) + Class.forName(item.getClass().getName() + "Builder") + .getConstructor(item.getClass()) + .newInstance(item); + } catch (Exception e) { + throw new IllegalStateException("Failed to create builder for: " + item.getClass(), e); + } } - public static java.util.List build(java.util.List> list) { - return list == null ? null : new ArrayList(list.stream().map(Builder::build).collect(Collectors.toList())); + + public static java.util.List build( + java.util.List> list) { + return list == null + ? null + : new ArrayList(list.stream().map(Builder::build).collect(Collectors.toList())); } - public static java.util.List build(java.util.Set> set) { - return set == null ? null : new ArrayList<>(set.stream().map(Builder::build).collect(Collectors.toList())); + + public static java.util.List build( + java.util.Set> set) { + return set == null + ? null + : new ArrayList<>(set.stream().map(Builder::build).collect(Collectors.toList())); } - public static java.util.List aggregate(java.util.List... lists) { - return new ArrayList(Arrays.stream(lists).filter(Objects::nonNull).collect(Collectors.toList())); + + public static java.util.List aggregate(java.util.List... lists) { + return new ArrayList( + Arrays.stream(lists).filter(Objects::nonNull).collect(Collectors.toList())); } - public static java.util.Set aggregate(java.util.Set[] sets) { - return new LinkedHashSet(Arrays.stream(sets).filter(Objects::nonNull).collect(Collectors.toSet())); + + public static java.util.Set aggregate(java.util.Set[] sets) { + return new LinkedHashSet( + Arrays.stream(sets).filter(Objects::nonNull).collect(Collectors.toSet())); } - public static ,F>java.lang.Boolean canVisit(V visitor,F fluent) { - if (visitor instanceof TypedVisitor) { - if (!((TypedVisitor) visitor).getType().isAssignableFrom(fluent.getClass())) { - return false; - } -} -if (visitor instanceof PathAwareTypedVisitor) { - PathAwareTypedVisitor pathAwareTypedVisitor = (PathAwareTypedVisitor) visitor; - Class parentType = pathAwareTypedVisitor.getParentType(); - Class actaulParentType = pathAwareTypedVisitor.getActualParentType(); - if (!parentType.isAssignableFrom(actaulParentType)) { - return false; - } -} -return hasCompatibleVisitMethod(visitor, fluent); + public static , F> java.lang.Boolean canVisit( + V visitor, F fluent) { + if (visitor instanceof TypedVisitor) { + if (!((TypedVisitor) visitor).getType().isAssignableFrom(fluent.getClass())) { + return false; + } + } + if (visitor instanceof PathAwareTypedVisitor) { + PathAwareTypedVisitor pathAwareTypedVisitor = (PathAwareTypedVisitor) visitor; + Class parentType = pathAwareTypedVisitor.getParentType(); + Class actaulParentType = pathAwareTypedVisitor.getActualParentType(); + if (!parentType.isAssignableFrom(actaulParentType)) { + return false; + } + } + return hasCompatibleVisitMethod(visitor, fluent); } - public static java.lang.Boolean hasCompatibleVisitMethod(V visitor,F fluent) { + + public static java.lang.Boolean hasCompatibleVisitMethod(V visitor, F fluent) { for (java.lang.reflect.Method method : visitor.getClass().getMethods()) { - if (!method.getName().equals(VISIT) || method.getParameterTypes().length != 1) { - continue; - } - Class visitorType = method.getParameterTypes()[0]; - if (visitorType.isAssignableFrom(fluent.getClass())) { - return true; - } else { + if (!method.getName().equals(VISIT) || method.getParameterTypes().length != 1) { + continue; + } + Class visitorType = method.getParameterTypes()[0]; + if (visitorType.isAssignableFrom(fluent.getClass())) { + return true; + } else { + return false; + } + } return false; } -} -return false; - } + public F accept(io.kubernetes.client.fluent.Visitor... visitors) { - return isPathAwareVisitorArray(visitors) ? acceptPathAware(asPathAwareVisitorArray(visitors)) : acceptInternal(visitors); - } - public F accept(java.lang.Class type,io.kubernetes.client.fluent.Visitor visitor) { - return accept(new TypedVisitor() { - @Override - public Class getType() { - return type; - } - @Override - public void visit(V element) { - visitor.visit(element); + return isPathAwareVisitorArray(visitors) + ? acceptPathAware(asPathAwareVisitorArray(visitors)) + : acceptInternal(visitors); } -}); + + public F accept(java.lang.Class type, io.kubernetes.client.fluent.Visitor visitor) { + return accept( + new TypedVisitor() { + @Override + public Class getType() { + return type; + } + + @Override + public void visit(V element) { + visitor.visit(element); + } + }); } + public F acceptInternal(io.kubernetes.client.fluent.Visitor... visitors) { for (Visitor visitor : visitors) { - for (Visitable visitable : _visitables) { - visitable.accept(visitor); - } + for (Visitable visitable : _visitables) { + visitable.accept(visitor); + } - if (canVisit(visitor, this)) { - visitor.visit(this); - } -} -return (F) this; + if (canVisit(visitor, this)) { + visitor.visit(this); + } + } + return (F) this; } - private F acceptPathAware(io.kubernetes.client.fluent.PathAwareTypedVisitor... pathAwareTypedVisitors) { - return acceptInternal(Arrays.stream(pathAwareTypedVisitors).map(p -> p.next(this)).toArray(size -> new PathAwareTypedVisitor[size])); + + private F acceptPathAware( + io.kubernetes.client.fluent.PathAwareTypedVisitor... pathAwareTypedVisitors) { + return acceptInternal( + Arrays.stream(pathAwareTypedVisitors) + .map(p -> p.next(this)) + .toArray(size -> new PathAwareTypedVisitor[size])); } - private static boolean isPathAwareVisitorArray(io.kubernetes.client.fluent.Visitor[] visitors) { - return !Arrays.stream(visitors).filter(v -> !(v instanceof PathAwareTypedVisitor)).findAny().isPresent(); + + private static boolean isPathAwareVisitorArray( + io.kubernetes.client.fluent.Visitor[] visitors) { + return !Arrays.stream(visitors) + .filter(v -> !(v instanceof PathAwareTypedVisitor)) + .findAny() + .isPresent(); } - private static io.kubernetes.client.fluent.PathAwareTypedVisitor[] asPathAwareVisitorArray(io.kubernetes.client.fluent.Visitor[] visitors) { - return Arrays.stream(visitors).filter(v -> v instanceof PathAwareTypedVisitor).map(v -> (PathAwareTypedVisitor) v).toArray(size -> new PathAwareTypedVisitor[size]); + + private static io.kubernetes.client.fluent.PathAwareTypedVisitor[] asPathAwareVisitorArray( + io.kubernetes.client.fluent.Visitor[] visitors) { + return Arrays.stream(visitors) + .filter(v -> v instanceof PathAwareTypedVisitor) + .map(v -> (PathAwareTypedVisitor) v) + .toArray(size -> new PathAwareTypedVisitor[size]); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/fluent/Builder.java b/fluent/src/main/java/io/kubernetes/client/fluent/Builder.java index e5939b60d8..757a491ad9 100644 --- a/fluent/src/main/java/io/kubernetes/client/fluent/Builder.java +++ b/fluent/src/main/java/io/kubernetes/client/fluent/Builder.java @@ -1,8 +1,18 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.fluent; -import java.lang.FunctionalInterface; - @java.lang.FunctionalInterface - public interface Builder{ +@java.lang.FunctionalInterface +public interface Builder { T build(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/fluent/Editable.java b/fluent/src/main/java/io/kubernetes/client/fluent/Editable.java index 1d4922af27..bbb46bd513 100644 --- a/fluent/src/main/java/io/kubernetes/client/fluent/Editable.java +++ b/fluent/src/main/java/io/kubernetes/client/fluent/Editable.java @@ -1,6 +1,17 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.fluent; -public interface Editable{ +public interface Editable { T edit(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/fluent/Fluent.java b/fluent/src/main/java/io/kubernetes/client/fluent/Fluent.java index 0f54ec9a0f..4d5fb2ec8b 100644 --- a/fluent/src/main/java/io/kubernetes/client/fluent/Fluent.java +++ b/fluent/src/main/java/io/kubernetes/client/fluent/Fluent.java @@ -1,5 +1,15 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.fluent; -public interface Fluent>{ - -} \ No newline at end of file +public interface Fluent> {} diff --git a/fluent/src/main/java/io/kubernetes/client/fluent/Nested.java b/fluent/src/main/java/io/kubernetes/client/fluent/Nested.java index edeb4d4e7e..3defd20e86 100644 --- a/fluent/src/main/java/io/kubernetes/client/fluent/Nested.java +++ b/fluent/src/main/java/io/kubernetes/client/fluent/Nested.java @@ -1,6 +1,17 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.fluent; -public interface Nested{ +public interface Nested { F and(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/fluent/PathAwareTypedVisitor.java b/fluent/src/main/java/io/kubernetes/client/fluent/PathAwareTypedVisitor.java index a3b6c4183a..ef7fcc045b 100644 --- a/fluent/src/main/java/io/kubernetes/client/fluent/PathAwareTypedVisitor.java +++ b/fluent/src/main/java/io/kubernetes/client/fluent/PathAwareTypedVisitor.java @@ -1,40 +1,60 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.fluent; import java.util.ArrayList; -import java.lang.Class; -import java.lang.Object; import java.util.List; -public class PathAwareTypedVisitor extends io.kubernetes.client.fluent.TypedVisitor{ + +public class PathAwareTypedVisitor extends io.kubernetes.client.fluent.TypedVisitor { PathAwareTypedVisitor(java.util.List path) { this.path = path; this.delegate = this; this.parentType = (Class

) getTypeArguments(PathAwareTypedVisitor.class, getClass()).get(1); } - PathAwareTypedVisitor(java.util.List path,io.kubernetes.client.fluent.PathAwareTypedVisitor delegate) { + + PathAwareTypedVisitor( + java.util.List path, + io.kubernetes.client.fluent.PathAwareTypedVisitor delegate) { this.path = path; this.delegate = this; - this.parentType = (Class

) getTypeArguments(PathAwareTypedVisitor.class, delegate.getClass()).get(1); + this.parentType = + (Class

) getTypeArguments(PathAwareTypedVisitor.class, delegate.getClass()).get(1); } + java.util.List path; - io.kubernetes.client.fluent.PathAwareTypedVisitor delegate; + io.kubernetes.client.fluent.PathAwareTypedVisitor delegate; java.lang.Class

parentType; + public void visit(V element) { delegate.path = path; delegate.visit(element); } - io.kubernetes.client.fluent.PathAwareTypedVisitor next(java.lang.Object item) { + + io.kubernetes.client.fluent.PathAwareTypedVisitor next(java.lang.Object item) { List path = new ArrayList(this.path); path.add(item); return new PathAwareTypedVisitor(path, this); } + P getParent() { return path.size() - 2 >= 0 ? (P) path.get(path.size() - 2) : null; } + java.lang.Class

getParentType() { return parentType != null ? parentType : delegate.getParentType(); } + protected java.lang.Class getActualParentType() { return path.size() - 2 >= 0 ? path.get(path.size() - 2).getClass() : Void.class; } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/fluent/TypedVisitor.java b/fluent/src/main/java/io/kubernetes/client/fluent/TypedVisitor.java index 2c4e9bbb19..74160f1272 100644 --- a/fluent/src/main/java/io/kubernetes/client/fluent/TypedVisitor.java +++ b/fluent/src/main/java/io/kubernetes/client/fluent/TypedVisitor.java @@ -1,24 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.fluent; import java.lang.reflect.Array; +import java.lang.reflect.GenericArrayType; import java.lang.reflect.ParameterizedType; import java.lang.reflect.Type; import java.lang.reflect.TypeVariable; import java.util.ArrayList; -import java.lang.Class; +import java.util.LinkedHashMap; import java.util.List; -import java.lang.reflect.GenericArrayType; import java.util.Map; -import java.util.LinkedHashMap; -public abstract class TypedVisitor implements io.kubernetes.client.fluent.Visitor{ + +public abstract class TypedVisitor implements io.kubernetes.client.fluent.Visitor { public java.lang.Class getType() { return (Class) getTypeArguments(TypedVisitor.class, getClass()).get(0); } + java.lang.Class getClass(java.lang.reflect.Type type) { - if (type instanceof Class) {return (Class) type;} else if (type instanceof ParameterizedType) {return getClass(((ParameterizedType) type).getRawType());} else if (type instanceof GenericArrayType) {Type componentType = ((GenericArrayType) type).getGenericComponentType(); Class componentClass = getClass(componentType); if (componentClass != null) {return Array.newInstance(componentClass, 0).getClass();} else {return null;}} else {return null;} + if (type instanceof Class) { + return (Class) type; + } else if (type instanceof ParameterizedType) { + return getClass(((ParameterizedType) type).getRawType()); + } else if (type instanceof GenericArrayType) { + Type componentType = ((GenericArrayType) type).getGenericComponentType(); + Class componentClass = getClass(componentType); + if (componentClass != null) { + return Array.newInstance(componentClass, 0).getClass(); + } else { + return null; + } + } else { + return null; + } } - java.util.List> getTypeArguments(java.lang.Class baseClass,java.lang.Class childClass) { - Map resolvedTypes = new LinkedHashMap<>(); + + java.util.List> getTypeArguments( + java.lang.Class baseClass, java.lang.Class childClass) { + Map resolvedTypes = new LinkedHashMap<>(); Type type = childClass; // start walking up the inheritance hierarchy until we hit baseClass while (!getClass(type).equals(baseClass)) { @@ -55,7 +84,5 @@ java.util.List> getTypeArguments(java.lang.Class baseCl typeArgumentsAsClasses.add(getClass(baseType)); } return typeArgumentsAsClasses; - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/fluent/Visitable.java b/fluent/src/main/java/io/kubernetes/client/fluent/Visitable.java index af123aae17..97f963c187 100644 --- a/fluent/src/main/java/io/kubernetes/client/fluent/Visitable.java +++ b/fluent/src/main/java/io/kubernetes/client/fluent/Visitable.java @@ -1,12 +1,33 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.fluent; -import java.lang.Class; -import java.lang.FunctionalInterface; - @java.lang.FunctionalInterface - public interface Visitable{ +@java.lang.FunctionalInterface +public interface Visitable { T accept(io.kubernetes.client.fluent.Visitor... visitor); - default T accept(java.lang.Class type,io.kubernetes.client.fluent.Visitor visitor) { - return accept(new TypedVisitor() {@Override public Class getType() {return type;} @Override public void visit(V element) {visitor.visit(element);}}); + + default T accept(java.lang.Class type, io.kubernetes.client.fluent.Visitor visitor) { + return accept( + new TypedVisitor() { + @Override + public Class getType() { + return type; + } + + @Override + public void visit(V element) { + visitor.visit(element); + } + }); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/fluent/VisitableBuilder.java b/fluent/src/main/java/io/kubernetes/client/fluent/VisitableBuilder.java index 7a48b7cfe9..a069f67980 100644 --- a/fluent/src/main/java/io/kubernetes/client/fluent/VisitableBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/fluent/VisitableBuilder.java @@ -1,5 +1,16 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.fluent; -public interface VisitableBuilder> extends io.kubernetes.client.fluent.Builder,io.kubernetes.client.fluent.Visitable{ - -} \ No newline at end of file +public interface VisitableBuilder> + extends io.kubernetes.client.fluent.Builder, io.kubernetes.client.fluent.Visitable {} diff --git a/fluent/src/main/java/io/kubernetes/client/fluent/VisitableMap.java b/fluent/src/main/java/io/kubernetes/client/fluent/VisitableMap.java index c3d88a64c7..cbc3f40257 100644 --- a/fluent/src/main/java/io/kubernetes/client/fluent/VisitableMap.java +++ b/fluent/src/main/java/io/kubernetes/client/fluent/VisitableMap.java @@ -1,31 +1,45 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.fluent; -import java.util.stream.Collectors; -import java.lang.Iterable; -import java.util.function.Consumer; -import java.util.HashMap; import java.util.ArrayList; -import java.util.Iterator; -import java.lang.Object; -import java.util.List; -import java.lang.String; -import java.util.Spliterator; -public class VisitableMap extends java.util.HashMap>> implements java.lang.Iterable>{ +import java.util.stream.Collectors; + +public class VisitableMap + extends java.util.HashMap< + java.lang.String, java.util.List>> + implements java.lang.Iterable> { public java.util.List> get(java.lang.Object key) { - if (!containsKey(key)) {put(String.valueOf(key), new ArrayList());} + if (!containsKey(key)) { + put(String.valueOf(key), new ArrayList()); + } return super.get(key); } + public java.util.List> aggregate() { return values().stream().flatMap(l -> l.stream()).collect(Collectors.toList()); } + public java.util.Iterator> iterator() { return aggregate().iterator(); } - public void forEach(java.util.function.Consumer> action) { + + public void forEach( + java.util.function.Consumer> action) { aggregate().forEach(action); } + public java.util.Spliterator spliterator() { return aggregate().spliterator(); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/fluent/Visitor.java b/fluent/src/main/java/io/kubernetes/client/fluent/Visitor.java index 712a3a34c5..0cfa4026cb 100644 --- a/fluent/src/main/java/io/kubernetes/client/fluent/Visitor.java +++ b/fluent/src/main/java/io/kubernetes/client/fluent/Visitor.java @@ -1,8 +1,18 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.fluent; -import java.lang.FunctionalInterface; - @java.lang.FunctionalInterface - public interface Visitor{ +@java.lang.FunctionalInterface +public interface Visitor { void visit(T element); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1ServiceReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1ServiceReferenceBuilder.java index 50fdb52b7a..9fcbdfb7fd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1ServiceReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1ServiceReferenceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class AdmissionregistrationV1ServiceReferenceBuilder extends io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class AdmissionregistrationV1ServiceReferenceBuilder + extends io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluentImpl< + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference, + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceBuilder> { public AdmissionregistrationV1ServiceReferenceBuilder() { this(false); } + public AdmissionregistrationV1ServiceReferenceBuilder(java.lang.Boolean validationEnabled) { this(new AdmissionregistrationV1ServiceReference(), validationEnabled); } - public AdmissionregistrationV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent fluent) { + + public AdmissionregistrationV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent fluent) { this(fluent, false); } - public AdmissionregistrationV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public AdmissionregistrationV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new AdmissionregistrationV1ServiceReference(), validationEnabled); } - public AdmissionregistrationV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent fluent,io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference instance) { + + public AdmissionregistrationV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent fluent, + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference instance) { this(fluent, instance, false); } - public AdmissionregistrationV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent fluent,io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public AdmissionregistrationV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent fluent, + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withNamespace(instance.getNamespace()); @@ -29,13 +56,18 @@ public AdmissionregistrationV1ServiceReferenceBuilder(io.kubernetes.client.opena fluent.withPort(instance.getPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public AdmissionregistrationV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference instance) { - this(instance,false); + + public AdmissionregistrationV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference instance) { + this(instance, false); } - public AdmissionregistrationV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public AdmissionregistrationV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withNamespace(instance.getNamespace()); @@ -44,30 +76,39 @@ public AdmissionregistrationV1ServiceReferenceBuilder(io.kubernetes.client.opena this.withPort(instance.getPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference build() { - AdmissionregistrationV1ServiceReference buildable = new AdmissionregistrationV1ServiceReference(); + AdmissionregistrationV1ServiceReference buildable = + new AdmissionregistrationV1ServiceReference(); buildable.setName(fluent.getName()); buildable.setNamespace(fluent.getNamespace()); buildable.setPath(fluent.getPath()); buildable.setPort(fluent.getPort()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - AdmissionregistrationV1ServiceReferenceBuilder that = (AdmissionregistrationV1ServiceReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + AdmissionregistrationV1ServiceReferenceBuilder that = + (AdmissionregistrationV1ServiceReferenceBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1ServiceReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1ServiceReferenceFluent.java index 71f3af99bc..1c51f72c42 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1ServiceReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1ServiceReferenceFluent.java @@ -1,45 +1,55 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface AdmissionregistrationV1ServiceReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface AdmissionregistrationV1ServiceReferenceFluent< + A extends + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getNamespace(); + public A withNamespace(java.lang.String namespace); + public java.lang.Boolean hasNamespace(); - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original); + public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); + public java.lang.Integer getPort(); + public A withPort(java.lang.Integer port); + public java.lang.Boolean hasPort(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1ServiceReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1ServiceReferenceFluentImpl.java index dc2690a345..3fdf750f85 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1ServiceReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1ServiceReferenceFluentImpl.java @@ -1,19 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class AdmissionregistrationV1ServiceReferenceFluentImpl< + A extends + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent< + A> { + public AdmissionregistrationV1ServiceReferenceFluentImpl() {} - /** - * Generated - */ -public class AdmissionregistrationV1ServiceReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent{ - public AdmissionregistrationV1ServiceReferenceFluentImpl() { - } - public AdmissionregistrationV1ServiceReferenceFluentImpl(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference instance) { + public AdmissionregistrationV1ServiceReferenceFluentImpl( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference instance) { this.withName(instance.getName()); this.withNamespace(instance.getNamespace()); @@ -21,84 +30,97 @@ public AdmissionregistrationV1ServiceReferenceFluentImpl(io.kubernetes.client.op this.withPath(instance.getPath()); this.withPort(instance.getPort()); - } + private java.lang.String name; private java.lang.String namespace; private java.lang.String path; private java.lang.Integer port; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getNamespace() { return this.namespace; } + public A withNamespace(java.lang.String namespace) { - this.namespace=namespace; return (A) this; + this.namespace = namespace; + return (A) this; } + public java.lang.Boolean hasNamespace() { return this.namespace != null; } - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original) { - return (A)withNamespace(new String(original)); + return (A) withNamespace(new String(original)); } + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } + public java.lang.Integer getPort() { return this.port; } + public A withPort(java.lang.Integer port) { - this.port=port; return (A) this; + this.port = port; + return (A) this; } + public java.lang.Boolean hasPort() { return this.port != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - AdmissionregistrationV1ServiceReferenceFluentImpl that = (AdmissionregistrationV1ServiceReferenceFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (namespace != null ? !namespace.equals(that.namespace) :that.namespace != null) return false; - if (path != null ? !path.equals(that.path) :that.path != null) return false; - if (port != null ? !port.equals(that.port) :that.port != null) return false; + AdmissionregistrationV1ServiceReferenceFluentImpl that = + (AdmissionregistrationV1ServiceReferenceFluentImpl) o; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (namespace != null ? !namespace.equals(that.namespace) : that.namespace != null) + return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; + if (port != null ? !port.equals(that.port) : that.port != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, namespace, path, port, super.hashCode()); + return java.util.Objects.hash(name, namespace, path, port, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1WebhookClientConfigBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1WebhookClientConfigBuilder.java index 14305bd4d5..cf64b483fa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1WebhookClientConfigBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1WebhookClientConfigBuilder.java @@ -1,68 +1,114 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class AdmissionregistrationV1WebhookClientConfigBuilder extends io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class AdmissionregistrationV1WebhookClientConfigBuilder + extends io.kubernetes.client.openapi.models + .AdmissionregistrationV1WebhookClientConfigFluentImpl< + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig, + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder> { public AdmissionregistrationV1WebhookClientConfigBuilder() { this(false); } + public AdmissionregistrationV1WebhookClientConfigBuilder(java.lang.Boolean validationEnabled) { this(new AdmissionregistrationV1WebhookClientConfig(), validationEnabled); } - public AdmissionregistrationV1WebhookClientConfigBuilder(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent fluent) { + + public AdmissionregistrationV1WebhookClientConfigBuilder( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + fluent) { this(fluent, false); } - public AdmissionregistrationV1WebhookClientConfigBuilder(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent fluent,java.lang.Boolean validationEnabled) { + + public AdmissionregistrationV1WebhookClientConfigBuilder( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + fluent, + java.lang.Boolean validationEnabled) { this(fluent, new AdmissionregistrationV1WebhookClientConfig(), validationEnabled); } - public AdmissionregistrationV1WebhookClientConfigBuilder(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent fluent,io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig instance) { + + public AdmissionregistrationV1WebhookClientConfigBuilder( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + fluent, + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig instance) { this(fluent, instance, false); } - public AdmissionregistrationV1WebhookClientConfigBuilder(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent fluent,io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public AdmissionregistrationV1WebhookClientConfigBuilder( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + fluent, + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCaBundle(instance.getCaBundle()); fluent.withService(instance.getService()); fluent.withUrl(instance.getUrl()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public AdmissionregistrationV1WebhookClientConfigBuilder(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig instance) { - this(instance,false); + + public AdmissionregistrationV1WebhookClientConfigBuilder( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig instance) { + this(instance, false); } - public AdmissionregistrationV1WebhookClientConfigBuilder(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public AdmissionregistrationV1WebhookClientConfigBuilder( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCaBundle(instance.getCaBundle()); this.withService(instance.getService()); this.withUrl(instance.getUrl()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig build() { - AdmissionregistrationV1WebhookClientConfig buildable = new AdmissionregistrationV1WebhookClientConfig(); + AdmissionregistrationV1WebhookClientConfig buildable = + new AdmissionregistrationV1WebhookClientConfig(); buildable.setCaBundle(fluent.getCaBundle()); buildable.setService(fluent.getService()); buildable.setUrl(fluent.getUrl()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - AdmissionregistrationV1WebhookClientConfigBuilder that = (AdmissionregistrationV1WebhookClientConfigBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + AdmissionregistrationV1WebhookClientConfigBuilder that = + (AdmissionregistrationV1WebhookClientConfigBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1WebhookClientConfigFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1WebhookClientConfigFluent.java index c35930bac8..f33cf26729 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1WebhookClientConfigFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1WebhookClientConfigFluent.java @@ -1,57 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Byte; -import java.util.Collection; -import java.lang.Boolean; - - /** - * Generated - */ -public interface AdmissionregistrationV1WebhookClientConfigFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface AdmissionregistrationV1WebhookClientConfigFluent< + A extends + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent> + extends io.kubernetes.client.fluent.Fluent { public A withCaBundle(byte... caBundle); + public byte[] getCaBundle(); - public A addToCaBundle(java.lang.Integer index,java.lang.Byte item); - public A setToCaBundle(java.lang.Integer index,java.lang.Byte item); + + public A addToCaBundle(java.lang.Integer index, java.lang.Byte item); + + public A setToCaBundle(java.lang.Integer index, java.lang.Byte item); + public A addToCaBundle(java.lang.Byte... items); + public A addAllToCaBundle(java.util.Collection items); + public A removeFromCaBundle(java.lang.Byte... items); + public A removeAllFromCaBundle(java.util.Collection items); + public java.lang.Boolean hasCaBundle(); - + /** * This method has been deprecated, please use method buildService instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference getService(); + public io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference buildService(); - public A withService(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference service); + + public A withService( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference service); + public java.lang.Boolean hasService(); - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent.ServiceNested withNewService(); - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent.ServiceNested withNewServiceLike(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference item); - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent.ServiceNested editService(); - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent.ServiceNested editOrNewService(); - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent.ServiceNested editOrNewServiceLike(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference item); + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + .ServiceNested< + A> + withNewService(); + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + .ServiceNested< + A> + withNewServiceLike( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference item); + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + .ServiceNested< + A> + editService(); + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + .ServiceNested< + A> + editOrNewService(); + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + .ServiceNested< + A> + editOrNewServiceLike( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference item); + public java.lang.String getUrl(); + public A withUrl(java.lang.String url); + public java.lang.Boolean hasUrl(); - - /** - * Method is deprecated. use withUrl instead. - */ + + /** Method is deprecated. use withUrl instead. */ @java.lang.Deprecated public A withNewUrl(java.lang.String original); - public interface ServiceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent>{ + + public interface ServiceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluent< + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + .ServiceNested< + N>> { public N and(); + public N endService(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1WebhookClientConfigFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1WebhookClientConfigFluentImpl.java index 10447119f5..b43d654105 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1WebhookClientConfigFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/AdmissionregistrationV1WebhookClientConfigFluentImpl.java @@ -1,156 +1,264 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Byte; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class AdmissionregistrationV1WebhookClientConfigFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent{ - public AdmissionregistrationV1WebhookClientConfigFluentImpl() { - } - public AdmissionregistrationV1WebhookClientConfigFluentImpl(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig instance) { +/** Generated */ +public class AdmissionregistrationV1WebhookClientConfigFluentImpl< + A extends + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent< + A> { + public AdmissionregistrationV1WebhookClientConfigFluentImpl() {} + + public AdmissionregistrationV1WebhookClientConfigFluentImpl( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig instance) { this.withCaBundle(instance.getCaBundle()); this.withService(instance.getService()); this.withUrl(instance.getUrl()); - } + private java.util.List caBundle; - private io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceBuilder service; + private io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceBuilder + service; private java.lang.String url; + public A withCaBundle(byte... caBundle) { - if (this.caBundle != null) {this.caBundle.clear();} - if (caBundle != null) {for (byte item :caBundle){ this.addToCaBundle(item);}} return (A) this; + if (this.caBundle != null) { + this.caBundle.clear(); + } + if (caBundle != null) { + for (byte item : caBundle) { + this.addToCaBundle(item); + } + } + return (A) this; } - public byte[] getCaBundle() { - //This needs to work with primitives, so we use arrays. -int size = caBundle != null ? caBundle.size() : 0; -byte[] result = new byte[size]; -if (size == 0) { - return result; -} -int index = 0; -for (byte item : caBundle) { - result[index++]=item; -} -return result; + public byte[] getCaBundle() { + // This needs to work with primitives, so we use arrays. + int size = caBundle != null ? caBundle.size() : 0; + byte[] result = new byte[size]; + if (size == 0) { + return result; + } + int index = 0; + for (byte item : caBundle) { + result[index++] = item; + } + return result; } - public A addToCaBundle(java.lang.Integer index,java.lang.Byte item) { - if (this.caBundle == null) {this.caBundle = new java.util.ArrayList();} + + public A addToCaBundle(java.lang.Integer index, java.lang.Byte item) { + if (this.caBundle == null) { + this.caBundle = new java.util.ArrayList(); + } this.caBundle.add(index, item); - return (A)this; + return (A) this; } - public A setToCaBundle(java.lang.Integer index,java.lang.Byte item) { - if (this.caBundle == null) {this.caBundle = new java.util.ArrayList();} - this.caBundle.set(index, item); return (A)this; + + public A setToCaBundle(java.lang.Integer index, java.lang.Byte item) { + if (this.caBundle == null) { + this.caBundle = new java.util.ArrayList(); + } + this.caBundle.set(index, item); + return (A) this; } + public A addToCaBundle(java.lang.Byte... items) { - if (this.caBundle == null) {this.caBundle = new java.util.ArrayList();} - for (java.lang.Byte item : items) {this.caBundle.add(item);} return (A)this; + if (this.caBundle == null) { + this.caBundle = new java.util.ArrayList(); + } + for (java.lang.Byte item : items) { + this.caBundle.add(item); + } + return (A) this; } + public A addAllToCaBundle(java.util.Collection items) { - if (this.caBundle == null) {this.caBundle = new java.util.ArrayList();} - for (java.lang.Byte item : items) {this.caBundle.add(item);} return (A)this; + if (this.caBundle == null) { + this.caBundle = new java.util.ArrayList(); + } + for (java.lang.Byte item : items) { + this.caBundle.add(item); + } + return (A) this; } + public A removeFromCaBundle(java.lang.Byte... items) { - for (java.lang.Byte item : items) {if (this.caBundle!= null){ this.caBundle.remove(item);}} return (A)this; + for (java.lang.Byte item : items) { + if (this.caBundle != null) { + this.caBundle.remove(item); + } + } + return (A) this; } + public A removeAllFromCaBundle(java.util.Collection items) { - for (java.lang.Byte item : items) {if (this.caBundle!= null){ this.caBundle.remove(item);}} return (A)this; + for (java.lang.Byte item : items) { + if (this.caBundle != null) { + this.caBundle.remove(item); + } + } + return (A) this; } + public java.lang.Boolean hasCaBundle() { return caBundle != null && !caBundle.isEmpty(); } - + /** * This method has been deprecated, please use method buildService instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference getService() { - return this.service!=null ?this.service.build():null; + return this.service != null ? this.service.build() : null; } - public io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference buildService() { - return this.service!=null ?this.service.build():null; + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference + buildService() { + return this.service != null ? this.service.build() : null; } - public A withService(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference service) { + + public A withService( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference service) { _visitables.get("service").remove(this.service); - if (service!=null){ this.service= new io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceBuilder(service); _visitables.get("service").add(this.service);} return (A) this; + if (service != null) { + this.service = + new io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceBuilder( + service); + _visitables.get("service").add(this.service); + } + return (A) this; } + public java.lang.Boolean hasService() { return this.service != null; } - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent.ServiceNested withNewService() { - return new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluentImpl.ServiceNestedImpl(); + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + .ServiceNested< + A> + withNewService() { + return new io.kubernetes.client.openapi.models + .AdmissionregistrationV1WebhookClientConfigFluentImpl.ServiceNestedImpl(); } - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent.ServiceNested withNewServiceLike(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference item) { - return new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluentImpl.ServiceNestedImpl(item); + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + .ServiceNested< + A> + withNewServiceLike( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference item) { + return new io.kubernetes.client.openapi.models + .AdmissionregistrationV1WebhookClientConfigFluentImpl.ServiceNestedImpl(item); } - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent.ServiceNested editService() { + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + .ServiceNested< + A> + editService() { return withNewServiceLike(getService()); } - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent.ServiceNested editOrNewService() { - return withNewServiceLike(getService() != null ? getService(): new io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + .ServiceNested< + A> + editOrNewService() { + return withNewServiceLike( + getService() != null + ? getService() + : new io.kubernetes.client.openapi.models + .AdmissionregistrationV1ServiceReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent.ServiceNested editOrNewServiceLike(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference item) { - return withNewServiceLike(getService() != null ? getService(): item); + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + .ServiceNested< + A> + editOrNewServiceLike( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference item) { + return withNewServiceLike(getService() != null ? getService() : item); } + public java.lang.String getUrl() { return this.url; } + public A withUrl(java.lang.String url) { - this.url=url; return (A) this; + this.url = url; + return (A) this; } + public java.lang.Boolean hasUrl() { return this.url != null; } - - /** - * Method is deprecated. use withUrl instead. - */ + + /** Method is deprecated. use withUrl instead. */ @java.lang.Deprecated public A withNewUrl(java.lang.String original) { - return (A)withUrl(new String(original)); + return (A) withUrl(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - AdmissionregistrationV1WebhookClientConfigFluentImpl that = (AdmissionregistrationV1WebhookClientConfigFluentImpl) o; - if (caBundle != null ? !caBundle.equals(that.caBundle) :that.caBundle != null) return false; - if (service != null ? !service.equals(that.service) :that.service != null) return false; - if (url != null ? !url.equals(that.url) :that.url != null) return false; + AdmissionregistrationV1WebhookClientConfigFluentImpl that = + (AdmissionregistrationV1WebhookClientConfigFluentImpl) o; + if (caBundle != null ? !caBundle.equals(that.caBundle) : that.caBundle != null) return false; + if (service != null ? !service.equals(that.service) : that.service != null) return false; + if (url != null ? !url.equals(that.url) : that.url != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(caBundle, service, url, super.hashCode()); + return java.util.Objects.hash(caBundle, service, url, super.hashCode()); } - public class ServiceNestedImpl extends io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluentImpl> implements io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent.ServiceNested,io.kubernetes.client.fluent.Nested{ - ServiceNestedImpl(io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference item) { - this.builder = new io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceBuilder(this, item); + + public class ServiceNestedImpl + extends io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceFluentImpl< + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent + .ServiceNested< + N>> + implements io.kubernetes.client.openapi.models + .AdmissionregistrationV1WebhookClientConfigFluent.ServiceNested< + N>, + io.kubernetes.client.fluent.Nested { + ServiceNestedImpl( + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReference item) { + this.builder = + new io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceBuilder( + this, item); } + ServiceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceBuilder( + this); } + io.kubernetes.client.openapi.models.AdmissionregistrationV1ServiceReferenceBuilder builder; + public N and() { - return (N) AdmissionregistrationV1WebhookClientConfigFluentImpl.this.withService(builder.build()); + return (N) + AdmissionregistrationV1WebhookClientConfigFluentImpl.this.withService(builder.build()); } + public N endService() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1ServiceReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1ServiceReferenceBuilder.java index 19ca38b770..ae9ad92771 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1ServiceReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1ServiceReferenceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class ApiextensionsV1ServiceReferenceBuilder extends io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class ApiextensionsV1ServiceReferenceBuilder + extends io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluentImpl< + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference, + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceBuilder> { public ApiextensionsV1ServiceReferenceBuilder() { this(false); } + public ApiextensionsV1ServiceReferenceBuilder(java.lang.Boolean validationEnabled) { this(new ApiextensionsV1ServiceReference(), validationEnabled); } - public ApiextensionsV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent fluent) { + + public ApiextensionsV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent fluent) { this(fluent, false); } - public ApiextensionsV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public ApiextensionsV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new ApiextensionsV1ServiceReference(), validationEnabled); } - public ApiextensionsV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent fluent,io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference instance) { + + public ApiextensionsV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent fluent, + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference instance) { this(fluent, instance, false); } - public ApiextensionsV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent fluent,io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public ApiextensionsV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent fluent, + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withNamespace(instance.getNamespace()); @@ -29,13 +56,18 @@ public ApiextensionsV1ServiceReferenceBuilder(io.kubernetes.client.openapi.model fluent.withPort(instance.getPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public ApiextensionsV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference instance) { - this(instance,false); + + public ApiextensionsV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference instance) { + this(instance, false); } - public ApiextensionsV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public ApiextensionsV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withNamespace(instance.getNamespace()); @@ -44,10 +76,12 @@ public ApiextensionsV1ServiceReferenceBuilder(io.kubernetes.client.openapi.model this.withPort(instance.getPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference build() { ApiextensionsV1ServiceReference buildable = new ApiextensionsV1ServiceReference(); buildable.setName(fluent.getName()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference build buildable.setPort(fluent.getPort()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; ApiextensionsV1ServiceReferenceBuilder that = (ApiextensionsV1ServiceReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1ServiceReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1ServiceReferenceFluent.java index 78f073c13a..e5464edc9a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1ServiceReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1ServiceReferenceFluent.java @@ -1,45 +1,54 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface ApiextensionsV1ServiceReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface ApiextensionsV1ServiceReferenceFluent< + A extends io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getNamespace(); + public A withNamespace(java.lang.String namespace); + public java.lang.Boolean hasNamespace(); - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original); + public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); + public java.lang.Integer getPort(); + public A withPort(java.lang.Integer port); + public java.lang.Boolean hasPort(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1ServiceReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1ServiceReferenceFluentImpl.java index c282223eef..f05f928c9d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1ServiceReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1ServiceReferenceFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class ApiextensionsV1ServiceReferenceFluentImpl< + A extends io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent { + public ApiextensionsV1ServiceReferenceFluentImpl() {} - /** - * Generated - */ -public class ApiextensionsV1ServiceReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent{ - public ApiextensionsV1ServiceReferenceFluentImpl() { - } - public ApiextensionsV1ServiceReferenceFluentImpl(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference instance) { + public ApiextensionsV1ServiceReferenceFluentImpl( + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference instance) { this.withName(instance.getName()); this.withNamespace(instance.getNamespace()); @@ -21,84 +28,96 @@ public ApiextensionsV1ServiceReferenceFluentImpl(io.kubernetes.client.openapi.mo this.withPath(instance.getPath()); this.withPort(instance.getPort()); - } + private java.lang.String name; private java.lang.String namespace; private java.lang.String path; private java.lang.Integer port; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getNamespace() { return this.namespace; } + public A withNamespace(java.lang.String namespace) { - this.namespace=namespace; return (A) this; + this.namespace = namespace; + return (A) this; } + public java.lang.Boolean hasNamespace() { return this.namespace != null; } - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original) { - return (A)withNamespace(new String(original)); + return (A) withNamespace(new String(original)); } + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } + public java.lang.Integer getPort() { return this.port; } + public A withPort(java.lang.Integer port) { - this.port=port; return (A) this; + this.port = port; + return (A) this; } + public java.lang.Boolean hasPort() { return this.port != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; ApiextensionsV1ServiceReferenceFluentImpl that = (ApiextensionsV1ServiceReferenceFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (namespace != null ? !namespace.equals(that.namespace) :that.namespace != null) return false; - if (path != null ? !path.equals(that.path) :that.path != null) return false; - if (port != null ? !port.equals(that.port) :that.port != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (namespace != null ? !namespace.equals(that.namespace) : that.namespace != null) + return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; + if (port != null ? !port.equals(that.port) : that.port != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, namespace, path, port, super.hashCode()); + return java.util.Objects.hash(name, namespace, path, port, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1WebhookClientConfigBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1WebhookClientConfigBuilder.java index 9814f9147e..2979281f11 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1WebhookClientConfigBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1WebhookClientConfigBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class ApiextensionsV1WebhookClientConfigBuilder extends io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class ApiextensionsV1WebhookClientConfigBuilder + extends io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluentImpl< + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig, + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigBuilder> { public ApiextensionsV1WebhookClientConfigBuilder() { this(false); } + public ApiextensionsV1WebhookClientConfigBuilder(java.lang.Boolean validationEnabled) { this(new ApiextensionsV1WebhookClientConfig(), validationEnabled); } - public ApiextensionsV1WebhookClientConfigBuilder(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent fluent) { + + public ApiextensionsV1WebhookClientConfigBuilder( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent fluent) { this(fluent, false); } - public ApiextensionsV1WebhookClientConfigBuilder(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent fluent,java.lang.Boolean validationEnabled) { + + public ApiextensionsV1WebhookClientConfigBuilder( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new ApiextensionsV1WebhookClientConfig(), validationEnabled); } - public ApiextensionsV1WebhookClientConfigBuilder(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent fluent,io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig instance) { + + public ApiextensionsV1WebhookClientConfigBuilder( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent fluent, + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig instance) { this(fluent, instance, false); } - public ApiextensionsV1WebhookClientConfigBuilder(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent fluent,io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public ApiextensionsV1WebhookClientConfigBuilder( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent fluent, + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCaBundle(instance.getCaBundle()); fluent.withService(instance.getService()); fluent.withUrl(instance.getUrl()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public ApiextensionsV1WebhookClientConfigBuilder(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig instance) { - this(instance,false); + + public ApiextensionsV1WebhookClientConfigBuilder( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig instance) { + this(instance, false); } - public ApiextensionsV1WebhookClientConfigBuilder(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public ApiextensionsV1WebhookClientConfigBuilder( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCaBundle(instance.getCaBundle()); this.withService(instance.getService()); this.withUrl(instance.getUrl()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig build() { ApiextensionsV1WebhookClientConfig buildable = new ApiextensionsV1WebhookClientConfig(); buildable.setCaBundle(fluent.getCaBundle()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig bu buildable.setUrl(fluent.getUrl()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; ApiextensionsV1WebhookClientConfigBuilder that = (ApiextensionsV1WebhookClientConfigBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1WebhookClientConfigFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1WebhookClientConfigFluent.java index 7c9eae3b89..8781028604 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1WebhookClientConfigFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1WebhookClientConfigFluent.java @@ -1,57 +1,92 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Byte; -import java.util.Collection; -import java.lang.Boolean; - - /** - * Generated - */ -public interface ApiextensionsV1WebhookClientConfigFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface ApiextensionsV1WebhookClientConfigFluent< + A extends io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent> + extends io.kubernetes.client.fluent.Fluent { public A withCaBundle(byte... caBundle); + public byte[] getCaBundle(); - public A addToCaBundle(java.lang.Integer index,java.lang.Byte item); - public A setToCaBundle(java.lang.Integer index,java.lang.Byte item); + + public A addToCaBundle(java.lang.Integer index, java.lang.Byte item); + + public A setToCaBundle(java.lang.Integer index, java.lang.Byte item); + public A addToCaBundle(java.lang.Byte... items); + public A addAllToCaBundle(java.util.Collection items); + public A removeFromCaBundle(java.lang.Byte... items); + public A removeAllFromCaBundle(java.util.Collection items); + public java.lang.Boolean hasCaBundle(); - + /** * This method has been deprecated, please use method buildService instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference getService(); + public io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference buildService(); + public A withService(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference service); + public java.lang.Boolean hasService(); - public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested withNewService(); - public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested withNewServiceLike(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference item); - public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested editService(); - public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested editOrNewService(); - public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested editOrNewServiceLike(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference item); + + public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested< + A> + withNewService(); + + public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested< + A> + withNewServiceLike(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference item); + + public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested< + A> + editService(); + + public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested< + A> + editOrNewService(); + + public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested< + A> + editOrNewServiceLike( + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference item); + public java.lang.String getUrl(); + public A withUrl(java.lang.String url); + public java.lang.Boolean hasUrl(); - - /** - * Method is deprecated. use withUrl instead. - */ + + /** Method is deprecated. use withUrl instead. */ @java.lang.Deprecated public A withNewUrl(java.lang.String original); - public interface ServiceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent>{ + + public interface ServiceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluent< + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent + .ServiceNested< + N>> { public N and(); + public N endService(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1WebhookClientConfigFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1WebhookClientConfigFluentImpl.java index 77713fa97e..bb5c6e0ab8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1WebhookClientConfigFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiextensionsV1WebhookClientConfigFluentImpl.java @@ -1,156 +1,249 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Byte; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class ApiextensionsV1WebhookClientConfigFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent{ - public ApiextensionsV1WebhookClientConfigFluentImpl() { - } - public ApiextensionsV1WebhookClientConfigFluentImpl(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig instance) { +/** Generated */ +public class ApiextensionsV1WebhookClientConfigFluentImpl< + A extends io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent { + public ApiextensionsV1WebhookClientConfigFluentImpl() {} + + public ApiextensionsV1WebhookClientConfigFluentImpl( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig instance) { this.withCaBundle(instance.getCaBundle()); this.withService(instance.getService()); this.withUrl(instance.getUrl()); - } + private java.util.List caBundle; private io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceBuilder service; private java.lang.String url; + public A withCaBundle(byte... caBundle) { - if (this.caBundle != null) {this.caBundle.clear();} - if (caBundle != null) {for (byte item :caBundle){ this.addToCaBundle(item);}} return (A) this; + if (this.caBundle != null) { + this.caBundle.clear(); + } + if (caBundle != null) { + for (byte item : caBundle) { + this.addToCaBundle(item); + } + } + return (A) this; } - public byte[] getCaBundle() { - //This needs to work with primitives, so we use arrays. -int size = caBundle != null ? caBundle.size() : 0; -byte[] result = new byte[size]; -if (size == 0) { - return result; -} -int index = 0; -for (byte item : caBundle) { - result[index++]=item; -} -return result; + public byte[] getCaBundle() { + // This needs to work with primitives, so we use arrays. + int size = caBundle != null ? caBundle.size() : 0; + byte[] result = new byte[size]; + if (size == 0) { + return result; + } + int index = 0; + for (byte item : caBundle) { + result[index++] = item; + } + return result; } - public A addToCaBundle(java.lang.Integer index,java.lang.Byte item) { - if (this.caBundle == null) {this.caBundle = new java.util.ArrayList();} + + public A addToCaBundle(java.lang.Integer index, java.lang.Byte item) { + if (this.caBundle == null) { + this.caBundle = new java.util.ArrayList(); + } this.caBundle.add(index, item); - return (A)this; + return (A) this; } - public A setToCaBundle(java.lang.Integer index,java.lang.Byte item) { - if (this.caBundle == null) {this.caBundle = new java.util.ArrayList();} - this.caBundle.set(index, item); return (A)this; + + public A setToCaBundle(java.lang.Integer index, java.lang.Byte item) { + if (this.caBundle == null) { + this.caBundle = new java.util.ArrayList(); + } + this.caBundle.set(index, item); + return (A) this; } + public A addToCaBundle(java.lang.Byte... items) { - if (this.caBundle == null) {this.caBundle = new java.util.ArrayList();} - for (java.lang.Byte item : items) {this.caBundle.add(item);} return (A)this; + if (this.caBundle == null) { + this.caBundle = new java.util.ArrayList(); + } + for (java.lang.Byte item : items) { + this.caBundle.add(item); + } + return (A) this; } + public A addAllToCaBundle(java.util.Collection items) { - if (this.caBundle == null) {this.caBundle = new java.util.ArrayList();} - for (java.lang.Byte item : items) {this.caBundle.add(item);} return (A)this; + if (this.caBundle == null) { + this.caBundle = new java.util.ArrayList(); + } + for (java.lang.Byte item : items) { + this.caBundle.add(item); + } + return (A) this; } + public A removeFromCaBundle(java.lang.Byte... items) { - for (java.lang.Byte item : items) {if (this.caBundle!= null){ this.caBundle.remove(item);}} return (A)this; + for (java.lang.Byte item : items) { + if (this.caBundle != null) { + this.caBundle.remove(item); + } + } + return (A) this; } + public A removeAllFromCaBundle(java.util.Collection items) { - for (java.lang.Byte item : items) {if (this.caBundle!= null){ this.caBundle.remove(item);}} return (A)this; + for (java.lang.Byte item : items) { + if (this.caBundle != null) { + this.caBundle.remove(item); + } + } + return (A) this; } + public java.lang.Boolean hasCaBundle() { return caBundle != null && !caBundle.isEmpty(); } - + /** * This method has been deprecated, please use method buildService instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference getService() { - return this.service!=null ?this.service.build():null; + return this.service != null ? this.service.build() : null; } + public io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference buildService() { - return this.service!=null ?this.service.build():null; + return this.service != null ? this.service.build() : null; } - public A withService(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference service) { + + public A withService( + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference service) { _visitables.get("service").remove(this.service); - if (service!=null){ this.service= new io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceBuilder(service); _visitables.get("service").add(this.service);} return (A) this; + if (service != null) { + this.service = + new io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceBuilder(service); + _visitables.get("service").add(this.service); + } + return (A) this; } + public java.lang.Boolean hasService() { return this.service != null; } - public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested withNewService() { - return new io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluentImpl.ServiceNestedImpl(); + + public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested< + A> + withNewService() { + return new io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluentImpl + .ServiceNestedImpl(); } - public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested withNewServiceLike(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference item) { - return new io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluentImpl.ServiceNestedImpl(item); + + public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested< + A> + withNewServiceLike(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference item) { + return new io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluentImpl + .ServiceNestedImpl(item); } - public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested editService() { + + public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested< + A> + editService() { return withNewServiceLike(getService()); } - public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested editOrNewService() { - return withNewServiceLike(getService() != null ? getService(): new io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested< + A> + editOrNewService() { + return withNewServiceLike( + getService() != null + ? getService() + : new io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested editOrNewServiceLike(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference item) { - return withNewServiceLike(getService() != null ? getService(): item); + + public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested< + A> + editOrNewServiceLike( + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference item) { + return withNewServiceLike(getService() != null ? getService() : item); } + public java.lang.String getUrl() { return this.url; } + public A withUrl(java.lang.String url) { - this.url=url; return (A) this; + this.url = url; + return (A) this; } + public java.lang.Boolean hasUrl() { return this.url != null; } - - /** - * Method is deprecated. use withUrl instead. - */ + + /** Method is deprecated. use withUrl instead. */ @java.lang.Deprecated public A withNewUrl(java.lang.String original) { - return (A)withUrl(new String(original)); + return (A) withUrl(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - ApiextensionsV1WebhookClientConfigFluentImpl that = (ApiextensionsV1WebhookClientConfigFluentImpl) o; - if (caBundle != null ? !caBundle.equals(that.caBundle) :that.caBundle != null) return false; - if (service != null ? !service.equals(that.service) :that.service != null) return false; - if (url != null ? !url.equals(that.url) :that.url != null) return false; + ApiextensionsV1WebhookClientConfigFluentImpl that = + (ApiextensionsV1WebhookClientConfigFluentImpl) o; + if (caBundle != null ? !caBundle.equals(that.caBundle) : that.caBundle != null) return false; + if (service != null ? !service.equals(that.service) : that.service != null) return false; + if (url != null ? !url.equals(that.url) : that.url != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(caBundle, service, url, super.hashCode()); + return java.util.Objects.hash(caBundle, service, url, super.hashCode()); } - public class ServiceNestedImpl extends io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluentImpl> implements io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent.ServiceNested,io.kubernetes.client.fluent.Nested{ + + public class ServiceNestedImpl + extends io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceFluentImpl< + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent + .ServiceNested< + N>> + implements io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent + .ServiceNested< + N>, + io.kubernetes.client.fluent.Nested { ServiceNestedImpl(io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReference item) { - this.builder = new io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceBuilder( + this, item); } + ServiceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceBuilder(this); } + io.kubernetes.client.openapi.models.ApiextensionsV1ServiceReferenceBuilder builder; + public N and() { return (N) ApiextensionsV1WebhookClientConfigFluentImpl.this.withService(builder.build()); } + public N endService() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiregistrationV1ServiceReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiregistrationV1ServiceReferenceBuilder.java index a140ffe9b6..1ff67b94a8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiregistrationV1ServiceReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiregistrationV1ServiceReferenceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class ApiregistrationV1ServiceReferenceBuilder extends io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class ApiregistrationV1ServiceReferenceBuilder + extends io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluentImpl< + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference, + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceBuilder> { public ApiregistrationV1ServiceReferenceBuilder() { this(false); } + public ApiregistrationV1ServiceReferenceBuilder(java.lang.Boolean validationEnabled) { this(new ApiregistrationV1ServiceReference(), validationEnabled); } - public ApiregistrationV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent fluent) { + + public ApiregistrationV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent fluent) { this(fluent, false); } - public ApiregistrationV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public ApiregistrationV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new ApiregistrationV1ServiceReference(), validationEnabled); } - public ApiregistrationV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent fluent,io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference instance) { + + public ApiregistrationV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent fluent, + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference instance) { this(fluent, instance, false); } - public ApiregistrationV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent fluent,io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public ApiregistrationV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent fluent, + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withNamespace(instance.getNamespace()); fluent.withPort(instance.getPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public ApiregistrationV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference instance) { - this(instance,false); + + public ApiregistrationV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference instance) { + this(instance, false); } - public ApiregistrationV1ServiceReferenceBuilder(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public ApiregistrationV1ServiceReferenceBuilder( + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withNamespace(instance.getNamespace()); this.withPort(instance.getPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference build() { ApiregistrationV1ServiceReference buildable = new ApiregistrationV1ServiceReference(); buildable.setName(fluent.getName()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference bui buildable.setPort(fluent.getPort()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; ApiregistrationV1ServiceReferenceBuilder that = (ApiregistrationV1ServiceReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiregistrationV1ServiceReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiregistrationV1ServiceReferenceFluent.java index 9483b02887..511f91c42f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiregistrationV1ServiceReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiregistrationV1ServiceReferenceFluent.java @@ -1,36 +1,44 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface ApiregistrationV1ServiceReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface ApiregistrationV1ServiceReferenceFluent< + A extends io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getNamespace(); + public A withNamespace(java.lang.String namespace); + public java.lang.Boolean hasNamespace(); - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original); + public java.lang.Integer getPort(); + public A withPort(java.lang.Integer port); + public java.lang.Boolean hasPort(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiregistrationV1ServiceReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiregistrationV1ServiceReferenceFluentImpl.java index 00582b3171..342849032f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiregistrationV1ServiceReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/ApiregistrationV1ServiceReferenceFluentImpl.java @@ -1,83 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class ApiregistrationV1ServiceReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent{ - public ApiregistrationV1ServiceReferenceFluentImpl() { - } - public ApiregistrationV1ServiceReferenceFluentImpl(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference instance) { +/** Generated */ +public class ApiregistrationV1ServiceReferenceFluentImpl< + A extends io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent { + public ApiregistrationV1ServiceReferenceFluentImpl() {} + + public ApiregistrationV1ServiceReferenceFluentImpl( + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference instance) { this.withName(instance.getName()); this.withNamespace(instance.getNamespace()); this.withPort(instance.getPort()); - } + private java.lang.String name; private java.lang.String namespace; private java.lang.Integer port; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getNamespace() { return this.namespace; } + public A withNamespace(java.lang.String namespace) { - this.namespace=namespace; return (A) this; + this.namespace = namespace; + return (A) this; } + public java.lang.Boolean hasNamespace() { return this.namespace != null; } - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original) { - return (A)withNamespace(new String(original)); + return (A) withNamespace(new String(original)); } + public java.lang.Integer getPort() { return this.port; } + public A withPort(java.lang.Integer port) { - this.port=port; return (A) this; + this.port = port; + return (A) this; } + public java.lang.Boolean hasPort() { return this.port != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - ApiregistrationV1ServiceReferenceFluentImpl that = (ApiregistrationV1ServiceReferenceFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (namespace != null ? !namespace.equals(that.namespace) :that.namespace != null) return false; - if (port != null ? !port.equals(that.port) :that.port != null) return false; + ApiregistrationV1ServiceReferenceFluentImpl that = + (ApiregistrationV1ServiceReferenceFluentImpl) o; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (namespace != null ? !namespace.equals(that.namespace) : that.namespace != null) + return false; + if (port != null ? !port.equals(that.port) : that.port != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, namespace, port, super.hashCode()); + return java.util.Objects.hash(name, namespace, port, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/AuthenticationV1TokenRequestBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/AuthenticationV1TokenRequestBuilder.java index 04c29f7abf..c2a56ab937 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/AuthenticationV1TokenRequestBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/AuthenticationV1TokenRequestBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class AuthenticationV1TokenRequestBuilder extends io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class AuthenticationV1TokenRequestBuilder + extends io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl< + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequest, + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestBuilder> { public AuthenticationV1TokenRequestBuilder() { this(false); } + public AuthenticationV1TokenRequestBuilder(java.lang.Boolean validationEnabled) { this(new AuthenticationV1TokenRequest(), validationEnabled); } - public AuthenticationV1TokenRequestBuilder(io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent fluent) { + + public AuthenticationV1TokenRequestBuilder( + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent fluent) { this(fluent, false); } - public AuthenticationV1TokenRequestBuilder(io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent fluent,java.lang.Boolean validationEnabled) { + + public AuthenticationV1TokenRequestBuilder( + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new AuthenticationV1TokenRequest(), validationEnabled); } - public AuthenticationV1TokenRequestBuilder(io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent fluent,io.kubernetes.client.openapi.models.AuthenticationV1TokenRequest instance) { + + public AuthenticationV1TokenRequestBuilder( + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent fluent, + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequest instance) { this(fluent, instance, false); } - public AuthenticationV1TokenRequestBuilder(io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent fluent,io.kubernetes.client.openapi.models.AuthenticationV1TokenRequest instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public AuthenticationV1TokenRequestBuilder( + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent fluent, + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequest instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public AuthenticationV1TokenRequestBuilder(io.kubernetes.client.openapi.models.A fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public AuthenticationV1TokenRequestBuilder(io.kubernetes.client.openapi.models.AuthenticationV1TokenRequest instance) { - this(instance,false); + + public AuthenticationV1TokenRequestBuilder( + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequest instance) { + this(instance, false); } - public AuthenticationV1TokenRequestBuilder(io.kubernetes.client.openapi.models.AuthenticationV1TokenRequest instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public AuthenticationV1TokenRequestBuilder( + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequest instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public AuthenticationV1TokenRequestBuilder(io.kubernetes.client.openapi.models.A this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequest build() { AuthenticationV1TokenRequest buildable = new AuthenticationV1TokenRequest(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequest build() buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; AuthenticationV1TokenRequestBuilder that = (AuthenticationV1TokenRequestBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/AuthenticationV1TokenRequestFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/AuthenticationV1TokenRequestFluent.java index 40dd4cc2c4..79eacae272 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/AuthenticationV1TokenRequestFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/AuthenticationV1TokenRequestFluent.java @@ -1,93 +1,155 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface AuthenticationV1TokenRequestFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface AuthenticationV1TokenRequestFluent< + A extends io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TokenRequestSpec getSpec(); + public io.kubernetes.client.openapi.models.V1TokenRequestSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1TokenRequestSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1TokenRequestSpec item); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1TokenRequestSpec item); - + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1TokenRequestSpec item); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1TokenRequestSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TokenRequestStatus getStatus(); + public io.kubernetes.client.openapi.models.V1TokenRequestStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1TokenRequestStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1TokenRequestStatus item); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1TokenRequestStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1TokenRequestStatus item); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1TokenRequestStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent< + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested< + N>> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent< + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested< + N>> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/AuthenticationV1TokenRequestFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/AuthenticationV1TokenRequestFluentImpl.java index 23da0f4724..1dd8c5bd45 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/AuthenticationV1TokenRequestFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/AuthenticationV1TokenRequestFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class AuthenticationV1TokenRequestFluentImpl< + A extends io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent { + public AuthenticationV1TokenRequestFluentImpl() {} - /** - * Generated - */ -public class AuthenticationV1TokenRequestFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent{ - public AuthenticationV1TokenRequestFluentImpl() { - } - public AuthenticationV1TokenRequestFluentImpl(io.kubernetes.client.openapi.models.AuthenticationV1TokenRequest instance) { + public AuthenticationV1TokenRequestFluentImpl( + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequest instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,315 @@ public AuthenticationV1TokenRequestFluentImpl(io.kubernetes.client.openapi.model this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1TokenRequestSpecBuilder spec; private io.kubernetes.client.openapi.models.V1TokenRequestStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TokenRequestSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1TokenRequestSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1TokenRequestSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1TokenRequestSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1TokenRequestSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1TokenRequestSpec item) { - return new io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1TokenRequestSpec item) { + return new io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1TokenRequestSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1TokenRequestSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1TokenRequestSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1TokenRequestSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TokenRequestStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1TokenRequestStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1TokenRequestStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1TokenRequestStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1TokenRequestStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1TokenRequestStatus item) { - return new io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1TokenRequestStatus item) { + return new io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1TokenRequestStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1TokenRequestStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1TokenRequestStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1TokenRequestStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; AuthenticationV1TokenRequestFluentImpl that = (AuthenticationV1TokenRequestFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) AuthenticationV1TokenRequestFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1TokenRequestSpecFluentImpl> implements io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1TokenRequestSpecFluentImpl< + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested> + implements io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.SpecNested< + N>, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1TokenRequestSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1TokenRequestSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1TokenRequestSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1TokenRequestSpecBuilder builder; + public N and() { return (N) AuthenticationV1TokenRequestFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1TokenRequestStatusFluentImpl> implements io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1TokenRequestStatusFluentImpl< + io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent.StatusNested> + implements io.kubernetes.client.openapi.models.AuthenticationV1TokenRequestFluent + .StatusNested< + N>, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1TokenRequestStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1TokenRequestStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1TokenRequestStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1TokenRequestStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1TokenRequestStatusBuilder builder; + public N and() { return (N) AuthenticationV1TokenRequestFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EndpointPortBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EndpointPortBuilder.java index 4ee0f30b99..ae0ba9f26d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EndpointPortBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EndpointPortBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class CoreV1EndpointPortBuilder extends io.kubernetes.client.openapi.models.CoreV1EndpointPortFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class CoreV1EndpointPortBuilder + extends io.kubernetes.client.openapi.models.CoreV1EndpointPortFluentImpl< + io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.CoreV1EndpointPort, + io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder> { public CoreV1EndpointPortBuilder() { this(false); } + public CoreV1EndpointPortBuilder(java.lang.Boolean validationEnabled) { this(new CoreV1EndpointPort(), validationEnabled); } - public CoreV1EndpointPortBuilder(io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent fluent) { + + public CoreV1EndpointPortBuilder( + io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent fluent) { this(fluent, false); } - public CoreV1EndpointPortBuilder(io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent fluent,java.lang.Boolean validationEnabled) { + + public CoreV1EndpointPortBuilder( + io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new CoreV1EndpointPort(), validationEnabled); } - public CoreV1EndpointPortBuilder(io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent fluent,io.kubernetes.client.openapi.models.CoreV1EndpointPort instance) { + + public CoreV1EndpointPortBuilder( + io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent fluent, + io.kubernetes.client.openapi.models.CoreV1EndpointPort instance) { this(fluent, instance, false); } - public CoreV1EndpointPortBuilder(io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent fluent,io.kubernetes.client.openapi.models.CoreV1EndpointPort instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public CoreV1EndpointPortBuilder( + io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent fluent, + io.kubernetes.client.openapi.models.CoreV1EndpointPort instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAppProtocol(instance.getAppProtocol()); fluent.withName(instance.getName()); @@ -29,13 +56,18 @@ public CoreV1EndpointPortBuilder(io.kubernetes.client.openapi.models.CoreV1Endpo fluent.withProtocol(instance.getProtocol()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public CoreV1EndpointPortBuilder(io.kubernetes.client.openapi.models.CoreV1EndpointPort instance) { - this(instance,false); + + public CoreV1EndpointPortBuilder( + io.kubernetes.client.openapi.models.CoreV1EndpointPort instance) { + this(instance, false); } - public CoreV1EndpointPortBuilder(io.kubernetes.client.openapi.models.CoreV1EndpointPort instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public CoreV1EndpointPortBuilder( + io.kubernetes.client.openapi.models.CoreV1EndpointPort instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAppProtocol(instance.getAppProtocol()); this.withName(instance.getName()); @@ -44,10 +76,12 @@ public CoreV1EndpointPortBuilder(io.kubernetes.client.openapi.models.CoreV1Endpo this.withProtocol(instance.getProtocol()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.CoreV1EndpointPort build() { CoreV1EndpointPort buildable = new CoreV1EndpointPort(); buildable.setAppProtocol(fluent.getAppProtocol()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.CoreV1EndpointPort build() { buildable.setProtocol(fluent.getProtocol()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; CoreV1EndpointPortBuilder that = (CoreV1EndpointPortBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EndpointPortFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EndpointPortFluent.java index 217a8afe07..88cb60c584 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EndpointPortFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EndpointPortFluent.java @@ -1,39 +1,51 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface CoreV1EndpointPortFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface CoreV1EndpointPortFluent< + A extends io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getAppProtocol(); + public A withAppProtocol(java.lang.String appProtocol); + public java.lang.Boolean hasAppProtocol(); - - /** - * Method is deprecated. use withAppProtocol instead. - */ + + /** Method is deprecated. use withAppProtocol instead. */ @java.lang.Deprecated public A withNewAppProtocol(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Integer getPort(); + public A withPort(java.lang.Integer port); + public java.lang.Boolean hasPort(); + public io.kubernetes.client.openapi.models.CoreV1EndpointPort.ProtocolEnum getProtocol(); - public A withProtocol(io.kubernetes.client.openapi.models.CoreV1EndpointPort.ProtocolEnum protocol); + + public A withProtocol( + io.kubernetes.client.openapi.models.CoreV1EndpointPort.ProtocolEnum protocol); + public java.lang.Boolean hasProtocol(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EndpointPortFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EndpointPortFluentImpl.java index c89ae958e2..9ef14ebc45 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EndpointPortFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EndpointPortFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class CoreV1EndpointPortFluentImpl< + A extends io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent { + public CoreV1EndpointPortFluentImpl() {} - /** - * Generated - */ -public class CoreV1EndpointPortFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent{ - public CoreV1EndpointPortFluentImpl() { - } - public CoreV1EndpointPortFluentImpl(io.kubernetes.client.openapi.models.CoreV1EndpointPort instance) { + public CoreV1EndpointPortFluentImpl( + io.kubernetes.client.openapi.models.CoreV1EndpointPort instance) { this.withAppProtocol(instance.getAppProtocol()); this.withName(instance.getName()); @@ -21,76 +28,91 @@ public CoreV1EndpointPortFluentImpl(io.kubernetes.client.openapi.models.CoreV1En this.withPort(instance.getPort()); this.withProtocol(instance.getProtocol()); - } + private java.lang.String appProtocol; private java.lang.String name; private java.lang.Integer port; private io.kubernetes.client.openapi.models.CoreV1EndpointPort.ProtocolEnum protocol; + public java.lang.String getAppProtocol() { return this.appProtocol; } + public A withAppProtocol(java.lang.String appProtocol) { - this.appProtocol=appProtocol; return (A) this; + this.appProtocol = appProtocol; + return (A) this; } + public java.lang.Boolean hasAppProtocol() { return this.appProtocol != null; } - - /** - * Method is deprecated. use withAppProtocol instead. - */ + + /** Method is deprecated. use withAppProtocol instead. */ @java.lang.Deprecated public A withNewAppProtocol(java.lang.String original) { - return (A)withAppProtocol(new String(original)); + return (A) withAppProtocol(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Integer getPort() { return this.port; } + public A withPort(java.lang.Integer port) { - this.port=port; return (A) this; + this.port = port; + return (A) this; } + public java.lang.Boolean hasPort() { return this.port != null; } + public io.kubernetes.client.openapi.models.CoreV1EndpointPort.ProtocolEnum getProtocol() { return this.protocol; } - public A withProtocol(io.kubernetes.client.openapi.models.CoreV1EndpointPort.ProtocolEnum protocol) { - this.protocol=protocol; return (A) this; + + public A withProtocol( + io.kubernetes.client.openapi.models.CoreV1EndpointPort.ProtocolEnum protocol) { + this.protocol = protocol; + return (A) this; } + public java.lang.Boolean hasProtocol() { return this.protocol != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; CoreV1EndpointPortFluentImpl that = (CoreV1EndpointPortFluentImpl) o; - if (appProtocol != null ? !appProtocol.equals(that.appProtocol) :that.appProtocol != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (port != null ? !port.equals(that.port) :that.port != null) return false; - if (protocol != null ? !protocol.equals(that.protocol) :that.protocol != null) return false; + if (appProtocol != null ? !appProtocol.equals(that.appProtocol) : that.appProtocol != null) + return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (port != null ? !port.equals(that.port) : that.port != null) return false; + if (protocol != null ? !protocol.equals(that.protocol) : that.protocol != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(appProtocol, name, port, protocol, super.hashCode()); + return java.util.Objects.hash(appProtocol, name, port, protocol, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventBuilder.java index ceb938aa1b..41a5ac4991 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class CoreV1EventBuilder extends io.kubernetes.client.openapi.models.CoreV1EventFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class CoreV1EventBuilder + extends io.kubernetes.client.openapi.models.CoreV1EventFluentImpl< + io.kubernetes.client.openapi.models.CoreV1EventBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.CoreV1Event, + io.kubernetes.client.openapi.models.CoreV1EventBuilder> { public CoreV1EventBuilder() { this(false); } + public CoreV1EventBuilder(java.lang.Boolean validationEnabled) { this(new CoreV1Event(), validationEnabled); } + public CoreV1EventBuilder(io.kubernetes.client.openapi.models.CoreV1EventFluent fluent) { this(fluent, false); } - public CoreV1EventBuilder(io.kubernetes.client.openapi.models.CoreV1EventFluent fluent,java.lang.Boolean validationEnabled) { + + public CoreV1EventBuilder( + io.kubernetes.client.openapi.models.CoreV1EventFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new CoreV1Event(), validationEnabled); } - public CoreV1EventBuilder(io.kubernetes.client.openapi.models.CoreV1EventFluent fluent,io.kubernetes.client.openapi.models.CoreV1Event instance) { + + public CoreV1EventBuilder( + io.kubernetes.client.openapi.models.CoreV1EventFluent fluent, + io.kubernetes.client.openapi.models.CoreV1Event instance) { this(fluent, instance, false); } - public CoreV1EventBuilder(io.kubernetes.client.openapi.models.CoreV1EventFluent fluent,io.kubernetes.client.openapi.models.CoreV1Event instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public CoreV1EventBuilder( + io.kubernetes.client.openapi.models.CoreV1EventFluent fluent, + io.kubernetes.client.openapi.models.CoreV1Event instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAction(instance.getAction()); fluent.withApiVersion(instance.getApiVersion()); @@ -55,13 +81,17 @@ public CoreV1EventBuilder(io.kubernetes.client.openapi.models.CoreV1EventFluent< fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public CoreV1EventBuilder(io.kubernetes.client.openapi.models.CoreV1Event instance) { - this(instance,false); + this(instance, false); } - public CoreV1EventBuilder(io.kubernetes.client.openapi.models.CoreV1Event instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public CoreV1EventBuilder( + io.kubernetes.client.openapi.models.CoreV1Event instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAction(instance.getAction()); this.withApiVersion(instance.getApiVersion()); @@ -96,10 +126,12 @@ public CoreV1EventBuilder(io.kubernetes.client.openapi.models.CoreV1Event instan this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.CoreV1EventFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.CoreV1Event build() { CoreV1Event buildable = new CoreV1Event(); buildable.setAction(fluent.getAction()); @@ -121,18 +153,23 @@ public io.kubernetes.client.openapi.models.CoreV1Event build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; CoreV1EventBuilder that = (CoreV1EventBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventFluent.java index 23a9868ae8..157c9a3f6a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventFluent.java @@ -1,201 +1,301 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.time.OffsetDateTime; - - /** - * Generated - */ -public interface CoreV1EventFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface CoreV1EventFluent< + A extends io.kubernetes.client.openapi.models.CoreV1EventFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getAction(); + public A withAction(java.lang.String action); + public java.lang.Boolean hasAction(); - - /** - * Method is deprecated. use withAction instead. - */ + + /** Method is deprecated. use withAction instead. */ @java.lang.Deprecated public A withNewAction(java.lang.String original); + public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.Integer getCount(); + public A withCount(java.lang.Integer count); + public java.lang.Boolean hasCount(); + public java.time.OffsetDateTime getEventTime(); + public A withEventTime(java.time.OffsetDateTime eventTime); + public java.lang.Boolean hasEventTime(); + public java.time.OffsetDateTime getFirstTimestamp(); + public A withFirstTimestamp(java.time.OffsetDateTime firstTimestamp); + public java.lang.Boolean hasFirstTimestamp(); - + /** * This method has been deprecated, please use method buildInvolvedObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getInvolvedObject(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildInvolvedObject(); + public A withInvolvedObject(io.kubernetes.client.openapi.models.V1ObjectReference involvedObject); + public java.lang.Boolean hasInvolvedObject(); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested withNewInvolvedObject(); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested withNewInvolvedObjectLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested editInvolvedObject(); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested editOrNewInvolvedObject(); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested editOrNewInvolvedObjectLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested + withNewInvolvedObject(); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested + withNewInvolvedObjectLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested + editInvolvedObject(); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested + editOrNewInvolvedObject(); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested + editOrNewInvolvedObjectLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.time.OffsetDateTime getLastTimestamp(); + public A withLastTimestamp(java.time.OffsetDateTime lastTimestamp); + public java.lang.Boolean hasLastTimestamp(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); - + /** * This method has been deprecated, please use method buildRelated instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getRelated(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildRelated(); + public A withRelated(io.kubernetes.client.openapi.models.V1ObjectReference related); + public java.lang.Boolean hasRelated(); + public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested withNewRelated(); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested withNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested withNewRelatedLike( + io.kubernetes.client.openapi.models.V1ObjectReference item); + public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested editRelated(); + public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested editOrNewRelated(); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested editOrNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested + editOrNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + public java.lang.String getReportingComponent(); + public A withReportingComponent(java.lang.String reportingComponent); + public java.lang.Boolean hasReportingComponent(); - - /** - * Method is deprecated. use withReportingComponent instead. - */ + + /** Method is deprecated. use withReportingComponent instead. */ @java.lang.Deprecated public A withNewReportingComponent(java.lang.String original); + public java.lang.String getReportingInstance(); + public A withReportingInstance(java.lang.String reportingInstance); + public java.lang.Boolean hasReportingInstance(); - - /** - * Method is deprecated. use withReportingInstance instead. - */ + + /** Method is deprecated. use withReportingInstance instead. */ @java.lang.Deprecated public A withNewReportingInstance(java.lang.String original); - + /** * This method has been deprecated, please use method buildSeries instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.CoreV1EventSeries getSeries(); + public io.kubernetes.client.openapi.models.CoreV1EventSeries buildSeries(); + public A withSeries(io.kubernetes.client.openapi.models.CoreV1EventSeries series); + public java.lang.Boolean hasSeries(); + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested withNewSeries(); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested withNewSeriesLike(io.kubernetes.client.openapi.models.CoreV1EventSeries item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested withNewSeriesLike( + io.kubernetes.client.openapi.models.CoreV1EventSeries item); + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested editSeries(); + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested editOrNewSeries(); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested editOrNewSeriesLike(io.kubernetes.client.openapi.models.CoreV1EventSeries item); - + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested editOrNewSeriesLike( + io.kubernetes.client.openapi.models.CoreV1EventSeries item); + /** * This method has been deprecated, please use method buildSource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EventSource getSource(); + public io.kubernetes.client.openapi.models.V1EventSource buildSource(); + public A withSource(io.kubernetes.client.openapi.models.V1EventSource source); + public java.lang.Boolean hasSource(); + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested withNewSource(); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested withNewSourceLike(io.kubernetes.client.openapi.models.V1EventSource item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested withNewSourceLike( + io.kubernetes.client.openapi.models.V1EventSource item); + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested editSource(); + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested editOrNewSource(); - public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested editOrNewSourceLike(io.kubernetes.client.openapi.models.V1EventSource item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested editOrNewSourceLike( + io.kubernetes.client.openapi.models.V1EventSource item); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface InvolvedObjectNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface InvolvedObjectNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested> { public N and(); + public N endInvolvedObject(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface RelatedNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface RelatedNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested> { public N and(); + public N endRelated(); - } - public interface SeriesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent>{ + + public interface SeriesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent< + io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested> { public N and(); + public N endSeries(); - } - public interface SourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EventSourceFluent>{ + + public interface SourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EventSourceFluent< + io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested> { public N and(); + public N endSource(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventFluentImpl.java index 13fe68ac97..4015308879 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventFluentImpl.java @@ -1,20 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.lang.Object; - - /** - * Generated - */ -public class CoreV1EventFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.CoreV1EventFluent{ - public CoreV1EventFluentImpl() { - } +/** Generated */ +public class CoreV1EventFluentImpl< + A extends io.kubernetes.client.openapi.models.CoreV1EventFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.CoreV1EventFluent { + public CoreV1EventFluentImpl() {} + public CoreV1EventFluentImpl(io.kubernetes.client.openapi.models.CoreV1Event instance) { this.withAction(instance.getAction()); @@ -49,8 +53,8 @@ public CoreV1EventFluentImpl(io.kubernetes.client.openapi.models.CoreV1Event ins this.withSource(instance.getSource()); this.withType(instance.getType()); - } + private java.lang.String action; private java.lang.String apiVersion; private java.lang.Integer count; @@ -68,453 +72,653 @@ public CoreV1EventFluentImpl(io.kubernetes.client.openapi.models.CoreV1Event ins private io.kubernetes.client.openapi.models.CoreV1EventSeriesBuilder series; private io.kubernetes.client.openapi.models.V1EventSourceBuilder source; private java.lang.String type; + public java.lang.String getAction() { return this.action; } + public A withAction(java.lang.String action) { - this.action=action; return (A) this; + this.action = action; + return (A) this; } + public java.lang.Boolean hasAction() { return this.action != null; } - - /** - * Method is deprecated. use withAction instead. - */ + + /** Method is deprecated. use withAction instead. */ @java.lang.Deprecated public A withNewAction(java.lang.String original) { - return (A)withAction(new String(original)); + return (A) withAction(new String(original)); } + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.Integer getCount() { return this.count; } + public A withCount(java.lang.Integer count) { - this.count=count; return (A) this; + this.count = count; + return (A) this; } + public java.lang.Boolean hasCount() { return this.count != null; } + public java.time.OffsetDateTime getEventTime() { return this.eventTime; } + public A withEventTime(java.time.OffsetDateTime eventTime) { - this.eventTime=eventTime; return (A) this; + this.eventTime = eventTime; + return (A) this; } + public java.lang.Boolean hasEventTime() { return this.eventTime != null; } + public java.time.OffsetDateTime getFirstTimestamp() { return this.firstTimestamp; } + public A withFirstTimestamp(java.time.OffsetDateTime firstTimestamp) { - this.firstTimestamp=firstTimestamp; return (A) this; + this.firstTimestamp = firstTimestamp; + return (A) this; } + public java.lang.Boolean hasFirstTimestamp() { return this.firstTimestamp != null; } - + /** * This method has been deprecated, please use method buildInvolvedObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getInvolvedObject() { - return this.involvedObject!=null ?this.involvedObject.build():null; + return this.involvedObject != null ? this.involvedObject.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectReference buildInvolvedObject() { - return this.involvedObject!=null ?this.involvedObject.build():null; + return this.involvedObject != null ? this.involvedObject.build() : null; } - public A withInvolvedObject(io.kubernetes.client.openapi.models.V1ObjectReference involvedObject) { + + public A withInvolvedObject( + io.kubernetes.client.openapi.models.V1ObjectReference involvedObject) { _visitables.get("involvedObject").remove(this.involvedObject); - if (involvedObject!=null){ this.involvedObject= new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(involvedObject); _visitables.get("involvedObject").add(this.involvedObject);} return (A) this; + if (involvedObject != null) { + this.involvedObject = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(involvedObject); + _visitables.get("involvedObject").add(this.involvedObject); + } + return (A) this; } + public java.lang.Boolean hasInvolvedObject() { return this.involvedObject != null; } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested withNewInvolvedObject() { + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested + withNewInvolvedObject() { return new io.kubernetes.client.openapi.models.CoreV1EventFluentImpl.InvolvedObjectNestedImpl(); } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested withNewInvolvedObjectLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return new io.kubernetes.client.openapi.models.CoreV1EventFluentImpl.InvolvedObjectNestedImpl(item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested + withNewInvolvedObjectLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return new io.kubernetes.client.openapi.models.CoreV1EventFluentImpl.InvolvedObjectNestedImpl( + item); } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested editInvolvedObject() { + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested + editInvolvedObject() { return withNewInvolvedObjectLike(getInvolvedObject()); } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested editOrNewInvolvedObject() { - return withNewInvolvedObjectLike(getInvolvedObject() != null ? getInvolvedObject(): new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested + editOrNewInvolvedObject() { + return withNewInvolvedObjectLike( + getInvolvedObject() != null + ? getInvolvedObject() + : new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested editOrNewInvolvedObjectLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return withNewInvolvedObjectLike(getInvolvedObject() != null ? getInvolvedObject(): item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested + editOrNewInvolvedObjectLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return withNewInvolvedObjectLike(getInvolvedObject() != null ? getInvolvedObject() : item); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.time.OffsetDateTime getLastTimestamp() { return this.lastTimestamp; } + public A withLastTimestamp(java.time.OffsetDateTime lastTimestamp) { - this.lastTimestamp=lastTimestamp; return (A) this; + this.lastTimestamp = lastTimestamp; + return (A) this; } + public java.lang.Boolean hasLastTimestamp() { return this.lastTimestamp != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.CoreV1EventFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.CoreV1EventFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } - + /** * This method has been deprecated, please use method buildRelated instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getRelated() { - return this.related!=null ?this.related.build():null; + return this.related != null ? this.related.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectReference buildRelated() { - return this.related!=null ?this.related.build():null; + return this.related != null ? this.related.build() : null; } + public A withRelated(io.kubernetes.client.openapi.models.V1ObjectReference related) { _visitables.get("related").remove(this.related); - if (related!=null){ this.related= new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(related); _visitables.get("related").add(this.related);} return (A) this; + if (related != null) { + this.related = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(related); + _visitables.get("related").add(this.related); + } + return (A) this; } + public java.lang.Boolean hasRelated() { return this.related != null; } + public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested withNewRelated() { return new io.kubernetes.client.openapi.models.CoreV1EventFluentImpl.RelatedNestedImpl(); } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested withNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested withNewRelatedLike( + io.kubernetes.client.openapi.models.V1ObjectReference item) { return new io.kubernetes.client.openapi.models.CoreV1EventFluentImpl.RelatedNestedImpl(item); } + public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested editRelated() { return withNewRelatedLike(getRelated()); } + public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested editOrNewRelated() { - return withNewRelatedLike(getRelated() != null ? getRelated(): new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); + return withNewRelatedLike( + getRelated() != null + ? getRelated() + : new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested editOrNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return withNewRelatedLike(getRelated() != null ? getRelated(): item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested + editOrNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return withNewRelatedLike(getRelated() != null ? getRelated() : item); } + public java.lang.String getReportingComponent() { return this.reportingComponent; } + public A withReportingComponent(java.lang.String reportingComponent) { - this.reportingComponent=reportingComponent; return (A) this; + this.reportingComponent = reportingComponent; + return (A) this; } + public java.lang.Boolean hasReportingComponent() { return this.reportingComponent != null; } - - /** - * Method is deprecated. use withReportingComponent instead. - */ + + /** Method is deprecated. use withReportingComponent instead. */ @java.lang.Deprecated public A withNewReportingComponent(java.lang.String original) { - return (A)withReportingComponent(new String(original)); + return (A) withReportingComponent(new String(original)); } + public java.lang.String getReportingInstance() { return this.reportingInstance; } + public A withReportingInstance(java.lang.String reportingInstance) { - this.reportingInstance=reportingInstance; return (A) this; + this.reportingInstance = reportingInstance; + return (A) this; } + public java.lang.Boolean hasReportingInstance() { return this.reportingInstance != null; } - - /** - * Method is deprecated. use withReportingInstance instead. - */ + + /** Method is deprecated. use withReportingInstance instead. */ @java.lang.Deprecated public A withNewReportingInstance(java.lang.String original) { - return (A)withReportingInstance(new String(original)); + return (A) withReportingInstance(new String(original)); } - + /** * This method has been deprecated, please use method buildSeries instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.CoreV1EventSeries getSeries() { - return this.series!=null ?this.series.build():null; + return this.series != null ? this.series.build() : null; } + public io.kubernetes.client.openapi.models.CoreV1EventSeries buildSeries() { - return this.series!=null ?this.series.build():null; + return this.series != null ? this.series.build() : null; } + public A withSeries(io.kubernetes.client.openapi.models.CoreV1EventSeries series) { _visitables.get("series").remove(this.series); - if (series!=null){ this.series= new io.kubernetes.client.openapi.models.CoreV1EventSeriesBuilder(series); _visitables.get("series").add(this.series);} return (A) this; + if (series != null) { + this.series = new io.kubernetes.client.openapi.models.CoreV1EventSeriesBuilder(series); + _visitables.get("series").add(this.series); + } + return (A) this; } + public java.lang.Boolean hasSeries() { return this.series != null; } + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested withNewSeries() { return new io.kubernetes.client.openapi.models.CoreV1EventFluentImpl.SeriesNestedImpl(); } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested withNewSeriesLike(io.kubernetes.client.openapi.models.CoreV1EventSeries item) { + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested withNewSeriesLike( + io.kubernetes.client.openapi.models.CoreV1EventSeries item) { return new io.kubernetes.client.openapi.models.CoreV1EventFluentImpl.SeriesNestedImpl(item); } + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested editSeries() { return withNewSeriesLike(getSeries()); } + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested editOrNewSeries() { - return withNewSeriesLike(getSeries() != null ? getSeries(): new io.kubernetes.client.openapi.models.CoreV1EventSeriesBuilder().build()); + return withNewSeriesLike( + getSeries() != null + ? getSeries() + : new io.kubernetes.client.openapi.models.CoreV1EventSeriesBuilder().build()); } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested editOrNewSeriesLike(io.kubernetes.client.openapi.models.CoreV1EventSeries item) { - return withNewSeriesLike(getSeries() != null ? getSeries(): item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested editOrNewSeriesLike( + io.kubernetes.client.openapi.models.CoreV1EventSeries item) { + return withNewSeriesLike(getSeries() != null ? getSeries() : item); } - + /** * This method has been deprecated, please use method buildSource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EventSource getSource() { - return this.source!=null ?this.source.build():null; + return this.source != null ? this.source.build() : null; } + public io.kubernetes.client.openapi.models.V1EventSource buildSource() { - return this.source!=null ?this.source.build():null; + return this.source != null ? this.source.build() : null; } + public A withSource(io.kubernetes.client.openapi.models.V1EventSource source) { _visitables.get("source").remove(this.source); - if (source!=null){ this.source= new io.kubernetes.client.openapi.models.V1EventSourceBuilder(source); _visitables.get("source").add(this.source);} return (A) this; + if (source != null) { + this.source = new io.kubernetes.client.openapi.models.V1EventSourceBuilder(source); + _visitables.get("source").add(this.source); + } + return (A) this; } + public java.lang.Boolean hasSource() { return this.source != null; } + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested withNewSource() { return new io.kubernetes.client.openapi.models.CoreV1EventFluentImpl.SourceNestedImpl(); } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested withNewSourceLike(io.kubernetes.client.openapi.models.V1EventSource item) { + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested withNewSourceLike( + io.kubernetes.client.openapi.models.V1EventSource item) { return new io.kubernetes.client.openapi.models.CoreV1EventFluentImpl.SourceNestedImpl(item); } + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested editSource() { return withNewSourceLike(getSource()); } + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested editOrNewSource() { - return withNewSourceLike(getSource() != null ? getSource(): new io.kubernetes.client.openapi.models.V1EventSourceBuilder().build()); + return withNewSourceLike( + getSource() != null + ? getSource() + : new io.kubernetes.client.openapi.models.V1EventSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested editOrNewSourceLike(io.kubernetes.client.openapi.models.V1EventSource item) { - return withNewSourceLike(getSource() != null ? getSource(): item); + + public io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested editOrNewSourceLike( + io.kubernetes.client.openapi.models.V1EventSource item) { + return withNewSourceLike(getSource() != null ? getSource() : item); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; CoreV1EventFluentImpl that = (CoreV1EventFluentImpl) o; - if (action != null ? !action.equals(that.action) :that.action != null) return false; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (count != null ? !count.equals(that.count) :that.count != null) return false; - if (eventTime != null ? !eventTime.equals(that.eventTime) :that.eventTime != null) return false; - if (firstTimestamp != null ? !firstTimestamp.equals(that.firstTimestamp) :that.firstTimestamp != null) return false; - if (involvedObject != null ? !involvedObject.equals(that.involvedObject) :that.involvedObject != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (lastTimestamp != null ? !lastTimestamp.equals(that.lastTimestamp) :that.lastTimestamp != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (related != null ? !related.equals(that.related) :that.related != null) return false; - if (reportingComponent != null ? !reportingComponent.equals(that.reportingComponent) :that.reportingComponent != null) return false; - if (reportingInstance != null ? !reportingInstance.equals(that.reportingInstance) :that.reportingInstance != null) return false; - if (series != null ? !series.equals(that.series) :that.series != null) return false; - if (source != null ? !source.equals(that.source) :that.source != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (action != null ? !action.equals(that.action) : that.action != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (count != null ? !count.equals(that.count) : that.count != null) return false; + if (eventTime != null ? !eventTime.equals(that.eventTime) : that.eventTime != null) + return false; + if (firstTimestamp != null + ? !firstTimestamp.equals(that.firstTimestamp) + : that.firstTimestamp != null) return false; + if (involvedObject != null + ? !involvedObject.equals(that.involvedObject) + : that.involvedObject != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (lastTimestamp != null + ? !lastTimestamp.equals(that.lastTimestamp) + : that.lastTimestamp != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (related != null ? !related.equals(that.related) : that.related != null) return false; + if (reportingComponent != null + ? !reportingComponent.equals(that.reportingComponent) + : that.reportingComponent != null) return false; + if (reportingInstance != null + ? !reportingInstance.equals(that.reportingInstance) + : that.reportingInstance != null) return false; + if (series != null ? !series.equals(that.series) : that.series != null) return false; + if (source != null ? !source.equals(that.source) : that.source != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(action, apiVersion, count, eventTime, firstTimestamp, involvedObject, kind, lastTimestamp, message, metadata, reason, related, reportingComponent, reportingInstance, series, source, type, super.hashCode()); + return java.util.Objects.hash( + action, + apiVersion, + count, + eventTime, + firstTimestamp, + involvedObject, + kind, + lastTimestamp, + message, + metadata, + reason, + related, + reportingComponent, + reportingInstance, + series, + source, + type, + super.hashCode()); } - public class InvolvedObjectNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested,io.kubernetes.client.fluent.Nested{ + + public class InvolvedObjectNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested> + implements io.kubernetes.client.openapi.models.CoreV1EventFluent.InvolvedObjectNested, + io.kubernetes.client.fluent.Nested { InvolvedObjectNestedImpl(io.kubernetes.client.openapi.models.V1ObjectReference item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + InvolvedObjectNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; + public N and() { return (N) CoreV1EventFluentImpl.this.withInvolvedObject(builder.build()); } + public N endInvolvedObject() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.CoreV1EventFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) CoreV1EventFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class RelatedNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested,io.kubernetes.client.fluent.Nested{ + + public class RelatedNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested> + implements io.kubernetes.client.openapi.models.CoreV1EventFluent.RelatedNested, + io.kubernetes.client.fluent.Nested { RelatedNestedImpl(io.kubernetes.client.openapi.models.V1ObjectReference item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + RelatedNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; + public N and() { return (N) CoreV1EventFluentImpl.this.withRelated(builder.build()); } + public N endRelated() { return and(); } - } - public class SeriesNestedImpl extends io.kubernetes.client.openapi.models.CoreV1EventSeriesFluentImpl> implements io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested,io.kubernetes.client.fluent.Nested{ + + public class SeriesNestedImpl + extends io.kubernetes.client.openapi.models.CoreV1EventSeriesFluentImpl< + io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested> + implements io.kubernetes.client.openapi.models.CoreV1EventFluent.SeriesNested, + io.kubernetes.client.fluent.Nested { SeriesNestedImpl(io.kubernetes.client.openapi.models.CoreV1EventSeries item) { this.builder = new io.kubernetes.client.openapi.models.CoreV1EventSeriesBuilder(this, item); } + SeriesNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.CoreV1EventSeriesBuilder(this); } + io.kubernetes.client.openapi.models.CoreV1EventSeriesBuilder builder; + public N and() { return (N) CoreV1EventFluentImpl.this.withSeries(builder.build()); } + public N endSeries() { return and(); } - } - public class SourceNestedImpl extends io.kubernetes.client.openapi.models.V1EventSourceFluentImpl> implements io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested,io.kubernetes.client.fluent.Nested{ + + public class SourceNestedImpl + extends io.kubernetes.client.openapi.models.V1EventSourceFluentImpl< + io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested> + implements io.kubernetes.client.openapi.models.CoreV1EventFluent.SourceNested, + io.kubernetes.client.fluent.Nested { SourceNestedImpl(io.kubernetes.client.openapi.models.V1EventSource item) { this.builder = new io.kubernetes.client.openapi.models.V1EventSourceBuilder(this, item); } + SourceNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1EventSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1EventSourceBuilder builder; + public N and() { return (N) CoreV1EventFluentImpl.this.withSource(builder.build()); } + public N endSource() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventListBuilder.java index b259c0febb..2973cd34eb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class CoreV1EventListBuilder extends io.kubernetes.client.openapi.models.CoreV1EventListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class CoreV1EventListBuilder + extends io.kubernetes.client.openapi.models.CoreV1EventListFluentImpl< + io.kubernetes.client.openapi.models.CoreV1EventListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.CoreV1EventList, + io.kubernetes.client.openapi.models.CoreV1EventListBuilder> { public CoreV1EventListBuilder() { this(false); } + public CoreV1EventListBuilder(java.lang.Boolean validationEnabled) { this(new CoreV1EventList(), validationEnabled); } - public CoreV1EventListBuilder(io.kubernetes.client.openapi.models.CoreV1EventListFluent fluent) { + + public CoreV1EventListBuilder( + io.kubernetes.client.openapi.models.CoreV1EventListFluent fluent) { this(fluent, false); } - public CoreV1EventListBuilder(io.kubernetes.client.openapi.models.CoreV1EventListFluent fluent,java.lang.Boolean validationEnabled) { + + public CoreV1EventListBuilder( + io.kubernetes.client.openapi.models.CoreV1EventListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new CoreV1EventList(), validationEnabled); } - public CoreV1EventListBuilder(io.kubernetes.client.openapi.models.CoreV1EventListFluent fluent,io.kubernetes.client.openapi.models.CoreV1EventList instance) { + + public CoreV1EventListBuilder( + io.kubernetes.client.openapi.models.CoreV1EventListFluent fluent, + io.kubernetes.client.openapi.models.CoreV1EventList instance) { this(fluent, instance, false); } - public CoreV1EventListBuilder(io.kubernetes.client.openapi.models.CoreV1EventListFluent fluent,io.kubernetes.client.openapi.models.CoreV1EventList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public CoreV1EventListBuilder( + io.kubernetes.client.openapi.models.CoreV1EventListFluent fluent, + io.kubernetes.client.openapi.models.CoreV1EventList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public CoreV1EventListBuilder(io.kubernetes.client.openapi.models.CoreV1EventLis fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public CoreV1EventListBuilder(io.kubernetes.client.openapi.models.CoreV1EventList instance) { - this(instance,false); + this(instance, false); } - public CoreV1EventListBuilder(io.kubernetes.client.openapi.models.CoreV1EventList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public CoreV1EventListBuilder( + io.kubernetes.client.openapi.models.CoreV1EventList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public CoreV1EventListBuilder(io.kubernetes.client.openapi.models.CoreV1EventLis this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.CoreV1EventListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.CoreV1EventList build() { CoreV1EventList buildable = new CoreV1EventList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.CoreV1EventList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; CoreV1EventListBuilder that = (CoreV1EventListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventListFluent.java index 42c166b1e6..4a083554d6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventListFluent.java @@ -1,95 +1,153 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface CoreV1EventListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface CoreV1EventListFluent< + A extends io.kubernetes.client.openapi.models.CoreV1EventListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.CoreV1Event item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.CoreV1Event item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1Event item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1Event item); + public A addToItems(io.kubernetes.client.openapi.models.CoreV1Event... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.CoreV1Event... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.CoreV1Event buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.CoreV1Event buildFirstItem(); + public io.kubernetes.client.openapi.models.CoreV1Event buildLastItem(); - public io.kubernetes.client.openapi.models.CoreV1Event buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.CoreV1Event buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.CoreV1Event... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.CoreV1Event item); - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.CoreV1Event item); - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.CoreV1Event item); + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1Event item); + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.CoreV1EventFluent>{ + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.CoreV1EventFluent< + io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventListFluentImpl.java index 0e6fc33ffa..75b6e0bb6b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class CoreV1EventListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.CoreV1EventListFluent{ - public CoreV1EventListFluentImpl() { - } +/** Generated */ +public class CoreV1EventListFluentImpl< + A extends io.kubernetes.client.openapi.models.CoreV1EventListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.CoreV1EventListFluent { + public CoreV1EventListFluentImpl() {} + public CoreV1EventListFluentImpl(io.kubernetes.client.openapi.models.CoreV1EventList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,123 @@ public CoreV1EventListFluentImpl(io.kubernetes.client.openapi.models.CoreV1Event this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.CoreV1Event item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.CoreV1EventBuilder builder = new io.kubernetes.client.openapi.models.CoreV1EventBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1Event item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.CoreV1EventBuilder builder = + new io.kubernetes.client.openapi.models.CoreV1EventBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.CoreV1Event item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.CoreV1EventBuilder builder = new io.kubernetes.client.openapi.models.CoreV1EventBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1Event item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.CoreV1EventBuilder builder = + new io.kubernetes.client.openapi.models.CoreV1EventBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.CoreV1Event... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.CoreV1Event item : items) {io.kubernetes.client.openapi.models.CoreV1EventBuilder builder = new io.kubernetes.client.openapi.models.CoreV1EventBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.CoreV1Event item : items) { + io.kubernetes.client.openapi.models.CoreV1EventBuilder builder = + new io.kubernetes.client.openapi.models.CoreV1EventBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.CoreV1Event item : items) {io.kubernetes.client.openapi.models.CoreV1EventBuilder builder = new io.kubernetes.client.openapi.models.CoreV1EventBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.CoreV1Event item : items) { + io.kubernetes.client.openapi.models.CoreV1EventBuilder builder = + new io.kubernetes.client.openapi.models.CoreV1EventBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.CoreV1Event... items) { - for (io.kubernetes.client.openapi.models.CoreV1Event item : items) {io.kubernetes.client.openapi.models.CoreV1EventBuilder builder = new io.kubernetes.client.openapi.models.CoreV1EventBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.CoreV1Event item : items) { + io.kubernetes.client.openapi.models.CoreV1EventBuilder builder = + new io.kubernetes.client.openapi.models.CoreV1EventBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.CoreV1Event item : items) {io.kubernetes.client.openapi.models.CoreV1EventBuilder builder = new io.kubernetes.client.openapi.models.CoreV1EventBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.CoreV1Event item : items) { + io.kubernetes.client.openapi.models.CoreV1EventBuilder builder = + new io.kubernetes.client.openapi.models.CoreV1EventBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +157,274 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.CoreV1Event buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.CoreV1Event buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.CoreV1Event buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.CoreV1Event buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.CoreV1EventBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.CoreV1Event buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.CoreV1EventBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.CoreV1EventBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.CoreV1EventBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.CoreV1Event item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.CoreV1Event item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.CoreV1Event... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.CoreV1Event item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.CoreV1Event item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.CoreV1EventListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.CoreV1Event item) { - return new io.kubernetes.client.openapi.models.CoreV1EventListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.CoreV1Event item) { + return new io.kubernetes.client.openapi.models.CoreV1EventListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.CoreV1Event item) { - return new io.kubernetes.client.openapi.models.CoreV1EventListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1Event item) { + return new io.kubernetes.client.openapi.models.CoreV1EventListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.CoreV1EventListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.CoreV1EventListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.CoreV1EventListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; CoreV1EventListFluentImpl that = (CoreV1EventListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.CoreV1EventFluentImpl> implements io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.CoreV1Event item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.CoreV1EventFluentImpl< + io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.CoreV1EventListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1Event item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.CoreV1EventBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.CoreV1EventBuilder(this); } + io.kubernetes.client.openapi.models.CoreV1EventBuilder builder; java.lang.Integer index; + public N and() { - return (N) CoreV1EventListFluentImpl.this.setToItems(index,builder.build()); + return (N) CoreV1EventListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.CoreV1EventListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) CoreV1EventListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventSeriesBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventSeriesBuilder.java index 2aaa915a31..a6294c4723 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventSeriesBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventSeriesBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class CoreV1EventSeriesBuilder extends io.kubernetes.client.openapi.models.CoreV1EventSeriesFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class CoreV1EventSeriesBuilder + extends io.kubernetes.client.openapi.models.CoreV1EventSeriesFluentImpl< + io.kubernetes.client.openapi.models.CoreV1EventSeriesBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.CoreV1EventSeries, + io.kubernetes.client.openapi.models.CoreV1EventSeriesBuilder> { public CoreV1EventSeriesBuilder() { this(false); } + public CoreV1EventSeriesBuilder(java.lang.Boolean validationEnabled) { this(new CoreV1EventSeries(), validationEnabled); } - public CoreV1EventSeriesBuilder(io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent fluent) { + + public CoreV1EventSeriesBuilder( + io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent fluent) { this(fluent, false); } - public CoreV1EventSeriesBuilder(io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent fluent,java.lang.Boolean validationEnabled) { + + public CoreV1EventSeriesBuilder( + io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new CoreV1EventSeries(), validationEnabled); } - public CoreV1EventSeriesBuilder(io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent fluent,io.kubernetes.client.openapi.models.CoreV1EventSeries instance) { + + public CoreV1EventSeriesBuilder( + io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent fluent, + io.kubernetes.client.openapi.models.CoreV1EventSeries instance) { this(fluent, instance, false); } - public CoreV1EventSeriesBuilder(io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent fluent,io.kubernetes.client.openapi.models.CoreV1EventSeries instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public CoreV1EventSeriesBuilder( + io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent fluent, + io.kubernetes.client.openapi.models.CoreV1EventSeries instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCount(instance.getCount()); fluent.withLastObservedTime(instance.getLastObservedTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public CoreV1EventSeriesBuilder(io.kubernetes.client.openapi.models.CoreV1EventSeries instance) { - this(instance,false); + this(instance, false); } - public CoreV1EventSeriesBuilder(io.kubernetes.client.openapi.models.CoreV1EventSeries instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public CoreV1EventSeriesBuilder( + io.kubernetes.client.openapi.models.CoreV1EventSeries instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCount(instance.getCount()); this.withLastObservedTime(instance.getLastObservedTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.CoreV1EventSeries build() { CoreV1EventSeries buildable = new CoreV1EventSeries(); buildable.setCount(fluent.getCount()); buildable.setLastObservedTime(fluent.getLastObservedTime()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; CoreV1EventSeriesBuilder that = (CoreV1EventSeriesBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventSeriesFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventSeriesFluent.java index 8399174418..f82b95db43 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventSeriesFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventSeriesFluent.java @@ -1,21 +1,30 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface CoreV1EventSeriesFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface CoreV1EventSeriesFluent< + A extends io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getCount(); + public A withCount(java.lang.Integer count); + public java.lang.Boolean hasCount(); + public java.time.OffsetDateTime getLastObservedTime(); + public A withLastObservedTime(java.time.OffsetDateTime lastObservedTime); + public java.lang.Boolean hasLastObservedTime(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventSeriesFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventSeriesFluentImpl.java index 8013d164ba..c4aa651ba9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventSeriesFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/CoreV1EventSeriesFluentImpl.java @@ -1,53 +1,72 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class CoreV1EventSeriesFluentImpl< + A extends io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent { + public CoreV1EventSeriesFluentImpl() {} - /** - * Generated - */ -public class CoreV1EventSeriesFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.CoreV1EventSeriesFluent{ - public CoreV1EventSeriesFluentImpl() { - } - public CoreV1EventSeriesFluentImpl(io.kubernetes.client.openapi.models.CoreV1EventSeries instance) { + public CoreV1EventSeriesFluentImpl( + io.kubernetes.client.openapi.models.CoreV1EventSeries instance) { this.withCount(instance.getCount()); this.withLastObservedTime(instance.getLastObservedTime()); - } + private java.lang.Integer count; private java.time.OffsetDateTime lastObservedTime; + public java.lang.Integer getCount() { return this.count; } + public A withCount(java.lang.Integer count) { - this.count=count; return (A) this; + this.count = count; + return (A) this; } + public java.lang.Boolean hasCount() { return this.count != null; } + public java.time.OffsetDateTime getLastObservedTime() { return this.lastObservedTime; } + public A withLastObservedTime(java.time.OffsetDateTime lastObservedTime) { - this.lastObservedTime=lastObservedTime; return (A) this; + this.lastObservedTime = lastObservedTime; + return (A) this; } + public java.lang.Boolean hasLastObservedTime() { return this.lastObservedTime != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; CoreV1EventSeriesFluentImpl that = (CoreV1EventSeriesFluentImpl) o; - if (count != null ? !count.equals(that.count) :that.count != null) return false; - if (lastObservedTime != null ? !lastObservedTime.equals(that.lastObservedTime) :that.lastObservedTime != null) return false; + if (count != null ? !count.equals(that.count) : that.count != null) return false; + if (lastObservedTime != null + ? !lastObservedTime.equals(that.lastObservedTime) + : that.lastObservedTime != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(count, lastObservedTime, super.hashCode()); + return java.util.Objects.hash(count, lastObservedTime, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/DiscoveryV1EndpointPortBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/DiscoveryV1EndpointPortBuilder.java index 7f33995fbb..134ebb018a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/DiscoveryV1EndpointPortBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/DiscoveryV1EndpointPortBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class DiscoveryV1EndpointPortBuilder extends io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class DiscoveryV1EndpointPortBuilder + extends io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluentImpl< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort, + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder> { public DiscoveryV1EndpointPortBuilder() { this(false); } + public DiscoveryV1EndpointPortBuilder(java.lang.Boolean validationEnabled) { this(new DiscoveryV1EndpointPort(), validationEnabled); } - public DiscoveryV1EndpointPortBuilder(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent fluent) { + + public DiscoveryV1EndpointPortBuilder( + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent fluent) { this(fluent, false); } - public DiscoveryV1EndpointPortBuilder(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent fluent,java.lang.Boolean validationEnabled) { + + public DiscoveryV1EndpointPortBuilder( + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new DiscoveryV1EndpointPort(), validationEnabled); } - public DiscoveryV1EndpointPortBuilder(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent fluent,io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort instance) { + + public DiscoveryV1EndpointPortBuilder( + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent fluent, + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort instance) { this(fluent, instance, false); } - public DiscoveryV1EndpointPortBuilder(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent fluent,io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public DiscoveryV1EndpointPortBuilder( + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent fluent, + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAppProtocol(instance.getAppProtocol()); fluent.withName(instance.getName()); @@ -29,13 +56,18 @@ public DiscoveryV1EndpointPortBuilder(io.kubernetes.client.openapi.models.Discov fluent.withProtocol(instance.getProtocol()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public DiscoveryV1EndpointPortBuilder(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort instance) { - this(instance,false); + + public DiscoveryV1EndpointPortBuilder( + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort instance) { + this(instance, false); } - public DiscoveryV1EndpointPortBuilder(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public DiscoveryV1EndpointPortBuilder( + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAppProtocol(instance.getAppProtocol()); this.withName(instance.getName()); @@ -44,10 +76,12 @@ public DiscoveryV1EndpointPortBuilder(io.kubernetes.client.openapi.models.Discov this.withProtocol(instance.getProtocol()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort build() { DiscoveryV1EndpointPort buildable = new DiscoveryV1EndpointPort(); buildable.setAppProtocol(fluent.getAppProtocol()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort build() { buildable.setProtocol(fluent.getProtocol()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; DiscoveryV1EndpointPortBuilder that = (DiscoveryV1EndpointPortBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/DiscoveryV1EndpointPortFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/DiscoveryV1EndpointPortFluent.java index 20c0234fb7..62858a7847 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/DiscoveryV1EndpointPortFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/DiscoveryV1EndpointPortFluent.java @@ -1,45 +1,54 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface DiscoveryV1EndpointPortFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface DiscoveryV1EndpointPortFluent< + A extends io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getAppProtocol(); + public A withAppProtocol(java.lang.String appProtocol); + public java.lang.Boolean hasAppProtocol(); - - /** - * Method is deprecated. use withAppProtocol instead. - */ + + /** Method is deprecated. use withAppProtocol instead. */ @java.lang.Deprecated public A withNewAppProtocol(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Integer getPort(); + public A withPort(java.lang.Integer port); + public java.lang.Boolean hasPort(); + public java.lang.String getProtocol(); + public A withProtocol(java.lang.String protocol); + public java.lang.Boolean hasProtocol(); - - /** - * Method is deprecated. use withProtocol instead. - */ + + /** Method is deprecated. use withProtocol instead. */ @java.lang.Deprecated public A withNewProtocol(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/DiscoveryV1EndpointPortFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/DiscoveryV1EndpointPortFluentImpl.java index 74cdda3592..dbf5785bd5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/DiscoveryV1EndpointPortFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/DiscoveryV1EndpointPortFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class DiscoveryV1EndpointPortFluentImpl< + A extends io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent { + public DiscoveryV1EndpointPortFluentImpl() {} - /** - * Generated - */ -public class DiscoveryV1EndpointPortFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent{ - public DiscoveryV1EndpointPortFluentImpl() { - } - public DiscoveryV1EndpointPortFluentImpl(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort instance) { + public DiscoveryV1EndpointPortFluentImpl( + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort instance) { this.withAppProtocol(instance.getAppProtocol()); this.withName(instance.getName()); @@ -21,84 +28,96 @@ public DiscoveryV1EndpointPortFluentImpl(io.kubernetes.client.openapi.models.Dis this.withPort(instance.getPort()); this.withProtocol(instance.getProtocol()); - } + private java.lang.String appProtocol; private java.lang.String name; private java.lang.Integer port; private java.lang.String protocol; + public java.lang.String getAppProtocol() { return this.appProtocol; } + public A withAppProtocol(java.lang.String appProtocol) { - this.appProtocol=appProtocol; return (A) this; + this.appProtocol = appProtocol; + return (A) this; } + public java.lang.Boolean hasAppProtocol() { return this.appProtocol != null; } - - /** - * Method is deprecated. use withAppProtocol instead. - */ + + /** Method is deprecated. use withAppProtocol instead. */ @java.lang.Deprecated public A withNewAppProtocol(java.lang.String original) { - return (A)withAppProtocol(new String(original)); + return (A) withAppProtocol(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Integer getPort() { return this.port; } + public A withPort(java.lang.Integer port) { - this.port=port; return (A) this; + this.port = port; + return (A) this; } + public java.lang.Boolean hasPort() { return this.port != null; } + public java.lang.String getProtocol() { return this.protocol; } + public A withProtocol(java.lang.String protocol) { - this.protocol=protocol; return (A) this; + this.protocol = protocol; + return (A) this; } + public java.lang.Boolean hasProtocol() { return this.protocol != null; } - - /** - * Method is deprecated. use withProtocol instead. - */ + + /** Method is deprecated. use withProtocol instead. */ @java.lang.Deprecated public A withNewProtocol(java.lang.String original) { - return (A)withProtocol(new String(original)); + return (A) withProtocol(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; DiscoveryV1EndpointPortFluentImpl that = (DiscoveryV1EndpointPortFluentImpl) o; - if (appProtocol != null ? !appProtocol.equals(that.appProtocol) :that.appProtocol != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (port != null ? !port.equals(that.port) :that.port != null) return false; - if (protocol != null ? !protocol.equals(that.protocol) :that.protocol != null) return false; + if (appProtocol != null ? !appProtocol.equals(that.appProtocol) : that.appProtocol != null) + return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (port != null ? !port.equals(that.port) : that.port != null) return false; + if (protocol != null ? !protocol.equals(that.protocol) : that.protocol != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(appProtocol, name, port, protocol, super.hashCode()); + return java.util.Objects.hash(appProtocol, name, port, protocol, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventBuilder.java index 04e24780ed..ee9b286896 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class EventsV1EventBuilder extends io.kubernetes.client.openapi.models.EventsV1EventFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class EventsV1EventBuilder + extends io.kubernetes.client.openapi.models.EventsV1EventFluentImpl< + io.kubernetes.client.openapi.models.EventsV1EventBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.EventsV1Event, + io.kubernetes.client.openapi.models.EventsV1EventBuilder> { public EventsV1EventBuilder() { this(false); } + public EventsV1EventBuilder(java.lang.Boolean validationEnabled) { this(new EventsV1Event(), validationEnabled); } + public EventsV1EventBuilder(io.kubernetes.client.openapi.models.EventsV1EventFluent fluent) { this(fluent, false); } - public EventsV1EventBuilder(io.kubernetes.client.openapi.models.EventsV1EventFluent fluent,java.lang.Boolean validationEnabled) { + + public EventsV1EventBuilder( + io.kubernetes.client.openapi.models.EventsV1EventFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new EventsV1Event(), validationEnabled); } - public EventsV1EventBuilder(io.kubernetes.client.openapi.models.EventsV1EventFluent fluent,io.kubernetes.client.openapi.models.EventsV1Event instance) { + + public EventsV1EventBuilder( + io.kubernetes.client.openapi.models.EventsV1EventFluent fluent, + io.kubernetes.client.openapi.models.EventsV1Event instance) { this(fluent, instance, false); } - public EventsV1EventBuilder(io.kubernetes.client.openapi.models.EventsV1EventFluent fluent,io.kubernetes.client.openapi.models.EventsV1Event instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public EventsV1EventBuilder( + io.kubernetes.client.openapi.models.EventsV1EventFluent fluent, + io.kubernetes.client.openapi.models.EventsV1Event instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAction(instance.getAction()); fluent.withApiVersion(instance.getApiVersion()); @@ -55,13 +81,17 @@ public EventsV1EventBuilder(io.kubernetes.client.openapi.models.EventsV1EventFlu fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public EventsV1EventBuilder(io.kubernetes.client.openapi.models.EventsV1Event instance) { - this(instance,false); + this(instance, false); } - public EventsV1EventBuilder(io.kubernetes.client.openapi.models.EventsV1Event instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public EventsV1EventBuilder( + io.kubernetes.client.openapi.models.EventsV1Event instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAction(instance.getAction()); this.withApiVersion(instance.getApiVersion()); @@ -96,10 +126,12 @@ public EventsV1EventBuilder(io.kubernetes.client.openapi.models.EventsV1Event in this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.EventsV1EventFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.EventsV1Event build() { EventsV1Event buildable = new EventsV1Event(); buildable.setAction(fluent.getAction()); @@ -121,18 +153,23 @@ public io.kubernetes.client.openapi.models.EventsV1Event build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; EventsV1EventBuilder that = (EventsV1EventBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventFluent.java index 42b4699106..fd804c30d6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventFluent.java @@ -1,201 +1,305 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.time.OffsetDateTime; - - /** - * Generated - */ -public interface EventsV1EventFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface EventsV1EventFluent< + A extends io.kubernetes.client.openapi.models.EventsV1EventFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getAction(); + public A withAction(java.lang.String action); + public java.lang.Boolean hasAction(); - - /** - * Method is deprecated. use withAction instead. - */ + + /** Method is deprecated. use withAction instead. */ @java.lang.Deprecated public A withNewAction(java.lang.String original); + public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.Integer getDeprecatedCount(); + public A withDeprecatedCount(java.lang.Integer deprecatedCount); + public java.lang.Boolean hasDeprecatedCount(); + public java.time.OffsetDateTime getDeprecatedFirstTimestamp(); + public A withDeprecatedFirstTimestamp(java.time.OffsetDateTime deprecatedFirstTimestamp); + public java.lang.Boolean hasDeprecatedFirstTimestamp(); + public java.time.OffsetDateTime getDeprecatedLastTimestamp(); + public A withDeprecatedLastTimestamp(java.time.OffsetDateTime deprecatedLastTimestamp); + public java.lang.Boolean hasDeprecatedLastTimestamp(); - + /** * This method has been deprecated, please use method buildDeprecatedSource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EventSource getDeprecatedSource(); + public io.kubernetes.client.openapi.models.V1EventSource buildDeprecatedSource(); + public A withDeprecatedSource(io.kubernetes.client.openapi.models.V1EventSource deprecatedSource); + public java.lang.Boolean hasDeprecatedSource(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested withNewDeprecatedSource(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested withNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested editDeprecatedSource(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested editOrNewDeprecatedSource(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested editOrNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested + withNewDeprecatedSource(); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested + withNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested + editDeprecatedSource(); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested + editOrNewDeprecatedSource(); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested + editOrNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item); + public java.time.OffsetDateTime getEventTime(); + public A withEventTime(java.time.OffsetDateTime eventTime); + public java.lang.Boolean hasEventTime(); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public java.lang.String getNote(); + public A withNote(java.lang.String note); + public java.lang.Boolean hasNote(); - - /** - * Method is deprecated. use withNote instead. - */ + + /** Method is deprecated. use withNote instead. */ @java.lang.Deprecated public A withNewNote(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); - + /** * This method has been deprecated, please use method buildRegarding instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getRegarding(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildRegarding(); + public A withRegarding(io.kubernetes.client.openapi.models.V1ObjectReference regarding); + public java.lang.Boolean hasRegarding(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested withNewRegarding(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested withNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested + withNewRegarding(); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested + withNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested editRegarding(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested editOrNewRegarding(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested editOrNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested + editOrNewRegarding(); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested + editOrNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + /** * This method has been deprecated, please use method buildRelated instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getRelated(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildRelated(); + public A withRelated(io.kubernetes.client.openapi.models.V1ObjectReference related); + public java.lang.Boolean hasRelated(); + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested withNewRelated(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested withNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested + withNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested editRelated(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested editOrNewRelated(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested editOrNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested + editOrNewRelated(); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested + editOrNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + public java.lang.String getReportingController(); + public A withReportingController(java.lang.String reportingController); + public java.lang.Boolean hasReportingController(); - - /** - * Method is deprecated. use withReportingController instead. - */ + + /** Method is deprecated. use withReportingController instead. */ @java.lang.Deprecated public A withNewReportingController(java.lang.String original); + public java.lang.String getReportingInstance(); + public A withReportingInstance(java.lang.String reportingInstance); + public java.lang.Boolean hasReportingInstance(); - - /** - * Method is deprecated. use withReportingInstance instead. - */ + + /** Method is deprecated. use withReportingInstance instead. */ @java.lang.Deprecated public A withNewReportingInstance(java.lang.String original); - + /** * This method has been deprecated, please use method buildSeries instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.EventsV1EventSeries getSeries(); + public io.kubernetes.client.openapi.models.EventsV1EventSeries buildSeries(); + public A withSeries(io.kubernetes.client.openapi.models.EventsV1EventSeries series); + public java.lang.Boolean hasSeries(); + public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested withNewSeries(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested withNewSeriesLike(io.kubernetes.client.openapi.models.EventsV1EventSeries item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested withNewSeriesLike( + io.kubernetes.client.openapi.models.EventsV1EventSeries item); + public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested editSeries(); + public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested editOrNewSeries(); - public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested editOrNewSeriesLike(io.kubernetes.client.openapi.models.EventsV1EventSeries item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested + editOrNewSeriesLike(io.kubernetes.client.openapi.models.EventsV1EventSeries item); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface DeprecatedSourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EventSourceFluent>{ + + public interface DeprecatedSourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EventSourceFluent< + io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested> { public N and(); + public N endDeprecatedSource(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface RegardingNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface RegardingNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested> { public N and(); + public N endRegarding(); - } - public interface RelatedNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface RelatedNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested> { public N and(); + public N endRelated(); - } - public interface SeriesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent>{ + + public interface SeriesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent< + io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested> { public N and(); + public N endSeries(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventFluentImpl.java index 765c9658b1..b20eb325dd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventFluentImpl.java @@ -1,20 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.lang.Object; - - /** - * Generated - */ -public class EventsV1EventFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.EventsV1EventFluent{ - public EventsV1EventFluentImpl() { - } +/** Generated */ +public class EventsV1EventFluentImpl< + A extends io.kubernetes.client.openapi.models.EventsV1EventFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.EventsV1EventFluent { + public EventsV1EventFluentImpl() {} + public EventsV1EventFluentImpl(io.kubernetes.client.openapi.models.EventsV1Event instance) { this.withAction(instance.getAction()); @@ -49,8 +53,8 @@ public EventsV1EventFluentImpl(io.kubernetes.client.openapi.models.EventsV1Event this.withSeries(instance.getSeries()); this.withType(instance.getType()); - } + private java.lang.String action; private java.lang.String apiVersion; private java.lang.Integer deprecatedCount; @@ -68,453 +72,664 @@ public EventsV1EventFluentImpl(io.kubernetes.client.openapi.models.EventsV1Event private java.lang.String reportingInstance; private io.kubernetes.client.openapi.models.EventsV1EventSeriesBuilder series; private java.lang.String type; + public java.lang.String getAction() { return this.action; } + public A withAction(java.lang.String action) { - this.action=action; return (A) this; + this.action = action; + return (A) this; } + public java.lang.Boolean hasAction() { return this.action != null; } - - /** - * Method is deprecated. use withAction instead. - */ + + /** Method is deprecated. use withAction instead. */ @java.lang.Deprecated public A withNewAction(java.lang.String original) { - return (A)withAction(new String(original)); + return (A) withAction(new String(original)); } + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.Integer getDeprecatedCount() { return this.deprecatedCount; } + public A withDeprecatedCount(java.lang.Integer deprecatedCount) { - this.deprecatedCount=deprecatedCount; return (A) this; + this.deprecatedCount = deprecatedCount; + return (A) this; } + public java.lang.Boolean hasDeprecatedCount() { return this.deprecatedCount != null; } + public java.time.OffsetDateTime getDeprecatedFirstTimestamp() { return this.deprecatedFirstTimestamp; } + public A withDeprecatedFirstTimestamp(java.time.OffsetDateTime deprecatedFirstTimestamp) { - this.deprecatedFirstTimestamp=deprecatedFirstTimestamp; return (A) this; + this.deprecatedFirstTimestamp = deprecatedFirstTimestamp; + return (A) this; } + public java.lang.Boolean hasDeprecatedFirstTimestamp() { return this.deprecatedFirstTimestamp != null; } + public java.time.OffsetDateTime getDeprecatedLastTimestamp() { return this.deprecatedLastTimestamp; } + public A withDeprecatedLastTimestamp(java.time.OffsetDateTime deprecatedLastTimestamp) { - this.deprecatedLastTimestamp=deprecatedLastTimestamp; return (A) this; + this.deprecatedLastTimestamp = deprecatedLastTimestamp; + return (A) this; } + public java.lang.Boolean hasDeprecatedLastTimestamp() { return this.deprecatedLastTimestamp != null; } - + /** * This method has been deprecated, please use method buildDeprecatedSource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EventSource getDeprecatedSource() { - return this.deprecatedSource!=null ?this.deprecatedSource.build():null; + return this.deprecatedSource != null ? this.deprecatedSource.build() : null; } + public io.kubernetes.client.openapi.models.V1EventSource buildDeprecatedSource() { - return this.deprecatedSource!=null ?this.deprecatedSource.build():null; + return this.deprecatedSource != null ? this.deprecatedSource.build() : null; } - public A withDeprecatedSource(io.kubernetes.client.openapi.models.V1EventSource deprecatedSource) { + + public A withDeprecatedSource( + io.kubernetes.client.openapi.models.V1EventSource deprecatedSource) { _visitables.get("deprecatedSource").remove(this.deprecatedSource); - if (deprecatedSource!=null){ this.deprecatedSource= new io.kubernetes.client.openapi.models.V1EventSourceBuilder(deprecatedSource); _visitables.get("deprecatedSource").add(this.deprecatedSource);} return (A) this; + if (deprecatedSource != null) { + this.deprecatedSource = + new io.kubernetes.client.openapi.models.V1EventSourceBuilder(deprecatedSource); + _visitables.get("deprecatedSource").add(this.deprecatedSource); + } + return (A) this; } + public java.lang.Boolean hasDeprecatedSource() { return this.deprecatedSource != null; } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested withNewDeprecatedSource() { - return new io.kubernetes.client.openapi.models.EventsV1EventFluentImpl.DeprecatedSourceNestedImpl(); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested + withNewDeprecatedSource() { + return new io.kubernetes.client.openapi.models.EventsV1EventFluentImpl + .DeprecatedSourceNestedImpl(); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested withNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item) { - return new io.kubernetes.client.openapi.models.EventsV1EventFluentImpl.DeprecatedSourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested + withNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item) { + return new io.kubernetes.client.openapi.models.EventsV1EventFluentImpl + .DeprecatedSourceNestedImpl(item); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested editDeprecatedSource() { + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested + editDeprecatedSource() { return withNewDeprecatedSourceLike(getDeprecatedSource()); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested editOrNewDeprecatedSource() { - return withNewDeprecatedSourceLike(getDeprecatedSource() != null ? getDeprecatedSource(): new io.kubernetes.client.openapi.models.V1EventSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested + editOrNewDeprecatedSource() { + return withNewDeprecatedSourceLike( + getDeprecatedSource() != null + ? getDeprecatedSource() + : new io.kubernetes.client.openapi.models.V1EventSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested editOrNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item) { - return withNewDeprecatedSourceLike(getDeprecatedSource() != null ? getDeprecatedSource(): item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested + editOrNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item) { + return withNewDeprecatedSourceLike( + getDeprecatedSource() != null ? getDeprecatedSource() : item); } + public java.time.OffsetDateTime getEventTime() { return this.eventTime; } + public A withEventTime(java.time.OffsetDateTime eventTime) { - this.eventTime=eventTime; return (A) this; + this.eventTime = eventTime; + return (A) this; } + public java.lang.Boolean hasEventTime() { return this.eventTime != null; } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.EventsV1EventFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.EventsV1EventFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public java.lang.String getNote() { return this.note; } + public A withNote(java.lang.String note) { - this.note=note; return (A) this; + this.note = note; + return (A) this; } + public java.lang.Boolean hasNote() { return this.note != null; } - - /** - * Method is deprecated. use withNote instead. - */ + + /** Method is deprecated. use withNote instead. */ @java.lang.Deprecated public A withNewNote(java.lang.String original) { - return (A)withNote(new String(original)); + return (A) withNote(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } - + /** * This method has been deprecated, please use method buildRegarding instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getRegarding() { - return this.regarding!=null ?this.regarding.build():null; + return this.regarding != null ? this.regarding.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectReference buildRegarding() { - return this.regarding!=null ?this.regarding.build():null; + return this.regarding != null ? this.regarding.build() : null; } + public A withRegarding(io.kubernetes.client.openapi.models.V1ObjectReference regarding) { _visitables.get("regarding").remove(this.regarding); - if (regarding!=null){ this.regarding= new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(regarding); _visitables.get("regarding").add(this.regarding);} return (A) this; + if (regarding != null) { + this.regarding = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(regarding); + _visitables.get("regarding").add(this.regarding); + } + return (A) this; } + public java.lang.Boolean hasRegarding() { return this.regarding != null; } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested withNewRegarding() { + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested + withNewRegarding() { return new io.kubernetes.client.openapi.models.EventsV1EventFluentImpl.RegardingNestedImpl(); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested withNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return new io.kubernetes.client.openapi.models.EventsV1EventFluentImpl.RegardingNestedImpl(item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested + withNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return new io.kubernetes.client.openapi.models.EventsV1EventFluentImpl.RegardingNestedImpl( + item); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested editRegarding() { + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested + editRegarding() { return withNewRegardingLike(getRegarding()); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested editOrNewRegarding() { - return withNewRegardingLike(getRegarding() != null ? getRegarding(): new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested + editOrNewRegarding() { + return withNewRegardingLike( + getRegarding() != null + ? getRegarding() + : new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested editOrNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return withNewRegardingLike(getRegarding() != null ? getRegarding(): item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested + editOrNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return withNewRegardingLike(getRegarding() != null ? getRegarding() : item); } - + /** * This method has been deprecated, please use method buildRelated instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getRelated() { - return this.related!=null ?this.related.build():null; + return this.related != null ? this.related.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectReference buildRelated() { - return this.related!=null ?this.related.build():null; + return this.related != null ? this.related.build() : null; } + public A withRelated(io.kubernetes.client.openapi.models.V1ObjectReference related) { _visitables.get("related").remove(this.related); - if (related!=null){ this.related= new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(related); _visitables.get("related").add(this.related);} return (A) this; + if (related != null) { + this.related = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(related); + _visitables.get("related").add(this.related); + } + return (A) this; } + public java.lang.Boolean hasRelated() { return this.related != null; } + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested withNewRelated() { return new io.kubernetes.client.openapi.models.EventsV1EventFluentImpl.RelatedNestedImpl(); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested withNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested + withNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { return new io.kubernetes.client.openapi.models.EventsV1EventFluentImpl.RelatedNestedImpl(item); } + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested editRelated() { return withNewRelatedLike(getRelated()); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested editOrNewRelated() { - return withNewRelatedLike(getRelated() != null ? getRelated(): new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested + editOrNewRelated() { + return withNewRelatedLike( + getRelated() != null + ? getRelated() + : new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested editOrNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return withNewRelatedLike(getRelated() != null ? getRelated(): item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested + editOrNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return withNewRelatedLike(getRelated() != null ? getRelated() : item); } + public java.lang.String getReportingController() { return this.reportingController; } + public A withReportingController(java.lang.String reportingController) { - this.reportingController=reportingController; return (A) this; + this.reportingController = reportingController; + return (A) this; } + public java.lang.Boolean hasReportingController() { return this.reportingController != null; } - - /** - * Method is deprecated. use withReportingController instead. - */ + + /** Method is deprecated. use withReportingController instead. */ @java.lang.Deprecated public A withNewReportingController(java.lang.String original) { - return (A)withReportingController(new String(original)); + return (A) withReportingController(new String(original)); } + public java.lang.String getReportingInstance() { return this.reportingInstance; } + public A withReportingInstance(java.lang.String reportingInstance) { - this.reportingInstance=reportingInstance; return (A) this; + this.reportingInstance = reportingInstance; + return (A) this; } + public java.lang.Boolean hasReportingInstance() { return this.reportingInstance != null; } - - /** - * Method is deprecated. use withReportingInstance instead. - */ + + /** Method is deprecated. use withReportingInstance instead. */ @java.lang.Deprecated public A withNewReportingInstance(java.lang.String original) { - return (A)withReportingInstance(new String(original)); + return (A) withReportingInstance(new String(original)); } - + /** * This method has been deprecated, please use method buildSeries instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.EventsV1EventSeries getSeries() { - return this.series!=null ?this.series.build():null; + return this.series != null ? this.series.build() : null; } + public io.kubernetes.client.openapi.models.EventsV1EventSeries buildSeries() { - return this.series!=null ?this.series.build():null; + return this.series != null ? this.series.build() : null; } + public A withSeries(io.kubernetes.client.openapi.models.EventsV1EventSeries series) { _visitables.get("series").remove(this.series); - if (series!=null){ this.series= new io.kubernetes.client.openapi.models.EventsV1EventSeriesBuilder(series); _visitables.get("series").add(this.series);} return (A) this; + if (series != null) { + this.series = new io.kubernetes.client.openapi.models.EventsV1EventSeriesBuilder(series); + _visitables.get("series").add(this.series); + } + return (A) this; } + public java.lang.Boolean hasSeries() { return this.series != null; } + public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested withNewSeries() { return new io.kubernetes.client.openapi.models.EventsV1EventFluentImpl.SeriesNestedImpl(); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested withNewSeriesLike(io.kubernetes.client.openapi.models.EventsV1EventSeries item) { + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested withNewSeriesLike( + io.kubernetes.client.openapi.models.EventsV1EventSeries item) { return new io.kubernetes.client.openapi.models.EventsV1EventFluentImpl.SeriesNestedImpl(item); } + public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested editSeries() { return withNewSeriesLike(getSeries()); } + public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested editOrNewSeries() { - return withNewSeriesLike(getSeries() != null ? getSeries(): new io.kubernetes.client.openapi.models.EventsV1EventSeriesBuilder().build()); + return withNewSeriesLike( + getSeries() != null + ? getSeries() + : new io.kubernetes.client.openapi.models.EventsV1EventSeriesBuilder().build()); } - public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested editOrNewSeriesLike(io.kubernetes.client.openapi.models.EventsV1EventSeries item) { - return withNewSeriesLike(getSeries() != null ? getSeries(): item); + + public io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested + editOrNewSeriesLike(io.kubernetes.client.openapi.models.EventsV1EventSeries item) { + return withNewSeriesLike(getSeries() != null ? getSeries() : item); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; EventsV1EventFluentImpl that = (EventsV1EventFluentImpl) o; - if (action != null ? !action.equals(that.action) :that.action != null) return false; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (deprecatedCount != null ? !deprecatedCount.equals(that.deprecatedCount) :that.deprecatedCount != null) return false; - if (deprecatedFirstTimestamp != null ? !deprecatedFirstTimestamp.equals(that.deprecatedFirstTimestamp) :that.deprecatedFirstTimestamp != null) return false; - if (deprecatedLastTimestamp != null ? !deprecatedLastTimestamp.equals(that.deprecatedLastTimestamp) :that.deprecatedLastTimestamp != null) return false; - if (deprecatedSource != null ? !deprecatedSource.equals(that.deprecatedSource) :that.deprecatedSource != null) return false; - if (eventTime != null ? !eventTime.equals(that.eventTime) :that.eventTime != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (note != null ? !note.equals(that.note) :that.note != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (regarding != null ? !regarding.equals(that.regarding) :that.regarding != null) return false; - if (related != null ? !related.equals(that.related) :that.related != null) return false; - if (reportingController != null ? !reportingController.equals(that.reportingController) :that.reportingController != null) return false; - if (reportingInstance != null ? !reportingInstance.equals(that.reportingInstance) :that.reportingInstance != null) return false; - if (series != null ? !series.equals(that.series) :that.series != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (action != null ? !action.equals(that.action) : that.action != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (deprecatedCount != null + ? !deprecatedCount.equals(that.deprecatedCount) + : that.deprecatedCount != null) return false; + if (deprecatedFirstTimestamp != null + ? !deprecatedFirstTimestamp.equals(that.deprecatedFirstTimestamp) + : that.deprecatedFirstTimestamp != null) return false; + if (deprecatedLastTimestamp != null + ? !deprecatedLastTimestamp.equals(that.deprecatedLastTimestamp) + : that.deprecatedLastTimestamp != null) return false; + if (deprecatedSource != null + ? !deprecatedSource.equals(that.deprecatedSource) + : that.deprecatedSource != null) return false; + if (eventTime != null ? !eventTime.equals(that.eventTime) : that.eventTime != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (note != null ? !note.equals(that.note) : that.note != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (regarding != null ? !regarding.equals(that.regarding) : that.regarding != null) + return false; + if (related != null ? !related.equals(that.related) : that.related != null) return false; + if (reportingController != null + ? !reportingController.equals(that.reportingController) + : that.reportingController != null) return false; + if (reportingInstance != null + ? !reportingInstance.equals(that.reportingInstance) + : that.reportingInstance != null) return false; + if (series != null ? !series.equals(that.series) : that.series != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(action, apiVersion, deprecatedCount, deprecatedFirstTimestamp, deprecatedLastTimestamp, deprecatedSource, eventTime, kind, metadata, note, reason, regarding, related, reportingController, reportingInstance, series, type, super.hashCode()); + return java.util.Objects.hash( + action, + apiVersion, + deprecatedCount, + deprecatedFirstTimestamp, + deprecatedLastTimestamp, + deprecatedSource, + eventTime, + kind, + metadata, + note, + reason, + regarding, + related, + reportingController, + reportingInstance, + series, + type, + super.hashCode()); } - public class DeprecatedSourceNestedImpl extends io.kubernetes.client.openapi.models.V1EventSourceFluentImpl> implements io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested,io.kubernetes.client.fluent.Nested{ + + public class DeprecatedSourceNestedImpl + extends io.kubernetes.client.openapi.models.V1EventSourceFluentImpl< + io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested> + implements io.kubernetes.client.openapi.models.EventsV1EventFluent.DeprecatedSourceNested, + io.kubernetes.client.fluent.Nested { DeprecatedSourceNestedImpl(io.kubernetes.client.openapi.models.V1EventSource item) { this.builder = new io.kubernetes.client.openapi.models.V1EventSourceBuilder(this, item); } + DeprecatedSourceNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1EventSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1EventSourceBuilder builder; + public N and() { return (N) EventsV1EventFluentImpl.this.withDeprecatedSource(builder.build()); } + public N endDeprecatedSource() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.EventsV1EventFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) EventsV1EventFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class RegardingNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested,io.kubernetes.client.fluent.Nested{ + + public class RegardingNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested> + implements io.kubernetes.client.openapi.models.EventsV1EventFluent.RegardingNested, + io.kubernetes.client.fluent.Nested { RegardingNestedImpl(io.kubernetes.client.openapi.models.V1ObjectReference item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + RegardingNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; + public N and() { return (N) EventsV1EventFluentImpl.this.withRegarding(builder.build()); } + public N endRegarding() { return and(); } - } - public class RelatedNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested,io.kubernetes.client.fluent.Nested{ + + public class RelatedNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested> + implements io.kubernetes.client.openapi.models.EventsV1EventFluent.RelatedNested, + io.kubernetes.client.fluent.Nested { RelatedNestedImpl(io.kubernetes.client.openapi.models.V1ObjectReference item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + RelatedNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; + public N and() { return (N) EventsV1EventFluentImpl.this.withRelated(builder.build()); } + public N endRelated() { return and(); } - } - public class SeriesNestedImpl extends io.kubernetes.client.openapi.models.EventsV1EventSeriesFluentImpl> implements io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested,io.kubernetes.client.fluent.Nested{ + + public class SeriesNestedImpl + extends io.kubernetes.client.openapi.models.EventsV1EventSeriesFluentImpl< + io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested> + implements io.kubernetes.client.openapi.models.EventsV1EventFluent.SeriesNested, + io.kubernetes.client.fluent.Nested { SeriesNestedImpl(io.kubernetes.client.openapi.models.EventsV1EventSeries item) { this.builder = new io.kubernetes.client.openapi.models.EventsV1EventSeriesBuilder(this, item); } + SeriesNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.EventsV1EventSeriesBuilder(this); } + io.kubernetes.client.openapi.models.EventsV1EventSeriesBuilder builder; + public N and() { return (N) EventsV1EventFluentImpl.this.withSeries(builder.build()); } + public N endSeries() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventListBuilder.java index f6e47f489f..9cf5ce3c41 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class EventsV1EventListBuilder extends io.kubernetes.client.openapi.models.EventsV1EventListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class EventsV1EventListBuilder + extends io.kubernetes.client.openapi.models.EventsV1EventListFluentImpl< + io.kubernetes.client.openapi.models.EventsV1EventListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.EventsV1EventList, + io.kubernetes.client.openapi.models.EventsV1EventListBuilder> { public EventsV1EventListBuilder() { this(false); } + public EventsV1EventListBuilder(java.lang.Boolean validationEnabled) { this(new EventsV1EventList(), validationEnabled); } - public EventsV1EventListBuilder(io.kubernetes.client.openapi.models.EventsV1EventListFluent fluent) { + + public EventsV1EventListBuilder( + io.kubernetes.client.openapi.models.EventsV1EventListFluent fluent) { this(fluent, false); } - public EventsV1EventListBuilder(io.kubernetes.client.openapi.models.EventsV1EventListFluent fluent,java.lang.Boolean validationEnabled) { + + public EventsV1EventListBuilder( + io.kubernetes.client.openapi.models.EventsV1EventListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new EventsV1EventList(), validationEnabled); } - public EventsV1EventListBuilder(io.kubernetes.client.openapi.models.EventsV1EventListFluent fluent,io.kubernetes.client.openapi.models.EventsV1EventList instance) { + + public EventsV1EventListBuilder( + io.kubernetes.client.openapi.models.EventsV1EventListFluent fluent, + io.kubernetes.client.openapi.models.EventsV1EventList instance) { this(fluent, instance, false); } - public EventsV1EventListBuilder(io.kubernetes.client.openapi.models.EventsV1EventListFluent fluent,io.kubernetes.client.openapi.models.EventsV1EventList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public EventsV1EventListBuilder( + io.kubernetes.client.openapi.models.EventsV1EventListFluent fluent, + io.kubernetes.client.openapi.models.EventsV1EventList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public EventsV1EventListBuilder(io.kubernetes.client.openapi.models.EventsV1Even fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public EventsV1EventListBuilder(io.kubernetes.client.openapi.models.EventsV1EventList instance) { - this(instance,false); + this(instance, false); } - public EventsV1EventListBuilder(io.kubernetes.client.openapi.models.EventsV1EventList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public EventsV1EventListBuilder( + io.kubernetes.client.openapi.models.EventsV1EventList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public EventsV1EventListBuilder(io.kubernetes.client.openapi.models.EventsV1Even this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.EventsV1EventListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.EventsV1EventList build() { EventsV1EventList buildable = new EventsV1EventList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.EventsV1EventList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; EventsV1EventListBuilder that = (EventsV1EventListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventListFluent.java index 918fdc3cf4..fbc0d584da 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventListFluent.java @@ -1,95 +1,155 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface EventsV1EventListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface EventsV1EventListFluent< + A extends io.kubernetes.client.openapi.models.EventsV1EventListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.EventsV1Event item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.EventsV1Event item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.EventsV1Event item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.EventsV1Event item); + public A addToItems(io.kubernetes.client.openapi.models.EventsV1Event... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.EventsV1Event... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.EventsV1Event buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.EventsV1Event buildFirstItem(); + public io.kubernetes.client.openapi.models.EventsV1Event buildLastItem(); - public io.kubernetes.client.openapi.models.EventsV1Event buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.EventsV1Event buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.EventsV1Event... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.EventsV1Event item); - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.EventsV1Event item); - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.EventsV1Event item); + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.EventsV1Event item); + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.EventsV1EventFluent>{ + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.EventsV1EventFluent< + io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventListFluentImpl.java index 7e8bef63b7..5118d58f5a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class EventsV1EventListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.EventsV1EventListFluent{ - public EventsV1EventListFluentImpl() { - } - public EventsV1EventListFluentImpl(io.kubernetes.client.openapi.models.EventsV1EventList instance) { + +/** Generated */ +public class EventsV1EventListFluentImpl< + A extends io.kubernetes.client.openapi.models.EventsV1EventListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.EventsV1EventListFluent { + public EventsV1EventListFluentImpl() {} + + public EventsV1EventListFluentImpl( + io.kubernetes.client.openapi.models.EventsV1EventList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public EventsV1EventListFluentImpl(io.kubernetes.client.openapi.models.EventsV1E this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.EventsV1Event item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.EventsV1EventBuilder builder = new io.kubernetes.client.openapi.models.EventsV1EventBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.EventsV1Event item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.EventsV1EventBuilder builder = + new io.kubernetes.client.openapi.models.EventsV1EventBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.EventsV1Event item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.EventsV1EventBuilder builder = new io.kubernetes.client.openapi.models.EventsV1EventBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.EventsV1Event item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.EventsV1EventBuilder builder = + new io.kubernetes.client.openapi.models.EventsV1EventBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.EventsV1Event... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.EventsV1Event item : items) {io.kubernetes.client.openapi.models.EventsV1EventBuilder builder = new io.kubernetes.client.openapi.models.EventsV1EventBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.EventsV1Event item : items) { + io.kubernetes.client.openapi.models.EventsV1EventBuilder builder = + new io.kubernetes.client.openapi.models.EventsV1EventBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.EventsV1Event item : items) {io.kubernetes.client.openapi.models.EventsV1EventBuilder builder = new io.kubernetes.client.openapi.models.EventsV1EventBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.EventsV1Event item : items) { + io.kubernetes.client.openapi.models.EventsV1EventBuilder builder = + new io.kubernetes.client.openapi.models.EventsV1EventBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.EventsV1Event... items) { - for (io.kubernetes.client.openapi.models.EventsV1Event item : items) {io.kubernetes.client.openapi.models.EventsV1EventBuilder builder = new io.kubernetes.client.openapi.models.EventsV1EventBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.EventsV1Event item : items) { + io.kubernetes.client.openapi.models.EventsV1EventBuilder builder = + new io.kubernetes.client.openapi.models.EventsV1EventBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.EventsV1Event item : items) {io.kubernetes.client.openapi.models.EventsV1EventBuilder builder = new io.kubernetes.client.openapi.models.EventsV1EventBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.EventsV1Event item : items) { + io.kubernetes.client.openapi.models.EventsV1EventBuilder builder = + new io.kubernetes.client.openapi.models.EventsV1EventBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.EventsV1EventBuilder builder = each.next(); @@ -87,174 +159,277 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.EventsV1Event buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.EventsV1Event buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.EventsV1Event buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.EventsV1Event buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.EventsV1EventBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.EventsV1Event buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.EventsV1EventBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.EventsV1EventBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.EventsV1EventBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.EventsV1Event item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.EventsV1Event item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.EventsV1Event... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.EventsV1Event item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.EventsV1Event item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.EventsV1EventListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.EventsV1Event item) { - return new io.kubernetes.client.openapi.models.EventsV1EventListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.EventsV1Event item) { + return new io.kubernetes.client.openapi.models.EventsV1EventListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.EventsV1Event item) { - return new io.kubernetes.client.openapi.models.EventsV1EventListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.EventsV1Event item) { + return new io.kubernetes.client.openapi.models.EventsV1EventListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.EventsV1EventListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.EventsV1EventListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.EventsV1EventListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; EventsV1EventListFluentImpl that = (EventsV1EventListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.EventsV1EventFluentImpl> implements io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.EventsV1Event item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.EventsV1EventFluentImpl< + io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.EventsV1EventListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.EventsV1Event item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.EventsV1EventBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.EventsV1EventBuilder(this); } + io.kubernetes.client.openapi.models.EventsV1EventBuilder builder; java.lang.Integer index; + public N and() { - return (N) EventsV1EventListFluentImpl.this.setToItems(index,builder.build()); + return (N) EventsV1EventListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.EventsV1EventListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) EventsV1EventListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventSeriesBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventSeriesBuilder.java index 0359fcd6a9..5af6e02e7b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventSeriesBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventSeriesBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class EventsV1EventSeriesBuilder extends io.kubernetes.client.openapi.models.EventsV1EventSeriesFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class EventsV1EventSeriesBuilder + extends io.kubernetes.client.openapi.models.EventsV1EventSeriesFluentImpl< + io.kubernetes.client.openapi.models.EventsV1EventSeriesBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.EventsV1EventSeries, + io.kubernetes.client.openapi.models.EventsV1EventSeriesBuilder> { public EventsV1EventSeriesBuilder() { this(false); } + public EventsV1EventSeriesBuilder(java.lang.Boolean validationEnabled) { this(new EventsV1EventSeries(), validationEnabled); } - public EventsV1EventSeriesBuilder(io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent fluent) { + + public EventsV1EventSeriesBuilder( + io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent fluent) { this(fluent, false); } - public EventsV1EventSeriesBuilder(io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent fluent,java.lang.Boolean validationEnabled) { + + public EventsV1EventSeriesBuilder( + io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new EventsV1EventSeries(), validationEnabled); } - public EventsV1EventSeriesBuilder(io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent fluent,io.kubernetes.client.openapi.models.EventsV1EventSeries instance) { + + public EventsV1EventSeriesBuilder( + io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent fluent, + io.kubernetes.client.openapi.models.EventsV1EventSeries instance) { this(fluent, instance, false); } - public EventsV1EventSeriesBuilder(io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent fluent,io.kubernetes.client.openapi.models.EventsV1EventSeries instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public EventsV1EventSeriesBuilder( + io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent fluent, + io.kubernetes.client.openapi.models.EventsV1EventSeries instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCount(instance.getCount()); fluent.withLastObservedTime(instance.getLastObservedTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public EventsV1EventSeriesBuilder(io.kubernetes.client.openapi.models.EventsV1EventSeries instance) { - this(instance,false); + + public EventsV1EventSeriesBuilder( + io.kubernetes.client.openapi.models.EventsV1EventSeries instance) { + this(instance, false); } - public EventsV1EventSeriesBuilder(io.kubernetes.client.openapi.models.EventsV1EventSeries instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public EventsV1EventSeriesBuilder( + io.kubernetes.client.openapi.models.EventsV1EventSeries instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCount(instance.getCount()); this.withLastObservedTime(instance.getLastObservedTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.EventsV1EventSeries build() { EventsV1EventSeries buildable = new EventsV1EventSeries(); buildable.setCount(fluent.getCount()); buildable.setLastObservedTime(fluent.getLastObservedTime()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; EventsV1EventSeriesBuilder that = (EventsV1EventSeriesBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventSeriesFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventSeriesFluent.java index 77fc0d533f..277fba19ff 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventSeriesFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventSeriesFluent.java @@ -1,21 +1,30 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface EventsV1EventSeriesFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface EventsV1EventSeriesFluent< + A extends io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getCount(); + public A withCount(java.lang.Integer count); + public java.lang.Boolean hasCount(); + public java.time.OffsetDateTime getLastObservedTime(); + public A withLastObservedTime(java.time.OffsetDateTime lastObservedTime); + public java.lang.Boolean hasLastObservedTime(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventSeriesFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventSeriesFluentImpl.java index d9f78613fa..8f38141e6a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventSeriesFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/EventsV1EventSeriesFluentImpl.java @@ -1,53 +1,72 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class EventsV1EventSeriesFluentImpl< + A extends io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent { + public EventsV1EventSeriesFluentImpl() {} - /** - * Generated - */ -public class EventsV1EventSeriesFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.EventsV1EventSeriesFluent{ - public EventsV1EventSeriesFluentImpl() { - } - public EventsV1EventSeriesFluentImpl(io.kubernetes.client.openapi.models.EventsV1EventSeries instance) { + public EventsV1EventSeriesFluentImpl( + io.kubernetes.client.openapi.models.EventsV1EventSeries instance) { this.withCount(instance.getCount()); this.withLastObservedTime(instance.getLastObservedTime()); - } + private java.lang.Integer count; private java.time.OffsetDateTime lastObservedTime; + public java.lang.Integer getCount() { return this.count; } + public A withCount(java.lang.Integer count) { - this.count=count; return (A) this; + this.count = count; + return (A) this; } + public java.lang.Boolean hasCount() { return this.count != null; } + public java.time.OffsetDateTime getLastObservedTime() { return this.lastObservedTime; } + public A withLastObservedTime(java.time.OffsetDateTime lastObservedTime) { - this.lastObservedTime=lastObservedTime; return (A) this; + this.lastObservedTime = lastObservedTime; + return (A) this; } + public java.lang.Boolean hasLastObservedTime() { return this.lastObservedTime != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; EventsV1EventSeriesFluentImpl that = (EventsV1EventSeriesFluentImpl) o; - if (count != null ? !count.equals(that.count) :that.count != null) return false; - if (lastObservedTime != null ? !lastObservedTime.equals(that.lastObservedTime) :that.lastObservedTime != null) return false; + if (count != null ? !count.equals(that.count) : that.count != null) return false; + if (lastObservedTime != null + ? !lastObservedTime.equals(that.lastObservedTime) + : that.lastObservedTime != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(count, lastObservedTime, super.hashCode()); + return java.util.Objects.hash(count, lastObservedTime, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/StorageV1TokenRequestBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/StorageV1TokenRequestBuilder.java index 110d23c521..26f0458b94 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/StorageV1TokenRequestBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/StorageV1TokenRequestBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class StorageV1TokenRequestBuilder extends io.kubernetes.client.openapi.models.StorageV1TokenRequestFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class StorageV1TokenRequestBuilder + extends io.kubernetes.client.openapi.models.StorageV1TokenRequestFluentImpl< + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.StorageV1TokenRequest, + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder> { public StorageV1TokenRequestBuilder() { this(false); } + public StorageV1TokenRequestBuilder(java.lang.Boolean validationEnabled) { this(new StorageV1TokenRequest(), validationEnabled); } - public StorageV1TokenRequestBuilder(io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent fluent) { + + public StorageV1TokenRequestBuilder( + io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent fluent) { this(fluent, false); } - public StorageV1TokenRequestBuilder(io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent fluent,java.lang.Boolean validationEnabled) { + + public StorageV1TokenRequestBuilder( + io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new StorageV1TokenRequest(), validationEnabled); } - public StorageV1TokenRequestBuilder(io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent fluent,io.kubernetes.client.openapi.models.StorageV1TokenRequest instance) { + + public StorageV1TokenRequestBuilder( + io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent fluent, + io.kubernetes.client.openapi.models.StorageV1TokenRequest instance) { this(fluent, instance, false); } - public StorageV1TokenRequestBuilder(io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent fluent,io.kubernetes.client.openapi.models.StorageV1TokenRequest instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public StorageV1TokenRequestBuilder( + io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent fluent, + io.kubernetes.client.openapi.models.StorageV1TokenRequest instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAudience(instance.getAudience()); fluent.withExpirationSeconds(instance.getExpirationSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public StorageV1TokenRequestBuilder(io.kubernetes.client.openapi.models.StorageV1TokenRequest instance) { - this(instance,false); + + public StorageV1TokenRequestBuilder( + io.kubernetes.client.openapi.models.StorageV1TokenRequest instance) { + this(instance, false); } - public StorageV1TokenRequestBuilder(io.kubernetes.client.openapi.models.StorageV1TokenRequest instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public StorageV1TokenRequestBuilder( + io.kubernetes.client.openapi.models.StorageV1TokenRequest instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAudience(instance.getAudience()); this.withExpirationSeconds(instance.getExpirationSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.StorageV1TokenRequest build() { StorageV1TokenRequest buildable = new StorageV1TokenRequest(); buildable.setAudience(fluent.getAudience()); buildable.setExpirationSeconds(fluent.getExpirationSeconds()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; StorageV1TokenRequestBuilder that = (StorageV1TokenRequestBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/StorageV1TokenRequestFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/StorageV1TokenRequestFluent.java index d190355d1f..6e8bd0ea08 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/StorageV1TokenRequestFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/StorageV1TokenRequestFluent.java @@ -1,27 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Long; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface StorageV1TokenRequestFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface StorageV1TokenRequestFluent< + A extends io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getAudience(); + public A withAudience(java.lang.String audience); + public java.lang.Boolean hasAudience(); - - /** - * Method is deprecated. use withAudience instead. - */ + + /** Method is deprecated. use withAudience instead. */ @java.lang.Deprecated public A withNewAudience(java.lang.String original); + public java.lang.Long getExpirationSeconds(); + public A withExpirationSeconds(java.lang.Long expirationSeconds); + public java.lang.Boolean hasExpirationSeconds(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/StorageV1TokenRequestFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/StorageV1TokenRequestFluentImpl.java index a7dcd1aff0..6eeaad07e6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/StorageV1TokenRequestFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/StorageV1TokenRequestFluentImpl.java @@ -1,62 +1,78 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class StorageV1TokenRequestFluentImpl< + A extends io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent { + public StorageV1TokenRequestFluentImpl() {} - /** - * Generated - */ -public class StorageV1TokenRequestFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent{ - public StorageV1TokenRequestFluentImpl() { - } - public StorageV1TokenRequestFluentImpl(io.kubernetes.client.openapi.models.StorageV1TokenRequest instance) { + public StorageV1TokenRequestFluentImpl( + io.kubernetes.client.openapi.models.StorageV1TokenRequest instance) { this.withAudience(instance.getAudience()); this.withExpirationSeconds(instance.getExpirationSeconds()); - } + private java.lang.String audience; private java.lang.Long expirationSeconds; + public java.lang.String getAudience() { return this.audience; } + public A withAudience(java.lang.String audience) { - this.audience=audience; return (A) this; + this.audience = audience; + return (A) this; } + public java.lang.Boolean hasAudience() { return this.audience != null; } - - /** - * Method is deprecated. use withAudience instead. - */ + + /** Method is deprecated. use withAudience instead. */ @java.lang.Deprecated public A withNewAudience(java.lang.String original) { - return (A)withAudience(new String(original)); + return (A) withAudience(new String(original)); } + public java.lang.Long getExpirationSeconds() { return this.expirationSeconds; } + public A withExpirationSeconds(java.lang.Long expirationSeconds) { - this.expirationSeconds=expirationSeconds; return (A) this; + this.expirationSeconds = expirationSeconds; + return (A) this; } + public java.lang.Boolean hasExpirationSeconds() { return this.expirationSeconds != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; StorageV1TokenRequestFluentImpl that = (StorageV1TokenRequestFluentImpl) o; - if (audience != null ? !audience.equals(that.audience) :that.audience != null) return false; - if (expirationSeconds != null ? !expirationSeconds.equals(that.expirationSeconds) :that.expirationSeconds != null) return false; + if (audience != null ? !audience.equals(that.audience) : that.audience != null) return false; + if (expirationSeconds != null + ? !expirationSeconds.equals(that.expirationSeconds) + : that.expirationSeconds != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(audience, expirationSeconds, super.hashCode()); + return java.util.Objects.hash(audience, expirationSeconds, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupBuilder.java index 5303faff45..8bfbd23e36 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1APIGroupBuilder extends io.kubernetes.client.openapi.models.V1APIGroupFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1APIGroupBuilder + extends io.kubernetes.client.openapi.models.V1APIGroupFluentImpl< + io.kubernetes.client.openapi.models.V1APIGroupBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1APIGroup, + io.kubernetes.client.openapi.models.V1APIGroupBuilder> { public V1APIGroupBuilder() { this(false); } + public V1APIGroupBuilder(java.lang.Boolean validationEnabled) { this(new V1APIGroup(), validationEnabled); } + public V1APIGroupBuilder(io.kubernetes.client.openapi.models.V1APIGroupFluent fluent) { this(fluent, false); } - public V1APIGroupBuilder(io.kubernetes.client.openapi.models.V1APIGroupFluent fluent,java.lang.Boolean validationEnabled) { + + public V1APIGroupBuilder( + io.kubernetes.client.openapi.models.V1APIGroupFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1APIGroup(), validationEnabled); } - public V1APIGroupBuilder(io.kubernetes.client.openapi.models.V1APIGroupFluent fluent,io.kubernetes.client.openapi.models.V1APIGroup instance) { + + public V1APIGroupBuilder( + io.kubernetes.client.openapi.models.V1APIGroupFluent fluent, + io.kubernetes.client.openapi.models.V1APIGroup instance) { this(fluent, instance, false); } - public V1APIGroupBuilder(io.kubernetes.client.openapi.models.V1APIGroupFluent fluent,io.kubernetes.client.openapi.models.V1APIGroup instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1APIGroupBuilder( + io.kubernetes.client.openapi.models.V1APIGroupFluent fluent, + io.kubernetes.client.openapi.models.V1APIGroup instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -33,13 +59,17 @@ public V1APIGroupBuilder(io.kubernetes.client.openapi.models.V1APIGroupFluent fluent.withVersions(instance.getVersions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1APIGroupBuilder(io.kubernetes.client.openapi.models.V1APIGroup instance) { - this(instance,false); + this(instance, false); } - public V1APIGroupBuilder(io.kubernetes.client.openapi.models.V1APIGroup instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1APIGroupBuilder( + io.kubernetes.client.openapi.models.V1APIGroup instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -52,10 +82,12 @@ public V1APIGroupBuilder(io.kubernetes.client.openapi.models.V1APIGroup instance this.withVersions(instance.getVersions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1APIGroupFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1APIGroup build() { V1APIGroup buildable = new V1APIGroup(); buildable.setApiVersion(fluent.getApiVersion()); @@ -66,18 +98,23 @@ public io.kubernetes.client.openapi.models.V1APIGroup build() { buildable.setVersions(fluent.getVersions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1APIGroupBuilder that = (V1APIGroupBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupFluent.java index c970d5fc1a..b61183549a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupFluent.java @@ -1,139 +1,279 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1APIGroupFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1APIGroupFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - + /** * This method has been deprecated, please use method buildPreferredVersion instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery getPreferredVersion(); + public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildPreferredVersion(); - public A withPreferredVersion(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery preferredVersion); + + public A withPreferredVersion( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery preferredVersion); + public java.lang.Boolean hasPreferredVersion(); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested withNewPreferredVersion(); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested withNewPreferredVersionLike(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested editPreferredVersion(); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested editOrNewPreferredVersion(); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested editOrNewPreferredVersionLike(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item); - public A addToServerAddressByClientCIDRs(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); - public A setToServerAddressByClientCIDRs(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); - public A addToServerAddressByClientCIDRs(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items); - public A addAllToServerAddressByClientCIDRs(java.util.Collection items); - public A removeFromServerAddressByClientCIDRs(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items); - public A removeAllFromServerAddressByClientCIDRs(java.util.Collection items); - public A removeMatchingFromServerAddressByClientCIDRs(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested + withNewPreferredVersion(); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested + withNewPreferredVersionLike( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested + editPreferredVersion(); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested + editOrNewPreferredVersion(); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested + editOrNewPreferredVersionLike( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item); + + public A addToServerAddressByClientCIDRs( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); + + public A setToServerAddressByClientCIDRs( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); + + public A addToServerAddressByClientCIDRs( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items); + + public A addAllToServerAddressByClientCIDRs( + java.util.Collection items); + + public A removeFromServerAddressByClientCIDRs( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items); + + public A removeAllFromServerAddressByClientCIDRs( + java.util.Collection items); + + public A removeMatchingFromServerAddressByClientCIDRs( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate); + /** * This method has been deprecated, please use method buildServerAddressByClientCIDRs instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getServerAddressByClientCIDRs(); - public java.util.List buildServerAddressByClientCIDRs(); - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildServerAddressByClientCIDR(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildFirstServerAddressByClientCIDR(); - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildLastServerAddressByClientCIDR(); - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildMatchingServerAddressByClientCIDR(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingServerAddressByClientCIDR(java.util.function.Predicate predicate); - public A withServerAddressByClientCIDRs(java.util.List serverAddressByClientCIDRs); - public A withServerAddressByClientCIDRs(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... serverAddressByClientCIDRs); + public java.util.List + getServerAddressByClientCIDRs(); + + public java.util.List + buildServerAddressByClientCIDRs(); + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildServerAddressByClientCIDR(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildFirstServerAddressByClientCIDR(); + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildLastServerAddressByClientCIDR(); + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildMatchingServerAddressByClientCIDR( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate); + + public java.lang.Boolean hasMatchingServerAddressByClientCIDR( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate); + + public A withServerAddressByClientCIDRs( + java.util.List + serverAddressByClientCIDRs); + + public A withServerAddressByClientCIDRs( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... + serverAddressByClientCIDRs); + public java.lang.Boolean hasServerAddressByClientCIDRs(); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested addNewServerAddressByClientCIDR(); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested addNewServerAddressByClientCIDRLike(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested setNewServerAddressByClientCIDRLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested editServerAddressByClientCIDR(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested editFirstServerAddressByClientCIDR(); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested editLastServerAddressByClientCIDR(); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested editMatchingServerAddressByClientCIDR(java.util.function.Predicate predicate); - public A addToVersions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item); - public A setToVersions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + addNewServerAddressByClientCIDR(); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + addNewServerAddressByClientCIDRLike( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + setNewServerAddressByClientCIDRLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + editServerAddressByClientCIDR(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + editFirstServerAddressByClientCIDR(); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + editLastServerAddressByClientCIDR(); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + editMatchingServerAddressByClientCIDR( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate); + + public A addToVersions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item); + + public A setToVersions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item); + public A addToVersions(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery... items); - public A addAllToVersions(java.util.Collection items); - public A removeFromVersions(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery... items); - public A removeAllFromVersions(java.util.Collection items); - public A removeMatchingFromVersions(java.util.function.Predicate predicate); - + + public A addAllToVersions( + java.util.Collection items); + + public A removeFromVersions( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery... items); + + public A removeAllFromVersions( + java.util.Collection items); + + public A removeMatchingFromVersions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder> + predicate); + /** * This method has been deprecated, please use method buildVersions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getVersions(); - public java.util.List buildVersions(); - public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildVersion(java.lang.Integer index); + public java.util.List + getVersions(); + + public java.util.List + buildVersions(); + + public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildVersion( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildFirstVersion(); + public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildLastVersion(); - public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildMatchingVersion(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVersion(java.util.function.Predicate predicate); - public A withVersions(java.util.List versions); + + public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildMatchingVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder> + predicate); + + public java.lang.Boolean hasMatchingVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder> + predicate); + + public A withVersions( + java.util.List versions); + public A withVersions(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery... versions); + public java.lang.Boolean hasVersions(); + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested addNewVersion(); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested addNewVersionLike(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested setNewVersionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested editVersion(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested addNewVersionLike( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested setNewVersionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested editVersion( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested editFirstVersion(); + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested editLastVersion(); - public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested editMatchingVersion(java.util.function.Predicate predicate); - public interface PreferredVersionNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent>{ + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested editMatchingVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder> + predicate); + + public interface PreferredVersionNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent< + io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested> { public N and(); + public N endPreferredVersion(); - } - public interface ServerAddressByClientCIDRsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent>{ + + public interface ServerAddressByClientCIDRsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent< + io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested< + N>> { public N and(); + public N endServerAddressByClientCIDR(); - } - public interface VersionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent>{ + + public interface VersionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent< + io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested> { public N and(); + public N endVersion(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupFluentImpl.java index 42f1de67ff..78ada74ec3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupFluentImpl.java @@ -1,25 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1APIGroupFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1APIGroupFluent{ - public V1APIGroupFluentImpl() { - } +/** Generated */ +public class V1APIGroupFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1APIGroupFluent { + public V1APIGroupFluentImpl() {} + public V1APIGroupFluentImpl(io.kubernetes.client.openapi.models.V1APIGroup instance) { this.withApiVersion(instance.getApiVersion()); @@ -32,127 +33,244 @@ public V1APIGroupFluentImpl(io.kubernetes.client.openapi.models.V1APIGroup insta this.withServerAddressByClientCIDRs(instance.getServerAddressByClientCIDRs()); this.withVersions(instance.getVersions()); - } + private java.lang.String apiVersion; private java.lang.String kind; private java.lang.String name; private io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder preferredVersion; - private java.util.ArrayList serverAddressByClientCIDRs; - private java.util.ArrayList versions; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + serverAddressByClientCIDRs; + private java.util.ArrayList + versions; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } - + /** * This method has been deprecated, please use method buildPreferredVersion instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery getPreferredVersion() { - return this.preferredVersion!=null ?this.preferredVersion.build():null; + return this.preferredVersion != null ? this.preferredVersion.build() : null; } + public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildPreferredVersion() { - return this.preferredVersion!=null ?this.preferredVersion.build():null; + return this.preferredVersion != null ? this.preferredVersion.build() : null; } - public A withPreferredVersion(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery preferredVersion) { + + public A withPreferredVersion( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery preferredVersion) { _visitables.get("preferredVersion").remove(this.preferredVersion); - if (preferredVersion!=null){ this.preferredVersion= new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(preferredVersion); _visitables.get("preferredVersion").add(this.preferredVersion);} return (A) this; + if (preferredVersion != null) { + this.preferredVersion = + new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder( + preferredVersion); + _visitables.get("preferredVersion").add(this.preferredVersion); + } + return (A) this; } + public java.lang.Boolean hasPreferredVersion() { return this.preferredVersion != null; } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested withNewPreferredVersion() { - return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl.PreferredVersionNestedImpl(); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested + withNewPreferredVersion() { + return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl + .PreferredVersionNestedImpl(); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested withNewPreferredVersionLike(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { - return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl.PreferredVersionNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested + withNewPreferredVersionLike( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { + return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl.PreferredVersionNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested editPreferredVersion() { + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested + editPreferredVersion() { return withNewPreferredVersionLike(getPreferredVersion()); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested editOrNewPreferredVersion() { - return withNewPreferredVersionLike(getPreferredVersion() != null ? getPreferredVersion(): new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder().build()); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested + editOrNewPreferredVersion() { + return withNewPreferredVersionLike( + getPreferredVersion() != null + ? getPreferredVersion() + : new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder().build()); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested editOrNewPreferredVersionLike(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { - return withNewPreferredVersionLike(getPreferredVersion() != null ? getPreferredVersion(): item); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested + editOrNewPreferredVersionLike( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { + return withNewPreferredVersionLike( + getPreferredVersion() != null ? getPreferredVersion() : item); } - public A addToServerAddressByClientCIDRs(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { - if (this.serverAddressByClientCIDRs == null) {this.serverAddressByClientCIDRs = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item);_visitables.get("serverAddressByClientCIDRs").add(index >= 0 ? index : _visitables.get("serverAddressByClientCIDRs").size(), builder);this.serverAddressByClientCIDRs.add(index >= 0 ? index : serverAddressByClientCIDRs.size(), builder); return (A)this; + + public A addToServerAddressByClientCIDRs( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { + if (this.serverAddressByClientCIDRs == null) { + this.serverAddressByClientCIDRs = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder>(); + } + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); + _visitables + .get("serverAddressByClientCIDRs") + .add(index >= 0 ? index : _visitables.get("serverAddressByClientCIDRs").size(), builder); + this.serverAddressByClientCIDRs.add( + index >= 0 ? index : serverAddressByClientCIDRs.size(), builder); + return (A) this; } - public A setToServerAddressByClientCIDRs(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { - if (this.serverAddressByClientCIDRs == null) {this.serverAddressByClientCIDRs = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); - if (index < 0 || index >= _visitables.get("serverAddressByClientCIDRs").size()) { _visitables.get("serverAddressByClientCIDRs").add(builder); } else { _visitables.get("serverAddressByClientCIDRs").set(index, builder);} - if (index < 0 || index >= serverAddressByClientCIDRs.size()) { serverAddressByClientCIDRs.add(builder); } else { serverAddressByClientCIDRs.set(index, builder);} - return (A)this; + + public A setToServerAddressByClientCIDRs( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { + if (this.serverAddressByClientCIDRs == null) { + this.serverAddressByClientCIDRs = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder>(); + } + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); + if (index < 0 || index >= _visitables.get("serverAddressByClientCIDRs").size()) { + _visitables.get("serverAddressByClientCIDRs").add(builder); + } else { + _visitables.get("serverAddressByClientCIDRs").set(index, builder); + } + if (index < 0 || index >= serverAddressByClientCIDRs.size()) { + serverAddressByClientCIDRs.add(builder); + } else { + serverAddressByClientCIDRs.set(index, builder); + } + return (A) this; } - public A addToServerAddressByClientCIDRs(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items) { - if (this.serverAddressByClientCIDRs == null) {this.serverAddressByClientCIDRs = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) {io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item);_visitables.get("serverAddressByClientCIDRs").add(builder);this.serverAddressByClientCIDRs.add(builder);} return (A)this; + + public A addToServerAddressByClientCIDRs( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items) { + if (this.serverAddressByClientCIDRs == null) { + this.serverAddressByClientCIDRs = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) { + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); + _visitables.get("serverAddressByClientCIDRs").add(builder); + this.serverAddressByClientCIDRs.add(builder); + } + return (A) this; } - public A addAllToServerAddressByClientCIDRs(java.util.Collection items) { - if (this.serverAddressByClientCIDRs == null) {this.serverAddressByClientCIDRs = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) {io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item);_visitables.get("serverAddressByClientCIDRs").add(builder);this.serverAddressByClientCIDRs.add(builder);} return (A)this; + + public A addAllToServerAddressByClientCIDRs( + java.util.Collection items) { + if (this.serverAddressByClientCIDRs == null) { + this.serverAddressByClientCIDRs = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) { + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); + _visitables.get("serverAddressByClientCIDRs").add(builder); + this.serverAddressByClientCIDRs.add(builder); + } + return (A) this; } - public A removeFromServerAddressByClientCIDRs(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items) { - for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) {io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item);_visitables.get("serverAddressByClientCIDRs").remove(builder);if (this.serverAddressByClientCIDRs != null) {this.serverAddressByClientCIDRs.remove(builder);}} return (A)this; + + public A removeFromServerAddressByClientCIDRs( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items) { + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) { + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); + _visitables.get("serverAddressByClientCIDRs").remove(builder); + if (this.serverAddressByClientCIDRs != null) { + this.serverAddressByClientCIDRs.remove(builder); + } + } + return (A) this; } - public A removeAllFromServerAddressByClientCIDRs(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) {io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item);_visitables.get("serverAddressByClientCIDRs").remove(builder);if (this.serverAddressByClientCIDRs != null) {this.serverAddressByClientCIDRs.remove(builder);}} return (A)this; + + public A removeAllFromServerAddressByClientCIDRs( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) { + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); + _visitables.get("serverAddressByClientCIDRs").remove(builder); + if (this.serverAddressByClientCIDRs != null) { + this.serverAddressByClientCIDRs.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromServerAddressByClientCIDRs(java.util.function.Predicate predicate) { + + public A removeMatchingFromServerAddressByClientCIDRs( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate) { if (serverAddressByClientCIDRs == null) return (A) this; - final Iterator each = serverAddressByClientCIDRs.iterator(); + final Iterator each = + serverAddressByClientCIDRs.iterator(); final List visitables = _visitables.get("serverAddressByClientCIDRs"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = each.next(); @@ -161,104 +279,268 @@ public A removeMatchingFromServerAddressByClientCIDRs(java.util.function.Predica each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildServerAddressByClientCIDRs instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getServerAddressByClientCIDRs() { + public java.util.List + getServerAddressByClientCIDRs() { return serverAddressByClientCIDRs != null ? build(serverAddressByClientCIDRs) : null; } - public java.util.List buildServerAddressByClientCIDRs() { + + public java.util.List + buildServerAddressByClientCIDRs() { return serverAddressByClientCIDRs != null ? build(serverAddressByClientCIDRs) : null; } - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildServerAddressByClientCIDR(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildServerAddressByClientCIDR(java.lang.Integer index) { return this.serverAddressByClientCIDRs.get(index).build(); } - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildFirstServerAddressByClientCIDR() { + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildFirstServerAddressByClientCIDR() { return this.serverAddressByClientCIDRs.get(0).build(); } - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildLastServerAddressByClientCIDR() { + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildLastServerAddressByClientCIDR() { return this.serverAddressByClientCIDRs.get(serverAddressByClientCIDRs.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildMatchingServerAddressByClientCIDR(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder item: serverAddressByClientCIDRs) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildMatchingServerAddressByClientCIDR( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder item : + serverAddressByClientCIDRs) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingServerAddressByClientCIDR(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder item: serverAddressByClientCIDRs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingServerAddressByClientCIDR( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder item : + serverAddressByClientCIDRs) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withServerAddressByClientCIDRs(java.util.List serverAddressByClientCIDRs) { - if (this.serverAddressByClientCIDRs != null) { _visitables.get("serverAddressByClientCIDRs").removeAll(this.serverAddressByClientCIDRs);} - if (serverAddressByClientCIDRs != null) {this.serverAddressByClientCIDRs = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : serverAddressByClientCIDRs){this.addToServerAddressByClientCIDRs(item);}} else { this.serverAddressByClientCIDRs = null;} return (A) this; + + public A withServerAddressByClientCIDRs( + java.util.List + serverAddressByClientCIDRs) { + if (this.serverAddressByClientCIDRs != null) { + _visitables.get("serverAddressByClientCIDRs").removeAll(this.serverAddressByClientCIDRs); + } + if (serverAddressByClientCIDRs != null) { + this.serverAddressByClientCIDRs = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : + serverAddressByClientCIDRs) { + this.addToServerAddressByClientCIDRs(item); + } + } else { + this.serverAddressByClientCIDRs = null; + } + return (A) this; } - public A withServerAddressByClientCIDRs(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... serverAddressByClientCIDRs) { - if (this.serverAddressByClientCIDRs != null) {this.serverAddressByClientCIDRs.clear();} - if (serverAddressByClientCIDRs != null) {for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item :serverAddressByClientCIDRs){ this.addToServerAddressByClientCIDRs(item);}} return (A) this; + + public A withServerAddressByClientCIDRs( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... + serverAddressByClientCIDRs) { + if (this.serverAddressByClientCIDRs != null) { + this.serverAddressByClientCIDRs.clear(); + } + if (serverAddressByClientCIDRs != null) { + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : + serverAddressByClientCIDRs) { + this.addToServerAddressByClientCIDRs(item); + } + } + return (A) this; } + public java.lang.Boolean hasServerAddressByClientCIDRs() { return serverAddressByClientCIDRs != null && !serverAddressByClientCIDRs.isEmpty(); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested addNewServerAddressByClientCIDR() { - return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl.ServerAddressByClientCIDRsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + addNewServerAddressByClientCIDR() { + return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl + .ServerAddressByClientCIDRsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested addNewServerAddressByClientCIDRLike(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { - return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl.ServerAddressByClientCIDRsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + addNewServerAddressByClientCIDRLike( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { + return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl + .ServerAddressByClientCIDRsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested setNewServerAddressByClientCIDRLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { - return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl.ServerAddressByClientCIDRsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + setNewServerAddressByClientCIDRLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { + return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl + .ServerAddressByClientCIDRsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested editServerAddressByClientCIDR(java.lang.Integer index) { - if (serverAddressByClientCIDRs.size() <= index) throw new RuntimeException("Can't edit serverAddressByClientCIDRs. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + editServerAddressByClientCIDR(java.lang.Integer index) { + if (serverAddressByClientCIDRs.size() <= index) + throw new RuntimeException("Can't edit serverAddressByClientCIDRs. Index exceeds size."); return setNewServerAddressByClientCIDRLike(index, buildServerAddressByClientCIDR(index)); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested editFirstServerAddressByClientCIDR() { - if (serverAddressByClientCIDRs.size() == 0) throw new RuntimeException("Can't edit first serverAddressByClientCIDRs. The list is empty."); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + editFirstServerAddressByClientCIDR() { + if (serverAddressByClientCIDRs.size() == 0) + throw new RuntimeException("Can't edit first serverAddressByClientCIDRs. The list is empty."); return setNewServerAddressByClientCIDRLike(0, buildServerAddressByClientCIDR(0)); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested editLastServerAddressByClientCIDR() { + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + editLastServerAddressByClientCIDR() { int index = serverAddressByClientCIDRs.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last serverAddressByClientCIDRs. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last serverAddressByClientCIDRs. The list is empty."); return setNewServerAddressByClientCIDRLike(index, buildServerAddressByClientCIDR(index)); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested editMatchingServerAddressByClientCIDR(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested + editMatchingServerAddressByClientCIDR( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder = new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(item);_visitables.get("versions").add(index >= 0 ? index : _visitables.get("versions").size(), builder);this.versions.add(index >= 0 ? index : versions.size(), builder); return (A)this; + + public A addToVersions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { + if (this.versions == null) { + this.versions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder>(); + } + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder = + new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(item); + _visitables + .get("versions") + .add(index >= 0 ? index : _visitables.get("versions").size(), builder); + this.versions.add(index >= 0 ? index : versions.size(), builder); + return (A) this; } - public A setToVersions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { - if (this.versions == null) {this.versions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder = new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(item); - if (index < 0 || index >= _visitables.get("versions").size()) { _visitables.get("versions").add(builder); } else { _visitables.get("versions").set(index, builder);} - if (index < 0 || index >= versions.size()) { versions.add(builder); } else { versions.set(index, builder);} - return (A)this; + + public A setToVersions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { + if (this.versions == null) { + this.versions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder>(); + } + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder = + new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(item); + if (index < 0 || index >= _visitables.get("versions").size()) { + _visitables.get("versions").add(builder); + } else { + _visitables.get("versions").set(index, builder); + } + if (index < 0 || index >= versions.size()) { + versions.add(builder); + } else { + versions.set(index, builder); + } + return (A) this; } + public A addToVersions(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery... items) { - if (this.versions == null) {this.versions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item : items) {io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder = new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(item);_visitables.get("versions").add(builder);this.versions.add(builder);} return (A)this; + if (this.versions == null) { + this.versions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item : items) { + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder = + new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(item); + _visitables.get("versions").add(builder); + this.versions.add(builder); + } + return (A) this; } - public A addAllToVersions(java.util.Collection items) { - if (this.versions == null) {this.versions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item : items) {io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder = new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(item);_visitables.get("versions").add(builder);this.versions.add(builder);} return (A)this; + + public A addAllToVersions( + java.util.Collection items) { + if (this.versions == null) { + this.versions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item : items) { + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder = + new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(item); + _visitables.get("versions").add(builder); + this.versions.add(builder); + } + return (A) this; } - public A removeFromVersions(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery... items) { - for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item : items) {io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder = new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(item);_visitables.get("versions").remove(builder);if (this.versions != null) {this.versions.remove(builder);}} return (A)this; + + public A removeFromVersions( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery... items) { + for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item : items) { + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder = + new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(item); + _visitables.get("versions").remove(builder); + if (this.versions != null) { + this.versions.remove(builder); + } + } + return (A) this; } - public A removeAllFromVersions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item : items) {io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder = new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(item);_visitables.get("versions").remove(builder);if (this.versions != null) {this.versions.remove(builder);}} return (A)this; + + public A removeAllFromVersions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item : items) { + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder = + new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(item); + _visitables.get("versions").remove(builder); + if (this.versions != null) { + this.versions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromVersions(java.util.function.Predicate predicate) { + + public A removeMatchingFromVersions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder> + predicate) { if (versions == null) return (A) this; - final Iterator each = versions.iterator(); + final Iterator each = + versions.iterator(); final List visitables = _visitables.get("versions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder = each.next(); @@ -267,144 +549,263 @@ public A removeMatchingFromVersions(java.util.function.Predicate getVersions() { + public java.util.List + getVersions() { return versions != null ? build(versions) : null; } - public java.util.List buildVersions() { + + public java.util.List + buildVersions() { return versions != null ? build(versions) : null; } - public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildVersion(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildVersion( + java.lang.Integer index) { return this.versions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildFirstVersion() { return this.versions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildLastVersion() { return this.versions.get(versions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildMatchingVersion(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder item: versions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery buildMatchingVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder item : versions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingVersion(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder item: versions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder item : versions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withVersions(java.util.List versions) { - if (this.versions != null) { _visitables.get("versions").removeAll(this.versions);} - if (versions != null) {this.versions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item : versions){this.addToVersions(item);}} else { this.versions = null;} return (A) this; + + public A withVersions( + java.util.List versions) { + if (this.versions != null) { + _visitables.get("versions").removeAll(this.versions); + } + if (versions != null) { + this.versions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item : versions) { + this.addToVersions(item); + } + } else { + this.versions = null; + } + return (A) this; } - public A withVersions(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery... versions) { - if (this.versions != null) {this.versions.clear();} - if (versions != null) {for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item :versions){ this.addToVersions(item);}} return (A) this; + + public A withVersions( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery... versions) { + if (this.versions != null) { + this.versions.clear(); + } + if (versions != null) { + for (io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item : versions) { + this.addToVersions(item); + } + } + return (A) this; } + public java.lang.Boolean hasVersions() { return versions != null && !versions.isEmpty(); } + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested addNewVersion() { return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl.VersionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested addNewVersionLike(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { - return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl.VersionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested addNewVersionLike( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { + return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl.VersionsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested setNewVersionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { - return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl.VersionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested setNewVersionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { + return new io.kubernetes.client.openapi.models.V1APIGroupFluentImpl.VersionsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested editVersion(java.lang.Integer index) { - if (versions.size() <= index) throw new RuntimeException("Can't edit versions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested editVersion( + java.lang.Integer index) { + if (versions.size() <= index) + throw new RuntimeException("Can't edit versions. Index exceeds size."); return setNewVersionLike(index, buildVersion(index)); } + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested editFirstVersion() { - if (versions.size() == 0) throw new RuntimeException("Can't edit first versions. The list is empty."); + if (versions.size() == 0) + throw new RuntimeException("Can't edit first versions. The list is empty."); return setNewVersionLike(0, buildVersion(0)); } + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested editLastVersion() { int index = versions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last versions. The list is empty."); return setNewVersionLike(index, buildVersion(index)); } - public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested editMatchingVersion(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested editMatchingVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluentImpl> implements io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested,io.kubernetes.client.fluent.Nested{ - PreferredVersionNestedImpl(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { - this.builder = new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(this, item); + + public class PreferredVersionNestedImpl + extends io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluentImpl< + io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested> + implements io.kubernetes.client.openapi.models.V1APIGroupFluent.PreferredVersionNested, + io.kubernetes.client.fluent.Nested { + PreferredVersionNestedImpl( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { + this.builder = + new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(this, item); } + PreferredVersionNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(this); } + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder; + public N and() { return (N) V1APIGroupFluentImpl.this.withPreferredVersion(builder.build()); } + public N endPreferredVersion() { return and(); } - } - public class ServerAddressByClientCIDRsNestedImpl extends io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluentImpl> implements io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested,io.kubernetes.client.fluent.Nested{ - ServerAddressByClientCIDRsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { + + public class ServerAddressByClientCIDRsNestedImpl + extends io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluentImpl< + io.kubernetes.client.openapi.models.V1APIGroupFluent.ServerAddressByClientCIDRsNested> + implements io.kubernetes.client.openapi.models.V1APIGroupFluent + .ServerAddressByClientCIDRsNested< + N>, + io.kubernetes.client.fluent.Nested { + ServerAddressByClientCIDRsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(this, item); } + ServerAddressByClientCIDRsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(this); } + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1APIGroupFluentImpl.this.setToServerAddressByClientCIDRs(index,builder.build()); + return (N) V1APIGroupFluentImpl.this.setToServerAddressByClientCIDRs(index, builder.build()); } + public N endServerAddressByClientCIDR() { return and(); } - } - public class VersionsNestedImpl extends io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluentImpl> implements io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested,io.kubernetes.client.fluent.Nested{ - VersionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { + + public class VersionsNestedImpl + extends io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluentImpl< + io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested> + implements io.kubernetes.client.openapi.models.V1APIGroupFluent.VersionsNested, + io.kubernetes.client.fluent.Nested { + VersionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(this, item); } + VersionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder(this); } + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1APIGroupFluentImpl.this.setToVersions(index,builder.build()); + return (N) V1APIGroupFluentImpl.this.setToVersions(index, builder.build()); } + public N endVersion() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupListBuilder.java index 51c3400d79..3f218b18e0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupListBuilder.java @@ -1,49 +1,81 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1APIGroupListBuilder extends io.kubernetes.client.openapi.models.V1APIGroupListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1APIGroupListBuilder + extends io.kubernetes.client.openapi.models.V1APIGroupListFluentImpl< + io.kubernetes.client.openapi.models.V1APIGroupListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1APIGroupList, + io.kubernetes.client.openapi.models.V1APIGroupListBuilder> { public V1APIGroupListBuilder() { this(false); } + public V1APIGroupListBuilder(java.lang.Boolean validationEnabled) { this(new V1APIGroupList(), validationEnabled); } + public V1APIGroupListBuilder(io.kubernetes.client.openapi.models.V1APIGroupListFluent fluent) { this(fluent, false); } - public V1APIGroupListBuilder(io.kubernetes.client.openapi.models.V1APIGroupListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1APIGroupListBuilder( + io.kubernetes.client.openapi.models.V1APIGroupListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1APIGroupList(), validationEnabled); } - public V1APIGroupListBuilder(io.kubernetes.client.openapi.models.V1APIGroupListFluent fluent,io.kubernetes.client.openapi.models.V1APIGroupList instance) { + + public V1APIGroupListBuilder( + io.kubernetes.client.openapi.models.V1APIGroupListFluent fluent, + io.kubernetes.client.openapi.models.V1APIGroupList instance) { this(fluent, instance, false); } - public V1APIGroupListBuilder(io.kubernetes.client.openapi.models.V1APIGroupListFluent fluent,io.kubernetes.client.openapi.models.V1APIGroupList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1APIGroupListBuilder( + io.kubernetes.client.openapi.models.V1APIGroupListFluent fluent, + io.kubernetes.client.openapi.models.V1APIGroupList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withGroups(instance.getGroups()); fluent.withKind(instance.getKind()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1APIGroupListBuilder(io.kubernetes.client.openapi.models.V1APIGroupList instance) { - this(instance,false); + this(instance, false); } - public V1APIGroupListBuilder(io.kubernetes.client.openapi.models.V1APIGroupList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1APIGroupListBuilder( + io.kubernetes.client.openapi.models.V1APIGroupList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withGroups(instance.getGroups()); this.withKind(instance.getKind()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1APIGroupListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1APIGroupList build() { V1APIGroupList buildable = new V1APIGroupList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -51,18 +83,23 @@ public io.kubernetes.client.openapi.models.V1APIGroupList build() { buildable.setKind(fluent.getKind()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1APIGroupListBuilder that = (V1APIGroupListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupListFluent.java index a8e5c99399..047754e7e5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupListFluent.java @@ -1,75 +1,116 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1APIGroupListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1APIGroupListFluent< + A extends io.kubernetes.client.openapi.models.V1APIGroupListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToGroups(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIGroup item); - public A setToGroups(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIGroup item); + + public A addToGroups( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIGroup item); + + public A setToGroups( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIGroup item); + public A addToGroups(io.kubernetes.client.openapi.models.V1APIGroup... items); - public A addAllToGroups(java.util.Collection items); + + public A addAllToGroups( + java.util.Collection items); + public A removeFromGroups(io.kubernetes.client.openapi.models.V1APIGroup... items); - public A removeAllFromGroups(java.util.Collection items); - public A removeMatchingFromGroups(java.util.function.Predicate predicate); - + + public A removeAllFromGroups( + java.util.Collection items); + + public A removeMatchingFromGroups( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildGroups instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getGroups(); + public java.util.List buildGroups(); + public io.kubernetes.client.openapi.models.V1APIGroup buildGroup(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1APIGroup buildFirstGroup(); + public io.kubernetes.client.openapi.models.V1APIGroup buildLastGroup(); - public io.kubernetes.client.openapi.models.V1APIGroup buildMatchingGroup(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingGroup(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1APIGroup buildMatchingGroup( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingGroup( + java.util.function.Predicate + predicate); + public A withGroups(java.util.List groups); + public A withGroups(io.kubernetes.client.openapi.models.V1APIGroup... groups); + public java.lang.Boolean hasGroups(); + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested addNewGroup(); - public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested addNewGroupLike(io.kubernetes.client.openapi.models.V1APIGroup item); - public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested setNewGroupLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIGroup item); - public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested editGroup(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested addNewGroupLike( + io.kubernetes.client.openapi.models.V1APIGroup item); + + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested setNewGroupLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIGroup item); + + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested editGroup( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested editFirstGroup(); + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested editLastGroup(); - public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested editMatchingGroup(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested editMatchingGroup( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - public interface GroupsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1APIGroupFluent>{ + + public interface GroupsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1APIGroupFluent< + io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested> { public N and(); + public N endGroup(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupListFluentImpl.java index ab11c7a745..422fa4781e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIGroupListFluentImpl.java @@ -1,79 +1,149 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1APIGroupListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1APIGroupListFluent{ - public V1APIGroupListFluentImpl() { - } +/** Generated */ +public class V1APIGroupListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1APIGroupListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1APIGroupListFluent { + public V1APIGroupListFluentImpl() {} + public V1APIGroupListFluentImpl(io.kubernetes.client.openapi.models.V1APIGroupList instance) { this.withApiVersion(instance.getApiVersion()); this.withGroups(instance.getGroups()); this.withKind(instance.getKind()); - } + private java.lang.String apiVersion; private java.util.ArrayList groups; private java.lang.String kind; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToGroups(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIGroup item) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1APIGroupBuilder builder = new io.kubernetes.client.openapi.models.V1APIGroupBuilder(item);_visitables.get("groups").add(index >= 0 ? index : _visitables.get("groups").size(), builder);this.groups.add(index >= 0 ? index : groups.size(), builder); return (A)this; + + public A addToGroups( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIGroup item) { + if (this.groups == null) { + this.groups = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1APIGroupBuilder builder = + new io.kubernetes.client.openapi.models.V1APIGroupBuilder(item); + _visitables.get("groups").add(index >= 0 ? index : _visitables.get("groups").size(), builder); + this.groups.add(index >= 0 ? index : groups.size(), builder); + return (A) this; } - public A setToGroups(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIGroup item) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1APIGroupBuilder builder = new io.kubernetes.client.openapi.models.V1APIGroupBuilder(item); - if (index < 0 || index >= _visitables.get("groups").size()) { _visitables.get("groups").add(builder); } else { _visitables.get("groups").set(index, builder);} - if (index < 0 || index >= groups.size()) { groups.add(builder); } else { groups.set(index, builder);} - return (A)this; + + public A setToGroups( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIGroup item) { + if (this.groups == null) { + this.groups = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1APIGroupBuilder builder = + new io.kubernetes.client.openapi.models.V1APIGroupBuilder(item); + if (index < 0 || index >= _visitables.get("groups").size()) { + _visitables.get("groups").add(builder); + } else { + _visitables.get("groups").set(index, builder); + } + if (index < 0 || index >= groups.size()) { + groups.add(builder); + } else { + groups.set(index, builder); + } + return (A) this; } + public A addToGroups(io.kubernetes.client.openapi.models.V1APIGroup... items) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1APIGroup item : items) {io.kubernetes.client.openapi.models.V1APIGroupBuilder builder = new io.kubernetes.client.openapi.models.V1APIGroupBuilder(item);_visitables.get("groups").add(builder);this.groups.add(builder);} return (A)this; + if (this.groups == null) { + this.groups = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1APIGroup item : items) { + io.kubernetes.client.openapi.models.V1APIGroupBuilder builder = + new io.kubernetes.client.openapi.models.V1APIGroupBuilder(item); + _visitables.get("groups").add(builder); + this.groups.add(builder); + } + return (A) this; } - public A addAllToGroups(java.util.Collection items) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1APIGroup item : items) {io.kubernetes.client.openapi.models.V1APIGroupBuilder builder = new io.kubernetes.client.openapi.models.V1APIGroupBuilder(item);_visitables.get("groups").add(builder);this.groups.add(builder);} return (A)this; + + public A addAllToGroups( + java.util.Collection items) { + if (this.groups == null) { + this.groups = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1APIGroup item : items) { + io.kubernetes.client.openapi.models.V1APIGroupBuilder builder = + new io.kubernetes.client.openapi.models.V1APIGroupBuilder(item); + _visitables.get("groups").add(builder); + this.groups.add(builder); + } + return (A) this; } + public A removeFromGroups(io.kubernetes.client.openapi.models.V1APIGroup... items) { - for (io.kubernetes.client.openapi.models.V1APIGroup item : items) {io.kubernetes.client.openapi.models.V1APIGroupBuilder builder = new io.kubernetes.client.openapi.models.V1APIGroupBuilder(item);_visitables.get("groups").remove(builder);if (this.groups != null) {this.groups.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1APIGroup item : items) { + io.kubernetes.client.openapi.models.V1APIGroupBuilder builder = + new io.kubernetes.client.openapi.models.V1APIGroupBuilder(item); + _visitables.get("groups").remove(builder); + if (this.groups != null) { + this.groups.remove(builder); + } + } + return (A) this; } - public A removeAllFromGroups(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1APIGroup item : items) {io.kubernetes.client.openapi.models.V1APIGroupBuilder builder = new io.kubernetes.client.openapi.models.V1APIGroupBuilder(item);_visitables.get("groups").remove(builder);if (this.groups != null) {this.groups.remove(builder);}} return (A)this; + + public A removeAllFromGroups( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1APIGroup item : items) { + io.kubernetes.client.openapi.models.V1APIGroupBuilder builder = + new io.kubernetes.client.openapi.models.V1APIGroupBuilder(item); + _visitables.get("groups").remove(builder); + if (this.groups != null) { + this.groups.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromGroups(java.util.function.Predicate predicate) { + + public A removeMatchingFromGroups( + java.util.function.Predicate + predicate) { if (groups == null) return (A) this; final Iterator each = groups.iterator(); final List visitables = _visitables.get("groups"); @@ -84,123 +154,195 @@ public A removeMatchingFromGroups(java.util.function.Predicate getGroups() { return groups != null ? build(groups) : null; } + public java.util.List buildGroups() { return groups != null ? build(groups) : null; } + public io.kubernetes.client.openapi.models.V1APIGroup buildGroup(java.lang.Integer index) { return this.groups.get(index).build(); } + public io.kubernetes.client.openapi.models.V1APIGroup buildFirstGroup() { return this.groups.get(0).build(); } + public io.kubernetes.client.openapi.models.V1APIGroup buildLastGroup() { return this.groups.get(groups.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1APIGroup buildMatchingGroup(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1APIGroupBuilder item: groups) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1APIGroup buildMatchingGroup( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1APIGroupBuilder item : groups) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingGroup(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1APIGroupBuilder item: groups) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingGroup( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1APIGroupBuilder item : groups) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withGroups(java.util.List groups) { - if (this.groups != null) { _visitables.get("groups").removeAll(this.groups);} - if (groups != null) {this.groups = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1APIGroup item : groups){this.addToGroups(item);}} else { this.groups = null;} return (A) this; + if (this.groups != null) { + _visitables.get("groups").removeAll(this.groups); + } + if (groups != null) { + this.groups = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1APIGroup item : groups) { + this.addToGroups(item); + } + } else { + this.groups = null; + } + return (A) this; } + public A withGroups(io.kubernetes.client.openapi.models.V1APIGroup... groups) { - if (this.groups != null) {this.groups.clear();} - if (groups != null) {for (io.kubernetes.client.openapi.models.V1APIGroup item :groups){ this.addToGroups(item);}} return (A) this; + if (this.groups != null) { + this.groups.clear(); + } + if (groups != null) { + for (io.kubernetes.client.openapi.models.V1APIGroup item : groups) { + this.addToGroups(item); + } + } + return (A) this; } + public java.lang.Boolean hasGroups() { return groups != null && !groups.isEmpty(); } + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested addNewGroup() { return new io.kubernetes.client.openapi.models.V1APIGroupListFluentImpl.GroupsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested addNewGroupLike(io.kubernetes.client.openapi.models.V1APIGroup item) { - return new io.kubernetes.client.openapi.models.V1APIGroupListFluentImpl.GroupsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested addNewGroupLike( + io.kubernetes.client.openapi.models.V1APIGroup item) { + return new io.kubernetes.client.openapi.models.V1APIGroupListFluentImpl.GroupsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested setNewGroupLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIGroup item) { - return new io.kubernetes.client.openapi.models.V1APIGroupListFluentImpl.GroupsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested setNewGroupLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIGroup item) { + return new io.kubernetes.client.openapi.models.V1APIGroupListFluentImpl.GroupsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested editGroup(java.lang.Integer index) { - if (groups.size() <= index) throw new RuntimeException("Can't edit groups. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested editGroup( + java.lang.Integer index) { + if (groups.size() <= index) + throw new RuntimeException("Can't edit groups. Index exceeds size."); return setNewGroupLike(index, buildGroup(index)); } + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested editFirstGroup() { - if (groups.size() == 0) throw new RuntimeException("Can't edit first groups. The list is empty."); + if (groups.size() == 0) + throw new RuntimeException("Can't edit first groups. The list is empty."); return setNewGroupLike(0, buildGroup(0)); } + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested editLastGroup() { int index = groups.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last groups. The list is empty."); return setNewGroupLike(index, buildGroup(index)); } - public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested editMatchingGroup(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested editMatchingGroup( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1APIGroupFluentImpl> implements io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested,io.kubernetes.client.fluent.Nested{ - GroupsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIGroup item) { + + public class GroupsNestedImpl + extends io.kubernetes.client.openapi.models.V1APIGroupFluentImpl< + io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested> + implements io.kubernetes.client.openapi.models.V1APIGroupListFluent.GroupsNested, + io.kubernetes.client.fluent.Nested { + GroupsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIGroup item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1APIGroupBuilder(this, item); } + GroupsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1APIGroupBuilder(this); } + io.kubernetes.client.openapi.models.V1APIGroupBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1APIGroupListFluentImpl.this.setToGroups(index,builder.build()); + return (N) V1APIGroupListFluentImpl.this.setToGroups(index, builder.build()); } + public N endGroup() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceBuilder.java index e559e98b44..9e83807ff2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1APIResourceBuilder extends io.kubernetes.client.openapi.models.V1APIResourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1APIResourceBuilder + extends io.kubernetes.client.openapi.models.V1APIResourceFluentImpl< + io.kubernetes.client.openapi.models.V1APIResourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1APIResource, + io.kubernetes.client.openapi.models.V1APIResourceBuilder> { public V1APIResourceBuilder() { this(false); } + public V1APIResourceBuilder(java.lang.Boolean validationEnabled) { this(new V1APIResource(), validationEnabled); } + public V1APIResourceBuilder(io.kubernetes.client.openapi.models.V1APIResourceFluent fluent) { this(fluent, false); } - public V1APIResourceBuilder(io.kubernetes.client.openapi.models.V1APIResourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1APIResourceBuilder( + io.kubernetes.client.openapi.models.V1APIResourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1APIResource(), validationEnabled); } - public V1APIResourceBuilder(io.kubernetes.client.openapi.models.V1APIResourceFluent fluent,io.kubernetes.client.openapi.models.V1APIResource instance) { + + public V1APIResourceBuilder( + io.kubernetes.client.openapi.models.V1APIResourceFluent fluent, + io.kubernetes.client.openapi.models.V1APIResource instance) { this(fluent, instance, false); } - public V1APIResourceBuilder(io.kubernetes.client.openapi.models.V1APIResourceFluent fluent,io.kubernetes.client.openapi.models.V1APIResource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1APIResourceBuilder( + io.kubernetes.client.openapi.models.V1APIResourceFluent fluent, + io.kubernetes.client.openapi.models.V1APIResource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCategories(instance.getCategories()); fluent.withGroup(instance.getGroup()); @@ -41,13 +67,17 @@ public V1APIResourceBuilder(io.kubernetes.client.openapi.models.V1APIResourceFlu fluent.withVersion(instance.getVersion()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1APIResourceBuilder(io.kubernetes.client.openapi.models.V1APIResource instance) { - this(instance,false); + this(instance, false); } - public V1APIResourceBuilder(io.kubernetes.client.openapi.models.V1APIResource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1APIResourceBuilder( + io.kubernetes.client.openapi.models.V1APIResource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCategories(instance.getCategories()); this.withGroup(instance.getGroup()); @@ -68,10 +98,12 @@ public V1APIResourceBuilder(io.kubernetes.client.openapi.models.V1APIResource in this.withVersion(instance.getVersion()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1APIResourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1APIResource build() { V1APIResource buildable = new V1APIResource(); buildable.setCategories(fluent.getCategories()); @@ -86,18 +118,23 @@ public io.kubernetes.client.openapi.models.V1APIResource build() { buildable.setVersion(fluent.getVersion()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1APIResourceBuilder that = (V1APIResourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceFluent.java index d33197fa3e..bb4677889a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceFluent.java @@ -1,124 +1,185 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1APIResourceFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToCategories(java.lang.Integer index,java.lang.String item); - public A setToCategories(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1APIResourceFluent< + A extends io.kubernetes.client.openapi.models.V1APIResourceFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToCategories(java.lang.Integer index, java.lang.String item); + + public A setToCategories(java.lang.Integer index, java.lang.String item); + public A addToCategories(java.lang.String... items); + public A addAllToCategories(java.util.Collection items); + public A removeFromCategories(java.lang.String... items); + public A removeAllFromCategories(java.util.Collection items); + public java.util.List getCategories(); + public java.lang.String getCategory(java.lang.Integer index); + public java.lang.String getFirstCategory(); + public java.lang.String getLastCategory(); - public java.lang.String getMatchingCategory(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCategory(java.util.function.Predicate predicate); + + public java.lang.String getMatchingCategory( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingCategory( + java.util.function.Predicate predicate); + public A withCategories(java.util.List categories); + public A withCategories(java.lang.String... categories); + public java.lang.Boolean hasCategories(); + public A addNewCategory(java.lang.String original); + public java.lang.String getGroup(); + public A withGroup(java.lang.String group); + public java.lang.Boolean hasGroup(); - - /** - * Method is deprecated. use withGroup instead. - */ + + /** Method is deprecated. use withGroup instead. */ @java.lang.Deprecated public A withNewGroup(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Boolean getNamespaced(); + public A withNamespaced(java.lang.Boolean namespaced); + public java.lang.Boolean hasNamespaced(); - public A addToShortNames(java.lang.Integer index,java.lang.String item); - public A setToShortNames(java.lang.Integer index,java.lang.String item); + + public A addToShortNames(java.lang.Integer index, java.lang.String item); + + public A setToShortNames(java.lang.Integer index, java.lang.String item); + public A addToShortNames(java.lang.String... items); + public A addAllToShortNames(java.util.Collection items); + public A removeFromShortNames(java.lang.String... items); + public A removeAllFromShortNames(java.util.Collection items); + public java.util.List getShortNames(); + public java.lang.String getShortName(java.lang.Integer index); + public java.lang.String getFirstShortName(); + public java.lang.String getLastShortName(); - public java.lang.String getMatchingShortName(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingShortName(java.util.function.Predicate predicate); + + public java.lang.String getMatchingShortName( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingShortName( + java.util.function.Predicate predicate); + public A withShortNames(java.util.List shortNames); + public A withShortNames(java.lang.String... shortNames); + public java.lang.Boolean hasShortNames(); + public A addNewShortName(java.lang.String original); + public java.lang.String getSingularName(); + public A withSingularName(java.lang.String singularName); + public java.lang.Boolean hasSingularName(); - - /** - * Method is deprecated. use withSingularName instead. - */ + + /** Method is deprecated. use withSingularName instead. */ @java.lang.Deprecated public A withNewSingularName(java.lang.String original); + public java.lang.String getStorageVersionHash(); + public A withStorageVersionHash(java.lang.String storageVersionHash); + public java.lang.Boolean hasStorageVersionHash(); - - /** - * Method is deprecated. use withStorageVersionHash instead. - */ + + /** Method is deprecated. use withStorageVersionHash instead. */ @java.lang.Deprecated public A withNewStorageVersionHash(java.lang.String original); - public A addToVerbs(java.lang.Integer index,java.lang.String item); - public A setToVerbs(java.lang.Integer index,java.lang.String item); + + public A addToVerbs(java.lang.Integer index, java.lang.String item); + + public A setToVerbs(java.lang.Integer index, java.lang.String item); + public A addToVerbs(java.lang.String... items); + public A addAllToVerbs(java.util.Collection items); + public A removeFromVerbs(java.lang.String... items); + public A removeAllFromVerbs(java.util.Collection items); + public java.util.List getVerbs(); + public java.lang.String getVerb(java.lang.Integer index); + public java.lang.String getFirstVerb(); + public java.lang.String getLastVerb(); + public java.lang.String getMatchingVerb(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate); + public A withVerbs(java.util.List verbs); + public A withVerbs(java.lang.String... verbs); + public java.lang.Boolean hasVerbs(); + public A addNewVerb(java.lang.String original); + public java.lang.String getVersion(); + public A withVersion(java.lang.String version); + public java.lang.Boolean hasVersion(); - - /** - * Method is deprecated. use withVersion instead. - */ + + /** Method is deprecated. use withVersion instead. */ @java.lang.Deprecated public A withNewVersion(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceFluentImpl.java index e4f9e947f4..54a8e30457 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceFluentImpl.java @@ -1,22 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1APIResourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1APIResourceFluent{ - public V1APIResourceFluentImpl() { - } +/** Generated */ +public class V1APIResourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1APIResourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1APIResourceFluent { + public V1APIResourceFluentImpl() {} + public V1APIResourceFluentImpl(io.kubernetes.client.openapi.models.V1APIResource instance) { this.withCategories(instance.getCategories()); @@ -37,8 +39,8 @@ public V1APIResourceFluentImpl(io.kubernetes.client.openapi.models.V1APIResource this.withVerbs(instance.getVerbs()); this.withVersion(instance.getVersion()); - } + private java.util.List categories; private java.lang.String group; private java.lang.String kind; @@ -49,297 +51,535 @@ public V1APIResourceFluentImpl(io.kubernetes.client.openapi.models.V1APIResource private java.lang.String storageVersionHash; private java.util.List verbs; private java.lang.String version; - public A addToCategories(java.lang.Integer index,java.lang.String item) { - if (this.categories == null) {this.categories = new java.util.ArrayList();} + + public A addToCategories(java.lang.Integer index, java.lang.String item) { + if (this.categories == null) { + this.categories = new java.util.ArrayList(); + } this.categories.add(index, item); - return (A)this; + return (A) this; } - public A setToCategories(java.lang.Integer index,java.lang.String item) { - if (this.categories == null) {this.categories = new java.util.ArrayList();} - this.categories.set(index, item); return (A)this; + + public A setToCategories(java.lang.Integer index, java.lang.String item) { + if (this.categories == null) { + this.categories = new java.util.ArrayList(); + } + this.categories.set(index, item); + return (A) this; } + public A addToCategories(java.lang.String... items) { - if (this.categories == null) {this.categories = new java.util.ArrayList();} - for (java.lang.String item : items) {this.categories.add(item);} return (A)this; + if (this.categories == null) { + this.categories = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.categories.add(item); + } + return (A) this; } + public A addAllToCategories(java.util.Collection items) { - if (this.categories == null) {this.categories = new java.util.ArrayList();} - for (java.lang.String item : items) {this.categories.add(item);} return (A)this; + if (this.categories == null) { + this.categories = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.categories.add(item); + } + return (A) this; } + public A removeFromCategories(java.lang.String... items) { - for (java.lang.String item : items) {if (this.categories!= null){ this.categories.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.categories != null) { + this.categories.remove(item); + } + } + return (A) this; } + public A removeAllFromCategories(java.util.Collection items) { - for (java.lang.String item : items) {if (this.categories!= null){ this.categories.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.categories != null) { + this.categories.remove(item); + } + } + return (A) this; } + public java.util.List getCategories() { return this.categories; } + public java.lang.String getCategory(java.lang.Integer index) { return this.categories.get(index); } + public java.lang.String getFirstCategory() { return this.categories.get(0); } + public java.lang.String getLastCategory() { return this.categories.get(categories.size() - 1); } - public java.lang.String getMatchingCategory(java.util.function.Predicate predicate) { - for (java.lang.String item: categories) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingCategory( + java.util.function.Predicate predicate) { + for (java.lang.String item : categories) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingCategory(java.util.function.Predicate predicate) { - for (java.lang.String item: categories) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCategory( + java.util.function.Predicate predicate) { + for (java.lang.String item : categories) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withCategories(java.util.List categories) { - if (categories != null) {this.categories = new java.util.ArrayList(); for (java.lang.String item : categories){this.addToCategories(item);}} else { this.categories = null;} return (A) this; + if (categories != null) { + this.categories = new java.util.ArrayList(); + for (java.lang.String item : categories) { + this.addToCategories(item); + } + } else { + this.categories = null; + } + return (A) this; } + public A withCategories(java.lang.String... categories) { - if (this.categories != null) {this.categories.clear();} - if (categories != null) {for (java.lang.String item :categories){ this.addToCategories(item);}} return (A) this; + if (this.categories != null) { + this.categories.clear(); + } + if (categories != null) { + for (java.lang.String item : categories) { + this.addToCategories(item); + } + } + return (A) this; } + public java.lang.Boolean hasCategories() { return categories != null && !categories.isEmpty(); } + public A addNewCategory(java.lang.String original) { - return (A)addToCategories(new String(original)); + return (A) addToCategories(new String(original)); } + public java.lang.String getGroup() { return this.group; } + public A withGroup(java.lang.String group) { - this.group=group; return (A) this; + this.group = group; + return (A) this; } + public java.lang.Boolean hasGroup() { return this.group != null; } - - /** - * Method is deprecated. use withGroup instead. - */ + + /** Method is deprecated. use withGroup instead. */ @java.lang.Deprecated public A withNewGroup(java.lang.String original) { - return (A)withGroup(new String(original)); + return (A) withGroup(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Boolean getNamespaced() { return this.namespaced; } + public A withNamespaced(java.lang.Boolean namespaced) { - this.namespaced=namespaced; return (A) this; + this.namespaced = namespaced; + return (A) this; } + public java.lang.Boolean hasNamespaced() { return this.namespaced != null; } - public A addToShortNames(java.lang.Integer index,java.lang.String item) { - if (this.shortNames == null) {this.shortNames = new java.util.ArrayList();} + + public A addToShortNames(java.lang.Integer index, java.lang.String item) { + if (this.shortNames == null) { + this.shortNames = new java.util.ArrayList(); + } this.shortNames.add(index, item); - return (A)this; + return (A) this; } - public A setToShortNames(java.lang.Integer index,java.lang.String item) { - if (this.shortNames == null) {this.shortNames = new java.util.ArrayList();} - this.shortNames.set(index, item); return (A)this; + + public A setToShortNames(java.lang.Integer index, java.lang.String item) { + if (this.shortNames == null) { + this.shortNames = new java.util.ArrayList(); + } + this.shortNames.set(index, item); + return (A) this; } + public A addToShortNames(java.lang.String... items) { - if (this.shortNames == null) {this.shortNames = new java.util.ArrayList();} - for (java.lang.String item : items) {this.shortNames.add(item);} return (A)this; + if (this.shortNames == null) { + this.shortNames = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.shortNames.add(item); + } + return (A) this; } + public A addAllToShortNames(java.util.Collection items) { - if (this.shortNames == null) {this.shortNames = new java.util.ArrayList();} - for (java.lang.String item : items) {this.shortNames.add(item);} return (A)this; + if (this.shortNames == null) { + this.shortNames = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.shortNames.add(item); + } + return (A) this; } + public A removeFromShortNames(java.lang.String... items) { - for (java.lang.String item : items) {if (this.shortNames!= null){ this.shortNames.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.shortNames != null) { + this.shortNames.remove(item); + } + } + return (A) this; } + public A removeAllFromShortNames(java.util.Collection items) { - for (java.lang.String item : items) {if (this.shortNames!= null){ this.shortNames.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.shortNames != null) { + this.shortNames.remove(item); + } + } + return (A) this; } + public java.util.List getShortNames() { return this.shortNames; } + public java.lang.String getShortName(java.lang.Integer index) { return this.shortNames.get(index); } + public java.lang.String getFirstShortName() { return this.shortNames.get(0); } + public java.lang.String getLastShortName() { return this.shortNames.get(shortNames.size() - 1); } - public java.lang.String getMatchingShortName(java.util.function.Predicate predicate) { - for (java.lang.String item: shortNames) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingShortName( + java.util.function.Predicate predicate) { + for (java.lang.String item : shortNames) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingShortName(java.util.function.Predicate predicate) { - for (java.lang.String item: shortNames) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingShortName( + java.util.function.Predicate predicate) { + for (java.lang.String item : shortNames) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withShortNames(java.util.List shortNames) { - if (shortNames != null) {this.shortNames = new java.util.ArrayList(); for (java.lang.String item : shortNames){this.addToShortNames(item);}} else { this.shortNames = null;} return (A) this; + if (shortNames != null) { + this.shortNames = new java.util.ArrayList(); + for (java.lang.String item : shortNames) { + this.addToShortNames(item); + } + } else { + this.shortNames = null; + } + return (A) this; } + public A withShortNames(java.lang.String... shortNames) { - if (this.shortNames != null) {this.shortNames.clear();} - if (shortNames != null) {for (java.lang.String item :shortNames){ this.addToShortNames(item);}} return (A) this; + if (this.shortNames != null) { + this.shortNames.clear(); + } + if (shortNames != null) { + for (java.lang.String item : shortNames) { + this.addToShortNames(item); + } + } + return (A) this; } + public java.lang.Boolean hasShortNames() { return shortNames != null && !shortNames.isEmpty(); } + public A addNewShortName(java.lang.String original) { - return (A)addToShortNames(new String(original)); + return (A) addToShortNames(new String(original)); } + public java.lang.String getSingularName() { return this.singularName; } + public A withSingularName(java.lang.String singularName) { - this.singularName=singularName; return (A) this; + this.singularName = singularName; + return (A) this; } + public java.lang.Boolean hasSingularName() { return this.singularName != null; } - - /** - * Method is deprecated. use withSingularName instead. - */ + + /** Method is deprecated. use withSingularName instead. */ @java.lang.Deprecated public A withNewSingularName(java.lang.String original) { - return (A)withSingularName(new String(original)); + return (A) withSingularName(new String(original)); } + public java.lang.String getStorageVersionHash() { return this.storageVersionHash; } + public A withStorageVersionHash(java.lang.String storageVersionHash) { - this.storageVersionHash=storageVersionHash; return (A) this; + this.storageVersionHash = storageVersionHash; + return (A) this; } + public java.lang.Boolean hasStorageVersionHash() { return this.storageVersionHash != null; } - - /** - * Method is deprecated. use withStorageVersionHash instead. - */ + + /** Method is deprecated. use withStorageVersionHash instead. */ @java.lang.Deprecated public A withNewStorageVersionHash(java.lang.String original) { - return (A)withStorageVersionHash(new String(original)); + return (A) withStorageVersionHash(new String(original)); } - public A addToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} + + public A addToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } this.verbs.add(index, item); - return (A)this; + return (A) this; } - public A setToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - this.verbs.set(index, item); return (A)this; + + public A setToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + this.verbs.set(index, item); + return (A) this; } + public A addToVerbs(java.lang.String... items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A addAllToVerbs(java.util.Collection items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A removeFromVerbs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public A removeAllFromVerbs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public java.util.List getVerbs() { return this.verbs; } + public java.lang.String getVerb(java.lang.Integer index) { return this.verbs.get(index); } + public java.lang.String getFirstVerb() { return this.verbs.get(0); } + public java.lang.String getLastVerb() { return this.verbs.get(verbs.size() - 1); } - public java.lang.String getMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withVerbs(java.util.List verbs) { - if (verbs != null) {this.verbs = new java.util.ArrayList(); for (java.lang.String item : verbs){this.addToVerbs(item);}} else { this.verbs = null;} return (A) this; + if (verbs != null) { + this.verbs = new java.util.ArrayList(); + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } else { + this.verbs = null; + } + return (A) this; } + public A withVerbs(java.lang.String... verbs) { - if (this.verbs != null) {this.verbs.clear();} - if (verbs != null) {for (java.lang.String item :verbs){ this.addToVerbs(item);}} return (A) this; + if (this.verbs != null) { + this.verbs.clear(); + } + if (verbs != null) { + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } + return (A) this; } + public java.lang.Boolean hasVerbs() { return verbs != null && !verbs.isEmpty(); } + public A addNewVerb(java.lang.String original) { - return (A)addToVerbs(new String(original)); + return (A) addToVerbs(new String(original)); } + public java.lang.String getVersion() { return this.version; } + public A withVersion(java.lang.String version) { - this.version=version; return (A) this; + this.version = version; + return (A) this; } + public java.lang.Boolean hasVersion() { return this.version != null; } - - /** - * Method is deprecated. use withVersion instead. - */ + + /** Method is deprecated. use withVersion instead. */ @java.lang.Deprecated public A withNewVersion(java.lang.String original) { - return (A)withVersion(new String(original)); + return (A) withVersion(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1APIResourceFluentImpl that = (V1APIResourceFluentImpl) o; - if (categories != null ? !categories.equals(that.categories) :that.categories != null) return false; - if (group != null ? !group.equals(that.group) :that.group != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (namespaced != null ? !namespaced.equals(that.namespaced) :that.namespaced != null) return false; - if (shortNames != null ? !shortNames.equals(that.shortNames) :that.shortNames != null) return false; - if (singularName != null ? !singularName.equals(that.singularName) :that.singularName != null) return false; - if (storageVersionHash != null ? !storageVersionHash.equals(that.storageVersionHash) :that.storageVersionHash != null) return false; - if (verbs != null ? !verbs.equals(that.verbs) :that.verbs != null) return false; - if (version != null ? !version.equals(that.version) :that.version != null) return false; + if (categories != null ? !categories.equals(that.categories) : that.categories != null) + return false; + if (group != null ? !group.equals(that.group) : that.group != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (namespaced != null ? !namespaced.equals(that.namespaced) : that.namespaced != null) + return false; + if (shortNames != null ? !shortNames.equals(that.shortNames) : that.shortNames != null) + return false; + if (singularName != null ? !singularName.equals(that.singularName) : that.singularName != null) + return false; + if (storageVersionHash != null + ? !storageVersionHash.equals(that.storageVersionHash) + : that.storageVersionHash != null) return false; + if (verbs != null ? !verbs.equals(that.verbs) : that.verbs != null) return false; + if (version != null ? !version.equals(that.version) : that.version != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(categories, group, kind, name, namespaced, shortNames, singularName, storageVersionHash, verbs, version, super.hashCode()); - } - -} \ No newline at end of file + return java.util.Objects.hash( + categories, + group, + kind, + name, + namespaced, + shortNames, + singularName, + storageVersionHash, + verbs, + version, + super.hashCode()); + } +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceListBuilder.java index 4231ae1a9b..eb46e23a55 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1APIResourceListBuilder extends io.kubernetes.client.openapi.models.V1APIResourceListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1APIResourceListBuilder + extends io.kubernetes.client.openapi.models.V1APIResourceListFluentImpl< + io.kubernetes.client.openapi.models.V1APIResourceListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1APIResourceList, + io.kubernetes.client.openapi.models.V1APIResourceListBuilder> { public V1APIResourceListBuilder() { this(false); } + public V1APIResourceListBuilder(java.lang.Boolean validationEnabled) { this(new V1APIResourceList(), validationEnabled); } - public V1APIResourceListBuilder(io.kubernetes.client.openapi.models.V1APIResourceListFluent fluent) { + + public V1APIResourceListBuilder( + io.kubernetes.client.openapi.models.V1APIResourceListFluent fluent) { this(fluent, false); } - public V1APIResourceListBuilder(io.kubernetes.client.openapi.models.V1APIResourceListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1APIResourceListBuilder( + io.kubernetes.client.openapi.models.V1APIResourceListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1APIResourceList(), validationEnabled); } - public V1APIResourceListBuilder(io.kubernetes.client.openapi.models.V1APIResourceListFluent fluent,io.kubernetes.client.openapi.models.V1APIResourceList instance) { + + public V1APIResourceListBuilder( + io.kubernetes.client.openapi.models.V1APIResourceListFluent fluent, + io.kubernetes.client.openapi.models.V1APIResourceList instance) { this(fluent, instance, false); } - public V1APIResourceListBuilder(io.kubernetes.client.openapi.models.V1APIResourceListFluent fluent,io.kubernetes.client.openapi.models.V1APIResourceList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1APIResourceListBuilder( + io.kubernetes.client.openapi.models.V1APIResourceListFluent fluent, + io.kubernetes.client.openapi.models.V1APIResourceList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withGroupVersion(instance.getGroupVersion()); @@ -29,13 +56,17 @@ public V1APIResourceListBuilder(io.kubernetes.client.openapi.models.V1APIResourc fluent.withResources(instance.getResources()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1APIResourceListBuilder(io.kubernetes.client.openapi.models.V1APIResourceList instance) { - this(instance,false); + this(instance, false); } - public V1APIResourceListBuilder(io.kubernetes.client.openapi.models.V1APIResourceList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1APIResourceListBuilder( + io.kubernetes.client.openapi.models.V1APIResourceList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withGroupVersion(instance.getGroupVersion()); @@ -44,10 +75,12 @@ public V1APIResourceListBuilder(io.kubernetes.client.openapi.models.V1APIResourc this.withResources(instance.getResources()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1APIResourceListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1APIResourceList build() { V1APIResourceList buildable = new V1APIResourceList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1APIResourceList build() { buildable.setResources(fluent.getResources()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1APIResourceListBuilder that = (V1APIResourceListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceListFluent.java index 8e8c1e9dee..e39a41893f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceListFluent.java @@ -1,84 +1,132 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1APIResourceListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1APIResourceListFluent< + A extends io.kubernetes.client.openapi.models.V1APIResourceListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getGroupVersion(); + public A withGroupVersion(java.lang.String groupVersion); + public java.lang.Boolean hasGroupVersion(); - - /** - * Method is deprecated. use withGroupVersion instead. - */ + + /** Method is deprecated. use withGroupVersion instead. */ @java.lang.Deprecated public A withNewGroupVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - public A addToResources(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIResource item); - public A setToResources(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIResource item); + + public A addToResources( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIResource item); + + public A setToResources( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIResource item); + public A addToResources(io.kubernetes.client.openapi.models.V1APIResource... items); - public A addAllToResources(java.util.Collection items); + + public A addAllToResources( + java.util.Collection items); + public A removeFromResources(io.kubernetes.client.openapi.models.V1APIResource... items); - public A removeAllFromResources(java.util.Collection items); - public A removeMatchingFromResources(java.util.function.Predicate predicate); - + + public A removeAllFromResources( + java.util.Collection items); + + public A removeMatchingFromResources( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildResources instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getResources(); + public java.util.List buildResources(); + public io.kubernetes.client.openapi.models.V1APIResource buildResource(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1APIResource buildFirstResource(); + public io.kubernetes.client.openapi.models.V1APIResource buildLastResource(); - public io.kubernetes.client.openapi.models.V1APIResource buildMatchingResource(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingResource(java.util.function.Predicate predicate); - public A withResources(java.util.List resources); + + public io.kubernetes.client.openapi.models.V1APIResource buildMatchingResource( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingResource( + java.util.function.Predicate + predicate); + + public A withResources( + java.util.List resources); + public A withResources(io.kubernetes.client.openapi.models.V1APIResource... resources); + public java.lang.Boolean hasResources(); - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested addNewResource(); - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested addNewResourceLike(io.kubernetes.client.openapi.models.V1APIResource item); - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested setNewResourceLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIResource item); - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested editResource(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested editFirstResource(); - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested editLastResource(); - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested editMatchingResource(java.util.function.Predicate predicate); - public interface ResourcesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1APIResourceFluent>{ + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + addNewResource(); + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + addNewResourceLike(io.kubernetes.client.openapi.models.V1APIResource item); + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + setNewResourceLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIResource item); + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + editResource(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + editFirstResource(); + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + editLastResource(); + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + editMatchingResource( + java.util.function.Predicate + predicate); + + public interface ResourcesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1APIResourceFluent< + io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested> { public N and(); + public N endResource(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceListFluentImpl.java index da33811014..c9fbd6e262 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIResourceListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1APIResourceListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1APIResourceListFluent{ - public V1APIResourceListFluentImpl() { - } - public V1APIResourceListFluentImpl(io.kubernetes.client.openapi.models.V1APIResourceList instance) { +/** Generated */ +public class V1APIResourceListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1APIResourceListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1APIResourceListFluent { + public V1APIResourceListFluentImpl() {} + + public V1APIResourceListFluentImpl( + io.kubernetes.client.openapi.models.V1APIResourceList instance) { this.withApiVersion(instance.getApiVersion()); this.withGroupVersion(instance.getGroupVersion()); @@ -28,91 +31,166 @@ public V1APIResourceListFluentImpl(io.kubernetes.client.openapi.models.V1APIReso this.withKind(instance.getKind()); this.withResources(instance.getResources()); - } + private java.lang.String apiVersion; private java.lang.String groupVersion; private java.lang.String kind; private java.util.ArrayList resources; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getGroupVersion() { return this.groupVersion; } + public A withGroupVersion(java.lang.String groupVersion) { - this.groupVersion=groupVersion; return (A) this; + this.groupVersion = groupVersion; + return (A) this; } + public java.lang.Boolean hasGroupVersion() { return this.groupVersion != null; } - - /** - * Method is deprecated. use withGroupVersion instead. - */ + + /** Method is deprecated. use withGroupVersion instead. */ @java.lang.Deprecated public A withNewGroupVersion(java.lang.String original) { - return (A)withGroupVersion(new String(original)); + return (A) withGroupVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - public A addToResources(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIResource item) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1APIResourceBuilder builder = new io.kubernetes.client.openapi.models.V1APIResourceBuilder(item);_visitables.get("resources").add(index >= 0 ? index : _visitables.get("resources").size(), builder);this.resources.add(index >= 0 ? index : resources.size(), builder); return (A)this; + + public A addToResources( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIResource item) { + if (this.resources == null) { + this.resources = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1APIResourceBuilder builder = + new io.kubernetes.client.openapi.models.V1APIResourceBuilder(item); + _visitables + .get("resources") + .add(index >= 0 ? index : _visitables.get("resources").size(), builder); + this.resources.add(index >= 0 ? index : resources.size(), builder); + return (A) this; } - public A setToResources(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIResource item) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1APIResourceBuilder builder = new io.kubernetes.client.openapi.models.V1APIResourceBuilder(item); - if (index < 0 || index >= _visitables.get("resources").size()) { _visitables.get("resources").add(builder); } else { _visitables.get("resources").set(index, builder);} - if (index < 0 || index >= resources.size()) { resources.add(builder); } else { resources.set(index, builder);} - return (A)this; + + public A setToResources( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIResource item) { + if (this.resources == null) { + this.resources = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1APIResourceBuilder builder = + new io.kubernetes.client.openapi.models.V1APIResourceBuilder(item); + if (index < 0 || index >= _visitables.get("resources").size()) { + _visitables.get("resources").add(builder); + } else { + _visitables.get("resources").set(index, builder); + } + if (index < 0 || index >= resources.size()) { + resources.add(builder); + } else { + resources.set(index, builder); + } + return (A) this; } + public A addToResources(io.kubernetes.client.openapi.models.V1APIResource... items) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1APIResource item : items) {io.kubernetes.client.openapi.models.V1APIResourceBuilder builder = new io.kubernetes.client.openapi.models.V1APIResourceBuilder(item);_visitables.get("resources").add(builder);this.resources.add(builder);} return (A)this; + if (this.resources == null) { + this.resources = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1APIResource item : items) { + io.kubernetes.client.openapi.models.V1APIResourceBuilder builder = + new io.kubernetes.client.openapi.models.V1APIResourceBuilder(item); + _visitables.get("resources").add(builder); + this.resources.add(builder); + } + return (A) this; } - public A addAllToResources(java.util.Collection items) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1APIResource item : items) {io.kubernetes.client.openapi.models.V1APIResourceBuilder builder = new io.kubernetes.client.openapi.models.V1APIResourceBuilder(item);_visitables.get("resources").add(builder);this.resources.add(builder);} return (A)this; + + public A addAllToResources( + java.util.Collection items) { + if (this.resources == null) { + this.resources = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1APIResource item : items) { + io.kubernetes.client.openapi.models.V1APIResourceBuilder builder = + new io.kubernetes.client.openapi.models.V1APIResourceBuilder(item); + _visitables.get("resources").add(builder); + this.resources.add(builder); + } + return (A) this; } + public A removeFromResources(io.kubernetes.client.openapi.models.V1APIResource... items) { - for (io.kubernetes.client.openapi.models.V1APIResource item : items) {io.kubernetes.client.openapi.models.V1APIResourceBuilder builder = new io.kubernetes.client.openapi.models.V1APIResourceBuilder(item);_visitables.get("resources").remove(builder);if (this.resources != null) {this.resources.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1APIResource item : items) { + io.kubernetes.client.openapi.models.V1APIResourceBuilder builder = + new io.kubernetes.client.openapi.models.V1APIResourceBuilder(item); + _visitables.get("resources").remove(builder); + if (this.resources != null) { + this.resources.remove(builder); + } + } + return (A) this; } - public A removeAllFromResources(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1APIResource item : items) {io.kubernetes.client.openapi.models.V1APIResourceBuilder builder = new io.kubernetes.client.openapi.models.V1APIResourceBuilder(item);_visitables.get("resources").remove(builder);if (this.resources != null) {this.resources.remove(builder);}} return (A)this; + + public A removeAllFromResources( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1APIResource item : items) { + io.kubernetes.client.openapi.models.V1APIResourceBuilder builder = + new io.kubernetes.client.openapi.models.V1APIResourceBuilder(item); + _visitables.get("resources").remove(builder); + if (this.resources != null) { + this.resources.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromResources(java.util.function.Predicate predicate) { + + public A removeMatchingFromResources( + java.util.function.Predicate + predicate) { if (resources == null) return (A) this; - final Iterator each = resources.iterator(); + final Iterator each = + resources.iterator(); final List visitables = _visitables.get("resources"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1APIResourceBuilder builder = each.next(); @@ -121,107 +199,187 @@ public A removeMatchingFromResources(java.util.function.Predicate getResources() { return resources != null ? build(resources) : null; } + public java.util.List buildResources() { return resources != null ? build(resources) : null; } + public io.kubernetes.client.openapi.models.V1APIResource buildResource(java.lang.Integer index) { return this.resources.get(index).build(); } + public io.kubernetes.client.openapi.models.V1APIResource buildFirstResource() { return this.resources.get(0).build(); } + public io.kubernetes.client.openapi.models.V1APIResource buildLastResource() { return this.resources.get(resources.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1APIResource buildMatchingResource(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1APIResourceBuilder item: resources) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1APIResource buildMatchingResource( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1APIResourceBuilder item : resources) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingResource(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1APIResourceBuilder item: resources) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingResource( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1APIResourceBuilder item : resources) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withResources(java.util.List resources) { - if (this.resources != null) { _visitables.get("resources").removeAll(this.resources);} - if (resources != null) {this.resources = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1APIResource item : resources){this.addToResources(item);}} else { this.resources = null;} return (A) this; + + public A withResources( + java.util.List resources) { + if (this.resources != null) { + _visitables.get("resources").removeAll(this.resources); + } + if (resources != null) { + this.resources = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1APIResource item : resources) { + this.addToResources(item); + } + } else { + this.resources = null; + } + return (A) this; } + public A withResources(io.kubernetes.client.openapi.models.V1APIResource... resources) { - if (this.resources != null) {this.resources.clear();} - if (resources != null) {for (io.kubernetes.client.openapi.models.V1APIResource item :resources){ this.addToResources(item);}} return (A) this; + if (this.resources != null) { + this.resources.clear(); + } + if (resources != null) { + for (io.kubernetes.client.openapi.models.V1APIResource item : resources) { + this.addToResources(item); + } + } + return (A) this; } + public java.lang.Boolean hasResources() { return resources != null && !resources.isEmpty(); } - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested addNewResource() { - return new io.kubernetes.client.openapi.models.V1APIResourceListFluentImpl.ResourcesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + addNewResource() { + return new io.kubernetes.client.openapi.models.V1APIResourceListFluentImpl + .ResourcesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested addNewResourceLike(io.kubernetes.client.openapi.models.V1APIResource item) { - return new io.kubernetes.client.openapi.models.V1APIResourceListFluentImpl.ResourcesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + addNewResourceLike(io.kubernetes.client.openapi.models.V1APIResource item) { + return new io.kubernetes.client.openapi.models.V1APIResourceListFluentImpl.ResourcesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested setNewResourceLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIResource item) { - return new io.kubernetes.client.openapi.models.V1APIResourceListFluentImpl.ResourcesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + setNewResourceLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIResource item) { + return new io.kubernetes.client.openapi.models.V1APIResourceListFluentImpl.ResourcesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested editResource(java.lang.Integer index) { - if (resources.size() <= index) throw new RuntimeException("Can't edit resources. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + editResource(java.lang.Integer index) { + if (resources.size() <= index) + throw new RuntimeException("Can't edit resources. Index exceeds size."); return setNewResourceLike(index, buildResource(index)); } - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested editFirstResource() { - if (resources.size() == 0) throw new RuntimeException("Can't edit first resources. The list is empty."); + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + editFirstResource() { + if (resources.size() == 0) + throw new RuntimeException("Can't edit first resources. The list is empty."); return setNewResourceLike(0, buildResource(0)); } - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested editLastResource() { + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + editLastResource() { int index = resources.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last resources. The list is empty."); return setNewResourceLike(index, buildResource(index)); } - public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested editMatchingResource(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested + editMatchingResource( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1APIResourceFluentImpl> implements io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested,io.kubernetes.client.fluent.Nested{ - ResourcesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIResource item) { + + public class ResourcesNestedImpl + extends io.kubernetes.client.openapi.models.V1APIResourceFluentImpl< + io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested> + implements io.kubernetes.client.openapi.models.V1APIResourceListFluent.ResourcesNested, + io.kubernetes.client.fluent.Nested { + ResourcesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIResource item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1APIResourceBuilder(this, item); } + ResourcesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1APIResourceBuilder(this); } + io.kubernetes.client.openapi.models.V1APIResourceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1APIResourceListFluentImpl.this.setToResources(index,builder.build()); + return (N) V1APIResourceListFluentImpl.this.setToResources(index, builder.build()); } + public N endResource() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceBuilder.java index 766467a145..1a2dc4937d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1APIServiceBuilder extends io.kubernetes.client.openapi.models.V1APIServiceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1APIServiceBuilder + extends io.kubernetes.client.openapi.models.V1APIServiceFluentImpl< + io.kubernetes.client.openapi.models.V1APIServiceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1APIService, + io.kubernetes.client.openapi.models.V1APIServiceBuilder> { public V1APIServiceBuilder() { this(false); } + public V1APIServiceBuilder(java.lang.Boolean validationEnabled) { this(new V1APIService(), validationEnabled); } + public V1APIServiceBuilder(io.kubernetes.client.openapi.models.V1APIServiceFluent fluent) { this(fluent, false); } - public V1APIServiceBuilder(io.kubernetes.client.openapi.models.V1APIServiceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1APIServiceBuilder( + io.kubernetes.client.openapi.models.V1APIServiceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1APIService(), validationEnabled); } - public V1APIServiceBuilder(io.kubernetes.client.openapi.models.V1APIServiceFluent fluent,io.kubernetes.client.openapi.models.V1APIService instance) { + + public V1APIServiceBuilder( + io.kubernetes.client.openapi.models.V1APIServiceFluent fluent, + io.kubernetes.client.openapi.models.V1APIService instance) { this(fluent, instance, false); } - public V1APIServiceBuilder(io.kubernetes.client.openapi.models.V1APIServiceFluent fluent,io.kubernetes.client.openapi.models.V1APIService instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1APIServiceBuilder( + io.kubernetes.client.openapi.models.V1APIServiceFluent fluent, + io.kubernetes.client.openapi.models.V1APIService instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,17 @@ public V1APIServiceBuilder(io.kubernetes.client.openapi.models.V1APIServiceFluen fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1APIServiceBuilder(io.kubernetes.client.openapi.models.V1APIService instance) { - this(instance,false); + this(instance, false); } - public V1APIServiceBuilder(io.kubernetes.client.openapi.models.V1APIService instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1APIServiceBuilder( + io.kubernetes.client.openapi.models.V1APIService instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +78,12 @@ public V1APIServiceBuilder(io.kubernetes.client.openapi.models.V1APIService inst this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1APIServiceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1APIService build() { V1APIService buildable = new V1APIService(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +93,23 @@ public io.kubernetes.client.openapi.models.V1APIService build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1APIServiceBuilder that = (V1APIServiceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceConditionBuilder.java index fdb4ed8ee5..805745702a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1APIServiceConditionBuilder extends io.kubernetes.client.openapi.models.V1APIServiceConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1APIServiceConditionBuilder + extends io.kubernetes.client.openapi.models.V1APIServiceConditionFluentImpl< + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1APIServiceCondition, + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder> { public V1APIServiceConditionBuilder() { this(false); } + public V1APIServiceConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1APIServiceCondition(), validationEnabled); } - public V1APIServiceConditionBuilder(io.kubernetes.client.openapi.models.V1APIServiceConditionFluent fluent) { + + public V1APIServiceConditionBuilder( + io.kubernetes.client.openapi.models.V1APIServiceConditionFluent fluent) { this(fluent, false); } - public V1APIServiceConditionBuilder(io.kubernetes.client.openapi.models.V1APIServiceConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1APIServiceConditionBuilder( + io.kubernetes.client.openapi.models.V1APIServiceConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1APIServiceCondition(), validationEnabled); } - public V1APIServiceConditionBuilder(io.kubernetes.client.openapi.models.V1APIServiceConditionFluent fluent,io.kubernetes.client.openapi.models.V1APIServiceCondition instance) { + + public V1APIServiceConditionBuilder( + io.kubernetes.client.openapi.models.V1APIServiceConditionFluent fluent, + io.kubernetes.client.openapi.models.V1APIServiceCondition instance) { this(fluent, instance, false); } - public V1APIServiceConditionBuilder(io.kubernetes.client.openapi.models.V1APIServiceConditionFluent fluent,io.kubernetes.client.openapi.models.V1APIServiceCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1APIServiceConditionBuilder( + io.kubernetes.client.openapi.models.V1APIServiceConditionFluent fluent, + io.kubernetes.client.openapi.models.V1APIServiceCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +58,18 @@ public V1APIServiceConditionBuilder(io.kubernetes.client.openapi.models.V1APISer fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1APIServiceConditionBuilder(io.kubernetes.client.openapi.models.V1APIServiceCondition instance) { - this(instance,false); + + public V1APIServiceConditionBuilder( + io.kubernetes.client.openapi.models.V1APIServiceCondition instance) { + this(instance, false); } - public V1APIServiceConditionBuilder(io.kubernetes.client.openapi.models.V1APIServiceCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1APIServiceConditionBuilder( + io.kubernetes.client.openapi.models.V1APIServiceCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,10 +80,12 @@ public V1APIServiceConditionBuilder(io.kubernetes.client.openapi.models.V1APISer this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1APIServiceConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1APIServiceCondition build() { V1APIServiceCondition buildable = new V1APIServiceCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1APIServiceCondition build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1APIServiceConditionBuilder that = (V1APIServiceConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceConditionFluent.java index 1ff010db4c..9c3e4c660d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceConditionFluent.java @@ -1,54 +1,64 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1APIServiceConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1APIServiceConditionFluent< + A extends io.kubernetes.client.openapi.models.V1APIServiceConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceConditionFluentImpl.java index 186be7bddb..c11d06399f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceConditionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1APIServiceConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1APIServiceConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1APIServiceConditionFluent { + public V1APIServiceConditionFluentImpl() {} - /** - * Generated - */ -public class V1APIServiceConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1APIServiceConditionFluent{ - public V1APIServiceConditionFluentImpl() { - } - public V1APIServiceConditionFluentImpl(io.kubernetes.client.openapi.models.V1APIServiceCondition instance) { + public V1APIServiceConditionFluentImpl( + io.kubernetes.client.openapi.models.V1APIServiceCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,103 +30,119 @@ public V1APIServiceConditionFluentImpl(io.kubernetes.client.openapi.models.V1API this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1APIServiceConditionFluentImpl that = (V1APIServiceConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceFluent.java index 51d71c15cf..d30b623d07 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceFluent.java @@ -1,93 +1,144 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1APIServiceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1APIServiceFluent< + A extends io.kubernetes.client.openapi.models.V1APIServiceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1APIServiceSpec getSpec(); + public io.kubernetes.client.openapi.models.V1APIServiceSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1APIServiceSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1APIServiceSpec item); + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1APIServiceSpec item); + public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1APIServiceSpec item); - + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1APIServiceSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1APIServiceStatus getStatus(); + public io.kubernetes.client.openapi.models.V1APIServiceStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1APIServiceStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1APIServiceStatus item); + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1APIServiceStatus item); + public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1APIServiceStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1APIServiceStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1APIServiceSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1APIServiceSpecFluent< + io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1APIServiceStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1APIServiceStatusFluent< + io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceFluentImpl.java index 9e578207c2..d261a52852 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1APIServiceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1APIServiceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1APIServiceFluent { + public V1APIServiceFluentImpl() {} - /** - * Generated - */ -public class V1APIServiceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1APIServiceFluent{ - public V1APIServiceFluentImpl() { - } public V1APIServiceFluentImpl(io.kubernetes.client.openapi.models.V1APIService instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +29,296 @@ public V1APIServiceFluentImpl(io.kubernetes.client.openapi.models.V1APIService i this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1APIServiceSpecBuilder spec; private io.kubernetes.client.openapi.models.V1APIServiceStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1APIServiceFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1APIServiceFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1APIServiceSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1APIServiceSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1APIServiceSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1APIServiceSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1APIServiceSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1APIServiceFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1APIServiceSpec item) { + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1APIServiceSpec item) { return new io.kubernetes.client.openapi.models.V1APIServiceFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1APIServiceSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1APIServiceSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1APIServiceSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1APIServiceSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1APIServiceStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1APIServiceStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1APIServiceStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1APIServiceStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1APIServiceStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1APIServiceFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1APIServiceStatus item) { + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1APIServiceStatus item) { return new io.kubernetes.client.openapi.models.V1APIServiceFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1APIServiceStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1APIServiceStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1APIServiceStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1APIServiceStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1APIServiceFluentImpl that = (V1APIServiceFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1APIServiceFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1APIServiceFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1APIServiceSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1APIServiceSpecFluentImpl< + io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1APIServiceFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1APIServiceSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1APIServiceSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1APIServiceSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1APIServiceSpecBuilder builder; + public N and() { return (N) V1APIServiceFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1APIServiceStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1APIServiceStatusFluentImpl< + io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1APIServiceFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1APIServiceStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1APIServiceStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1APIServiceStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1APIServiceStatusBuilder builder; + public N and() { return (N) V1APIServiceFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceListBuilder.java index 208ed7acf7..0a5baa9473 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1APIServiceListBuilder extends io.kubernetes.client.openapi.models.V1APIServiceListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1APIServiceListBuilder + extends io.kubernetes.client.openapi.models.V1APIServiceListFluentImpl< + io.kubernetes.client.openapi.models.V1APIServiceListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1APIServiceList, + io.kubernetes.client.openapi.models.V1APIServiceListBuilder> { public V1APIServiceListBuilder() { this(false); } + public V1APIServiceListBuilder(java.lang.Boolean validationEnabled) { this(new V1APIServiceList(), validationEnabled); } - public V1APIServiceListBuilder(io.kubernetes.client.openapi.models.V1APIServiceListFluent fluent) { + + public V1APIServiceListBuilder( + io.kubernetes.client.openapi.models.V1APIServiceListFluent fluent) { this(fluent, false); } - public V1APIServiceListBuilder(io.kubernetes.client.openapi.models.V1APIServiceListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1APIServiceListBuilder( + io.kubernetes.client.openapi.models.V1APIServiceListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1APIServiceList(), validationEnabled); } - public V1APIServiceListBuilder(io.kubernetes.client.openapi.models.V1APIServiceListFluent fluent,io.kubernetes.client.openapi.models.V1APIServiceList instance) { + + public V1APIServiceListBuilder( + io.kubernetes.client.openapi.models.V1APIServiceListFluent fluent, + io.kubernetes.client.openapi.models.V1APIServiceList instance) { this(fluent, instance, false); } - public V1APIServiceListBuilder(io.kubernetes.client.openapi.models.V1APIServiceListFluent fluent,io.kubernetes.client.openapi.models.V1APIServiceList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1APIServiceListBuilder( + io.kubernetes.client.openapi.models.V1APIServiceListFluent fluent, + io.kubernetes.client.openapi.models.V1APIServiceList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1APIServiceListBuilder(io.kubernetes.client.openapi.models.V1APIServiceL fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1APIServiceListBuilder(io.kubernetes.client.openapi.models.V1APIServiceList instance) { - this(instance,false); + this(instance, false); } - public V1APIServiceListBuilder(io.kubernetes.client.openapi.models.V1APIServiceList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1APIServiceListBuilder( + io.kubernetes.client.openapi.models.V1APIServiceList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1APIServiceListBuilder(io.kubernetes.client.openapi.models.V1APIServiceL this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1APIServiceListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1APIServiceList build() { V1APIServiceList buildable = new V1APIServiceList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1APIServiceList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1APIServiceListBuilder that = (V1APIServiceListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceListFluent.java index c6c619a879..5a01434b96 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceListFluent.java @@ -1,95 +1,154 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1APIServiceListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1APIServiceListFluent< + A extends io.kubernetes.client.openapi.models.V1APIServiceListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIService item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIService item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIService item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIService item); + public A addToItems(io.kubernetes.client.openapi.models.V1APIService... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1APIService... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1APIService buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1APIService buildFirstItem(); + public io.kubernetes.client.openapi.models.V1APIService buildLastItem(); - public io.kubernetes.client.openapi.models.V1APIService buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1APIService buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1APIService... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1APIService item); - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIService item); - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1APIService item); + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIService item); + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1APIServiceFluent>{ + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1APIServiceFluent< + io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceListFluentImpl.java index 1ea264c932..7a88e063ae 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1APIServiceListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1APIServiceListFluent{ - public V1APIServiceListFluentImpl() { - } +/** Generated */ +public class V1APIServiceListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1APIServiceListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1APIServiceListFluent { + public V1APIServiceListFluentImpl() {} + public V1APIServiceListFluentImpl(io.kubernetes.client.openapi.models.V1APIServiceList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,123 @@ public V1APIServiceListFluentImpl(io.kubernetes.client.openapi.models.V1APIServi this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIService item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1APIServiceBuilder builder = new io.kubernetes.client.openapi.models.V1APIServiceBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIService item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1APIServiceBuilder builder = + new io.kubernetes.client.openapi.models.V1APIServiceBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIService item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1APIServiceBuilder builder = new io.kubernetes.client.openapi.models.V1APIServiceBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIService item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1APIServiceBuilder builder = + new io.kubernetes.client.openapi.models.V1APIServiceBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1APIService... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1APIService item : items) {io.kubernetes.client.openapi.models.V1APIServiceBuilder builder = new io.kubernetes.client.openapi.models.V1APIServiceBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1APIService item : items) { + io.kubernetes.client.openapi.models.V1APIServiceBuilder builder = + new io.kubernetes.client.openapi.models.V1APIServiceBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1APIService item : items) {io.kubernetes.client.openapi.models.V1APIServiceBuilder builder = new io.kubernetes.client.openapi.models.V1APIServiceBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1APIService item : items) { + io.kubernetes.client.openapi.models.V1APIServiceBuilder builder = + new io.kubernetes.client.openapi.models.V1APIServiceBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1APIService... items) { - for (io.kubernetes.client.openapi.models.V1APIService item : items) {io.kubernetes.client.openapi.models.V1APIServiceBuilder builder = new io.kubernetes.client.openapi.models.V1APIServiceBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1APIService item : items) { + io.kubernetes.client.openapi.models.V1APIServiceBuilder builder = + new io.kubernetes.client.openapi.models.V1APIServiceBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1APIService item : items) {io.kubernetes.client.openapi.models.V1APIServiceBuilder builder = new io.kubernetes.client.openapi.models.V1APIServiceBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1APIService item : items) { + io.kubernetes.client.openapi.models.V1APIServiceBuilder builder = + new io.kubernetes.client.openapi.models.V1APIServiceBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +157,275 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1APIService buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1APIService buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1APIService buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1APIService buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1APIServiceBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1APIService buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1APIServiceBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1APIServiceBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1APIServiceBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1APIService item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1APIService item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1APIService... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1APIService item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1APIService item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1APIServiceListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1APIService item) { - return new io.kubernetes.client.openapi.models.V1APIServiceListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1APIService item) { + return new io.kubernetes.client.openapi.models.V1APIServiceListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIService item) { - return new io.kubernetes.client.openapi.models.V1APIServiceListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIService item) { + return new io.kubernetes.client.openapi.models.V1APIServiceListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1APIServiceListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1APIServiceListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1APIServiceListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1APIServiceListFluentImpl that = (V1APIServiceListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1APIServiceFluentImpl> implements io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIService item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1APIServiceFluentImpl< + io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1APIServiceListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIService item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1APIServiceBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1APIServiceBuilder(this); } + io.kubernetes.client.openapi.models.V1APIServiceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1APIServiceListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1APIServiceListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1APIServiceListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1APIServiceListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceSpecBuilder.java index cd6ce72e95..c742eef7eb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1APIServiceSpecBuilder extends io.kubernetes.client.openapi.models.V1APIServiceSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1APIServiceSpecBuilder + extends io.kubernetes.client.openapi.models.V1APIServiceSpecFluentImpl< + io.kubernetes.client.openapi.models.V1APIServiceSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1APIServiceSpec, + io.kubernetes.client.openapi.models.V1APIServiceSpecBuilder> { public V1APIServiceSpecBuilder() { this(false); } + public V1APIServiceSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1APIServiceSpec(), validationEnabled); } - public V1APIServiceSpecBuilder(io.kubernetes.client.openapi.models.V1APIServiceSpecFluent fluent) { + + public V1APIServiceSpecBuilder( + io.kubernetes.client.openapi.models.V1APIServiceSpecFluent fluent) { this(fluent, false); } - public V1APIServiceSpecBuilder(io.kubernetes.client.openapi.models.V1APIServiceSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1APIServiceSpecBuilder( + io.kubernetes.client.openapi.models.V1APIServiceSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1APIServiceSpec(), validationEnabled); } - public V1APIServiceSpecBuilder(io.kubernetes.client.openapi.models.V1APIServiceSpecFluent fluent,io.kubernetes.client.openapi.models.V1APIServiceSpec instance) { + + public V1APIServiceSpecBuilder( + io.kubernetes.client.openapi.models.V1APIServiceSpecFluent fluent, + io.kubernetes.client.openapi.models.V1APIServiceSpec instance) { this(fluent, instance, false); } - public V1APIServiceSpecBuilder(io.kubernetes.client.openapi.models.V1APIServiceSpecFluent fluent,io.kubernetes.client.openapi.models.V1APIServiceSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1APIServiceSpecBuilder( + io.kubernetes.client.openapi.models.V1APIServiceSpecFluent fluent, + io.kubernetes.client.openapi.models.V1APIServiceSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCaBundle(instance.getCaBundle()); fluent.withGroup(instance.getGroup()); @@ -35,13 +62,17 @@ public V1APIServiceSpecBuilder(io.kubernetes.client.openapi.models.V1APIServiceS fluent.withVersionPriority(instance.getVersionPriority()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1APIServiceSpecBuilder(io.kubernetes.client.openapi.models.V1APIServiceSpec instance) { - this(instance,false); + this(instance, false); } - public V1APIServiceSpecBuilder(io.kubernetes.client.openapi.models.V1APIServiceSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1APIServiceSpecBuilder( + io.kubernetes.client.openapi.models.V1APIServiceSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCaBundle(instance.getCaBundle()); this.withGroup(instance.getGroup()); @@ -56,10 +87,12 @@ public V1APIServiceSpecBuilder(io.kubernetes.client.openapi.models.V1APIServiceS this.withVersionPriority(instance.getVersionPriority()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1APIServiceSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1APIServiceSpec build() { V1APIServiceSpec buildable = new V1APIServiceSpec(); buildable.setCaBundle(fluent.getCaBundle()); @@ -71,18 +104,23 @@ public io.kubernetes.client.openapi.models.V1APIServiceSpec build() { buildable.setVersionPriority(fluent.getVersionPriority()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1APIServiceSpecBuilder that = (V1APIServiceSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceSpecFluent.java index 308f4386c9..b5e27fe30d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceSpecFluent.java @@ -1,75 +1,114 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Byte; -import java.util.Collection; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1APIServiceSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1APIServiceSpecFluent< + A extends io.kubernetes.client.openapi.models.V1APIServiceSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public A withCaBundle(byte... caBundle); + public byte[] getCaBundle(); - public A addToCaBundle(java.lang.Integer index,java.lang.Byte item); - public A setToCaBundle(java.lang.Integer index,java.lang.Byte item); + + public A addToCaBundle(java.lang.Integer index, java.lang.Byte item); + + public A setToCaBundle(java.lang.Integer index, java.lang.Byte item); + public A addToCaBundle(java.lang.Byte... items); + public A addAllToCaBundle(java.util.Collection items); + public A removeFromCaBundle(java.lang.Byte... items); + public A removeAllFromCaBundle(java.util.Collection items); + public java.lang.Boolean hasCaBundle(); + public java.lang.String getGroup(); + public A withGroup(java.lang.String group); + public java.lang.Boolean hasGroup(); - - /** - * Method is deprecated. use withGroup instead. - */ + + /** Method is deprecated. use withGroup instead. */ @java.lang.Deprecated public A withNewGroup(java.lang.String original); + public java.lang.Integer getGroupPriorityMinimum(); + public A withGroupPriorityMinimum(java.lang.Integer groupPriorityMinimum); + public java.lang.Boolean hasGroupPriorityMinimum(); + public java.lang.Boolean getInsecureSkipTLSVerify(); + public A withInsecureSkipTLSVerify(java.lang.Boolean insecureSkipTLSVerify); + public java.lang.Boolean hasInsecureSkipTLSVerify(); - + /** * This method has been deprecated, please use method buildService instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference getService(); + public io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference buildService(); - public A withService(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference service); + + public A withService( + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference service); + public java.lang.Boolean hasService(); - public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested withNewService(); - public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested withNewServiceLike(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference item); + + public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested + withNewService(); + + public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested + withNewServiceLike( + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference item); + public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested editService(); - public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested editOrNewService(); - public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested editOrNewServiceLike(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference item); + + public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested + editOrNewService(); + + public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested + editOrNewServiceLike( + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference item); + public java.lang.String getVersion(); + public A withVersion(java.lang.String version); + public java.lang.Boolean hasVersion(); - - /** - * Method is deprecated. use withVersion instead. - */ + + /** Method is deprecated. use withVersion instead. */ @java.lang.Deprecated public A withNewVersion(java.lang.String original); + public java.lang.Integer getVersionPriority(); + public A withVersionPriority(java.lang.Integer versionPriority); + public java.lang.Boolean hasVersionPriority(); - public interface ServiceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent>{ + + public interface ServiceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluent< + io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested> { public N and(); + public N endService(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceSpecFluentImpl.java index 742bd12691..51872197bb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceSpecFluentImpl.java @@ -1,23 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Byte; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1APIServiceSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1APIServiceSpecFluent{ - public V1APIServiceSpecFluentImpl() { - } +/** Generated */ +public class V1APIServiceSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1APIServiceSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1APIServiceSpecFluent { + public V1APIServiceSpecFluentImpl() {} + public V1APIServiceSpecFluentImpl(io.kubernetes.client.openapi.models.V1APIServiceSpec instance) { this.withCaBundle(instance.getCaBundle()); @@ -32,8 +33,8 @@ public V1APIServiceSpecFluentImpl(io.kubernetes.client.openapi.models.V1APIServi this.withVersion(instance.getVersion()); this.withVersionPriority(instance.getVersionPriority()); - } + private java.util.List caBundle; private java.lang.String group; private java.lang.Integer groupPriorityMinimum; @@ -41,176 +42,284 @@ public V1APIServiceSpecFluentImpl(io.kubernetes.client.openapi.models.V1APIServi private io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceBuilder service; private java.lang.String version; private java.lang.Integer versionPriority; + public A withCaBundle(byte... caBundle) { - if (this.caBundle != null) {this.caBundle.clear();} - if (caBundle != null) {for (byte item :caBundle){ this.addToCaBundle(item);}} return (A) this; + if (this.caBundle != null) { + this.caBundle.clear(); + } + if (caBundle != null) { + for (byte item : caBundle) { + this.addToCaBundle(item); + } + } + return (A) this; } - public byte[] getCaBundle() { - //This needs to work with primitives, so we use arrays. -int size = caBundle != null ? caBundle.size() : 0; -byte[] result = new byte[size]; -if (size == 0) { - return result; -} -int index = 0; -for (byte item : caBundle) { - result[index++]=item; -} -return result; + public byte[] getCaBundle() { + // This needs to work with primitives, so we use arrays. + int size = caBundle != null ? caBundle.size() : 0; + byte[] result = new byte[size]; + if (size == 0) { + return result; + } + int index = 0; + for (byte item : caBundle) { + result[index++] = item; + } + return result; } - public A addToCaBundle(java.lang.Integer index,java.lang.Byte item) { - if (this.caBundle == null) {this.caBundle = new java.util.ArrayList();} + + public A addToCaBundle(java.lang.Integer index, java.lang.Byte item) { + if (this.caBundle == null) { + this.caBundle = new java.util.ArrayList(); + } this.caBundle.add(index, item); - return (A)this; + return (A) this; } - public A setToCaBundle(java.lang.Integer index,java.lang.Byte item) { - if (this.caBundle == null) {this.caBundle = new java.util.ArrayList();} - this.caBundle.set(index, item); return (A)this; + + public A setToCaBundle(java.lang.Integer index, java.lang.Byte item) { + if (this.caBundle == null) { + this.caBundle = new java.util.ArrayList(); + } + this.caBundle.set(index, item); + return (A) this; } + public A addToCaBundle(java.lang.Byte... items) { - if (this.caBundle == null) {this.caBundle = new java.util.ArrayList();} - for (java.lang.Byte item : items) {this.caBundle.add(item);} return (A)this; + if (this.caBundle == null) { + this.caBundle = new java.util.ArrayList(); + } + for (java.lang.Byte item : items) { + this.caBundle.add(item); + } + return (A) this; } + public A addAllToCaBundle(java.util.Collection items) { - if (this.caBundle == null) {this.caBundle = new java.util.ArrayList();} - for (java.lang.Byte item : items) {this.caBundle.add(item);} return (A)this; + if (this.caBundle == null) { + this.caBundle = new java.util.ArrayList(); + } + for (java.lang.Byte item : items) { + this.caBundle.add(item); + } + return (A) this; } + public A removeFromCaBundle(java.lang.Byte... items) { - for (java.lang.Byte item : items) {if (this.caBundle!= null){ this.caBundle.remove(item);}} return (A)this; + for (java.lang.Byte item : items) { + if (this.caBundle != null) { + this.caBundle.remove(item); + } + } + return (A) this; } + public A removeAllFromCaBundle(java.util.Collection items) { - for (java.lang.Byte item : items) {if (this.caBundle!= null){ this.caBundle.remove(item);}} return (A)this; + for (java.lang.Byte item : items) { + if (this.caBundle != null) { + this.caBundle.remove(item); + } + } + return (A) this; } + public java.lang.Boolean hasCaBundle() { return caBundle != null && !caBundle.isEmpty(); } + public java.lang.String getGroup() { return this.group; } + public A withGroup(java.lang.String group) { - this.group=group; return (A) this; + this.group = group; + return (A) this; } + public java.lang.Boolean hasGroup() { return this.group != null; } - - /** - * Method is deprecated. use withGroup instead. - */ + + /** Method is deprecated. use withGroup instead. */ @java.lang.Deprecated public A withNewGroup(java.lang.String original) { - return (A)withGroup(new String(original)); + return (A) withGroup(new String(original)); } + public java.lang.Integer getGroupPriorityMinimum() { return this.groupPriorityMinimum; } + public A withGroupPriorityMinimum(java.lang.Integer groupPriorityMinimum) { - this.groupPriorityMinimum=groupPriorityMinimum; return (A) this; + this.groupPriorityMinimum = groupPriorityMinimum; + return (A) this; } + public java.lang.Boolean hasGroupPriorityMinimum() { return this.groupPriorityMinimum != null; } + public java.lang.Boolean getInsecureSkipTLSVerify() { return this.insecureSkipTLSVerify; } + public A withInsecureSkipTLSVerify(java.lang.Boolean insecureSkipTLSVerify) { - this.insecureSkipTLSVerify=insecureSkipTLSVerify; return (A) this; + this.insecureSkipTLSVerify = insecureSkipTLSVerify; + return (A) this; } + public java.lang.Boolean hasInsecureSkipTLSVerify() { return this.insecureSkipTLSVerify != null; } - + /** * This method has been deprecated, please use method buildService instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference getService() { - return this.service!=null ?this.service.build():null; + return this.service != null ? this.service.build() : null; } + public io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference buildService() { - return this.service!=null ?this.service.build():null; + return this.service != null ? this.service.build() : null; } - public A withService(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference service) { + + public A withService( + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference service) { _visitables.get("service").remove(this.service); - if (service!=null){ this.service= new io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceBuilder(service); _visitables.get("service").add(this.service);} return (A) this; + if (service != null) { + this.service = + new io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceBuilder(service); + _visitables.get("service").add(this.service); + } + return (A) this; } + public java.lang.Boolean hasService() { return this.service != null; } - public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested withNewService() { + + public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested + withNewService() { return new io.kubernetes.client.openapi.models.V1APIServiceSpecFluentImpl.ServiceNestedImpl(); } - public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested withNewServiceLike(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference item) { - return new io.kubernetes.client.openapi.models.V1APIServiceSpecFluentImpl.ServiceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested + withNewServiceLike( + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference item) { + return new io.kubernetes.client.openapi.models.V1APIServiceSpecFluentImpl.ServiceNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested editService() { return withNewServiceLike(getService()); } - public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested editOrNewService() { - return withNewServiceLike(getService() != null ? getService(): new io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested + editOrNewService() { + return withNewServiceLike( + getService() != null + ? getService() + : new io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested editOrNewServiceLike(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference item) { - return withNewServiceLike(getService() != null ? getService(): item); + + public io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested + editOrNewServiceLike( + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference item) { + return withNewServiceLike(getService() != null ? getService() : item); } + public java.lang.String getVersion() { return this.version; } + public A withVersion(java.lang.String version) { - this.version=version; return (A) this; + this.version = version; + return (A) this; } + public java.lang.Boolean hasVersion() { return this.version != null; } - - /** - * Method is deprecated. use withVersion instead. - */ + + /** Method is deprecated. use withVersion instead. */ @java.lang.Deprecated public A withNewVersion(java.lang.String original) { - return (A)withVersion(new String(original)); + return (A) withVersion(new String(original)); } + public java.lang.Integer getVersionPriority() { return this.versionPriority; } + public A withVersionPriority(java.lang.Integer versionPriority) { - this.versionPriority=versionPriority; return (A) this; + this.versionPriority = versionPriority; + return (A) this; } + public java.lang.Boolean hasVersionPriority() { return this.versionPriority != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1APIServiceSpecFluentImpl that = (V1APIServiceSpecFluentImpl) o; - if (caBundle != null ? !caBundle.equals(that.caBundle) :that.caBundle != null) return false; - if (group != null ? !group.equals(that.group) :that.group != null) return false; - if (groupPriorityMinimum != null ? !groupPriorityMinimum.equals(that.groupPriorityMinimum) :that.groupPriorityMinimum != null) return false; - if (insecureSkipTLSVerify != null ? !insecureSkipTLSVerify.equals(that.insecureSkipTLSVerify) :that.insecureSkipTLSVerify != null) return false; - if (service != null ? !service.equals(that.service) :that.service != null) return false; - if (version != null ? !version.equals(that.version) :that.version != null) return false; - if (versionPriority != null ? !versionPriority.equals(that.versionPriority) :that.versionPriority != null) return false; + if (caBundle != null ? !caBundle.equals(that.caBundle) : that.caBundle != null) return false; + if (group != null ? !group.equals(that.group) : that.group != null) return false; + if (groupPriorityMinimum != null + ? !groupPriorityMinimum.equals(that.groupPriorityMinimum) + : that.groupPriorityMinimum != null) return false; + if (insecureSkipTLSVerify != null + ? !insecureSkipTLSVerify.equals(that.insecureSkipTLSVerify) + : that.insecureSkipTLSVerify != null) return false; + if (service != null ? !service.equals(that.service) : that.service != null) return false; + if (version != null ? !version.equals(that.version) : that.version != null) return false; + if (versionPriority != null + ? !versionPriority.equals(that.versionPriority) + : that.versionPriority != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(caBundle, group, groupPriorityMinimum, insecureSkipTLSVerify, service, version, versionPriority, super.hashCode()); + return java.util.Objects.hash( + caBundle, + group, + groupPriorityMinimum, + insecureSkipTLSVerify, + service, + version, + versionPriority, + super.hashCode()); } - public class ServiceNestedImpl extends io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested,io.kubernetes.client.fluent.Nested{ + + public class ServiceNestedImpl + extends io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested> + implements io.kubernetes.client.openapi.models.V1APIServiceSpecFluent.ServiceNested, + io.kubernetes.client.fluent.Nested { ServiceNestedImpl(io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReference item) { - this.builder = new io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceBuilder( + this, item); } + ServiceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceBuilder(this); } + io.kubernetes.client.openapi.models.ApiregistrationV1ServiceReferenceBuilder builder; + public N and() { return (N) V1APIServiceSpecFluentImpl.this.withService(builder.build()); } + public N endService() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceStatusBuilder.java index 03b4d08aec..d66992cd27 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceStatusBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1APIServiceStatusBuilder extends io.kubernetes.client.openapi.models.V1APIServiceStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1APIServiceStatusBuilder + extends io.kubernetes.client.openapi.models.V1APIServiceStatusFluentImpl< + io.kubernetes.client.openapi.models.V1APIServiceStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1APIServiceStatus, + io.kubernetes.client.openapi.models.V1APIServiceStatusBuilder> { public V1APIServiceStatusBuilder() { this(false); } + public V1APIServiceStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1APIServiceStatus(), validationEnabled); } - public V1APIServiceStatusBuilder(io.kubernetes.client.openapi.models.V1APIServiceStatusFluent fluent) { + + public V1APIServiceStatusBuilder( + io.kubernetes.client.openapi.models.V1APIServiceStatusFluent fluent) { this(fluent, false); } - public V1APIServiceStatusBuilder(io.kubernetes.client.openapi.models.V1APIServiceStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1APIServiceStatusBuilder( + io.kubernetes.client.openapi.models.V1APIServiceStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1APIServiceStatus(), validationEnabled); } - public V1APIServiceStatusBuilder(io.kubernetes.client.openapi.models.V1APIServiceStatusFluent fluent,io.kubernetes.client.openapi.models.V1APIServiceStatus instance) { + + public V1APIServiceStatusBuilder( + io.kubernetes.client.openapi.models.V1APIServiceStatusFluent fluent, + io.kubernetes.client.openapi.models.V1APIServiceStatus instance) { this(fluent, instance, false); } - public V1APIServiceStatusBuilder(io.kubernetes.client.openapi.models.V1APIServiceStatusFluent fluent,io.kubernetes.client.openapi.models.V1APIServiceStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1APIServiceStatusBuilder( + io.kubernetes.client.openapi.models.V1APIServiceStatusFluent fluent, + io.kubernetes.client.openapi.models.V1APIServiceStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditions(instance.getConditions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1APIServiceStatusBuilder(io.kubernetes.client.openapi.models.V1APIServiceStatus instance) { - this(instance,false); + + public V1APIServiceStatusBuilder( + io.kubernetes.client.openapi.models.V1APIServiceStatus instance) { + this(instance, false); } - public V1APIServiceStatusBuilder(io.kubernetes.client.openapi.models.V1APIServiceStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1APIServiceStatusBuilder( + io.kubernetes.client.openapi.models.V1APIServiceStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditions(instance.getConditions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1APIServiceStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1APIServiceStatus build() { V1APIServiceStatus buildable = new V1APIServiceStatus(); buildable.setConditions(fluent.getConditions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1APIServiceStatusBuilder that = (V1APIServiceStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceStatusFluent.java index 73fa52ec0c..9cfc79a2a1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceStatusFluent.java @@ -1,57 +1,105 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1APIServiceStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIServiceCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIServiceCondition item); +/** Generated */ +public interface V1APIServiceStatusFluent< + A extends io.kubernetes.client.openapi.models.V1APIServiceStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIServiceCondition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIServiceCondition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1APIServiceCondition... items); - public A addAllToConditions(java.util.Collection items); + + public A addAllToConditions( + java.util.Collection items); + public A removeFromConditions(io.kubernetes.client.openapi.models.V1APIServiceCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1APIServiceCondition buildCondition(java.lang.Integer index); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V1APIServiceCondition buildCondition( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1APIServiceCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1APIServiceCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1APIServiceCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); + + public io.kubernetes.client.openapi.models.V1APIServiceCondition buildMatchingCondition( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate); + + public A withConditions( + java.util.List conditions); + public A withConditions(io.kubernetes.client.openapi.models.V1APIServiceCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1APIServiceCondition item); - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIServiceCondition item); - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1APIServiceConditionFluent>{ + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1APIServiceCondition item); + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIServiceCondition item); + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder> + predicate); + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1APIServiceConditionFluent< + io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceStatusFluentImpl.java index 2ccb6160de..8c2d329d6a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIServiceStatusFluentImpl.java @@ -1,57 +1,136 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1APIServiceStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1APIServiceStatusFluent{ - public V1APIServiceStatusFluentImpl() { - } - public V1APIServiceStatusFluentImpl(io.kubernetes.client.openapi.models.V1APIServiceStatus instance) { - this.withConditions(instance.getConditions()); +/** Generated */ +public class V1APIServiceStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1APIServiceStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1APIServiceStatusFluent { + public V1APIServiceStatusFluentImpl() {} + public V1APIServiceStatusFluentImpl( + io.kubernetes.client.openapi.models.V1APIServiceStatus instance) { + this.withConditions(instance.getConditions()); } - private java.util.ArrayList conditions; - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIServiceCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder = new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + private java.util.ArrayList + conditions; + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIServiceCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIServiceCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder = new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIServiceCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } + public A addToConditions(io.kubernetes.client.openapi.models.V1APIServiceCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1APIServiceCondition item : items) {io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder = new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1APIServiceCondition item : items) { + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1APIServiceCondition item : items) {io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder = new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1APIServiceCondition item : items) { + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V1APIServiceCondition... items) { - for (io.kubernetes.client.openapi.models.V1APIServiceCondition item : items) {io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder = new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1APIServiceCondition... items) { + for (io.kubernetes.client.openapi.models.V1APIServiceCondition item : items) { + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1APIServiceCondition item : items) {io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder = new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1APIServiceCondition item : items) { + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder = each.next(); @@ -60,104 +139,186 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1APIServiceCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1APIServiceCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1APIServiceCondition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1APIServiceCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1APIServiceCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1APIServiceCondition buildMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1APIServiceCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1APIServiceCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } + public A withConditions(io.kubernetes.client.openapi.models.V1APIServiceCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1APIServiceCondition item :conditions){ this.addToConditions(item);}} return (A) this; + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1APIServiceCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1APIServiceStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1APIServiceStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1APIServiceCondition item) { - return new io.kubernetes.client.openapi.models.V1APIServiceStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1APIServiceCondition item) { + return new io.kubernetes.client.openapi.models.V1APIServiceStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIServiceCondition item) { - return new io.kubernetes.client.openapi.models.V1APIServiceStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIServiceCondition item) { + return new io.kubernetes.client.openapi.models.V1APIServiceStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1APIServiceConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1APIServiceCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1APIServiceConditionFluentImpl< + io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1APIServiceStatusFluent.ConditionsNested, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1APIServiceCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1APIServiceConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1APIServiceStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1APIServiceStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIVersionsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIVersionsBuilder.java index 3d93a49633..d3b07034a4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIVersionsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIVersionsBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1APIVersionsBuilder extends io.kubernetes.client.openapi.models.V1APIVersionsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1APIVersionsBuilder + extends io.kubernetes.client.openapi.models.V1APIVersionsFluentImpl< + io.kubernetes.client.openapi.models.V1APIVersionsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1APIVersions, + io.kubernetes.client.openapi.models.V1APIVersionsBuilder> { public V1APIVersionsBuilder() { this(false); } + public V1APIVersionsBuilder(java.lang.Boolean validationEnabled) { this(new V1APIVersions(), validationEnabled); } + public V1APIVersionsBuilder(io.kubernetes.client.openapi.models.V1APIVersionsFluent fluent) { this(fluent, false); } - public V1APIVersionsBuilder(io.kubernetes.client.openapi.models.V1APIVersionsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1APIVersionsBuilder( + io.kubernetes.client.openapi.models.V1APIVersionsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1APIVersions(), validationEnabled); } - public V1APIVersionsBuilder(io.kubernetes.client.openapi.models.V1APIVersionsFluent fluent,io.kubernetes.client.openapi.models.V1APIVersions instance) { + + public V1APIVersionsBuilder( + io.kubernetes.client.openapi.models.V1APIVersionsFluent fluent, + io.kubernetes.client.openapi.models.V1APIVersions instance) { this(fluent, instance, false); } - public V1APIVersionsBuilder(io.kubernetes.client.openapi.models.V1APIVersionsFluent fluent,io.kubernetes.client.openapi.models.V1APIVersions instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1APIVersionsBuilder( + io.kubernetes.client.openapi.models.V1APIVersionsFluent fluent, + io.kubernetes.client.openapi.models.V1APIVersions instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +55,17 @@ public V1APIVersionsBuilder(io.kubernetes.client.openapi.models.V1APIVersionsFlu fluent.withVersions(instance.getVersions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1APIVersionsBuilder(io.kubernetes.client.openapi.models.V1APIVersions instance) { - this(instance,false); + this(instance, false); } - public V1APIVersionsBuilder(io.kubernetes.client.openapi.models.V1APIVersions instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1APIVersionsBuilder( + io.kubernetes.client.openapi.models.V1APIVersions instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +74,12 @@ public V1APIVersionsBuilder(io.kubernetes.client.openapi.models.V1APIVersions in this.withVersions(instance.getVersions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1APIVersionsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1APIVersions build() { V1APIVersions buildable = new V1APIVersions(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1APIVersions build() { buildable.setVersions(fluent.getVersions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1APIVersionsBuilder that = (V1APIVersionsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIVersionsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIVersionsFluent.java index 7b3f3ae266..979a837110 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIVersionsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIVersionsFluent.java @@ -1,91 +1,177 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1APIVersionsFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1APIVersionsFluent< + A extends io.kubernetes.client.openapi.models.V1APIVersionsFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - public A addToServerAddressByClientCIDRs(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); - public A setToServerAddressByClientCIDRs(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); - public A addToServerAddressByClientCIDRs(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items); - public A addAllToServerAddressByClientCIDRs(java.util.Collection items); - public A removeFromServerAddressByClientCIDRs(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items); - public A removeAllFromServerAddressByClientCIDRs(java.util.Collection items); - public A removeMatchingFromServerAddressByClientCIDRs(java.util.function.Predicate predicate); - + + public A addToServerAddressByClientCIDRs( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); + + public A setToServerAddressByClientCIDRs( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); + + public A addToServerAddressByClientCIDRs( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items); + + public A addAllToServerAddressByClientCIDRs( + java.util.Collection items); + + public A removeFromServerAddressByClientCIDRs( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items); + + public A removeAllFromServerAddressByClientCIDRs( + java.util.Collection items); + + public A removeMatchingFromServerAddressByClientCIDRs( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate); + /** * This method has been deprecated, please use method buildServerAddressByClientCIDRs instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getServerAddressByClientCIDRs(); - public java.util.List buildServerAddressByClientCIDRs(); - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildServerAddressByClientCIDR(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildFirstServerAddressByClientCIDR(); - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildLastServerAddressByClientCIDR(); - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildMatchingServerAddressByClientCIDR(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingServerAddressByClientCIDR(java.util.function.Predicate predicate); - public A withServerAddressByClientCIDRs(java.util.List serverAddressByClientCIDRs); - public A withServerAddressByClientCIDRs(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... serverAddressByClientCIDRs); + public java.util.List + getServerAddressByClientCIDRs(); + + public java.util.List + buildServerAddressByClientCIDRs(); + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildServerAddressByClientCIDR(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildFirstServerAddressByClientCIDR(); + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildLastServerAddressByClientCIDR(); + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildMatchingServerAddressByClientCIDR( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate); + + public java.lang.Boolean hasMatchingServerAddressByClientCIDR( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate); + + public A withServerAddressByClientCIDRs( + java.util.List + serverAddressByClientCIDRs); + + public A withServerAddressByClientCIDRs( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... + serverAddressByClientCIDRs); + public java.lang.Boolean hasServerAddressByClientCIDRs(); - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested addNewServerAddressByClientCIDR(); - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested addNewServerAddressByClientCIDRLike(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested setNewServerAddressByClientCIDRLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested editServerAddressByClientCIDR(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested editFirstServerAddressByClientCIDR(); - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested editLastServerAddressByClientCIDR(); - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested editMatchingServerAddressByClientCIDR(java.util.function.Predicate predicate); - public A addToVersions(java.lang.Integer index,java.lang.String item); - public A setToVersions(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + addNewServerAddressByClientCIDR(); + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + addNewServerAddressByClientCIDRLike( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + setNewServerAddressByClientCIDRLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item); + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + editServerAddressByClientCIDR(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + editFirstServerAddressByClientCIDR(); + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + editLastServerAddressByClientCIDR(); + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + editMatchingServerAddressByClientCIDR( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate); + + public A addToVersions(java.lang.Integer index, java.lang.String item); + + public A setToVersions(java.lang.Integer index, java.lang.String item); + public A addToVersions(java.lang.String... items); + public A addAllToVersions(java.util.Collection items); + public A removeFromVersions(java.lang.String... items); + public A removeAllFromVersions(java.util.Collection items); + public java.util.List getVersions(); + public java.lang.String getVersion(java.lang.Integer index); + public java.lang.String getFirstVersion(); + public java.lang.String getLastVersion(); - public java.lang.String getMatchingVersion(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVersion(java.util.function.Predicate predicate); + + public java.lang.String getMatchingVersion( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingVersion( + java.util.function.Predicate predicate); + public A withVersions(java.util.List versions); + public A withVersions(java.lang.String... versions); + public java.lang.Boolean hasVersions(); + public A addNewVersion(java.lang.String original); - public interface ServerAddressByClientCIDRsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent>{ + + public interface ServerAddressByClientCIDRsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent< + io.kubernetes.client.openapi.models.V1APIVersionsFluent + .ServerAddressByClientCIDRsNested< + N>> { public N and(); + public N endServerAddressByClientCIDR(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIVersionsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIVersionsFluentImpl.java index 517f56ce9a..4b917bb23c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIVersionsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1APIVersionsFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1APIVersionsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1APIVersionsFluent{ - public V1APIVersionsFluentImpl() { - } +/** Generated */ +public class V1APIVersionsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1APIVersionsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1APIVersionsFluent { + public V1APIVersionsFluentImpl() {} + public V1APIVersionsFluentImpl(io.kubernetes.client.openapi.models.V1APIVersions instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,74 +30,159 @@ public V1APIVersionsFluentImpl(io.kubernetes.client.openapi.models.V1APIVersions this.withServerAddressByClientCIDRs(instance.getServerAddressByClientCIDRs()); this.withVersions(instance.getVersions()); - } + private java.lang.String apiVersion; private java.lang.String kind; - private java.util.ArrayList serverAddressByClientCIDRs; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + serverAddressByClientCIDRs; private java.util.List versions; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - public A addToServerAddressByClientCIDRs(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { - if (this.serverAddressByClientCIDRs == null) {this.serverAddressByClientCIDRs = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item);_visitables.get("serverAddressByClientCIDRs").add(index >= 0 ? index : _visitables.get("serverAddressByClientCIDRs").size(), builder);this.serverAddressByClientCIDRs.add(index >= 0 ? index : serverAddressByClientCIDRs.size(), builder); return (A)this; + + public A addToServerAddressByClientCIDRs( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { + if (this.serverAddressByClientCIDRs == null) { + this.serverAddressByClientCIDRs = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder>(); + } + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); + _visitables + .get("serverAddressByClientCIDRs") + .add(index >= 0 ? index : _visitables.get("serverAddressByClientCIDRs").size(), builder); + this.serverAddressByClientCIDRs.add( + index >= 0 ? index : serverAddressByClientCIDRs.size(), builder); + return (A) this; } - public A setToServerAddressByClientCIDRs(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { - if (this.serverAddressByClientCIDRs == null) {this.serverAddressByClientCIDRs = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); - if (index < 0 || index >= _visitables.get("serverAddressByClientCIDRs").size()) { _visitables.get("serverAddressByClientCIDRs").add(builder); } else { _visitables.get("serverAddressByClientCIDRs").set(index, builder);} - if (index < 0 || index >= serverAddressByClientCIDRs.size()) { serverAddressByClientCIDRs.add(builder); } else { serverAddressByClientCIDRs.set(index, builder);} - return (A)this; + + public A setToServerAddressByClientCIDRs( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { + if (this.serverAddressByClientCIDRs == null) { + this.serverAddressByClientCIDRs = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder>(); + } + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); + if (index < 0 || index >= _visitables.get("serverAddressByClientCIDRs").size()) { + _visitables.get("serverAddressByClientCIDRs").add(builder); + } else { + _visitables.get("serverAddressByClientCIDRs").set(index, builder); + } + if (index < 0 || index >= serverAddressByClientCIDRs.size()) { + serverAddressByClientCIDRs.add(builder); + } else { + serverAddressByClientCIDRs.set(index, builder); + } + return (A) this; } - public A addToServerAddressByClientCIDRs(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items) { - if (this.serverAddressByClientCIDRs == null) {this.serverAddressByClientCIDRs = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) {io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item);_visitables.get("serverAddressByClientCIDRs").add(builder);this.serverAddressByClientCIDRs.add(builder);} return (A)this; + + public A addToServerAddressByClientCIDRs( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items) { + if (this.serverAddressByClientCIDRs == null) { + this.serverAddressByClientCIDRs = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) { + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); + _visitables.get("serverAddressByClientCIDRs").add(builder); + this.serverAddressByClientCIDRs.add(builder); + } + return (A) this; } - public A addAllToServerAddressByClientCIDRs(java.util.Collection items) { - if (this.serverAddressByClientCIDRs == null) {this.serverAddressByClientCIDRs = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) {io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item);_visitables.get("serverAddressByClientCIDRs").add(builder);this.serverAddressByClientCIDRs.add(builder);} return (A)this; + + public A addAllToServerAddressByClientCIDRs( + java.util.Collection items) { + if (this.serverAddressByClientCIDRs == null) { + this.serverAddressByClientCIDRs = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) { + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); + _visitables.get("serverAddressByClientCIDRs").add(builder); + this.serverAddressByClientCIDRs.add(builder); + } + return (A) this; } - public A removeFromServerAddressByClientCIDRs(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items) { - for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) {io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item);_visitables.get("serverAddressByClientCIDRs").remove(builder);if (this.serverAddressByClientCIDRs != null) {this.serverAddressByClientCIDRs.remove(builder);}} return (A)this; + + public A removeFromServerAddressByClientCIDRs( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... items) { + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) { + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); + _visitables.get("serverAddressByClientCIDRs").remove(builder); + if (this.serverAddressByClientCIDRs != null) { + this.serverAddressByClientCIDRs.remove(builder); + } + } + return (A) this; } - public A removeAllFromServerAddressByClientCIDRs(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) {io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item);_visitables.get("serverAddressByClientCIDRs").remove(builder);if (this.serverAddressByClientCIDRs != null) {this.serverAddressByClientCIDRs.remove(builder);}} return (A)this; + + public A removeAllFromServerAddressByClientCIDRs( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : items) { + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(item); + _visitables.get("serverAddressByClientCIDRs").remove(builder); + if (this.serverAddressByClientCIDRs != null) { + this.serverAddressByClientCIDRs.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromServerAddressByClientCIDRs(java.util.function.Predicate predicate) { + + public A removeMatchingFromServerAddressByClientCIDRs( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate) { if (serverAddressByClientCIDRs == null) return (A) this; - final Iterator each = serverAddressByClientCIDRs.iterator(); + final Iterator each = + serverAddressByClientCIDRs.iterator(); final List visitables = _visitables.get("serverAddressByClientCIDRs"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder = each.next(); @@ -104,161 +191,337 @@ public A removeMatchingFromServerAddressByClientCIDRs(java.util.function.Predica each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildServerAddressByClientCIDRs instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getServerAddressByClientCIDRs() { + public java.util.List + getServerAddressByClientCIDRs() { return serverAddressByClientCIDRs != null ? build(serverAddressByClientCIDRs) : null; } - public java.util.List buildServerAddressByClientCIDRs() { + + public java.util.List + buildServerAddressByClientCIDRs() { return serverAddressByClientCIDRs != null ? build(serverAddressByClientCIDRs) : null; } - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildServerAddressByClientCIDR(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildServerAddressByClientCIDR(java.lang.Integer index) { return this.serverAddressByClientCIDRs.get(index).build(); } - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildFirstServerAddressByClientCIDR() { + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildFirstServerAddressByClientCIDR() { return this.serverAddressByClientCIDRs.get(0).build(); } - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildLastServerAddressByClientCIDR() { + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildLastServerAddressByClientCIDR() { return this.serverAddressByClientCIDRs.get(serverAddressByClientCIDRs.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR buildMatchingServerAddressByClientCIDR(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder item: serverAddressByClientCIDRs) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR + buildMatchingServerAddressByClientCIDR( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder item : + serverAddressByClientCIDRs) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingServerAddressByClientCIDR(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder item: serverAddressByClientCIDRs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingServerAddressByClientCIDR( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder item : + serverAddressByClientCIDRs) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withServerAddressByClientCIDRs(java.util.List serverAddressByClientCIDRs) { - if (this.serverAddressByClientCIDRs != null) { _visitables.get("serverAddressByClientCIDRs").removeAll(this.serverAddressByClientCIDRs);} - if (serverAddressByClientCIDRs != null) {this.serverAddressByClientCIDRs = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : serverAddressByClientCIDRs){this.addToServerAddressByClientCIDRs(item);}} else { this.serverAddressByClientCIDRs = null;} return (A) this; + + public A withServerAddressByClientCIDRs( + java.util.List + serverAddressByClientCIDRs) { + if (this.serverAddressByClientCIDRs != null) { + _visitables.get("serverAddressByClientCIDRs").removeAll(this.serverAddressByClientCIDRs); + } + if (serverAddressByClientCIDRs != null) { + this.serverAddressByClientCIDRs = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : + serverAddressByClientCIDRs) { + this.addToServerAddressByClientCIDRs(item); + } + } else { + this.serverAddressByClientCIDRs = null; + } + return (A) this; } - public A withServerAddressByClientCIDRs(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... serverAddressByClientCIDRs) { - if (this.serverAddressByClientCIDRs != null) {this.serverAddressByClientCIDRs.clear();} - if (serverAddressByClientCIDRs != null) {for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item :serverAddressByClientCIDRs){ this.addToServerAddressByClientCIDRs(item);}} return (A) this; + + public A withServerAddressByClientCIDRs( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR... + serverAddressByClientCIDRs) { + if (this.serverAddressByClientCIDRs != null) { + this.serverAddressByClientCIDRs.clear(); + } + if (serverAddressByClientCIDRs != null) { + for (io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item : + serverAddressByClientCIDRs) { + this.addToServerAddressByClientCIDRs(item); + } + } + return (A) this; } + public java.lang.Boolean hasServerAddressByClientCIDRs() { return serverAddressByClientCIDRs != null && !serverAddressByClientCIDRs.isEmpty(); } - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested addNewServerAddressByClientCIDR() { - return new io.kubernetes.client.openapi.models.V1APIVersionsFluentImpl.ServerAddressByClientCIDRsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + addNewServerAddressByClientCIDR() { + return new io.kubernetes.client.openapi.models.V1APIVersionsFluentImpl + .ServerAddressByClientCIDRsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested addNewServerAddressByClientCIDRLike(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { - return new io.kubernetes.client.openapi.models.V1APIVersionsFluentImpl.ServerAddressByClientCIDRsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + addNewServerAddressByClientCIDRLike( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { + return new io.kubernetes.client.openapi.models.V1APIVersionsFluentImpl + .ServerAddressByClientCIDRsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested setNewServerAddressByClientCIDRLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { - return new io.kubernetes.client.openapi.models.V1APIVersionsFluentImpl.ServerAddressByClientCIDRsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + setNewServerAddressByClientCIDRLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { + return new io.kubernetes.client.openapi.models.V1APIVersionsFluentImpl + .ServerAddressByClientCIDRsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested editServerAddressByClientCIDR(java.lang.Integer index) { - if (serverAddressByClientCIDRs.size() <= index) throw new RuntimeException("Can't edit serverAddressByClientCIDRs. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + editServerAddressByClientCIDR(java.lang.Integer index) { + if (serverAddressByClientCIDRs.size() <= index) + throw new RuntimeException("Can't edit serverAddressByClientCIDRs. Index exceeds size."); return setNewServerAddressByClientCIDRLike(index, buildServerAddressByClientCIDR(index)); } - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested editFirstServerAddressByClientCIDR() { - if (serverAddressByClientCIDRs.size() == 0) throw new RuntimeException("Can't edit first serverAddressByClientCIDRs. The list is empty."); + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + editFirstServerAddressByClientCIDR() { + if (serverAddressByClientCIDRs.size() == 0) + throw new RuntimeException("Can't edit first serverAddressByClientCIDRs. The list is empty."); return setNewServerAddressByClientCIDRLike(0, buildServerAddressByClientCIDR(0)); } - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested editLastServerAddressByClientCIDR() { + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + editLastServerAddressByClientCIDR() { int index = serverAddressByClientCIDRs.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last serverAddressByClientCIDRs. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last serverAddressByClientCIDRs. The list is empty."); return setNewServerAddressByClientCIDRLike(index, buildServerAddressByClientCIDR(index)); } - public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested editMatchingServerAddressByClientCIDR(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested + editMatchingServerAddressByClientCIDR( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + predicate) { int index = -1; - for (int i=0;i();} + + public A addToVersions(java.lang.Integer index, java.lang.String item) { + if (this.versions == null) { + this.versions = new java.util.ArrayList(); + } this.versions.add(index, item); - return (A)this; + return (A) this; } - public A setToVersions(java.lang.Integer index,java.lang.String item) { - if (this.versions == null) {this.versions = new java.util.ArrayList();} - this.versions.set(index, item); return (A)this; + + public A setToVersions(java.lang.Integer index, java.lang.String item) { + if (this.versions == null) { + this.versions = new java.util.ArrayList(); + } + this.versions.set(index, item); + return (A) this; } + public A addToVersions(java.lang.String... items) { - if (this.versions == null) {this.versions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.versions.add(item);} return (A)this; + if (this.versions == null) { + this.versions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.versions.add(item); + } + return (A) this; } + public A addAllToVersions(java.util.Collection items) { - if (this.versions == null) {this.versions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.versions.add(item);} return (A)this; + if (this.versions == null) { + this.versions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.versions.add(item); + } + return (A) this; } + public A removeFromVersions(java.lang.String... items) { - for (java.lang.String item : items) {if (this.versions!= null){ this.versions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.versions != null) { + this.versions.remove(item); + } + } + return (A) this; } + public A removeAllFromVersions(java.util.Collection items) { - for (java.lang.String item : items) {if (this.versions!= null){ this.versions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.versions != null) { + this.versions.remove(item); + } + } + return (A) this; } + public java.util.List getVersions() { return this.versions; } + public java.lang.String getVersion(java.lang.Integer index) { return this.versions.get(index); } + public java.lang.String getFirstVersion() { return this.versions.get(0); } + public java.lang.String getLastVersion() { return this.versions.get(versions.size() - 1); } - public java.lang.String getMatchingVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: versions) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : versions) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: versions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : versions) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withVersions(java.util.List versions) { - if (versions != null) {this.versions = new java.util.ArrayList(); for (java.lang.String item : versions){this.addToVersions(item);}} else { this.versions = null;} return (A) this; + if (versions != null) { + this.versions = new java.util.ArrayList(); + for (java.lang.String item : versions) { + this.addToVersions(item); + } + } else { + this.versions = null; + } + return (A) this; } + public A withVersions(java.lang.String... versions) { - if (this.versions != null) {this.versions.clear();} - if (versions != null) {for (java.lang.String item :versions){ this.addToVersions(item);}} return (A) this; + if (this.versions != null) { + this.versions.clear(); + } + if (versions != null) { + for (java.lang.String item : versions) { + this.addToVersions(item); + } + } + return (A) this; } + public java.lang.Boolean hasVersions() { return versions != null && !versions.isEmpty(); } + public A addNewVersion(java.lang.String original) { - return (A)addToVersions(new String(original)); + return (A) addToVersions(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1APIVersionsFluentImpl that = (V1APIVersionsFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (serverAddressByClientCIDRs != null ? !serverAddressByClientCIDRs.equals(that.serverAddressByClientCIDRs) :that.serverAddressByClientCIDRs != null) return false; - if (versions != null ? !versions.equals(that.versions) :that.versions != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (serverAddressByClientCIDRs != null + ? !serverAddressByClientCIDRs.equals(that.serverAddressByClientCIDRs) + : that.serverAddressByClientCIDRs != null) return false; + if (versions != null ? !versions.equals(that.versions) : that.versions != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, serverAddressByClientCIDRs, versions, super.hashCode()); + return java.util.Objects.hash( + apiVersion, kind, serverAddressByClientCIDRs, versions, super.hashCode()); } - public class ServerAddressByClientCIDRsNestedImpl extends io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluentImpl> implements io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested,io.kubernetes.client.fluent.Nested{ - ServerAddressByClientCIDRsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { + + public class ServerAddressByClientCIDRsNestedImpl + extends io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluentImpl< + io.kubernetes.client.openapi.models.V1APIVersionsFluent.ServerAddressByClientCIDRsNested< + N>> + implements io.kubernetes.client.openapi.models.V1APIVersionsFluent + .ServerAddressByClientCIDRsNested< + N>, + io.kubernetes.client.fluent.Nested { + ServerAddressByClientCIDRsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(this, item); } + ServerAddressByClientCIDRsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder(this); } + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1APIVersionsFluentImpl.this.setToServerAddressByClientCIDRs(index,builder.build()); + return (N) + V1APIVersionsFluentImpl.this.setToServerAddressByClientCIDRs(index, builder.build()); } + public N endServerAddressByClientCIDR() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AWSElasticBlockStoreVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AWSElasticBlockStoreVolumeSourceBuilder.java index 4ec615fc2f..600268af3d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AWSElasticBlockStoreVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AWSElasticBlockStoreVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1AWSElasticBlockStoreVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1AWSElasticBlockStoreVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource, + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder> { public V1AWSElasticBlockStoreVolumeSourceBuilder() { this(false); } + public V1AWSElasticBlockStoreVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1AWSElasticBlockStoreVolumeSource(), validationEnabled); } - public V1AWSElasticBlockStoreVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent fluent) { + + public V1AWSElasticBlockStoreVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent fluent) { this(fluent, false); } - public V1AWSElasticBlockStoreVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1AWSElasticBlockStoreVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1AWSElasticBlockStoreVolumeSource(), validationEnabled); } - public V1AWSElasticBlockStoreVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource instance) { + + public V1AWSElasticBlockStoreVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource instance) { this(fluent, instance, false); } - public V1AWSElasticBlockStoreVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1AWSElasticBlockStoreVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withPartition(instance.getPartition()); @@ -29,13 +56,18 @@ public V1AWSElasticBlockStoreVolumeSourceBuilder(io.kubernetes.client.openapi.mo fluent.withVolumeID(instance.getVolumeID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1AWSElasticBlockStoreVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource instance) { - this(instance,false); + + public V1AWSElasticBlockStoreVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource instance) { + this(instance, false); } - public V1AWSElasticBlockStoreVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1AWSElasticBlockStoreVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withPartition(instance.getPartition()); @@ -44,10 +76,12 @@ public V1AWSElasticBlockStoreVolumeSourceBuilder(io.kubernetes.client.openapi.mo this.withVolumeID(instance.getVolumeID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource build() { V1AWSElasticBlockStoreVolumeSource buildable = new V1AWSElasticBlockStoreVolumeSource(); buildable.setFsType(fluent.getFsType()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource bu buildable.setVolumeID(fluent.getVolumeID()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1AWSElasticBlockStoreVolumeSourceBuilder that = (V1AWSElasticBlockStoreVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AWSElasticBlockStoreVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AWSElasticBlockStoreVolumeSourceFluent.java index 112e19cded..75ba38089b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AWSElasticBlockStoreVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AWSElasticBlockStoreVolumeSourceFluent.java @@ -1,39 +1,50 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1AWSElasticBlockStoreVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1AWSElasticBlockStoreVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.Integer getPartition(); + public A withPartition(java.lang.Integer partition); + public java.lang.Boolean hasPartition(); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); + public java.lang.String getVolumeID(); + public A withVolumeID(java.lang.String volumeID); + public java.lang.Boolean hasVolumeID(); - - /** - * Method is deprecated. use withVolumeID instead. - */ + + /** Method is deprecated. use withVolumeID instead. */ @java.lang.Deprecated public A withNewVolumeID(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AWSElasticBlockStoreVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AWSElasticBlockStoreVolumeSourceFluentImpl.java index 20d270bf04..72aaad55ba 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AWSElasticBlockStoreVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AWSElasticBlockStoreVolumeSourceFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1AWSElasticBlockStoreVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent { + public V1AWSElasticBlockStoreVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1AWSElasticBlockStoreVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent{ - public V1AWSElasticBlockStoreVolumeSourceFluentImpl() { - } - public V1AWSElasticBlockStoreVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource instance) { + public V1AWSElasticBlockStoreVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource instance) { this.withFsType(instance.getFsType()); this.withPartition(instance.getPartition()); @@ -21,76 +28,91 @@ public V1AWSElasticBlockStoreVolumeSourceFluentImpl(io.kubernetes.client.openapi this.withReadOnly(instance.getReadOnly()); this.withVolumeID(instance.getVolumeID()); - } + private java.lang.String fsType; private java.lang.Integer partition; private java.lang.Boolean readOnly; private java.lang.String volumeID; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.Integer getPartition() { return this.partition; } + public A withPartition(java.lang.Integer partition) { - this.partition=partition; return (A) this; + this.partition = partition; + return (A) this; } + public java.lang.Boolean hasPartition() { return this.partition != null; } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public java.lang.String getVolumeID() { return this.volumeID; } + public A withVolumeID(java.lang.String volumeID) { - this.volumeID=volumeID; return (A) this; + this.volumeID = volumeID; + return (A) this; } + public java.lang.Boolean hasVolumeID() { return this.volumeID != null; } - - /** - * Method is deprecated. use withVolumeID instead. - */ + + /** Method is deprecated. use withVolumeID instead. */ @java.lang.Deprecated public A withNewVolumeID(java.lang.String original) { - return (A)withVolumeID(new String(original)); + return (A) withVolumeID(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1AWSElasticBlockStoreVolumeSourceFluentImpl that = (V1AWSElasticBlockStoreVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (partition != null ? !partition.equals(that.partition) :that.partition != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (volumeID != null ? !volumeID.equals(that.volumeID) :that.volumeID != null) return false; + V1AWSElasticBlockStoreVolumeSourceFluentImpl that = + (V1AWSElasticBlockStoreVolumeSourceFluentImpl) o; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (partition != null ? !partition.equals(that.partition) : that.partition != null) + return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (volumeID != null ? !volumeID.equals(that.volumeID) : that.volumeID != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, partition, readOnly, volumeID, super.hashCode()); + return java.util.Objects.hash(fsType, partition, readOnly, volumeID, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AffinityBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AffinityBuilder.java index 541c17b07e..6fcdb6ec6b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AffinityBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AffinityBuilder.java @@ -1,49 +1,81 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1AffinityBuilder extends io.kubernetes.client.openapi.models.V1AffinityFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1AffinityBuilder + extends io.kubernetes.client.openapi.models.V1AffinityFluentImpl< + io.kubernetes.client.openapi.models.V1AffinityBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Affinity, + io.kubernetes.client.openapi.models.V1AffinityBuilder> { public V1AffinityBuilder() { this(false); } + public V1AffinityBuilder(java.lang.Boolean validationEnabled) { this(new V1Affinity(), validationEnabled); } + public V1AffinityBuilder(io.kubernetes.client.openapi.models.V1AffinityFluent fluent) { this(fluent, false); } - public V1AffinityBuilder(io.kubernetes.client.openapi.models.V1AffinityFluent fluent,java.lang.Boolean validationEnabled) { + + public V1AffinityBuilder( + io.kubernetes.client.openapi.models.V1AffinityFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Affinity(), validationEnabled); } - public V1AffinityBuilder(io.kubernetes.client.openapi.models.V1AffinityFluent fluent,io.kubernetes.client.openapi.models.V1Affinity instance) { + + public V1AffinityBuilder( + io.kubernetes.client.openapi.models.V1AffinityFluent fluent, + io.kubernetes.client.openapi.models.V1Affinity instance) { this(fluent, instance, false); } - public V1AffinityBuilder(io.kubernetes.client.openapi.models.V1AffinityFluent fluent,io.kubernetes.client.openapi.models.V1Affinity instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1AffinityBuilder( + io.kubernetes.client.openapi.models.V1AffinityFluent fluent, + io.kubernetes.client.openapi.models.V1Affinity instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNodeAffinity(instance.getNodeAffinity()); fluent.withPodAffinity(instance.getPodAffinity()); fluent.withPodAntiAffinity(instance.getPodAntiAffinity()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1AffinityBuilder(io.kubernetes.client.openapi.models.V1Affinity instance) { - this(instance,false); + this(instance, false); } - public V1AffinityBuilder(io.kubernetes.client.openapi.models.V1Affinity instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1AffinityBuilder( + io.kubernetes.client.openapi.models.V1Affinity instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNodeAffinity(instance.getNodeAffinity()); this.withPodAffinity(instance.getPodAffinity()); this.withPodAntiAffinity(instance.getPodAntiAffinity()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1AffinityFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Affinity build() { V1Affinity buildable = new V1Affinity(); buildable.setNodeAffinity(fluent.getNodeAffinity()); @@ -51,18 +83,23 @@ public io.kubernetes.client.openapi.models.V1Affinity build() { buildable.setPodAntiAffinity(fluent.getPodAntiAffinity()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1AffinityBuilder that = (V1AffinityBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AffinityFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AffinityFluent.java index 5ee2280168..555268a434 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AffinityFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AffinityFluent.java @@ -1,75 +1,133 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1AffinityFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1AffinityFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildNodeAffinity instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeAffinity getNodeAffinity(); + public io.kubernetes.client.openapi.models.V1NodeAffinity buildNodeAffinity(); + public A withNodeAffinity(io.kubernetes.client.openapi.models.V1NodeAffinity nodeAffinity); + public java.lang.Boolean hasNodeAffinity(); - public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested withNewNodeAffinity(); - public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested withNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1NodeAffinity item); - public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested editNodeAffinity(); - public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested editOrNewNodeAffinity(); - public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested editOrNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1NodeAffinity item); - + + public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested + withNewNodeAffinity(); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested + withNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1NodeAffinity item); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested + editNodeAffinity(); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested + editOrNewNodeAffinity(); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested + editOrNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1NodeAffinity item); + /** * This method has been deprecated, please use method buildPodAffinity instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodAffinity getPodAffinity(); + public io.kubernetes.client.openapi.models.V1PodAffinity buildPodAffinity(); + public A withPodAffinity(io.kubernetes.client.openapi.models.V1PodAffinity podAffinity); + public java.lang.Boolean hasPodAffinity(); - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested withNewPodAffinity(); - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested withNewPodAffinityLike(io.kubernetes.client.openapi.models.V1PodAffinity item); - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested editPodAffinity(); - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested editOrNewPodAffinity(); - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested editOrNewPodAffinityLike(io.kubernetes.client.openapi.models.V1PodAffinity item); - + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested + withNewPodAffinity(); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested + withNewPodAffinityLike(io.kubernetes.client.openapi.models.V1PodAffinity item); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested + editPodAffinity(); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested + editOrNewPodAffinity(); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested + editOrNewPodAffinityLike(io.kubernetes.client.openapi.models.V1PodAffinity item); + /** * This method has been deprecated, please use method buildPodAntiAffinity instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodAntiAffinity getPodAntiAffinity(); + public io.kubernetes.client.openapi.models.V1PodAntiAffinity buildPodAntiAffinity(); - public A withPodAntiAffinity(io.kubernetes.client.openapi.models.V1PodAntiAffinity podAntiAffinity); + + public A withPodAntiAffinity( + io.kubernetes.client.openapi.models.V1PodAntiAffinity podAntiAffinity); + public java.lang.Boolean hasPodAntiAffinity(); - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested withNewPodAntiAffinity(); - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested withNewPodAntiAffinityLike(io.kubernetes.client.openapi.models.V1PodAntiAffinity item); - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested editPodAntiAffinity(); - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested editOrNewPodAntiAffinity(); - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested editOrNewPodAntiAffinityLike(io.kubernetes.client.openapi.models.V1PodAntiAffinity item); - public interface NodeAffinityNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeAffinityFluent>{ + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested + withNewPodAntiAffinity(); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested + withNewPodAntiAffinityLike(io.kubernetes.client.openapi.models.V1PodAntiAffinity item); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested + editPodAntiAffinity(); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested + editOrNewPodAntiAffinity(); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested + editOrNewPodAntiAffinityLike(io.kubernetes.client.openapi.models.V1PodAntiAffinity item); + + public interface NodeAffinityNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeAffinityFluent< + io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested> { public N and(); + public N endNodeAffinity(); - } - public interface PodAffinityNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodAffinityFluent>{ + + public interface PodAffinityNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodAffinityFluent< + io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested> { public N and(); + public N endPodAffinity(); - } - public interface PodAntiAffinityNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent>{ + + public interface PodAntiAffinityNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent< + io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested> { public N and(); + public N endPodAntiAffinity(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AffinityFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AffinityFluentImpl.java index 2f9c719076..4c7eeb51ac 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AffinityFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AffinityFluentImpl.java @@ -1,189 +1,292 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1AffinityFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1AffinityFluent { + public V1AffinityFluentImpl() {} - /** - * Generated - */ -public class V1AffinityFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1AffinityFluent{ - public V1AffinityFluentImpl() { - } public V1AffinityFluentImpl(io.kubernetes.client.openapi.models.V1Affinity instance) { this.withNodeAffinity(instance.getNodeAffinity()); this.withPodAffinity(instance.getPodAffinity()); this.withPodAntiAffinity(instance.getPodAntiAffinity()); - } + private io.kubernetes.client.openapi.models.V1NodeAffinityBuilder nodeAffinity; private io.kubernetes.client.openapi.models.V1PodAffinityBuilder podAffinity; private io.kubernetes.client.openapi.models.V1PodAntiAffinityBuilder podAntiAffinity; - + /** * This method has been deprecated, please use method buildNodeAffinity instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeAffinity getNodeAffinity() { - return this.nodeAffinity!=null ?this.nodeAffinity.build():null; + return this.nodeAffinity != null ? this.nodeAffinity.build() : null; } + public io.kubernetes.client.openapi.models.V1NodeAffinity buildNodeAffinity() { - return this.nodeAffinity!=null ?this.nodeAffinity.build():null; + return this.nodeAffinity != null ? this.nodeAffinity.build() : null; } + public A withNodeAffinity(io.kubernetes.client.openapi.models.V1NodeAffinity nodeAffinity) { _visitables.get("nodeAffinity").remove(this.nodeAffinity); - if (nodeAffinity!=null){ this.nodeAffinity= new io.kubernetes.client.openapi.models.V1NodeAffinityBuilder(nodeAffinity); _visitables.get("nodeAffinity").add(this.nodeAffinity);} return (A) this; + if (nodeAffinity != null) { + this.nodeAffinity = + new io.kubernetes.client.openapi.models.V1NodeAffinityBuilder(nodeAffinity); + _visitables.get("nodeAffinity").add(this.nodeAffinity); + } + return (A) this; } + public java.lang.Boolean hasNodeAffinity() { return this.nodeAffinity != null; } - public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested withNewNodeAffinity() { + + public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested + withNewNodeAffinity() { return new io.kubernetes.client.openapi.models.V1AffinityFluentImpl.NodeAffinityNestedImpl(); } - public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested withNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1NodeAffinity item) { - return new io.kubernetes.client.openapi.models.V1AffinityFluentImpl.NodeAffinityNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested + withNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1NodeAffinity item) { + return new io.kubernetes.client.openapi.models.V1AffinityFluentImpl.NodeAffinityNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested editNodeAffinity() { + + public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested + editNodeAffinity() { return withNewNodeAffinityLike(getNodeAffinity()); } - public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested editOrNewNodeAffinity() { - return withNewNodeAffinityLike(getNodeAffinity() != null ? getNodeAffinity(): new io.kubernetes.client.openapi.models.V1NodeAffinityBuilder().build()); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested + editOrNewNodeAffinity() { + return withNewNodeAffinityLike( + getNodeAffinity() != null + ? getNodeAffinity() + : new io.kubernetes.client.openapi.models.V1NodeAffinityBuilder().build()); } - public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested editOrNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1NodeAffinity item) { - return withNewNodeAffinityLike(getNodeAffinity() != null ? getNodeAffinity(): item); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested + editOrNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1NodeAffinity item) { + return withNewNodeAffinityLike(getNodeAffinity() != null ? getNodeAffinity() : item); } - + /** * This method has been deprecated, please use method buildPodAffinity instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodAffinity getPodAffinity() { - return this.podAffinity!=null ?this.podAffinity.build():null; + return this.podAffinity != null ? this.podAffinity.build() : null; } + public io.kubernetes.client.openapi.models.V1PodAffinity buildPodAffinity() { - return this.podAffinity!=null ?this.podAffinity.build():null; + return this.podAffinity != null ? this.podAffinity.build() : null; } + public A withPodAffinity(io.kubernetes.client.openapi.models.V1PodAffinity podAffinity) { _visitables.get("podAffinity").remove(this.podAffinity); - if (podAffinity!=null){ this.podAffinity= new io.kubernetes.client.openapi.models.V1PodAffinityBuilder(podAffinity); _visitables.get("podAffinity").add(this.podAffinity);} return (A) this; + if (podAffinity != null) { + this.podAffinity = new io.kubernetes.client.openapi.models.V1PodAffinityBuilder(podAffinity); + _visitables.get("podAffinity").add(this.podAffinity); + } + return (A) this; } + public java.lang.Boolean hasPodAffinity() { return this.podAffinity != null; } - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested withNewPodAffinity() { + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested + withNewPodAffinity() { return new io.kubernetes.client.openapi.models.V1AffinityFluentImpl.PodAffinityNestedImpl(); } - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested withNewPodAffinityLike(io.kubernetes.client.openapi.models.V1PodAffinity item) { + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested + withNewPodAffinityLike(io.kubernetes.client.openapi.models.V1PodAffinity item) { return new io.kubernetes.client.openapi.models.V1AffinityFluentImpl.PodAffinityNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested editPodAffinity() { + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested + editPodAffinity() { return withNewPodAffinityLike(getPodAffinity()); } - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested editOrNewPodAffinity() { - return withNewPodAffinityLike(getPodAffinity() != null ? getPodAffinity(): new io.kubernetes.client.openapi.models.V1PodAffinityBuilder().build()); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested + editOrNewPodAffinity() { + return withNewPodAffinityLike( + getPodAffinity() != null + ? getPodAffinity() + : new io.kubernetes.client.openapi.models.V1PodAffinityBuilder().build()); } - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested editOrNewPodAffinityLike(io.kubernetes.client.openapi.models.V1PodAffinity item) { - return withNewPodAffinityLike(getPodAffinity() != null ? getPodAffinity(): item); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested + editOrNewPodAffinityLike(io.kubernetes.client.openapi.models.V1PodAffinity item) { + return withNewPodAffinityLike(getPodAffinity() != null ? getPodAffinity() : item); } - + /** * This method has been deprecated, please use method buildPodAntiAffinity instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodAntiAffinity getPodAntiAffinity() { - return this.podAntiAffinity!=null ?this.podAntiAffinity.build():null; + return this.podAntiAffinity != null ? this.podAntiAffinity.build() : null; } + public io.kubernetes.client.openapi.models.V1PodAntiAffinity buildPodAntiAffinity() { - return this.podAntiAffinity!=null ?this.podAntiAffinity.build():null; + return this.podAntiAffinity != null ? this.podAntiAffinity.build() : null; } - public A withPodAntiAffinity(io.kubernetes.client.openapi.models.V1PodAntiAffinity podAntiAffinity) { + + public A withPodAntiAffinity( + io.kubernetes.client.openapi.models.V1PodAntiAffinity podAntiAffinity) { _visitables.get("podAntiAffinity").remove(this.podAntiAffinity); - if (podAntiAffinity!=null){ this.podAntiAffinity= new io.kubernetes.client.openapi.models.V1PodAntiAffinityBuilder(podAntiAffinity); _visitables.get("podAntiAffinity").add(this.podAntiAffinity);} return (A) this; + if (podAntiAffinity != null) { + this.podAntiAffinity = + new io.kubernetes.client.openapi.models.V1PodAntiAffinityBuilder(podAntiAffinity); + _visitables.get("podAntiAffinity").add(this.podAntiAffinity); + } + return (A) this; } + public java.lang.Boolean hasPodAntiAffinity() { return this.podAntiAffinity != null; } - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested withNewPodAntiAffinity() { + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested + withNewPodAntiAffinity() { return new io.kubernetes.client.openapi.models.V1AffinityFluentImpl.PodAntiAffinityNestedImpl(); } - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested withNewPodAntiAffinityLike(io.kubernetes.client.openapi.models.V1PodAntiAffinity item) { - return new io.kubernetes.client.openapi.models.V1AffinityFluentImpl.PodAntiAffinityNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested + withNewPodAntiAffinityLike(io.kubernetes.client.openapi.models.V1PodAntiAffinity item) { + return new io.kubernetes.client.openapi.models.V1AffinityFluentImpl.PodAntiAffinityNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested editPodAntiAffinity() { + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested + editPodAntiAffinity() { return withNewPodAntiAffinityLike(getPodAntiAffinity()); } - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested editOrNewPodAntiAffinity() { - return withNewPodAntiAffinityLike(getPodAntiAffinity() != null ? getPodAntiAffinity(): new io.kubernetes.client.openapi.models.V1PodAntiAffinityBuilder().build()); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested + editOrNewPodAntiAffinity() { + return withNewPodAntiAffinityLike( + getPodAntiAffinity() != null + ? getPodAntiAffinity() + : new io.kubernetes.client.openapi.models.V1PodAntiAffinityBuilder().build()); } - public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested editOrNewPodAntiAffinityLike(io.kubernetes.client.openapi.models.V1PodAntiAffinity item) { - return withNewPodAntiAffinityLike(getPodAntiAffinity() != null ? getPodAntiAffinity(): item); + + public io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested + editOrNewPodAntiAffinityLike(io.kubernetes.client.openapi.models.V1PodAntiAffinity item) { + return withNewPodAntiAffinityLike(getPodAntiAffinity() != null ? getPodAntiAffinity() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1AffinityFluentImpl that = (V1AffinityFluentImpl) o; - if (nodeAffinity != null ? !nodeAffinity.equals(that.nodeAffinity) :that.nodeAffinity != null) return false; - if (podAffinity != null ? !podAffinity.equals(that.podAffinity) :that.podAffinity != null) return false; - if (podAntiAffinity != null ? !podAntiAffinity.equals(that.podAntiAffinity) :that.podAntiAffinity != null) return false; + if (nodeAffinity != null ? !nodeAffinity.equals(that.nodeAffinity) : that.nodeAffinity != null) + return false; + if (podAffinity != null ? !podAffinity.equals(that.podAffinity) : that.podAffinity != null) + return false; + if (podAntiAffinity != null + ? !podAntiAffinity.equals(that.podAntiAffinity) + : that.podAntiAffinity != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(nodeAffinity, podAffinity, podAntiAffinity, super.hashCode()); + return java.util.Objects.hash(nodeAffinity, podAffinity, podAntiAffinity, super.hashCode()); } - public class NodeAffinityNestedImpl extends io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl> implements io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested,io.kubernetes.client.fluent.Nested{ + + public class NodeAffinityNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl< + io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested> + implements io.kubernetes.client.openapi.models.V1AffinityFluent.NodeAffinityNested, + io.kubernetes.client.fluent.Nested { NodeAffinityNestedImpl(io.kubernetes.client.openapi.models.V1NodeAffinity item) { this.builder = new io.kubernetes.client.openapi.models.V1NodeAffinityBuilder(this, item); } + NodeAffinityNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NodeAffinityBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeAffinityBuilder builder; + public N and() { return (N) V1AffinityFluentImpl.this.withNodeAffinity(builder.build()); } + public N endNodeAffinity() { return and(); } - } - public class PodAffinityNestedImpl extends io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl> implements io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested,io.kubernetes.client.fluent.Nested{ + + public class PodAffinityNestedImpl + extends io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl< + io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested> + implements io.kubernetes.client.openapi.models.V1AffinityFluent.PodAffinityNested, + io.kubernetes.client.fluent.Nested { PodAffinityNestedImpl(io.kubernetes.client.openapi.models.V1PodAffinity item) { this.builder = new io.kubernetes.client.openapi.models.V1PodAffinityBuilder(this, item); } + PodAffinityNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodAffinityBuilder(this); } + io.kubernetes.client.openapi.models.V1PodAffinityBuilder builder; + public N and() { return (N) V1AffinityFluentImpl.this.withPodAffinity(builder.build()); } + public N endPodAffinity() { return and(); } - } - public class PodAntiAffinityNestedImpl extends io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl> implements io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested,io.kubernetes.client.fluent.Nested{ + + public class PodAntiAffinityNestedImpl + extends io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl< + io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested> + implements io.kubernetes.client.openapi.models.V1AffinityFluent.PodAntiAffinityNested, + io.kubernetes.client.fluent.Nested { PodAntiAffinityNestedImpl(io.kubernetes.client.openapi.models.V1PodAntiAffinity item) { this.builder = new io.kubernetes.client.openapi.models.V1PodAntiAffinityBuilder(this, item); } + PodAntiAffinityNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodAntiAffinityBuilder(this); } + io.kubernetes.client.openapi.models.V1PodAntiAffinityBuilder builder; + public N and() { return (N) V1AffinityFluentImpl.this.withPodAntiAffinity(builder.build()); } + public N endPodAntiAffinity() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AggregationRuleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AggregationRuleBuilder.java index 643ce8cf32..725f8e5f59 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AggregationRuleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AggregationRuleBuilder.java @@ -1,58 +1,96 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1AggregationRuleBuilder extends io.kubernetes.client.openapi.models.V1AggregationRuleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1AggregationRuleBuilder + extends io.kubernetes.client.openapi.models.V1AggregationRuleFluentImpl< + io.kubernetes.client.openapi.models.V1AggregationRuleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1AggregationRule, + io.kubernetes.client.openapi.models.V1AggregationRuleBuilder> { public V1AggregationRuleBuilder() { this(false); } + public V1AggregationRuleBuilder(java.lang.Boolean validationEnabled) { this(new V1AggregationRule(), validationEnabled); } - public V1AggregationRuleBuilder(io.kubernetes.client.openapi.models.V1AggregationRuleFluent fluent) { + + public V1AggregationRuleBuilder( + io.kubernetes.client.openapi.models.V1AggregationRuleFluent fluent) { this(fluent, false); } - public V1AggregationRuleBuilder(io.kubernetes.client.openapi.models.V1AggregationRuleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1AggregationRuleBuilder( + io.kubernetes.client.openapi.models.V1AggregationRuleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1AggregationRule(), validationEnabled); } - public V1AggregationRuleBuilder(io.kubernetes.client.openapi.models.V1AggregationRuleFluent fluent,io.kubernetes.client.openapi.models.V1AggregationRule instance) { + + public V1AggregationRuleBuilder( + io.kubernetes.client.openapi.models.V1AggregationRuleFluent fluent, + io.kubernetes.client.openapi.models.V1AggregationRule instance) { this(fluent, instance, false); } - public V1AggregationRuleBuilder(io.kubernetes.client.openapi.models.V1AggregationRuleFluent fluent,io.kubernetes.client.openapi.models.V1AggregationRule instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1AggregationRuleBuilder( + io.kubernetes.client.openapi.models.V1AggregationRuleFluent fluent, + io.kubernetes.client.openapi.models.V1AggregationRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withClusterRoleSelectors(instance.getClusterRoleSelectors()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1AggregationRuleBuilder(io.kubernetes.client.openapi.models.V1AggregationRule instance) { - this(instance,false); + this(instance, false); } - public V1AggregationRuleBuilder(io.kubernetes.client.openapi.models.V1AggregationRule instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1AggregationRuleBuilder( + io.kubernetes.client.openapi.models.V1AggregationRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withClusterRoleSelectors(instance.getClusterRoleSelectors()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1AggregationRuleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1AggregationRule build() { V1AggregationRule buildable = new V1AggregationRule(); buildable.setClusterRoleSelectors(fluent.getClusterRoleSelectors()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1AggregationRuleBuilder that = (V1AggregationRuleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AggregationRuleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AggregationRuleFluent.java index 9fcea709a1..7090348f31 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AggregationRuleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AggregationRuleFluent.java @@ -1,57 +1,109 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1AggregationRuleFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToClusterRoleSelectors(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelector item); - public A setToClusterRoleSelectors(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelector item); +/** Generated */ +public interface V1AggregationRuleFluent< + A extends io.kubernetes.client.openapi.models.V1AggregationRuleFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToClusterRoleSelectors( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LabelSelector item); + + public A setToClusterRoleSelectors( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LabelSelector item); + public A addToClusterRoleSelectors(io.kubernetes.client.openapi.models.V1LabelSelector... items); - public A addAllToClusterRoleSelectors(java.util.Collection items); - public A removeFromClusterRoleSelectors(io.kubernetes.client.openapi.models.V1LabelSelector... items); - public A removeAllFromClusterRoleSelectors(java.util.Collection items); - public A removeMatchingFromClusterRoleSelectors(java.util.function.Predicate predicate); - + + public A addAllToClusterRoleSelectors( + java.util.Collection items); + + public A removeFromClusterRoleSelectors( + io.kubernetes.client.openapi.models.V1LabelSelector... items); + + public A removeAllFromClusterRoleSelectors( + java.util.Collection items); + + public A removeMatchingFromClusterRoleSelectors( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildClusterRoleSelectors instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getClusterRoleSelectors(); - public java.util.List buildClusterRoleSelectors(); - public io.kubernetes.client.openapi.models.V1LabelSelector buildClusterRoleSelector(java.lang.Integer index); + public java.util.List + getClusterRoleSelectors(); + + public java.util.List + buildClusterRoleSelectors(); + + public io.kubernetes.client.openapi.models.V1LabelSelector buildClusterRoleSelector( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1LabelSelector buildFirstClusterRoleSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildLastClusterRoleSelector(); - public io.kubernetes.client.openapi.models.V1LabelSelector buildMatchingClusterRoleSelector(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingClusterRoleSelector(java.util.function.Predicate predicate); - public A withClusterRoleSelectors(java.util.List clusterRoleSelectors); - public A withClusterRoleSelectors(io.kubernetes.client.openapi.models.V1LabelSelector... clusterRoleSelectors); + + public io.kubernetes.client.openapi.models.V1LabelSelector buildMatchingClusterRoleSelector( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingClusterRoleSelector( + java.util.function.Predicate + predicate); + + public A withClusterRoleSelectors( + java.util.List clusterRoleSelectors); + + public A withClusterRoleSelectors( + io.kubernetes.client.openapi.models.V1LabelSelector... clusterRoleSelectors); + public java.lang.Boolean hasClusterRoleSelectors(); - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested addNewClusterRoleSelector(); - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested addNewClusterRoleSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested setNewClusterRoleSelectorLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested editClusterRoleSelector(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested editFirstClusterRoleSelector(); - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested editLastClusterRoleSelector(); - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested editMatchingClusterRoleSelector(java.util.function.Predicate predicate); - public interface ClusterRoleSelectorsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + addNewClusterRoleSelector(); + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + addNewClusterRoleSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + setNewClusterRoleSelectorLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + editClusterRoleSelector(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + editFirstClusterRoleSelector(); + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + editLastClusterRoleSelector(); + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + editMatchingClusterRoleSelector( + java.util.function.Predicate + predicate); + + public interface ClusterRoleSelectorsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1AggregationRuleFluent + .ClusterRoleSelectorsNested< + N>> { public N and(); + public N endClusterRoleSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AggregationRuleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AggregationRuleFluentImpl.java index f1f74947ab..22281c5936 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AggregationRuleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AggregationRuleFluentImpl.java @@ -1,57 +1,132 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1AggregationRuleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1AggregationRuleFluent{ - public V1AggregationRuleFluentImpl() { - } - public V1AggregationRuleFluentImpl(io.kubernetes.client.openapi.models.V1AggregationRule instance) { - this.withClusterRoleSelectors(instance.getClusterRoleSelectors()); +/** Generated */ +public class V1AggregationRuleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1AggregationRuleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1AggregationRuleFluent { + public V1AggregationRuleFluentImpl() {} + public V1AggregationRuleFluentImpl( + io.kubernetes.client.openapi.models.V1AggregationRule instance) { + this.withClusterRoleSelectors(instance.getClusterRoleSelectors()); } - private java.util.ArrayList clusterRoleSelectors; - public A addToClusterRoleSelectors(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelector item) { - if (this.clusterRoleSelectors == null) {this.clusterRoleSelectors = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(item);_visitables.get("clusterRoleSelectors").add(index >= 0 ? index : _visitables.get("clusterRoleSelectors").size(), builder);this.clusterRoleSelectors.add(index >= 0 ? index : clusterRoleSelectors.size(), builder); return (A)this; + + private java.util.ArrayList + clusterRoleSelectors; + + public A addToClusterRoleSelectors( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LabelSelector item) { + if (this.clusterRoleSelectors == null) { + this.clusterRoleSelectors = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(item); + _visitables + .get("clusterRoleSelectors") + .add(index >= 0 ? index : _visitables.get("clusterRoleSelectors").size(), builder); + this.clusterRoleSelectors.add(index >= 0 ? index : clusterRoleSelectors.size(), builder); + return (A) this; } - public A setToClusterRoleSelectors(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelector item) { - if (this.clusterRoleSelectors == null) {this.clusterRoleSelectors = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(item); - if (index < 0 || index >= _visitables.get("clusterRoleSelectors").size()) { _visitables.get("clusterRoleSelectors").add(builder); } else { _visitables.get("clusterRoleSelectors").set(index, builder);} - if (index < 0 || index >= clusterRoleSelectors.size()) { clusterRoleSelectors.add(builder); } else { clusterRoleSelectors.set(index, builder);} - return (A)this; + + public A setToClusterRoleSelectors( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LabelSelector item) { + if (this.clusterRoleSelectors == null) { + this.clusterRoleSelectors = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(item); + if (index < 0 || index >= _visitables.get("clusterRoleSelectors").size()) { + _visitables.get("clusterRoleSelectors").add(builder); + } else { + _visitables.get("clusterRoleSelectors").set(index, builder); + } + if (index < 0 || index >= clusterRoleSelectors.size()) { + clusterRoleSelectors.add(builder); + } else { + clusterRoleSelectors.set(index, builder); + } + return (A) this; } + public A addToClusterRoleSelectors(io.kubernetes.client.openapi.models.V1LabelSelector... items) { - if (this.clusterRoleSelectors == null) {this.clusterRoleSelectors = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LabelSelector item : items) {io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(item);_visitables.get("clusterRoleSelectors").add(builder);this.clusterRoleSelectors.add(builder);} return (A)this; + if (this.clusterRoleSelectors == null) { + this.clusterRoleSelectors = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1LabelSelector item : items) { + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(item); + _visitables.get("clusterRoleSelectors").add(builder); + this.clusterRoleSelectors.add(builder); + } + return (A) this; } - public A addAllToClusterRoleSelectors(java.util.Collection items) { - if (this.clusterRoleSelectors == null) {this.clusterRoleSelectors = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LabelSelector item : items) {io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(item);_visitables.get("clusterRoleSelectors").add(builder);this.clusterRoleSelectors.add(builder);} return (A)this; + + public A addAllToClusterRoleSelectors( + java.util.Collection items) { + if (this.clusterRoleSelectors == null) { + this.clusterRoleSelectors = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1LabelSelector item : items) { + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(item); + _visitables.get("clusterRoleSelectors").add(builder); + this.clusterRoleSelectors.add(builder); + } + return (A) this; } - public A removeFromClusterRoleSelectors(io.kubernetes.client.openapi.models.V1LabelSelector... items) { - for (io.kubernetes.client.openapi.models.V1LabelSelector item : items) {io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(item);_visitables.get("clusterRoleSelectors").remove(builder);if (this.clusterRoleSelectors != null) {this.clusterRoleSelectors.remove(builder);}} return (A)this; + + public A removeFromClusterRoleSelectors( + io.kubernetes.client.openapi.models.V1LabelSelector... items) { + for (io.kubernetes.client.openapi.models.V1LabelSelector item : items) { + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(item); + _visitables.get("clusterRoleSelectors").remove(builder); + if (this.clusterRoleSelectors != null) { + this.clusterRoleSelectors.remove(builder); + } + } + return (A) this; } - public A removeAllFromClusterRoleSelectors(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1LabelSelector item : items) {io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(item);_visitables.get("clusterRoleSelectors").remove(builder);if (this.clusterRoleSelectors != null) {this.clusterRoleSelectors.remove(builder);}} return (A)this; + + public A removeAllFromClusterRoleSelectors( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1LabelSelector item : items) { + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(item); + _visitables.get("clusterRoleSelectors").remove(builder); + if (this.clusterRoleSelectors != null) { + this.clusterRoleSelectors.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromClusterRoleSelectors(java.util.function.Predicate predicate) { + + public A removeMatchingFromClusterRoleSelectors( + java.util.function.Predicate + predicate) { if (clusterRoleSelectors == null) return (A) this; - final Iterator each = clusterRoleSelectors.iterator(); + final Iterator each = + clusterRoleSelectors.iterator(); final List visitables = _visitables.get("clusterRoleSelectors"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder = each.next(); @@ -60,104 +135,191 @@ public A removeMatchingFromClusterRoleSelectors(java.util.function.Predicate getClusterRoleSelectors() { + public java.util.List + getClusterRoleSelectors() { return clusterRoleSelectors != null ? build(clusterRoleSelectors) : null; } - public java.util.List buildClusterRoleSelectors() { + + public java.util.List + buildClusterRoleSelectors() { return clusterRoleSelectors != null ? build(clusterRoleSelectors) : null; } - public io.kubernetes.client.openapi.models.V1LabelSelector buildClusterRoleSelector(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1LabelSelector buildClusterRoleSelector( + java.lang.Integer index) { return this.clusterRoleSelectors.get(index).build(); } + public io.kubernetes.client.openapi.models.V1LabelSelector buildFirstClusterRoleSelector() { return this.clusterRoleSelectors.get(0).build(); } + public io.kubernetes.client.openapi.models.V1LabelSelector buildLastClusterRoleSelector() { return this.clusterRoleSelectors.get(clusterRoleSelectors.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1LabelSelector buildMatchingClusterRoleSelector(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LabelSelectorBuilder item: clusterRoleSelectors) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1LabelSelector buildMatchingClusterRoleSelector( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1LabelSelectorBuilder item : clusterRoleSelectors) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingClusterRoleSelector(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LabelSelectorBuilder item: clusterRoleSelectors) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingClusterRoleSelector( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1LabelSelectorBuilder item : clusterRoleSelectors) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withClusterRoleSelectors(java.util.List clusterRoleSelectors) { - if (this.clusterRoleSelectors != null) { _visitables.get("clusterRoleSelectors").removeAll(this.clusterRoleSelectors);} - if (clusterRoleSelectors != null) {this.clusterRoleSelectors = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1LabelSelector item : clusterRoleSelectors){this.addToClusterRoleSelectors(item);}} else { this.clusterRoleSelectors = null;} return (A) this; + + public A withClusterRoleSelectors( + java.util.List clusterRoleSelectors) { + if (this.clusterRoleSelectors != null) { + _visitables.get("clusterRoleSelectors").removeAll(this.clusterRoleSelectors); + } + if (clusterRoleSelectors != null) { + this.clusterRoleSelectors = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1LabelSelector item : clusterRoleSelectors) { + this.addToClusterRoleSelectors(item); + } + } else { + this.clusterRoleSelectors = null; + } + return (A) this; } - public A withClusterRoleSelectors(io.kubernetes.client.openapi.models.V1LabelSelector... clusterRoleSelectors) { - if (this.clusterRoleSelectors != null) {this.clusterRoleSelectors.clear();} - if (clusterRoleSelectors != null) {for (io.kubernetes.client.openapi.models.V1LabelSelector item :clusterRoleSelectors){ this.addToClusterRoleSelectors(item);}} return (A) this; + + public A withClusterRoleSelectors( + io.kubernetes.client.openapi.models.V1LabelSelector... clusterRoleSelectors) { + if (this.clusterRoleSelectors != null) { + this.clusterRoleSelectors.clear(); + } + if (clusterRoleSelectors != null) { + for (io.kubernetes.client.openapi.models.V1LabelSelector item : clusterRoleSelectors) { + this.addToClusterRoleSelectors(item); + } + } + return (A) this; } + public java.lang.Boolean hasClusterRoleSelectors() { return clusterRoleSelectors != null && !clusterRoleSelectors.isEmpty(); } - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested addNewClusterRoleSelector() { - return new io.kubernetes.client.openapi.models.V1AggregationRuleFluentImpl.ClusterRoleSelectorsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + addNewClusterRoleSelector() { + return new io.kubernetes.client.openapi.models.V1AggregationRuleFluentImpl + .ClusterRoleSelectorsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested addNewClusterRoleSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1AggregationRuleFluentImpl.ClusterRoleSelectorsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + addNewClusterRoleSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1AggregationRuleFluentImpl + .ClusterRoleSelectorsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested setNewClusterRoleSelectorLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1AggregationRuleFluentImpl.ClusterRoleSelectorsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + setNewClusterRoleSelectorLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1AggregationRuleFluentImpl + .ClusterRoleSelectorsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested editClusterRoleSelector(java.lang.Integer index) { - if (clusterRoleSelectors.size() <= index) throw new RuntimeException("Can't edit clusterRoleSelectors. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + editClusterRoleSelector(java.lang.Integer index) { + if (clusterRoleSelectors.size() <= index) + throw new RuntimeException("Can't edit clusterRoleSelectors. Index exceeds size."); return setNewClusterRoleSelectorLike(index, buildClusterRoleSelector(index)); } - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested editFirstClusterRoleSelector() { - if (clusterRoleSelectors.size() == 0) throw new RuntimeException("Can't edit first clusterRoleSelectors. The list is empty."); + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + editFirstClusterRoleSelector() { + if (clusterRoleSelectors.size() == 0) + throw new RuntimeException("Can't edit first clusterRoleSelectors. The list is empty."); return setNewClusterRoleSelectorLike(0, buildClusterRoleSelector(0)); } - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested editLastClusterRoleSelector() { + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + editLastClusterRoleSelector() { int index = clusterRoleSelectors.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last clusterRoleSelectors. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last clusterRoleSelectors. The list is empty."); return setNewClusterRoleSelectorLike(index, buildClusterRoleSelector(index)); } - public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested editMatchingClusterRoleSelector(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested + editMatchingClusterRoleSelector( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested,io.kubernetes.client.fluent.Nested{ - ClusterRoleSelectorsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelector item) { + + public class ClusterRoleSelectorsNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1AggregationRuleFluent.ClusterRoleSelectorsNested> + implements io.kubernetes.client.openapi.models.V1AggregationRuleFluent + .ClusterRoleSelectorsNested< + N>, + io.kubernetes.client.fluent.Nested { + ClusterRoleSelectorsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LabelSelector item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + ClusterRoleSelectorsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1AggregationRuleFluentImpl.this.setToClusterRoleSelectors(index,builder.build()); + return (N) V1AggregationRuleFluentImpl.this.setToClusterRoleSelectors(index, builder.build()); } + public N endClusterRoleSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AttachedVolumeBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AttachedVolumeBuilder.java index f2c2ccbfd4..764a34361a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AttachedVolumeBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AttachedVolumeBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1AttachedVolumeBuilder extends io.kubernetes.client.openapi.models.V1AttachedVolumeFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1AttachedVolumeBuilder + extends io.kubernetes.client.openapi.models.V1AttachedVolumeFluentImpl< + io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1AttachedVolume, + io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder> { public V1AttachedVolumeBuilder() { this(false); } + public V1AttachedVolumeBuilder(java.lang.Boolean validationEnabled) { this(new V1AttachedVolume(), validationEnabled); } - public V1AttachedVolumeBuilder(io.kubernetes.client.openapi.models.V1AttachedVolumeFluent fluent) { + + public V1AttachedVolumeBuilder( + io.kubernetes.client.openapi.models.V1AttachedVolumeFluent fluent) { this(fluent, false); } - public V1AttachedVolumeBuilder(io.kubernetes.client.openapi.models.V1AttachedVolumeFluent fluent,java.lang.Boolean validationEnabled) { + + public V1AttachedVolumeBuilder( + io.kubernetes.client.openapi.models.V1AttachedVolumeFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1AttachedVolume(), validationEnabled); } - public V1AttachedVolumeBuilder(io.kubernetes.client.openapi.models.V1AttachedVolumeFluent fluent,io.kubernetes.client.openapi.models.V1AttachedVolume instance) { + + public V1AttachedVolumeBuilder( + io.kubernetes.client.openapi.models.V1AttachedVolumeFluent fluent, + io.kubernetes.client.openapi.models.V1AttachedVolume instance) { this(fluent, instance, false); } - public V1AttachedVolumeBuilder(io.kubernetes.client.openapi.models.V1AttachedVolumeFluent fluent,io.kubernetes.client.openapi.models.V1AttachedVolume instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1AttachedVolumeBuilder( + io.kubernetes.client.openapi.models.V1AttachedVolumeFluent fluent, + io.kubernetes.client.openapi.models.V1AttachedVolume instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDevicePath(instance.getDevicePath()); fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1AttachedVolumeBuilder(io.kubernetes.client.openapi.models.V1AttachedVolume instance) { - this(instance,false); + this(instance, false); } - public V1AttachedVolumeBuilder(io.kubernetes.client.openapi.models.V1AttachedVolume instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1AttachedVolumeBuilder( + io.kubernetes.client.openapi.models.V1AttachedVolume instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDevicePath(instance.getDevicePath()); this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1AttachedVolumeFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1AttachedVolume build() { V1AttachedVolume buildable = new V1AttachedVolume(); buildable.setDevicePath(fluent.getDevicePath()); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1AttachedVolumeBuilder that = (V1AttachedVolumeBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AttachedVolumeFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AttachedVolumeFluent.java index c1ed27715f..33878c6e35 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AttachedVolumeFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AttachedVolumeFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1AttachedVolumeFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1AttachedVolumeFluent< + A extends io.kubernetes.client.openapi.models.V1AttachedVolumeFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getDevicePath(); + public A withDevicePath(java.lang.String devicePath); + public java.lang.Boolean hasDevicePath(); - - /** - * Method is deprecated. use withDevicePath instead. - */ + + /** Method is deprecated. use withDevicePath instead. */ @java.lang.Deprecated public A withNewDevicePath(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AttachedVolumeFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AttachedVolumeFluentImpl.java index 6b887d992b..d154727efd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AttachedVolumeFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AttachedVolumeFluentImpl.java @@ -1,69 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1AttachedVolumeFluentImpl< + A extends io.kubernetes.client.openapi.models.V1AttachedVolumeFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1AttachedVolumeFluent { + public V1AttachedVolumeFluentImpl() {} - /** - * Generated - */ -public class V1AttachedVolumeFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1AttachedVolumeFluent{ - public V1AttachedVolumeFluentImpl() { - } public V1AttachedVolumeFluentImpl(io.kubernetes.client.openapi.models.V1AttachedVolume instance) { this.withDevicePath(instance.getDevicePath()); this.withName(instance.getName()); - } + private java.lang.String devicePath; private java.lang.String name; + public java.lang.String getDevicePath() { return this.devicePath; } + public A withDevicePath(java.lang.String devicePath) { - this.devicePath=devicePath; return (A) this; + this.devicePath = devicePath; + return (A) this; } + public java.lang.Boolean hasDevicePath() { return this.devicePath != null; } - - /** - * Method is deprecated. use withDevicePath instead. - */ + + /** Method is deprecated. use withDevicePath instead. */ @java.lang.Deprecated public A withNewDevicePath(java.lang.String original) { - return (A)withDevicePath(new String(original)); + return (A) withDevicePath(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1AttachedVolumeFluentImpl that = (V1AttachedVolumeFluentImpl) o; - if (devicePath != null ? !devicePath.equals(that.devicePath) :that.devicePath != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (devicePath != null ? !devicePath.equals(that.devicePath) : that.devicePath != null) + return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(devicePath, name, super.hashCode()); + return java.util.Objects.hash(devicePath, name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureDiskVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureDiskVolumeSourceBuilder.java index 960dfffe62..feccb14cfb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureDiskVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureDiskVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1AzureDiskVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1AzureDiskVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource, + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder> { public V1AzureDiskVolumeSourceBuilder() { this(false); } + public V1AzureDiskVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1AzureDiskVolumeSource(), validationEnabled); } - public V1AzureDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent fluent) { + + public V1AzureDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent fluent) { this(fluent, false); } - public V1AzureDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1AzureDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1AzureDiskVolumeSource(), validationEnabled); } - public V1AzureDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource instance) { + + public V1AzureDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource instance) { this(fluent, instance, false); } - public V1AzureDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1AzureDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCachingMode(instance.getCachingMode()); fluent.withDiskName(instance.getDiskName()); @@ -33,13 +60,18 @@ public V1AzureDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1Azur fluent.withReadOnly(instance.getReadOnly()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1AzureDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource instance) { - this(instance,false); + + public V1AzureDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource instance) { + this(instance, false); } - public V1AzureDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1AzureDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCachingMode(instance.getCachingMode()); this.withDiskName(instance.getDiskName()); @@ -52,10 +84,12 @@ public V1AzureDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1Azur this.withReadOnly(instance.getReadOnly()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource build() { V1AzureDiskVolumeSource buildable = new V1AzureDiskVolumeSource(); buildable.setCachingMode(fluent.getCachingMode()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource build() { buildable.setReadOnly(fluent.getReadOnly()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1AzureDiskVolumeSourceBuilder that = (V1AzureDiskVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureDiskVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureDiskVolumeSourceFluent.java index ba11296a21..570f2f8932 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureDiskVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureDiskVolumeSourceFluent.java @@ -1,62 +1,74 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1AzureDiskVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1AzureDiskVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getCachingMode(); + public A withCachingMode(java.lang.String cachingMode); + public java.lang.Boolean hasCachingMode(); - - /** - * Method is deprecated. use withCachingMode instead. - */ + + /** Method is deprecated. use withCachingMode instead. */ @java.lang.Deprecated public A withNewCachingMode(java.lang.String original); + public java.lang.String getDiskName(); + public A withDiskName(java.lang.String diskName); + public java.lang.Boolean hasDiskName(); - - /** - * Method is deprecated. use withDiskName instead. - */ + + /** Method is deprecated. use withDiskName instead. */ @java.lang.Deprecated public A withNewDiskName(java.lang.String original); + public java.lang.String getDiskURI(); + public A withDiskURI(java.lang.String diskURI); + public java.lang.Boolean hasDiskURI(); - - /** - * Method is deprecated. use withDiskURI instead. - */ + + /** Method is deprecated. use withDiskURI instead. */ @java.lang.Deprecated public A withNewDiskURI(java.lang.String original); + public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureDiskVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureDiskVolumeSourceFluentImpl.java index e13e3ceb08..1df5d577f0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureDiskVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureDiskVolumeSourceFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1AzureDiskVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent { + public V1AzureDiskVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1AzureDiskVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent{ - public V1AzureDiskVolumeSourceFluentImpl() { - } - public V1AzureDiskVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource instance) { + public V1AzureDiskVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource instance) { this.withCachingMode(instance.getCachingMode()); this.withDiskName(instance.getDiskName()); @@ -24,122 +32,139 @@ public V1AzureDiskVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1A this.withKind(instance.getKind()); this.withReadOnly(instance.getReadOnly()); - } + private java.lang.String cachingMode; private java.lang.String diskName; private java.lang.String diskURI; private java.lang.String fsType; private java.lang.String kind; private java.lang.Boolean readOnly; + public java.lang.String getCachingMode() { return this.cachingMode; } + public A withCachingMode(java.lang.String cachingMode) { - this.cachingMode=cachingMode; return (A) this; + this.cachingMode = cachingMode; + return (A) this; } + public java.lang.Boolean hasCachingMode() { return this.cachingMode != null; } - - /** - * Method is deprecated. use withCachingMode instead. - */ + + /** Method is deprecated. use withCachingMode instead. */ @java.lang.Deprecated public A withNewCachingMode(java.lang.String original) { - return (A)withCachingMode(new String(original)); + return (A) withCachingMode(new String(original)); } + public java.lang.String getDiskName() { return this.diskName; } + public A withDiskName(java.lang.String diskName) { - this.diskName=diskName; return (A) this; + this.diskName = diskName; + return (A) this; } + public java.lang.Boolean hasDiskName() { return this.diskName != null; } - - /** - * Method is deprecated. use withDiskName instead. - */ + + /** Method is deprecated. use withDiskName instead. */ @java.lang.Deprecated public A withNewDiskName(java.lang.String original) { - return (A)withDiskName(new String(original)); + return (A) withDiskName(new String(original)); } + public java.lang.String getDiskURI() { return this.diskURI; } + public A withDiskURI(java.lang.String diskURI) { - this.diskURI=diskURI; return (A) this; + this.diskURI = diskURI; + return (A) this; } + public java.lang.Boolean hasDiskURI() { return this.diskURI != null; } - - /** - * Method is deprecated. use withDiskURI instead. - */ + + /** Method is deprecated. use withDiskURI instead. */ @java.lang.Deprecated public A withNewDiskURI(java.lang.String original) { - return (A)withDiskURI(new String(original)); + return (A) withDiskURI(new String(original)); } + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1AzureDiskVolumeSourceFluentImpl that = (V1AzureDiskVolumeSourceFluentImpl) o; - if (cachingMode != null ? !cachingMode.equals(that.cachingMode) :that.cachingMode != null) return false; - if (diskName != null ? !diskName.equals(that.diskName) :that.diskName != null) return false; - if (diskURI != null ? !diskURI.equals(that.diskURI) :that.diskURI != null) return false; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; + if (cachingMode != null ? !cachingMode.equals(that.cachingMode) : that.cachingMode != null) + return false; + if (diskName != null ? !diskName.equals(that.diskName) : that.diskName != null) return false; + if (diskURI != null ? !diskURI.equals(that.diskURI) : that.diskURI != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(cachingMode, diskName, diskURI, fsType, kind, readOnly, super.hashCode()); + return java.util.Objects.hash( + cachingMode, diskName, diskURI, fsType, kind, readOnly, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFilePersistentVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFilePersistentVolumeSourceBuilder.java index c27d7145f0..3decd07077 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFilePersistentVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFilePersistentVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1AzureFilePersistentVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1AzureFilePersistentVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource, + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceBuilder> { public V1AzureFilePersistentVolumeSourceBuilder() { this(false); } + public V1AzureFilePersistentVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1AzureFilePersistentVolumeSource(), validationEnabled); } - public V1AzureFilePersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent fluent) { + + public V1AzureFilePersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent fluent) { this(fluent, false); } - public V1AzureFilePersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1AzureFilePersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1AzureFilePersistentVolumeSource(), validationEnabled); } - public V1AzureFilePersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource instance) { + + public V1AzureFilePersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource instance) { this(fluent, instance, false); } - public V1AzureFilePersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1AzureFilePersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withReadOnly(instance.getReadOnly()); fluent.withSecretName(instance.getSecretName()); @@ -29,13 +56,18 @@ public V1AzureFilePersistentVolumeSourceBuilder(io.kubernetes.client.openapi.mod fluent.withShareName(instance.getShareName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1AzureFilePersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource instance) { - this(instance,false); + + public V1AzureFilePersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource instance) { + this(instance, false); } - public V1AzureFilePersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1AzureFilePersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withReadOnly(instance.getReadOnly()); this.withSecretName(instance.getSecretName()); @@ -44,10 +76,12 @@ public V1AzureFilePersistentVolumeSourceBuilder(io.kubernetes.client.openapi.mod this.withShareName(instance.getShareName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource build() { V1AzureFilePersistentVolumeSource buildable = new V1AzureFilePersistentVolumeSource(); buildable.setReadOnly(fluent.getReadOnly()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource bui buildable.setShareName(fluent.getShareName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1AzureFilePersistentVolumeSourceBuilder that = (V1AzureFilePersistentVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFilePersistentVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFilePersistentVolumeSourceFluent.java index 7c83b52c9e..7db7ed0981 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFilePersistentVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFilePersistentVolumeSourceFluent.java @@ -1,44 +1,54 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1AzureFilePersistentVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1AzureFilePersistentVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); + public java.lang.String getSecretName(); + public A withSecretName(java.lang.String secretName); + public java.lang.Boolean hasSecretName(); - - /** - * Method is deprecated. use withSecretName instead. - */ + + /** Method is deprecated. use withSecretName instead. */ @java.lang.Deprecated public A withNewSecretName(java.lang.String original); + public java.lang.String getSecretNamespace(); + public A withSecretNamespace(java.lang.String secretNamespace); + public java.lang.Boolean hasSecretNamespace(); - - /** - * Method is deprecated. use withSecretNamespace instead. - */ + + /** Method is deprecated. use withSecretNamespace instead. */ @java.lang.Deprecated public A withNewSecretNamespace(java.lang.String original); + public java.lang.String getShareName(); + public A withShareName(java.lang.String shareName); + public java.lang.Boolean hasShareName(); - - /** - * Method is deprecated. use withShareName instead. - */ + + /** Method is deprecated. use withShareName instead. */ @java.lang.Deprecated public A withNewShareName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFilePersistentVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFilePersistentVolumeSourceFluentImpl.java index 8fba60ca15..1dd97c9b63 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFilePersistentVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFilePersistentVolumeSourceFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1AzureFilePersistentVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent { + public V1AzureFilePersistentVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1AzureFilePersistentVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent{ - public V1AzureFilePersistentVolumeSourceFluentImpl() { - } - public V1AzureFilePersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource instance) { + public V1AzureFilePersistentVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource instance) { this.withReadOnly(instance.getReadOnly()); this.withSecretName(instance.getSecretName()); @@ -20,84 +28,101 @@ public V1AzureFilePersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi. this.withSecretNamespace(instance.getSecretNamespace()); this.withShareName(instance.getShareName()); - } + private java.lang.Boolean readOnly; private java.lang.String secretName; private java.lang.String secretNamespace; private java.lang.String shareName; + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public java.lang.String getSecretName() { return this.secretName; } + public A withSecretName(java.lang.String secretName) { - this.secretName=secretName; return (A) this; + this.secretName = secretName; + return (A) this; } + public java.lang.Boolean hasSecretName() { return this.secretName != null; } - - /** - * Method is deprecated. use withSecretName instead. - */ + + /** Method is deprecated. use withSecretName instead. */ @java.lang.Deprecated public A withNewSecretName(java.lang.String original) { - return (A)withSecretName(new String(original)); + return (A) withSecretName(new String(original)); } + public java.lang.String getSecretNamespace() { return this.secretNamespace; } + public A withSecretNamespace(java.lang.String secretNamespace) { - this.secretNamespace=secretNamespace; return (A) this; + this.secretNamespace = secretNamespace; + return (A) this; } + public java.lang.Boolean hasSecretNamespace() { return this.secretNamespace != null; } - - /** - * Method is deprecated. use withSecretNamespace instead. - */ + + /** Method is deprecated. use withSecretNamespace instead. */ @java.lang.Deprecated public A withNewSecretNamespace(java.lang.String original) { - return (A)withSecretNamespace(new String(original)); + return (A) withSecretNamespace(new String(original)); } + public java.lang.String getShareName() { return this.shareName; } + public A withShareName(java.lang.String shareName) { - this.shareName=shareName; return (A) this; + this.shareName = shareName; + return (A) this; } + public java.lang.Boolean hasShareName() { return this.shareName != null; } - - /** - * Method is deprecated. use withShareName instead. - */ + + /** Method is deprecated. use withShareName instead. */ @java.lang.Deprecated public A withNewShareName(java.lang.String original) { - return (A)withShareName(new String(original)); + return (A) withShareName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1AzureFilePersistentVolumeSourceFluentImpl that = (V1AzureFilePersistentVolumeSourceFluentImpl) o; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretName != null ? !secretName.equals(that.secretName) :that.secretName != null) return false; - if (secretNamespace != null ? !secretNamespace.equals(that.secretNamespace) :that.secretNamespace != null) return false; - if (shareName != null ? !shareName.equals(that.shareName) :that.shareName != null) return false; + V1AzureFilePersistentVolumeSourceFluentImpl that = + (V1AzureFilePersistentVolumeSourceFluentImpl) o; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretName != null ? !secretName.equals(that.secretName) : that.secretName != null) + return false; + if (secretNamespace != null + ? !secretNamespace.equals(that.secretNamespace) + : that.secretNamespace != null) return false; + if (shareName != null ? !shareName.equals(that.shareName) : that.shareName != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(readOnly, secretName, secretNamespace, shareName, super.hashCode()); + return java.util.Objects.hash( + readOnly, secretName, secretNamespace, shareName, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFileVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFileVolumeSourceBuilder.java index d1dc21159f..978d4b02b4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFileVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFileVolumeSourceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1AzureFileVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1AzureFileVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1AzureFileVolumeSource, + io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceBuilder> { public V1AzureFileVolumeSourceBuilder() { this(false); } + public V1AzureFileVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1AzureFileVolumeSource(), validationEnabled); } - public V1AzureFileVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent fluent) { + + public V1AzureFileVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent fluent) { this(fluent, false); } - public V1AzureFileVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1AzureFileVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1AzureFileVolumeSource(), validationEnabled); } - public V1AzureFileVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1AzureFileVolumeSource instance) { + + public V1AzureFileVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1AzureFileVolumeSource instance) { this(fluent, instance, false); } - public V1AzureFileVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1AzureFileVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1AzureFileVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1AzureFileVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withReadOnly(instance.getReadOnly()); fluent.withSecretName(instance.getSecretName()); fluent.withShareName(instance.getShareName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1AzureFileVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureFileVolumeSource instance) { - this(instance,false); + + public V1AzureFileVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureFileVolumeSource instance) { + this(instance, false); } - public V1AzureFileVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1AzureFileVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1AzureFileVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1AzureFileVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withReadOnly(instance.getReadOnly()); this.withSecretName(instance.getSecretName()); this.withShareName(instance.getShareName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1AzureFileVolumeSource build() { V1AzureFileVolumeSource buildable = new V1AzureFileVolumeSource(); buildable.setReadOnly(fluent.getReadOnly()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1AzureFileVolumeSource build() { buildable.setShareName(fluent.getShareName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1AzureFileVolumeSourceBuilder that = (V1AzureFileVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFileVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFileVolumeSourceFluent.java index 23e6b215d4..c144846623 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFileVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFileVolumeSourceFluent.java @@ -1,35 +1,44 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1AzureFileVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1AzureFileVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); + public java.lang.String getSecretName(); + public A withSecretName(java.lang.String secretName); + public java.lang.Boolean hasSecretName(); - - /** - * Method is deprecated. use withSecretName instead. - */ + + /** Method is deprecated. use withSecretName instead. */ @java.lang.Deprecated public A withNewSecretName(java.lang.String original); + public java.lang.String getShareName(); + public A withShareName(java.lang.String shareName); + public java.lang.Boolean hasShareName(); - - /** - * Method is deprecated. use withShareName instead. - */ + + /** Method is deprecated. use withShareName instead. */ @java.lang.Deprecated public A withNewShareName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFileVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFileVolumeSourceFluentImpl.java index d15534a8e7..db59b5637d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFileVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1AzureFileVolumeSourceFluentImpl.java @@ -1,82 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1AzureFileVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent{ - public V1AzureFileVolumeSourceFluentImpl() { - } - public V1AzureFileVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1AzureFileVolumeSource instance) { +/** Generated */ +public class V1AzureFileVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent { + public V1AzureFileVolumeSourceFluentImpl() {} + + public V1AzureFileVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1AzureFileVolumeSource instance) { this.withReadOnly(instance.getReadOnly()); this.withSecretName(instance.getSecretName()); this.withShareName(instance.getShareName()); - } + private java.lang.Boolean readOnly; private java.lang.String secretName; private java.lang.String shareName; + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public java.lang.String getSecretName() { return this.secretName; } + public A withSecretName(java.lang.String secretName) { - this.secretName=secretName; return (A) this; + this.secretName = secretName; + return (A) this; } + public java.lang.Boolean hasSecretName() { return this.secretName != null; } - - /** - * Method is deprecated. use withSecretName instead. - */ + + /** Method is deprecated. use withSecretName instead. */ @java.lang.Deprecated public A withNewSecretName(java.lang.String original) { - return (A)withSecretName(new String(original)); + return (A) withSecretName(new String(original)); } + public java.lang.String getShareName() { return this.shareName; } + public A withShareName(java.lang.String shareName) { - this.shareName=shareName; return (A) this; + this.shareName = shareName; + return (A) this; } + public java.lang.Boolean hasShareName() { return this.shareName != null; } - - /** - * Method is deprecated. use withShareName instead. - */ + + /** Method is deprecated. use withShareName instead. */ @java.lang.Deprecated public A withNewShareName(java.lang.String original) { - return (A)withShareName(new String(original)); + return (A) withShareName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1AzureFileVolumeSourceFluentImpl that = (V1AzureFileVolumeSourceFluentImpl) o; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretName != null ? !secretName.equals(that.secretName) :that.secretName != null) return false; - if (shareName != null ? !shareName.equals(that.shareName) :that.shareName != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretName != null ? !secretName.equals(that.secretName) : that.secretName != null) + return false; + if (shareName != null ? !shareName.equals(that.shareName) : that.shareName != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(readOnly, secretName, shareName, super.hashCode()); + return java.util.Objects.hash(readOnly, secretName, shareName, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BindingBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BindingBuilder.java index bd8ae24909..f952df39d6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BindingBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BindingBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1BindingBuilder extends io.kubernetes.client.openapi.models.V1BindingFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1BindingBuilder + extends io.kubernetes.client.openapi.models.V1BindingFluentImpl< + io.kubernetes.client.openapi.models.V1BindingBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Binding, + io.kubernetes.client.openapi.models.V1BindingBuilder> { public V1BindingBuilder() { this(false); } + public V1BindingBuilder(java.lang.Boolean validationEnabled) { this(new V1Binding(), validationEnabled); } + public V1BindingBuilder(io.kubernetes.client.openapi.models.V1BindingFluent fluent) { this(fluent, false); } - public V1BindingBuilder(io.kubernetes.client.openapi.models.V1BindingFluent fluent,java.lang.Boolean validationEnabled) { + + public V1BindingBuilder( + io.kubernetes.client.openapi.models.V1BindingFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Binding(), validationEnabled); } - public V1BindingBuilder(io.kubernetes.client.openapi.models.V1BindingFluent fluent,io.kubernetes.client.openapi.models.V1Binding instance) { + + public V1BindingBuilder( + io.kubernetes.client.openapi.models.V1BindingFluent fluent, + io.kubernetes.client.openapi.models.V1Binding instance) { this(fluent, instance, false); } - public V1BindingBuilder(io.kubernetes.client.openapi.models.V1BindingFluent fluent,io.kubernetes.client.openapi.models.V1Binding instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1BindingBuilder( + io.kubernetes.client.openapi.models.V1BindingFluent fluent, + io.kubernetes.client.openapi.models.V1Binding instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +55,16 @@ public V1BindingBuilder(io.kubernetes.client.openapi.models.V1BindingFluent f fluent.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1BindingBuilder(io.kubernetes.client.openapi.models.V1Binding instance) { - this(instance,false); + this(instance, false); } - public V1BindingBuilder(io.kubernetes.client.openapi.models.V1Binding instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1BindingBuilder( + io.kubernetes.client.openapi.models.V1Binding instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +73,12 @@ public V1BindingBuilder(io.kubernetes.client.openapi.models.V1Binding instance,j this.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1BindingFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Binding build() { V1Binding buildable = new V1Binding(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +87,23 @@ public io.kubernetes.client.openapi.models.V1Binding build() { buildable.setTarget(fluent.getTarget()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1BindingBuilder that = (V1BindingBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BindingFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BindingFluent.java index eb2c076726..1aed8c4045 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BindingFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BindingFluent.java @@ -1,73 +1,107 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1BindingFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1BindingFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getTarget(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildTarget(); + public A withTarget(io.kubernetes.client.openapi.models.V1ObjectReference target); + public java.lang.Boolean hasTarget(); + public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested withNewTarget(); - public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested withNewTargetLike( + io.kubernetes.client.openapi.models.V1ObjectReference item); + public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested editTarget(); + public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested editOrNewTarget(); - public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested editOrNewTargetLike( + io.kubernetes.client.openapi.models.V1ObjectReference item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface TargetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface TargetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested> { public N and(); + public N endTarget(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BindingFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BindingFluentImpl.java index 5fad2f1700..9f7205293e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BindingFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BindingFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1BindingFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1BindingFluent { + public V1BindingFluentImpl() {} - /** - * Generated - */ -public class V1BindingFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1BindingFluent{ - public V1BindingFluentImpl() { - } public V1BindingFluentImpl(io.kubernetes.client.openapi.models.V1Binding instance) { this.withApiVersion(instance.getApiVersion()); @@ -21,158 +26,216 @@ public V1BindingFluentImpl(io.kubernetes.client.openapi.models.V1Binding instanc this.withMetadata(instance.getMetadata()); this.withTarget(instance.getTarget()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder target; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1BindingFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1BindingFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectReference buildTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public A withTarget(io.kubernetes.client.openapi.models.V1ObjectReference target) { _visitables.get("target").remove(this.target); - if (target!=null){ this.target= new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(target); _visitables.get("target").add(this.target);} return (A) this; + if (target != null) { + this.target = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(target); + _visitables.get("target").add(this.target); + } + return (A) this; } + public java.lang.Boolean hasTarget() { return this.target != null; } + public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested withNewTarget() { return new io.kubernetes.client.openapi.models.V1BindingFluentImpl.TargetNestedImpl(); } - public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + + public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested withNewTargetLike( + io.kubernetes.client.openapi.models.V1ObjectReference item) { return new io.kubernetes.client.openapi.models.V1BindingFluentImpl.TargetNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested editTarget() { return withNewTargetLike(getTarget()); } + public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested editOrNewTarget() { - return withNewTargetLike(getTarget() != null ? getTarget(): new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); + return withNewTargetLike( + getTarget() != null + ? getTarget() + : new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return withNewTargetLike(getTarget() != null ? getTarget(): item); + + public io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested editOrNewTargetLike( + io.kubernetes.client.openapi.models.V1ObjectReference item) { + return withNewTargetLike(getTarget() != null ? getTarget() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1BindingFluentImpl that = (V1BindingFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (target != null ? !target.equals(that.target) :that.target != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (target != null ? !target.equals(that.target) : that.target != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, target, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, target, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1BindingFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1BindingFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class TargetNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested,io.kubernetes.client.fluent.Nested{ + + public class TargetNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested> + implements io.kubernetes.client.openapi.models.V1BindingFluent.TargetNested, + io.kubernetes.client.fluent.Nested { TargetNestedImpl(io.kubernetes.client.openapi.models.V1ObjectReference item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + TargetNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; + public N and() { return (N) V1BindingFluentImpl.this.withTarget(builder.build()); } + public N endTarget() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BoundObjectReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BoundObjectReferenceBuilder.java index dae6128d55..78baa04da2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BoundObjectReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BoundObjectReferenceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1BoundObjectReferenceBuilder extends io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1BoundObjectReferenceBuilder + extends io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1BoundObjectReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1BoundObjectReference, + io.kubernetes.client.openapi.models.V1BoundObjectReferenceBuilder> { public V1BoundObjectReferenceBuilder() { this(false); } + public V1BoundObjectReferenceBuilder(java.lang.Boolean validationEnabled) { this(new V1BoundObjectReference(), validationEnabled); } - public V1BoundObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent fluent) { + + public V1BoundObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent fluent) { this(fluent, false); } - public V1BoundObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1BoundObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1BoundObjectReference(), validationEnabled); } - public V1BoundObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V1BoundObjectReference instance) { + + public V1BoundObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1BoundObjectReference instance) { this(fluent, instance, false); } - public V1BoundObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V1BoundObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1BoundObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1BoundObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +56,18 @@ public V1BoundObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1Bound fluent.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1BoundObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1BoundObjectReference instance) { - this(instance,false); + + public V1BoundObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1BoundObjectReference instance) { + this(instance, false); } - public V1BoundObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1BoundObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1BoundObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1BoundObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +76,12 @@ public V1BoundObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1Bound this.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1BoundObjectReference build() { V1BoundObjectReference buildable = new V1BoundObjectReference(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1BoundObjectReference build() { buildable.setUid(fluent.getUid()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1BoundObjectReferenceBuilder that = (V1BoundObjectReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BoundObjectReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BoundObjectReferenceFluent.java index 1f5eeebc98..465bad3d1a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BoundObjectReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BoundObjectReferenceFluent.java @@ -1,50 +1,58 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1BoundObjectReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1BoundObjectReferenceFluent< + A extends io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getUid(); + public A withUid(java.lang.String uid); + public java.lang.Boolean hasUid(); - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BoundObjectReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BoundObjectReferenceFluentImpl.java index 18efc6dddb..b7db53d595 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BoundObjectReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1BoundObjectReferenceFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1BoundObjectReferenceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent { + public V1BoundObjectReferenceFluentImpl() {} - /** - * Generated - */ -public class V1BoundObjectReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent{ - public V1BoundObjectReferenceFluentImpl() { - } - public V1BoundObjectReferenceFluentImpl(io.kubernetes.client.openapi.models.V1BoundObjectReference instance) { + public V1BoundObjectReferenceFluentImpl( + io.kubernetes.client.openapi.models.V1BoundObjectReference instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -20,92 +28,102 @@ public V1BoundObjectReferenceFluentImpl(io.kubernetes.client.openapi.models.V1Bo this.withName(instance.getName()); this.withUid(instance.getUid()); - } + private java.lang.String apiVersion; private java.lang.String kind; private java.lang.String name; private java.lang.String uid; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getUid() { return this.uid; } + public A withUid(java.lang.String uid) { - this.uid=uid; return (A) this; + this.uid = uid; + return (A) this; } + public java.lang.Boolean hasUid() { return this.uid != null; } - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original) { - return (A)withUid(new String(original)); + return (A) withUid(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1BoundObjectReferenceFluentImpl that = (V1BoundObjectReferenceFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (uid != null ? !uid.equals(that.uid) :that.uid != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (uid != null ? !uid.equals(that.uid) : that.uid != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, name, uid, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, name, uid, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverBuilder.java index 5ba948d5ac..bd09555a81 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CSIDriverBuilder extends io.kubernetes.client.openapi.models.V1CSIDriverFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CSIDriverBuilder + extends io.kubernetes.client.openapi.models.V1CSIDriverFluentImpl< + io.kubernetes.client.openapi.models.V1CSIDriverBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CSIDriver, + io.kubernetes.client.openapi.models.V1CSIDriverBuilder> { public V1CSIDriverBuilder() { this(false); } + public V1CSIDriverBuilder(java.lang.Boolean validationEnabled) { this(new V1CSIDriver(), validationEnabled); } + public V1CSIDriverBuilder(io.kubernetes.client.openapi.models.V1CSIDriverFluent fluent) { this(fluent, false); } - public V1CSIDriverBuilder(io.kubernetes.client.openapi.models.V1CSIDriverFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CSIDriverBuilder( + io.kubernetes.client.openapi.models.V1CSIDriverFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CSIDriver(), validationEnabled); } - public V1CSIDriverBuilder(io.kubernetes.client.openapi.models.V1CSIDriverFluent fluent,io.kubernetes.client.openapi.models.V1CSIDriver instance) { + + public V1CSIDriverBuilder( + io.kubernetes.client.openapi.models.V1CSIDriverFluent fluent, + io.kubernetes.client.openapi.models.V1CSIDriver instance) { this(fluent, instance, false); } - public V1CSIDriverBuilder(io.kubernetes.client.openapi.models.V1CSIDriverFluent fluent,io.kubernetes.client.openapi.models.V1CSIDriver instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CSIDriverBuilder( + io.kubernetes.client.openapi.models.V1CSIDriverFluent fluent, + io.kubernetes.client.openapi.models.V1CSIDriver instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +55,17 @@ public V1CSIDriverBuilder(io.kubernetes.client.openapi.models.V1CSIDriverFluent< fluent.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1CSIDriverBuilder(io.kubernetes.client.openapi.models.V1CSIDriver instance) { - this(instance,false); + this(instance, false); } - public V1CSIDriverBuilder(io.kubernetes.client.openapi.models.V1CSIDriver instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CSIDriverBuilder( + io.kubernetes.client.openapi.models.V1CSIDriver instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +74,12 @@ public V1CSIDriverBuilder(io.kubernetes.client.openapi.models.V1CSIDriver instan this.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CSIDriverFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CSIDriver build() { V1CSIDriver buildable = new V1CSIDriver(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1CSIDriver build() { buildable.setSpec(fluent.getSpec()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CSIDriverBuilder that = (V1CSIDriverBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverFluent.java index 211afe541f..3efa89f67c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverFluent.java @@ -1,73 +1,109 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CSIDriverFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CSIDriverFluent< + A extends io.kubernetes.client.openapi.models.V1CSIDriverFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CSIDriverSpec getSpec(); + public io.kubernetes.client.openapi.models.V1CSIDriverSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1CSIDriverSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1CSIDriverSpec item); + + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1CSIDriverSpec item); + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CSIDriverSpec item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1CSIDriverSpec item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent< + io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested> { public N and(); + public N endSpec(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverFluentImpl.java index 1058a37eed..10ca1324e5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1CSIDriverFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CSIDriverFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CSIDriverFluent { + public V1CSIDriverFluentImpl() {} - /** - * Generated - */ -public class V1CSIDriverFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CSIDriverFluent{ - public V1CSIDriverFluentImpl() { - } public V1CSIDriverFluentImpl(io.kubernetes.client.openapi.models.V1CSIDriver instance) { this.withApiVersion(instance.getApiVersion()); @@ -21,158 +27,217 @@ public V1CSIDriverFluentImpl(io.kubernetes.client.openapi.models.V1CSIDriver ins this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1CSIDriverSpecBuilder spec; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1CSIDriverFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1CSIDriverFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CSIDriverSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1CSIDriverSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1CSIDriverSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1CSIDriverSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1CSIDriverSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1CSIDriverFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1CSIDriverSpec item) { + + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1CSIDriverSpec item) { return new io.kubernetes.client.openapi.models.V1CSIDriverFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1CSIDriverSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1CSIDriverSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CSIDriverSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1CSIDriverSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CSIDriverFluentImpl that = (V1CSIDriverFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1CSIDriverFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1CSIDriverFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1CSIDriverSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1CSIDriverSpecFluentImpl< + io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1CSIDriverFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1CSIDriverSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1CSIDriverSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1CSIDriverSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1CSIDriverSpecBuilder builder; + public N and() { return (N) V1CSIDriverFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverListBuilder.java index 28bdfc29af..a72313b192 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CSIDriverListBuilder extends io.kubernetes.client.openapi.models.V1CSIDriverListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CSIDriverListBuilder + extends io.kubernetes.client.openapi.models.V1CSIDriverListFluentImpl< + io.kubernetes.client.openapi.models.V1CSIDriverListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CSIDriverList, + io.kubernetes.client.openapi.models.V1CSIDriverListBuilder> { public V1CSIDriverListBuilder() { this(false); } + public V1CSIDriverListBuilder(java.lang.Boolean validationEnabled) { this(new V1CSIDriverList(), validationEnabled); } - public V1CSIDriverListBuilder(io.kubernetes.client.openapi.models.V1CSIDriverListFluent fluent) { + + public V1CSIDriverListBuilder( + io.kubernetes.client.openapi.models.V1CSIDriverListFluent fluent) { this(fluent, false); } - public V1CSIDriverListBuilder(io.kubernetes.client.openapi.models.V1CSIDriverListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CSIDriverListBuilder( + io.kubernetes.client.openapi.models.V1CSIDriverListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CSIDriverList(), validationEnabled); } - public V1CSIDriverListBuilder(io.kubernetes.client.openapi.models.V1CSIDriverListFluent fluent,io.kubernetes.client.openapi.models.V1CSIDriverList instance) { + + public V1CSIDriverListBuilder( + io.kubernetes.client.openapi.models.V1CSIDriverListFluent fluent, + io.kubernetes.client.openapi.models.V1CSIDriverList instance) { this(fluent, instance, false); } - public V1CSIDriverListBuilder(io.kubernetes.client.openapi.models.V1CSIDriverListFluent fluent,io.kubernetes.client.openapi.models.V1CSIDriverList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CSIDriverListBuilder( + io.kubernetes.client.openapi.models.V1CSIDriverListFluent fluent, + io.kubernetes.client.openapi.models.V1CSIDriverList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1CSIDriverListBuilder(io.kubernetes.client.openapi.models.V1CSIDriverLis fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1CSIDriverListBuilder(io.kubernetes.client.openapi.models.V1CSIDriverList instance) { - this(instance,false); + this(instance, false); } - public V1CSIDriverListBuilder(io.kubernetes.client.openapi.models.V1CSIDriverList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CSIDriverListBuilder( + io.kubernetes.client.openapi.models.V1CSIDriverList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1CSIDriverListBuilder(io.kubernetes.client.openapi.models.V1CSIDriverLis this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CSIDriverListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CSIDriverList build() { V1CSIDriverList buildable = new V1CSIDriverList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1CSIDriverList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CSIDriverListBuilder that = (V1CSIDriverListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverListFluent.java index de40c85062..121ef8f952 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverListFluent.java @@ -1,95 +1,153 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CSIDriverListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CSIDriverListFluent< + A extends io.kubernetes.client.openapi.models.V1CSIDriverListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSIDriver item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSIDriver item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSIDriver item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSIDriver item); + public A addToItems(io.kubernetes.client.openapi.models.V1CSIDriver... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1CSIDriver... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1CSIDriver buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1CSIDriver buildFirstItem(); + public io.kubernetes.client.openapi.models.V1CSIDriver buildLastItem(); - public io.kubernetes.client.openapi.models.V1CSIDriver buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1CSIDriver buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1CSIDriver... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1CSIDriver item); - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSIDriver item); - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1CSIDriver item); + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSIDriver item); + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CSIDriverFluent>{ + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CSIDriverFluent< + io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverListFluentImpl.java index 8da813224d..8b721a4a62 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1CSIDriverListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CSIDriverListFluent{ - public V1CSIDriverListFluentImpl() { - } +/** Generated */ +public class V1CSIDriverListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CSIDriverListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CSIDriverListFluent { + public V1CSIDriverListFluentImpl() {} + public V1CSIDriverListFluentImpl(io.kubernetes.client.openapi.models.V1CSIDriverList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,123 @@ public V1CSIDriverListFluentImpl(io.kubernetes.client.openapi.models.V1CSIDriver this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSIDriver item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CSIDriverBuilder builder = new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSIDriver item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1CSIDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSIDriver item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CSIDriverBuilder builder = new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSIDriver item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1CSIDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1CSIDriver... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CSIDriver item : items) {io.kubernetes.client.openapi.models.V1CSIDriverBuilder builder = new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1CSIDriver item : items) { + io.kubernetes.client.openapi.models.V1CSIDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CSIDriver item : items) {io.kubernetes.client.openapi.models.V1CSIDriverBuilder builder = new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1CSIDriver item : items) { + io.kubernetes.client.openapi.models.V1CSIDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1CSIDriver... items) { - for (io.kubernetes.client.openapi.models.V1CSIDriver item : items) {io.kubernetes.client.openapi.models.V1CSIDriverBuilder builder = new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1CSIDriver item : items) { + io.kubernetes.client.openapi.models.V1CSIDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1CSIDriver item : items) {io.kubernetes.client.openapi.models.V1CSIDriverBuilder builder = new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1CSIDriver item : items) { + io.kubernetes.client.openapi.models.V1CSIDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +157,274 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1CSIDriver buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1CSIDriver buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1CSIDriver buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1CSIDriver buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CSIDriverBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1CSIDriver buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1CSIDriverBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CSIDriverBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1CSIDriverBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1CSIDriver item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1CSIDriver item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1CSIDriver... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1CSIDriver item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1CSIDriver item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1CSIDriverListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1CSIDriver item) { - return new io.kubernetes.client.openapi.models.V1CSIDriverListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1CSIDriver item) { + return new io.kubernetes.client.openapi.models.V1CSIDriverListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSIDriver item) { - return new io.kubernetes.client.openapi.models.V1CSIDriverListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSIDriver item) { + return new io.kubernetes.client.openapi.models.V1CSIDriverListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1CSIDriverListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1CSIDriverListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1CSIDriverListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CSIDriverListFluentImpl that = (V1CSIDriverListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1CSIDriverFluentImpl> implements io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSIDriver item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1CSIDriverFluentImpl< + io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1CSIDriverListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSIDriver item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1CSIDriverBuilder(this); } + io.kubernetes.client.openapi.models.V1CSIDriverBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1CSIDriverListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1CSIDriverListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1CSIDriverListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1CSIDriverListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverSpecBuilder.java index 7d1f48515d..656e8fa2dc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CSIDriverSpecBuilder extends io.kubernetes.client.openapi.models.V1CSIDriverSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CSIDriverSpecBuilder + extends io.kubernetes.client.openapi.models.V1CSIDriverSpecFluentImpl< + io.kubernetes.client.openapi.models.V1CSIDriverSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CSIDriverSpec, + io.kubernetes.client.openapi.models.V1CSIDriverSpecBuilder> { public V1CSIDriverSpecBuilder() { this(false); } + public V1CSIDriverSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1CSIDriverSpec(), validationEnabled); } - public V1CSIDriverSpecBuilder(io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent fluent) { + + public V1CSIDriverSpecBuilder( + io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent fluent) { this(fluent, false); } - public V1CSIDriverSpecBuilder(io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CSIDriverSpecBuilder( + io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CSIDriverSpec(), validationEnabled); } - public V1CSIDriverSpecBuilder(io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent fluent,io.kubernetes.client.openapi.models.V1CSIDriverSpec instance) { + + public V1CSIDriverSpecBuilder( + io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent fluent, + io.kubernetes.client.openapi.models.V1CSIDriverSpec instance) { this(fluent, instance, false); } - public V1CSIDriverSpecBuilder(io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent fluent,io.kubernetes.client.openapi.models.V1CSIDriverSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CSIDriverSpecBuilder( + io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent fluent, + io.kubernetes.client.openapi.models.V1CSIDriverSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAttachRequired(instance.getAttachRequired()); fluent.withFsGroupPolicy(instance.getFsGroupPolicy()); @@ -35,13 +62,17 @@ public V1CSIDriverSpecBuilder(io.kubernetes.client.openapi.models.V1CSIDriverSpe fluent.withVolumeLifecycleModes(instance.getVolumeLifecycleModes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1CSIDriverSpecBuilder(io.kubernetes.client.openapi.models.V1CSIDriverSpec instance) { - this(instance,false); + this(instance, false); } - public V1CSIDriverSpecBuilder(io.kubernetes.client.openapi.models.V1CSIDriverSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CSIDriverSpecBuilder( + io.kubernetes.client.openapi.models.V1CSIDriverSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAttachRequired(instance.getAttachRequired()); this.withFsGroupPolicy(instance.getFsGroupPolicy()); @@ -56,10 +87,12 @@ public V1CSIDriverSpecBuilder(io.kubernetes.client.openapi.models.V1CSIDriverSpe this.withVolumeLifecycleModes(instance.getVolumeLifecycleModes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CSIDriverSpec build() { V1CSIDriverSpec buildable = new V1CSIDriverSpec(); buildable.setAttachRequired(fluent.getAttachRequired()); @@ -71,18 +104,23 @@ public io.kubernetes.client.openapi.models.V1CSIDriverSpec build() { buildable.setVolumeLifecycleModes(fluent.getVolumeLifecycleModes()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CSIDriverSpecBuilder that = (V1CSIDriverSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverSpecFluent.java index da0f3b08ba..45b4fee2a7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverSpecFluent.java @@ -1,94 +1,176 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CSIDriverSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CSIDriverSpecFluent< + A extends io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Boolean getAttachRequired(); + public A withAttachRequired(java.lang.Boolean attachRequired); + public java.lang.Boolean hasAttachRequired(); + public java.lang.String getFsGroupPolicy(); + public A withFsGroupPolicy(java.lang.String fsGroupPolicy); + public java.lang.Boolean hasFsGroupPolicy(); - - /** - * Method is deprecated. use withFsGroupPolicy instead. - */ + + /** Method is deprecated. use withFsGroupPolicy instead. */ @java.lang.Deprecated public A withNewFsGroupPolicy(java.lang.String original); + public java.lang.Boolean getPodInfoOnMount(); + public A withPodInfoOnMount(java.lang.Boolean podInfoOnMount); + public java.lang.Boolean hasPodInfoOnMount(); + public java.lang.Boolean getRequiresRepublish(); + public A withRequiresRepublish(java.lang.Boolean requiresRepublish); + public java.lang.Boolean hasRequiresRepublish(); + public java.lang.Boolean getStorageCapacity(); + public A withStorageCapacity(java.lang.Boolean storageCapacity); + public java.lang.Boolean hasStorageCapacity(); - public A addToTokenRequests(java.lang.Integer index,io.kubernetes.client.openapi.models.StorageV1TokenRequest item); - public A setToTokenRequests(java.lang.Integer index,io.kubernetes.client.openapi.models.StorageV1TokenRequest item); + + public A addToTokenRequests( + java.lang.Integer index, io.kubernetes.client.openapi.models.StorageV1TokenRequest item); + + public A setToTokenRequests( + java.lang.Integer index, io.kubernetes.client.openapi.models.StorageV1TokenRequest item); + public A addToTokenRequests(io.kubernetes.client.openapi.models.StorageV1TokenRequest... items); - public A addAllToTokenRequests(java.util.Collection items); - public A removeFromTokenRequests(io.kubernetes.client.openapi.models.StorageV1TokenRequest... items); - public A removeAllFromTokenRequests(java.util.Collection items); - public A removeMatchingFromTokenRequests(java.util.function.Predicate predicate); - + + public A addAllToTokenRequests( + java.util.Collection items); + + public A removeFromTokenRequests( + io.kubernetes.client.openapi.models.StorageV1TokenRequest... items); + + public A removeAllFromTokenRequests( + java.util.Collection items); + + public A removeMatchingFromTokenRequests( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildTokenRequests instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getTokenRequests(); - public java.util.List buildTokenRequests(); - public io.kubernetes.client.openapi.models.StorageV1TokenRequest buildTokenRequest(java.lang.Integer index); + public java.util.List + getTokenRequests(); + + public java.util.List + buildTokenRequests(); + + public io.kubernetes.client.openapi.models.StorageV1TokenRequest buildTokenRequest( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.StorageV1TokenRequest buildFirstTokenRequest(); + public io.kubernetes.client.openapi.models.StorageV1TokenRequest buildLastTokenRequest(); - public io.kubernetes.client.openapi.models.StorageV1TokenRequest buildMatchingTokenRequest(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingTokenRequest(java.util.function.Predicate predicate); - public A withTokenRequests(java.util.List tokenRequests); - public A withTokenRequests(io.kubernetes.client.openapi.models.StorageV1TokenRequest... tokenRequests); + + public io.kubernetes.client.openapi.models.StorageV1TokenRequest buildMatchingTokenRequest( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingTokenRequest( + java.util.function.Predicate + predicate); + + public A withTokenRequests( + java.util.List tokenRequests); + + public A withTokenRequests( + io.kubernetes.client.openapi.models.StorageV1TokenRequest... tokenRequests); + public java.lang.Boolean hasTokenRequests(); - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested addNewTokenRequest(); - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested addNewTokenRequestLike(io.kubernetes.client.openapi.models.StorageV1TokenRequest item); - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested setNewTokenRequestLike(java.lang.Integer index,io.kubernetes.client.openapi.models.StorageV1TokenRequest item); - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested editTokenRequest(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested editFirstTokenRequest(); - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested editLastTokenRequest(); - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested editMatchingTokenRequest(java.util.function.Predicate predicate); - public A addToVolumeLifecycleModes(java.lang.Integer index,java.lang.String item); - public A setToVolumeLifecycleModes(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + addNewTokenRequest(); + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + addNewTokenRequestLike(io.kubernetes.client.openapi.models.StorageV1TokenRequest item); + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + setNewTokenRequestLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.StorageV1TokenRequest item); + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + editTokenRequest(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + editFirstTokenRequest(); + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + editLastTokenRequest(); + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + editMatchingTokenRequest( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder> + predicate); + + public A addToVolumeLifecycleModes(java.lang.Integer index, java.lang.String item); + + public A setToVolumeLifecycleModes(java.lang.Integer index, java.lang.String item); + public A addToVolumeLifecycleModes(java.lang.String... items); + public A addAllToVolumeLifecycleModes(java.util.Collection items); + public A removeFromVolumeLifecycleModes(java.lang.String... items); + public A removeAllFromVolumeLifecycleModes(java.util.Collection items); + public java.util.List getVolumeLifecycleModes(); + public java.lang.String getVolumeLifecycleMode(java.lang.Integer index); + public java.lang.String getFirstVolumeLifecycleMode(); + public java.lang.String getLastVolumeLifecycleMode(); - public java.lang.String getMatchingVolumeLifecycleMode(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVolumeLifecycleMode(java.util.function.Predicate predicate); + + public java.lang.String getMatchingVolumeLifecycleMode( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingVolumeLifecycleMode( + java.util.function.Predicate predicate); + public A withVolumeLifecycleModes(java.util.List volumeLifecycleModes); + public A withVolumeLifecycleModes(java.lang.String... volumeLifecycleModes); + public java.lang.Boolean hasVolumeLifecycleModes(); + public A addNewVolumeLifecycleMode(java.lang.String original); - public interface TokenRequestsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent>{ + + public interface TokenRequestsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.StorageV1TokenRequestFluent< + io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested> { public N and(); + public N endTokenRequest(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverSpecFluentImpl.java index 8a8a25dfe6..49b1b60c29 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIDriverSpecFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1CSIDriverSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent{ - public V1CSIDriverSpecFluentImpl() { - } +/** Generated */ +public class V1CSIDriverSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent { + public V1CSIDriverSpecFluentImpl() {} + public V1CSIDriverSpecFluentImpl(io.kubernetes.client.openapi.models.V1CSIDriverSpec instance) { this.withAttachRequired(instance.getAttachRequired()); @@ -34,96 +36,189 @@ public V1CSIDriverSpecFluentImpl(io.kubernetes.client.openapi.models.V1CSIDriver this.withTokenRequests(instance.getTokenRequests()); this.withVolumeLifecycleModes(instance.getVolumeLifecycleModes()); - } + private java.lang.Boolean attachRequired; private java.lang.String fsGroupPolicy; private java.lang.Boolean podInfoOnMount; private java.lang.Boolean requiresRepublish; private java.lang.Boolean storageCapacity; - private java.util.ArrayList tokenRequests; + private java.util.ArrayList + tokenRequests; private java.util.List volumeLifecycleModes; + public java.lang.Boolean getAttachRequired() { return this.attachRequired; } + public A withAttachRequired(java.lang.Boolean attachRequired) { - this.attachRequired=attachRequired; return (A) this; + this.attachRequired = attachRequired; + return (A) this; } + public java.lang.Boolean hasAttachRequired() { return this.attachRequired != null; } + public java.lang.String getFsGroupPolicy() { return this.fsGroupPolicy; } + public A withFsGroupPolicy(java.lang.String fsGroupPolicy) { - this.fsGroupPolicy=fsGroupPolicy; return (A) this; + this.fsGroupPolicy = fsGroupPolicy; + return (A) this; } + public java.lang.Boolean hasFsGroupPolicy() { return this.fsGroupPolicy != null; } - - /** - * Method is deprecated. use withFsGroupPolicy instead. - */ + + /** Method is deprecated. use withFsGroupPolicy instead. */ @java.lang.Deprecated public A withNewFsGroupPolicy(java.lang.String original) { - return (A)withFsGroupPolicy(new String(original)); + return (A) withFsGroupPolicy(new String(original)); } + public java.lang.Boolean getPodInfoOnMount() { return this.podInfoOnMount; } + public A withPodInfoOnMount(java.lang.Boolean podInfoOnMount) { - this.podInfoOnMount=podInfoOnMount; return (A) this; + this.podInfoOnMount = podInfoOnMount; + return (A) this; } + public java.lang.Boolean hasPodInfoOnMount() { return this.podInfoOnMount != null; } + public java.lang.Boolean getRequiresRepublish() { return this.requiresRepublish; } + public A withRequiresRepublish(java.lang.Boolean requiresRepublish) { - this.requiresRepublish=requiresRepublish; return (A) this; + this.requiresRepublish = requiresRepublish; + return (A) this; } + public java.lang.Boolean hasRequiresRepublish() { return this.requiresRepublish != null; } + public java.lang.Boolean getStorageCapacity() { return this.storageCapacity; } + public A withStorageCapacity(java.lang.Boolean storageCapacity) { - this.storageCapacity=storageCapacity; return (A) this; + this.storageCapacity = storageCapacity; + return (A) this; } + public java.lang.Boolean hasStorageCapacity() { return this.storageCapacity != null; } - public A addToTokenRequests(java.lang.Integer index,io.kubernetes.client.openapi.models.StorageV1TokenRequest item) { - if (this.tokenRequests == null) {this.tokenRequests = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder = new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(item);_visitables.get("tokenRequests").add(index >= 0 ? index : _visitables.get("tokenRequests").size(), builder);this.tokenRequests.add(index >= 0 ? index : tokenRequests.size(), builder); return (A)this; + + public A addToTokenRequests( + java.lang.Integer index, io.kubernetes.client.openapi.models.StorageV1TokenRequest item) { + if (this.tokenRequests == null) { + this.tokenRequests = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder>(); + } + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder = + new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(item); + _visitables + .get("tokenRequests") + .add(index >= 0 ? index : _visitables.get("tokenRequests").size(), builder); + this.tokenRequests.add(index >= 0 ? index : tokenRequests.size(), builder); + return (A) this; } - public A setToTokenRequests(java.lang.Integer index,io.kubernetes.client.openapi.models.StorageV1TokenRequest item) { - if (this.tokenRequests == null) {this.tokenRequests = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder = new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(item); - if (index < 0 || index >= _visitables.get("tokenRequests").size()) { _visitables.get("tokenRequests").add(builder); } else { _visitables.get("tokenRequests").set(index, builder);} - if (index < 0 || index >= tokenRequests.size()) { tokenRequests.add(builder); } else { tokenRequests.set(index, builder);} - return (A)this; + + public A setToTokenRequests( + java.lang.Integer index, io.kubernetes.client.openapi.models.StorageV1TokenRequest item) { + if (this.tokenRequests == null) { + this.tokenRequests = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder>(); + } + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder = + new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(item); + if (index < 0 || index >= _visitables.get("tokenRequests").size()) { + _visitables.get("tokenRequests").add(builder); + } else { + _visitables.get("tokenRequests").set(index, builder); + } + if (index < 0 || index >= tokenRequests.size()) { + tokenRequests.add(builder); + } else { + tokenRequests.set(index, builder); + } + return (A) this; } + public A addToTokenRequests(io.kubernetes.client.openapi.models.StorageV1TokenRequest... items) { - if (this.tokenRequests == null) {this.tokenRequests = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.StorageV1TokenRequest item : items) {io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder = new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(item);_visitables.get("tokenRequests").add(builder);this.tokenRequests.add(builder);} return (A)this; + if (this.tokenRequests == null) { + this.tokenRequests = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder>(); + } + for (io.kubernetes.client.openapi.models.StorageV1TokenRequest item : items) { + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder = + new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(item); + _visitables.get("tokenRequests").add(builder); + this.tokenRequests.add(builder); + } + return (A) this; } - public A addAllToTokenRequests(java.util.Collection items) { - if (this.tokenRequests == null) {this.tokenRequests = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.StorageV1TokenRequest item : items) {io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder = new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(item);_visitables.get("tokenRequests").add(builder);this.tokenRequests.add(builder);} return (A)this; + + public A addAllToTokenRequests( + java.util.Collection items) { + if (this.tokenRequests == null) { + this.tokenRequests = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder>(); + } + for (io.kubernetes.client.openapi.models.StorageV1TokenRequest item : items) { + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder = + new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(item); + _visitables.get("tokenRequests").add(builder); + this.tokenRequests.add(builder); + } + return (A) this; } - public A removeFromTokenRequests(io.kubernetes.client.openapi.models.StorageV1TokenRequest... items) { - for (io.kubernetes.client.openapi.models.StorageV1TokenRequest item : items) {io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder = new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(item);_visitables.get("tokenRequests").remove(builder);if (this.tokenRequests != null) {this.tokenRequests.remove(builder);}} return (A)this; + + public A removeFromTokenRequests( + io.kubernetes.client.openapi.models.StorageV1TokenRequest... items) { + for (io.kubernetes.client.openapi.models.StorageV1TokenRequest item : items) { + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder = + new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(item); + _visitables.get("tokenRequests").remove(builder); + if (this.tokenRequests != null) { + this.tokenRequests.remove(builder); + } + } + return (A) this; } - public A removeAllFromTokenRequests(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.StorageV1TokenRequest item : items) {io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder = new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(item);_visitables.get("tokenRequests").remove(builder);if (this.tokenRequests != null) {this.tokenRequests.remove(builder);}} return (A)this; + + public A removeAllFromTokenRequests( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.StorageV1TokenRequest item : items) { + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder = + new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(item); + _visitables.get("tokenRequests").remove(builder); + if (this.tokenRequests != null) { + this.tokenRequests.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromTokenRequests(java.util.function.Predicate predicate) { + + public A removeMatchingFromTokenRequests( + java.util.function.Predicate + predicate) { if (tokenRequests == null) return (A) this; - final Iterator each = tokenRequests.iterator(); + final Iterator each = + tokenRequests.iterator(); final List visitables = _visitables.get("tokenRequests"); while (each.hasNext()) { io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder = each.next(); @@ -132,164 +227,337 @@ public A removeMatchingFromTokenRequests(java.util.function.Predicate getTokenRequests() { + public java.util.List + getTokenRequests() { return tokenRequests != null ? build(tokenRequests) : null; } - public java.util.List buildTokenRequests() { + + public java.util.List + buildTokenRequests() { return tokenRequests != null ? build(tokenRequests) : null; } - public io.kubernetes.client.openapi.models.StorageV1TokenRequest buildTokenRequest(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.StorageV1TokenRequest buildTokenRequest( + java.lang.Integer index) { return this.tokenRequests.get(index).build(); } + public io.kubernetes.client.openapi.models.StorageV1TokenRequest buildFirstTokenRequest() { return this.tokenRequests.get(0).build(); } + public io.kubernetes.client.openapi.models.StorageV1TokenRequest buildLastTokenRequest() { return this.tokenRequests.get(tokenRequests.size() - 1).build(); } - public io.kubernetes.client.openapi.models.StorageV1TokenRequest buildMatchingTokenRequest(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder item: tokenRequests) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.StorageV1TokenRequest buildMatchingTokenRequest( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder item : tokenRequests) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingTokenRequest(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder item: tokenRequests) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingTokenRequest( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder item : tokenRequests) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withTokenRequests(java.util.List tokenRequests) { - if (this.tokenRequests != null) { _visitables.get("tokenRequests").removeAll(this.tokenRequests);} - if (tokenRequests != null) {this.tokenRequests = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.StorageV1TokenRequest item : tokenRequests){this.addToTokenRequests(item);}} else { this.tokenRequests = null;} return (A) this; + + public A withTokenRequests( + java.util.List tokenRequests) { + if (this.tokenRequests != null) { + _visitables.get("tokenRequests").removeAll(this.tokenRequests); + } + if (tokenRequests != null) { + this.tokenRequests = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.StorageV1TokenRequest item : tokenRequests) { + this.addToTokenRequests(item); + } + } else { + this.tokenRequests = null; + } + return (A) this; } - public A withTokenRequests(io.kubernetes.client.openapi.models.StorageV1TokenRequest... tokenRequests) { - if (this.tokenRequests != null) {this.tokenRequests.clear();} - if (tokenRequests != null) {for (io.kubernetes.client.openapi.models.StorageV1TokenRequest item :tokenRequests){ this.addToTokenRequests(item);}} return (A) this; + + public A withTokenRequests( + io.kubernetes.client.openapi.models.StorageV1TokenRequest... tokenRequests) { + if (this.tokenRequests != null) { + this.tokenRequests.clear(); + } + if (tokenRequests != null) { + for (io.kubernetes.client.openapi.models.StorageV1TokenRequest item : tokenRequests) { + this.addToTokenRequests(item); + } + } + return (A) this; } + public java.lang.Boolean hasTokenRequests() { return tokenRequests != null && !tokenRequests.isEmpty(); } - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested addNewTokenRequest() { - return new io.kubernetes.client.openapi.models.V1CSIDriverSpecFluentImpl.TokenRequestsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + addNewTokenRequest() { + return new io.kubernetes.client.openapi.models.V1CSIDriverSpecFluentImpl + .TokenRequestsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested addNewTokenRequestLike(io.kubernetes.client.openapi.models.StorageV1TokenRequest item) { - return new io.kubernetes.client.openapi.models.V1CSIDriverSpecFluentImpl.TokenRequestsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + addNewTokenRequestLike(io.kubernetes.client.openapi.models.StorageV1TokenRequest item) { + return new io.kubernetes.client.openapi.models.V1CSIDriverSpecFluentImpl + .TokenRequestsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested setNewTokenRequestLike(java.lang.Integer index,io.kubernetes.client.openapi.models.StorageV1TokenRequest item) { - return new io.kubernetes.client.openapi.models.V1CSIDriverSpecFluentImpl.TokenRequestsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + setNewTokenRequestLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.StorageV1TokenRequest item) { + return new io.kubernetes.client.openapi.models.V1CSIDriverSpecFluentImpl + .TokenRequestsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested editTokenRequest(java.lang.Integer index) { - if (tokenRequests.size() <= index) throw new RuntimeException("Can't edit tokenRequests. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + editTokenRequest(java.lang.Integer index) { + if (tokenRequests.size() <= index) + throw new RuntimeException("Can't edit tokenRequests. Index exceeds size."); return setNewTokenRequestLike(index, buildTokenRequest(index)); } - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested editFirstTokenRequest() { - if (tokenRequests.size() == 0) throw new RuntimeException("Can't edit first tokenRequests. The list is empty."); + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + editFirstTokenRequest() { + if (tokenRequests.size() == 0) + throw new RuntimeException("Can't edit first tokenRequests. The list is empty."); return setNewTokenRequestLike(0, buildTokenRequest(0)); } - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested editLastTokenRequest() { + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + editLastTokenRequest() { int index = tokenRequests.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last tokenRequests. The list is empty."); return setNewTokenRequestLike(index, buildTokenRequest(index)); } - public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested editMatchingTokenRequest(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested + editMatchingTokenRequest( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder> + predicate) { int index = -1; - for (int i=0;i();} + + public A addToVolumeLifecycleModes(java.lang.Integer index, java.lang.String item) { + if (this.volumeLifecycleModes == null) { + this.volumeLifecycleModes = new java.util.ArrayList(); + } this.volumeLifecycleModes.add(index, item); - return (A)this; + return (A) this; } - public A setToVolumeLifecycleModes(java.lang.Integer index,java.lang.String item) { - if (this.volumeLifecycleModes == null) {this.volumeLifecycleModes = new java.util.ArrayList();} - this.volumeLifecycleModes.set(index, item); return (A)this; + + public A setToVolumeLifecycleModes(java.lang.Integer index, java.lang.String item) { + if (this.volumeLifecycleModes == null) { + this.volumeLifecycleModes = new java.util.ArrayList(); + } + this.volumeLifecycleModes.set(index, item); + return (A) this; } + public A addToVolumeLifecycleModes(java.lang.String... items) { - if (this.volumeLifecycleModes == null) {this.volumeLifecycleModes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.volumeLifecycleModes.add(item);} return (A)this; + if (this.volumeLifecycleModes == null) { + this.volumeLifecycleModes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.volumeLifecycleModes.add(item); + } + return (A) this; } + public A addAllToVolumeLifecycleModes(java.util.Collection items) { - if (this.volumeLifecycleModes == null) {this.volumeLifecycleModes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.volumeLifecycleModes.add(item);} return (A)this; + if (this.volumeLifecycleModes == null) { + this.volumeLifecycleModes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.volumeLifecycleModes.add(item); + } + return (A) this; } + public A removeFromVolumeLifecycleModes(java.lang.String... items) { - for (java.lang.String item : items) {if (this.volumeLifecycleModes!= null){ this.volumeLifecycleModes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.volumeLifecycleModes != null) { + this.volumeLifecycleModes.remove(item); + } + } + return (A) this; } + public A removeAllFromVolumeLifecycleModes(java.util.Collection items) { - for (java.lang.String item : items) {if (this.volumeLifecycleModes!= null){ this.volumeLifecycleModes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.volumeLifecycleModes != null) { + this.volumeLifecycleModes.remove(item); + } + } + return (A) this; } + public java.util.List getVolumeLifecycleModes() { return this.volumeLifecycleModes; } + public java.lang.String getVolumeLifecycleMode(java.lang.Integer index) { return this.volumeLifecycleModes.get(index); } + public java.lang.String getFirstVolumeLifecycleMode() { return this.volumeLifecycleModes.get(0); } + public java.lang.String getLastVolumeLifecycleMode() { return this.volumeLifecycleModes.get(volumeLifecycleModes.size() - 1); } - public java.lang.String getMatchingVolumeLifecycleMode(java.util.function.Predicate predicate) { - for (java.lang.String item: volumeLifecycleModes) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingVolumeLifecycleMode( + java.util.function.Predicate predicate) { + for (java.lang.String item : volumeLifecycleModes) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingVolumeLifecycleMode(java.util.function.Predicate predicate) { - for (java.lang.String item: volumeLifecycleModes) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVolumeLifecycleMode( + java.util.function.Predicate predicate) { + for (java.lang.String item : volumeLifecycleModes) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withVolumeLifecycleModes(java.util.List volumeLifecycleModes) { - if (volumeLifecycleModes != null) {this.volumeLifecycleModes = new java.util.ArrayList(); for (java.lang.String item : volumeLifecycleModes){this.addToVolumeLifecycleModes(item);}} else { this.volumeLifecycleModes = null;} return (A) this; + if (volumeLifecycleModes != null) { + this.volumeLifecycleModes = new java.util.ArrayList(); + for (java.lang.String item : volumeLifecycleModes) { + this.addToVolumeLifecycleModes(item); + } + } else { + this.volumeLifecycleModes = null; + } + return (A) this; } + public A withVolumeLifecycleModes(java.lang.String... volumeLifecycleModes) { - if (this.volumeLifecycleModes != null) {this.volumeLifecycleModes.clear();} - if (volumeLifecycleModes != null) {for (java.lang.String item :volumeLifecycleModes){ this.addToVolumeLifecycleModes(item);}} return (A) this; + if (this.volumeLifecycleModes != null) { + this.volumeLifecycleModes.clear(); + } + if (volumeLifecycleModes != null) { + for (java.lang.String item : volumeLifecycleModes) { + this.addToVolumeLifecycleModes(item); + } + } + return (A) this; } + public java.lang.Boolean hasVolumeLifecycleModes() { return volumeLifecycleModes != null && !volumeLifecycleModes.isEmpty(); } + public A addNewVolumeLifecycleMode(java.lang.String original) { - return (A)addToVolumeLifecycleModes(new String(original)); + return (A) addToVolumeLifecycleModes(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CSIDriverSpecFluentImpl that = (V1CSIDriverSpecFluentImpl) o; - if (attachRequired != null ? !attachRequired.equals(that.attachRequired) :that.attachRequired != null) return false; - if (fsGroupPolicy != null ? !fsGroupPolicy.equals(that.fsGroupPolicy) :that.fsGroupPolicy != null) return false; - if (podInfoOnMount != null ? !podInfoOnMount.equals(that.podInfoOnMount) :that.podInfoOnMount != null) return false; - if (requiresRepublish != null ? !requiresRepublish.equals(that.requiresRepublish) :that.requiresRepublish != null) return false; - if (storageCapacity != null ? !storageCapacity.equals(that.storageCapacity) :that.storageCapacity != null) return false; - if (tokenRequests != null ? !tokenRequests.equals(that.tokenRequests) :that.tokenRequests != null) return false; - if (volumeLifecycleModes != null ? !volumeLifecycleModes.equals(that.volumeLifecycleModes) :that.volumeLifecycleModes != null) return false; + if (attachRequired != null + ? !attachRequired.equals(that.attachRequired) + : that.attachRequired != null) return false; + if (fsGroupPolicy != null + ? !fsGroupPolicy.equals(that.fsGroupPolicy) + : that.fsGroupPolicy != null) return false; + if (podInfoOnMount != null + ? !podInfoOnMount.equals(that.podInfoOnMount) + : that.podInfoOnMount != null) return false; + if (requiresRepublish != null + ? !requiresRepublish.equals(that.requiresRepublish) + : that.requiresRepublish != null) return false; + if (storageCapacity != null + ? !storageCapacity.equals(that.storageCapacity) + : that.storageCapacity != null) return false; + if (tokenRequests != null + ? !tokenRequests.equals(that.tokenRequests) + : that.tokenRequests != null) return false; + if (volumeLifecycleModes != null + ? !volumeLifecycleModes.equals(that.volumeLifecycleModes) + : that.volumeLifecycleModes != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(attachRequired, fsGroupPolicy, podInfoOnMount, requiresRepublish, storageCapacity, tokenRequests, volumeLifecycleModes, super.hashCode()); + return java.util.Objects.hash( + attachRequired, + fsGroupPolicy, + podInfoOnMount, + requiresRepublish, + storageCapacity, + tokenRequests, + volumeLifecycleModes, + super.hashCode()); } - public class TokenRequestsNestedImpl extends io.kubernetes.client.openapi.models.StorageV1TokenRequestFluentImpl> implements io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested,io.kubernetes.client.fluent.Nested{ - TokenRequestsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.StorageV1TokenRequest item) { + + public class TokenRequestsNestedImpl + extends io.kubernetes.client.openapi.models.StorageV1TokenRequestFluentImpl< + io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested> + implements io.kubernetes.client.openapi.models.V1CSIDriverSpecFluent.TokenRequestsNested, + io.kubernetes.client.fluent.Nested { + TokenRequestsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.StorageV1TokenRequest item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(this, item); } + TokenRequestsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder(this); } + io.kubernetes.client.openapi.models.StorageV1TokenRequestBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1CSIDriverSpecFluentImpl.this.setToTokenRequests(index,builder.build()); + return (N) V1CSIDriverSpecFluentImpl.this.setToTokenRequests(index, builder.build()); } + public N endTokenRequest() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeBuilder.java index 565bb2a5f1..1791b2d9fb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CSINodeBuilder extends io.kubernetes.client.openapi.models.V1CSINodeFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CSINodeBuilder + extends io.kubernetes.client.openapi.models.V1CSINodeFluentImpl< + io.kubernetes.client.openapi.models.V1CSINodeBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CSINode, + io.kubernetes.client.openapi.models.V1CSINodeBuilder> { public V1CSINodeBuilder() { this(false); } + public V1CSINodeBuilder(java.lang.Boolean validationEnabled) { this(new V1CSINode(), validationEnabled); } + public V1CSINodeBuilder(io.kubernetes.client.openapi.models.V1CSINodeFluent fluent) { this(fluent, false); } - public V1CSINodeBuilder(io.kubernetes.client.openapi.models.V1CSINodeFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CSINodeBuilder( + io.kubernetes.client.openapi.models.V1CSINodeFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CSINode(), validationEnabled); } - public V1CSINodeBuilder(io.kubernetes.client.openapi.models.V1CSINodeFluent fluent,io.kubernetes.client.openapi.models.V1CSINode instance) { + + public V1CSINodeBuilder( + io.kubernetes.client.openapi.models.V1CSINodeFluent fluent, + io.kubernetes.client.openapi.models.V1CSINode instance) { this(fluent, instance, false); } - public V1CSINodeBuilder(io.kubernetes.client.openapi.models.V1CSINodeFluent fluent,io.kubernetes.client.openapi.models.V1CSINode instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CSINodeBuilder( + io.kubernetes.client.openapi.models.V1CSINodeFluent fluent, + io.kubernetes.client.openapi.models.V1CSINode instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +55,16 @@ public V1CSINodeBuilder(io.kubernetes.client.openapi.models.V1CSINodeFluent f fluent.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1CSINodeBuilder(io.kubernetes.client.openapi.models.V1CSINode instance) { - this(instance,false); + this(instance, false); } - public V1CSINodeBuilder(io.kubernetes.client.openapi.models.V1CSINode instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CSINodeBuilder( + io.kubernetes.client.openapi.models.V1CSINode instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +73,12 @@ public V1CSINodeBuilder(io.kubernetes.client.openapi.models.V1CSINode instance,j this.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CSINodeFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CSINode build() { V1CSINode buildable = new V1CSINode(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +87,23 @@ public io.kubernetes.client.openapi.models.V1CSINode build() { buildable.setSpec(fluent.getSpec()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CSINodeBuilder that = (V1CSINodeBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeDriverBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeDriverBuilder.java index 9565a171e6..271e9b6ff8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeDriverBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeDriverBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CSINodeDriverBuilder extends io.kubernetes.client.openapi.models.V1CSINodeDriverFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CSINodeDriverBuilder + extends io.kubernetes.client.openapi.models.V1CSINodeDriverFluentImpl< + io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CSINodeDriver, + io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder> { public V1CSINodeDriverBuilder() { this(false); } + public V1CSINodeDriverBuilder(java.lang.Boolean validationEnabled) { this(new V1CSINodeDriver(), validationEnabled); } - public V1CSINodeDriverBuilder(io.kubernetes.client.openapi.models.V1CSINodeDriverFluent fluent) { + + public V1CSINodeDriverBuilder( + io.kubernetes.client.openapi.models.V1CSINodeDriverFluent fluent) { this(fluent, false); } - public V1CSINodeDriverBuilder(io.kubernetes.client.openapi.models.V1CSINodeDriverFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CSINodeDriverBuilder( + io.kubernetes.client.openapi.models.V1CSINodeDriverFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CSINodeDriver(), validationEnabled); } - public V1CSINodeDriverBuilder(io.kubernetes.client.openapi.models.V1CSINodeDriverFluent fluent,io.kubernetes.client.openapi.models.V1CSINodeDriver instance) { + + public V1CSINodeDriverBuilder( + io.kubernetes.client.openapi.models.V1CSINodeDriverFluent fluent, + io.kubernetes.client.openapi.models.V1CSINodeDriver instance) { this(fluent, instance, false); } - public V1CSINodeDriverBuilder(io.kubernetes.client.openapi.models.V1CSINodeDriverFluent fluent,io.kubernetes.client.openapi.models.V1CSINodeDriver instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CSINodeDriverBuilder( + io.kubernetes.client.openapi.models.V1CSINodeDriverFluent fluent, + io.kubernetes.client.openapi.models.V1CSINodeDriver instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAllocatable(instance.getAllocatable()); fluent.withName(instance.getName()); @@ -29,13 +56,17 @@ public V1CSINodeDriverBuilder(io.kubernetes.client.openapi.models.V1CSINodeDrive fluent.withTopologyKeys(instance.getTopologyKeys()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1CSINodeDriverBuilder(io.kubernetes.client.openapi.models.V1CSINodeDriver instance) { - this(instance,false); + this(instance, false); } - public V1CSINodeDriverBuilder(io.kubernetes.client.openapi.models.V1CSINodeDriver instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CSINodeDriverBuilder( + io.kubernetes.client.openapi.models.V1CSINodeDriver instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAllocatable(instance.getAllocatable()); this.withName(instance.getName()); @@ -44,10 +75,12 @@ public V1CSINodeDriverBuilder(io.kubernetes.client.openapi.models.V1CSINodeDrive this.withTopologyKeys(instance.getTopologyKeys()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CSINodeDriverFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CSINodeDriver build() { V1CSINodeDriver buildable = new V1CSINodeDriver(); buildable.setAllocatable(fluent.getAllocatable()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1CSINodeDriver build() { buildable.setTopologyKeys(fluent.getTopologyKeys()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CSINodeDriverBuilder that = (V1CSINodeDriverBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeDriverFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeDriverFluent.java index ae784f017a..a2df9bee58 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeDriverFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeDriverFluent.java @@ -1,74 +1,111 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CSINodeDriverFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1CSINodeDriverFluent< + A extends io.kubernetes.client.openapi.models.V1CSINodeDriverFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildAllocatable instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeNodeResources getAllocatable(); + public io.kubernetes.client.openapi.models.V1VolumeNodeResources buildAllocatable(); + public A withAllocatable(io.kubernetes.client.openapi.models.V1VolumeNodeResources allocatable); + public java.lang.Boolean hasAllocatable(); - public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested withNewAllocatable(); - public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested withNewAllocatableLike(io.kubernetes.client.openapi.models.V1VolumeNodeResources item); - public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested editAllocatable(); - public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested editOrNewAllocatable(); - public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested editOrNewAllocatableLike(io.kubernetes.client.openapi.models.V1VolumeNodeResources item); + + public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested + withNewAllocatable(); + + public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested + withNewAllocatableLike(io.kubernetes.client.openapi.models.V1VolumeNodeResources item); + + public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested + editAllocatable(); + + public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested + editOrNewAllocatable(); + + public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested + editOrNewAllocatableLike(io.kubernetes.client.openapi.models.V1VolumeNodeResources item); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getNodeID(); + public A withNodeID(java.lang.String nodeID); + public java.lang.Boolean hasNodeID(); - - /** - * Method is deprecated. use withNodeID instead. - */ + + /** Method is deprecated. use withNodeID instead. */ @java.lang.Deprecated public A withNewNodeID(java.lang.String original); - public A addToTopologyKeys(java.lang.Integer index,java.lang.String item); - public A setToTopologyKeys(java.lang.Integer index,java.lang.String item); + + public A addToTopologyKeys(java.lang.Integer index, java.lang.String item); + + public A setToTopologyKeys(java.lang.Integer index, java.lang.String item); + public A addToTopologyKeys(java.lang.String... items); + public A addAllToTopologyKeys(java.util.Collection items); + public A removeFromTopologyKeys(java.lang.String... items); + public A removeAllFromTopologyKeys(java.util.Collection items); + public java.util.List getTopologyKeys(); + public java.lang.String getTopologyKey(java.lang.Integer index); + public java.lang.String getFirstTopologyKey(); + public java.lang.String getLastTopologyKey(); - public java.lang.String getMatchingTopologyKey(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingTopologyKey(java.util.function.Predicate predicate); + + public java.lang.String getMatchingTopologyKey( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingTopologyKey( + java.util.function.Predicate predicate); + public A withTopologyKeys(java.util.List topologyKeys); + public A withTopologyKeys(java.lang.String... topologyKeys); + public java.lang.Boolean hasTopologyKeys(); + public A addNewTopologyKey(java.lang.String original); - public interface AllocatableNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent>{ + + public interface AllocatableNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent< + io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested> { public N and(); + public N endAllocatable(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeDriverFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeDriverFluentImpl.java index 2080bbe433..ccb48dc44f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeDriverFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeDriverFluentImpl.java @@ -1,23 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1CSINodeDriverFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CSINodeDriverFluent{ - public V1CSINodeDriverFluentImpl() { - } +/** Generated */ +public class V1CSINodeDriverFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CSINodeDriverFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CSINodeDriverFluent { + public V1CSINodeDriverFluentImpl() {} + public V1CSINodeDriverFluentImpl(io.kubernetes.client.openapi.models.V1CSINodeDriver instance) { this.withAllocatable(instance.getAllocatable()); @@ -26,162 +27,270 @@ public V1CSINodeDriverFluentImpl(io.kubernetes.client.openapi.models.V1CSINodeDr this.withNodeID(instance.getNodeID()); this.withTopologyKeys(instance.getTopologyKeys()); - } + private io.kubernetes.client.openapi.models.V1VolumeNodeResourcesBuilder allocatable; private java.lang.String name; private java.lang.String nodeID; private java.util.List topologyKeys; - + /** * This method has been deprecated, please use method buildAllocatable instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeNodeResources getAllocatable() { - return this.allocatable!=null ?this.allocatable.build():null; + return this.allocatable != null ? this.allocatable.build() : null; } + public io.kubernetes.client.openapi.models.V1VolumeNodeResources buildAllocatable() { - return this.allocatable!=null ?this.allocatable.build():null; + return this.allocatable != null ? this.allocatable.build() : null; } + public A withAllocatable(io.kubernetes.client.openapi.models.V1VolumeNodeResources allocatable) { _visitables.get("allocatable").remove(this.allocatable); - if (allocatable!=null){ this.allocatable= new io.kubernetes.client.openapi.models.V1VolumeNodeResourcesBuilder(allocatable); _visitables.get("allocatable").add(this.allocatable);} return (A) this; + if (allocatable != null) { + this.allocatable = + new io.kubernetes.client.openapi.models.V1VolumeNodeResourcesBuilder(allocatable); + _visitables.get("allocatable").add(this.allocatable); + } + return (A) this; } + public java.lang.Boolean hasAllocatable() { return this.allocatable != null; } - public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested withNewAllocatable() { - return new io.kubernetes.client.openapi.models.V1CSINodeDriverFluentImpl.AllocatableNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested + withNewAllocatable() { + return new io.kubernetes.client.openapi.models.V1CSINodeDriverFluentImpl + .AllocatableNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested withNewAllocatableLike(io.kubernetes.client.openapi.models.V1VolumeNodeResources item) { - return new io.kubernetes.client.openapi.models.V1CSINodeDriverFluentImpl.AllocatableNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested + withNewAllocatableLike(io.kubernetes.client.openapi.models.V1VolumeNodeResources item) { + return new io.kubernetes.client.openapi.models.V1CSINodeDriverFluentImpl.AllocatableNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested editAllocatable() { + + public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested + editAllocatable() { return withNewAllocatableLike(getAllocatable()); } - public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested editOrNewAllocatable() { - return withNewAllocatableLike(getAllocatable() != null ? getAllocatable(): new io.kubernetes.client.openapi.models.V1VolumeNodeResourcesBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested + editOrNewAllocatable() { + return withNewAllocatableLike( + getAllocatable() != null + ? getAllocatable() + : new io.kubernetes.client.openapi.models.V1VolumeNodeResourcesBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested editOrNewAllocatableLike(io.kubernetes.client.openapi.models.V1VolumeNodeResources item) { - return withNewAllocatableLike(getAllocatable() != null ? getAllocatable(): item); + + public io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested + editOrNewAllocatableLike(io.kubernetes.client.openapi.models.V1VolumeNodeResources item) { + return withNewAllocatableLike(getAllocatable() != null ? getAllocatable() : item); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getNodeID() { return this.nodeID; } + public A withNodeID(java.lang.String nodeID) { - this.nodeID=nodeID; return (A) this; + this.nodeID = nodeID; + return (A) this; } + public java.lang.Boolean hasNodeID() { return this.nodeID != null; } - - /** - * Method is deprecated. use withNodeID instead. - */ + + /** Method is deprecated. use withNodeID instead. */ @java.lang.Deprecated public A withNewNodeID(java.lang.String original) { - return (A)withNodeID(new String(original)); + return (A) withNodeID(new String(original)); } - public A addToTopologyKeys(java.lang.Integer index,java.lang.String item) { - if (this.topologyKeys == null) {this.topologyKeys = new java.util.ArrayList();} + + public A addToTopologyKeys(java.lang.Integer index, java.lang.String item) { + if (this.topologyKeys == null) { + this.topologyKeys = new java.util.ArrayList(); + } this.topologyKeys.add(index, item); - return (A)this; + return (A) this; } - public A setToTopologyKeys(java.lang.Integer index,java.lang.String item) { - if (this.topologyKeys == null) {this.topologyKeys = new java.util.ArrayList();} - this.topologyKeys.set(index, item); return (A)this; + + public A setToTopologyKeys(java.lang.Integer index, java.lang.String item) { + if (this.topologyKeys == null) { + this.topologyKeys = new java.util.ArrayList(); + } + this.topologyKeys.set(index, item); + return (A) this; } + public A addToTopologyKeys(java.lang.String... items) { - if (this.topologyKeys == null) {this.topologyKeys = new java.util.ArrayList();} - for (java.lang.String item : items) {this.topologyKeys.add(item);} return (A)this; + if (this.topologyKeys == null) { + this.topologyKeys = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.topologyKeys.add(item); + } + return (A) this; } + public A addAllToTopologyKeys(java.util.Collection items) { - if (this.topologyKeys == null) {this.topologyKeys = new java.util.ArrayList();} - for (java.lang.String item : items) {this.topologyKeys.add(item);} return (A)this; + if (this.topologyKeys == null) { + this.topologyKeys = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.topologyKeys.add(item); + } + return (A) this; } + public A removeFromTopologyKeys(java.lang.String... items) { - for (java.lang.String item : items) {if (this.topologyKeys!= null){ this.topologyKeys.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.topologyKeys != null) { + this.topologyKeys.remove(item); + } + } + return (A) this; } + public A removeAllFromTopologyKeys(java.util.Collection items) { - for (java.lang.String item : items) {if (this.topologyKeys!= null){ this.topologyKeys.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.topologyKeys != null) { + this.topologyKeys.remove(item); + } + } + return (A) this; } + public java.util.List getTopologyKeys() { return this.topologyKeys; } + public java.lang.String getTopologyKey(java.lang.Integer index) { return this.topologyKeys.get(index); } + public java.lang.String getFirstTopologyKey() { return this.topologyKeys.get(0); } + public java.lang.String getLastTopologyKey() { return this.topologyKeys.get(topologyKeys.size() - 1); } - public java.lang.String getMatchingTopologyKey(java.util.function.Predicate predicate) { - for (java.lang.String item: topologyKeys) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingTopologyKey( + java.util.function.Predicate predicate) { + for (java.lang.String item : topologyKeys) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingTopologyKey(java.util.function.Predicate predicate) { - for (java.lang.String item: topologyKeys) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingTopologyKey( + java.util.function.Predicate predicate) { + for (java.lang.String item : topologyKeys) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withTopologyKeys(java.util.List topologyKeys) { - if (topologyKeys != null) {this.topologyKeys = new java.util.ArrayList(); for (java.lang.String item : topologyKeys){this.addToTopologyKeys(item);}} else { this.topologyKeys = null;} return (A) this; + if (topologyKeys != null) { + this.topologyKeys = new java.util.ArrayList(); + for (java.lang.String item : topologyKeys) { + this.addToTopologyKeys(item); + } + } else { + this.topologyKeys = null; + } + return (A) this; } + public A withTopologyKeys(java.lang.String... topologyKeys) { - if (this.topologyKeys != null) {this.topologyKeys.clear();} - if (topologyKeys != null) {for (java.lang.String item :topologyKeys){ this.addToTopologyKeys(item);}} return (A) this; + if (this.topologyKeys != null) { + this.topologyKeys.clear(); + } + if (topologyKeys != null) { + for (java.lang.String item : topologyKeys) { + this.addToTopologyKeys(item); + } + } + return (A) this; } + public java.lang.Boolean hasTopologyKeys() { return topologyKeys != null && !topologyKeys.isEmpty(); } + public A addNewTopologyKey(java.lang.String original) { - return (A)addToTopologyKeys(new String(original)); + return (A) addToTopologyKeys(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CSINodeDriverFluentImpl that = (V1CSINodeDriverFluentImpl) o; - if (allocatable != null ? !allocatable.equals(that.allocatable) :that.allocatable != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (nodeID != null ? !nodeID.equals(that.nodeID) :that.nodeID != null) return false; - if (topologyKeys != null ? !topologyKeys.equals(that.topologyKeys) :that.topologyKeys != null) return false; + if (allocatable != null ? !allocatable.equals(that.allocatable) : that.allocatable != null) + return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (nodeID != null ? !nodeID.equals(that.nodeID) : that.nodeID != null) return false; + if (topologyKeys != null ? !topologyKeys.equals(that.topologyKeys) : that.topologyKeys != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(allocatable, name, nodeID, topologyKeys, super.hashCode()); + return java.util.Objects.hash(allocatable, name, nodeID, topologyKeys, super.hashCode()); } - public class AllocatableNestedImpl extends io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluentImpl> implements io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested,io.kubernetes.client.fluent.Nested{ + + public class AllocatableNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluentImpl< + io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested> + implements io.kubernetes.client.openapi.models.V1CSINodeDriverFluent.AllocatableNested, + io.kubernetes.client.fluent.Nested { AllocatableNestedImpl(io.kubernetes.client.openapi.models.V1VolumeNodeResources item) { - this.builder = new io.kubernetes.client.openapi.models.V1VolumeNodeResourcesBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1VolumeNodeResourcesBuilder(this, item); } + AllocatableNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1VolumeNodeResourcesBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeNodeResourcesBuilder builder; + public N and() { return (N) V1CSINodeDriverFluentImpl.this.withAllocatable(builder.build()); } + public N endAllocatable() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeFluent.java index 66113483dc..06f3987aad 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeFluent.java @@ -1,73 +1,107 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CSINodeFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CSINodeFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CSINodeSpec getSpec(); + public io.kubernetes.client.openapi.models.V1CSINodeSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1CSINodeSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1CSINodeSpec item); + + public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1CSINodeSpec item); + public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CSINodeSpec item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1CSINodeSpec item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CSINodeSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CSINodeSpecFluent< + io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested> { public N and(); + public N endSpec(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeFluentImpl.java index 8f0e806ea9..e7e4ea8d55 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1CSINodeFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CSINodeFluent { + public V1CSINodeFluentImpl() {} - /** - * Generated - */ -public class V1CSINodeFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CSINodeFluent{ - public V1CSINodeFluentImpl() { - } public V1CSINodeFluentImpl(io.kubernetes.client.openapi.models.V1CSINode instance) { this.withApiVersion(instance.getApiVersion()); @@ -21,158 +26,216 @@ public V1CSINodeFluentImpl(io.kubernetes.client.openapi.models.V1CSINode instanc this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1CSINodeSpecBuilder spec; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1CSINodeFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1CSINodeFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CSINodeSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1CSINodeSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1CSINodeSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1CSINodeSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1CSINodeSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1CSINodeFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1CSINodeSpec item) { + + public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1CSINodeSpec item) { return new io.kubernetes.client.openapi.models.V1CSINodeFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1CSINodeSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1CSINodeSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CSINodeSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1CSINodeSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CSINodeFluentImpl that = (V1CSINodeFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1CSINodeFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1CSINodeFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1CSINodeSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1CSINodeSpecFluentImpl< + io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1CSINodeFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1CSINodeSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1CSINodeSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1CSINodeSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1CSINodeSpecBuilder builder; + public N and() { return (N) V1CSINodeFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeListBuilder.java index 7c2315c047..f93bfed34e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeListBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CSINodeListBuilder extends io.kubernetes.client.openapi.models.V1CSINodeListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CSINodeListBuilder + extends io.kubernetes.client.openapi.models.V1CSINodeListFluentImpl< + io.kubernetes.client.openapi.models.V1CSINodeListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CSINodeList, + io.kubernetes.client.openapi.models.V1CSINodeListBuilder> { public V1CSINodeListBuilder() { this(false); } + public V1CSINodeListBuilder(java.lang.Boolean validationEnabled) { this(new V1CSINodeList(), validationEnabled); } + public V1CSINodeListBuilder(io.kubernetes.client.openapi.models.V1CSINodeListFluent fluent) { this(fluent, false); } - public V1CSINodeListBuilder(io.kubernetes.client.openapi.models.V1CSINodeListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CSINodeListBuilder( + io.kubernetes.client.openapi.models.V1CSINodeListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CSINodeList(), validationEnabled); } - public V1CSINodeListBuilder(io.kubernetes.client.openapi.models.V1CSINodeListFluent fluent,io.kubernetes.client.openapi.models.V1CSINodeList instance) { + + public V1CSINodeListBuilder( + io.kubernetes.client.openapi.models.V1CSINodeListFluent fluent, + io.kubernetes.client.openapi.models.V1CSINodeList instance) { this(fluent, instance, false); } - public V1CSINodeListBuilder(io.kubernetes.client.openapi.models.V1CSINodeListFluent fluent,io.kubernetes.client.openapi.models.V1CSINodeList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CSINodeListBuilder( + io.kubernetes.client.openapi.models.V1CSINodeListFluent fluent, + io.kubernetes.client.openapi.models.V1CSINodeList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +55,17 @@ public V1CSINodeListBuilder(io.kubernetes.client.openapi.models.V1CSINodeListFlu fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1CSINodeListBuilder(io.kubernetes.client.openapi.models.V1CSINodeList instance) { - this(instance,false); + this(instance, false); } - public V1CSINodeListBuilder(io.kubernetes.client.openapi.models.V1CSINodeList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CSINodeListBuilder( + io.kubernetes.client.openapi.models.V1CSINodeList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +74,12 @@ public V1CSINodeListBuilder(io.kubernetes.client.openapi.models.V1CSINodeList in this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CSINodeListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CSINodeList build() { V1CSINodeList buildable = new V1CSINodeList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1CSINodeList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CSINodeListBuilder that = (V1CSINodeListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeListFluent.java index 6c022adae2..3b4cb993de 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeListFluent.java @@ -1,95 +1,146 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CSINodeListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CSINodeListFluent< + A extends io.kubernetes.client.openapi.models.V1CSINodeListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINode item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINode item); + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINode item); + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINode item); + public A addToItems(io.kubernetes.client.openapi.models.V1CSINode... items); + public A addAllToItems(java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1CSINode... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1CSINode buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1CSINode buildFirstItem(); + public io.kubernetes.client.openapi.models.V1CSINode buildLastItem(); - public io.kubernetes.client.openapi.models.V1CSINode buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1CSINode buildMatchingItem( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1CSINode... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1CSINode item); - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINode item); - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1CSINode item); + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINode item); + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CSINodeFluent>{ + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CSINodeFluent< + io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeListFluentImpl.java index d901447090..cd6d8b076b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1CSINodeListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CSINodeListFluent{ - public V1CSINodeListFluentImpl() { - } +/** Generated */ +public class V1CSINodeListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CSINodeListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CSINodeListFluent { + public V1CSINodeListFluentImpl() {} + public V1CSINodeListFluentImpl(io.kubernetes.client.openapi.models.V1CSINodeList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,117 @@ public V1CSINodeListFluentImpl(io.kubernetes.client.openapi.models.V1CSINodeList this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINode item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CSINodeBuilder builder = new io.kubernetes.client.openapi.models.V1CSINodeBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINode item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1CSINodeBuilder builder = + new io.kubernetes.client.openapi.models.V1CSINodeBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINode item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CSINodeBuilder builder = new io.kubernetes.client.openapi.models.V1CSINodeBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINode item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1CSINodeBuilder builder = + new io.kubernetes.client.openapi.models.V1CSINodeBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1CSINode... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CSINode item : items) {io.kubernetes.client.openapi.models.V1CSINodeBuilder builder = new io.kubernetes.client.openapi.models.V1CSINodeBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1CSINode item : items) { + io.kubernetes.client.openapi.models.V1CSINodeBuilder builder = + new io.kubernetes.client.openapi.models.V1CSINodeBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CSINode item : items) {io.kubernetes.client.openapi.models.V1CSINodeBuilder builder = new io.kubernetes.client.openapi.models.V1CSINodeBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1CSINode item : items) { + io.kubernetes.client.openapi.models.V1CSINodeBuilder builder = + new io.kubernetes.client.openapi.models.V1CSINodeBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1CSINode... items) { - for (io.kubernetes.client.openapi.models.V1CSINode item : items) {io.kubernetes.client.openapi.models.V1CSINodeBuilder builder = new io.kubernetes.client.openapi.models.V1CSINodeBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1CSINode item : items) { + io.kubernetes.client.openapi.models.V1CSINodeBuilder builder = + new io.kubernetes.client.openapi.models.V1CSINodeBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1CSINode item : items) {io.kubernetes.client.openapi.models.V1CSINodeBuilder builder = new io.kubernetes.client.openapi.models.V1CSINodeBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1CSINode item : items) { + io.kubernetes.client.openapi.models.V1CSINodeBuilder builder = + new io.kubernetes.client.openapi.models.V1CSINodeBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +151,272 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1CSINode buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1CSINode buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1CSINode buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1CSINode buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CSINodeBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1CSINode buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1CSINodeBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CSINodeBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1CSINodeBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1CSINode item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1CSINode item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1CSINode... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1CSINode item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1CSINode item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1CSINodeListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1CSINode item) { - return new io.kubernetes.client.openapi.models.V1CSINodeListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1CSINode item) { + return new io.kubernetes.client.openapi.models.V1CSINodeListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINode item) { - return new io.kubernetes.client.openapi.models.V1CSINodeListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINode item) { + return new io.kubernetes.client.openapi.models.V1CSINodeListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1CSINodeListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { return new io.kubernetes.client.openapi.models.V1CSINodeListFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CSINodeListFluentImpl that = (V1CSINodeListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1CSINodeFluentImpl> implements io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINode item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1CSINodeFluentImpl< + io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1CSINodeListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINode item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1CSINodeBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1CSINodeBuilder(this); } + io.kubernetes.client.openapi.models.V1CSINodeBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1CSINodeListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1CSINodeListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1CSINodeListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1CSINodeListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeSpecBuilder.java index d09ce6c5bc..1c1e82f2fa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeSpecBuilder.java @@ -1,58 +1,95 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CSINodeSpecBuilder extends io.kubernetes.client.openapi.models.V1CSINodeSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CSINodeSpecBuilder + extends io.kubernetes.client.openapi.models.V1CSINodeSpecFluentImpl< + io.kubernetes.client.openapi.models.V1CSINodeSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CSINodeSpec, + io.kubernetes.client.openapi.models.V1CSINodeSpecBuilder> { public V1CSINodeSpecBuilder() { this(false); } + public V1CSINodeSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1CSINodeSpec(), validationEnabled); } + public V1CSINodeSpecBuilder(io.kubernetes.client.openapi.models.V1CSINodeSpecFluent fluent) { this(fluent, false); } - public V1CSINodeSpecBuilder(io.kubernetes.client.openapi.models.V1CSINodeSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CSINodeSpecBuilder( + io.kubernetes.client.openapi.models.V1CSINodeSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CSINodeSpec(), validationEnabled); } - public V1CSINodeSpecBuilder(io.kubernetes.client.openapi.models.V1CSINodeSpecFluent fluent,io.kubernetes.client.openapi.models.V1CSINodeSpec instance) { + + public V1CSINodeSpecBuilder( + io.kubernetes.client.openapi.models.V1CSINodeSpecFluent fluent, + io.kubernetes.client.openapi.models.V1CSINodeSpec instance) { this(fluent, instance, false); } - public V1CSINodeSpecBuilder(io.kubernetes.client.openapi.models.V1CSINodeSpecFluent fluent,io.kubernetes.client.openapi.models.V1CSINodeSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CSINodeSpecBuilder( + io.kubernetes.client.openapi.models.V1CSINodeSpecFluent fluent, + io.kubernetes.client.openapi.models.V1CSINodeSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDrivers(instance.getDrivers()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1CSINodeSpecBuilder(io.kubernetes.client.openapi.models.V1CSINodeSpec instance) { - this(instance,false); + this(instance, false); } - public V1CSINodeSpecBuilder(io.kubernetes.client.openapi.models.V1CSINodeSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CSINodeSpecBuilder( + io.kubernetes.client.openapi.models.V1CSINodeSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDrivers(instance.getDrivers()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CSINodeSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CSINodeSpec build() { V1CSINodeSpec buildable = new V1CSINodeSpec(); buildable.setDrivers(fluent.getDrivers()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CSINodeSpecBuilder that = (V1CSINodeSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeSpecFluent.java index 0d1d5b89bd..f555cc55d0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeSpecFluent.java @@ -1,57 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CSINodeSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToDrivers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINodeDriver item); - public A setToDrivers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINodeDriver item); +/** Generated */ +public interface V1CSINodeSpecFluent< + A extends io.kubernetes.client.openapi.models.V1CSINodeSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToDrivers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINodeDriver item); + + public A setToDrivers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINodeDriver item); + public A addToDrivers(io.kubernetes.client.openapi.models.V1CSINodeDriver... items); - public A addAllToDrivers(java.util.Collection items); + + public A addAllToDrivers( + java.util.Collection items); + public A removeFromDrivers(io.kubernetes.client.openapi.models.V1CSINodeDriver... items); - public A removeAllFromDrivers(java.util.Collection items); - public A removeMatchingFromDrivers(java.util.function.Predicate predicate); - + + public A removeAllFromDrivers( + java.util.Collection items); + + public A removeMatchingFromDrivers( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildDrivers instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getDrivers(); + public java.util.List buildDrivers(); + public io.kubernetes.client.openapi.models.V1CSINodeDriver buildDriver(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1CSINodeDriver buildFirstDriver(); + public io.kubernetes.client.openapi.models.V1CSINodeDriver buildLastDriver(); - public io.kubernetes.client.openapi.models.V1CSINodeDriver buildMatchingDriver(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingDriver(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1CSINodeDriver buildMatchingDriver( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingDriver( + java.util.function.Predicate + predicate); + public A withDrivers(java.util.List drivers); + public A withDrivers(io.kubernetes.client.openapi.models.V1CSINodeDriver... drivers); + public java.lang.Boolean hasDrivers(); + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested addNewDriver(); - public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested addNewDriverLike(io.kubernetes.client.openapi.models.V1CSINodeDriver item); - public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested setNewDriverLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINodeDriver item); - public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested editDriver(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested addNewDriverLike( + io.kubernetes.client.openapi.models.V1CSINodeDriver item); + + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested setNewDriverLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINodeDriver item); + + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested editDriver( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested editFirstDriver(); + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested editLastDriver(); - public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested editMatchingDriver(java.util.function.Predicate predicate); - public interface DriversNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CSINodeDriverFluent>{ + + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested + editMatchingDriver( + java.util.function.Predicate + predicate); + + public interface DriversNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CSINodeDriverFluent< + io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested> { public N and(); + public N endDriver(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeSpecFluentImpl.java index 35d2efd7f7..b2111cd81c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSINodeSpecFluentImpl.java @@ -1,57 +1,127 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1CSINodeSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CSINodeSpecFluent{ - public V1CSINodeSpecFluentImpl() { - } +/** Generated */ +public class V1CSINodeSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CSINodeSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CSINodeSpecFluent { + public V1CSINodeSpecFluentImpl() {} + public V1CSINodeSpecFluentImpl(io.kubernetes.client.openapi.models.V1CSINodeSpec instance) { this.withDrivers(instance.getDrivers()); - } + private java.util.ArrayList drivers; - public A addToDrivers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINodeDriver item) { - if (this.drivers == null) {this.drivers = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder = new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(item);_visitables.get("drivers").add(index >= 0 ? index : _visitables.get("drivers").size(), builder);this.drivers.add(index >= 0 ? index : drivers.size(), builder); return (A)this; + + public A addToDrivers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINodeDriver item) { + if (this.drivers == null) { + this.drivers = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(item); + _visitables.get("drivers").add(index >= 0 ? index : _visitables.get("drivers").size(), builder); + this.drivers.add(index >= 0 ? index : drivers.size(), builder); + return (A) this; } - public A setToDrivers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINodeDriver item) { - if (this.drivers == null) {this.drivers = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder = new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(item); - if (index < 0 || index >= _visitables.get("drivers").size()) { _visitables.get("drivers").add(builder); } else { _visitables.get("drivers").set(index, builder);} - if (index < 0 || index >= drivers.size()) { drivers.add(builder); } else { drivers.set(index, builder);} - return (A)this; + + public A setToDrivers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINodeDriver item) { + if (this.drivers == null) { + this.drivers = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(item); + if (index < 0 || index >= _visitables.get("drivers").size()) { + _visitables.get("drivers").add(builder); + } else { + _visitables.get("drivers").set(index, builder); + } + if (index < 0 || index >= drivers.size()) { + drivers.add(builder); + } else { + drivers.set(index, builder); + } + return (A) this; } + public A addToDrivers(io.kubernetes.client.openapi.models.V1CSINodeDriver... items) { - if (this.drivers == null) {this.drivers = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CSINodeDriver item : items) {io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder = new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(item);_visitables.get("drivers").add(builder);this.drivers.add(builder);} return (A)this; + if (this.drivers == null) { + this.drivers = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1CSINodeDriver item : items) { + io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(item); + _visitables.get("drivers").add(builder); + this.drivers.add(builder); + } + return (A) this; } - public A addAllToDrivers(java.util.Collection items) { - if (this.drivers == null) {this.drivers = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CSINodeDriver item : items) {io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder = new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(item);_visitables.get("drivers").add(builder);this.drivers.add(builder);} return (A)this; + + public A addAllToDrivers( + java.util.Collection items) { + if (this.drivers == null) { + this.drivers = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1CSINodeDriver item : items) { + io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(item); + _visitables.get("drivers").add(builder); + this.drivers.add(builder); + } + return (A) this; } + public A removeFromDrivers(io.kubernetes.client.openapi.models.V1CSINodeDriver... items) { - for (io.kubernetes.client.openapi.models.V1CSINodeDriver item : items) {io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder = new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(item);_visitables.get("drivers").remove(builder);if (this.drivers != null) {this.drivers.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1CSINodeDriver item : items) { + io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(item); + _visitables.get("drivers").remove(builder); + if (this.drivers != null) { + this.drivers.remove(builder); + } + } + return (A) this; } - public A removeAllFromDrivers(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1CSINodeDriver item : items) {io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder = new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(item);_visitables.get("drivers").remove(builder);if (this.drivers != null) {this.drivers.remove(builder);}} return (A)this; + + public A removeAllFromDrivers( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1CSINodeDriver item : items) { + io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(item); + _visitables.get("drivers").remove(builder); + if (this.drivers != null) { + this.drivers.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromDrivers(java.util.function.Predicate predicate) { + + public A removeMatchingFromDrivers( + java.util.function.Predicate + predicate) { if (drivers == null) return (A) this; - final Iterator each = drivers.iterator(); + final Iterator each = + drivers.iterator(); final List visitables = _visitables.get("drivers"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder = each.next(); @@ -60,104 +130,177 @@ public A removeMatchingFromDrivers(java.util.function.Predicate getDrivers() { return drivers != null ? build(drivers) : null; } + public java.util.List buildDrivers() { return drivers != null ? build(drivers) : null; } + public io.kubernetes.client.openapi.models.V1CSINodeDriver buildDriver(java.lang.Integer index) { return this.drivers.get(index).build(); } + public io.kubernetes.client.openapi.models.V1CSINodeDriver buildFirstDriver() { return this.drivers.get(0).build(); } + public io.kubernetes.client.openapi.models.V1CSINodeDriver buildLastDriver() { return this.drivers.get(drivers.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1CSINodeDriver buildMatchingDriver(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder item: drivers) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1CSINodeDriver buildMatchingDriver( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder item : drivers) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingDriver(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder item: drivers) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingDriver( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder item : drivers) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withDrivers(java.util.List drivers) { - if (this.drivers != null) { _visitables.get("drivers").removeAll(this.drivers);} - if (drivers != null) {this.drivers = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1CSINodeDriver item : drivers){this.addToDrivers(item);}} else { this.drivers = null;} return (A) this; + + public A withDrivers( + java.util.List drivers) { + if (this.drivers != null) { + _visitables.get("drivers").removeAll(this.drivers); + } + if (drivers != null) { + this.drivers = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1CSINodeDriver item : drivers) { + this.addToDrivers(item); + } + } else { + this.drivers = null; + } + return (A) this; } + public A withDrivers(io.kubernetes.client.openapi.models.V1CSINodeDriver... drivers) { - if (this.drivers != null) {this.drivers.clear();} - if (drivers != null) {for (io.kubernetes.client.openapi.models.V1CSINodeDriver item :drivers){ this.addToDrivers(item);}} return (A) this; + if (this.drivers != null) { + this.drivers.clear(); + } + if (drivers != null) { + for (io.kubernetes.client.openapi.models.V1CSINodeDriver item : drivers) { + this.addToDrivers(item); + } + } + return (A) this; } + public java.lang.Boolean hasDrivers() { return drivers != null && !drivers.isEmpty(); } + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested addNewDriver() { return new io.kubernetes.client.openapi.models.V1CSINodeSpecFluentImpl.DriversNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested addNewDriverLike(io.kubernetes.client.openapi.models.V1CSINodeDriver item) { - return new io.kubernetes.client.openapi.models.V1CSINodeSpecFluentImpl.DriversNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested addNewDriverLike( + io.kubernetes.client.openapi.models.V1CSINodeDriver item) { + return new io.kubernetes.client.openapi.models.V1CSINodeSpecFluentImpl.DriversNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested setNewDriverLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINodeDriver item) { - return new io.kubernetes.client.openapi.models.V1CSINodeSpecFluentImpl.DriversNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested setNewDriverLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINodeDriver item) { + return new io.kubernetes.client.openapi.models.V1CSINodeSpecFluentImpl.DriversNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested editDriver(java.lang.Integer index) { - if (drivers.size() <= index) throw new RuntimeException("Can't edit drivers. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested editDriver( + java.lang.Integer index) { + if (drivers.size() <= index) + throw new RuntimeException("Can't edit drivers. Index exceeds size."); return setNewDriverLike(index, buildDriver(index)); } - public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested editFirstDriver() { - if (drivers.size() == 0) throw new RuntimeException("Can't edit first drivers. The list is empty."); + + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested + editFirstDriver() { + if (drivers.size() == 0) + throw new RuntimeException("Can't edit first drivers. The list is empty."); return setNewDriverLike(0, buildDriver(0)); } + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested editLastDriver() { int index = drivers.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last drivers. The list is empty."); return setNewDriverLike(index, buildDriver(index)); } - public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested editMatchingDriver(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested + editMatchingDriver( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1CSINodeDriverFluentImpl> implements io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested,io.kubernetes.client.fluent.Nested{ - DriversNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CSINodeDriver item) { + + public class DriversNestedImpl + extends io.kubernetes.client.openapi.models.V1CSINodeDriverFluentImpl< + io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested> + implements io.kubernetes.client.openapi.models.V1CSINodeSpecFluent.DriversNested, + io.kubernetes.client.fluent.Nested { + DriversNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CSINodeDriver item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(this, item); } + DriversNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder(this); } + io.kubernetes.client.openapi.models.V1CSINodeDriverBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1CSINodeSpecFluentImpl.this.setToDrivers(index,builder.build()); + return (N) V1CSINodeSpecFluentImpl.this.setToDrivers(index, builder.build()); } + public N endDriver() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIPersistentVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIPersistentVolumeSourceBuilder.java index 75c8d20954..07fed7826f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIPersistentVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIPersistentVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CSIPersistentVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CSIPersistentVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource, + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceBuilder> { public V1CSIPersistentVolumeSourceBuilder() { this(false); } + public V1CSIPersistentVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1CSIPersistentVolumeSource(), validationEnabled); } - public V1CSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent fluent) { + + public V1CSIPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent fluent) { this(fluent, false); } - public V1CSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CSIPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CSIPersistentVolumeSource(), validationEnabled); } - public V1CSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource instance) { + + public V1CSIPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource instance) { this(fluent, instance, false); } - public V1CSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CSIPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withControllerExpandSecretRef(instance.getControllerExpandSecretRef()); fluent.withControllerPublishSecretRef(instance.getControllerPublishSecretRef()); @@ -39,13 +66,18 @@ public V1CSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1 fluent.withVolumeHandle(instance.getVolumeHandle()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource instance) { - this(instance,false); + + public V1CSIPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource instance) { + this(instance, false); } - public V1CSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CSIPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withControllerExpandSecretRef(instance.getControllerExpandSecretRef()); this.withControllerPublishSecretRef(instance.getControllerPublishSecretRef()); @@ -64,10 +96,12 @@ public V1CSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1 this.withVolumeHandle(instance.getVolumeHandle()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource build() { V1CSIPersistentVolumeSource buildable = new V1CSIPersistentVolumeSource(); buildable.setControllerExpandSecretRef(fluent.getControllerExpandSecretRef()); @@ -81,18 +115,23 @@ public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource build() { buildable.setVolumeHandle(fluent.getVolumeHandle()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CSIPersistentVolumeSourceBuilder that = (V1CSIPersistentVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIPersistentVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIPersistentVolumeSourceFluent.java index ed2b26dfc8..cb93eff948 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIPersistentVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIPersistentVolumeSourceFluent.java @@ -1,134 +1,278 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1CSIPersistentVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1CSIPersistentVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildControllerExpandSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getControllerExpandSecretRef(); + public io.kubernetes.client.openapi.models.V1SecretReference buildControllerExpandSecretRef(); - public A withControllerExpandSecretRef(io.kubernetes.client.openapi.models.V1SecretReference controllerExpandSecretRef); + + public A withControllerExpandSecretRef( + io.kubernetes.client.openapi.models.V1SecretReference controllerExpandSecretRef); + public java.lang.Boolean hasControllerExpandSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerExpandSecretRefNested withNewControllerExpandSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerExpandSecretRefNested withNewControllerExpandSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerExpandSecretRefNested editControllerExpandSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerExpandSecretRefNested editOrNewControllerExpandSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerExpandSecretRefNested editOrNewControllerExpandSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); - + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerExpandSecretRefNested< + A> + withNewControllerExpandSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerExpandSecretRefNested< + A> + withNewControllerExpandSecretRefLike( + io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerExpandSecretRefNested< + A> + editControllerExpandSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerExpandSecretRefNested< + A> + editOrNewControllerExpandSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerExpandSecretRefNested< + A> + editOrNewControllerExpandSecretRefLike( + io.kubernetes.client.openapi.models.V1SecretReference item); + /** * This method has been deprecated, please use method buildControllerPublishSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getControllerPublishSecretRef(); + public io.kubernetes.client.openapi.models.V1SecretReference buildControllerPublishSecretRef(); - public A withControllerPublishSecretRef(io.kubernetes.client.openapi.models.V1SecretReference controllerPublishSecretRef); + + public A withControllerPublishSecretRef( + io.kubernetes.client.openapi.models.V1SecretReference controllerPublishSecretRef); + public java.lang.Boolean hasControllerPublishSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerPublishSecretRefNested withNewControllerPublishSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerPublishSecretRefNested withNewControllerPublishSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerPublishSecretRefNested editControllerPublishSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerPublishSecretRefNested editOrNewControllerPublishSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerPublishSecretRefNested editOrNewControllerPublishSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerPublishSecretRefNested< + A> + withNewControllerPublishSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerPublishSecretRefNested< + A> + withNewControllerPublishSecretRefLike( + io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerPublishSecretRefNested< + A> + editControllerPublishSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerPublishSecretRefNested< + A> + editOrNewControllerPublishSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerPublishSecretRefNested< + A> + editOrNewControllerPublishSecretRefLike( + io.kubernetes.client.openapi.models.V1SecretReference item); + public java.lang.String getDriver(); + public A withDriver(java.lang.String driver); + public java.lang.Boolean hasDriver(); - - /** - * Method is deprecated. use withDriver instead. - */ + + /** Method is deprecated. use withDriver instead. */ @java.lang.Deprecated public A withNewDriver(java.lang.String original); + public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); - + /** * This method has been deprecated, please use method buildNodePublishSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getNodePublishSecretRef(); + public io.kubernetes.client.openapi.models.V1SecretReference buildNodePublishSecretRef(); - public A withNodePublishSecretRef(io.kubernetes.client.openapi.models.V1SecretReference nodePublishSecretRef); + + public A withNodePublishSecretRef( + io.kubernetes.client.openapi.models.V1SecretReference nodePublishSecretRef); + public java.lang.Boolean hasNodePublishSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodePublishSecretRefNested withNewNodePublishSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodePublishSecretRefNested withNewNodePublishSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodePublishSecretRefNested editNodePublishSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodePublishSecretRefNested editOrNewNodePublishSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodePublishSecretRefNested editOrNewNodePublishSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); - + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodePublishSecretRefNested< + A> + withNewNodePublishSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodePublishSecretRefNested< + A> + withNewNodePublishSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodePublishSecretRefNested< + A> + editNodePublishSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodePublishSecretRefNested< + A> + editOrNewNodePublishSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodePublishSecretRefNested< + A> + editOrNewNodePublishSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + /** * This method has been deprecated, please use method buildNodeStageSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getNodeStageSecretRef(); + public io.kubernetes.client.openapi.models.V1SecretReference buildNodeStageSecretRef(); - public A withNodeStageSecretRef(io.kubernetes.client.openapi.models.V1SecretReference nodeStageSecretRef); + + public A withNodeStageSecretRef( + io.kubernetes.client.openapi.models.V1SecretReference nodeStageSecretRef); + public java.lang.Boolean hasNodeStageSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodeStageSecretRefNested withNewNodeStageSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodeStageSecretRefNested withNewNodeStageSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodeStageSecretRefNested editNodeStageSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodeStageSecretRefNested editOrNewNodeStageSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodeStageSecretRefNested editOrNewNodeStageSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodeStageSecretRefNested< + A> + withNewNodeStageSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodeStageSecretRefNested< + A> + withNewNodeStageSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodeStageSecretRefNested< + A> + editNodeStageSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodeStageSecretRefNested< + A> + editOrNewNodeStageSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodeStageSecretRefNested< + A> + editOrNewNodeStageSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - public A addToVolumeAttributes(java.lang.String key,java.lang.String value); - public A addToVolumeAttributes(java.util.Map map); + + public A addToVolumeAttributes(java.lang.String key, java.lang.String value); + + public A addToVolumeAttributes(java.util.Map map); + public A removeFromVolumeAttributes(java.lang.String key); - public A removeFromVolumeAttributes(java.util.Map map); - public java.util.Map getVolumeAttributes(); - public A withVolumeAttributes(java.util.Map volumeAttributes); + + public A removeFromVolumeAttributes(java.util.Map map); + + public java.util.Map getVolumeAttributes(); + + public A withVolumeAttributes( + java.util.Map volumeAttributes); + public java.lang.Boolean hasVolumeAttributes(); + public java.lang.String getVolumeHandle(); + public A withVolumeHandle(java.lang.String volumeHandle); + public java.lang.Boolean hasVolumeHandle(); - - /** - * Method is deprecated. use withVolumeHandle instead. - */ + + /** Method is deprecated. use withVolumeHandle instead. */ @java.lang.Deprecated public A withNewVolumeHandle(java.lang.String original); - public interface ControllerExpandSecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretReferenceFluent>{ + + public interface ControllerExpandSecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretReferenceFluent< + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerExpandSecretRefNested< + N>> { public N and(); + public N endControllerExpandSecretRef(); - } - public interface ControllerPublishSecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretReferenceFluent>{ + + public interface ControllerPublishSecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretReferenceFluent< + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerPublishSecretRefNested< + N>> { public N and(); + public N endControllerPublishSecretRef(); - } - public interface NodePublishSecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretReferenceFluent>{ + + public interface NodePublishSecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretReferenceFluent< + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodePublishSecretRefNested< + N>> { public N and(); + public N endNodePublishSecretRef(); - } - public interface NodeStageSecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretReferenceFluent>{ + + public interface NodeStageSecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretReferenceFluent< + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodeStageSecretRefNested< + N>> { public N and(); + public N endNodeStageSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIPersistentVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIPersistentVolumeSourceFluentImpl.java index 4a4c9b609c..605673af5b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIPersistentVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIPersistentVolumeSourceFluentImpl.java @@ -1,21 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public class V1CSIPersistentVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent{ - public V1CSIPersistentVolumeSourceFluentImpl() { - } - public V1CSIPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource instance) { +/** Generated */ +public class V1CSIPersistentVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent { + public V1CSIPersistentVolumeSourceFluentImpl() {} + + public V1CSIPersistentVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource instance) { this.withControllerExpandSecretRef(instance.getControllerExpandSecretRef()); this.withControllerPublishSecretRef(instance.getControllerPublishSecretRef()); @@ -33,8 +38,8 @@ public V1CSIPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models this.withVolumeAttributes(instance.getVolumeAttributes()); this.withVolumeHandle(instance.getVolumeHandle()); - } + private io.kubernetes.client.openapi.models.V1SecretReferenceBuilder controllerExpandSecretRef; private io.kubernetes.client.openapi.models.V1SecretReferenceBuilder controllerPublishSecretRef; private java.lang.String driver; @@ -42,310 +47,584 @@ public V1CSIPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models private io.kubernetes.client.openapi.models.V1SecretReferenceBuilder nodePublishSecretRef; private io.kubernetes.client.openapi.models.V1SecretReferenceBuilder nodeStageSecretRef; private java.lang.Boolean readOnly; - private java.util.Map volumeAttributes; + private java.util.Map volumeAttributes; private java.lang.String volumeHandle; - + /** * This method has been deprecated, please use method buildControllerExpandSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getControllerExpandSecretRef() { - return this.controllerExpandSecretRef!=null ?this.controllerExpandSecretRef.build():null; + return this.controllerExpandSecretRef != null ? this.controllerExpandSecretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretReference buildControllerExpandSecretRef() { - return this.controllerExpandSecretRef!=null ?this.controllerExpandSecretRef.build():null; + return this.controllerExpandSecretRef != null ? this.controllerExpandSecretRef.build() : null; } - public A withControllerExpandSecretRef(io.kubernetes.client.openapi.models.V1SecretReference controllerExpandSecretRef) { + + public A withControllerExpandSecretRef( + io.kubernetes.client.openapi.models.V1SecretReference controllerExpandSecretRef) { _visitables.get("controllerExpandSecretRef").remove(this.controllerExpandSecretRef); - if (controllerExpandSecretRef!=null){ this.controllerExpandSecretRef= new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(controllerExpandSecretRef); _visitables.get("controllerExpandSecretRef").add(this.controllerExpandSecretRef);} return (A) this; + if (controllerExpandSecretRef != null) { + this.controllerExpandSecretRef = + new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder( + controllerExpandSecretRef); + _visitables.get("controllerExpandSecretRef").add(this.controllerExpandSecretRef); + } + return (A) this; } + public java.lang.Boolean hasControllerExpandSecretRef() { return this.controllerExpandSecretRef != null; } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerExpandSecretRefNested withNewControllerExpandSecretRef() { - return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl.ControllerExpandSecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerExpandSecretRefNested< + A> + withNewControllerExpandSecretRef() { + return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl + .ControllerExpandSecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerExpandSecretRefNested withNewControllerExpandSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl.ControllerExpandSecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerExpandSecretRefNested< + A> + withNewControllerExpandSecretRefLike( + io.kubernetes.client.openapi.models.V1SecretReference item) { + return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl + .ControllerExpandSecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerExpandSecretRefNested editControllerExpandSecretRef() { + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerExpandSecretRefNested< + A> + editControllerExpandSecretRef() { return withNewControllerExpandSecretRefLike(getControllerExpandSecretRef()); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerExpandSecretRefNested editOrNewControllerExpandSecretRef() { - return withNewControllerExpandSecretRefLike(getControllerExpandSecretRef() != null ? getControllerExpandSecretRef(): new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerExpandSecretRefNested< + A> + editOrNewControllerExpandSecretRef() { + return withNewControllerExpandSecretRefLike( + getControllerExpandSecretRef() != null + ? getControllerExpandSecretRef() + : new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerExpandSecretRefNested editOrNewControllerExpandSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return withNewControllerExpandSecretRefLike(getControllerExpandSecretRef() != null ? getControllerExpandSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerExpandSecretRefNested< + A> + editOrNewControllerExpandSecretRefLike( + io.kubernetes.client.openapi.models.V1SecretReference item) { + return withNewControllerExpandSecretRefLike( + getControllerExpandSecretRef() != null ? getControllerExpandSecretRef() : item); } - + /** * This method has been deprecated, please use method buildControllerPublishSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getControllerPublishSecretRef() { - return this.controllerPublishSecretRef!=null ?this.controllerPublishSecretRef.build():null; + return this.controllerPublishSecretRef != null ? this.controllerPublishSecretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretReference buildControllerPublishSecretRef() { - return this.controllerPublishSecretRef!=null ?this.controllerPublishSecretRef.build():null; + return this.controllerPublishSecretRef != null ? this.controllerPublishSecretRef.build() : null; } - public A withControllerPublishSecretRef(io.kubernetes.client.openapi.models.V1SecretReference controllerPublishSecretRef) { + + public A withControllerPublishSecretRef( + io.kubernetes.client.openapi.models.V1SecretReference controllerPublishSecretRef) { _visitables.get("controllerPublishSecretRef").remove(this.controllerPublishSecretRef); - if (controllerPublishSecretRef!=null){ this.controllerPublishSecretRef= new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(controllerPublishSecretRef); _visitables.get("controllerPublishSecretRef").add(this.controllerPublishSecretRef);} return (A) this; + if (controllerPublishSecretRef != null) { + this.controllerPublishSecretRef = + new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder( + controllerPublishSecretRef); + _visitables.get("controllerPublishSecretRef").add(this.controllerPublishSecretRef); + } + return (A) this; } + public java.lang.Boolean hasControllerPublishSecretRef() { return this.controllerPublishSecretRef != null; } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerPublishSecretRefNested withNewControllerPublishSecretRef() { - return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl.ControllerPublishSecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerPublishSecretRefNested< + A> + withNewControllerPublishSecretRef() { + return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl + .ControllerPublishSecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerPublishSecretRefNested withNewControllerPublishSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl.ControllerPublishSecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerPublishSecretRefNested< + A> + withNewControllerPublishSecretRefLike( + io.kubernetes.client.openapi.models.V1SecretReference item) { + return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl + .ControllerPublishSecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerPublishSecretRefNested editControllerPublishSecretRef() { + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerPublishSecretRefNested< + A> + editControllerPublishSecretRef() { return withNewControllerPublishSecretRefLike(getControllerPublishSecretRef()); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerPublishSecretRefNested editOrNewControllerPublishSecretRef() { - return withNewControllerPublishSecretRefLike(getControllerPublishSecretRef() != null ? getControllerPublishSecretRef(): new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerPublishSecretRefNested< + A> + editOrNewControllerPublishSecretRef() { + return withNewControllerPublishSecretRefLike( + getControllerPublishSecretRef() != null + ? getControllerPublishSecretRef() + : new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerPublishSecretRefNested editOrNewControllerPublishSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return withNewControllerPublishSecretRefLike(getControllerPublishSecretRef() != null ? getControllerPublishSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerPublishSecretRefNested< + A> + editOrNewControllerPublishSecretRefLike( + io.kubernetes.client.openapi.models.V1SecretReference item) { + return withNewControllerPublishSecretRefLike( + getControllerPublishSecretRef() != null ? getControllerPublishSecretRef() : item); } + public java.lang.String getDriver() { return this.driver; } + public A withDriver(java.lang.String driver) { - this.driver=driver; return (A) this; + this.driver = driver; + return (A) this; } + public java.lang.Boolean hasDriver() { return this.driver != null; } - - /** - * Method is deprecated. use withDriver instead. - */ + + /** Method is deprecated. use withDriver instead. */ @java.lang.Deprecated public A withNewDriver(java.lang.String original) { - return (A)withDriver(new String(original)); + return (A) withDriver(new String(original)); } + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } - + /** * This method has been deprecated, please use method buildNodePublishSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getNodePublishSecretRef() { - return this.nodePublishSecretRef!=null ?this.nodePublishSecretRef.build():null; + return this.nodePublishSecretRef != null ? this.nodePublishSecretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretReference buildNodePublishSecretRef() { - return this.nodePublishSecretRef!=null ?this.nodePublishSecretRef.build():null; + return this.nodePublishSecretRef != null ? this.nodePublishSecretRef.build() : null; } - public A withNodePublishSecretRef(io.kubernetes.client.openapi.models.V1SecretReference nodePublishSecretRef) { + + public A withNodePublishSecretRef( + io.kubernetes.client.openapi.models.V1SecretReference nodePublishSecretRef) { _visitables.get("nodePublishSecretRef").remove(this.nodePublishSecretRef); - if (nodePublishSecretRef!=null){ this.nodePublishSecretRef= new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(nodePublishSecretRef); _visitables.get("nodePublishSecretRef").add(this.nodePublishSecretRef);} return (A) this; + if (nodePublishSecretRef != null) { + this.nodePublishSecretRef = + new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(nodePublishSecretRef); + _visitables.get("nodePublishSecretRef").add(this.nodePublishSecretRef); + } + return (A) this; } + public java.lang.Boolean hasNodePublishSecretRef() { return this.nodePublishSecretRef != null; } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodePublishSecretRefNested withNewNodePublishSecretRef() { - return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl.NodePublishSecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodePublishSecretRefNested< + A> + withNewNodePublishSecretRef() { + return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl + .NodePublishSecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodePublishSecretRefNested withNewNodePublishSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl.NodePublishSecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodePublishSecretRefNested< + A> + withNewNodePublishSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl + .NodePublishSecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodePublishSecretRefNested editNodePublishSecretRef() { + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodePublishSecretRefNested< + A> + editNodePublishSecretRef() { return withNewNodePublishSecretRefLike(getNodePublishSecretRef()); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodePublishSecretRefNested editOrNewNodePublishSecretRef() { - return withNewNodePublishSecretRefLike(getNodePublishSecretRef() != null ? getNodePublishSecretRef(): new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodePublishSecretRefNested< + A> + editOrNewNodePublishSecretRef() { + return withNewNodePublishSecretRefLike( + getNodePublishSecretRef() != null + ? getNodePublishSecretRef() + : new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodePublishSecretRefNested editOrNewNodePublishSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return withNewNodePublishSecretRefLike(getNodePublishSecretRef() != null ? getNodePublishSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodePublishSecretRefNested< + A> + editOrNewNodePublishSecretRefLike( + io.kubernetes.client.openapi.models.V1SecretReference item) { + return withNewNodePublishSecretRefLike( + getNodePublishSecretRef() != null ? getNodePublishSecretRef() : item); } - + /** * This method has been deprecated, please use method buildNodeStageSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getNodeStageSecretRef() { - return this.nodeStageSecretRef!=null ?this.nodeStageSecretRef.build():null; + return this.nodeStageSecretRef != null ? this.nodeStageSecretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretReference buildNodeStageSecretRef() { - return this.nodeStageSecretRef!=null ?this.nodeStageSecretRef.build():null; + return this.nodeStageSecretRef != null ? this.nodeStageSecretRef.build() : null; } - public A withNodeStageSecretRef(io.kubernetes.client.openapi.models.V1SecretReference nodeStageSecretRef) { + + public A withNodeStageSecretRef( + io.kubernetes.client.openapi.models.V1SecretReference nodeStageSecretRef) { _visitables.get("nodeStageSecretRef").remove(this.nodeStageSecretRef); - if (nodeStageSecretRef!=null){ this.nodeStageSecretRef= new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(nodeStageSecretRef); _visitables.get("nodeStageSecretRef").add(this.nodeStageSecretRef);} return (A) this; + if (nodeStageSecretRef != null) { + this.nodeStageSecretRef = + new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(nodeStageSecretRef); + _visitables.get("nodeStageSecretRef").add(this.nodeStageSecretRef); + } + return (A) this; } + public java.lang.Boolean hasNodeStageSecretRef() { return this.nodeStageSecretRef != null; } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodeStageSecretRefNested withNewNodeStageSecretRef() { - return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl.NodeStageSecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodeStageSecretRefNested< + A> + withNewNodeStageSecretRef() { + return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl + .NodeStageSecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodeStageSecretRefNested withNewNodeStageSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl.NodeStageSecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodeStageSecretRefNested< + A> + withNewNodeStageSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl + .NodeStageSecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodeStageSecretRefNested editNodeStageSecretRef() { + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodeStageSecretRefNested< + A> + editNodeStageSecretRef() { return withNewNodeStageSecretRefLike(getNodeStageSecretRef()); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodeStageSecretRefNested editOrNewNodeStageSecretRef() { - return withNewNodeStageSecretRefLike(getNodeStageSecretRef() != null ? getNodeStageSecretRef(): new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodeStageSecretRefNested< + A> + editOrNewNodeStageSecretRef() { + return withNewNodeStageSecretRefLike( + getNodeStageSecretRef() != null + ? getNodeStageSecretRef() + : new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodeStageSecretRefNested editOrNewNodeStageSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return withNewNodeStageSecretRefLike(getNodeStageSecretRef() != null ? getNodeStageSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodeStageSecretRefNested< + A> + editOrNewNodeStageSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return withNewNodeStageSecretRefLike( + getNodeStageSecretRef() != null ? getNodeStageSecretRef() : item); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - public A addToVolumeAttributes(java.lang.String key,java.lang.String value) { - if(this.volumeAttributes == null && key != null && value != null) { this.volumeAttributes = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.volumeAttributes.put(key, value);} return (A)this; + + public A addToVolumeAttributes(java.lang.String key, java.lang.String value) { + if (this.volumeAttributes == null && key != null && value != null) { + this.volumeAttributes = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.volumeAttributes.put(key, value); + } + return (A) this; } - public A addToVolumeAttributes(java.util.Map map) { - if(this.volumeAttributes == null && map != null) { this.volumeAttributes = new java.util.LinkedHashMap(); } - if(map != null) { this.volumeAttributes.putAll(map);} return (A)this; + + public A addToVolumeAttributes(java.util.Map map) { + if (this.volumeAttributes == null && map != null) { + this.volumeAttributes = new java.util.LinkedHashMap(); + } + if (map != null) { + this.volumeAttributes.putAll(map); + } + return (A) this; } + public A removeFromVolumeAttributes(java.lang.String key) { - if(this.volumeAttributes == null) { return (A) this; } - if(key != null && this.volumeAttributes != null) {this.volumeAttributes.remove(key);} return (A)this; + if (this.volumeAttributes == null) { + return (A) this; + } + if (key != null && this.volumeAttributes != null) { + this.volumeAttributes.remove(key); + } + return (A) this; } - public A removeFromVolumeAttributes(java.util.Map map) { - if(this.volumeAttributes == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.volumeAttributes != null){this.volumeAttributes.remove(key);}}} return (A)this; + + public A removeFromVolumeAttributes(java.util.Map map) { + if (this.volumeAttributes == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.volumeAttributes != null) { + this.volumeAttributes.remove(key); + } + } + } + return (A) this; } - public java.util.Map getVolumeAttributes() { + + public java.util.Map getVolumeAttributes() { return this.volumeAttributes; } - public A withVolumeAttributes(java.util.Map volumeAttributes) { - if (volumeAttributes == null) { this.volumeAttributes = null;} else {this.volumeAttributes = new java.util.LinkedHashMap(volumeAttributes);} return (A) this; + + public A withVolumeAttributes( + java.util.Map volumeAttributes) { + if (volumeAttributes == null) { + this.volumeAttributes = null; + } else { + this.volumeAttributes = new java.util.LinkedHashMap(volumeAttributes); + } + return (A) this; } + public java.lang.Boolean hasVolumeAttributes() { return this.volumeAttributes != null; } + public java.lang.String getVolumeHandle() { return this.volumeHandle; } + public A withVolumeHandle(java.lang.String volumeHandle) { - this.volumeHandle=volumeHandle; return (A) this; + this.volumeHandle = volumeHandle; + return (A) this; } + public java.lang.Boolean hasVolumeHandle() { return this.volumeHandle != null; } - - /** - * Method is deprecated. use withVolumeHandle instead. - */ + + /** Method is deprecated. use withVolumeHandle instead. */ @java.lang.Deprecated public A withNewVolumeHandle(java.lang.String original) { - return (A)withVolumeHandle(new String(original)); + return (A) withVolumeHandle(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CSIPersistentVolumeSourceFluentImpl that = (V1CSIPersistentVolumeSourceFluentImpl) o; - if (controllerExpandSecretRef != null ? !controllerExpandSecretRef.equals(that.controllerExpandSecretRef) :that.controllerExpandSecretRef != null) return false; - if (controllerPublishSecretRef != null ? !controllerPublishSecretRef.equals(that.controllerPublishSecretRef) :that.controllerPublishSecretRef != null) return false; - if (driver != null ? !driver.equals(that.driver) :that.driver != null) return false; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (nodePublishSecretRef != null ? !nodePublishSecretRef.equals(that.nodePublishSecretRef) :that.nodePublishSecretRef != null) return false; - if (nodeStageSecretRef != null ? !nodeStageSecretRef.equals(that.nodeStageSecretRef) :that.nodeStageSecretRef != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (volumeAttributes != null ? !volumeAttributes.equals(that.volumeAttributes) :that.volumeAttributes != null) return false; - if (volumeHandle != null ? !volumeHandle.equals(that.volumeHandle) :that.volumeHandle != null) return false; + if (controllerExpandSecretRef != null + ? !controllerExpandSecretRef.equals(that.controllerExpandSecretRef) + : that.controllerExpandSecretRef != null) return false; + if (controllerPublishSecretRef != null + ? !controllerPublishSecretRef.equals(that.controllerPublishSecretRef) + : that.controllerPublishSecretRef != null) return false; + if (driver != null ? !driver.equals(that.driver) : that.driver != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (nodePublishSecretRef != null + ? !nodePublishSecretRef.equals(that.nodePublishSecretRef) + : that.nodePublishSecretRef != null) return false; + if (nodeStageSecretRef != null + ? !nodeStageSecretRef.equals(that.nodeStageSecretRef) + : that.nodeStageSecretRef != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (volumeAttributes != null + ? !volumeAttributes.equals(that.volumeAttributes) + : that.volumeAttributes != null) return false; + if (volumeHandle != null ? !volumeHandle.equals(that.volumeHandle) : that.volumeHandle != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(controllerExpandSecretRef, controllerPublishSecretRef, driver, fsType, nodePublishSecretRef, nodeStageSecretRef, readOnly, volumeAttributes, volumeHandle, super.hashCode()); + return java.util.Objects.hash( + controllerExpandSecretRef, + controllerPublishSecretRef, + driver, + fsType, + nodePublishSecretRef, + nodeStageSecretRef, + readOnly, + volumeAttributes, + volumeHandle, + super.hashCode()); } - public class ControllerExpandSecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerExpandSecretRefNested,io.kubernetes.client.fluent.Nested{ - ControllerExpandSecretRefNestedImpl(io.kubernetes.client.openapi.models.V1SecretReference item) { + + public class ControllerExpandSecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerExpandSecretRefNested< + N>> + implements io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerExpandSecretRefNested< + N>, + io.kubernetes.client.fluent.Nested { + ControllerExpandSecretRefNestedImpl( + io.kubernetes.client.openapi.models.V1SecretReference item) { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this, item); } + ControllerExpandSecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretReferenceBuilder builder; + public N and() { - return (N) V1CSIPersistentVolumeSourceFluentImpl.this.withControllerExpandSecretRef(builder.build()); + return (N) + V1CSIPersistentVolumeSourceFluentImpl.this.withControllerExpandSecretRef(builder.build()); } + public N endControllerExpandSecretRef() { return and(); } - } - public class ControllerPublishSecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.ControllerPublishSecretRefNested,io.kubernetes.client.fluent.Nested{ - ControllerPublishSecretRefNestedImpl(io.kubernetes.client.openapi.models.V1SecretReference item) { + + public class ControllerPublishSecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerPublishSecretRefNested< + N>> + implements io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .ControllerPublishSecretRefNested< + N>, + io.kubernetes.client.fluent.Nested { + ControllerPublishSecretRefNestedImpl( + io.kubernetes.client.openapi.models.V1SecretReference item) { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this, item); } + ControllerPublishSecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretReferenceBuilder builder; + public N and() { - return (N) V1CSIPersistentVolumeSourceFluentImpl.this.withControllerPublishSecretRef(builder.build()); + return (N) + V1CSIPersistentVolumeSourceFluentImpl.this.withControllerPublishSecretRef( + builder.build()); } + public N endControllerPublishSecretRef() { return and(); } - } - public class NodePublishSecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodePublishSecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class NodePublishSecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodePublishSecretRefNested< + N>> + implements io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodePublishSecretRefNested< + N>, + io.kubernetes.client.fluent.Nested { NodePublishSecretRefNestedImpl(io.kubernetes.client.openapi.models.V1SecretReference item) { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this, item); } + NodePublishSecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretReferenceBuilder builder; + public N and() { - return (N) V1CSIPersistentVolumeSourceFluentImpl.this.withNodePublishSecretRef(builder.build()); + return (N) + V1CSIPersistentVolumeSourceFluentImpl.this.withNodePublishSecretRef(builder.build()); } + public N endNodePublishSecretRef() { return and(); } - } - public class NodeStageSecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent.NodeStageSecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class NodeStageSecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodeStageSecretRefNested< + N>> + implements io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent + .NodeStageSecretRefNested< + N>, + io.kubernetes.client.fluent.Nested { NodeStageSecretRefNestedImpl(io.kubernetes.client.openapi.models.V1SecretReference item) { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this, item); } + NodeStageSecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretReferenceBuilder builder; + public N and() { return (N) V1CSIPersistentVolumeSourceFluentImpl.this.withNodeStageSecretRef(builder.build()); } + public N endNodeStageSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIVolumeSourceBuilder.java index c09e02eea5..85a4076047 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CSIVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CSIVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1CSIVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CSIVolumeSource, + io.kubernetes.client.openapi.models.V1CSIVolumeSourceBuilder> { public V1CSIVolumeSourceBuilder() { this(false); } + public V1CSIVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1CSIVolumeSource(), validationEnabled); } - public V1CSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent fluent) { + + public V1CSIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent fluent) { this(fluent, false); } - public V1CSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CSIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CSIVolumeSource(), validationEnabled); } - public V1CSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1CSIVolumeSource instance) { + + public V1CSIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1CSIVolumeSource instance) { this(fluent, instance, false); } - public V1CSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1CSIVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CSIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1CSIVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDriver(instance.getDriver()); fluent.withFsType(instance.getFsType()); @@ -31,13 +58,17 @@ public V1CSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIVolumeS fluent.withVolumeAttributes(instance.getVolumeAttributes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1CSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIVolumeSource instance) { - this(instance,false); + this(instance, false); } - public V1CSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CSIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CSIVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDriver(instance.getDriver()); this.withFsType(instance.getFsType()); @@ -48,10 +79,12 @@ public V1CSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CSIVolumeS this.withVolumeAttributes(instance.getVolumeAttributes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CSIVolumeSource build() { V1CSIVolumeSource buildable = new V1CSIVolumeSource(); buildable.setDriver(fluent.getDriver()); @@ -61,18 +94,23 @@ public io.kubernetes.client.openapi.models.V1CSIVolumeSource build() { buildable.setVolumeAttributes(fluent.getVolumeAttributes()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CSIVolumeSourceBuilder that = (V1CSIVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIVolumeSourceFluent.java index 929e681991..79ccc44d9d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIVolumeSourceFluent.java @@ -1,65 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1CSIVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CSIVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getDriver(); + public A withDriver(java.lang.String driver); + public java.lang.Boolean hasDriver(); - - /** - * Method is deprecated. use withDriver instead. - */ + + /** Method is deprecated. use withDriver instead. */ @java.lang.Deprecated public A withNewDriver(java.lang.String original); + public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); - + /** * This method has been deprecated, please use method buildNodePublishSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getNodePublishSecretRef(); + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildNodePublishSecretRef(); - public A withNodePublishSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference nodePublishSecretRef); + + public A withNodePublishSecretRef( + io.kubernetes.client.openapi.models.V1LocalObjectReference nodePublishSecretRef); + public java.lang.Boolean hasNodePublishSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested withNewNodePublishSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested withNewNodePublishSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested editNodePublishSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested editOrNewNodePublishSecretRef(); - public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested editOrNewNodePublishSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested + withNewNodePublishSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested + withNewNodePublishSecretRefLike( + io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested + editNodePublishSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested + editOrNewNodePublishSecretRef(); + + public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested + editOrNewNodePublishSecretRefLike( + io.kubernetes.client.openapi.models.V1LocalObjectReference item); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - public A addToVolumeAttributes(java.lang.String key,java.lang.String value); - public A addToVolumeAttributes(java.util.Map map); + + public A addToVolumeAttributes(java.lang.String key, java.lang.String value); + + public A addToVolumeAttributes(java.util.Map map); + public A removeFromVolumeAttributes(java.lang.String key); - public A removeFromVolumeAttributes(java.util.Map map); - public java.util.Map getVolumeAttributes(); - public A withVolumeAttributes(java.util.Map volumeAttributes); + + public A removeFromVolumeAttributes(java.util.Map map); + + public java.util.Map getVolumeAttributes(); + + public A withVolumeAttributes( + java.util.Map volumeAttributes); + public java.lang.Boolean hasVolumeAttributes(); - public interface NodePublishSecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent>{ + + public interface NodePublishSecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent + .NodePublishSecretRefNested< + N>> { public N and(); + public N endNodePublishSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIVolumeSourceFluentImpl.java index ae19a6ac5e..c32d14f578 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CSIVolumeSourceFluentImpl.java @@ -1,21 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public class V1CSIVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent{ - public V1CSIVolumeSourceFluentImpl() { - } - public V1CSIVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1CSIVolumeSource instance) { +/** Generated */ +public class V1CSIVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent { + public V1CSIVolumeSourceFluentImpl() {} + + public V1CSIVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1CSIVolumeSource instance) { this.withDriver(instance.getDriver()); this.withFsType(instance.getFsType()); @@ -25,144 +30,236 @@ public V1CSIVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1CSIVolu this.withReadOnly(instance.getReadOnly()); this.withVolumeAttributes(instance.getVolumeAttributes()); - } + private java.lang.String driver; private java.lang.String fsType; private io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder nodePublishSecretRef; private java.lang.Boolean readOnly; - private java.util.Map volumeAttributes; + private java.util.Map volumeAttributes; + public java.lang.String getDriver() { return this.driver; } + public A withDriver(java.lang.String driver) { - this.driver=driver; return (A) this; + this.driver = driver; + return (A) this; } + public java.lang.Boolean hasDriver() { return this.driver != null; } - - /** - * Method is deprecated. use withDriver instead. - */ + + /** Method is deprecated. use withDriver instead. */ @java.lang.Deprecated public A withNewDriver(java.lang.String original) { - return (A)withDriver(new String(original)); + return (A) withDriver(new String(original)); } + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } - + /** * This method has been deprecated, please use method buildNodePublishSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getNodePublishSecretRef() { - return this.nodePublishSecretRef!=null ?this.nodePublishSecretRef.build():null; + return this.nodePublishSecretRef != null ? this.nodePublishSecretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildNodePublishSecretRef() { - return this.nodePublishSecretRef!=null ?this.nodePublishSecretRef.build():null; + return this.nodePublishSecretRef != null ? this.nodePublishSecretRef.build() : null; } - public A withNodePublishSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference nodePublishSecretRef) { + + public A withNodePublishSecretRef( + io.kubernetes.client.openapi.models.V1LocalObjectReference nodePublishSecretRef) { _visitables.get("nodePublishSecretRef").remove(this.nodePublishSecretRef); - if (nodePublishSecretRef!=null){ this.nodePublishSecretRef= new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(nodePublishSecretRef); _visitables.get("nodePublishSecretRef").add(this.nodePublishSecretRef);} return (A) this; + if (nodePublishSecretRef != null) { + this.nodePublishSecretRef = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder( + nodePublishSecretRef); + _visitables.get("nodePublishSecretRef").add(this.nodePublishSecretRef); + } + return (A) this; } + public java.lang.Boolean hasNodePublishSecretRef() { return this.nodePublishSecretRef != null; } - public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested withNewNodePublishSecretRef() { - return new io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluentImpl.NodePublishSecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested + withNewNodePublishSecretRef() { + return new io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluentImpl + .NodePublishSecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested withNewNodePublishSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluentImpl.NodePublishSecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested + withNewNodePublishSecretRefLike( + io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluentImpl + .NodePublishSecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested editNodePublishSecretRef() { + + public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested + editNodePublishSecretRef() { return withNewNodePublishSecretRefLike(getNodePublishSecretRef()); } - public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested editOrNewNodePublishSecretRef() { - return withNewNodePublishSecretRefLike(getNodePublishSecretRef() != null ? getNodePublishSecretRef(): new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested + editOrNewNodePublishSecretRef() { + return withNewNodePublishSecretRefLike( + getNodePublishSecretRef() != null + ? getNodePublishSecretRef() + : new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested editOrNewNodePublishSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return withNewNodePublishSecretRefLike(getNodePublishSecretRef() != null ? getNodePublishSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested + editOrNewNodePublishSecretRefLike( + io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return withNewNodePublishSecretRefLike( + getNodePublishSecretRef() != null ? getNodePublishSecretRef() : item); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - public A addToVolumeAttributes(java.lang.String key,java.lang.String value) { - if(this.volumeAttributes == null && key != null && value != null) { this.volumeAttributes = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.volumeAttributes.put(key, value);} return (A)this; + + public A addToVolumeAttributes(java.lang.String key, java.lang.String value) { + if (this.volumeAttributes == null && key != null && value != null) { + this.volumeAttributes = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.volumeAttributes.put(key, value); + } + return (A) this; } - public A addToVolumeAttributes(java.util.Map map) { - if(this.volumeAttributes == null && map != null) { this.volumeAttributes = new java.util.LinkedHashMap(); } - if(map != null) { this.volumeAttributes.putAll(map);} return (A)this; + + public A addToVolumeAttributes(java.util.Map map) { + if (this.volumeAttributes == null && map != null) { + this.volumeAttributes = new java.util.LinkedHashMap(); + } + if (map != null) { + this.volumeAttributes.putAll(map); + } + return (A) this; } + public A removeFromVolumeAttributes(java.lang.String key) { - if(this.volumeAttributes == null) { return (A) this; } - if(key != null && this.volumeAttributes != null) {this.volumeAttributes.remove(key);} return (A)this; + if (this.volumeAttributes == null) { + return (A) this; + } + if (key != null && this.volumeAttributes != null) { + this.volumeAttributes.remove(key); + } + return (A) this; } - public A removeFromVolumeAttributes(java.util.Map map) { - if(this.volumeAttributes == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.volumeAttributes != null){this.volumeAttributes.remove(key);}}} return (A)this; + + public A removeFromVolumeAttributes(java.util.Map map) { + if (this.volumeAttributes == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.volumeAttributes != null) { + this.volumeAttributes.remove(key); + } + } + } + return (A) this; } - public java.util.Map getVolumeAttributes() { + + public java.util.Map getVolumeAttributes() { return this.volumeAttributes; } - public A withVolumeAttributes(java.util.Map volumeAttributes) { - if (volumeAttributes == null) { this.volumeAttributes = null;} else {this.volumeAttributes = new java.util.LinkedHashMap(volumeAttributes);} return (A) this; + + public A withVolumeAttributes( + java.util.Map volumeAttributes) { + if (volumeAttributes == null) { + this.volumeAttributes = null; + } else { + this.volumeAttributes = new java.util.LinkedHashMap(volumeAttributes); + } + return (A) this; } + public java.lang.Boolean hasVolumeAttributes() { return this.volumeAttributes != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CSIVolumeSourceFluentImpl that = (V1CSIVolumeSourceFluentImpl) o; - if (driver != null ? !driver.equals(that.driver) :that.driver != null) return false; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (nodePublishSecretRef != null ? !nodePublishSecretRef.equals(that.nodePublishSecretRef) :that.nodePublishSecretRef != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (volumeAttributes != null ? !volumeAttributes.equals(that.volumeAttributes) :that.volumeAttributes != null) return false; + if (driver != null ? !driver.equals(that.driver) : that.driver != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (nodePublishSecretRef != null + ? !nodePublishSecretRef.equals(that.nodePublishSecretRef) + : that.nodePublishSecretRef != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (volumeAttributes != null + ? !volumeAttributes.equals(that.volumeAttributes) + : that.volumeAttributes != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(driver, fsType, nodePublishSecretRef, readOnly, volumeAttributes, super.hashCode()); + return java.util.Objects.hash( + driver, fsType, nodePublishSecretRef, readOnly, volumeAttributes, super.hashCode()); } - public class NodePublishSecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested,io.kubernetes.client.fluent.Nested{ - NodePublishSecretRefNestedImpl(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); + + public class NodePublishSecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent.NodePublishSecretRefNested> + implements io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent + .NodePublishSecretRefNested< + N>, + io.kubernetes.client.fluent.Nested { + NodePublishSecretRefNestedImpl( + io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + this.builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); } + NodePublishSecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder; + public N and() { return (N) V1CSIVolumeSourceFluentImpl.this.withNodePublishSecretRef(builder.build()); } + public N endNodePublishSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CapabilitiesBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CapabilitiesBuilder.java index fe00fe3bc8..8f4d5a8238 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CapabilitiesBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CapabilitiesBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CapabilitiesBuilder extends io.kubernetes.client.openapi.models.V1CapabilitiesFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CapabilitiesBuilder + extends io.kubernetes.client.openapi.models.V1CapabilitiesFluentImpl< + io.kubernetes.client.openapi.models.V1CapabilitiesBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Capabilities, + io.kubernetes.client.openapi.models.V1CapabilitiesBuilder> { public V1CapabilitiesBuilder() { this(false); } + public V1CapabilitiesBuilder(java.lang.Boolean validationEnabled) { this(new V1Capabilities(), validationEnabled); } + public V1CapabilitiesBuilder(io.kubernetes.client.openapi.models.V1CapabilitiesFluent fluent) { this(fluent, false); } - public V1CapabilitiesBuilder(io.kubernetes.client.openapi.models.V1CapabilitiesFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CapabilitiesBuilder( + io.kubernetes.client.openapi.models.V1CapabilitiesFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Capabilities(), validationEnabled); } - public V1CapabilitiesBuilder(io.kubernetes.client.openapi.models.V1CapabilitiesFluent fluent,io.kubernetes.client.openapi.models.V1Capabilities instance) { + + public V1CapabilitiesBuilder( + io.kubernetes.client.openapi.models.V1CapabilitiesFluent fluent, + io.kubernetes.client.openapi.models.V1Capabilities instance) { this(fluent, instance, false); } - public V1CapabilitiesBuilder(io.kubernetes.client.openapi.models.V1CapabilitiesFluent fluent,io.kubernetes.client.openapi.models.V1Capabilities instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CapabilitiesBuilder( + io.kubernetes.client.openapi.models.V1CapabilitiesFluent fluent, + io.kubernetes.client.openapi.models.V1Capabilities instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAdd(instance.getAdd()); fluent.withDrop(instance.getDrop()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1CapabilitiesBuilder(io.kubernetes.client.openapi.models.V1Capabilities instance) { - this(instance,false); + this(instance, false); } - public V1CapabilitiesBuilder(io.kubernetes.client.openapi.models.V1Capabilities instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CapabilitiesBuilder( + io.kubernetes.client.openapi.models.V1Capabilities instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAdd(instance.getAdd()); this.withDrop(instance.getDrop()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CapabilitiesFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Capabilities build() { V1Capabilities buildable = new V1Capabilities(); buildable.setAdd(fluent.getAdd()); buildable.setDrop(fluent.getDrop()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CapabilitiesBuilder that = (V1CapabilitiesBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CapabilitiesFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CapabilitiesFluent.java index 8f4cb2896a..db68652f23 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CapabilitiesFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CapabilitiesFluent.java @@ -1,50 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1CapabilitiesFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAdd(java.lang.Integer index,java.lang.String item); - public A setToAdd(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1CapabilitiesFluent< + A extends io.kubernetes.client.openapi.models.V1CapabilitiesFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAdd(java.lang.Integer index, java.lang.String item); + + public A setToAdd(java.lang.Integer index, java.lang.String item); + public A addToAdd(java.lang.String... items); + public A addAllToAdd(java.util.Collection items); + public A removeFromAdd(java.lang.String... items); + public A removeAllFromAdd(java.util.Collection items); + public java.util.List getAdd(); + public java.lang.String getAdd(java.lang.Integer index); + public java.lang.String getFirstAdd(); + public java.lang.String getLastAdd(); + public java.lang.String getMatchingAdd(java.util.function.Predicate predicate); + public java.lang.Boolean hasMatchingAdd(java.util.function.Predicate predicate); + public A withAdd(java.util.List add); + public A withAdd(java.lang.String... add); + public java.lang.Boolean hasAdd(); + public A addNewAdd(java.lang.String original); - public A addToDrop(java.lang.Integer index,java.lang.String item); - public A setToDrop(java.lang.Integer index,java.lang.String item); + + public A addToDrop(java.lang.Integer index, java.lang.String item); + + public A setToDrop(java.lang.Integer index, java.lang.String item); + public A addToDrop(java.lang.String... items); + public A addAllToDrop(java.util.Collection items); + public A removeFromDrop(java.lang.String... items); + public A removeAllFromDrop(java.util.Collection items); + public java.util.List getDrop(); + public java.lang.String getDrop(java.lang.Integer index); + public java.lang.String getFirstDrop(); + public java.lang.String getLastDrop(); + public java.lang.String getMatchingDrop(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingDrop(java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingDrop( + java.util.function.Predicate predicate); + public A withDrop(java.util.List drop); + public A withDrop(java.lang.String... drop); + public java.lang.Boolean hasDrop(); + public A addNewDrop(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CapabilitiesFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CapabilitiesFluentImpl.java index b722526f9f..a6ebf821e7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CapabilitiesFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CapabilitiesFluentImpl.java @@ -1,147 +1,286 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.ArrayList; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public class V1CapabilitiesFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CapabilitiesFluent{ - public V1CapabilitiesFluentImpl() { - } +/** Generated */ +public class V1CapabilitiesFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CapabilitiesFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CapabilitiesFluent { + public V1CapabilitiesFluentImpl() {} + public V1CapabilitiesFluentImpl(io.kubernetes.client.openapi.models.V1Capabilities instance) { this.withAdd(instance.getAdd()); this.withDrop(instance.getDrop()); - } + private java.util.List add; private java.util.List drop; - public A addToAdd(java.lang.Integer index,java.lang.String item) { - if (this.add == null) {this.add = new java.util.ArrayList();} + + public A addToAdd(java.lang.Integer index, java.lang.String item) { + if (this.add == null) { + this.add = new java.util.ArrayList(); + } this.add.add(index, item); - return (A)this; + return (A) this; } - public A setToAdd(java.lang.Integer index,java.lang.String item) { - if (this.add == null) {this.add = new java.util.ArrayList();} - this.add.set(index, item); return (A)this; + + public A setToAdd(java.lang.Integer index, java.lang.String item) { + if (this.add == null) { + this.add = new java.util.ArrayList(); + } + this.add.set(index, item); + return (A) this; } + public A addToAdd(java.lang.String... items) { - if (this.add == null) {this.add = new java.util.ArrayList();} - for (java.lang.String item : items) {this.add.add(item);} return (A)this; + if (this.add == null) { + this.add = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.add.add(item); + } + return (A) this; } + public A addAllToAdd(java.util.Collection items) { - if (this.add == null) {this.add = new java.util.ArrayList();} - for (java.lang.String item : items) {this.add.add(item);} return (A)this; + if (this.add == null) { + this.add = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.add.add(item); + } + return (A) this; } + public A removeFromAdd(java.lang.String... items) { - for (java.lang.String item : items) {if (this.add!= null){ this.add.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.add != null) { + this.add.remove(item); + } + } + return (A) this; } + public A removeAllFromAdd(java.util.Collection items) { - for (java.lang.String item : items) {if (this.add!= null){ this.add.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.add != null) { + this.add.remove(item); + } + } + return (A) this; } + public java.util.List getAdd() { return this.add; } + public java.lang.String getAdd(java.lang.Integer index) { return this.add.get(index); } + public java.lang.String getFirstAdd() { return this.add.get(0); } + public java.lang.String getLastAdd() { return this.add.get(add.size() - 1); } + public java.lang.String getMatchingAdd(java.util.function.Predicate predicate) { - for (java.lang.String item: add) { if(predicate.test(item)){ return item;} } return null; + for (java.lang.String item : add) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAdd(java.util.function.Predicate predicate) { - for (java.lang.String item: add) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAdd( + java.util.function.Predicate predicate) { + for (java.lang.String item : add) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAdd(java.util.List add) { - if (add != null) {this.add = new java.util.ArrayList(); for (java.lang.String item : add){this.addToAdd(item);}} else { this.add = null;} return (A) this; + if (add != null) { + this.add = new java.util.ArrayList(); + for (java.lang.String item : add) { + this.addToAdd(item); + } + } else { + this.add = null; + } + return (A) this; } + public A withAdd(java.lang.String... add) { - if (this.add != null) {this.add.clear();} - if (add != null) {for (java.lang.String item :add){ this.addToAdd(item);}} return (A) this; + if (this.add != null) { + this.add.clear(); + } + if (add != null) { + for (java.lang.String item : add) { + this.addToAdd(item); + } + } + return (A) this; } + public java.lang.Boolean hasAdd() { return add != null && !add.isEmpty(); } + public A addNewAdd(java.lang.String original) { - return (A)addToAdd(new String(original)); + return (A) addToAdd(new String(original)); } - public A addToDrop(java.lang.Integer index,java.lang.String item) { - if (this.drop == null) {this.drop = new java.util.ArrayList();} + + public A addToDrop(java.lang.Integer index, java.lang.String item) { + if (this.drop == null) { + this.drop = new java.util.ArrayList(); + } this.drop.add(index, item); - return (A)this; + return (A) this; } - public A setToDrop(java.lang.Integer index,java.lang.String item) { - if (this.drop == null) {this.drop = new java.util.ArrayList();} - this.drop.set(index, item); return (A)this; + + public A setToDrop(java.lang.Integer index, java.lang.String item) { + if (this.drop == null) { + this.drop = new java.util.ArrayList(); + } + this.drop.set(index, item); + return (A) this; } + public A addToDrop(java.lang.String... items) { - if (this.drop == null) {this.drop = new java.util.ArrayList();} - for (java.lang.String item : items) {this.drop.add(item);} return (A)this; + if (this.drop == null) { + this.drop = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.drop.add(item); + } + return (A) this; } + public A addAllToDrop(java.util.Collection items) { - if (this.drop == null) {this.drop = new java.util.ArrayList();} - for (java.lang.String item : items) {this.drop.add(item);} return (A)this; + if (this.drop == null) { + this.drop = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.drop.add(item); + } + return (A) this; } + public A removeFromDrop(java.lang.String... items) { - for (java.lang.String item : items) {if (this.drop!= null){ this.drop.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.drop != null) { + this.drop.remove(item); + } + } + return (A) this; } + public A removeAllFromDrop(java.util.Collection items) { - for (java.lang.String item : items) {if (this.drop!= null){ this.drop.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.drop != null) { + this.drop.remove(item); + } + } + return (A) this; } + public java.util.List getDrop() { return this.drop; } + public java.lang.String getDrop(java.lang.Integer index) { return this.drop.get(index); } + public java.lang.String getFirstDrop() { return this.drop.get(0); } + public java.lang.String getLastDrop() { return this.drop.get(drop.size() - 1); } - public java.lang.String getMatchingDrop(java.util.function.Predicate predicate) { - for (java.lang.String item: drop) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingDrop( + java.util.function.Predicate predicate) { + for (java.lang.String item : drop) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingDrop(java.util.function.Predicate predicate) { - for (java.lang.String item: drop) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingDrop( + java.util.function.Predicate predicate) { + for (java.lang.String item : drop) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withDrop(java.util.List drop) { - if (drop != null) {this.drop = new java.util.ArrayList(); for (java.lang.String item : drop){this.addToDrop(item);}} else { this.drop = null;} return (A) this; + if (drop != null) { + this.drop = new java.util.ArrayList(); + for (java.lang.String item : drop) { + this.addToDrop(item); + } + } else { + this.drop = null; + } + return (A) this; } + public A withDrop(java.lang.String... drop) { - if (this.drop != null) {this.drop.clear();} - if (drop != null) {for (java.lang.String item :drop){ this.addToDrop(item);}} return (A) this; + if (this.drop != null) { + this.drop.clear(); + } + if (drop != null) { + for (java.lang.String item : drop) { + this.addToDrop(item); + } + } + return (A) this; } + public java.lang.Boolean hasDrop() { return drop != null && !drop.isEmpty(); } + public A addNewDrop(java.lang.String original) { - return (A)addToDrop(new String(original)); + return (A) addToDrop(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CapabilitiesFluentImpl that = (V1CapabilitiesFluentImpl) o; - if (add != null ? !add.equals(that.add) :that.add != null) return false; - if (drop != null ? !drop.equals(that.drop) :that.drop != null) return false; + if (add != null ? !add.equals(that.add) : that.add != null) return false; + if (drop != null ? !drop.equals(that.drop) : that.drop != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(add, drop, super.hashCode()); + return java.util.Objects.hash(add, drop, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSPersistentVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSPersistentVolumeSourceBuilder.java index 176605651f..9cd1f04710 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSPersistentVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSPersistentVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CephFSPersistentVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CephFSPersistentVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource, + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceBuilder> { public V1CephFSPersistentVolumeSourceBuilder() { this(false); } + public V1CephFSPersistentVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1CephFSPersistentVolumeSource(), validationEnabled); } - public V1CephFSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent fluent) { + + public V1CephFSPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent fluent) { this(fluent, false); } - public V1CephFSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CephFSPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CephFSPersistentVolumeSource(), validationEnabled); } - public V1CephFSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource instance) { + + public V1CephFSPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource instance) { this(fluent, instance, false); } - public V1CephFSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CephFSPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMonitors(instance.getMonitors()); fluent.withPath(instance.getPath()); @@ -33,13 +60,18 @@ public V1CephFSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models fluent.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CephFSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource instance) { - this(instance,false); + + public V1CephFSPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource instance) { + this(instance, false); } - public V1CephFSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CephFSPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMonitors(instance.getMonitors()); this.withPath(instance.getPath()); @@ -52,10 +84,12 @@ public V1CephFSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models this.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource build() { V1CephFSPersistentVolumeSource buildable = new V1CephFSPersistentVolumeSource(); buildable.setMonitors(fluent.getMonitors()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource build( buildable.setUser(fluent.getUser()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CephFSPersistentVolumeSourceBuilder that = (V1CephFSPersistentVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSPersistentVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSPersistentVolumeSourceFluent.java index abdd6d92f2..6320c19eab 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSPersistentVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSPersistentVolumeSourceFluent.java @@ -1,86 +1,128 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CephFSPersistentVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToMonitors(java.lang.Integer index,java.lang.String item); - public A setToMonitors(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1CephFSPersistentVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToMonitors(java.lang.Integer index, java.lang.String item); + + public A setToMonitors(java.lang.Integer index, java.lang.String item); + public A addToMonitors(java.lang.String... items); + public A addAllToMonitors(java.util.Collection items); + public A removeFromMonitors(java.lang.String... items); + public A removeAllFromMonitors(java.util.Collection items); + public java.util.List getMonitors(); + public java.lang.String getMonitor(java.lang.Integer index); + public java.lang.String getFirstMonitor(); + public java.lang.String getLastMonitor(); - public java.lang.String getMatchingMonitor(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMonitor(java.util.function.Predicate predicate); + + public java.lang.String getMatchingMonitor( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingMonitor( + java.util.function.Predicate predicate); + public A withMonitors(java.util.List monitors); + public A withMonitors(java.lang.String... monitors); + public java.lang.Boolean hasMonitors(); + public A addNewMonitor(java.lang.String original); + public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); + public java.lang.String getSecretFile(); + public A withSecretFile(java.lang.String secretFile); + public java.lang.Boolean hasSecretFile(); - - /** - * Method is deprecated. use withSecretFile instead. - */ + + /** Method is deprecated. use withSecretFile instead. */ @java.lang.Deprecated public A withNewSecretFile(java.lang.String original); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1SecretReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); - public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + public java.lang.String getUser(); + public A withUser(java.lang.String user); + public java.lang.Boolean hasUser(); - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretReferenceFluent>{ + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretReferenceFluent< + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent + .SecretRefNested< + N>> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSPersistentVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSPersistentVolumeSourceFluentImpl.java index 40d594bf94..fef2ec0cad 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSPersistentVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSPersistentVolumeSourceFluentImpl.java @@ -1,24 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1CephFSPersistentVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent{ - public V1CephFSPersistentVolumeSourceFluentImpl() { - } - public V1CephFSPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource instance) { +/** Generated */ +public class V1CephFSPersistentVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent { + public V1CephFSPersistentVolumeSourceFluentImpl() {} + + public V1CephFSPersistentVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource instance) { this.withMonitors(instance.getMonitors()); this.withPath(instance.getPath()); @@ -30,192 +32,308 @@ public V1CephFSPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.mod this.withSecretRef(instance.getSecretRef()); this.withUser(instance.getUser()); - } + private java.util.List monitors; private java.lang.String path; private java.lang.Boolean readOnly; private java.lang.String secretFile; private io.kubernetes.client.openapi.models.V1SecretReferenceBuilder secretRef; private java.lang.String user; - public A addToMonitors(java.lang.Integer index,java.lang.String item) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} + + public A addToMonitors(java.lang.Integer index, java.lang.String item) { + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } this.monitors.add(index, item); - return (A)this; + return (A) this; } - public A setToMonitors(java.lang.Integer index,java.lang.String item) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} - this.monitors.set(index, item); return (A)this; + + public A setToMonitors(java.lang.Integer index, java.lang.String item) { + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } + this.monitors.set(index, item); + return (A) this; } + public A addToMonitors(java.lang.String... items) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} - for (java.lang.String item : items) {this.monitors.add(item);} return (A)this; + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.monitors.add(item); + } + return (A) this; } + public A addAllToMonitors(java.util.Collection items) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} - for (java.lang.String item : items) {this.monitors.add(item);} return (A)this; + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.monitors.add(item); + } + return (A) this; } + public A removeFromMonitors(java.lang.String... items) { - for (java.lang.String item : items) {if (this.monitors!= null){ this.monitors.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.monitors != null) { + this.monitors.remove(item); + } + } + return (A) this; } + public A removeAllFromMonitors(java.util.Collection items) { - for (java.lang.String item : items) {if (this.monitors!= null){ this.monitors.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.monitors != null) { + this.monitors.remove(item); + } + } + return (A) this; } + public java.util.List getMonitors() { return this.monitors; } + public java.lang.String getMonitor(java.lang.Integer index) { return this.monitors.get(index); } + public java.lang.String getFirstMonitor() { return this.monitors.get(0); } + public java.lang.String getLastMonitor() { return this.monitors.get(monitors.size() - 1); } - public java.lang.String getMatchingMonitor(java.util.function.Predicate predicate) { - for (java.lang.String item: monitors) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingMonitor( + java.util.function.Predicate predicate) { + for (java.lang.String item : monitors) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingMonitor(java.util.function.Predicate predicate) { - for (java.lang.String item: monitors) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMonitor( + java.util.function.Predicate predicate) { + for (java.lang.String item : monitors) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withMonitors(java.util.List monitors) { - if (monitors != null) {this.monitors = new java.util.ArrayList(); for (java.lang.String item : monitors){this.addToMonitors(item);}} else { this.monitors = null;} return (A) this; + if (monitors != null) { + this.monitors = new java.util.ArrayList(); + for (java.lang.String item : monitors) { + this.addToMonitors(item); + } + } else { + this.monitors = null; + } + return (A) this; } + public A withMonitors(java.lang.String... monitors) { - if (this.monitors != null) {this.monitors.clear();} - if (monitors != null) {for (java.lang.String item :monitors){ this.addToMonitors(item);}} return (A) this; + if (this.monitors != null) { + this.monitors.clear(); + } + if (monitors != null) { + for (java.lang.String item : monitors) { + this.addToMonitors(item); + } + } + return (A) this; } + public java.lang.Boolean hasMonitors() { return monitors != null && !monitors.isEmpty(); } + public A addNewMonitor(java.lang.String original) { - return (A)addToMonitors(new String(original)); + return (A) addToMonitors(new String(original)); } + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public java.lang.String getSecretFile() { return this.secretFile; } + public A withSecretFile(java.lang.String secretFile) { - this.secretFile=secretFile; return (A) this; + this.secretFile = secretFile; + return (A) this; } + public java.lang.Boolean hasSecretFile() { return this.secretFile != null; } - - /** - * Method is deprecated. use withSecretFile instead. - */ + + /** Method is deprecated. use withSecretFile instead. */ @java.lang.Deprecated public A withNewSecretFile(java.lang.String original) { - return (A)withSecretFile(new String(original)); + return (A) withSecretFile(new String(original)); } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return new io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return new io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public java.lang.String getUser() { return this.user; } + public A withUser(java.lang.String user) { - this.user=user; return (A) this; + this.user = user; + return (A) this; } + public java.lang.Boolean hasUser() { return this.user != null; } - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original) { - return (A)withUser(new String(original)); + return (A) withUser(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CephFSPersistentVolumeSourceFluentImpl that = (V1CephFSPersistentVolumeSourceFluentImpl) o; - if (monitors != null ? !monitors.equals(that.monitors) :that.monitors != null) return false; - if (path != null ? !path.equals(that.path) :that.path != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretFile != null ? !secretFile.equals(that.secretFile) :that.secretFile != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; - if (user != null ? !user.equals(that.user) :that.user != null) return false; + if (monitors != null ? !monitors.equals(that.monitors) : that.monitors != null) return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretFile != null ? !secretFile.equals(that.secretFile) : that.secretFile != null) + return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; + if (user != null ? !user.equals(that.user) : that.user != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(monitors, path, readOnly, secretFile, secretRef, user, super.hashCode()); + return java.util.Objects.hash( + monitors, path, readOnly, secretFile, secretRef, user, super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent.SecretRefNested< + N>> + implements io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent + .SecretRefNested< + N>, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1SecretReference item) { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretReferenceBuilder builder; + public N and() { return (N) V1CephFSPersistentVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSVolumeSourceBuilder.java index 3bc0735513..e05518553c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CephFSVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CephFSVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1CephFSVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CephFSVolumeSource, + io.kubernetes.client.openapi.models.V1CephFSVolumeSourceBuilder> { public V1CephFSVolumeSourceBuilder() { this(false); } + public V1CephFSVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1CephFSVolumeSource(), validationEnabled); } - public V1CephFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent fluent) { + + public V1CephFSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent fluent) { this(fluent, false); } - public V1CephFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CephFSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CephFSVolumeSource(), validationEnabled); } - public V1CephFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1CephFSVolumeSource instance) { + + public V1CephFSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1CephFSVolumeSource instance) { this(fluent, instance, false); } - public V1CephFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1CephFSVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CephFSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1CephFSVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMonitors(instance.getMonitors()); fluent.withPath(instance.getPath()); @@ -33,13 +60,18 @@ public V1CephFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSV fluent.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CephFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSVolumeSource instance) { - this(instance,false); + + public V1CephFSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CephFSVolumeSource instance) { + this(instance, false); } - public V1CephFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CephFSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CephFSVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMonitors(instance.getMonitors()); this.withPath(instance.getPath()); @@ -52,10 +84,12 @@ public V1CephFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CephFSV this.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CephFSVolumeSource build() { V1CephFSVolumeSource buildable = new V1CephFSVolumeSource(); buildable.setMonitors(fluent.getMonitors()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1CephFSVolumeSource build() { buildable.setUser(fluent.getUser()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CephFSVolumeSourceBuilder that = (V1CephFSVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSVolumeSourceFluent.java index 3943288cc3..bc472afc21 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSVolumeSourceFluent.java @@ -1,86 +1,126 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CephFSVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToMonitors(java.lang.Integer index,java.lang.String item); - public A setToMonitors(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1CephFSVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToMonitors(java.lang.Integer index, java.lang.String item); + + public A setToMonitors(java.lang.Integer index, java.lang.String item); + public A addToMonitors(java.lang.String... items); + public A addAllToMonitors(java.util.Collection items); + public A removeFromMonitors(java.lang.String... items); + public A removeAllFromMonitors(java.util.Collection items); + public java.util.List getMonitors(); + public java.lang.String getMonitor(java.lang.Integer index); + public java.lang.String getFirstMonitor(); + public java.lang.String getLastMonitor(); - public java.lang.String getMatchingMonitor(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMonitor(java.util.function.Predicate predicate); + + public java.lang.String getMatchingMonitor( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingMonitor( + java.util.function.Predicate predicate); + public A withMonitors(java.util.List monitors); + public A withMonitors(java.lang.String... monitors); + public java.lang.Boolean hasMonitors(); + public A addNewMonitor(java.lang.String original); + public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); + public java.lang.String getSecretFile(); + public A withSecretFile(java.lang.String secretFile); + public java.lang.Boolean hasSecretFile(); - - /** - * Method is deprecated. use withSecretFile instead. - */ + + /** Method is deprecated. use withSecretFile instead. */ @java.lang.Deprecated public A withNewSecretFile(java.lang.String original); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + public java.lang.String getUser(); + public A withUser(java.lang.String user); + public java.lang.Boolean hasUser(); - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent>{ + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSVolumeSourceFluentImpl.java index bd8cb59d8c..b2dac68d5c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CephFSVolumeSourceFluentImpl.java @@ -1,24 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1CephFSVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent{ - public V1CephFSVolumeSourceFluentImpl() { - } - public V1CephFSVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1CephFSVolumeSource instance) { +/** Generated */ +public class V1CephFSVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent { + public V1CephFSVolumeSourceFluentImpl() {} + + public V1CephFSVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1CephFSVolumeSource instance) { this.withMonitors(instance.getMonitors()); this.withPath(instance.getPath()); @@ -30,192 +32,307 @@ public V1CephFSVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1Ceph this.withSecretRef(instance.getSecretRef()); this.withUser(instance.getUser()); - } + private java.util.List monitors; private java.lang.String path; private java.lang.Boolean readOnly; private java.lang.String secretFile; private io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder secretRef; private java.lang.String user; - public A addToMonitors(java.lang.Integer index,java.lang.String item) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} + + public A addToMonitors(java.lang.Integer index, java.lang.String item) { + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } this.monitors.add(index, item); - return (A)this; + return (A) this; } - public A setToMonitors(java.lang.Integer index,java.lang.String item) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} - this.monitors.set(index, item); return (A)this; + + public A setToMonitors(java.lang.Integer index, java.lang.String item) { + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } + this.monitors.set(index, item); + return (A) this; } + public A addToMonitors(java.lang.String... items) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} - for (java.lang.String item : items) {this.monitors.add(item);} return (A)this; + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.monitors.add(item); + } + return (A) this; } + public A addAllToMonitors(java.util.Collection items) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} - for (java.lang.String item : items) {this.monitors.add(item);} return (A)this; + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.monitors.add(item); + } + return (A) this; } + public A removeFromMonitors(java.lang.String... items) { - for (java.lang.String item : items) {if (this.monitors!= null){ this.monitors.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.monitors != null) { + this.monitors.remove(item); + } + } + return (A) this; } + public A removeAllFromMonitors(java.util.Collection items) { - for (java.lang.String item : items) {if (this.monitors!= null){ this.monitors.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.monitors != null) { + this.monitors.remove(item); + } + } + return (A) this; } + public java.util.List getMonitors() { return this.monitors; } + public java.lang.String getMonitor(java.lang.Integer index) { return this.monitors.get(index); } + public java.lang.String getFirstMonitor() { return this.monitors.get(0); } + public java.lang.String getLastMonitor() { return this.monitors.get(monitors.size() - 1); } - public java.lang.String getMatchingMonitor(java.util.function.Predicate predicate) { - for (java.lang.String item: monitors) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingMonitor( + java.util.function.Predicate predicate) { + for (java.lang.String item : monitors) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingMonitor(java.util.function.Predicate predicate) { - for (java.lang.String item: monitors) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMonitor( + java.util.function.Predicate predicate) { + for (java.lang.String item : monitors) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withMonitors(java.util.List monitors) { - if (monitors != null) {this.monitors = new java.util.ArrayList(); for (java.lang.String item : monitors){this.addToMonitors(item);}} else { this.monitors = null;} return (A) this; + if (monitors != null) { + this.monitors = new java.util.ArrayList(); + for (java.lang.String item : monitors) { + this.addToMonitors(item); + } + } else { + this.monitors = null; + } + return (A) this; } + public A withMonitors(java.lang.String... monitors) { - if (this.monitors != null) {this.monitors.clear();} - if (monitors != null) {for (java.lang.String item :monitors){ this.addToMonitors(item);}} return (A) this; + if (this.monitors != null) { + this.monitors.clear(); + } + if (monitors != null) { + for (java.lang.String item : monitors) { + this.addToMonitors(item); + } + } + return (A) this; } + public java.lang.Boolean hasMonitors() { return monitors != null && !monitors.isEmpty(); } + public A addNewMonitor(java.lang.String original) { - return (A)addToMonitors(new String(original)); + return (A) addToMonitors(new String(original)); } + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public java.lang.String getSecretFile() { return this.secretFile; } + public A withSecretFile(java.lang.String secretFile) { - this.secretFile=secretFile; return (A) this; + this.secretFile = secretFile; + return (A) this; } + public java.lang.Boolean hasSecretFile() { return this.secretFile != null; } - - /** - * Method is deprecated. use withSecretFile instead. - */ + + /** Method is deprecated. use withSecretFile instead. */ @java.lang.Deprecated public A withNewSecretFile(java.lang.String original) { - return (A)withSecretFile(new String(original)); + return (A) withSecretFile(new String(original)); } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluentImpl + .SecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public java.lang.String getUser() { return this.user; } + public A withUser(java.lang.String user) { - this.user=user; return (A) this; + this.user = user; + return (A) this; } + public java.lang.Boolean hasUser() { return this.user != null; } - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original) { - return (A)withUser(new String(original)); + return (A) withUser(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CephFSVolumeSourceFluentImpl that = (V1CephFSVolumeSourceFluentImpl) o; - if (monitors != null ? !monitors.equals(that.monitors) :that.monitors != null) return false; - if (path != null ? !path.equals(that.path) :that.path != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretFile != null ? !secretFile.equals(that.secretFile) :that.secretFile != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; - if (user != null ? !user.equals(that.user) :that.user != null) return false; + if (monitors != null ? !monitors.equals(that.monitors) : that.monitors != null) return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretFile != null ? !secretFile.equals(that.secretFile) : that.secretFile != null) + return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; + if (user != null ? !user.equals(that.user) : that.user != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(monitors, path, readOnly, secretFile, secretRef, user, super.hashCode()); + return java.util.Objects.hash( + monitors, path, readOnly, secretFile, secretRef, user, super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested> + implements io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent.SecretRefNested, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder; + public N and() { return (N) V1CephFSVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestBuilder.java index 81f25a6f82..763741493b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CertificateSigningRequestBuilder extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CertificateSigningRequestBuilder + extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CertificateSigningRequest, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder> { public V1CertificateSigningRequestBuilder() { this(false); } + public V1CertificateSigningRequestBuilder(java.lang.Boolean validationEnabled) { this(new V1CertificateSigningRequest(), validationEnabled); } - public V1CertificateSigningRequestBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent fluent) { + + public V1CertificateSigningRequestBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent fluent) { this(fluent, false); } - public V1CertificateSigningRequestBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CertificateSigningRequestBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CertificateSigningRequest(), validationEnabled); } - public V1CertificateSigningRequestBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent fluent,io.kubernetes.client.openapi.models.V1CertificateSigningRequest instance) { + + public V1CertificateSigningRequestBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent fluent, + io.kubernetes.client.openapi.models.V1CertificateSigningRequest instance) { this(fluent, instance, false); } - public V1CertificateSigningRequestBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent fluent,io.kubernetes.client.openapi.models.V1CertificateSigningRequest instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CertificateSigningRequestBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent fluent, + io.kubernetes.client.openapi.models.V1CertificateSigningRequest instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1CertificateSigningRequestBuilder(io.kubernetes.client.openapi.models.V1 fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CertificateSigningRequestBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequest instance) { - this(instance,false); + + public V1CertificateSigningRequestBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequest instance) { + this(instance, false); } - public V1CertificateSigningRequestBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequest instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CertificateSigningRequestBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequest instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1CertificateSigningRequestBuilder(io.kubernetes.client.openapi.models.V1 this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CertificateSigningRequest build() { V1CertificateSigningRequest buildable = new V1CertificateSigningRequest(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1CertificateSigningRequest build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CertificateSigningRequestBuilder that = (V1CertificateSigningRequestBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestConditionBuilder.java index a80d694758..4b70b1c976 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CertificateSigningRequestConditionBuilder extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CertificateSigningRequestConditionBuilder + extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluentImpl< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder> { public V1CertificateSigningRequestConditionBuilder() { this(false); } + public V1CertificateSigningRequestConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1CertificateSigningRequestCondition(), validationEnabled); } - public V1CertificateSigningRequestConditionBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent fluent) { + + public V1CertificateSigningRequestConditionBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent fluent) { this(fluent, false); } - public V1CertificateSigningRequestConditionBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CertificateSigningRequestConditionBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CertificateSigningRequestCondition(), validationEnabled); } - public V1CertificateSigningRequestConditionBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent fluent,io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition instance) { + + public V1CertificateSigningRequestConditionBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent fluent, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition instance) { this(fluent, instance, false); } - public V1CertificateSigningRequestConditionBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent fluent,io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CertificateSigningRequestConditionBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent fluent, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withLastUpdateTime(instance.getLastUpdateTime()); @@ -33,13 +60,18 @@ public V1CertificateSigningRequestConditionBuilder(io.kubernetes.client.openapi. fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CertificateSigningRequestConditionBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition instance) { - this(instance,false); + + public V1CertificateSigningRequestConditionBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition instance) { + this(instance, false); } - public V1CertificateSigningRequestConditionBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CertificateSigningRequestConditionBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withLastUpdateTime(instance.getLastUpdateTime()); @@ -52,10 +84,12 @@ public V1CertificateSigningRequestConditionBuilder(io.kubernetes.client.openapi. this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition build() { V1CertificateSigningRequestCondition buildable = new V1CertificateSigningRequestCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -66,18 +100,24 @@ public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1CertificateSigningRequestConditionBuilder that = (V1CertificateSigningRequestConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1CertificateSigningRequestConditionBuilder that = + (V1CertificateSigningRequestConditionBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestConditionFluent.java index a777d7e2f1..7fc2db6f36 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestConditionFluent.java @@ -1,51 +1,68 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CertificateSigningRequestConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CertificateSigningRequestConditionFluent< + A extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.time.OffsetDateTime getLastUpdateTime(); + public A withLastUpdateTime(java.time.OffsetDateTime lastUpdateTime); + public java.lang.Boolean hasLastUpdateTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition.TypeEnum getType(); - public A withType(io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition.TypeEnum type); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition.TypeEnum + getType(); + + public A withType( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition.TypeEnum type); + public java.lang.Boolean hasType(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestConditionFluentImpl.java index ed5181e423..1bd571bab6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestConditionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1CertificateSigningRequestConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent { + public V1CertificateSigningRequestConditionFluentImpl() {} - /** - * Generated - */ -public class V1CertificateSigningRequestConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent{ - public V1CertificateSigningRequestConditionFluentImpl() { - } - public V1CertificateSigningRequestConditionFluentImpl(io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition instance) { + public V1CertificateSigningRequestConditionFluentImpl( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withLastUpdateTime(instance.getLastUpdateTime()); @@ -25,106 +32,133 @@ public V1CertificateSigningRequestConditionFluentImpl(io.kubernetes.client.opena this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.time.OffsetDateTime lastUpdateTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition.TypeEnum type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.time.OffsetDateTime getLastUpdateTime() { return this.lastUpdateTime; } + public A withLastUpdateTime(java.time.OffsetDateTime lastUpdateTime) { - this.lastUpdateTime=lastUpdateTime; return (A) this; + this.lastUpdateTime = lastUpdateTime; + return (A) this; } + public java.lang.Boolean hasLastUpdateTime() { return this.lastUpdateTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition.TypeEnum getType() { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition.TypeEnum + getType() { return this.type; } - public A withType(io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition.TypeEnum type) { - this.type=type; return (A) this; + + public A withType( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition.TypeEnum type) { + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1CertificateSigningRequestConditionFluentImpl that = (V1CertificateSigningRequestConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (lastUpdateTime != null ? !lastUpdateTime.equals(that.lastUpdateTime) :that.lastUpdateTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + V1CertificateSigningRequestConditionFluentImpl that = + (V1CertificateSigningRequestConditionFluentImpl) o; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (lastUpdateTime != null + ? !lastUpdateTime.equals(that.lastUpdateTime) + : that.lastUpdateTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, lastUpdateTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, lastUpdateTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestFluent.java index 1e0535c84e..3d45dcf10b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestFluent.java @@ -1,93 +1,155 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CertificateSigningRequestFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CertificateSigningRequestFluent< + A extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec getSpec(); + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec item); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec item); - + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus getStatus(); + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus item); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested< + N>> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestFluentImpl.java index cd912bf866..a4b068b0e0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1CertificateSigningRequestFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent { + public V1CertificateSigningRequestFluentImpl() {} - /** - * Generated - */ -public class V1CertificateSigningRequestFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent{ - public V1CertificateSigningRequestFluentImpl() { - } - public V1CertificateSigningRequestFluentImpl(io.kubernetes.client.openapi.models.V1CertificateSigningRequest instance) { + public V1CertificateSigningRequestFluentImpl( + io.kubernetes.client.openapi.models.V1CertificateSigningRequest instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,326 @@ public V1CertificateSigningRequestFluentImpl(io.kubernetes.client.openapi.models this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecBuilder spec; private io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec item) { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec item) { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } - public A withStatus(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus status) { + + public A withStatus( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus item) { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested + withNewStatusLike( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus item) { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CertificateSigningRequestFluentImpl that = (V1CertificateSigningRequestFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1CertificateSigningRequestFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluentImpl< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.SpecNested< + N>, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecBuilder( + this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecBuilder builder; + public N and() { return (N) V1CertificateSigningRequestFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluentImpl< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent.StatusNested< + N>, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusBuilder( + this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusBuilder builder; + public N and() { return (N) V1CertificateSigningRequestFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestListBuilder.java index deb3776363..c6f1c3b97a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CertificateSigningRequestListBuilder extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CertificateSigningRequestListBuilder + extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluentImpl< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestList, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestListBuilder> { public V1CertificateSigningRequestListBuilder() { this(false); } + public V1CertificateSigningRequestListBuilder(java.lang.Boolean validationEnabled) { this(new V1CertificateSigningRequestList(), validationEnabled); } - public V1CertificateSigningRequestListBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent fluent) { + + public V1CertificateSigningRequestListBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent fluent) { this(fluent, false); } - public V1CertificateSigningRequestListBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CertificateSigningRequestListBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CertificateSigningRequestList(), validationEnabled); } - public V1CertificateSigningRequestListBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent fluent,io.kubernetes.client.openapi.models.V1CertificateSigningRequestList instance) { + + public V1CertificateSigningRequestListBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent fluent, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestList instance) { this(fluent, instance, false); } - public V1CertificateSigningRequestListBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent fluent,io.kubernetes.client.openapi.models.V1CertificateSigningRequestList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CertificateSigningRequestListBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent fluent, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1CertificateSigningRequestListBuilder(io.kubernetes.client.openapi.model fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CertificateSigningRequestListBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestList instance) { - this(instance,false); + + public V1CertificateSigningRequestListBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestList instance) { + this(instance, false); } - public V1CertificateSigningRequestListBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CertificateSigningRequestListBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1CertificateSigningRequestListBuilder(io.kubernetes.client.openapi.model this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestList build() { V1CertificateSigningRequestList buildable = new V1CertificateSigningRequestList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1CertificateSigningRequestList build buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CertificateSigningRequestListBuilder that = (V1CertificateSigningRequestListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestListFluent.java index 14e3f53922..e4b72a0392 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestListFluent.java @@ -1,95 +1,173 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CertificateSigningRequestListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CertificateSigningRequestListFluent< + A extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequest item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequest item); + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequest item); + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequest item); + public A addToItems(io.kubernetes.client.openapi.models.V1CertificateSigningRequest... items); - public A addAllToItems(java.util.Collection items); - public A removeFromItems(io.kubernetes.client.openapi.models.V1CertificateSigningRequest... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A addAllToItems( + java.util.Collection items); + + public A removeFromItems( + io.kubernetes.client.openapi.models.V1CertificateSigningRequest... items); + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); - public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequest buildItem(java.lang.Integer index); + + public java.util.List + buildItems(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequest buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1CertificateSigningRequest buildFirstItem(); + public io.kubernetes.client.openapi.models.V1CertificateSigningRequest buildLastItem(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequest buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequest buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1CertificateSigningRequest... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequest item); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequest item); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequest item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequest item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent>{ + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluent< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestListFluentImpl.java index 10c3dcbd27..9abcf9e6bd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1CertificateSigningRequestListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent{ - public V1CertificateSigningRequestListFluentImpl() { - } - public V1CertificateSigningRequestListFluentImpl(io.kubernetes.client.openapi.models.V1CertificateSigningRequestList instance) { + +/** Generated */ +public class V1CertificateSigningRequestListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent { + public V1CertificateSigningRequestListFluentImpl() {} + + public V1CertificateSigningRequestListFluentImpl( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,136 @@ public V1CertificateSigningRequestListFluentImpl(io.kubernetes.client.openapi.mo this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder> + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequest item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequest item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder>(); + } + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequest item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequest item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder>(); + } + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1CertificateSigningRequest... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CertificateSigningRequest item : items) {io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequest item : items) { + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CertificateSigningRequest item : items) {io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequest item : items) { + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A removeFromItems(io.kubernetes.client.openapi.models.V1CertificateSigningRequest... items) { - for (io.kubernetes.client.openapi.models.V1CertificateSigningRequest item : items) {io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeFromItems( + io.kubernetes.client.openapi.models.V1CertificateSigningRequest... items) { + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequest item : items) { + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1CertificateSigningRequest item : items) {io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequest item : items) { + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder = each.next(); @@ -87,174 +169,298 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { + public java.util.List + getItems() { return items != null ? build(items) : null; } - public java.util.List buildItems() { + + public java.util.List + buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequest buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequest buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1CertificateSigningRequest buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1CertificateSigningRequest buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequest buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequest buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1CertificateSigningRequest item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequest item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1CertificateSigningRequest... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1CertificateSigningRequest item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequest item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequest item) { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequest item) { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequest item) { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequest item) { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CertificateSigningRequestListFluentImpl that = (V1CertificateSigningRequestListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl> implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequest item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestFluentImpl< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent + .ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequest item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder(this); } + io.kubernetes.client.openapi.models.V1CertificateSigningRequestBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1CertificateSigningRequestListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1CertificateSigningRequestListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent.MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1CertificateSigningRequestListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestSpecBuilder.java index 6c392cc724..bef4585dc3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CertificateSigningRequestSpecBuilder extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CertificateSigningRequestSpecBuilder + extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluentImpl< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecBuilder> { public V1CertificateSigningRequestSpecBuilder() { this(false); } + public V1CertificateSigningRequestSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1CertificateSigningRequestSpec(), validationEnabled); } - public V1CertificateSigningRequestSpecBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent fluent) { + + public V1CertificateSigningRequestSpecBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent fluent) { this(fluent, false); } - public V1CertificateSigningRequestSpecBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CertificateSigningRequestSpecBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CertificateSigningRequestSpec(), validationEnabled); } - public V1CertificateSigningRequestSpecBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent fluent,io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec instance) { + + public V1CertificateSigningRequestSpecBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent fluent, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec instance) { this(fluent, instance, false); } - public V1CertificateSigningRequestSpecBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent fluent,io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CertificateSigningRequestSpecBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent fluent, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withExpirationSeconds(instance.getExpirationSeconds()); fluent.withExtra(instance.getExtra()); @@ -37,13 +64,18 @@ public V1CertificateSigningRequestSpecBuilder(io.kubernetes.client.openapi.model fluent.withUsername(instance.getUsername()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CertificateSigningRequestSpecBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec instance) { - this(instance,false); + + public V1CertificateSigningRequestSpecBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec instance) { + this(instance, false); } - public V1CertificateSigningRequestSpecBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CertificateSigningRequestSpecBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withExpirationSeconds(instance.getExpirationSeconds()); this.withExtra(instance.getExtra()); @@ -60,10 +92,12 @@ public V1CertificateSigningRequestSpecBuilder(io.kubernetes.client.openapi.model this.withUsername(instance.getUsername()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec build() { V1CertificateSigningRequestSpec buildable = new V1CertificateSigningRequestSpec(); buildable.setExpirationSeconds(fluent.getExpirationSeconds()); @@ -76,18 +110,23 @@ public io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec build buildable.setUsername(fluent.getUsername()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CertificateSigningRequestSpecBuilder that = (V1CertificateSigningRequestSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestSpecFluent.java index 58b12fad5e..1f9ed547b4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestSpecFluent.java @@ -1,100 +1,155 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Byte; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1CertificateSigningRequestSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CertificateSigningRequestSpecFluent< + A extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getExpirationSeconds(); + public A withExpirationSeconds(java.lang.Integer expirationSeconds); + public java.lang.Boolean hasExpirationSeconds(); - public A addToExtra(java.lang.String key,java.util.List value); - public A addToExtra(java.util.Map> map); + + public A addToExtra(java.lang.String key, java.util.List value); + + public A addToExtra(java.util.Map> map); + public A removeFromExtra(java.lang.String key); - public A removeFromExtra(java.util.Map> map); - public java.util.Map> getExtra(); - public A withExtra(java.util.Map> extra); + + public A removeFromExtra(java.util.Map> map); + + public java.util.Map> getExtra(); + + public A withExtra( + java.util.Map> extra); + public java.lang.Boolean hasExtra(); - public A addToGroups(java.lang.Integer index,java.lang.String item); - public A setToGroups(java.lang.Integer index,java.lang.String item); + + public A addToGroups(java.lang.Integer index, java.lang.String item); + + public A setToGroups(java.lang.Integer index, java.lang.String item); + public A addToGroups(java.lang.String... items); + public A addAllToGroups(java.util.Collection items); + public A removeFromGroups(java.lang.String... items); + public A removeAllFromGroups(java.util.Collection items); + public java.util.List getGroups(); + public java.lang.String getGroup(java.lang.Integer index); + public java.lang.String getFirstGroup(); + public java.lang.String getLastGroup(); - public java.lang.String getMatchingGroup(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingGroup(java.util.function.Predicate predicate); + + public java.lang.String getMatchingGroup( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingGroup( + java.util.function.Predicate predicate); + public A withGroups(java.util.List groups); + public A withGroups(java.lang.String... groups); + public java.lang.Boolean hasGroups(); + public A addNewGroup(java.lang.String original); + public A withRequest(byte... request); + public byte[] getRequest(); - public A addToRequest(java.lang.Integer index,java.lang.Byte item); - public A setToRequest(java.lang.Integer index,java.lang.Byte item); + + public A addToRequest(java.lang.Integer index, java.lang.Byte item); + + public A setToRequest(java.lang.Integer index, java.lang.Byte item); + public A addToRequest(java.lang.Byte... items); + public A addAllToRequest(java.util.Collection items); + public A removeFromRequest(java.lang.Byte... items); + public A removeAllFromRequest(java.util.Collection items); + public java.lang.Boolean hasRequest(); + public java.lang.String getSignerName(); + public A withSignerName(java.lang.String signerName); + public java.lang.Boolean hasSignerName(); - - /** - * Method is deprecated. use withSignerName instead. - */ + + /** Method is deprecated. use withSignerName instead. */ @java.lang.Deprecated public A withNewSignerName(java.lang.String original); + public java.lang.String getUid(); + public A withUid(java.lang.String uid); + public java.lang.Boolean hasUid(); - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original); - public A addToUsages(java.lang.Integer index,java.lang.String item); - public A setToUsages(java.lang.Integer index,java.lang.String item); + + public A addToUsages(java.lang.Integer index, java.lang.String item); + + public A setToUsages(java.lang.Integer index, java.lang.String item); + public A addToUsages(java.lang.String... items); + public A addAllToUsages(java.util.Collection items); + public A removeFromUsages(java.lang.String... items); + public A removeAllFromUsages(java.util.Collection items); + public java.util.List getUsages(); + public java.lang.String getUsage(java.lang.Integer index); + public java.lang.String getFirstUsage(); + public java.lang.String getLastUsage(); - public java.lang.String getMatchingUsage(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingUsage(java.util.function.Predicate predicate); + + public java.lang.String getMatchingUsage( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingUsage( + java.util.function.Predicate predicate); + public A withUsages(java.util.List usages); + public A withUsages(java.lang.String... usages); + public java.lang.Boolean hasUsages(); + public A addNewUsage(java.lang.String original); + public java.lang.String getUsername(); + public A withUsername(java.lang.String username); + public java.lang.Boolean hasUsername(); - - /** - * Method is deprecated. use withUsername instead. - */ + + /** Method is deprecated. use withUsername instead. */ @java.lang.Deprecated public A withNewUsername(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestSpecFluentImpl.java index 5310b8dea7..1fa42bbddf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestSpecFluentImpl.java @@ -1,26 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Byte; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public class V1CertificateSigningRequestSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent{ - public V1CertificateSigningRequestSpecFluentImpl() { - } - public V1CertificateSigningRequestSpecFluentImpl(io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec instance) { +/** Generated */ +public class V1CertificateSigningRequestSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpecFluent { + public V1CertificateSigningRequestSpecFluentImpl() {} + + public V1CertificateSigningRequestSpecFluentImpl( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestSpec instance) { this.withExpirationSeconds(instance.getExpirationSeconds()); this.withExtra(instance.getExtra()); @@ -36,269 +36,505 @@ public V1CertificateSigningRequestSpecFluentImpl(io.kubernetes.client.openapi.mo this.withUsages(instance.getUsages()); this.withUsername(instance.getUsername()); - } + private java.lang.Integer expirationSeconds; - private java.util.Map> extra; + private java.util.Map> extra; private java.util.List groups; private java.util.List request; private java.lang.String signerName; private java.lang.String uid; private java.util.List usages; private java.lang.String username; + public java.lang.Integer getExpirationSeconds() { return this.expirationSeconds; } + public A withExpirationSeconds(java.lang.Integer expirationSeconds) { - this.expirationSeconds=expirationSeconds; return (A) this; + this.expirationSeconds = expirationSeconds; + return (A) this; } + public java.lang.Boolean hasExpirationSeconds() { return this.expirationSeconds != null; } - public A addToExtra(java.lang.String key,java.util.List value) { - if(this.extra == null && key != null && value != null) { this.extra = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.extra.put(key, value);} return (A)this; + + public A addToExtra(java.lang.String key, java.util.List value) { + if (this.extra == null && key != null && value != null) { + this.extra = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.extra.put(key, value); + } + return (A) this; } - public A addToExtra(java.util.Map> map) { - if(this.extra == null && map != null) { this.extra = new java.util.LinkedHashMap(); } - if(map != null) { this.extra.putAll(map);} return (A)this; + + public A addToExtra(java.util.Map> map) { + if (this.extra == null && map != null) { + this.extra = new java.util.LinkedHashMap(); + } + if (map != null) { + this.extra.putAll(map); + } + return (A) this; } + public A removeFromExtra(java.lang.String key) { - if(this.extra == null) { return (A) this; } - if(key != null && this.extra != null) {this.extra.remove(key);} return (A)this; + if (this.extra == null) { + return (A) this; + } + if (key != null && this.extra != null) { + this.extra.remove(key); + } + return (A) this; } - public A removeFromExtra(java.util.Map> map) { - if(this.extra == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.extra != null){this.extra.remove(key);}}} return (A)this; + + public A removeFromExtra(java.util.Map> map) { + if (this.extra == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.extra != null) { + this.extra.remove(key); + } + } + } + return (A) this; } - public java.util.Map> getExtra() { + + public java.util.Map> getExtra() { return this.extra; } - public A withExtra(java.util.Map> extra) { - if (extra == null) { this.extra = null;} else {this.extra = new java.util.LinkedHashMap(extra);} return (A) this; + + public A withExtra( + java.util.Map> extra) { + if (extra == null) { + this.extra = null; + } else { + this.extra = new java.util.LinkedHashMap(extra); + } + return (A) this; } + public java.lang.Boolean hasExtra() { return this.extra != null; } - public A addToGroups(java.lang.Integer index,java.lang.String item) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} + + public A addToGroups(java.lang.Integer index, java.lang.String item) { + if (this.groups == null) { + this.groups = new java.util.ArrayList(); + } this.groups.add(index, item); - return (A)this; + return (A) this; } - public A setToGroups(java.lang.Integer index,java.lang.String item) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} - this.groups.set(index, item); return (A)this; + + public A setToGroups(java.lang.Integer index, java.lang.String item) { + if (this.groups == null) { + this.groups = new java.util.ArrayList(); + } + this.groups.set(index, item); + return (A) this; } + public A addToGroups(java.lang.String... items) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.groups.add(item);} return (A)this; + if (this.groups == null) { + this.groups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.groups.add(item); + } + return (A) this; } + public A addAllToGroups(java.util.Collection items) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.groups.add(item);} return (A)this; + if (this.groups == null) { + this.groups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.groups.add(item); + } + return (A) this; } + public A removeFromGroups(java.lang.String... items) { - for (java.lang.String item : items) {if (this.groups!= null){ this.groups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.groups != null) { + this.groups.remove(item); + } + } + return (A) this; } + public A removeAllFromGroups(java.util.Collection items) { - for (java.lang.String item : items) {if (this.groups!= null){ this.groups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.groups != null) { + this.groups.remove(item); + } + } + return (A) this; } + public java.util.List getGroups() { return this.groups; } + public java.lang.String getGroup(java.lang.Integer index) { return this.groups.get(index); } + public java.lang.String getFirstGroup() { return this.groups.get(0); } + public java.lang.String getLastGroup() { return this.groups.get(groups.size() - 1); } - public java.lang.String getMatchingGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: groups) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : groups) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: groups) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : groups) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withGroups(java.util.List groups) { - if (groups != null) {this.groups = new java.util.ArrayList(); for (java.lang.String item : groups){this.addToGroups(item);}} else { this.groups = null;} return (A) this; + if (groups != null) { + this.groups = new java.util.ArrayList(); + for (java.lang.String item : groups) { + this.addToGroups(item); + } + } else { + this.groups = null; + } + return (A) this; } + public A withGroups(java.lang.String... groups) { - if (this.groups != null) {this.groups.clear();} - if (groups != null) {for (java.lang.String item :groups){ this.addToGroups(item);}} return (A) this; + if (this.groups != null) { + this.groups.clear(); + } + if (groups != null) { + for (java.lang.String item : groups) { + this.addToGroups(item); + } + } + return (A) this; } + public java.lang.Boolean hasGroups() { return groups != null && !groups.isEmpty(); } + public A addNewGroup(java.lang.String original) { - return (A)addToGroups(new String(original)); + return (A) addToGroups(new String(original)); } + public A withRequest(byte... request) { - if (this.request != null) {this.request.clear();} - if (request != null) {for (byte item :request){ this.addToRequest(item);}} return (A) this; + if (this.request != null) { + this.request.clear(); + } + if (request != null) { + for (byte item : request) { + this.addToRequest(item); + } + } + return (A) this; } - public byte[] getRequest() { - //This needs to work with primitives, so we use arrays. -int size = request != null ? request.size() : 0; -byte[] result = new byte[size]; -if (size == 0) { - return result; -} -int index = 0; -for (byte item : request) { - result[index++]=item; -} -return result; + public byte[] getRequest() { + // This needs to work with primitives, so we use arrays. + int size = request != null ? request.size() : 0; + byte[] result = new byte[size]; + if (size == 0) { + return result; + } + int index = 0; + for (byte item : request) { + result[index++] = item; + } + return result; } - public A addToRequest(java.lang.Integer index,java.lang.Byte item) { - if (this.request == null) {this.request = new java.util.ArrayList();} + + public A addToRequest(java.lang.Integer index, java.lang.Byte item) { + if (this.request == null) { + this.request = new java.util.ArrayList(); + } this.request.add(index, item); - return (A)this; + return (A) this; } - public A setToRequest(java.lang.Integer index,java.lang.Byte item) { - if (this.request == null) {this.request = new java.util.ArrayList();} - this.request.set(index, item); return (A)this; + + public A setToRequest(java.lang.Integer index, java.lang.Byte item) { + if (this.request == null) { + this.request = new java.util.ArrayList(); + } + this.request.set(index, item); + return (A) this; } + public A addToRequest(java.lang.Byte... items) { - if (this.request == null) {this.request = new java.util.ArrayList();} - for (java.lang.Byte item : items) {this.request.add(item);} return (A)this; + if (this.request == null) { + this.request = new java.util.ArrayList(); + } + for (java.lang.Byte item : items) { + this.request.add(item); + } + return (A) this; } + public A addAllToRequest(java.util.Collection items) { - if (this.request == null) {this.request = new java.util.ArrayList();} - for (java.lang.Byte item : items) {this.request.add(item);} return (A)this; + if (this.request == null) { + this.request = new java.util.ArrayList(); + } + for (java.lang.Byte item : items) { + this.request.add(item); + } + return (A) this; } + public A removeFromRequest(java.lang.Byte... items) { - for (java.lang.Byte item : items) {if (this.request!= null){ this.request.remove(item);}} return (A)this; + for (java.lang.Byte item : items) { + if (this.request != null) { + this.request.remove(item); + } + } + return (A) this; } + public A removeAllFromRequest(java.util.Collection items) { - for (java.lang.Byte item : items) {if (this.request!= null){ this.request.remove(item);}} return (A)this; + for (java.lang.Byte item : items) { + if (this.request != null) { + this.request.remove(item); + } + } + return (A) this; } + public java.lang.Boolean hasRequest() { return request != null && !request.isEmpty(); } + public java.lang.String getSignerName() { return this.signerName; } + public A withSignerName(java.lang.String signerName) { - this.signerName=signerName; return (A) this; + this.signerName = signerName; + return (A) this; } + public java.lang.Boolean hasSignerName() { return this.signerName != null; } - - /** - * Method is deprecated. use withSignerName instead. - */ + + /** Method is deprecated. use withSignerName instead. */ @java.lang.Deprecated public A withNewSignerName(java.lang.String original) { - return (A)withSignerName(new String(original)); + return (A) withSignerName(new String(original)); } + public java.lang.String getUid() { return this.uid; } + public A withUid(java.lang.String uid) { - this.uid=uid; return (A) this; + this.uid = uid; + return (A) this; } + public java.lang.Boolean hasUid() { return this.uid != null; } - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original) { - return (A)withUid(new String(original)); + return (A) withUid(new String(original)); } - public A addToUsages(java.lang.Integer index,java.lang.String item) { - if (this.usages == null) {this.usages = new java.util.ArrayList();} + + public A addToUsages(java.lang.Integer index, java.lang.String item) { + if (this.usages == null) { + this.usages = new java.util.ArrayList(); + } this.usages.add(index, item); - return (A)this; + return (A) this; } - public A setToUsages(java.lang.Integer index,java.lang.String item) { - if (this.usages == null) {this.usages = new java.util.ArrayList();} - this.usages.set(index, item); return (A)this; + + public A setToUsages(java.lang.Integer index, java.lang.String item) { + if (this.usages == null) { + this.usages = new java.util.ArrayList(); + } + this.usages.set(index, item); + return (A) this; } + public A addToUsages(java.lang.String... items) { - if (this.usages == null) {this.usages = new java.util.ArrayList();} - for (java.lang.String item : items) {this.usages.add(item);} return (A)this; + if (this.usages == null) { + this.usages = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.usages.add(item); + } + return (A) this; } + public A addAllToUsages(java.util.Collection items) { - if (this.usages == null) {this.usages = new java.util.ArrayList();} - for (java.lang.String item : items) {this.usages.add(item);} return (A)this; + if (this.usages == null) { + this.usages = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.usages.add(item); + } + return (A) this; } + public A removeFromUsages(java.lang.String... items) { - for (java.lang.String item : items) {if (this.usages!= null){ this.usages.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.usages != null) { + this.usages.remove(item); + } + } + return (A) this; } + public A removeAllFromUsages(java.util.Collection items) { - for (java.lang.String item : items) {if (this.usages!= null){ this.usages.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.usages != null) { + this.usages.remove(item); + } + } + return (A) this; } + public java.util.List getUsages() { return this.usages; } + public java.lang.String getUsage(java.lang.Integer index) { return this.usages.get(index); } + public java.lang.String getFirstUsage() { return this.usages.get(0); } + public java.lang.String getLastUsage() { return this.usages.get(usages.size() - 1); } - public java.lang.String getMatchingUsage(java.util.function.Predicate predicate) { - for (java.lang.String item: usages) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingUsage( + java.util.function.Predicate predicate) { + for (java.lang.String item : usages) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingUsage(java.util.function.Predicate predicate) { - for (java.lang.String item: usages) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingUsage( + java.util.function.Predicate predicate) { + for (java.lang.String item : usages) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withUsages(java.util.List usages) { - if (usages != null) {this.usages = new java.util.ArrayList(); for (java.lang.String item : usages){this.addToUsages(item);}} else { this.usages = null;} return (A) this; + if (usages != null) { + this.usages = new java.util.ArrayList(); + for (java.lang.String item : usages) { + this.addToUsages(item); + } + } else { + this.usages = null; + } + return (A) this; } + public A withUsages(java.lang.String... usages) { - if (this.usages != null) {this.usages.clear();} - if (usages != null) {for (java.lang.String item :usages){ this.addToUsages(item);}} return (A) this; + if (this.usages != null) { + this.usages.clear(); + } + if (usages != null) { + for (java.lang.String item : usages) { + this.addToUsages(item); + } + } + return (A) this; } + public java.lang.Boolean hasUsages() { return usages != null && !usages.isEmpty(); } + public A addNewUsage(java.lang.String original) { - return (A)addToUsages(new String(original)); + return (A) addToUsages(new String(original)); } + public java.lang.String getUsername() { return this.username; } + public A withUsername(java.lang.String username) { - this.username=username; return (A) this; + this.username = username; + return (A) this; } + public java.lang.Boolean hasUsername() { return this.username != null; } - - /** - * Method is deprecated. use withUsername instead. - */ + + /** Method is deprecated. use withUsername instead. */ @java.lang.Deprecated public A withNewUsername(java.lang.String original) { - return (A)withUsername(new String(original)); + return (A) withUsername(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CertificateSigningRequestSpecFluentImpl that = (V1CertificateSigningRequestSpecFluentImpl) o; - if (expirationSeconds != null ? !expirationSeconds.equals(that.expirationSeconds) :that.expirationSeconds != null) return false; - if (extra != null ? !extra.equals(that.extra) :that.extra != null) return false; - if (groups != null ? !groups.equals(that.groups) :that.groups != null) return false; - if (request != null ? !request.equals(that.request) :that.request != null) return false; - if (signerName != null ? !signerName.equals(that.signerName) :that.signerName != null) return false; - if (uid != null ? !uid.equals(that.uid) :that.uid != null) return false; - if (usages != null ? !usages.equals(that.usages) :that.usages != null) return false; - if (username != null ? !username.equals(that.username) :that.username != null) return false; + if (expirationSeconds != null + ? !expirationSeconds.equals(that.expirationSeconds) + : that.expirationSeconds != null) return false; + if (extra != null ? !extra.equals(that.extra) : that.extra != null) return false; + if (groups != null ? !groups.equals(that.groups) : that.groups != null) return false; + if (request != null ? !request.equals(that.request) : that.request != null) return false; + if (signerName != null ? !signerName.equals(that.signerName) : that.signerName != null) + return false; + if (uid != null ? !uid.equals(that.uid) : that.uid != null) return false; + if (usages != null ? !usages.equals(that.usages) : that.usages != null) return false; + if (username != null ? !username.equals(that.username) : that.username != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(expirationSeconds, extra, groups, request, signerName, uid, usages, username, super.hashCode()); + return java.util.Objects.hash( + expirationSeconds, + extra, + groups, + request, + signerName, + uid, + usages, + username, + super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestStatusBuilder.java index e5a5e91077..9d6b8010f7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestStatusBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CertificateSigningRequestStatusBuilder extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CertificateSigningRequestStatusBuilder + extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluentImpl< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusBuilder> { public V1CertificateSigningRequestStatusBuilder() { this(false); } + public V1CertificateSigningRequestStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1CertificateSigningRequestStatus(), validationEnabled); } - public V1CertificateSigningRequestStatusBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent fluent) { + + public V1CertificateSigningRequestStatusBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent fluent) { this(fluent, false); } - public V1CertificateSigningRequestStatusBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CertificateSigningRequestStatusBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CertificateSigningRequestStatus(), validationEnabled); } - public V1CertificateSigningRequestStatusBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent fluent,io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus instance) { + + public V1CertificateSigningRequestStatusBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent fluent, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus instance) { this(fluent, instance, false); } - public V1CertificateSigningRequestStatusBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent fluent,io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CertificateSigningRequestStatusBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent fluent, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCertificate(instance.getCertificate()); fluent.withConditions(instance.getConditions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CertificateSigningRequestStatusBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus instance) { - this(instance,false); + + public V1CertificateSigningRequestStatusBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus instance) { + this(instance, false); } - public V1CertificateSigningRequestStatusBuilder(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CertificateSigningRequestStatusBuilder( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCertificate(instance.getCertificate()); this.withConditions(instance.getConditions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus build() { V1CertificateSigningRequestStatus buildable = new V1CertificateSigningRequestStatus(); buildable.setCertificate(fluent.getCertificate()); buildable.setConditions(fluent.getConditions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CertificateSigningRequestStatusBuilder that = (V1CertificateSigningRequestStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestStatusFluent.java index 295eecfaf0..916f69d32d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestStatusFluent.java @@ -1,67 +1,156 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Byte; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CertificateSigningRequestStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CertificateSigningRequestStatusFluent< + A extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public A withCertificate(byte... certificate); + public byte[] getCertificate(); - public A addToCertificate(java.lang.Integer index,java.lang.Byte item); - public A setToCertificate(java.lang.Integer index,java.lang.Byte item); + + public A addToCertificate(java.lang.Integer index, java.lang.Byte item); + + public A setToCertificate(java.lang.Integer index, java.lang.Byte item); + public A addToCertificate(java.lang.Byte... items); + public A addAllToCertificate(java.util.Collection items); + public A removeFromCertificate(java.lang.Byte... items); + public A removeAllFromCertificate(java.util.Collection items); + public java.lang.Boolean hasCertificate(); - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item); - public A addToConditions(io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition... items); - public A addAllToConditions(java.util.Collection items); - public A removeFromConditions(io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item); + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item); + + public A addToConditions( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition... items); + + public A addAllToConditions( + java.util.Collection + items); + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition... items); + + public A removeAllFromConditions( + java.util.Collection + items); + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder> + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition buildCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition buildFirstCondition(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); - public A withConditions(io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition... conditions); + public java.util.List + getConditions(); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition buildCondition( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition + buildFirstCondition(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition + buildLastCondition(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder> + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder> + predicate); + + public A withConditions( + java.util.List + conditions); + + public A withConditions( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent>{ + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder> + predicate); + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluent< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestStatusFluentImpl.java index 462a138532..e9a445ee9a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CertificateSigningRequestStatusFluentImpl.java @@ -1,212 +1,458 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Byte; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1CertificateSigningRequestStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent{ - public V1CertificateSigningRequestStatusFluentImpl() { - } - public V1CertificateSigningRequestStatusFluentImpl(io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus instance) { +/** Generated */ +public class V1CertificateSigningRequestStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent { + public V1CertificateSigningRequestStatusFluentImpl() {} + + public V1CertificateSigningRequestStatusFluentImpl( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatus instance) { this.withCertificate(instance.getCertificate()); this.withConditions(instance.getConditions()); - } + private java.util.List certificate; - private java.util.ArrayList conditions; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder> + conditions; + public A withCertificate(byte... certificate) { - if (this.certificate != null) {this.certificate.clear();} - if (certificate != null) {for (byte item :certificate){ this.addToCertificate(item);}} return (A) this; + if (this.certificate != null) { + this.certificate.clear(); + } + if (certificate != null) { + for (byte item : certificate) { + this.addToCertificate(item); + } + } + return (A) this; } - public byte[] getCertificate() { - //This needs to work with primitives, so we use arrays. -int size = certificate != null ? certificate.size() : 0; -byte[] result = new byte[size]; -if (size == 0) { - return result; -} -int index = 0; -for (byte item : certificate) { - result[index++]=item; -} -return result; + public byte[] getCertificate() { + // This needs to work with primitives, so we use arrays. + int size = certificate != null ? certificate.size() : 0; + byte[] result = new byte[size]; + if (size == 0) { + return result; + } + int index = 0; + for (byte item : certificate) { + result[index++] = item; + } + return result; } - public A addToCertificate(java.lang.Integer index,java.lang.Byte item) { - if (this.certificate == null) {this.certificate = new java.util.ArrayList();} + + public A addToCertificate(java.lang.Integer index, java.lang.Byte item) { + if (this.certificate == null) { + this.certificate = new java.util.ArrayList(); + } this.certificate.add(index, item); - return (A)this; + return (A) this; } - public A setToCertificate(java.lang.Integer index,java.lang.Byte item) { - if (this.certificate == null) {this.certificate = new java.util.ArrayList();} - this.certificate.set(index, item); return (A)this; + + public A setToCertificate(java.lang.Integer index, java.lang.Byte item) { + if (this.certificate == null) { + this.certificate = new java.util.ArrayList(); + } + this.certificate.set(index, item); + return (A) this; } + public A addToCertificate(java.lang.Byte... items) { - if (this.certificate == null) {this.certificate = new java.util.ArrayList();} - for (java.lang.Byte item : items) {this.certificate.add(item);} return (A)this; + if (this.certificate == null) { + this.certificate = new java.util.ArrayList(); + } + for (java.lang.Byte item : items) { + this.certificate.add(item); + } + return (A) this; } + public A addAllToCertificate(java.util.Collection items) { - if (this.certificate == null) {this.certificate = new java.util.ArrayList();} - for (java.lang.Byte item : items) {this.certificate.add(item);} return (A)this; + if (this.certificate == null) { + this.certificate = new java.util.ArrayList(); + } + for (java.lang.Byte item : items) { + this.certificate.add(item); + } + return (A) this; } + public A removeFromCertificate(java.lang.Byte... items) { - for (java.lang.Byte item : items) {if (this.certificate!= null){ this.certificate.remove(item);}} return (A)this; + for (java.lang.Byte item : items) { + if (this.certificate != null) { + this.certificate.remove(item); + } + } + return (A) this; } + public A removeAllFromCertificate(java.util.Collection items) { - for (java.lang.Byte item : items) {if (this.certificate!= null){ this.certificate.remove(item);}} return (A)this; + for (java.lang.Byte item : items) { + if (this.certificate != null) { + this.certificate.remove(item); + } + } + return (A) this; } + public java.lang.Boolean hasCertificate() { return certificate != null && !certificate.isEmpty(); } - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } - public A addToConditions(io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item : items) {io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addToConditions( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition... items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item : items) { + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item : items) {io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection + items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item : items) { + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition... items) { - for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item : items) {io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition... items) { + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item : items) { + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item : items) {io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item : items) { + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder> + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator + each = conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions() { + public java.util.List + getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition buildFirstCondition() { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition + buildFirstCondition() { return this.conditions.get(0).build(); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition buildLastCondition() { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition + buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List + conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item : + conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } - public A withConditions(io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item :conditions){ this.addToConditions(item);}} return (A) this; + + public A withConditions( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition... conditions) { + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item : + conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item) { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item) { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item) { - return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item) { + return new io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionFluentImpl< + io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + N>> + implements io.kubernetes.client.openapi.models.V1CertificateSigningRequestStatusFluent + .ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CertificateSigningRequestCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder( + this, item); } + ConditionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1CertificateSigningRequestConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1CertificateSigningRequestStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) + V1CertificateSigningRequestStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderPersistentVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderPersistentVolumeSourceBuilder.java index c63ff487eb..bb82b9fe93 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderPersistentVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderPersistentVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CinderPersistentVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CinderPersistentVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource, + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceBuilder> { public V1CinderPersistentVolumeSourceBuilder() { this(false); } + public V1CinderPersistentVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1CinderPersistentVolumeSource(), validationEnabled); } - public V1CinderPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent fluent) { + + public V1CinderPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent fluent) { this(fluent, false); } - public V1CinderPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CinderPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CinderPersistentVolumeSource(), validationEnabled); } - public V1CinderPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource instance) { + + public V1CinderPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource instance) { this(fluent, instance, false); } - public V1CinderPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CinderPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withReadOnly(instance.getReadOnly()); @@ -29,13 +56,18 @@ public V1CinderPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models fluent.withVolumeID(instance.getVolumeID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CinderPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource instance) { - this(instance,false); + + public V1CinderPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource instance) { + this(instance, false); } - public V1CinderPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CinderPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withReadOnly(instance.getReadOnly()); @@ -44,10 +76,12 @@ public V1CinderPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models this.withVolumeID(instance.getVolumeID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource build() { V1CinderPersistentVolumeSource buildable = new V1CinderPersistentVolumeSource(); buildable.setFsType(fluent.getFsType()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource build( buildable.setVolumeID(fluent.getVolumeID()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CinderPersistentVolumeSourceBuilder that = (V1CinderPersistentVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderPersistentVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderPersistentVolumeSourceFluent.java index f06d744b52..53efdfb1ea 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderPersistentVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderPersistentVolumeSourceFluent.java @@ -1,56 +1,84 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CinderPersistentVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CinderPersistentVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1SecretReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); - public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + public java.lang.String getVolumeID(); + public A withVolumeID(java.lang.String volumeID); + public java.lang.Boolean hasVolumeID(); - - /** - * Method is deprecated. use withVolumeID instead. - */ + + /** Method is deprecated. use withVolumeID instead. */ @java.lang.Deprecated public A withNewVolumeID(java.lang.String original); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretReferenceFluent>{ + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretReferenceFluent< + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent + .SecretRefNested< + N>> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderPersistentVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderPersistentVolumeSourceFluentImpl.java index 0467430696..f94ba327d6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderPersistentVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderPersistentVolumeSourceFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1CinderPersistentVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent { + public V1CinderPersistentVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1CinderPersistentVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent{ - public V1CinderPersistentVolumeSourceFluentImpl() { - } - public V1CinderPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource instance) { + public V1CinderPersistentVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource instance) { this.withFsType(instance.getFsType()); this.withReadOnly(instance.getReadOnly()); @@ -21,117 +28,161 @@ public V1CinderPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.mod this.withSecretRef(instance.getSecretRef()); this.withVolumeID(instance.getVolumeID()); - } + private java.lang.String fsType; private java.lang.Boolean readOnly; private io.kubernetes.client.openapi.models.V1SecretReferenceBuilder secretRef; private java.lang.String volumeID; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return new io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return new io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public java.lang.String getVolumeID() { return this.volumeID; } + public A withVolumeID(java.lang.String volumeID) { - this.volumeID=volumeID; return (A) this; + this.volumeID = volumeID; + return (A) this; } + public java.lang.Boolean hasVolumeID() { return this.volumeID != null; } - - /** - * Method is deprecated. use withVolumeID instead. - */ + + /** Method is deprecated. use withVolumeID instead. */ @java.lang.Deprecated public A withNewVolumeID(java.lang.String original) { - return (A)withVolumeID(new String(original)); + return (A) withVolumeID(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CinderPersistentVolumeSourceFluentImpl that = (V1CinderPersistentVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; - if (volumeID != null ? !volumeID.equals(that.volumeID) :that.volumeID != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; + if (volumeID != null ? !volumeID.equals(that.volumeID) : that.volumeID != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, readOnly, secretRef, volumeID, super.hashCode()); + return java.util.Objects.hash(fsType, readOnly, secretRef, volumeID, super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent.SecretRefNested< + N>> + implements io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent + .SecretRefNested< + N>, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1SecretReference item) { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretReferenceBuilder builder; + public N and() { return (N) V1CinderPersistentVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderVolumeSourceBuilder.java index 2ce518bbc6..50f560c7a5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CinderVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CinderVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1CinderVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CinderVolumeSource, + io.kubernetes.client.openapi.models.V1CinderVolumeSourceBuilder> { public V1CinderVolumeSourceBuilder() { this(false); } + public V1CinderVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1CinderVolumeSource(), validationEnabled); } - public V1CinderVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent fluent) { + + public V1CinderVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent fluent) { this(fluent, false); } - public V1CinderVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CinderVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CinderVolumeSource(), validationEnabled); } - public V1CinderVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1CinderVolumeSource instance) { + + public V1CinderVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1CinderVolumeSource instance) { this(fluent, instance, false); } - public V1CinderVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1CinderVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CinderVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1CinderVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withReadOnly(instance.getReadOnly()); @@ -29,13 +56,18 @@ public V1CinderVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderV fluent.withVolumeID(instance.getVolumeID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CinderVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderVolumeSource instance) { - this(instance,false); + + public V1CinderVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CinderVolumeSource instance) { + this(instance, false); } - public V1CinderVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CinderVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1CinderVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withReadOnly(instance.getReadOnly()); @@ -44,10 +76,12 @@ public V1CinderVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1CinderV this.withVolumeID(instance.getVolumeID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CinderVolumeSource build() { V1CinderVolumeSource buildable = new V1CinderVolumeSource(); buildable.setFsType(fluent.getFsType()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1CinderVolumeSource build() { buildable.setVolumeID(fluent.getVolumeID()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CinderVolumeSourceBuilder that = (V1CinderVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderVolumeSourceFluent.java index 6349f813cc..31a5f3de0c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderVolumeSourceFluent.java @@ -1,56 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CinderVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CinderVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + public java.lang.String getVolumeID(); + public A withVolumeID(java.lang.String volumeID); + public java.lang.Boolean hasVolumeID(); - - /** - * Method is deprecated. use withVolumeID instead. - */ + + /** Method is deprecated. use withVolumeID instead. */ @java.lang.Deprecated public A withNewVolumeID(java.lang.String original); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent>{ + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderVolumeSourceFluentImpl.java index 98cdd0d65a..7cbb34f460 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CinderVolumeSourceFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1CinderVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent { + public V1CinderVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1CinderVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent{ - public V1CinderVolumeSourceFluentImpl() { - } - public V1CinderVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1CinderVolumeSource instance) { + public V1CinderVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1CinderVolumeSource instance) { this.withFsType(instance.getFsType()); this.withReadOnly(instance.getReadOnly()); @@ -21,117 +28,160 @@ public V1CinderVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1Cind this.withSecretRef(instance.getSecretRef()); this.withVolumeID(instance.getVolumeID()); - } + private java.lang.String fsType; private java.lang.Boolean readOnly; private io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder secretRef; private java.lang.String volumeID; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluentImpl + .SecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public java.lang.String getVolumeID() { return this.volumeID; } + public A withVolumeID(java.lang.String volumeID) { - this.volumeID=volumeID; return (A) this; + this.volumeID = volumeID; + return (A) this; } + public java.lang.Boolean hasVolumeID() { return this.volumeID != null; } - - /** - * Method is deprecated. use withVolumeID instead. - */ + + /** Method is deprecated. use withVolumeID instead. */ @java.lang.Deprecated public A withNewVolumeID(java.lang.String original) { - return (A)withVolumeID(new String(original)); + return (A) withVolumeID(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CinderVolumeSourceFluentImpl that = (V1CinderVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; - if (volumeID != null ? !volumeID.equals(that.volumeID) :that.volumeID != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; + if (volumeID != null ? !volumeID.equals(that.volumeID) : that.volumeID != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, readOnly, secretRef, volumeID, super.hashCode()); + return java.util.Objects.hash(fsType, readOnly, secretRef, volumeID, super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested> + implements io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent.SecretRefNested, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder; + public N and() { return (N) V1CinderVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClientIPConfigBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClientIPConfigBuilder.java index 7ca03ae6b3..80bea0c8c0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClientIPConfigBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClientIPConfigBuilder.java @@ -1,58 +1,96 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ClientIPConfigBuilder extends io.kubernetes.client.openapi.models.V1ClientIPConfigFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ClientIPConfigBuilder + extends io.kubernetes.client.openapi.models.V1ClientIPConfigFluentImpl< + io.kubernetes.client.openapi.models.V1ClientIPConfigBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ClientIPConfig, + io.kubernetes.client.openapi.models.V1ClientIPConfigBuilder> { public V1ClientIPConfigBuilder() { this(false); } + public V1ClientIPConfigBuilder(java.lang.Boolean validationEnabled) { this(new V1ClientIPConfig(), validationEnabled); } - public V1ClientIPConfigBuilder(io.kubernetes.client.openapi.models.V1ClientIPConfigFluent fluent) { + + public V1ClientIPConfigBuilder( + io.kubernetes.client.openapi.models.V1ClientIPConfigFluent fluent) { this(fluent, false); } - public V1ClientIPConfigBuilder(io.kubernetes.client.openapi.models.V1ClientIPConfigFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ClientIPConfigBuilder( + io.kubernetes.client.openapi.models.V1ClientIPConfigFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ClientIPConfig(), validationEnabled); } - public V1ClientIPConfigBuilder(io.kubernetes.client.openapi.models.V1ClientIPConfigFluent fluent,io.kubernetes.client.openapi.models.V1ClientIPConfig instance) { + + public V1ClientIPConfigBuilder( + io.kubernetes.client.openapi.models.V1ClientIPConfigFluent fluent, + io.kubernetes.client.openapi.models.V1ClientIPConfig instance) { this(fluent, instance, false); } - public V1ClientIPConfigBuilder(io.kubernetes.client.openapi.models.V1ClientIPConfigFluent fluent,io.kubernetes.client.openapi.models.V1ClientIPConfig instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ClientIPConfigBuilder( + io.kubernetes.client.openapi.models.V1ClientIPConfigFluent fluent, + io.kubernetes.client.openapi.models.V1ClientIPConfig instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withTimeoutSeconds(instance.getTimeoutSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ClientIPConfigBuilder(io.kubernetes.client.openapi.models.V1ClientIPConfig instance) { - this(instance,false); + this(instance, false); } - public V1ClientIPConfigBuilder(io.kubernetes.client.openapi.models.V1ClientIPConfig instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ClientIPConfigBuilder( + io.kubernetes.client.openapi.models.V1ClientIPConfig instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withTimeoutSeconds(instance.getTimeoutSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ClientIPConfigFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ClientIPConfig build() { V1ClientIPConfig buildable = new V1ClientIPConfig(); buildable.setTimeoutSeconds(fluent.getTimeoutSeconds()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ClientIPConfigBuilder that = (V1ClientIPConfigBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClientIPConfigFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClientIPConfigFluent.java index 927e8118b8..0d14122b87 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClientIPConfigFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClientIPConfigFluent.java @@ -1,17 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ClientIPConfigFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ClientIPConfigFluent< + A extends io.kubernetes.client.openapi.models.V1ClientIPConfigFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getTimeoutSeconds(); + public A withTimeoutSeconds(java.lang.Integer timeoutSeconds); + public java.lang.Boolean hasTimeoutSeconds(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClientIPConfigFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClientIPConfigFluentImpl.java index 3208d024d8..7c2c0d5b53 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClientIPConfigFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClientIPConfigFluentImpl.java @@ -1,39 +1,54 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1ClientIPConfigFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ClientIPConfigFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ClientIPConfigFluent { + public V1ClientIPConfigFluentImpl() {} - /** - * Generated - */ -public class V1ClientIPConfigFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ClientIPConfigFluent{ - public V1ClientIPConfigFluentImpl() { - } public V1ClientIPConfigFluentImpl(io.kubernetes.client.openapi.models.V1ClientIPConfig instance) { this.withTimeoutSeconds(instance.getTimeoutSeconds()); - } + private java.lang.Integer timeoutSeconds; + public java.lang.Integer getTimeoutSeconds() { return this.timeoutSeconds; } + public A withTimeoutSeconds(java.lang.Integer timeoutSeconds) { - this.timeoutSeconds=timeoutSeconds; return (A) this; + this.timeoutSeconds = timeoutSeconds; + return (A) this; } + public java.lang.Boolean hasTimeoutSeconds() { return this.timeoutSeconds != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ClientIPConfigFluentImpl that = (V1ClientIPConfigFluentImpl) o; - if (timeoutSeconds != null ? !timeoutSeconds.equals(that.timeoutSeconds) :that.timeoutSeconds != null) return false; + if (timeoutSeconds != null + ? !timeoutSeconds.equals(that.timeoutSeconds) + : that.timeoutSeconds != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(timeoutSeconds, super.hashCode()); + return java.util.Objects.hash(timeoutSeconds, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingBuilder.java index 49c1fb7e83..3ecdf411d3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ClusterRoleBindingBuilder extends io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ClusterRoleBindingBuilder + extends io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ClusterRoleBinding, + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder> { public V1ClusterRoleBindingBuilder() { this(false); } + public V1ClusterRoleBindingBuilder(java.lang.Boolean validationEnabled) { this(new V1ClusterRoleBinding(), validationEnabled); } - public V1ClusterRoleBindingBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent fluent) { + + public V1ClusterRoleBindingBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent fluent) { this(fluent, false); } - public V1ClusterRoleBindingBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ClusterRoleBindingBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ClusterRoleBinding(), validationEnabled); } - public V1ClusterRoleBindingBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent fluent,io.kubernetes.client.openapi.models.V1ClusterRoleBinding instance) { + + public V1ClusterRoleBindingBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent fluent, + io.kubernetes.client.openapi.models.V1ClusterRoleBinding instance) { this(fluent, instance, false); } - public V1ClusterRoleBindingBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent fluent,io.kubernetes.client.openapi.models.V1ClusterRoleBinding instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ClusterRoleBindingBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent fluent, + io.kubernetes.client.openapi.models.V1ClusterRoleBinding instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1ClusterRoleBindingBuilder(io.kubernetes.client.openapi.models.V1Cluster fluent.withSubjects(instance.getSubjects()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ClusterRoleBindingBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleBinding instance) { - this(instance,false); + + public V1ClusterRoleBindingBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleBinding instance) { + this(instance, false); } - public V1ClusterRoleBindingBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleBinding instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ClusterRoleBindingBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleBinding instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1ClusterRoleBindingBuilder(io.kubernetes.client.openapi.models.V1Cluster this.withSubjects(instance.getSubjects()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ClusterRoleBinding build() { V1ClusterRoleBinding buildable = new V1ClusterRoleBinding(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1ClusterRoleBinding build() { buildable.setSubjects(fluent.getSubjects()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ClusterRoleBindingBuilder that = (V1ClusterRoleBindingBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingFluent.java index 88d26bdf97..e542513da7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingFluent.java @@ -1,115 +1,194 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1ClusterRoleBindingFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ClusterRoleBindingFluent< + A extends io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildRoleRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RoleRef getRoleRef(); + public io.kubernetes.client.openapi.models.V1RoleRef buildRoleRef(); + public A withRoleRef(io.kubernetes.client.openapi.models.V1RoleRef roleRef); + public java.lang.Boolean hasRoleRef(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested withNewRoleRef(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested withNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested editRoleRef(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested editOrNewRoleRef(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested editOrNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item); - public A addToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item); - public A setToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested + withNewRoleRef(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested + withNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested + editRoleRef(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested + editOrNewRoleRef(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested + editOrNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item); + + public A addToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item); + + public A setToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item); + public A addToSubjects(io.kubernetes.client.openapi.models.V1Subject... items); - public A addAllToSubjects(java.util.Collection items); + + public A addAllToSubjects( + java.util.Collection items); + public A removeFromSubjects(io.kubernetes.client.openapi.models.V1Subject... items); - public A removeAllFromSubjects(java.util.Collection items); - public A removeMatchingFromSubjects(java.util.function.Predicate predicate); - + + public A removeAllFromSubjects( + java.util.Collection items); + + public A removeMatchingFromSubjects( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildSubjects instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getSubjects(); + public java.util.List buildSubjects(); + public io.kubernetes.client.openapi.models.V1Subject buildSubject(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Subject buildFirstSubject(); + public io.kubernetes.client.openapi.models.V1Subject buildLastSubject(); - public io.kubernetes.client.openapi.models.V1Subject buildMatchingSubject(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingSubject(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Subject buildMatchingSubject( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingSubject( + java.util.function.Predicate predicate); + public A withSubjects(java.util.List subjects); + public A withSubjects(io.kubernetes.client.openapi.models.V1Subject... subjects); + public java.lang.Boolean hasSubjects(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested addNewSubject(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested addNewSubjectLike(io.kubernetes.client.openapi.models.V1Subject item); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested setNewSubjectLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested editSubject(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested editFirstSubject(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested editLastSubject(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested editMatchingSubject(java.util.function.Predicate predicate); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + addNewSubject(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + addNewSubjectLike(io.kubernetes.client.openapi.models.V1Subject item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + setNewSubjectLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + editSubject(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + editFirstSubject(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + editLastSubject(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + editMatchingSubject( + java.util.function.Predicate + predicate); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface RoleRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1RoleRefFluent>{ + + public interface RoleRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1RoleRefFluent< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested> { public N and(); + public N endRoleRef(); - } - public interface SubjectsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SubjectFluent>{ + + public interface SubjectsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SubjectFluent< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested> { public N and(); + public N endSubject(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingFluentImpl.java index eee76e5520..501fe71b1b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1ClusterRoleBindingFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent{ - public V1ClusterRoleBindingFluentImpl() { - } - public V1ClusterRoleBindingFluentImpl(io.kubernetes.client.openapi.models.V1ClusterRoleBinding instance) { + +/** Generated */ +public class V1ClusterRoleBindingFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent { + public V1ClusterRoleBindingFluentImpl() {} + + public V1ClusterRoleBindingFluentImpl( + io.kubernetes.client.openapi.models.V1ClusterRoleBinding instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -30,141 +33,259 @@ public V1ClusterRoleBindingFluentImpl(io.kubernetes.client.openapi.models.V1Clus this.withRoleRef(instance.getRoleRef()); this.withSubjects(instance.getSubjects()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1RoleRefBuilder roleRef; private java.util.ArrayList subjects; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildRoleRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RoleRef getRoleRef() { - return this.roleRef!=null ?this.roleRef.build():null; + return this.roleRef != null ? this.roleRef.build() : null; } + public io.kubernetes.client.openapi.models.V1RoleRef buildRoleRef() { - return this.roleRef!=null ?this.roleRef.build():null; + return this.roleRef != null ? this.roleRef.build() : null; } + public A withRoleRef(io.kubernetes.client.openapi.models.V1RoleRef roleRef) { _visitables.get("roleRef").remove(this.roleRef); - if (roleRef!=null){ this.roleRef= new io.kubernetes.client.openapi.models.V1RoleRefBuilder(roleRef); _visitables.get("roleRef").add(this.roleRef);} return (A) this; + if (roleRef != null) { + this.roleRef = new io.kubernetes.client.openapi.models.V1RoleRefBuilder(roleRef); + _visitables.get("roleRef").add(this.roleRef); + } + return (A) this; } + public java.lang.Boolean hasRoleRef() { return this.roleRef != null; } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested withNewRoleRef() { - return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl.RoleRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested + withNewRoleRef() { + return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl + .RoleRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested withNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item) { - return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl.RoleRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested + withNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item) { + return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl.RoleRefNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested editRoleRef() { + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested + editRoleRef() { return withNewRoleRefLike(getRoleRef()); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested editOrNewRoleRef() { - return withNewRoleRefLike(getRoleRef() != null ? getRoleRef(): new io.kubernetes.client.openapi.models.V1RoleRefBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested + editOrNewRoleRef() { + return withNewRoleRefLike( + getRoleRef() != null + ? getRoleRef() + : new io.kubernetes.client.openapi.models.V1RoleRefBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested editOrNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item) { - return withNewRoleRefLike(getRoleRef() != null ? getRoleRef(): item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested + editOrNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item) { + return withNewRoleRefLike(getRoleRef() != null ? getRoleRef() : item); } - public A addToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(item);_visitables.get("subjects").add(index >= 0 ? index : _visitables.get("subjects").size(), builder);this.subjects.add(index >= 0 ? index : subjects.size(), builder); return (A)this; + + public A addToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item) { + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); + _visitables + .get("subjects") + .add(index >= 0 ? index : _visitables.get("subjects").size(), builder); + this.subjects.add(index >= 0 ? index : subjects.size(), builder); + return (A) this; } - public A setToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); - if (index < 0 || index >= _visitables.get("subjects").size()) { _visitables.get("subjects").add(builder); } else { _visitables.get("subjects").set(index, builder);} - if (index < 0 || index >= subjects.size()) { subjects.add(builder); } else { subjects.set(index, builder);} - return (A)this; + + public A setToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item) { + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); + if (index < 0 || index >= _visitables.get("subjects").size()) { + _visitables.get("subjects").add(builder); + } else { + _visitables.get("subjects").set(index, builder); + } + if (index < 0 || index >= subjects.size()) { + subjects.add(builder); + } else { + subjects.set(index, builder); + } + return (A) this; } + public A addToSubjects(io.kubernetes.client.openapi.models.V1Subject... items) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Subject item : items) {io.kubernetes.client.openapi.models.V1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(item);_visitables.get("subjects").add(builder);this.subjects.add(builder);} return (A)this; + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Subject item : items) { + io.kubernetes.client.openapi.models.V1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); + _visitables.get("subjects").add(builder); + this.subjects.add(builder); + } + return (A) this; } - public A addAllToSubjects(java.util.Collection items) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Subject item : items) {io.kubernetes.client.openapi.models.V1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(item);_visitables.get("subjects").add(builder);this.subjects.add(builder);} return (A)this; + + public A addAllToSubjects( + java.util.Collection items) { + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Subject item : items) { + io.kubernetes.client.openapi.models.V1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); + _visitables.get("subjects").add(builder); + this.subjects.add(builder); + } + return (A) this; } + public A removeFromSubjects(io.kubernetes.client.openapi.models.V1Subject... items) { - for (io.kubernetes.client.openapi.models.V1Subject item : items) {io.kubernetes.client.openapi.models.V1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(item);_visitables.get("subjects").remove(builder);if (this.subjects != null) {this.subjects.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Subject item : items) { + io.kubernetes.client.openapi.models.V1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); + _visitables.get("subjects").remove(builder); + if (this.subjects != null) { + this.subjects.remove(builder); + } + } + return (A) this; } - public A removeAllFromSubjects(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Subject item : items) {io.kubernetes.client.openapi.models.V1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(item);_visitables.get("subjects").remove(builder);if (this.subjects != null) {this.subjects.remove(builder);}} return (A)this; + + public A removeAllFromSubjects( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Subject item : items) { + io.kubernetes.client.openapi.models.V1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); + _visitables.get("subjects").remove(builder); + if (this.subjects != null) { + this.subjects.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromSubjects(java.util.function.Predicate predicate) { + + public A removeMatchingFromSubjects( + java.util.function.Predicate + predicate) { if (subjects == null) return (A) this; final Iterator each = subjects.iterator(); final List visitables = _visitables.get("subjects"); @@ -175,140 +296,233 @@ public A removeMatchingFromSubjects(java.util.function.Predicate getSubjects() { return subjects != null ? build(subjects) : null; } + public java.util.List buildSubjects() { return subjects != null ? build(subjects) : null; } + public io.kubernetes.client.openapi.models.V1Subject buildSubject(java.lang.Integer index) { return this.subjects.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Subject buildFirstSubject() { return this.subjects.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Subject buildLastSubject() { return this.subjects.get(subjects.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Subject buildMatchingSubject(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1SubjectBuilder item: subjects) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Subject buildMatchingSubject( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1SubjectBuilder item : subjects) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingSubject(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1SubjectBuilder item: subjects) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingSubject( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1SubjectBuilder item : subjects) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withSubjects(java.util.List subjects) { - if (this.subjects != null) { _visitables.get("subjects").removeAll(this.subjects);} - if (subjects != null) {this.subjects = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Subject item : subjects){this.addToSubjects(item);}} else { this.subjects = null;} return (A) this; + if (this.subjects != null) { + _visitables.get("subjects").removeAll(this.subjects); + } + if (subjects != null) { + this.subjects = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Subject item : subjects) { + this.addToSubjects(item); + } + } else { + this.subjects = null; + } + return (A) this; } + public A withSubjects(io.kubernetes.client.openapi.models.V1Subject... subjects) { - if (this.subjects != null) {this.subjects.clear();} - if (subjects != null) {for (io.kubernetes.client.openapi.models.V1Subject item :subjects){ this.addToSubjects(item);}} return (A) this; + if (this.subjects != null) { + this.subjects.clear(); + } + if (subjects != null) { + for (io.kubernetes.client.openapi.models.V1Subject item : subjects) { + this.addToSubjects(item); + } + } + return (A) this; } + public java.lang.Boolean hasSubjects() { return subjects != null && !subjects.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested addNewSubject() { - return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl.SubjectsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + addNewSubject() { + return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl + .SubjectsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested addNewSubjectLike(io.kubernetes.client.openapi.models.V1Subject item) { - return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl.SubjectsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + addNewSubjectLike(io.kubernetes.client.openapi.models.V1Subject item) { + return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl + .SubjectsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested setNewSubjectLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item) { - return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl.SubjectsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + setNewSubjectLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item) { + return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl + .SubjectsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested editSubject(java.lang.Integer index) { - if (subjects.size() <= index) throw new RuntimeException("Can't edit subjects. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + editSubject(java.lang.Integer index) { + if (subjects.size() <= index) + throw new RuntimeException("Can't edit subjects. Index exceeds size."); return setNewSubjectLike(index, buildSubject(index)); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested editFirstSubject() { - if (subjects.size() == 0) throw new RuntimeException("Can't edit first subjects. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + editFirstSubject() { + if (subjects.size() == 0) + throw new RuntimeException("Can't edit first subjects. The list is empty."); return setNewSubjectLike(0, buildSubject(0)); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested editLastSubject() { + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + editLastSubject() { int index = subjects.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last subjects. The list is empty."); return setNewSubjectLike(index, buildSubject(index)); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested editMatchingSubject(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested + editMatchingSubject( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1ClusterRoleBindingFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class RoleRefNestedImpl extends io.kubernetes.client.openapi.models.V1RoleRefFluentImpl> implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested,io.kubernetes.client.fluent.Nested{ + + public class RoleRefNestedImpl + extends io.kubernetes.client.openapi.models.V1RoleRefFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested> + implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.RoleRefNested, + io.kubernetes.client.fluent.Nested { RoleRefNestedImpl(io.kubernetes.client.openapi.models.V1RoleRef item) { this.builder = new io.kubernetes.client.openapi.models.V1RoleRefBuilder(this, item); } + RoleRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1RoleRefBuilder(this); } + io.kubernetes.client.openapi.models.V1RoleRefBuilder builder; + public N and() { return (N) V1ClusterRoleBindingFluentImpl.this.withRoleRef(builder.build()); } + public N endRoleRef() { return and(); } - } - public class SubjectsNestedImpl extends io.kubernetes.client.openapi.models.V1SubjectFluentImpl> implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested,io.kubernetes.client.fluent.Nested{ - SubjectsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item) { + + public class SubjectsNestedImpl + extends io.kubernetes.client.openapi.models.V1SubjectFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested> + implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent.SubjectsNested, + io.kubernetes.client.fluent.Nested { + SubjectsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(this, item); } + SubjectsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(this); } + io.kubernetes.client.openapi.models.V1SubjectBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ClusterRoleBindingFluentImpl.this.setToSubjects(index,builder.build()); + return (N) V1ClusterRoleBindingFluentImpl.this.setToSubjects(index, builder.build()); } + public N endSubject() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingListBuilder.java index 5ac72fac5c..78acd01c73 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ClusterRoleBindingListBuilder extends io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ClusterRoleBindingListBuilder + extends io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingList, + io.kubernetes.client.openapi.models.V1ClusterRoleBindingListBuilder> { public V1ClusterRoleBindingListBuilder() { this(false); } + public V1ClusterRoleBindingListBuilder(java.lang.Boolean validationEnabled) { this(new V1ClusterRoleBindingList(), validationEnabled); } - public V1ClusterRoleBindingListBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent fluent) { + + public V1ClusterRoleBindingListBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent fluent) { this(fluent, false); } - public V1ClusterRoleBindingListBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ClusterRoleBindingListBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ClusterRoleBindingList(), validationEnabled); } - public V1ClusterRoleBindingListBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent fluent,io.kubernetes.client.openapi.models.V1ClusterRoleBindingList instance) { + + public V1ClusterRoleBindingListBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent fluent, + io.kubernetes.client.openapi.models.V1ClusterRoleBindingList instance) { this(fluent, instance, false); } - public V1ClusterRoleBindingListBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent fluent,io.kubernetes.client.openapi.models.V1ClusterRoleBindingList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ClusterRoleBindingListBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent fluent, + io.kubernetes.client.openapi.models.V1ClusterRoleBindingList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1ClusterRoleBindingListBuilder(io.kubernetes.client.openapi.models.V1Clu fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ClusterRoleBindingListBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleBindingList instance) { - this(instance,false); + + public V1ClusterRoleBindingListBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleBindingList instance) { + this(instance, false); } - public V1ClusterRoleBindingListBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleBindingList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ClusterRoleBindingListBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleBindingList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1ClusterRoleBindingListBuilder(io.kubernetes.client.openapi.models.V1Clu this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingList build() { V1ClusterRoleBindingList buildable = new V1ClusterRoleBindingList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1ClusterRoleBindingList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ClusterRoleBindingListBuilder that = (V1ClusterRoleBindingListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingListFluent.java index a08c719c8c..889a02d693 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingListFluent.java @@ -1,95 +1,163 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ClusterRoleBindingListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ClusterRoleBindingListFluent< + A extends io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRoleBinding item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRoleBinding item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRoleBinding item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRoleBinding item); + public A addToItems(io.kubernetes.client.openapi.models.V1ClusterRoleBinding... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1ClusterRoleBinding... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBinding buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBinding buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ClusterRoleBinding buildFirstItem(); + public io.kubernetes.client.openapi.models.V1ClusterRoleBinding buildLastItem(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBinding buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBinding buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1ClusterRoleBinding... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ClusterRoleBinding item); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRoleBinding item); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1ClusterRoleBinding item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRoleBinding item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent>{ + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluent< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingListFluentImpl.java index b05aa958c1..578fdf046e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBindingListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1ClusterRoleBindingListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent{ - public V1ClusterRoleBindingListFluentImpl() { - } - public V1ClusterRoleBindingListFluentImpl(io.kubernetes.client.openapi.models.V1ClusterRoleBindingList instance) { + +/** Generated */ +public class V1ClusterRoleBindingListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent { + public V1ClusterRoleBindingListFluentImpl() {} + + public V1ClusterRoleBindingListFluentImpl( + io.kubernetes.client.openapi.models.V1ClusterRoleBindingList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,131 @@ public V1ClusterRoleBindingListFluentImpl(io.kubernetes.client.openapi.models.V1 this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRoleBinding item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRoleBinding item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder>(); + } + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder = + new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRoleBinding item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRoleBinding item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder>(); + } + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder = + new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1ClusterRoleBinding... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ClusterRoleBinding item : items) {io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ClusterRoleBinding item : items) { + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder = + new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ClusterRoleBinding item : items) {io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ClusterRoleBinding item : items) { + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder = + new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1ClusterRoleBinding... items) { - for (io.kubernetes.client.openapi.models.V1ClusterRoleBinding item : items) {io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ClusterRoleBinding item : items) { + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder = + new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ClusterRoleBinding item : items) {io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ClusterRoleBinding item : items) { + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder = + new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder = each.next(); @@ -87,174 +164,287 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1ClusterRoleBinding buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ClusterRoleBinding buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ClusterRoleBinding buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ClusterRoleBinding buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBinding buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ClusterRoleBinding buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ClusterRoleBinding item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ClusterRoleBinding item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1ClusterRoleBinding... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1ClusterRoleBinding item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1ClusterRoleBinding item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ClusterRoleBinding item) { - return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1ClusterRoleBinding item) { + return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRoleBinding item) { - return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRoleBinding item) { + return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ClusterRoleBindingListFluentImpl that = (V1ClusterRoleBindingListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl> implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRoleBinding item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1ClusterRoleBindingFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRoleBinding item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder(this); } + io.kubernetes.client.openapi.models.V1ClusterRoleBindingBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ClusterRoleBindingListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1ClusterRoleBindingListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ClusterRoleBindingListFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1ClusterRoleBindingListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBuilder.java index fb11a8d2c5..7583906d66 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ClusterRoleBuilder extends io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ClusterRoleBuilder + extends io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ClusterRole, + io.kubernetes.client.openapi.models.V1ClusterRoleBuilder> { public V1ClusterRoleBuilder() { this(false); } + public V1ClusterRoleBuilder(java.lang.Boolean validationEnabled) { this(new V1ClusterRole(), validationEnabled); } + public V1ClusterRoleBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleFluent fluent) { this(fluent, false); } - public V1ClusterRoleBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ClusterRoleBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ClusterRole(), validationEnabled); } - public V1ClusterRoleBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleFluent fluent,io.kubernetes.client.openapi.models.V1ClusterRole instance) { + + public V1ClusterRoleBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleFluent fluent, + io.kubernetes.client.openapi.models.V1ClusterRole instance) { this(fluent, instance, false); } - public V1ClusterRoleBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleFluent fluent,io.kubernetes.client.openapi.models.V1ClusterRole instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ClusterRoleBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleFluent fluent, + io.kubernetes.client.openapi.models.V1ClusterRole instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAggregationRule(instance.getAggregationRule()); fluent.withApiVersion(instance.getApiVersion()); @@ -31,13 +57,17 @@ public V1ClusterRoleBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleFlu fluent.withRules(instance.getRules()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ClusterRoleBuilder(io.kubernetes.client.openapi.models.V1ClusterRole instance) { - this(instance,false); + this(instance, false); } - public V1ClusterRoleBuilder(io.kubernetes.client.openapi.models.V1ClusterRole instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ClusterRoleBuilder( + io.kubernetes.client.openapi.models.V1ClusterRole instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAggregationRule(instance.getAggregationRule()); this.withApiVersion(instance.getApiVersion()); @@ -48,10 +78,12 @@ public V1ClusterRoleBuilder(io.kubernetes.client.openapi.models.V1ClusterRole in this.withRules(instance.getRules()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ClusterRoleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ClusterRole build() { V1ClusterRole buildable = new V1ClusterRole(); buildable.setAggregationRule(fluent.getAggregationRule()); @@ -61,18 +93,23 @@ public io.kubernetes.client.openapi.models.V1ClusterRole build() { buildable.setRules(fluent.getRules()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ClusterRoleBuilder that = (V1ClusterRoleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleFluent.java index 953eea7175..cb4125d945 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleFluent.java @@ -1,115 +1,193 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1ClusterRoleFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1ClusterRoleFluent< + A extends io.kubernetes.client.openapi.models.V1ClusterRoleFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildAggregationRule instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1AggregationRule getAggregationRule(); + public io.kubernetes.client.openapi.models.V1AggregationRule buildAggregationRule(); - public A withAggregationRule(io.kubernetes.client.openapi.models.V1AggregationRule aggregationRule); + + public A withAggregationRule( + io.kubernetes.client.openapi.models.V1AggregationRule aggregationRule); + public java.lang.Boolean hasAggregationRule(); - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested withNewAggregationRule(); - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested withNewAggregationRuleLike(io.kubernetes.client.openapi.models.V1AggregationRule item); - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested editAggregationRule(); - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested editOrNewAggregationRule(); - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested editOrNewAggregationRuleLike(io.kubernetes.client.openapi.models.V1AggregationRule item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested + withNewAggregationRule(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested + withNewAggregationRuleLike(io.kubernetes.client.openapi.models.V1AggregationRule item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested + editAggregationRule(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested + editOrNewAggregationRule(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested + editOrNewAggregationRuleLike(io.kubernetes.client.openapi.models.V1AggregationRule item); + public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item); - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public A addToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item); + + public A setToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item); + public A addToRules(io.kubernetes.client.openapi.models.V1PolicyRule... items); - public A addAllToRules(java.util.Collection items); + + public A addAllToRules( + java.util.Collection items); + public A removeFromRules(io.kubernetes.client.openapi.models.V1PolicyRule... items); - public A removeAllFromRules(java.util.Collection items); - public A removeMatchingFromRules(java.util.function.Predicate predicate); - + + public A removeAllFromRules( + java.util.Collection items); + + public A removeMatchingFromRules( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildRules instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getRules(); + public java.util.List buildRules(); + public io.kubernetes.client.openapi.models.V1PolicyRule buildRule(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PolicyRule buildFirstRule(); + public io.kubernetes.client.openapi.models.V1PolicyRule buildLastRule(); - public io.kubernetes.client.openapi.models.V1PolicyRule buildMatchingRule(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PolicyRule buildMatchingRule( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate + predicate); + public A withRules(java.util.List rules); + public A withRules(io.kubernetes.client.openapi.models.V1PolicyRule... rules); + public java.lang.Boolean hasRules(); + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested addNewRule(); - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1PolicyRule item); - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item); - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested editRule(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested addNewRuleLike( + io.kubernetes.client.openapi.models.V1PolicyRule item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested setNewRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested editRule( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested editFirstRule(); + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested editLastRule(); - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate); - public interface AggregationRuleNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1AggregationRuleFluent>{ + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested editMatchingRule( + java.util.function.Predicate + predicate); + + public interface AggregationRuleNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1AggregationRuleFluent< + io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested> { public N and(); + public N endAggregationRule(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface RulesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PolicyRuleFluent>{ + + public interface RulesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PolicyRuleFluent< + io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested> { public N and(); + public N endRule(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleFluentImpl.java index e7f1619d25..092e87c56c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1ClusterRoleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ClusterRoleFluent{ - public V1ClusterRoleFluentImpl() { - } +/** Generated */ +public class V1ClusterRoleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ClusterRoleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ClusterRoleFluent { + public V1ClusterRoleFluentImpl() {} + public V1ClusterRoleFluentImpl(io.kubernetes.client.openapi.models.V1ClusterRole instance) { this.withAggregationRule(instance.getAggregationRule()); @@ -30,141 +32,256 @@ public V1ClusterRoleFluentImpl(io.kubernetes.client.openapi.models.V1ClusterRole this.withMetadata(instance.getMetadata()); this.withRules(instance.getRules()); - } + private io.kubernetes.client.openapi.models.V1AggregationRuleBuilder aggregationRule; private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private java.util.ArrayList rules; - + /** * This method has been deprecated, please use method buildAggregationRule instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1AggregationRule getAggregationRule() { - return this.aggregationRule!=null ?this.aggregationRule.build():null; + return this.aggregationRule != null ? this.aggregationRule.build() : null; } + public io.kubernetes.client.openapi.models.V1AggregationRule buildAggregationRule() { - return this.aggregationRule!=null ?this.aggregationRule.build():null; + return this.aggregationRule != null ? this.aggregationRule.build() : null; } - public A withAggregationRule(io.kubernetes.client.openapi.models.V1AggregationRule aggregationRule) { + + public A withAggregationRule( + io.kubernetes.client.openapi.models.V1AggregationRule aggregationRule) { _visitables.get("aggregationRule").remove(this.aggregationRule); - if (aggregationRule!=null){ this.aggregationRule= new io.kubernetes.client.openapi.models.V1AggregationRuleBuilder(aggregationRule); _visitables.get("aggregationRule").add(this.aggregationRule);} return (A) this; + if (aggregationRule != null) { + this.aggregationRule = + new io.kubernetes.client.openapi.models.V1AggregationRuleBuilder(aggregationRule); + _visitables.get("aggregationRule").add(this.aggregationRule); + } + return (A) this; } + public java.lang.Boolean hasAggregationRule() { return this.aggregationRule != null; } - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested withNewAggregationRule() { - return new io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl.AggregationRuleNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested + withNewAggregationRule() { + return new io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl + .AggregationRuleNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested withNewAggregationRuleLike(io.kubernetes.client.openapi.models.V1AggregationRule item) { - return new io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl.AggregationRuleNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested + withNewAggregationRuleLike(io.kubernetes.client.openapi.models.V1AggregationRule item) { + return new io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl + .AggregationRuleNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested editAggregationRule() { + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested + editAggregationRule() { return withNewAggregationRuleLike(getAggregationRule()); } - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested editOrNewAggregationRule() { - return withNewAggregationRuleLike(getAggregationRule() != null ? getAggregationRule(): new io.kubernetes.client.openapi.models.V1AggregationRuleBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested + editOrNewAggregationRule() { + return withNewAggregationRuleLike( + getAggregationRule() != null + ? getAggregationRule() + : new io.kubernetes.client.openapi.models.V1AggregationRuleBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested editOrNewAggregationRuleLike(io.kubernetes.client.openapi.models.V1AggregationRule item) { - return withNewAggregationRuleLike(getAggregationRule() != null ? getAggregationRule(): item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested + editOrNewAggregationRuleLike(io.kubernetes.client.openapi.models.V1AggregationRule item) { + return withNewAggregationRuleLike(getAggregationRule() != null ? getAggregationRule() : item); } + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item);_visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder);this.rules.add(index >= 0 ? index : rules.size(), builder); return (A)this; + + public A addToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); + _visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder); + this.rules.add(index >= 0 ? index : rules.size(), builder); + return (A) this; } - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); - if (index < 0 || index >= _visitables.get("rules").size()) { _visitables.get("rules").add(builder); } else { _visitables.get("rules").set(index, builder);} - if (index < 0 || index >= rules.size()) { rules.add(builder); } else { rules.set(index, builder);} - return (A)this; + + public A setToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); + if (index < 0 || index >= _visitables.get("rules").size()) { + _visitables.get("rules").add(builder); + } else { + _visitables.get("rules").set(index, builder); + } + if (index < 0 || index >= rules.size()) { + rules.add(builder); + } else { + rules.set(index, builder); + } + return (A) this; } + public A addToRules(io.kubernetes.client.openapi.models.V1PolicyRule... items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) {io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + if (this.rules == null) { + this.rules = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) { + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } - public A addAllToRules(java.util.Collection items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) {io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + + public A addAllToRules( + java.util.Collection items) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) { + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } + public A removeFromRules(io.kubernetes.client.openapi.models.V1PolicyRule... items) { - for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) {io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) { + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeAllFromRules(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) {io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + + public A removeAllFromRules( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) { + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromRules(java.util.function.Predicate predicate) { + + public A removeMatchingFromRules( + java.util.function.Predicate + predicate) { if (rules == null) return (A) this; final Iterator each = rules.iterator(); final List visitables = _visitables.get("rules"); @@ -175,140 +292,228 @@ public A removeMatchingFromRules(java.util.function.Predicate getRules() { return rules != null ? build(rules) : null; } + public java.util.List buildRules() { return rules != null ? build(rules) : null; } + public io.kubernetes.client.openapi.models.V1PolicyRule buildRule(java.lang.Integer index) { return this.rules.get(index).build(); } + public io.kubernetes.client.openapi.models.V1PolicyRule buildFirstRule() { return this.rules.get(0).build(); } + public io.kubernetes.client.openapi.models.V1PolicyRule buildLastRule() { return this.rules.get(rules.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PolicyRule buildMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PolicyRuleBuilder item: rules) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PolicyRule buildMatchingRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PolicyRuleBuilder item : rules) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PolicyRuleBuilder item: rules) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PolicyRuleBuilder item : rules) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withRules(java.util.List rules) { - if (this.rules != null) { _visitables.get("rules").removeAll(this.rules);} - if (rules != null) {this.rules = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PolicyRule item : rules){this.addToRules(item);}} else { this.rules = null;} return (A) this; + if (this.rules != null) { + _visitables.get("rules").removeAll(this.rules); + } + if (rules != null) { + this.rules = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PolicyRule item : rules) { + this.addToRules(item); + } + } else { + this.rules = null; + } + return (A) this; } + public A withRules(io.kubernetes.client.openapi.models.V1PolicyRule... rules) { - if (this.rules != null) {this.rules.clear();} - if (rules != null) {for (io.kubernetes.client.openapi.models.V1PolicyRule item :rules){ this.addToRules(item);}} return (A) this; + if (this.rules != null) { + this.rules.clear(); + } + if (rules != null) { + for (io.kubernetes.client.openapi.models.V1PolicyRule item : rules) { + this.addToRules(item); + } + } + return (A) this; } + public java.lang.Boolean hasRules() { return rules != null && !rules.isEmpty(); } + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested addNewRule() { return new io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl.RulesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1PolicyRule item) { - return new io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl.RulesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested addNewRuleLike( + io.kubernetes.client.openapi.models.V1PolicyRule item) { + return new io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl.RulesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item) { - return new io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl.RulesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested setNewRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item) { + return new io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl.RulesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested editRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested editRule( + java.lang.Integer index) { if (rules.size() <= index) throw new RuntimeException("Can't edit rules. Index exceeds size."); return setNewRuleLike(index, buildRule(index)); } + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested editFirstRule() { if (rules.size() == 0) throw new RuntimeException("Can't edit first rules. The list is empty."); return setNewRuleLike(0, buildRule(0)); } + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested editLastRule() { int index = rules.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last rules. The list is empty."); return setNewRuleLike(index, buildRule(index)); } - public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested editMatchingRule( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1AggregationRuleFluentImpl> implements io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested,io.kubernetes.client.fluent.Nested{ + + public class AggregationRuleNestedImpl + extends io.kubernetes.client.openapi.models.V1AggregationRuleFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested> + implements io.kubernetes.client.openapi.models.V1ClusterRoleFluent.AggregationRuleNested, + io.kubernetes.client.fluent.Nested { AggregationRuleNestedImpl(io.kubernetes.client.openapi.models.V1AggregationRule item) { this.builder = new io.kubernetes.client.openapi.models.V1AggregationRuleBuilder(this, item); } + AggregationRuleNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1AggregationRuleBuilder(this); } + io.kubernetes.client.openapi.models.V1AggregationRuleBuilder builder; + public N and() { return (N) V1ClusterRoleFluentImpl.this.withAggregationRule(builder.build()); } + public N endAggregationRule() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ClusterRoleFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1ClusterRoleFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class RulesNestedImpl extends io.kubernetes.client.openapi.models.V1PolicyRuleFluentImpl> implements io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested,io.kubernetes.client.fluent.Nested{ - RulesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item) { + + public class RulesNestedImpl + extends io.kubernetes.client.openapi.models.V1PolicyRuleFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested> + implements io.kubernetes.client.openapi.models.V1ClusterRoleFluent.RulesNested, + io.kubernetes.client.fluent.Nested { + RulesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(this, item); } + RulesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(this); } + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ClusterRoleFluentImpl.this.setToRules(index,builder.build()); + return (N) V1ClusterRoleFluentImpl.this.setToRules(index, builder.build()); } + public N endRule() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleListBuilder.java index 30e72afca7..10fe10a03d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ClusterRoleListBuilder extends io.kubernetes.client.openapi.models.V1ClusterRoleListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ClusterRoleListBuilder + extends io.kubernetes.client.openapi.models.V1ClusterRoleListFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ClusterRoleList, + io.kubernetes.client.openapi.models.V1ClusterRoleListBuilder> { public V1ClusterRoleListBuilder() { this(false); } + public V1ClusterRoleListBuilder(java.lang.Boolean validationEnabled) { this(new V1ClusterRoleList(), validationEnabled); } - public V1ClusterRoleListBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleListFluent fluent) { + + public V1ClusterRoleListBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleListFluent fluent) { this(fluent, false); } - public V1ClusterRoleListBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ClusterRoleListBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ClusterRoleList(), validationEnabled); } - public V1ClusterRoleListBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleListFluent fluent,io.kubernetes.client.openapi.models.V1ClusterRoleList instance) { + + public V1ClusterRoleListBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleListFluent fluent, + io.kubernetes.client.openapi.models.V1ClusterRoleList instance) { this(fluent, instance, false); } - public V1ClusterRoleListBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleListFluent fluent,io.kubernetes.client.openapi.models.V1ClusterRoleList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ClusterRoleListBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleListFluent fluent, + io.kubernetes.client.openapi.models.V1ClusterRoleList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1ClusterRoleListBuilder(io.kubernetes.client.openapi.models.V1ClusterRol fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ClusterRoleListBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleList instance) { - this(instance,false); + this(instance, false); } - public V1ClusterRoleListBuilder(io.kubernetes.client.openapi.models.V1ClusterRoleList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ClusterRoleListBuilder( + io.kubernetes.client.openapi.models.V1ClusterRoleList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1ClusterRoleListBuilder(io.kubernetes.client.openapi.models.V1ClusterRol this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ClusterRoleListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ClusterRoleList build() { V1ClusterRoleList buildable = new V1ClusterRoleList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1ClusterRoleList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ClusterRoleListBuilder that = (V1ClusterRoleListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleListFluent.java index 2946a9d204..485097674b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleListFluent.java @@ -1,95 +1,155 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ClusterRoleListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ClusterRoleListFluent< + A extends io.kubernetes.client.openapi.models.V1ClusterRoleListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRole item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRole item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRole item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRole item); + public A addToItems(io.kubernetes.client.openapi.models.V1ClusterRole... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1ClusterRole... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1ClusterRole buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ClusterRole buildFirstItem(); + public io.kubernetes.client.openapi.models.V1ClusterRole buildLastItem(); - public io.kubernetes.client.openapi.models.V1ClusterRole buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ClusterRole buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1ClusterRole... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ClusterRole item); - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRole item); - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1ClusterRole item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRole item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ClusterRoleFluent>{ + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ClusterRoleFluent< + io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleListFluentImpl.java index 6707135a39..d3022eb6ef 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ClusterRoleListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1ClusterRoleListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ClusterRoleListFluent{ - public V1ClusterRoleListFluentImpl() { - } - public V1ClusterRoleListFluentImpl(io.kubernetes.client.openapi.models.V1ClusterRoleList instance) { + +/** Generated */ +public class V1ClusterRoleListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ClusterRoleListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ClusterRoleListFluent { + public V1ClusterRoleListFluentImpl() {} + + public V1ClusterRoleListFluentImpl( + io.kubernetes.client.openapi.models.V1ClusterRoleList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1ClusterRoleListFluentImpl(io.kubernetes.client.openapi.models.V1Cluster this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRole item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRole item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder = + new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRole item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRole item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder = + new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1ClusterRole... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ClusterRole item : items) {io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ClusterRole item : items) { + io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder = + new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ClusterRole item : items) {io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ClusterRole item : items) { + io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder = + new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1ClusterRole... items) { - for (io.kubernetes.client.openapi.models.V1ClusterRole item : items) {io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ClusterRole item : items) { + io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder = + new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ClusterRole item : items) {io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ClusterRole item : items) { + io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder = + new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder = each.next(); @@ -87,174 +159,277 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1ClusterRole buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ClusterRole buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ClusterRole buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ClusterRole buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ClusterRoleBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ClusterRole buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ClusterRoleBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ClusterRoleBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ClusterRoleBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ClusterRole item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ClusterRole item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1ClusterRole... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1ClusterRole item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1ClusterRole item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1ClusterRoleListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ClusterRole item) { - return new io.kubernetes.client.openapi.models.V1ClusterRoleListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1ClusterRole item) { + return new io.kubernetes.client.openapi.models.V1ClusterRoleListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRole item) { - return new io.kubernetes.client.openapi.models.V1ClusterRoleListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRole item) { + return new io.kubernetes.client.openapi.models.V1ClusterRoleListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1ClusterRoleListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1ClusterRoleListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1ClusterRoleListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ClusterRoleListFluentImpl that = (V1ClusterRoleListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl> implements io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ClusterRole item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1ClusterRoleFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ClusterRole item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ClusterRoleBuilder(this); } + io.kubernetes.client.openapi.models.V1ClusterRoleBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ClusterRoleListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1ClusterRoleListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ClusterRoleListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1ClusterRoleListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentConditionBuilder.java index 11eccd8509..7ad7901572 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ComponentConditionBuilder extends io.kubernetes.client.openapi.models.V1ComponentConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ComponentConditionBuilder + extends io.kubernetes.client.openapi.models.V1ComponentConditionFluentImpl< + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ComponentCondition, + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder> { public V1ComponentConditionBuilder() { this(false); } + public V1ComponentConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1ComponentCondition(), validationEnabled); } - public V1ComponentConditionBuilder(io.kubernetes.client.openapi.models.V1ComponentConditionFluent fluent) { + + public V1ComponentConditionBuilder( + io.kubernetes.client.openapi.models.V1ComponentConditionFluent fluent) { this(fluent, false); } - public V1ComponentConditionBuilder(io.kubernetes.client.openapi.models.V1ComponentConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ComponentConditionBuilder( + io.kubernetes.client.openapi.models.V1ComponentConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ComponentCondition(), validationEnabled); } - public V1ComponentConditionBuilder(io.kubernetes.client.openapi.models.V1ComponentConditionFluent fluent,io.kubernetes.client.openapi.models.V1ComponentCondition instance) { + + public V1ComponentConditionBuilder( + io.kubernetes.client.openapi.models.V1ComponentConditionFluent fluent, + io.kubernetes.client.openapi.models.V1ComponentCondition instance) { this(fluent, instance, false); } - public V1ComponentConditionBuilder(io.kubernetes.client.openapi.models.V1ComponentConditionFluent fluent,io.kubernetes.client.openapi.models.V1ComponentCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ComponentConditionBuilder( + io.kubernetes.client.openapi.models.V1ComponentConditionFluent fluent, + io.kubernetes.client.openapi.models.V1ComponentCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withError(instance.getError()); fluent.withMessage(instance.getMessage()); @@ -29,13 +56,18 @@ public V1ComponentConditionBuilder(io.kubernetes.client.openapi.models.V1Compone fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ComponentConditionBuilder(io.kubernetes.client.openapi.models.V1ComponentCondition instance) { - this(instance,false); + + public V1ComponentConditionBuilder( + io.kubernetes.client.openapi.models.V1ComponentCondition instance) { + this(instance, false); } - public V1ComponentConditionBuilder(io.kubernetes.client.openapi.models.V1ComponentCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ComponentConditionBuilder( + io.kubernetes.client.openapi.models.V1ComponentCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withError(instance.getError()); this.withMessage(instance.getMessage()); @@ -44,10 +76,12 @@ public V1ComponentConditionBuilder(io.kubernetes.client.openapi.models.V1Compone this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ComponentConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ComponentCondition build() { V1ComponentCondition buildable = new V1ComponentCondition(); buildable.setError(fluent.getError()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1ComponentCondition build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ComponentConditionBuilder that = (V1ComponentConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentConditionFluent.java index b92231729c..44e40dbce1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentConditionFluent.java @@ -1,50 +1,58 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ComponentConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ComponentConditionFluent< + A extends io.kubernetes.client.openapi.models.V1ComponentConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getError(); + public A withError(java.lang.String error); + public java.lang.Boolean hasError(); - - /** - * Method is deprecated. use withError instead. - */ + + /** Method is deprecated. use withError instead. */ @java.lang.Deprecated public A withNewError(java.lang.String original); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentConditionFluentImpl.java index dcb5e90404..e7c94122f8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentConditionFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ComponentConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ComponentConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ComponentConditionFluent { + public V1ComponentConditionFluentImpl() {} - /** - * Generated - */ -public class V1ComponentConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ComponentConditionFluent{ - public V1ComponentConditionFluentImpl() { - } - public V1ComponentConditionFluentImpl(io.kubernetes.client.openapi.models.V1ComponentCondition instance) { + public V1ComponentConditionFluentImpl( + io.kubernetes.client.openapi.models.V1ComponentCondition instance) { this.withError(instance.getError()); this.withMessage(instance.getMessage()); @@ -20,92 +28,101 @@ public V1ComponentConditionFluentImpl(io.kubernetes.client.openapi.models.V1Comp this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.lang.String error; private java.lang.String message; private java.lang.String status; private java.lang.String type; + public java.lang.String getError() { return this.error; } + public A withError(java.lang.String error) { - this.error=error; return (A) this; + this.error = error; + return (A) this; } + public java.lang.Boolean hasError() { return this.error != null; } - - /** - * Method is deprecated. use withError instead. - */ + + /** Method is deprecated. use withError instead. */ @java.lang.Deprecated public A withNewError(java.lang.String original) { - return (A)withError(new String(original)); + return (A) withError(new String(original)); } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ComponentConditionFluentImpl that = (V1ComponentConditionFluentImpl) o; - if (error != null ? !error.equals(that.error) :that.error != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (error != null ? !error.equals(that.error) : that.error != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(error, message, status, type, super.hashCode()); + return java.util.Objects.hash(error, message, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusBuilder.java index a53220b0e5..05460ea8de 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ComponentStatusBuilder extends io.kubernetes.client.openapi.models.V1ComponentStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ComponentStatusBuilder + extends io.kubernetes.client.openapi.models.V1ComponentStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ComponentStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ComponentStatus, + io.kubernetes.client.openapi.models.V1ComponentStatusBuilder> { public V1ComponentStatusBuilder() { this(false); } + public V1ComponentStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1ComponentStatus(), validationEnabled); } - public V1ComponentStatusBuilder(io.kubernetes.client.openapi.models.V1ComponentStatusFluent fluent) { + + public V1ComponentStatusBuilder( + io.kubernetes.client.openapi.models.V1ComponentStatusFluent fluent) { this(fluent, false); } - public V1ComponentStatusBuilder(io.kubernetes.client.openapi.models.V1ComponentStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ComponentStatusBuilder( + io.kubernetes.client.openapi.models.V1ComponentStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ComponentStatus(), validationEnabled); } - public V1ComponentStatusBuilder(io.kubernetes.client.openapi.models.V1ComponentStatusFluent fluent,io.kubernetes.client.openapi.models.V1ComponentStatus instance) { + + public V1ComponentStatusBuilder( + io.kubernetes.client.openapi.models.V1ComponentStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ComponentStatus instance) { this(fluent, instance, false); } - public V1ComponentStatusBuilder(io.kubernetes.client.openapi.models.V1ComponentStatusFluent fluent,io.kubernetes.client.openapi.models.V1ComponentStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ComponentStatusBuilder( + io.kubernetes.client.openapi.models.V1ComponentStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ComponentStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withConditions(instance.getConditions()); @@ -29,13 +56,17 @@ public V1ComponentStatusBuilder(io.kubernetes.client.openapi.models.V1ComponentS fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ComponentStatusBuilder(io.kubernetes.client.openapi.models.V1ComponentStatus instance) { - this(instance,false); + this(instance, false); } - public V1ComponentStatusBuilder(io.kubernetes.client.openapi.models.V1ComponentStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ComponentStatusBuilder( + io.kubernetes.client.openapi.models.V1ComponentStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withConditions(instance.getConditions()); @@ -44,10 +75,12 @@ public V1ComponentStatusBuilder(io.kubernetes.client.openapi.models.V1ComponentS this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ComponentStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ComponentStatus build() { V1ComponentStatus buildable = new V1ComponentStatus(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1ComponentStatus build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ComponentStatusBuilder that = (V1ComponentStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusFluent.java index 03fde2d7d2..a45ed8e7c4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusFluent.java @@ -1,95 +1,162 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ComponentStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ComponentStatusFluent< + A extends io.kubernetes.client.openapi.models.V1ComponentStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentCondition item); + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentCondition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentCondition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1ComponentCondition... items); - public A addAllToConditions(java.util.Collection items); + + public A addAllToConditions( + java.util.Collection items); + public A removeFromConditions(io.kubernetes.client.openapi.models.V1ComponentCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getConditions(); + public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1ComponentCondition buildCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ComponentCondition buildCondition( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ComponentCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1ComponentCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1ComponentCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); + + public io.kubernetes.client.openapi.models.V1ComponentCondition buildMatchingCondition( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate); + + public A withConditions( + java.util.List conditions); + public A withConditions(io.kubernetes.client.openapi.models.V1ComponentCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1ComponentCondition item); - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentCondition item); - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1ComponentCondition item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentCondition item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ComponentConditionFluent>{ + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ComponentConditionFluent< + io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested> { public N and(); + public N endCondition(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusFluentImpl.java index 7cac73ad2e..e7e9b2e529 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1ComponentStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ComponentStatusFluent{ - public V1ComponentStatusFluentImpl() { - } - public V1ComponentStatusFluentImpl(io.kubernetes.client.openapi.models.V1ComponentStatus instance) { + +/** Generated */ +public class V1ComponentStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ComponentStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ComponentStatusFluent { + public V1ComponentStatusFluentImpl() {} + + public V1ComponentStatusFluentImpl( + io.kubernetes.client.openapi.models.V1ComponentStatus instance) { this.withApiVersion(instance.getApiVersion()); this.withConditions(instance.getConditions()); @@ -28,57 +31,133 @@ public V1ComponentStatusFluentImpl(io.kubernetes.client.openapi.models.V1Compone this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList conditions; + private java.util.ArrayList + conditions; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } + public A addToConditions(io.kubernetes.client.openapi.models.V1ComponentCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ComponentCondition item : items) {io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ComponentCondition item : items) { + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ComponentCondition item : items) {io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ComponentCondition item : items) { + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } + public A removeFromConditions(io.kubernetes.client.openapi.models.V1ComponentCondition... items) { - for (io.kubernetes.client.openapi.models.V1ComponentCondition item : items) {io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ComponentCondition item : items) { + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ComponentCondition item : items) {io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ComponentCondition item : items) { + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder = each.next(); @@ -87,174 +166,289 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1ComponentCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ComponentCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ComponentCondition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ComponentCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ComponentCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ComponentConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ComponentCondition buildMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ComponentConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ComponentConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ComponentConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ComponentCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ComponentCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } + public A withConditions(io.kubernetes.client.openapi.models.V1ComponentCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1ComponentCondition item :conditions){ this.addToConditions(item);}} return (A) this; + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1ComponentCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1ComponentStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1ComponentStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1ComponentCondition item) { - return new io.kubernetes.client.openapi.models.V1ComponentStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1ComponentCondition item) { + return new io.kubernetes.client.openapi.models.V1ComponentStatusFluentImpl.ConditionsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentCondition item) { - return new io.kubernetes.client.openapi.models.V1ComponentStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentCondition item) { + return new io.kubernetes.client.openapi.models.V1ComponentStatusFluentImpl.ConditionsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1ComponentStatusFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1ComponentStatusFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1ComponentStatusFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ComponentStatusFluentImpl that = (V1ComponentStatusFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (conditions != null ? !conditions.equals(that.conditions) :that.conditions != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (conditions != null ? !conditions.equals(that.conditions) : that.conditions != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, conditions, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, conditions, kind, metadata, super.hashCode()); } - public class ConditionsNestedImpl extends io.kubernetes.client.openapi.models.V1ComponentConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1ComponentConditionFluentImpl< + io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1ComponentStatusFluent.ConditionsNested, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ComponentConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1ComponentConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ComponentStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1ComponentStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ComponentStatusFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1ComponentStatusFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusListBuilder.java index 16cdb8240e..3c1a485f99 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ComponentStatusListBuilder extends io.kubernetes.client.openapi.models.V1ComponentStatusListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ComponentStatusListBuilder + extends io.kubernetes.client.openapi.models.V1ComponentStatusListFluentImpl< + io.kubernetes.client.openapi.models.V1ComponentStatusListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ComponentStatusList, + io.kubernetes.client.openapi.models.V1ComponentStatusListBuilder> { public V1ComponentStatusListBuilder() { this(false); } + public V1ComponentStatusListBuilder(java.lang.Boolean validationEnabled) { this(new V1ComponentStatusList(), validationEnabled); } - public V1ComponentStatusListBuilder(io.kubernetes.client.openapi.models.V1ComponentStatusListFluent fluent) { + + public V1ComponentStatusListBuilder( + io.kubernetes.client.openapi.models.V1ComponentStatusListFluent fluent) { this(fluent, false); } - public V1ComponentStatusListBuilder(io.kubernetes.client.openapi.models.V1ComponentStatusListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ComponentStatusListBuilder( + io.kubernetes.client.openapi.models.V1ComponentStatusListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ComponentStatusList(), validationEnabled); } - public V1ComponentStatusListBuilder(io.kubernetes.client.openapi.models.V1ComponentStatusListFluent fluent,io.kubernetes.client.openapi.models.V1ComponentStatusList instance) { + + public V1ComponentStatusListBuilder( + io.kubernetes.client.openapi.models.V1ComponentStatusListFluent fluent, + io.kubernetes.client.openapi.models.V1ComponentStatusList instance) { this(fluent, instance, false); } - public V1ComponentStatusListBuilder(io.kubernetes.client.openapi.models.V1ComponentStatusListFluent fluent,io.kubernetes.client.openapi.models.V1ComponentStatusList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ComponentStatusListBuilder( + io.kubernetes.client.openapi.models.V1ComponentStatusListFluent fluent, + io.kubernetes.client.openapi.models.V1ComponentStatusList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1ComponentStatusListBuilder(io.kubernetes.client.openapi.models.V1Compon fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ComponentStatusListBuilder(io.kubernetes.client.openapi.models.V1ComponentStatusList instance) { - this(instance,false); + + public V1ComponentStatusListBuilder( + io.kubernetes.client.openapi.models.V1ComponentStatusList instance) { + this(instance, false); } - public V1ComponentStatusListBuilder(io.kubernetes.client.openapi.models.V1ComponentStatusList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ComponentStatusListBuilder( + io.kubernetes.client.openapi.models.V1ComponentStatusList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1ComponentStatusListBuilder(io.kubernetes.client.openapi.models.V1Compon this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ComponentStatusListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ComponentStatusList build() { V1ComponentStatusList buildable = new V1ComponentStatusList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1ComponentStatusList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ComponentStatusListBuilder that = (V1ComponentStatusListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusListFluent.java index 48254774a2..f6b5ff75c0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusListFluent.java @@ -1,95 +1,159 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ComponentStatusListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ComponentStatusListFluent< + A extends io.kubernetes.client.openapi.models.V1ComponentStatusListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentStatus item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentStatus item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentStatus item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentStatus item); + public A addToItems(io.kubernetes.client.openapi.models.V1ComponentStatus... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1ComponentStatus... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1ComponentStatus buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ComponentStatus buildFirstItem(); + public io.kubernetes.client.openapi.models.V1ComponentStatus buildLastItem(); - public io.kubernetes.client.openapi.models.V1ComponentStatus buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ComponentStatus buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1ComponentStatus... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ComponentStatus item); - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentStatus item); - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1ComponentStatus item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentStatus item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ComponentStatusFluent>{ + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ComponentStatusFluent< + io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusListFluentImpl.java index a08c9d096d..bfe6d59e81 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ComponentStatusListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1ComponentStatusListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ComponentStatusListFluent{ - public V1ComponentStatusListFluentImpl() { - } - public V1ComponentStatusListFluentImpl(io.kubernetes.client.openapi.models.V1ComponentStatusList instance) { + +/** Generated */ +public class V1ComponentStatusListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ComponentStatusListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ComponentStatusListFluent { + public V1ComponentStatusListFluentImpl() {} + + public V1ComponentStatusListFluentImpl( + io.kubernetes.client.openapi.models.V1ComponentStatusList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1ComponentStatusListFluentImpl(io.kubernetes.client.openapi.models.V1Com this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentStatus item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentStatus item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentStatus item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentStatus item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1ComponentStatus... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ComponentStatus item : items) {io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ComponentStatus item : items) { + io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ComponentStatus item : items) {io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ComponentStatus item : items) { + io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1ComponentStatus... items) { - for (io.kubernetes.client.openapi.models.V1ComponentStatus item : items) {io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ComponentStatus item : items) { + io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ComponentStatus item : items) {io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ComponentStatus item : items) { + io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder = each.next(); @@ -87,174 +159,282 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1ComponentStatus buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ComponentStatus buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ComponentStatus buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ComponentStatus buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ComponentStatusBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ComponentStatus buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ComponentStatusBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ComponentStatusBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ComponentStatusBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ComponentStatus item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ComponentStatus item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1ComponentStatus... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1ComponentStatus item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1ComponentStatus item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1ComponentStatusListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1ComponentStatusListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ComponentStatus item) { - return new io.kubernetes.client.openapi.models.V1ComponentStatusListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1ComponentStatus item) { + return new io.kubernetes.client.openapi.models.V1ComponentStatusListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentStatus item) { - return new io.kubernetes.client.openapi.models.V1ComponentStatusListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentStatus item) { + return new io.kubernetes.client.openapi.models.V1ComponentStatusListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1ComponentStatusListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1ComponentStatusListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1ComponentStatusListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1ComponentStatusListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ComponentStatusListFluentImpl that = (V1ComponentStatusListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1ComponentStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ComponentStatus item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1ComponentStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ComponentStatus item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ComponentStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1ComponentStatusBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ComponentStatusListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1ComponentStatusListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ComponentStatusListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1ComponentStatusListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConditionBuilder.java index c14e5638e1..07885e7b17 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConditionBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ConditionBuilder extends io.kubernetes.client.openapi.models.V1ConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ConditionBuilder + extends io.kubernetes.client.openapi.models.V1ConditionFluentImpl< + io.kubernetes.client.openapi.models.V1ConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Condition, + io.kubernetes.client.openapi.models.V1ConditionBuilder> { public V1ConditionBuilder() { this(false); } + public V1ConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1Condition(), validationEnabled); } + public V1ConditionBuilder(io.kubernetes.client.openapi.models.V1ConditionFluent fluent) { this(fluent, false); } - public V1ConditionBuilder(io.kubernetes.client.openapi.models.V1ConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ConditionBuilder( + io.kubernetes.client.openapi.models.V1ConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Condition(), validationEnabled); } - public V1ConditionBuilder(io.kubernetes.client.openapi.models.V1ConditionFluent fluent,io.kubernetes.client.openapi.models.V1Condition instance) { + + public V1ConditionBuilder( + io.kubernetes.client.openapi.models.V1ConditionFluent fluent, + io.kubernetes.client.openapi.models.V1Condition instance) { this(fluent, instance, false); } - public V1ConditionBuilder(io.kubernetes.client.openapi.models.V1ConditionFluent fluent,io.kubernetes.client.openapi.models.V1Condition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ConditionBuilder( + io.kubernetes.client.openapi.models.V1ConditionFluent fluent, + io.kubernetes.client.openapi.models.V1Condition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -33,13 +59,17 @@ public V1ConditionBuilder(io.kubernetes.client.openapi.models.V1ConditionFluent< fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ConditionBuilder(io.kubernetes.client.openapi.models.V1Condition instance) { - this(instance,false); + this(instance, false); } - public V1ConditionBuilder(io.kubernetes.client.openapi.models.V1Condition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ConditionBuilder( + io.kubernetes.client.openapi.models.V1Condition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -52,10 +82,12 @@ public V1ConditionBuilder(io.kubernetes.client.openapi.models.V1Condition instan this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Condition build() { V1Condition buildable = new V1Condition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -66,18 +98,23 @@ public io.kubernetes.client.openapi.models.V1Condition build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ConditionBuilder that = (V1ConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConditionFluent.java index 76018ddc9e..85c544f7b2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConditionFluent.java @@ -1,58 +1,70 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Long; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ConditionFluent< + A extends io.kubernetes.client.openapi.models.V1ConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.Long getObservedGeneration(); + public A withObservedGeneration(java.lang.Long observedGeneration); + public java.lang.Boolean hasObservedGeneration(); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConditionFluentImpl.java index 6154b31f8c..094e1dd9f7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConditionFluentImpl.java @@ -1,19 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ConditionFluent { + public V1ConditionFluentImpl() {} - /** - * Generated - */ -public class V1ConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ConditionFluent{ - public V1ConditionFluentImpl() { - } public V1ConditionFluentImpl(io.kubernetes.client.openapi.models.V1Condition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); @@ -26,114 +31,136 @@ public V1ConditionFluentImpl(io.kubernetes.client.openapi.models.V1Condition ins this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.Long observedGeneration; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.Long getObservedGeneration() { return this.observedGeneration; } + public A withObservedGeneration(java.lang.Long observedGeneration) { - this.observedGeneration=observedGeneration; return (A) this; + this.observedGeneration = observedGeneration; + return (A) this; } + public java.lang.Boolean hasObservedGeneration() { return this.observedGeneration != null; } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ConditionFluentImpl that = (V1ConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (observedGeneration != null ? !observedGeneration.equals(that.observedGeneration) :that.observedGeneration != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (observedGeneration != null + ? !observedGeneration.equals(that.observedGeneration) + : that.observedGeneration != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, observedGeneration, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, observedGeneration, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapBuilder.java index 332e56085f..2d51fa0689 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ConfigMapBuilder extends io.kubernetes.client.openapi.models.V1ConfigMapFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ConfigMapBuilder + extends io.kubernetes.client.openapi.models.V1ConfigMapFluentImpl< + io.kubernetes.client.openapi.models.V1ConfigMapBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ConfigMap, + io.kubernetes.client.openapi.models.V1ConfigMapBuilder> { public V1ConfigMapBuilder() { this(false); } + public V1ConfigMapBuilder(java.lang.Boolean validationEnabled) { this(new V1ConfigMap(), validationEnabled); } + public V1ConfigMapBuilder(io.kubernetes.client.openapi.models.V1ConfigMapFluent fluent) { this(fluent, false); } - public V1ConfigMapBuilder(io.kubernetes.client.openapi.models.V1ConfigMapFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ConfigMapBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ConfigMap(), validationEnabled); } - public V1ConfigMapBuilder(io.kubernetes.client.openapi.models.V1ConfigMapFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMap instance) { + + public V1ConfigMapBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMap instance) { this(fluent, instance, false); } - public V1ConfigMapBuilder(io.kubernetes.client.openapi.models.V1ConfigMapFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMap instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ConfigMapBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMap instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withBinaryData(instance.getBinaryData()); @@ -33,13 +59,17 @@ public V1ConfigMapBuilder(io.kubernetes.client.openapi.models.V1ConfigMapFluent< fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ConfigMapBuilder(io.kubernetes.client.openapi.models.V1ConfigMap instance) { - this(instance,false); + this(instance, false); } - public V1ConfigMapBuilder(io.kubernetes.client.openapi.models.V1ConfigMap instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ConfigMapBuilder( + io.kubernetes.client.openapi.models.V1ConfigMap instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withBinaryData(instance.getBinaryData()); @@ -52,10 +82,12 @@ public V1ConfigMapBuilder(io.kubernetes.client.openapi.models.V1ConfigMap instan this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ConfigMapFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ConfigMap build() { V1ConfigMap buildable = new V1ConfigMap(); buildable.setApiVersion(fluent.getApiVersion()); @@ -66,18 +98,23 @@ public io.kubernetes.client.openapi.models.V1ConfigMap build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ConfigMapBuilder that = (V1ConfigMapBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapEnvSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapEnvSourceBuilder.java index f657e89d18..19f8303944 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapEnvSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapEnvSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ConfigMapEnvSourceBuilder extends io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ConfigMapEnvSourceBuilder + extends io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluentImpl< + io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ConfigMapEnvSource, + io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceBuilder> { public V1ConfigMapEnvSourceBuilder() { this(false); } + public V1ConfigMapEnvSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1ConfigMapEnvSource(), validationEnabled); } - public V1ConfigMapEnvSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent fluent) { + + public V1ConfigMapEnvSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent fluent) { this(fluent, false); } - public V1ConfigMapEnvSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ConfigMapEnvSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ConfigMapEnvSource(), validationEnabled); } - public V1ConfigMapEnvSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMapEnvSource instance) { + + public V1ConfigMapEnvSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMapEnvSource instance) { this(fluent, instance, false); } - public V1ConfigMapEnvSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMapEnvSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ConfigMapEnvSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMapEnvSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ConfigMapEnvSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource instance) { - this(instance,false); + + public V1ConfigMapEnvSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapEnvSource instance) { + this(instance, false); } - public V1ConfigMapEnvSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ConfigMapEnvSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapEnvSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ConfigMapEnvSource build() { V1ConfigMapEnvSource buildable = new V1ConfigMapEnvSource(); buildable.setName(fluent.getName()); buildable.setOptional(fluent.getOptional()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ConfigMapEnvSourceBuilder that = (V1ConfigMapEnvSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapEnvSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapEnvSourceFluent.java index e440a557f1..71217612dd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapEnvSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapEnvSourceFluent.java @@ -1,26 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ConfigMapEnvSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ConfigMapEnvSourceFluent< + A extends io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Boolean getOptional(); + public A withOptional(java.lang.Boolean optional); + public java.lang.Boolean hasOptional(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapEnvSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapEnvSourceFluentImpl.java index 15177a36cd..2409f02e57 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapEnvSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapEnvSourceFluentImpl.java @@ -1,61 +1,76 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ConfigMapEnvSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent { + public V1ConfigMapEnvSourceFluentImpl() {} - /** - * Generated - */ -public class V1ConfigMapEnvSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent{ - public V1ConfigMapEnvSourceFluentImpl() { - } - public V1ConfigMapEnvSourceFluentImpl(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource instance) { + public V1ConfigMapEnvSourceFluentImpl( + io.kubernetes.client.openapi.models.V1ConfigMapEnvSource instance) { this.withName(instance.getName()); this.withOptional(instance.getOptional()); - } + private java.lang.String name; private java.lang.Boolean optional; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Boolean getOptional() { return this.optional; } + public A withOptional(java.lang.Boolean optional) { - this.optional=optional; return (A) this; + this.optional = optional; + return (A) this; } + public java.lang.Boolean hasOptional() { return this.optional != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ConfigMapEnvSourceFluentImpl that = (V1ConfigMapEnvSourceFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (optional != null ? !optional.equals(that.optional) :that.optional != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (optional != null ? !optional.equals(that.optional) : that.optional != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, optional, super.hashCode()); + return java.util.Objects.hash(name, optional, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapFluent.java index 2f4c701f15..180923c73d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapFluent.java @@ -1,72 +1,108 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1ConfigMapFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ConfigMapFluent< + A extends io.kubernetes.client.openapi.models.V1ConfigMapFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToBinaryData(java.lang.String key,byte[] value); - public A addToBinaryData(java.util.Map map); + + public A addToBinaryData(java.lang.String key, byte[] value); + + public A addToBinaryData(java.util.Map map); + public A removeFromBinaryData(java.lang.String key); - public A removeFromBinaryData(java.util.Map map); - public java.util.Map getBinaryData(); - public A withBinaryData(java.util.Map binaryData); + + public A removeFromBinaryData(java.util.Map map); + + public java.util.Map getBinaryData(); + + public A withBinaryData(java.util.Map binaryData); + public java.lang.Boolean hasBinaryData(); - public A addToData(java.lang.String key,java.lang.String value); - public A addToData(java.util.Map map); + + public A addToData(java.lang.String key, java.lang.String value); + + public A addToData(java.util.Map map); + public A removeFromData(java.lang.String key); - public A removeFromData(java.util.Map map); - public java.util.Map getData(); - public A withData(java.util.Map data); + + public A removeFromData(java.util.Map map); + + public java.util.Map getData(); + + public A withData(java.util.Map data); + public java.lang.Boolean hasData(); + public java.lang.Boolean getImmutable(); + public A withImmutable(java.lang.Boolean immutable); + public java.lang.Boolean hasImmutable(); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapFluentImpl.java index 8e24278419..13dc656d07 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapFluentImpl.java @@ -1,20 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public class V1ConfigMapFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ConfigMapFluent{ - public V1ConfigMapFluentImpl() { - } +/** Generated */ +public class V1ConfigMapFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ConfigMapFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ConfigMapFluent { + public V1ConfigMapFluentImpl() {} + public V1ConfigMapFluentImpl(io.kubernetes.client.openapi.models.V1ConfigMap instance) { this.withApiVersion(instance.getApiVersion()); @@ -27,171 +31,283 @@ public V1ConfigMapFluentImpl(io.kubernetes.client.openapi.models.V1ConfigMap ins this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.Map binaryData; - private java.util.Map data; + private java.util.Map binaryData; + private java.util.Map data; private java.lang.Boolean immutable; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToBinaryData(java.lang.String key,byte[] value) { - if(this.binaryData == null && key != null && value != null) { this.binaryData = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.binaryData.put(key, value);} return (A)this; + + public A addToBinaryData(java.lang.String key, byte[] value) { + if (this.binaryData == null && key != null && value != null) { + this.binaryData = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.binaryData.put(key, value); + } + return (A) this; } - public A addToBinaryData(java.util.Map map) { - if(this.binaryData == null && map != null) { this.binaryData = new java.util.LinkedHashMap(); } - if(map != null) { this.binaryData.putAll(map);} return (A)this; + + public A addToBinaryData(java.util.Map map) { + if (this.binaryData == null && map != null) { + this.binaryData = new java.util.LinkedHashMap(); + } + if (map != null) { + this.binaryData.putAll(map); + } + return (A) this; } + public A removeFromBinaryData(java.lang.String key) { - if(this.binaryData == null) { return (A) this; } - if(key != null && this.binaryData != null) {this.binaryData.remove(key);} return (A)this; + if (this.binaryData == null) { + return (A) this; + } + if (key != null && this.binaryData != null) { + this.binaryData.remove(key); + } + return (A) this; } - public A removeFromBinaryData(java.util.Map map) { - if(this.binaryData == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.binaryData != null){this.binaryData.remove(key);}}} return (A)this; + + public A removeFromBinaryData(java.util.Map map) { + if (this.binaryData == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.binaryData != null) { + this.binaryData.remove(key); + } + } + } + return (A) this; } - public java.util.Map getBinaryData() { + + public java.util.Map getBinaryData() { return this.binaryData; } - public A withBinaryData(java.util.Map binaryData) { - if (binaryData == null) { this.binaryData = null;} else {this.binaryData = new java.util.LinkedHashMap(binaryData);} return (A) this; + + public A withBinaryData(java.util.Map binaryData) { + if (binaryData == null) { + this.binaryData = null; + } else { + this.binaryData = new java.util.LinkedHashMap(binaryData); + } + return (A) this; } + public java.lang.Boolean hasBinaryData() { return this.binaryData != null; } - public A addToData(java.lang.String key,java.lang.String value) { - if(this.data == null && key != null && value != null) { this.data = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.data.put(key, value);} return (A)this; + + public A addToData(java.lang.String key, java.lang.String value) { + if (this.data == null && key != null && value != null) { + this.data = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.data.put(key, value); + } + return (A) this; } - public A addToData(java.util.Map map) { - if(this.data == null && map != null) { this.data = new java.util.LinkedHashMap(); } - if(map != null) { this.data.putAll(map);} return (A)this; + + public A addToData(java.util.Map map) { + if (this.data == null && map != null) { + this.data = new java.util.LinkedHashMap(); + } + if (map != null) { + this.data.putAll(map); + } + return (A) this; } + public A removeFromData(java.lang.String key) { - if(this.data == null) { return (A) this; } - if(key != null && this.data != null) {this.data.remove(key);} return (A)this; + if (this.data == null) { + return (A) this; + } + if (key != null && this.data != null) { + this.data.remove(key); + } + return (A) this; } - public A removeFromData(java.util.Map map) { - if(this.data == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.data != null){this.data.remove(key);}}} return (A)this; + + public A removeFromData(java.util.Map map) { + if (this.data == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.data != null) { + this.data.remove(key); + } + } + } + return (A) this; } - public java.util.Map getData() { + + public java.util.Map getData() { return this.data; } - public A withData(java.util.Map data) { - if (data == null) { this.data = null;} else {this.data = new java.util.LinkedHashMap(data);} return (A) this; + + public A withData(java.util.Map data) { + if (data == null) { + this.data = null; + } else { + this.data = new java.util.LinkedHashMap(data); + } + return (A) this; } + public java.lang.Boolean hasData() { return this.data != null; } + public java.lang.Boolean getImmutable() { return this.immutable; } + public A withImmutable(java.lang.Boolean immutable) { - this.immutable=immutable; return (A) this; + this.immutable = immutable; + return (A) this; } + public java.lang.Boolean hasImmutable() { return this.immutable != null; } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1ConfigMapFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1ConfigMapFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ConfigMapFluentImpl that = (V1ConfigMapFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (binaryData != null ? !binaryData.equals(that.binaryData) :that.binaryData != null) return false; - if (data != null ? !data.equals(that.data) :that.data != null) return false; - if (immutable != null ? !immutable.equals(that.immutable) :that.immutable != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (binaryData != null ? !binaryData.equals(that.binaryData) : that.binaryData != null) + return false; + if (data != null ? !data.equals(that.data) : that.data != null) return false; + if (immutable != null ? !immutable.equals(that.immutable) : that.immutable != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, binaryData, data, immutable, kind, metadata, super.hashCode()); + return java.util.Objects.hash( + apiVersion, binaryData, data, immutable, kind, metadata, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ConfigMapFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1ConfigMapFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapKeySelectorBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapKeySelectorBuilder.java index 11a3d0e919..256226b4f5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapKeySelectorBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapKeySelectorBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ConfigMapKeySelectorBuilder extends io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ConfigMapKeySelectorBuilder + extends io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluentImpl< + io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ConfigMapKeySelector, + io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorBuilder> { public V1ConfigMapKeySelectorBuilder() { this(false); } + public V1ConfigMapKeySelectorBuilder(java.lang.Boolean validationEnabled) { this(new V1ConfigMapKeySelector(), validationEnabled); } - public V1ConfigMapKeySelectorBuilder(io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent fluent) { + + public V1ConfigMapKeySelectorBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent fluent) { this(fluent, false); } - public V1ConfigMapKeySelectorBuilder(io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ConfigMapKeySelectorBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ConfigMapKeySelector(), validationEnabled); } - public V1ConfigMapKeySelectorBuilder(io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMapKeySelector instance) { + + public V1ConfigMapKeySelectorBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMapKeySelector instance) { this(fluent, instance, false); } - public V1ConfigMapKeySelectorBuilder(io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMapKeySelector instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ConfigMapKeySelectorBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMapKeySelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withKey(instance.getKey()); fluent.withName(instance.getName()); fluent.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ConfigMapKeySelectorBuilder(io.kubernetes.client.openapi.models.V1ConfigMapKeySelector instance) { - this(instance,false); + + public V1ConfigMapKeySelectorBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapKeySelector instance) { + this(instance, false); } - public V1ConfigMapKeySelectorBuilder(io.kubernetes.client.openapi.models.V1ConfigMapKeySelector instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ConfigMapKeySelectorBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapKeySelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withKey(instance.getKey()); this.withName(instance.getName()); this.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ConfigMapKeySelector build() { V1ConfigMapKeySelector buildable = new V1ConfigMapKeySelector(); buildable.setKey(fluent.getKey()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1ConfigMapKeySelector build() { buildable.setOptional(fluent.getOptional()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ConfigMapKeySelectorBuilder that = (V1ConfigMapKeySelectorBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapKeySelectorFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapKeySelectorFluent.java index 4ed2b9422f..a727276e7e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapKeySelectorFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapKeySelectorFluent.java @@ -1,35 +1,44 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ConfigMapKeySelectorFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ConfigMapKeySelectorFluent< + A extends io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getKey(); + public A withKey(java.lang.String key); + public java.lang.Boolean hasKey(); - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Boolean getOptional(); + public A withOptional(java.lang.Boolean optional); + public java.lang.Boolean hasOptional(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapKeySelectorFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapKeySelectorFluentImpl.java index 879cea938e..cfac996f87 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapKeySelectorFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapKeySelectorFluentImpl.java @@ -1,82 +1,99 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1ConfigMapKeySelectorFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent{ - public V1ConfigMapKeySelectorFluentImpl() { - } - public V1ConfigMapKeySelectorFluentImpl(io.kubernetes.client.openapi.models.V1ConfigMapKeySelector instance) { +/** Generated */ +public class V1ConfigMapKeySelectorFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent { + public V1ConfigMapKeySelectorFluentImpl() {} + + public V1ConfigMapKeySelectorFluentImpl( + io.kubernetes.client.openapi.models.V1ConfigMapKeySelector instance) { this.withKey(instance.getKey()); this.withName(instance.getName()); this.withOptional(instance.getOptional()); - } + private java.lang.String key; private java.lang.String name; private java.lang.Boolean optional; + public java.lang.String getKey() { return this.key; } + public A withKey(java.lang.String key) { - this.key=key; return (A) this; + this.key = key; + return (A) this; } + public java.lang.Boolean hasKey() { return this.key != null; } - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original) { - return (A)withKey(new String(original)); + return (A) withKey(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Boolean getOptional() { return this.optional; } + public A withOptional(java.lang.Boolean optional) { - this.optional=optional; return (A) this; + this.optional = optional; + return (A) this; } + public java.lang.Boolean hasOptional() { return this.optional != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ConfigMapKeySelectorFluentImpl that = (V1ConfigMapKeySelectorFluentImpl) o; - if (key != null ? !key.equals(that.key) :that.key != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (optional != null ? !optional.equals(that.optional) :that.optional != null) return false; + if (key != null ? !key.equals(that.key) : that.key != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (optional != null ? !optional.equals(that.optional) : that.optional != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(key, name, optional, super.hashCode()); + return java.util.Objects.hash(key, name, optional, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapListBuilder.java index 328b873b76..4cb9b22e01 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ConfigMapListBuilder extends io.kubernetes.client.openapi.models.V1ConfigMapListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ConfigMapListBuilder + extends io.kubernetes.client.openapi.models.V1ConfigMapListFluentImpl< + io.kubernetes.client.openapi.models.V1ConfigMapListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ConfigMapList, + io.kubernetes.client.openapi.models.V1ConfigMapListBuilder> { public V1ConfigMapListBuilder() { this(false); } + public V1ConfigMapListBuilder(java.lang.Boolean validationEnabled) { this(new V1ConfigMapList(), validationEnabled); } - public V1ConfigMapListBuilder(io.kubernetes.client.openapi.models.V1ConfigMapListFluent fluent) { + + public V1ConfigMapListBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapListFluent fluent) { this(fluent, false); } - public V1ConfigMapListBuilder(io.kubernetes.client.openapi.models.V1ConfigMapListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ConfigMapListBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ConfigMapList(), validationEnabled); } - public V1ConfigMapListBuilder(io.kubernetes.client.openapi.models.V1ConfigMapListFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMapList instance) { + + public V1ConfigMapListBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapListFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMapList instance) { this(fluent, instance, false); } - public V1ConfigMapListBuilder(io.kubernetes.client.openapi.models.V1ConfigMapListFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMapList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ConfigMapListBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapListFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMapList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1ConfigMapListBuilder(io.kubernetes.client.openapi.models.V1ConfigMapLis fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ConfigMapListBuilder(io.kubernetes.client.openapi.models.V1ConfigMapList instance) { - this(instance,false); + this(instance, false); } - public V1ConfigMapListBuilder(io.kubernetes.client.openapi.models.V1ConfigMapList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ConfigMapListBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1ConfigMapListBuilder(io.kubernetes.client.openapi.models.V1ConfigMapLis this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ConfigMapListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ConfigMapList build() { V1ConfigMapList buildable = new V1ConfigMapList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1ConfigMapList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ConfigMapListBuilder that = (V1ConfigMapListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapListFluent.java index 96c98dae2d..5942cd2675 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapListFluent.java @@ -1,95 +1,153 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ConfigMapListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ConfigMapListFluent< + A extends io.kubernetes.client.openapi.models.V1ConfigMapListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ConfigMap item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ConfigMap item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ConfigMap item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ConfigMap item); + public A addToItems(io.kubernetes.client.openapi.models.V1ConfigMap... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1ConfigMap... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1ConfigMap buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ConfigMap buildFirstItem(); + public io.kubernetes.client.openapi.models.V1ConfigMap buildLastItem(); - public io.kubernetes.client.openapi.models.V1ConfigMap buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ConfigMap buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1ConfigMap... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ConfigMap item); - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ConfigMap item); - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1ConfigMap item); + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ConfigMap item); + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ConfigMapFluent>{ + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ConfigMapFluent< + io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapListFluentImpl.java index 04da515b2e..b44b32c2db 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1ConfigMapListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ConfigMapListFluent{ - public V1ConfigMapListFluentImpl() { - } +/** Generated */ +public class V1ConfigMapListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ConfigMapListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ConfigMapListFluent { + public V1ConfigMapListFluentImpl() {} + public V1ConfigMapListFluentImpl(io.kubernetes.client.openapi.models.V1ConfigMapList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,123 @@ public V1ConfigMapListFluentImpl(io.kubernetes.client.openapi.models.V1ConfigMap this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ConfigMap item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ConfigMapBuilder builder = new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ConfigMap item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ConfigMapBuilder builder = + new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ConfigMap item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ConfigMapBuilder builder = new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ConfigMap item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ConfigMapBuilder builder = + new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1ConfigMap... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ConfigMap item : items) {io.kubernetes.client.openapi.models.V1ConfigMapBuilder builder = new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ConfigMap item : items) { + io.kubernetes.client.openapi.models.V1ConfigMapBuilder builder = + new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ConfigMap item : items) {io.kubernetes.client.openapi.models.V1ConfigMapBuilder builder = new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ConfigMap item : items) { + io.kubernetes.client.openapi.models.V1ConfigMapBuilder builder = + new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1ConfigMap... items) { - for (io.kubernetes.client.openapi.models.V1ConfigMap item : items) {io.kubernetes.client.openapi.models.V1ConfigMapBuilder builder = new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ConfigMap item : items) { + io.kubernetes.client.openapi.models.V1ConfigMapBuilder builder = + new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ConfigMap item : items) {io.kubernetes.client.openapi.models.V1ConfigMapBuilder builder = new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ConfigMap item : items) { + io.kubernetes.client.openapi.models.V1ConfigMapBuilder builder = + new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +157,274 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1ConfigMap buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ConfigMap buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ConfigMap buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ConfigMap buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ConfigMapBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ConfigMap buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ConfigMapBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ConfigMapBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ConfigMapBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ConfigMap item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ConfigMap item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1ConfigMap... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1ConfigMap item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1ConfigMap item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1ConfigMapListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ConfigMap item) { - return new io.kubernetes.client.openapi.models.V1ConfigMapListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1ConfigMap item) { + return new io.kubernetes.client.openapi.models.V1ConfigMapListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ConfigMap item) { - return new io.kubernetes.client.openapi.models.V1ConfigMapListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ConfigMap item) { + return new io.kubernetes.client.openapi.models.V1ConfigMapListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1ConfigMapListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1ConfigMapListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1ConfigMapListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ConfigMapListFluentImpl that = (V1ConfigMapListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1ConfigMapFluentImpl> implements io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ConfigMap item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1ConfigMapFluentImpl< + io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1ConfigMapListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1ConfigMap item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ConfigMapBuilder(this); } + io.kubernetes.client.openapi.models.V1ConfigMapBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ConfigMapListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1ConfigMapListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ConfigMapListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1ConfigMapListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapNodeConfigSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapNodeConfigSourceBuilder.java index d57fa2cd47..7665c91146 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapNodeConfigSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapNodeConfigSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ConfigMapNodeConfigSourceBuilder extends io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ConfigMapNodeConfigSourceBuilder + extends io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluentImpl< + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource, + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceBuilder> { public V1ConfigMapNodeConfigSourceBuilder() { this(false); } + public V1ConfigMapNodeConfigSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1ConfigMapNodeConfigSource(), validationEnabled); } - public V1ConfigMapNodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent fluent) { + + public V1ConfigMapNodeConfigSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent fluent) { this(fluent, false); } - public V1ConfigMapNodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ConfigMapNodeConfigSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ConfigMapNodeConfigSource(), validationEnabled); } - public V1ConfigMapNodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource instance) { + + public V1ConfigMapNodeConfigSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource instance) { this(fluent, instance, false); } - public V1ConfigMapNodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ConfigMapNodeConfigSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withKubeletConfigKey(instance.getKubeletConfigKey()); fluent.withName(instance.getName()); @@ -31,13 +58,18 @@ public V1ConfigMapNodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1 fluent.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ConfigMapNodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource instance) { - this(instance,false); + + public V1ConfigMapNodeConfigSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource instance) { + this(instance, false); } - public V1ConfigMapNodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ConfigMapNodeConfigSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withKubeletConfigKey(instance.getKubeletConfigKey()); this.withName(instance.getName()); @@ -48,10 +80,12 @@ public V1ConfigMapNodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1 this.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource build() { V1ConfigMapNodeConfigSource buildable = new V1ConfigMapNodeConfigSource(); buildable.setKubeletConfigKey(fluent.getKubeletConfigKey()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource build() { buildable.setUid(fluent.getUid()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ConfigMapNodeConfigSourceBuilder that = (V1ConfigMapNodeConfigSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapNodeConfigSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapNodeConfigSourceFluent.java index 95ef7e546a..462139edff 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapNodeConfigSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapNodeConfigSourceFluent.java @@ -1,59 +1,68 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ConfigMapNodeConfigSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ConfigMapNodeConfigSourceFluent< + A extends io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getKubeletConfigKey(); + public A withKubeletConfigKey(java.lang.String kubeletConfigKey); + public java.lang.Boolean hasKubeletConfigKey(); - - /** - * Method is deprecated. use withKubeletConfigKey instead. - */ + + /** Method is deprecated. use withKubeletConfigKey instead. */ @java.lang.Deprecated public A withNewKubeletConfigKey(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getNamespace(); + public A withNamespace(java.lang.String namespace); + public java.lang.Boolean hasNamespace(); - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original); + public java.lang.String getResourceVersion(); + public A withResourceVersion(java.lang.String resourceVersion); + public java.lang.Boolean hasResourceVersion(); - - /** - * Method is deprecated. use withResourceVersion instead. - */ + + /** Method is deprecated. use withResourceVersion instead. */ @java.lang.Deprecated public A withNewResourceVersion(java.lang.String original); + public java.lang.String getUid(); + public A withUid(java.lang.String uid); + public java.lang.Boolean hasUid(); - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapNodeConfigSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapNodeConfigSourceFluentImpl.java index 4659082d01..41a84b8d76 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapNodeConfigSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapNodeConfigSourceFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ConfigMapNodeConfigSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent { + public V1ConfigMapNodeConfigSourceFluentImpl() {} - /** - * Generated - */ -public class V1ConfigMapNodeConfigSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent{ - public V1ConfigMapNodeConfigSourceFluentImpl() { - } - public V1ConfigMapNodeConfigSourceFluentImpl(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource instance) { + public V1ConfigMapNodeConfigSourceFluentImpl( + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource instance) { this.withKubeletConfigKey(instance.getKubeletConfigKey()); this.withName(instance.getName()); @@ -22,111 +30,128 @@ public V1ConfigMapNodeConfigSourceFluentImpl(io.kubernetes.client.openapi.models this.withResourceVersion(instance.getResourceVersion()); this.withUid(instance.getUid()); - } + private java.lang.String kubeletConfigKey; private java.lang.String name; private java.lang.String namespace; private java.lang.String resourceVersion; private java.lang.String uid; + public java.lang.String getKubeletConfigKey() { return this.kubeletConfigKey; } + public A withKubeletConfigKey(java.lang.String kubeletConfigKey) { - this.kubeletConfigKey=kubeletConfigKey; return (A) this; + this.kubeletConfigKey = kubeletConfigKey; + return (A) this; } + public java.lang.Boolean hasKubeletConfigKey() { return this.kubeletConfigKey != null; } - - /** - * Method is deprecated. use withKubeletConfigKey instead. - */ + + /** Method is deprecated. use withKubeletConfigKey instead. */ @java.lang.Deprecated public A withNewKubeletConfigKey(java.lang.String original) { - return (A)withKubeletConfigKey(new String(original)); + return (A) withKubeletConfigKey(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getNamespace() { return this.namespace; } + public A withNamespace(java.lang.String namespace) { - this.namespace=namespace; return (A) this; + this.namespace = namespace; + return (A) this; } + public java.lang.Boolean hasNamespace() { return this.namespace != null; } - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original) { - return (A)withNamespace(new String(original)); + return (A) withNamespace(new String(original)); } + public java.lang.String getResourceVersion() { return this.resourceVersion; } + public A withResourceVersion(java.lang.String resourceVersion) { - this.resourceVersion=resourceVersion; return (A) this; + this.resourceVersion = resourceVersion; + return (A) this; } + public java.lang.Boolean hasResourceVersion() { return this.resourceVersion != null; } - - /** - * Method is deprecated. use withResourceVersion instead. - */ + + /** Method is deprecated. use withResourceVersion instead. */ @java.lang.Deprecated public A withNewResourceVersion(java.lang.String original) { - return (A)withResourceVersion(new String(original)); + return (A) withResourceVersion(new String(original)); } + public java.lang.String getUid() { return this.uid; } + public A withUid(java.lang.String uid) { - this.uid=uid; return (A) this; + this.uid = uid; + return (A) this; } + public java.lang.Boolean hasUid() { return this.uid != null; } - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original) { - return (A)withUid(new String(original)); + return (A) withUid(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ConfigMapNodeConfigSourceFluentImpl that = (V1ConfigMapNodeConfigSourceFluentImpl) o; - if (kubeletConfigKey != null ? !kubeletConfigKey.equals(that.kubeletConfigKey) :that.kubeletConfigKey != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (namespace != null ? !namespace.equals(that.namespace) :that.namespace != null) return false; - if (resourceVersion != null ? !resourceVersion.equals(that.resourceVersion) :that.resourceVersion != null) return false; - if (uid != null ? !uid.equals(that.uid) :that.uid != null) return false; + if (kubeletConfigKey != null + ? !kubeletConfigKey.equals(that.kubeletConfigKey) + : that.kubeletConfigKey != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (namespace != null ? !namespace.equals(that.namespace) : that.namespace != null) + return false; + if (resourceVersion != null + ? !resourceVersion.equals(that.resourceVersion) + : that.resourceVersion != null) return false; + if (uid != null ? !uid.equals(that.uid) : that.uid != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(kubeletConfigKey, name, namespace, resourceVersion, uid, super.hashCode()); + return java.util.Objects.hash( + kubeletConfigKey, name, namespace, resourceVersion, uid, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapProjectionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapProjectionBuilder.java index 35d815dbe6..33ba465542 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapProjectionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapProjectionBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ConfigMapProjectionBuilder extends io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ConfigMapProjectionBuilder + extends io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluentImpl< + io.kubernetes.client.openapi.models.V1ConfigMapProjectionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ConfigMapProjection, + io.kubernetes.client.openapi.models.V1ConfigMapProjectionBuilder> { public V1ConfigMapProjectionBuilder() { this(false); } + public V1ConfigMapProjectionBuilder(java.lang.Boolean validationEnabled) { this(new V1ConfigMapProjection(), validationEnabled); } - public V1ConfigMapProjectionBuilder(io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent fluent) { + + public V1ConfigMapProjectionBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent fluent) { this(fluent, false); } - public V1ConfigMapProjectionBuilder(io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ConfigMapProjectionBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ConfigMapProjection(), validationEnabled); } - public V1ConfigMapProjectionBuilder(io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMapProjection instance) { + + public V1ConfigMapProjectionBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMapProjection instance) { this(fluent, instance, false); } - public V1ConfigMapProjectionBuilder(io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMapProjection instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ConfigMapProjectionBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMapProjection instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withItems(instance.getItems()); fluent.withName(instance.getName()); fluent.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ConfigMapProjectionBuilder(io.kubernetes.client.openapi.models.V1ConfigMapProjection instance) { - this(instance,false); + + public V1ConfigMapProjectionBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapProjection instance) { + this(instance, false); } - public V1ConfigMapProjectionBuilder(io.kubernetes.client.openapi.models.V1ConfigMapProjection instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ConfigMapProjectionBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapProjection instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withItems(instance.getItems()); this.withName(instance.getName()); this.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ConfigMapProjection build() { V1ConfigMapProjection buildable = new V1ConfigMapProjection(); buildable.setItems(fluent.getItems()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1ConfigMapProjection build() { buildable.setOptional(fluent.getOptional()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ConfigMapProjectionBuilder that = (V1ConfigMapProjectionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapProjectionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapProjectionFluent.java index dd23d95fa4..271eb69773 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapProjectionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapProjectionFluent.java @@ -1,69 +1,116 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ConfigMapProjectionFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item); +/** Generated */ +public interface V1ConfigMapProjectionFluent< + A extends io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item); + public A addToItems(io.kubernetes.client.openapi.models.V1KeyToPath... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1KeyToPath... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1KeyToPath buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1KeyToPath buildFirstItem(); + public io.kubernetes.client.openapi.models.V1KeyToPath buildLastItem(); - public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1KeyToPath... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item); - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item); - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item); + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested + setNewItemLike(java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item); + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Boolean getOptional(); + public A withOptional(java.lang.Boolean optional); + public java.lang.Boolean hasOptional(); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1KeyToPathFluent>{ + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1KeyToPathFluent< + io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested> { public N and(); + public N endItem(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapProjectionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapProjectionFluentImpl.java index 15d07962f8..dde5fb1485 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapProjectionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapProjectionFluentImpl.java @@ -1,62 +1,131 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1ConfigMapProjectionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent{ - public V1ConfigMapProjectionFluentImpl() { - } - public V1ConfigMapProjectionFluentImpl(io.kubernetes.client.openapi.models.V1ConfigMapProjection instance) { +/** Generated */ +public class V1ConfigMapProjectionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent { + public V1ConfigMapProjectionFluentImpl() {} + + public V1ConfigMapProjectionFluentImpl( + io.kubernetes.client.openapi.models.V1ConfigMapProjection instance) { this.withItems(instance.getItems()); this.withName(instance.getName()); this.withOptional(instance.getOptional()); - } + private java.util.ArrayList items; private java.lang.String name; private java.lang.Boolean optional; - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1KeyToPath... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1KeyToPath... items) { - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -67,132 +136,211 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1KeyToPath buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1KeyToPath buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1KeyToPath buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1KeyToPath item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1KeyToPath... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1KeyToPath item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item) { - return new io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item) { + return new io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { - return new io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { + return new io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1KeyToPathFluentImpl> implements io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1KeyToPathFluentImpl< + io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(this); } + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ConfigMapProjectionFluentImpl.this.setToItems(index,builder.build()); + return (N) V1ConfigMapProjectionFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapVolumeSourceBuilder.java index 3a71858806..d71b05f2e7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ConfigMapVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ConfigMapVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource, + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceBuilder> { public V1ConfigMapVolumeSourceBuilder() { this(false); } + public V1ConfigMapVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1ConfigMapVolumeSource(), validationEnabled); } - public V1ConfigMapVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent fluent) { + + public V1ConfigMapVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent fluent) { this(fluent, false); } - public V1ConfigMapVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ConfigMapVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ConfigMapVolumeSource(), validationEnabled); } - public V1ConfigMapVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource instance) { + + public V1ConfigMapVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource instance) { this(fluent, instance, false); } - public V1ConfigMapVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ConfigMapVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDefaultMode(instance.getDefaultMode()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1ConfigMapVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1Conf fluent.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ConfigMapVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource instance) { - this(instance,false); + + public V1ConfigMapVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource instance) { + this(instance, false); } - public V1ConfigMapVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ConfigMapVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDefaultMode(instance.getDefaultMode()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1ConfigMapVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1Conf this.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource build() { V1ConfigMapVolumeSource buildable = new V1ConfigMapVolumeSource(); buildable.setDefaultMode(fluent.getDefaultMode()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource build() { buildable.setOptional(fluent.getOptional()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ConfigMapVolumeSourceBuilder that = (V1ConfigMapVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapVolumeSourceFluent.java index b18935c6fe..0d228dfe44 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapVolumeSourceFluent.java @@ -1,72 +1,122 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ConfigMapVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ConfigMapVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getDefaultMode(); + public A withDefaultMode(java.lang.Integer defaultMode); + public java.lang.Boolean hasDefaultMode(); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item); + public A addToItems(io.kubernetes.client.openapi.models.V1KeyToPath... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1KeyToPath... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1KeyToPath buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1KeyToPath buildFirstItem(); + public io.kubernetes.client.openapi.models.V1KeyToPath buildLastItem(); - public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1KeyToPath... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item); - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item); - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item); + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested + setNewItemLike(java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item); + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Boolean getOptional(); + public A withOptional(java.lang.Boolean optional); + public java.lang.Boolean hasOptional(); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1KeyToPathFluent>{ + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1KeyToPathFluent< + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested> { public N and(); + public N endItem(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapVolumeSourceFluentImpl.java index 35c4258d04..a642d4fcc2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ConfigMapVolumeSourceFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1ConfigMapVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent{ - public V1ConfigMapVolumeSourceFluentImpl() { - } - public V1ConfigMapVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource instance) { +/** Generated */ +public class V1ConfigMapVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent { + public V1ConfigMapVolumeSourceFluentImpl() {} + + public V1ConfigMapVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource instance) { this.withDefaultMode(instance.getDefaultMode()); this.withItems(instance.getItems()); @@ -28,47 +31,117 @@ public V1ConfigMapVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1C this.withName(instance.getName()); this.withOptional(instance.getOptional()); - } + private java.lang.Integer defaultMode; private java.util.ArrayList items; private java.lang.String name; private java.lang.Boolean optional; + public java.lang.Integer getDefaultMode() { return this.defaultMode; } + public A withDefaultMode(java.lang.Integer defaultMode) { - this.defaultMode=defaultMode; return (A) this; + this.defaultMode = defaultMode; + return (A) this; } + public java.lang.Boolean hasDefaultMode() { return this.defaultMode != null; } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1KeyToPath... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1KeyToPath... items) { - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -79,133 +152,213 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1KeyToPath buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1KeyToPath buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1KeyToPath buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1KeyToPath item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1KeyToPath... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1KeyToPath item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item) { - return new io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item) { + return new io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { - return new io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { + return new io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1KeyToPathFluentImpl> implements io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1KeyToPathFluentImpl< + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(this); } + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ConfigMapVolumeSourceFluentImpl.this.setToItems(index,builder.build()); + return (N) V1ConfigMapVolumeSourceFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerBuilder.java index 83c198aa63..b248060c49 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ContainerBuilder extends io.kubernetes.client.openapi.models.V1ContainerFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ContainerBuilder + extends io.kubernetes.client.openapi.models.V1ContainerFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Container, + io.kubernetes.client.openapi.models.V1ContainerBuilder> { public V1ContainerBuilder() { this(false); } + public V1ContainerBuilder(java.lang.Boolean validationEnabled) { this(new V1Container(), validationEnabled); } + public V1ContainerBuilder(io.kubernetes.client.openapi.models.V1ContainerFluent fluent) { this(fluent, false); } - public V1ContainerBuilder(io.kubernetes.client.openapi.models.V1ContainerFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ContainerBuilder( + io.kubernetes.client.openapi.models.V1ContainerFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Container(), validationEnabled); } - public V1ContainerBuilder(io.kubernetes.client.openapi.models.V1ContainerFluent fluent,io.kubernetes.client.openapi.models.V1Container instance) { + + public V1ContainerBuilder( + io.kubernetes.client.openapi.models.V1ContainerFluent fluent, + io.kubernetes.client.openapi.models.V1Container instance) { this(fluent, instance, false); } - public V1ContainerBuilder(io.kubernetes.client.openapi.models.V1ContainerFluent fluent,io.kubernetes.client.openapi.models.V1Container instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ContainerBuilder( + io.kubernetes.client.openapi.models.V1ContainerFluent fluent, + io.kubernetes.client.openapi.models.V1Container instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withArgs(instance.getArgs()); fluent.withCommand(instance.getCommand()); @@ -65,13 +91,17 @@ public V1ContainerBuilder(io.kubernetes.client.openapi.models.V1ContainerFluent< fluent.withWorkingDir(instance.getWorkingDir()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ContainerBuilder(io.kubernetes.client.openapi.models.V1Container instance) { - this(instance,false); + this(instance, false); } - public V1ContainerBuilder(io.kubernetes.client.openapi.models.V1Container instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ContainerBuilder( + io.kubernetes.client.openapi.models.V1Container instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withArgs(instance.getArgs()); this.withCommand(instance.getCommand()); @@ -116,10 +146,12 @@ public V1ContainerBuilder(io.kubernetes.client.openapi.models.V1Container instan this.withWorkingDir(instance.getWorkingDir()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ContainerFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Container build() { V1Container buildable = new V1Container(); buildable.setArgs(fluent.getArgs()); @@ -146,18 +178,23 @@ public io.kubernetes.client.openapi.models.V1Container build() { buildable.setWorkingDir(fluent.getWorkingDir()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ContainerBuilder that = (V1ContainerBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerFluent.java index 8b51d3aae8..499b530617 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerFluent.java @@ -1,400 +1,782 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.util.Collection; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import java.util.Iterator; -import java.lang.Integer; - - /** - * Generated - */ -public interface V1ContainerFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToArgs(java.lang.Integer index,java.lang.String item); - public A setToArgs(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1ContainerFluent< + A extends io.kubernetes.client.openapi.models.V1ContainerFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToArgs(java.lang.Integer index, java.lang.String item); + + public A setToArgs(java.lang.Integer index, java.lang.String item); + public A addToArgs(java.lang.String... items); + public A addAllToArgs(java.util.Collection items); + public A removeFromArgs(java.lang.String... items); + public A removeAllFromArgs(java.util.Collection items); + public java.util.List getArgs(); + public java.lang.String getArg(java.lang.Integer index); + public java.lang.String getFirstArg(); + public java.lang.String getLastArg(); + public java.lang.String getMatchingArg(java.util.function.Predicate predicate); + public java.lang.Boolean hasMatchingArg(java.util.function.Predicate predicate); + public A withArgs(java.util.List args); + public A withArgs(java.lang.String... args); + public java.lang.Boolean hasArgs(); + public A addNewArg(java.lang.String original); - public A addToCommand(java.lang.Integer index,java.lang.String item); - public A setToCommand(java.lang.Integer index,java.lang.String item); + + public A addToCommand(java.lang.Integer index, java.lang.String item); + + public A setToCommand(java.lang.Integer index, java.lang.String item); + public A addToCommand(java.lang.String... items); + public A addAllToCommand(java.util.Collection items); + public A removeFromCommand(java.lang.String... items); + public A removeAllFromCommand(java.util.Collection items); + public java.util.List getCommand(); + public java.lang.String getCommand(java.lang.Integer index); + public java.lang.String getFirstCommand(); + public java.lang.String getLastCommand(); - public java.lang.String getMatchingCommand(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCommand(java.util.function.Predicate predicate); + + public java.lang.String getMatchingCommand( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingCommand( + java.util.function.Predicate predicate); + public A withCommand(java.util.List command); + public A withCommand(java.lang.String... command); + public java.lang.Boolean hasCommand(); + public A addNewCommand(java.lang.String original); - public A addToEnv(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item); - public A setToEnv(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item); + + public A addToEnv(java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item); + + public A setToEnv(java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item); + public A addToEnv(io.kubernetes.client.openapi.models.V1EnvVar... items); + public A addAllToEnv(java.util.Collection items); + public A removeFromEnv(io.kubernetes.client.openapi.models.V1EnvVar... items); - public A removeAllFromEnv(java.util.Collection items); - public A removeMatchingFromEnv(java.util.function.Predicate predicate); - + + public A removeAllFromEnv( + java.util.Collection items); + + public A removeMatchingFromEnv( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildEnv instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getEnv(); + public java.util.List buildEnv(); + public io.kubernetes.client.openapi.models.V1EnvVar buildEnv(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EnvVar buildFirstEnv(); + public io.kubernetes.client.openapi.models.V1EnvVar buildLastEnv(); - public io.kubernetes.client.openapi.models.V1EnvVar buildMatchingEnv(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingEnv(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1EnvVar buildMatchingEnv( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingEnv( + java.util.function.Predicate predicate); + public A withEnv(java.util.List env); + public A withEnv(io.kubernetes.client.openapi.models.V1EnvVar... env); + public java.lang.Boolean hasEnv(); + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested addNewEnv(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested addNewEnvLike(io.kubernetes.client.openapi.models.V1EnvVar item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested setNewEnvLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested editEnv(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested addNewEnvLike( + io.kubernetes.client.openapi.models.V1EnvVar item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested setNewEnvLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested editEnv( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested editFirstEnv(); + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested editLastEnv(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested editMatchingEnv(java.util.function.Predicate predicate); - public A addToEnvFrom(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvFromSource item); - public A setToEnvFrom(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvFromSource item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested editMatchingEnv( + java.util.function.Predicate predicate); + + public A addToEnvFrom( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item); + + public A setToEnvFrom( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item); + public A addToEnvFrom(io.kubernetes.client.openapi.models.V1EnvFromSource... items); - public A addAllToEnvFrom(java.util.Collection items); + + public A addAllToEnvFrom( + java.util.Collection items); + public A removeFromEnvFrom(io.kubernetes.client.openapi.models.V1EnvFromSource... items); - public A removeAllFromEnvFrom(java.util.Collection items); - public A removeMatchingFromEnvFrom(java.util.function.Predicate predicate); - + + public A removeAllFromEnvFrom( + java.util.Collection items); + + public A removeMatchingFromEnvFrom( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildEnvFrom instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getEnvFrom(); + public java.util.List buildEnvFrom(); + public io.kubernetes.client.openapi.models.V1EnvFromSource buildEnvFrom(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EnvFromSource buildFirstEnvFrom(); + public io.kubernetes.client.openapi.models.V1EnvFromSource buildLastEnvFrom(); - public io.kubernetes.client.openapi.models.V1EnvFromSource buildMatchingEnvFrom(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingEnvFrom(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1EnvFromSource buildMatchingEnvFrom( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingEnvFrom( + java.util.function.Predicate + predicate); + public A withEnvFrom(java.util.List envFrom); + public A withEnvFrom(io.kubernetes.client.openapi.models.V1EnvFromSource... envFrom); + public java.lang.Boolean hasEnvFrom(); + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested addNewEnvFrom(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested addNewEnvFromLike(io.kubernetes.client.openapi.models.V1EnvFromSource item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested setNewEnvFromLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvFromSource item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested editEnvFrom(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested addNewEnvFromLike( + io.kubernetes.client.openapi.models.V1EnvFromSource item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested setNewEnvFromLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested editEnvFrom( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested editFirstEnvFrom(); + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested editLastEnvFrom(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested editMatchingEnvFrom(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested editMatchingEnvFrom( + java.util.function.Predicate + predicate); + public java.lang.String getImage(); + public A withImage(java.lang.String image); + public java.lang.Boolean hasImage(); - - /** - * Method is deprecated. use withImage instead. - */ + + /** Method is deprecated. use withImage instead. */ @java.lang.Deprecated public A withNewImage(java.lang.String original); + public io.kubernetes.client.openapi.models.V1Container.ImagePullPolicyEnum getImagePullPolicy(); - public A withImagePullPolicy(io.kubernetes.client.openapi.models.V1Container.ImagePullPolicyEnum imagePullPolicy); + + public A withImagePullPolicy( + io.kubernetes.client.openapi.models.V1Container.ImagePullPolicyEnum imagePullPolicy); + public java.lang.Boolean hasImagePullPolicy(); - + /** * This method has been deprecated, please use method buildLifecycle instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Lifecycle getLifecycle(); + public io.kubernetes.client.openapi.models.V1Lifecycle buildLifecycle(); + public A withLifecycle(io.kubernetes.client.openapi.models.V1Lifecycle lifecycle); + public java.lang.Boolean hasLifecycle(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested withNewLifecycle(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested withNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested + withNewLifecycle(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested + withNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item); + public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested editLifecycle(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested editOrNewLifecycle(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested editOrNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item); - + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested + editOrNewLifecycle(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested + editOrNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item); + /** * This method has been deprecated, please use method buildLivenessProbe instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Probe getLivenessProbe(); + public io.kubernetes.client.openapi.models.V1Probe buildLivenessProbe(); + public A withLivenessProbe(io.kubernetes.client.openapi.models.V1Probe livenessProbe); + public java.lang.Boolean hasLivenessProbe(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested withNewLivenessProbe(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested withNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested editLivenessProbe(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested editOrNewLivenessProbe(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested editOrNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested + withNewLivenessProbe(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested + withNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested + editLivenessProbe(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested + editOrNewLivenessProbe(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested + editOrNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item); - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item); + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item); + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item); + public A addToPorts(io.kubernetes.client.openapi.models.V1ContainerPort... items); - public A addAllToPorts(java.util.Collection items); + + public A addAllToPorts( + java.util.Collection items); + public A removeFromPorts(io.kubernetes.client.openapi.models.V1ContainerPort... items); - public A removeAllFromPorts(java.util.Collection items); - public A removeMatchingFromPorts(java.util.function.Predicate predicate); - + + public A removeAllFromPorts( + java.util.Collection items); + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildPorts instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getPorts(); + public java.util.List buildPorts(); + public io.kubernetes.client.openapi.models.V1ContainerPort buildPort(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ContainerPort buildFirstPort(); + public io.kubernetes.client.openapi.models.V1ContainerPort buildLastPort(); - public io.kubernetes.client.openapi.models.V1ContainerPort buildMatchingPort(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ContainerPort buildMatchingPort( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate); + public A withPorts(java.util.List ports); + public A withPorts(io.kubernetes.client.openapi.models.V1ContainerPort... ports); + public java.lang.Boolean hasPorts(); + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested addNewPort(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1ContainerPort item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested editPort(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested addNewPortLike( + io.kubernetes.client.openapi.models.V1ContainerPort item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested editPort( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested editFirstPort(); + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested editLastPort(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested editMatchingPort( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildReadinessProbe instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Probe getReadinessProbe(); + public io.kubernetes.client.openapi.models.V1Probe buildReadinessProbe(); + public A withReadinessProbe(io.kubernetes.client.openapi.models.V1Probe readinessProbe); + public java.lang.Boolean hasReadinessProbe(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested withNewReadinessProbe(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested withNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested editReadinessProbe(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested editOrNewReadinessProbe(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested editOrNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); - + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested + withNewReadinessProbe(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested + withNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested + editReadinessProbe(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested + editOrNewReadinessProbe(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested + editOrNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + /** * This method has been deprecated, please use method buildResources instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceRequirements getResources(); + public io.kubernetes.client.openapi.models.V1ResourceRequirements buildResources(); + public A withResources(io.kubernetes.client.openapi.models.V1ResourceRequirements resources); + public java.lang.Boolean hasResources(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested withNewResources(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested withNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested + withNewResources(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested + withNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item); + public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested editResources(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested editOrNewResources(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested editOrNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item); - + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested + editOrNewResources(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested + editOrNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item); + /** * This method has been deprecated, please use method buildSecurityContext instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecurityContext getSecurityContext(); + public io.kubernetes.client.openapi.models.V1SecurityContext buildSecurityContext(); - public A withSecurityContext(io.kubernetes.client.openapi.models.V1SecurityContext securityContext); + + public A withSecurityContext( + io.kubernetes.client.openapi.models.V1SecurityContext securityContext); + public java.lang.Boolean hasSecurityContext(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested withNewSecurityContext(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested withNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested editSecurityContext(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested editOrNewSecurityContext(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested editOrNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item); - + + public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested + withNewSecurityContext(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested + withNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested + editSecurityContext(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested + editOrNewSecurityContext(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested + editOrNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item); + /** * This method has been deprecated, please use method buildStartupProbe instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Probe getStartupProbe(); + public io.kubernetes.client.openapi.models.V1Probe buildStartupProbe(); + public A withStartupProbe(io.kubernetes.client.openapi.models.V1Probe startupProbe); + public java.lang.Boolean hasStartupProbe(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested withNewStartupProbe(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested withNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested editStartupProbe(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested editOrNewStartupProbe(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested editOrNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested + withNewStartupProbe(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested + withNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested + editStartupProbe(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested + editOrNewStartupProbe(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested + editOrNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + public java.lang.Boolean getStdin(); + public A withStdin(java.lang.Boolean stdin); + public java.lang.Boolean hasStdin(); + public java.lang.Boolean getStdinOnce(); + public A withStdinOnce(java.lang.Boolean stdinOnce); + public java.lang.Boolean hasStdinOnce(); + public java.lang.String getTerminationMessagePath(); + public A withTerminationMessagePath(java.lang.String terminationMessagePath); + public java.lang.Boolean hasTerminationMessagePath(); - - /** - * Method is deprecated. use withTerminationMessagePath instead. - */ + + /** Method is deprecated. use withTerminationMessagePath instead. */ @java.lang.Deprecated public A withNewTerminationMessagePath(java.lang.String original); - public io.kubernetes.client.openapi.models.V1Container.TerminationMessagePolicyEnum getTerminationMessagePolicy(); - public A withTerminationMessagePolicy(io.kubernetes.client.openapi.models.V1Container.TerminationMessagePolicyEnum terminationMessagePolicy); + + public io.kubernetes.client.openapi.models.V1Container.TerminationMessagePolicyEnum + getTerminationMessagePolicy(); + + public A withTerminationMessagePolicy( + io.kubernetes.client.openapi.models.V1Container.TerminationMessagePolicyEnum + terminationMessagePolicy); + public java.lang.Boolean hasTerminationMessagePolicy(); + public java.lang.Boolean getTty(); + public A withTty(java.lang.Boolean tty); + public java.lang.Boolean hasTty(); - public A addToVolumeDevices(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item); - public A setToVolumeDevices(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item); + + public A addToVolumeDevices( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item); + + public A setToVolumeDevices( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item); + public A addToVolumeDevices(io.kubernetes.client.openapi.models.V1VolumeDevice... items); - public A addAllToVolumeDevices(java.util.Collection items); + + public A addAllToVolumeDevices( + java.util.Collection items); + public A removeFromVolumeDevices(io.kubernetes.client.openapi.models.V1VolumeDevice... items); - public A removeAllFromVolumeDevices(java.util.Collection items); - public A removeMatchingFromVolumeDevices(java.util.function.Predicate predicate); - + + public A removeAllFromVolumeDevices( + java.util.Collection items); + + public A removeMatchingFromVolumeDevices( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildVolumeDevices instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getVolumeDevices(); + public java.util.List buildVolumeDevices(); - public io.kubernetes.client.openapi.models.V1VolumeDevice buildVolumeDevice(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1VolumeDevice buildVolumeDevice( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1VolumeDevice buildFirstVolumeDevice(); + public io.kubernetes.client.openapi.models.V1VolumeDevice buildLastVolumeDevice(); - public io.kubernetes.client.openapi.models.V1VolumeDevice buildMatchingVolumeDevice(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVolumeDevice(java.util.function.Predicate predicate); - public A withVolumeDevices(java.util.List volumeDevices); + + public io.kubernetes.client.openapi.models.V1VolumeDevice buildMatchingVolumeDevice( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingVolumeDevice( + java.util.function.Predicate + predicate); + + public A withVolumeDevices( + java.util.List volumeDevices); + public A withVolumeDevices(io.kubernetes.client.openapi.models.V1VolumeDevice... volumeDevices); + public java.lang.Boolean hasVolumeDevices(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested addNewVolumeDevice(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested addNewVolumeDeviceLike(io.kubernetes.client.openapi.models.V1VolumeDevice item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested setNewVolumeDeviceLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested editVolumeDevice(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested editFirstVolumeDevice(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested editLastVolumeDevice(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested editMatchingVolumeDevice(java.util.function.Predicate predicate); - public A addToVolumeMounts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeMount item); - public A setToVolumeMounts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeMount item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + addNewVolumeDevice(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + addNewVolumeDeviceLike(io.kubernetes.client.openapi.models.V1VolumeDevice item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + setNewVolumeDeviceLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + editVolumeDevice(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + editFirstVolumeDevice(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + editLastVolumeDevice(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + editMatchingVolumeDevice( + java.util.function.Predicate + predicate); + + public A addToVolumeMounts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item); + + public A setToVolumeMounts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item); + public A addToVolumeMounts(io.kubernetes.client.openapi.models.V1VolumeMount... items); - public A addAllToVolumeMounts(java.util.Collection items); + + public A addAllToVolumeMounts( + java.util.Collection items); + public A removeFromVolumeMounts(io.kubernetes.client.openapi.models.V1VolumeMount... items); - public A removeAllFromVolumeMounts(java.util.Collection items); - public A removeMatchingFromVolumeMounts(java.util.function.Predicate predicate); - + + public A removeAllFromVolumeMounts( + java.util.Collection items); + + public A removeMatchingFromVolumeMounts( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildVolumeMounts instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getVolumeMounts(); + public java.util.List buildVolumeMounts(); - public io.kubernetes.client.openapi.models.V1VolumeMount buildVolumeMount(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1VolumeMount buildVolumeMount( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1VolumeMount buildFirstVolumeMount(); + public io.kubernetes.client.openapi.models.V1VolumeMount buildLastVolumeMount(); - public io.kubernetes.client.openapi.models.V1VolumeMount buildMatchingVolumeMount(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVolumeMount(java.util.function.Predicate predicate); - public A withVolumeMounts(java.util.List volumeMounts); + + public io.kubernetes.client.openapi.models.V1VolumeMount buildMatchingVolumeMount( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingVolumeMount( + java.util.function.Predicate + predicate); + + public A withVolumeMounts( + java.util.List volumeMounts); + public A withVolumeMounts(io.kubernetes.client.openapi.models.V1VolumeMount... volumeMounts); + public java.lang.Boolean hasVolumeMounts(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested addNewVolumeMount(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested addNewVolumeMountLike(io.kubernetes.client.openapi.models.V1VolumeMount item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested setNewVolumeMountLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeMount item); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested editVolumeMount(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested editFirstVolumeMount(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested editLastVolumeMount(); - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested editMatchingVolumeMount(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + addNewVolumeMount(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + addNewVolumeMountLike(io.kubernetes.client.openapi.models.V1VolumeMount item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + setNewVolumeMountLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + editVolumeMount(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + editFirstVolumeMount(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + editLastVolumeMount(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + editMatchingVolumeMount( + java.util.function.Predicate + predicate); + public java.lang.String getWorkingDir(); + public A withWorkingDir(java.lang.String workingDir); + public java.lang.Boolean hasWorkingDir(); - - /** - * Method is deprecated. use withWorkingDir instead. - */ + + /** Method is deprecated. use withWorkingDir instead. */ @java.lang.Deprecated public A withNewWorkingDir(java.lang.String original); - public interface EnvNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EnvVarFluent>{ + + public interface EnvNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EnvVarFluent< + io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested> { public N and(); + public N endEnv(); - } - public interface EnvFromNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EnvFromSourceFluent>{ + + public interface EnvFromNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EnvFromSourceFluent< + io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested> { public N and(); + public N endEnvFrom(); - } - public interface LifecycleNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LifecycleFluent>{ + + public interface LifecycleNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LifecycleFluent< + io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested> { public N and(); + public N endLifecycle(); - } - public interface LivenessProbeNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ProbeFluent>{ + + public interface LivenessProbeNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ProbeFluent< + io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested> { public N and(); + public N endLivenessProbe(); - } - public interface PortsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ContainerPortFluent>{ + + public interface PortsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ContainerPortFluent< + io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested> { public N and(); + public N endPort(); - } - public interface ReadinessProbeNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ProbeFluent>{ + + public interface ReadinessProbeNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ProbeFluent< + io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested> { public N and(); + public N endReadinessProbe(); - } - public interface ResourcesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent>{ + + public interface ResourcesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent< + io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested> { public N and(); + public N endResources(); - } - public interface SecurityContextNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecurityContextFluent>{ + + public interface SecurityContextNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecurityContextFluent< + io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested> { public N and(); + public N endSecurityContext(); - } - public interface StartupProbeNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ProbeFluent>{ + + public interface StartupProbeNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ProbeFluent< + io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested> { public N and(); + public N endStartupProbe(); - } - public interface VolumeDevicesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeDeviceFluent>{ + + public interface VolumeDevicesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeDeviceFluent< + io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested> { public N and(); + public N endVolumeDevice(); - } - public interface VolumeMountsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeMountFluent>{ + + public interface VolumeMountsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeMountFluent< + io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested> { public N and(); + public N endVolumeMount(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerFluentImpl.java index 90a67d0ba1..7eba3fafbc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.List; -import java.lang.Boolean; -import java.util.Collection; -import java.lang.Object; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; import java.util.Iterator; -import java.lang.Integer; +import java.util.List; + +/** Generated */ +public class V1ContainerFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ContainerFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ContainerFluent { + public V1ContainerFluentImpl() {} - /** - * Generated - */ -public class V1ContainerFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ContainerFluent{ - public V1ContainerFluentImpl() { - } public V1ContainerFluentImpl(io.kubernetes.client.openapi.models.V1Container instance) { this.withArgs(instance.getArgs()); @@ -64,8 +66,8 @@ public V1ContainerFluentImpl(io.kubernetes.client.openapi.models.V1Container ins this.withVolumeMounts(instance.getVolumeMounts()); this.withWorkingDir(instance.getWorkingDir()); - } + private java.util.List args; private java.util.List command; private java.util.ArrayList env; @@ -83,145 +85,341 @@ public V1ContainerFluentImpl(io.kubernetes.client.openapi.models.V1Container ins private java.lang.Boolean stdin; private java.lang.Boolean stdinOnce; private java.lang.String terminationMessagePath; - private io.kubernetes.client.openapi.models.V1Container.TerminationMessagePolicyEnum terminationMessagePolicy; + private io.kubernetes.client.openapi.models.V1Container.TerminationMessagePolicyEnum + terminationMessagePolicy; private java.lang.Boolean tty; - private java.util.ArrayList volumeDevices; - private java.util.ArrayList volumeMounts; + private java.util.ArrayList + volumeDevices; + private java.util.ArrayList + volumeMounts; private java.lang.String workingDir; - public A addToArgs(java.lang.Integer index,java.lang.String item) { - if (this.args == null) {this.args = new java.util.ArrayList();} + + public A addToArgs(java.lang.Integer index, java.lang.String item) { + if (this.args == null) { + this.args = new java.util.ArrayList(); + } this.args.add(index, item); - return (A)this; + return (A) this; } - public A setToArgs(java.lang.Integer index,java.lang.String item) { - if (this.args == null) {this.args = new java.util.ArrayList();} - this.args.set(index, item); return (A)this; + + public A setToArgs(java.lang.Integer index, java.lang.String item) { + if (this.args == null) { + this.args = new java.util.ArrayList(); + } + this.args.set(index, item); + return (A) this; } + public A addToArgs(java.lang.String... items) { - if (this.args == null) {this.args = new java.util.ArrayList();} - for (java.lang.String item : items) {this.args.add(item);} return (A)this; + if (this.args == null) { + this.args = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.args.add(item); + } + return (A) this; } + public A addAllToArgs(java.util.Collection items) { - if (this.args == null) {this.args = new java.util.ArrayList();} - for (java.lang.String item : items) {this.args.add(item);} return (A)this; + if (this.args == null) { + this.args = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.args.add(item); + } + return (A) this; } + public A removeFromArgs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.args!= null){ this.args.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.args != null) { + this.args.remove(item); + } + } + return (A) this; } + public A removeAllFromArgs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.args!= null){ this.args.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.args != null) { + this.args.remove(item); + } + } + return (A) this; } + public java.util.List getArgs() { return this.args; } + public java.lang.String getArg(java.lang.Integer index) { return this.args.get(index); } + public java.lang.String getFirstArg() { return this.args.get(0); } + public java.lang.String getLastArg() { return this.args.get(args.size() - 1); } + public java.lang.String getMatchingArg(java.util.function.Predicate predicate) { - for (java.lang.String item: args) { if(predicate.test(item)){ return item;} } return null; + for (java.lang.String item : args) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingArg(java.util.function.Predicate predicate) { - for (java.lang.String item: args) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingArg( + java.util.function.Predicate predicate) { + for (java.lang.String item : args) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withArgs(java.util.List args) { - if (args != null) {this.args = new java.util.ArrayList(); for (java.lang.String item : args){this.addToArgs(item);}} else { this.args = null;} return (A) this; + if (args != null) { + this.args = new java.util.ArrayList(); + for (java.lang.String item : args) { + this.addToArgs(item); + } + } else { + this.args = null; + } + return (A) this; } + public A withArgs(java.lang.String... args) { - if (this.args != null) {this.args.clear();} - if (args != null) {for (java.lang.String item :args){ this.addToArgs(item);}} return (A) this; + if (this.args != null) { + this.args.clear(); + } + if (args != null) { + for (java.lang.String item : args) { + this.addToArgs(item); + } + } + return (A) this; } + public java.lang.Boolean hasArgs() { return args != null && !args.isEmpty(); } + public A addNewArg(java.lang.String original) { - return (A)addToArgs(new String(original)); + return (A) addToArgs(new String(original)); } - public A addToCommand(java.lang.Integer index,java.lang.String item) { - if (this.command == null) {this.command = new java.util.ArrayList();} + + public A addToCommand(java.lang.Integer index, java.lang.String item) { + if (this.command == null) { + this.command = new java.util.ArrayList(); + } this.command.add(index, item); - return (A)this; + return (A) this; } - public A setToCommand(java.lang.Integer index,java.lang.String item) { - if (this.command == null) {this.command = new java.util.ArrayList();} - this.command.set(index, item); return (A)this; + + public A setToCommand(java.lang.Integer index, java.lang.String item) { + if (this.command == null) { + this.command = new java.util.ArrayList(); + } + this.command.set(index, item); + return (A) this; } + public A addToCommand(java.lang.String... items) { - if (this.command == null) {this.command = new java.util.ArrayList();} - for (java.lang.String item : items) {this.command.add(item);} return (A)this; + if (this.command == null) { + this.command = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.command.add(item); + } + return (A) this; } + public A addAllToCommand(java.util.Collection items) { - if (this.command == null) {this.command = new java.util.ArrayList();} - for (java.lang.String item : items) {this.command.add(item);} return (A)this; + if (this.command == null) { + this.command = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.command.add(item); + } + return (A) this; } + public A removeFromCommand(java.lang.String... items) { - for (java.lang.String item : items) {if (this.command!= null){ this.command.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.command != null) { + this.command.remove(item); + } + } + return (A) this; } + public A removeAllFromCommand(java.util.Collection items) { - for (java.lang.String item : items) {if (this.command!= null){ this.command.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.command != null) { + this.command.remove(item); + } + } + return (A) this; } + public java.util.List getCommand() { return this.command; } + public java.lang.String getCommand(java.lang.Integer index) { return this.command.get(index); } + public java.lang.String getFirstCommand() { return this.command.get(0); } + public java.lang.String getLastCommand() { return this.command.get(command.size() - 1); } - public java.lang.String getMatchingCommand(java.util.function.Predicate predicate) { - for (java.lang.String item: command) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingCommand( + java.util.function.Predicate predicate) { + for (java.lang.String item : command) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingCommand(java.util.function.Predicate predicate) { - for (java.lang.String item: command) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCommand( + java.util.function.Predicate predicate) { + for (java.lang.String item : command) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withCommand(java.util.List command) { - if (command != null) {this.command = new java.util.ArrayList(); for (java.lang.String item : command){this.addToCommand(item);}} else { this.command = null;} return (A) this; + if (command != null) { + this.command = new java.util.ArrayList(); + for (java.lang.String item : command) { + this.addToCommand(item); + } + } else { + this.command = null; + } + return (A) this; } + public A withCommand(java.lang.String... command) { - if (this.command != null) {this.command.clear();} - if (command != null) {for (java.lang.String item :command){ this.addToCommand(item);}} return (A) this; + if (this.command != null) { + this.command.clear(); + } + if (command != null) { + for (java.lang.String item : command) { + this.addToCommand(item); + } + } + return (A) this; } + public java.lang.Boolean hasCommand() { return command != null && !command.isEmpty(); } + public A addNewCommand(java.lang.String original) { - return (A)addToCommand(new String(original)); + return (A) addToCommand(new String(original)); } - public A addToEnv(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item) { - if (this.env == null) {this.env = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item);_visitables.get("env").add(index >= 0 ? index : _visitables.get("env").size(), builder);this.env.add(index >= 0 ? index : env.size(), builder); return (A)this; + + public A addToEnv(java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item) { + if (this.env == null) { + this.env = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); + _visitables.get("env").add(index >= 0 ? index : _visitables.get("env").size(), builder); + this.env.add(index >= 0 ? index : env.size(), builder); + return (A) this; } - public A setToEnv(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item) { - if (this.env == null) {this.env = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); - if (index < 0 || index >= _visitables.get("env").size()) { _visitables.get("env").add(builder); } else { _visitables.get("env").set(index, builder);} - if (index < 0 || index >= env.size()) { env.add(builder); } else { env.set(index, builder);} - return (A)this; + + public A setToEnv(java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item) { + if (this.env == null) { + this.env = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); + if (index < 0 || index >= _visitables.get("env").size()) { + _visitables.get("env").add(builder); + } else { + _visitables.get("env").set(index, builder); + } + if (index < 0 || index >= env.size()) { + env.add(builder); + } else { + env.set(index, builder); + } + return (A) this; } + public A addToEnv(io.kubernetes.client.openapi.models.V1EnvVar... items) { - if (this.env == null) {this.env = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EnvVar item : items) {io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item);_visitables.get("env").add(builder);this.env.add(builder);} return (A)this; + if (this.env == null) { + this.env = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EnvVar item : items) { + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); + _visitables.get("env").add(builder); + this.env.add(builder); + } + return (A) this; } + public A addAllToEnv(java.util.Collection items) { - if (this.env == null) {this.env = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EnvVar item : items) {io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item);_visitables.get("env").add(builder);this.env.add(builder);} return (A)this; + if (this.env == null) { + this.env = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EnvVar item : items) { + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); + _visitables.get("env").add(builder); + this.env.add(builder); + } + return (A) this; } + public A removeFromEnv(io.kubernetes.client.openapi.models.V1EnvVar... items) { - for (io.kubernetes.client.openapi.models.V1EnvVar item : items) {io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item);_visitables.get("env").remove(builder);if (this.env != null) {this.env.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1EnvVar item : items) { + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); + _visitables.get("env").remove(builder); + if (this.env != null) { + this.env.remove(builder); + } + } + return (A) this; } - public A removeAllFromEnv(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1EnvVar item : items) {io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item);_visitables.get("env").remove(builder);if (this.env != null) {this.env.remove(builder);}} return (A)this; + + public A removeAllFromEnv( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1EnvVar item : items) { + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); + _visitables.get("env").remove(builder); + if (this.env != null) { + this.env.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromEnv(java.util.function.Predicate predicate) { + + public A removeMatchingFromEnv( + java.util.function.Predicate predicate) { if (env == null) return (A) this; final Iterator each = env.iterator(); final List visitables = _visitables.get("env"); @@ -232,104 +430,224 @@ public A removeMatchingFromEnv(java.util.function.Predicate getEnv() { return env != null ? build(env) : null; } + public java.util.List buildEnv() { return env != null ? build(env) : null; } + public io.kubernetes.client.openapi.models.V1EnvVar buildEnv(java.lang.Integer index) { return this.env.get(index).build(); } + public io.kubernetes.client.openapi.models.V1EnvVar buildFirstEnv() { return this.env.get(0).build(); } + public io.kubernetes.client.openapi.models.V1EnvVar buildLastEnv() { return this.env.get(env.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1EnvVar buildMatchingEnv(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EnvVarBuilder item: env) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1EnvVar buildMatchingEnv( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1EnvVarBuilder item : env) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingEnv(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EnvVarBuilder item: env) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingEnv( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1EnvVarBuilder item : env) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withEnv(java.util.List env) { - if (this.env != null) { _visitables.get("env").removeAll(this.env);} - if (env != null) {this.env = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1EnvVar item : env){this.addToEnv(item);}} else { this.env = null;} return (A) this; + if (this.env != null) { + _visitables.get("env").removeAll(this.env); + } + if (env != null) { + this.env = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1EnvVar item : env) { + this.addToEnv(item); + } + } else { + this.env = null; + } + return (A) this; } + public A withEnv(io.kubernetes.client.openapi.models.V1EnvVar... env) { - if (this.env != null) {this.env.clear();} - if (env != null) {for (io.kubernetes.client.openapi.models.V1EnvVar item :env){ this.addToEnv(item);}} return (A) this; + if (this.env != null) { + this.env.clear(); + } + if (env != null) { + for (io.kubernetes.client.openapi.models.V1EnvVar item : env) { + this.addToEnv(item); + } + } + return (A) this; } + public java.lang.Boolean hasEnv() { return env != null && !env.isEmpty(); } + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested addNewEnv() { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.EnvNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested addNewEnvLike(io.kubernetes.client.openapi.models.V1EnvVar item) { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested addNewEnvLike( + io.kubernetes.client.openapi.models.V1EnvVar item) { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.EnvNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested setNewEnvLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item) { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested setNewEnvLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item) { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.EnvNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested editEnv(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested editEnv( + java.lang.Integer index) { if (env.size() <= index) throw new RuntimeException("Can't edit env. Index exceeds size."); return setNewEnvLike(index, buildEnv(index)); } + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested editFirstEnv() { if (env.size() == 0) throw new RuntimeException("Can't edit first env. The list is empty."); return setNewEnvLike(0, buildEnv(0)); } + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested editLastEnv() { int index = env.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last env. The list is empty."); return setNewEnvLike(index, buildEnv(index)); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested editMatchingEnv(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested editMatchingEnv( + java.util.function.Predicate predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item);_visitables.get("envFrom").add(index >= 0 ? index : _visitables.get("envFrom").size(), builder);this.envFrom.add(index >= 0 ? index : envFrom.size(), builder); return (A)this; + + public A addToEnvFrom( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item) { + if (this.envFrom == null) { + this.envFrom = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); + _visitables.get("envFrom").add(index >= 0 ? index : _visitables.get("envFrom").size(), builder); + this.envFrom.add(index >= 0 ? index : envFrom.size(), builder); + return (A) this; } - public A setToEnvFrom(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvFromSource item) { - if (this.envFrom == null) {this.envFrom = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); - if (index < 0 || index >= _visitables.get("envFrom").size()) { _visitables.get("envFrom").add(builder); } else { _visitables.get("envFrom").set(index, builder);} - if (index < 0 || index >= envFrom.size()) { envFrom.add(builder); } else { envFrom.set(index, builder);} - return (A)this; + + public A setToEnvFrom( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item) { + if (this.envFrom == null) { + this.envFrom = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); + if (index < 0 || index >= _visitables.get("envFrom").size()) { + _visitables.get("envFrom").add(builder); + } else { + _visitables.get("envFrom").set(index, builder); + } + if (index < 0 || index >= envFrom.size()) { + envFrom.add(builder); + } else { + envFrom.set(index, builder); + } + return (A) this; } + public A addToEnvFrom(io.kubernetes.client.openapi.models.V1EnvFromSource... items) { - if (this.envFrom == null) {this.envFrom = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) {io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item);_visitables.get("envFrom").add(builder);this.envFrom.add(builder);} return (A)this; + if (this.envFrom == null) { + this.envFrom = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) { + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); + _visitables.get("envFrom").add(builder); + this.envFrom.add(builder); + } + return (A) this; } - public A addAllToEnvFrom(java.util.Collection items) { - if (this.envFrom == null) {this.envFrom = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) {io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item);_visitables.get("envFrom").add(builder);this.envFrom.add(builder);} return (A)this; + + public A addAllToEnvFrom( + java.util.Collection items) { + if (this.envFrom == null) { + this.envFrom = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) { + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); + _visitables.get("envFrom").add(builder); + this.envFrom.add(builder); + } + return (A) this; } + public A removeFromEnvFrom(io.kubernetes.client.openapi.models.V1EnvFromSource... items) { - for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) {io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item);_visitables.get("envFrom").remove(builder);if (this.envFrom != null) {this.envFrom.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) { + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); + _visitables.get("envFrom").remove(builder); + if (this.envFrom != null) { + this.envFrom.remove(builder); + } + } + return (A) this; } - public A removeAllFromEnvFrom(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) {io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item);_visitables.get("envFrom").remove(builder);if (this.envFrom != null) {this.envFrom.remove(builder);}} return (A)this; + + public A removeAllFromEnvFrom( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) { + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); + _visitables.get("envFrom").remove(builder); + if (this.envFrom != null) { + this.envFrom.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromEnvFrom(java.util.function.Predicate predicate) { + + public A removeMatchingFromEnvFrom( + java.util.function.Predicate + predicate) { if (envFrom == null) return (A) this; - final Iterator each = envFrom.iterator(); + final Iterator each = + envFrom.iterator(); final List visitables = _visitables.get("envFrom"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = each.next(); @@ -338,215 +656,394 @@ public A removeMatchingFromEnvFrom(java.util.function.Predicate getEnvFrom() { return envFrom != null ? build(envFrom) : null; } + public java.util.List buildEnvFrom() { return envFrom != null ? build(envFrom) : null; } + public io.kubernetes.client.openapi.models.V1EnvFromSource buildEnvFrom(java.lang.Integer index) { return this.envFrom.get(index).build(); } + public io.kubernetes.client.openapi.models.V1EnvFromSource buildFirstEnvFrom() { return this.envFrom.get(0).build(); } + public io.kubernetes.client.openapi.models.V1EnvFromSource buildLastEnvFrom() { return this.envFrom.get(envFrom.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1EnvFromSource buildMatchingEnvFrom(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder item: envFrom) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1EnvFromSource buildMatchingEnvFrom( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder item : envFrom) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingEnvFrom(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder item: envFrom) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingEnvFrom( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder item : envFrom) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withEnvFrom(java.util.List envFrom) { - if (this.envFrom != null) { _visitables.get("envFrom").removeAll(this.envFrom);} - if (envFrom != null) {this.envFrom = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1EnvFromSource item : envFrom){this.addToEnvFrom(item);}} else { this.envFrom = null;} return (A) this; + + public A withEnvFrom( + java.util.List envFrom) { + if (this.envFrom != null) { + _visitables.get("envFrom").removeAll(this.envFrom); + } + if (envFrom != null) { + this.envFrom = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1EnvFromSource item : envFrom) { + this.addToEnvFrom(item); + } + } else { + this.envFrom = null; + } + return (A) this; } + public A withEnvFrom(io.kubernetes.client.openapi.models.V1EnvFromSource... envFrom) { - if (this.envFrom != null) {this.envFrom.clear();} - if (envFrom != null) {for (io.kubernetes.client.openapi.models.V1EnvFromSource item :envFrom){ this.addToEnvFrom(item);}} return (A) this; + if (this.envFrom != null) { + this.envFrom.clear(); + } + if (envFrom != null) { + for (io.kubernetes.client.openapi.models.V1EnvFromSource item : envFrom) { + this.addToEnvFrom(item); + } + } + return (A) this; } + public java.lang.Boolean hasEnvFrom() { return envFrom != null && !envFrom.isEmpty(); } + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested addNewEnvFrom() { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.EnvFromNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested addNewEnvFromLike(io.kubernetes.client.openapi.models.V1EnvFromSource item) { - return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.EnvFromNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested addNewEnvFromLike( + io.kubernetes.client.openapi.models.V1EnvFromSource item) { + return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.EnvFromNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested setNewEnvFromLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvFromSource item) { - return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.EnvFromNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested setNewEnvFromLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item) { + return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.EnvFromNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested editEnvFrom(java.lang.Integer index) { - if (envFrom.size() <= index) throw new RuntimeException("Can't edit envFrom. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested editEnvFrom( + java.lang.Integer index) { + if (envFrom.size() <= index) + throw new RuntimeException("Can't edit envFrom. Index exceeds size."); return setNewEnvFromLike(index, buildEnvFrom(index)); } + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested editFirstEnvFrom() { - if (envFrom.size() == 0) throw new RuntimeException("Can't edit first envFrom. The list is empty."); + if (envFrom.size() == 0) + throw new RuntimeException("Can't edit first envFrom. The list is empty."); return setNewEnvFromLike(0, buildEnvFrom(0)); } + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested editLastEnvFrom() { int index = envFrom.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last envFrom. The list is empty."); return setNewEnvFromLike(index, buildEnvFrom(index)); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested editMatchingEnvFrom(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested editMatchingEnvFrom( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewLifecycle() { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested + withNewLifecycle() { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.LifecycleNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested withNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item) { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested + withNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item) { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.LifecycleNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested editLifecycle() { return withNewLifecycleLike(getLifecycle()); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested editOrNewLifecycle() { - return withNewLifecycleLike(getLifecycle() != null ? getLifecycle(): new io.kubernetes.client.openapi.models.V1LifecycleBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested + editOrNewLifecycle() { + return withNewLifecycleLike( + getLifecycle() != null + ? getLifecycle() + : new io.kubernetes.client.openapi.models.V1LifecycleBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested editOrNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item) { - return withNewLifecycleLike(getLifecycle() != null ? getLifecycle(): item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested + editOrNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item) { + return withNewLifecycleLike(getLifecycle() != null ? getLifecycle() : item); } - + /** * This method has been deprecated, please use method buildLivenessProbe instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Probe getLivenessProbe() { - return this.livenessProbe!=null ?this.livenessProbe.build():null; + return this.livenessProbe != null ? this.livenessProbe.build() : null; } + public io.kubernetes.client.openapi.models.V1Probe buildLivenessProbe() { - return this.livenessProbe!=null ?this.livenessProbe.build():null; + return this.livenessProbe != null ? this.livenessProbe.build() : null; } + public A withLivenessProbe(io.kubernetes.client.openapi.models.V1Probe livenessProbe) { _visitables.get("livenessProbe").remove(this.livenessProbe); - if (livenessProbe!=null){ this.livenessProbe= new io.kubernetes.client.openapi.models.V1ProbeBuilder(livenessProbe); _visitables.get("livenessProbe").add(this.livenessProbe);} return (A) this; + if (livenessProbe != null) { + this.livenessProbe = new io.kubernetes.client.openapi.models.V1ProbeBuilder(livenessProbe); + _visitables.get("livenessProbe").add(this.livenessProbe); + } + return (A) this; } + public java.lang.Boolean hasLivenessProbe() { return this.livenessProbe != null; } - public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested withNewLivenessProbe() { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested + withNewLivenessProbe() { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.LivenessProbeNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested withNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { - return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.LivenessProbeNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested + withNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { + return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.LivenessProbeNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested editLivenessProbe() { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested + editLivenessProbe() { return withNewLivenessProbeLike(getLivenessProbe()); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested editOrNewLivenessProbe() { - return withNewLivenessProbeLike(getLivenessProbe() != null ? getLivenessProbe(): new io.kubernetes.client.openapi.models.V1ProbeBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested + editOrNewLivenessProbe() { + return withNewLivenessProbeLike( + getLivenessProbe() != null + ? getLivenessProbe() + : new io.kubernetes.client.openapi.models.V1ProbeBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested editOrNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { - return withNewLivenessProbeLike(getLivenessProbe() != null ? getLivenessProbe(): item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested + editOrNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { + return withNewLivenessProbeLike(getLivenessProbe() != null ? getLivenessProbe() : item); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item);_visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder);this.ports.add(index >= 0 ? index : ports.size(), builder); return (A)this; + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); + _visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder); + this.ports.add(index >= 0 ? index : ports.size(), builder); + return (A) this; } - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); - if (index < 0 || index >= _visitables.get("ports").size()) { _visitables.get("ports").add(builder); } else { _visitables.get("ports").set(index, builder);} - if (index < 0 || index >= ports.size()) { ports.add(builder); } else { ports.set(index, builder);} - return (A)this; + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); + if (index < 0 || index >= _visitables.get("ports").size()) { + _visitables.get("ports").add(builder); + } else { + _visitables.get("ports").set(index, builder); + } + if (index < 0 || index >= ports.size()) { + ports.add(builder); + } else { + ports.set(index, builder); + } + return (A) this; } + public A addToPorts(io.kubernetes.client.openapi.models.V1ContainerPort... items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) {io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) { + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } - public A addAllToPorts(java.util.Collection items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) {io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + + public A addAllToPorts( + java.util.Collection items) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) { + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } + public A removeFromPorts(io.kubernetes.client.openapi.models.V1ContainerPort... items) { - for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) {io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) { + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeAllFromPorts(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) {io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + + public A removeAllFromPorts( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) { + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPorts(java.util.function.Predicate predicate) { + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate) { if (ports == null) return (A) this; - final Iterator each = ports.iterator(); + final Iterator each = + ports.iterator(); final List visitables = _visitables.get("ports"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = each.next(); @@ -555,293 +1052,530 @@ public A removeMatchingFromPorts(java.util.function.Predicate getPorts() { return ports != null ? build(ports) : null; } + public java.util.List buildPorts() { return ports != null ? build(ports) : null; } + public io.kubernetes.client.openapi.models.V1ContainerPort buildPort(java.lang.Integer index) { return this.ports.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ContainerPort buildFirstPort() { return this.ports.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ContainerPort buildLastPort() { return this.ports.get(ports.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ContainerPort buildMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerPortBuilder item: ports) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ContainerPort buildMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerPortBuilder item : ports) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerPortBuilder item: ports) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerPortBuilder item : ports) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withPorts(java.util.List ports) { - if (this.ports != null) { _visitables.get("ports").removeAll(this.ports);} - if (ports != null) {this.ports = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ContainerPort item : ports){this.addToPorts(item);}} else { this.ports = null;} return (A) this; + if (this.ports != null) { + _visitables.get("ports").removeAll(this.ports); + } + if (ports != null) { + this.ports = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ContainerPort item : ports) { + this.addToPorts(item); + } + } else { + this.ports = null; + } + return (A) this; } + public A withPorts(io.kubernetes.client.openapi.models.V1ContainerPort... ports) { - if (this.ports != null) {this.ports.clear();} - if (ports != null) {for (io.kubernetes.client.openapi.models.V1ContainerPort item :ports){ this.addToPorts(item);}} return (A) this; + if (this.ports != null) { + this.ports.clear(); + } + if (ports != null) { + for (io.kubernetes.client.openapi.models.V1ContainerPort item : ports) { + this.addToPorts(item); + } + } + return (A) this; } + public java.lang.Boolean hasPorts() { return ports != null && !ports.isEmpty(); } + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested addNewPort() { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.PortsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1ContainerPort item) { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested addNewPortLike( + io.kubernetes.client.openapi.models.V1ContainerPort item) { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.PortsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item) { - return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.PortsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item) { + return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.PortsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested editPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested editPort( + java.lang.Integer index) { if (ports.size() <= index) throw new RuntimeException("Can't edit ports. Index exceeds size."); return setNewPortLike(index, buildPort(index)); } + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested editFirstPort() { if (ports.size() == 0) throw new RuntimeException("Can't edit first ports. The list is empty."); return setNewPortLike(0, buildPort(0)); } + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested editLastPort() { int index = ports.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ports. The list is empty."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested editMatchingPort( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewReadinessProbe() { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested + withNewReadinessProbe() { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.ReadinessProbeNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested withNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { - return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.ReadinessProbeNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested + withNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { + return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.ReadinessProbeNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested editReadinessProbe() { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested + editReadinessProbe() { return withNewReadinessProbeLike(getReadinessProbe()); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested editOrNewReadinessProbe() { - return withNewReadinessProbeLike(getReadinessProbe() != null ? getReadinessProbe(): new io.kubernetes.client.openapi.models.V1ProbeBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested + editOrNewReadinessProbe() { + return withNewReadinessProbeLike( + getReadinessProbe() != null + ? getReadinessProbe() + : new io.kubernetes.client.openapi.models.V1ProbeBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested editOrNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { - return withNewReadinessProbeLike(getReadinessProbe() != null ? getReadinessProbe(): item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested + editOrNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { + return withNewReadinessProbeLike(getReadinessProbe() != null ? getReadinessProbe() : item); } - + /** * This method has been deprecated, please use method buildResources instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceRequirements getResources() { - return this.resources!=null ?this.resources.build():null; + return this.resources != null ? this.resources.build() : null; } + public io.kubernetes.client.openapi.models.V1ResourceRequirements buildResources() { - return this.resources!=null ?this.resources.build():null; + return this.resources != null ? this.resources.build() : null; } + public A withResources(io.kubernetes.client.openapi.models.V1ResourceRequirements resources) { _visitables.get("resources").remove(this.resources); - if (resources!=null){ this.resources= new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(resources); _visitables.get("resources").add(this.resources);} return (A) this; + if (resources != null) { + this.resources = + new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(resources); + _visitables.get("resources").add(this.resources); + } + return (A) this; } + public java.lang.Boolean hasResources() { return this.resources != null; } - public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested withNewResources() { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested + withNewResources() { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.ResourcesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested withNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested + withNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.ResourcesNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested editResources() { return withNewResourcesLike(getResources()); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested editOrNewResources() { - return withNewResourcesLike(getResources() != null ? getResources(): new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested + editOrNewResources() { + return withNewResourcesLike( + getResources() != null + ? getResources() + : new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested editOrNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { - return withNewResourcesLike(getResources() != null ? getResources(): item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested + editOrNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { + return withNewResourcesLike(getResources() != null ? getResources() : item); } - + /** * This method has been deprecated, please use method buildSecurityContext instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecurityContext getSecurityContext() { - return this.securityContext!=null ?this.securityContext.build():null; + return this.securityContext != null ? this.securityContext.build() : null; } + public io.kubernetes.client.openapi.models.V1SecurityContext buildSecurityContext() { - return this.securityContext!=null ?this.securityContext.build():null; + return this.securityContext != null ? this.securityContext.build() : null; } - public A withSecurityContext(io.kubernetes.client.openapi.models.V1SecurityContext securityContext) { + + public A withSecurityContext( + io.kubernetes.client.openapi.models.V1SecurityContext securityContext) { _visitables.get("securityContext").remove(this.securityContext); - if (securityContext!=null){ this.securityContext= new io.kubernetes.client.openapi.models.V1SecurityContextBuilder(securityContext); _visitables.get("securityContext").add(this.securityContext);} return (A) this; + if (securityContext != null) { + this.securityContext = + new io.kubernetes.client.openapi.models.V1SecurityContextBuilder(securityContext); + _visitables.get("securityContext").add(this.securityContext); + } + return (A) this; } + public java.lang.Boolean hasSecurityContext() { return this.securityContext != null; } - public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested withNewSecurityContext() { - return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.SecurityContextNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested + withNewSecurityContext() { + return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl + .SecurityContextNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested withNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item) { - return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.SecurityContextNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested + withNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item) { + return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.SecurityContextNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested editSecurityContext() { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested + editSecurityContext() { return withNewSecurityContextLike(getSecurityContext()); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested editOrNewSecurityContext() { - return withNewSecurityContextLike(getSecurityContext() != null ? getSecurityContext(): new io.kubernetes.client.openapi.models.V1SecurityContextBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested + editOrNewSecurityContext() { + return withNewSecurityContextLike( + getSecurityContext() != null + ? getSecurityContext() + : new io.kubernetes.client.openapi.models.V1SecurityContextBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested editOrNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item) { - return withNewSecurityContextLike(getSecurityContext() != null ? getSecurityContext(): item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested + editOrNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item) { + return withNewSecurityContextLike(getSecurityContext() != null ? getSecurityContext() : item); } - + /** * This method has been deprecated, please use method buildStartupProbe instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Probe getStartupProbe() { - return this.startupProbe!=null ?this.startupProbe.build():null; + return this.startupProbe != null ? this.startupProbe.build() : null; } + public io.kubernetes.client.openapi.models.V1Probe buildStartupProbe() { - return this.startupProbe!=null ?this.startupProbe.build():null; + return this.startupProbe != null ? this.startupProbe.build() : null; } + public A withStartupProbe(io.kubernetes.client.openapi.models.V1Probe startupProbe) { _visitables.get("startupProbe").remove(this.startupProbe); - if (startupProbe!=null){ this.startupProbe= new io.kubernetes.client.openapi.models.V1ProbeBuilder(startupProbe); _visitables.get("startupProbe").add(this.startupProbe);} return (A) this; + if (startupProbe != null) { + this.startupProbe = new io.kubernetes.client.openapi.models.V1ProbeBuilder(startupProbe); + _visitables.get("startupProbe").add(this.startupProbe); + } + return (A) this; } + public java.lang.Boolean hasStartupProbe() { return this.startupProbe != null; } - public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested withNewStartupProbe() { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested + withNewStartupProbe() { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.StartupProbeNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested withNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { - return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.StartupProbeNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested + withNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { + return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.StartupProbeNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested editStartupProbe() { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested + editStartupProbe() { return withNewStartupProbeLike(getStartupProbe()); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested editOrNewStartupProbe() { - return withNewStartupProbeLike(getStartupProbe() != null ? getStartupProbe(): new io.kubernetes.client.openapi.models.V1ProbeBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested + editOrNewStartupProbe() { + return withNewStartupProbeLike( + getStartupProbe() != null + ? getStartupProbe() + : new io.kubernetes.client.openapi.models.V1ProbeBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested editOrNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { - return withNewStartupProbeLike(getStartupProbe() != null ? getStartupProbe(): item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested + editOrNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { + return withNewStartupProbeLike(getStartupProbe() != null ? getStartupProbe() : item); } + public java.lang.Boolean getStdin() { return this.stdin; } + public A withStdin(java.lang.Boolean stdin) { - this.stdin=stdin; return (A) this; + this.stdin = stdin; + return (A) this; } + public java.lang.Boolean hasStdin() { return this.stdin != null; } + public java.lang.Boolean getStdinOnce() { return this.stdinOnce; } + public A withStdinOnce(java.lang.Boolean stdinOnce) { - this.stdinOnce=stdinOnce; return (A) this; + this.stdinOnce = stdinOnce; + return (A) this; } + public java.lang.Boolean hasStdinOnce() { return this.stdinOnce != null; } + public java.lang.String getTerminationMessagePath() { return this.terminationMessagePath; } + public A withTerminationMessagePath(java.lang.String terminationMessagePath) { - this.terminationMessagePath=terminationMessagePath; return (A) this; + this.terminationMessagePath = terminationMessagePath; + return (A) this; } + public java.lang.Boolean hasTerminationMessagePath() { return this.terminationMessagePath != null; } - - /** - * Method is deprecated. use withTerminationMessagePath instead. - */ + + /** Method is deprecated. use withTerminationMessagePath instead. */ @java.lang.Deprecated public A withNewTerminationMessagePath(java.lang.String original) { - return (A)withTerminationMessagePath(new String(original)); + return (A) withTerminationMessagePath(new String(original)); } - public io.kubernetes.client.openapi.models.V1Container.TerminationMessagePolicyEnum getTerminationMessagePolicy() { + + public io.kubernetes.client.openapi.models.V1Container.TerminationMessagePolicyEnum + getTerminationMessagePolicy() { return this.terminationMessagePolicy; } - public A withTerminationMessagePolicy(io.kubernetes.client.openapi.models.V1Container.TerminationMessagePolicyEnum terminationMessagePolicy) { - this.terminationMessagePolicy=terminationMessagePolicy; return (A) this; + + public A withTerminationMessagePolicy( + io.kubernetes.client.openapi.models.V1Container.TerminationMessagePolicyEnum + terminationMessagePolicy) { + this.terminationMessagePolicy = terminationMessagePolicy; + return (A) this; } + public java.lang.Boolean hasTerminationMessagePolicy() { return this.terminationMessagePolicy != null; } + public java.lang.Boolean getTty() { return this.tty; } + public A withTty(java.lang.Boolean tty) { - this.tty=tty; return (A) this; + this.tty = tty; + return (A) this; } + public java.lang.Boolean hasTty() { return this.tty != null; } - public A addToVolumeDevices(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item) { - if (this.volumeDevices == null) {this.volumeDevices = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item);_visitables.get("volumeDevices").add(index >= 0 ? index : _visitables.get("volumeDevices").size(), builder);this.volumeDevices.add(index >= 0 ? index : volumeDevices.size(), builder); return (A)this; + + public A addToVolumeDevices( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item) { + if (this.volumeDevices == null) { + this.volumeDevices = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); + _visitables + .get("volumeDevices") + .add(index >= 0 ? index : _visitables.get("volumeDevices").size(), builder); + this.volumeDevices.add(index >= 0 ? index : volumeDevices.size(), builder); + return (A) this; } - public A setToVolumeDevices(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item) { - if (this.volumeDevices == null) {this.volumeDevices = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); - if (index < 0 || index >= _visitables.get("volumeDevices").size()) { _visitables.get("volumeDevices").add(builder); } else { _visitables.get("volumeDevices").set(index, builder);} - if (index < 0 || index >= volumeDevices.size()) { volumeDevices.add(builder); } else { volumeDevices.set(index, builder);} - return (A)this; + + public A setToVolumeDevices( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item) { + if (this.volumeDevices == null) { + this.volumeDevices = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); + if (index < 0 || index >= _visitables.get("volumeDevices").size()) { + _visitables.get("volumeDevices").add(builder); + } else { + _visitables.get("volumeDevices").set(index, builder); + } + if (index < 0 || index >= volumeDevices.size()) { + volumeDevices.add(builder); + } else { + volumeDevices.set(index, builder); + } + return (A) this; } + public A addToVolumeDevices(io.kubernetes.client.openapi.models.V1VolumeDevice... items) { - if (this.volumeDevices == null) {this.volumeDevices = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) {io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item);_visitables.get("volumeDevices").add(builder);this.volumeDevices.add(builder);} return (A)this; + if (this.volumeDevices == null) { + this.volumeDevices = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) { + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); + _visitables.get("volumeDevices").add(builder); + this.volumeDevices.add(builder); + } + return (A) this; } - public A addAllToVolumeDevices(java.util.Collection items) { - if (this.volumeDevices == null) {this.volumeDevices = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) {io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item);_visitables.get("volumeDevices").add(builder);this.volumeDevices.add(builder);} return (A)this; + + public A addAllToVolumeDevices( + java.util.Collection items) { + if (this.volumeDevices == null) { + this.volumeDevices = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) { + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); + _visitables.get("volumeDevices").add(builder); + this.volumeDevices.add(builder); + } + return (A) this; } + public A removeFromVolumeDevices(io.kubernetes.client.openapi.models.V1VolumeDevice... items) { - for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) {io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item);_visitables.get("volumeDevices").remove(builder);if (this.volumeDevices != null) {this.volumeDevices.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) { + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); + _visitables.get("volumeDevices").remove(builder); + if (this.volumeDevices != null) { + this.volumeDevices.remove(builder); + } + } + return (A) this; } - public A removeAllFromVolumeDevices(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) {io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item);_visitables.get("volumeDevices").remove(builder);if (this.volumeDevices != null) {this.volumeDevices.remove(builder);}} return (A)this; + + public A removeAllFromVolumeDevices( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) { + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); + _visitables.get("volumeDevices").remove(builder); + if (this.volumeDevices != null) { + this.volumeDevices.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromVolumeDevices(java.util.function.Predicate predicate) { + + public A removeMatchingFromVolumeDevices( + java.util.function.Predicate + predicate) { if (volumeDevices == null) return (A) this; - final Iterator each = volumeDevices.iterator(); + final Iterator each = + volumeDevices.iterator(); final List visitables = _visitables.get("volumeDevices"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = each.next(); @@ -850,104 +1584,240 @@ public A removeMatchingFromVolumeDevices(java.util.function.Predicate getVolumeDevices() { return volumeDevices != null ? build(volumeDevices) : null; } + public java.util.List buildVolumeDevices() { return volumeDevices != null ? build(volumeDevices) : null; } - public io.kubernetes.client.openapi.models.V1VolumeDevice buildVolumeDevice(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1VolumeDevice buildVolumeDevice( + java.lang.Integer index) { return this.volumeDevices.get(index).build(); } + public io.kubernetes.client.openapi.models.V1VolumeDevice buildFirstVolumeDevice() { return this.volumeDevices.get(0).build(); } + public io.kubernetes.client.openapi.models.V1VolumeDevice buildLastVolumeDevice() { return this.volumeDevices.get(volumeDevices.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1VolumeDevice buildMatchingVolumeDevice(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder item: volumeDevices) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1VolumeDevice buildMatchingVolumeDevice( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder item : volumeDevices) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingVolumeDevice(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder item: volumeDevices) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVolumeDevice( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder item : volumeDevices) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withVolumeDevices(java.util.List volumeDevices) { - if (this.volumeDevices != null) { _visitables.get("volumeDevices").removeAll(this.volumeDevices);} - if (volumeDevices != null) {this.volumeDevices = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1VolumeDevice item : volumeDevices){this.addToVolumeDevices(item);}} else { this.volumeDevices = null;} return (A) this; + + public A withVolumeDevices( + java.util.List volumeDevices) { + if (this.volumeDevices != null) { + _visitables.get("volumeDevices").removeAll(this.volumeDevices); + } + if (volumeDevices != null) { + this.volumeDevices = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1VolumeDevice item : volumeDevices) { + this.addToVolumeDevices(item); + } + } else { + this.volumeDevices = null; + } + return (A) this; } + public A withVolumeDevices(io.kubernetes.client.openapi.models.V1VolumeDevice... volumeDevices) { - if (this.volumeDevices != null) {this.volumeDevices.clear();} - if (volumeDevices != null) {for (io.kubernetes.client.openapi.models.V1VolumeDevice item :volumeDevices){ this.addToVolumeDevices(item);}} return (A) this; + if (this.volumeDevices != null) { + this.volumeDevices.clear(); + } + if (volumeDevices != null) { + for (io.kubernetes.client.openapi.models.V1VolumeDevice item : volumeDevices) { + this.addToVolumeDevices(item); + } + } + return (A) this; } + public java.lang.Boolean hasVolumeDevices() { return volumeDevices != null && !volumeDevices.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested addNewVolumeDevice() { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + addNewVolumeDevice() { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.VolumeDevicesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested addNewVolumeDeviceLike(io.kubernetes.client.openapi.models.V1VolumeDevice item) { - return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.VolumeDevicesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + addNewVolumeDeviceLike(io.kubernetes.client.openapi.models.V1VolumeDevice item) { + return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.VolumeDevicesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested setNewVolumeDeviceLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item) { - return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.VolumeDevicesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + setNewVolumeDeviceLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item) { + return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.VolumeDevicesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested editVolumeDevice(java.lang.Integer index) { - if (volumeDevices.size() <= index) throw new RuntimeException("Can't edit volumeDevices. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + editVolumeDevice(java.lang.Integer index) { + if (volumeDevices.size() <= index) + throw new RuntimeException("Can't edit volumeDevices. Index exceeds size."); return setNewVolumeDeviceLike(index, buildVolumeDevice(index)); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested editFirstVolumeDevice() { - if (volumeDevices.size() == 0) throw new RuntimeException("Can't edit first volumeDevices. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + editFirstVolumeDevice() { + if (volumeDevices.size() == 0) + throw new RuntimeException("Can't edit first volumeDevices. The list is empty."); return setNewVolumeDeviceLike(0, buildVolumeDevice(0)); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested editLastVolumeDevice() { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + editLastVolumeDevice() { int index = volumeDevices.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last volumeDevices. The list is empty."); return setNewVolumeDeviceLike(index, buildVolumeDevice(index)); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested editMatchingVolumeDevice(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested + editMatchingVolumeDevice( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item);_visitables.get("volumeMounts").add(index >= 0 ? index : _visitables.get("volumeMounts").size(), builder);this.volumeMounts.add(index >= 0 ? index : volumeMounts.size(), builder); return (A)this; + + public A addToVolumeMounts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item) { + if (this.volumeMounts == null) { + this.volumeMounts = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); + _visitables + .get("volumeMounts") + .add(index >= 0 ? index : _visitables.get("volumeMounts").size(), builder); + this.volumeMounts.add(index >= 0 ? index : volumeMounts.size(), builder); + return (A) this; } - public A setToVolumeMounts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeMount item) { - if (this.volumeMounts == null) {this.volumeMounts = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); - if (index < 0 || index >= _visitables.get("volumeMounts").size()) { _visitables.get("volumeMounts").add(builder); } else { _visitables.get("volumeMounts").set(index, builder);} - if (index < 0 || index >= volumeMounts.size()) { volumeMounts.add(builder); } else { volumeMounts.set(index, builder);} - return (A)this; + + public A setToVolumeMounts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item) { + if (this.volumeMounts == null) { + this.volumeMounts = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); + if (index < 0 || index >= _visitables.get("volumeMounts").size()) { + _visitables.get("volumeMounts").add(builder); + } else { + _visitables.get("volumeMounts").set(index, builder); + } + if (index < 0 || index >= volumeMounts.size()) { + volumeMounts.add(builder); + } else { + volumeMounts.set(index, builder); + } + return (A) this; } + public A addToVolumeMounts(io.kubernetes.client.openapi.models.V1VolumeMount... items) { - if (this.volumeMounts == null) {this.volumeMounts = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) {io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item);_visitables.get("volumeMounts").add(builder);this.volumeMounts.add(builder);} return (A)this; + if (this.volumeMounts == null) { + this.volumeMounts = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) { + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); + _visitables.get("volumeMounts").add(builder); + this.volumeMounts.add(builder); + } + return (A) this; } - public A addAllToVolumeMounts(java.util.Collection items) { - if (this.volumeMounts == null) {this.volumeMounts = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) {io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item);_visitables.get("volumeMounts").add(builder);this.volumeMounts.add(builder);} return (A)this; + + public A addAllToVolumeMounts( + java.util.Collection items) { + if (this.volumeMounts == null) { + this.volumeMounts = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) { + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); + _visitables.get("volumeMounts").add(builder); + this.volumeMounts.add(builder); + } + return (A) this; } + public A removeFromVolumeMounts(io.kubernetes.client.openapi.models.V1VolumeMount... items) { - for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) {io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item);_visitables.get("volumeMounts").remove(builder);if (this.volumeMounts != null) {this.volumeMounts.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) { + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); + _visitables.get("volumeMounts").remove(builder); + if (this.volumeMounts != null) { + this.volumeMounts.remove(builder); + } + } + return (A) this; } - public A removeAllFromVolumeMounts(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) {io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item);_visitables.get("volumeMounts").remove(builder);if (this.volumeMounts != null) {this.volumeMounts.remove(builder);}} return (A)this; + + public A removeAllFromVolumeMounts( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) { + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); + _visitables.get("volumeMounts").remove(builder); + if (this.volumeMounts != null) { + this.volumeMounts.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromVolumeMounts(java.util.function.Predicate predicate) { + + public A removeMatchingFromVolumeMounts( + java.util.function.Predicate + predicate) { if (volumeMounts == null) return (A) this; - final Iterator each = volumeMounts.iterator(); + final Iterator each = + volumeMounts.iterator(); final List visitables = _visitables.get("volumeMounts"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = each.next(); @@ -956,314 +1826,520 @@ public A removeMatchingFromVolumeMounts(java.util.function.Predicate getVolumeMounts() { return volumeMounts != null ? build(volumeMounts) : null; } + public java.util.List buildVolumeMounts() { return volumeMounts != null ? build(volumeMounts) : null; } - public io.kubernetes.client.openapi.models.V1VolumeMount buildVolumeMount(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1VolumeMount buildVolumeMount( + java.lang.Integer index) { return this.volumeMounts.get(index).build(); } + public io.kubernetes.client.openapi.models.V1VolumeMount buildFirstVolumeMount() { return this.volumeMounts.get(0).build(); } + public io.kubernetes.client.openapi.models.V1VolumeMount buildLastVolumeMount() { return this.volumeMounts.get(volumeMounts.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1VolumeMount buildMatchingVolumeMount(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeMountBuilder item: volumeMounts) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1VolumeMount buildMatchingVolumeMount( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeMountBuilder item : volumeMounts) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingVolumeMount(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeMountBuilder item: volumeMounts) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVolumeMount( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeMountBuilder item : volumeMounts) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withVolumeMounts(java.util.List volumeMounts) { - if (this.volumeMounts != null) { _visitables.get("volumeMounts").removeAll(this.volumeMounts);} - if (volumeMounts != null) {this.volumeMounts = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1VolumeMount item : volumeMounts){this.addToVolumeMounts(item);}} else { this.volumeMounts = null;} return (A) this; + + public A withVolumeMounts( + java.util.List volumeMounts) { + if (this.volumeMounts != null) { + _visitables.get("volumeMounts").removeAll(this.volumeMounts); + } + if (volumeMounts != null) { + this.volumeMounts = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1VolumeMount item : volumeMounts) { + this.addToVolumeMounts(item); + } + } else { + this.volumeMounts = null; + } + return (A) this; } + public A withVolumeMounts(io.kubernetes.client.openapi.models.V1VolumeMount... volumeMounts) { - if (this.volumeMounts != null) {this.volumeMounts.clear();} - if (volumeMounts != null) {for (io.kubernetes.client.openapi.models.V1VolumeMount item :volumeMounts){ this.addToVolumeMounts(item);}} return (A) this; + if (this.volumeMounts != null) { + this.volumeMounts.clear(); + } + if (volumeMounts != null) { + for (io.kubernetes.client.openapi.models.V1VolumeMount item : volumeMounts) { + this.addToVolumeMounts(item); + } + } + return (A) this; } + public java.lang.Boolean hasVolumeMounts() { return volumeMounts != null && !volumeMounts.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested addNewVolumeMount() { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + addNewVolumeMount() { return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.VolumeMountsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested addNewVolumeMountLike(io.kubernetes.client.openapi.models.V1VolumeMount item) { - return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.VolumeMountsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + addNewVolumeMountLike(io.kubernetes.client.openapi.models.V1VolumeMount item) { + return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.VolumeMountsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested setNewVolumeMountLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeMount item) { - return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.VolumeMountsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + setNewVolumeMountLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item) { + return new io.kubernetes.client.openapi.models.V1ContainerFluentImpl.VolumeMountsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested editVolumeMount(java.lang.Integer index) { - if (volumeMounts.size() <= index) throw new RuntimeException("Can't edit volumeMounts. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + editVolumeMount(java.lang.Integer index) { + if (volumeMounts.size() <= index) + throw new RuntimeException("Can't edit volumeMounts. Index exceeds size."); return setNewVolumeMountLike(index, buildVolumeMount(index)); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested editFirstVolumeMount() { - if (volumeMounts.size() == 0) throw new RuntimeException("Can't edit first volumeMounts. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + editFirstVolumeMount() { + if (volumeMounts.size() == 0) + throw new RuntimeException("Can't edit first volumeMounts. The list is empty."); return setNewVolumeMountLike(0, buildVolumeMount(0)); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested editLastVolumeMount() { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + editLastVolumeMount() { int index = volumeMounts.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last volumeMounts. The list is empty."); return setNewVolumeMountLike(index, buildVolumeMount(index)); } - public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested editMatchingVolumeMount(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested + editMatchingVolumeMount( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1EnvVarFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested,io.kubernetes.client.fluent.Nested{ - EnvNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item) { + + public class EnvNestedImpl + extends io.kubernetes.client.openapi.models.V1EnvVarFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested> + implements io.kubernetes.client.openapi.models.V1ContainerFluent.EnvNested, + io.kubernetes.client.fluent.Nested { + EnvNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(this, item); } + EnvNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(this); } + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ContainerFluentImpl.this.setToEnv(index,builder.build()); + return (N) V1ContainerFluentImpl.this.setToEnv(index, builder.build()); } + public N endEnv() { return and(); } - } - public class EnvFromNestedImpl extends io.kubernetes.client.openapi.models.V1EnvFromSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested,io.kubernetes.client.fluent.Nested{ - EnvFromNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvFromSource item) { + + public class EnvFromNestedImpl + extends io.kubernetes.client.openapi.models.V1EnvFromSourceFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested> + implements io.kubernetes.client.openapi.models.V1ContainerFluent.EnvFromNested, + io.kubernetes.client.fluent.Nested { + EnvFromNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(this, item); } + EnvFromNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ContainerFluentImpl.this.setToEnvFrom(index,builder.build()); + return (N) V1ContainerFluentImpl.this.setToEnvFrom(index, builder.build()); } + public N endEnvFrom() { return and(); } - } - public class LifecycleNestedImpl extends io.kubernetes.client.openapi.models.V1LifecycleFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested,io.kubernetes.client.fluent.Nested{ + + public class LifecycleNestedImpl + extends io.kubernetes.client.openapi.models.V1LifecycleFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested> + implements io.kubernetes.client.openapi.models.V1ContainerFluent.LifecycleNested, + io.kubernetes.client.fluent.Nested { LifecycleNestedImpl(io.kubernetes.client.openapi.models.V1Lifecycle item) { this.builder = new io.kubernetes.client.openapi.models.V1LifecycleBuilder(this, item); } + LifecycleNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LifecycleBuilder(this); } + io.kubernetes.client.openapi.models.V1LifecycleBuilder builder; + public N and() { return (N) V1ContainerFluentImpl.this.withLifecycle(builder.build()); } + public N endLifecycle() { return and(); } - } - public class LivenessProbeNestedImpl extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested,io.kubernetes.client.fluent.Nested{ + + public class LivenessProbeNestedImpl + extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested> + implements io.kubernetes.client.openapi.models.V1ContainerFluent.LivenessProbeNested, + io.kubernetes.client.fluent.Nested { LivenessProbeNestedImpl(io.kubernetes.client.openapi.models.V1Probe item) { this.builder = new io.kubernetes.client.openapi.models.V1ProbeBuilder(this, item); } + LivenessProbeNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ProbeBuilder(this); } + io.kubernetes.client.openapi.models.V1ProbeBuilder builder; + public N and() { return (N) V1ContainerFluentImpl.this.withLivenessProbe(builder.build()); } + public N endLivenessProbe() { return and(); } - } - public class PortsNestedImpl extends io.kubernetes.client.openapi.models.V1ContainerPortFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested,io.kubernetes.client.fluent.Nested{ - PortsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item) { + + public class PortsNestedImpl + extends io.kubernetes.client.openapi.models.V1ContainerPortFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested> + implements io.kubernetes.client.openapi.models.V1ContainerFluent.PortsNested, + io.kubernetes.client.fluent.Nested { + PortsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(this, item); } + PortsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(this); } + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ContainerFluentImpl.this.setToPorts(index,builder.build()); + return (N) V1ContainerFluentImpl.this.setToPorts(index, builder.build()); } + public N endPort() { return and(); } - } - public class ReadinessProbeNestedImpl extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested,io.kubernetes.client.fluent.Nested{ + + public class ReadinessProbeNestedImpl + extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested> + implements io.kubernetes.client.openapi.models.V1ContainerFluent.ReadinessProbeNested, + io.kubernetes.client.fluent.Nested { ReadinessProbeNestedImpl(io.kubernetes.client.openapi.models.V1Probe item) { this.builder = new io.kubernetes.client.openapi.models.V1ProbeBuilder(this, item); } + ReadinessProbeNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ProbeBuilder(this); } + io.kubernetes.client.openapi.models.V1ProbeBuilder builder; + public N and() { return (N) V1ContainerFluentImpl.this.withReadinessProbe(builder.build()); } + public N endReadinessProbe() { return and(); } - } - public class ResourcesNestedImpl extends io.kubernetes.client.openapi.models.V1ResourceRequirementsFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested,io.kubernetes.client.fluent.Nested{ + + public class ResourcesNestedImpl + extends io.kubernetes.client.openapi.models.V1ResourceRequirementsFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested> + implements io.kubernetes.client.openapi.models.V1ContainerFluent.ResourcesNested, + io.kubernetes.client.fluent.Nested { ResourcesNestedImpl(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { - this.builder = new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(this, item); } + ResourcesNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(this); } + io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder builder; + public N and() { return (N) V1ContainerFluentImpl.this.withResources(builder.build()); } + public N endResources() { return and(); } - } - public class SecurityContextNestedImpl extends io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested,io.kubernetes.client.fluent.Nested{ + + public class SecurityContextNestedImpl + extends io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested> + implements io.kubernetes.client.openapi.models.V1ContainerFluent.SecurityContextNested, + io.kubernetes.client.fluent.Nested { SecurityContextNestedImpl(io.kubernetes.client.openapi.models.V1SecurityContext item) { this.builder = new io.kubernetes.client.openapi.models.V1SecurityContextBuilder(this, item); } + SecurityContextNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecurityContextBuilder(this); } + io.kubernetes.client.openapi.models.V1SecurityContextBuilder builder; + public N and() { return (N) V1ContainerFluentImpl.this.withSecurityContext(builder.build()); } + public N endSecurityContext() { return and(); } - } - public class StartupProbeNestedImpl extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested,io.kubernetes.client.fluent.Nested{ + + public class StartupProbeNestedImpl + extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested> + implements io.kubernetes.client.openapi.models.V1ContainerFluent.StartupProbeNested, + io.kubernetes.client.fluent.Nested { StartupProbeNestedImpl(io.kubernetes.client.openapi.models.V1Probe item) { this.builder = new io.kubernetes.client.openapi.models.V1ProbeBuilder(this, item); } + StartupProbeNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ProbeBuilder(this); } + io.kubernetes.client.openapi.models.V1ProbeBuilder builder; + public N and() { return (N) V1ContainerFluentImpl.this.withStartupProbe(builder.build()); } + public N endStartupProbe() { return and(); } - } - public class VolumeDevicesNestedImpl extends io.kubernetes.client.openapi.models.V1VolumeDeviceFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested,io.kubernetes.client.fluent.Nested{ - VolumeDevicesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item) { + + public class VolumeDevicesNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeDeviceFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested> + implements io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeDevicesNested, + io.kubernetes.client.fluent.Nested { + VolumeDevicesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(this, item); } + VolumeDevicesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ContainerFluentImpl.this.setToVolumeDevices(index,builder.build()); + return (N) V1ContainerFluentImpl.this.setToVolumeDevices(index, builder.build()); } + public N endVolumeDevice() { return and(); } - } - public class VolumeMountsNestedImpl extends io.kubernetes.client.openapi.models.V1VolumeMountFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested,io.kubernetes.client.fluent.Nested{ - VolumeMountsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeMount item) { + + public class VolumeMountsNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeMountFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested> + implements io.kubernetes.client.openapi.models.V1ContainerFluent.VolumeMountsNested, + io.kubernetes.client.fluent.Nested { + VolumeMountsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(this, item); } + VolumeMountsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ContainerFluentImpl.this.setToVolumeMounts(index,builder.build()); + return (N) V1ContainerFluentImpl.this.setToVolumeMounts(index, builder.build()); } + public N endVolumeMount() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerImageBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerImageBuilder.java index c1a848b160..d8a56e048f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerImageBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerImageBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ContainerImageBuilder extends io.kubernetes.client.openapi.models.V1ContainerImageFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ContainerImageBuilder + extends io.kubernetes.client.openapi.models.V1ContainerImageFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerImageBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ContainerImage, + io.kubernetes.client.openapi.models.V1ContainerImageBuilder> { public V1ContainerImageBuilder() { this(false); } + public V1ContainerImageBuilder(java.lang.Boolean validationEnabled) { this(new V1ContainerImage(), validationEnabled); } - public V1ContainerImageBuilder(io.kubernetes.client.openapi.models.V1ContainerImageFluent fluent) { + + public V1ContainerImageBuilder( + io.kubernetes.client.openapi.models.V1ContainerImageFluent fluent) { this(fluent, false); } - public V1ContainerImageBuilder(io.kubernetes.client.openapi.models.V1ContainerImageFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ContainerImageBuilder( + io.kubernetes.client.openapi.models.V1ContainerImageFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ContainerImage(), validationEnabled); } - public V1ContainerImageBuilder(io.kubernetes.client.openapi.models.V1ContainerImageFluent fluent,io.kubernetes.client.openapi.models.V1ContainerImage instance) { + + public V1ContainerImageBuilder( + io.kubernetes.client.openapi.models.V1ContainerImageFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerImage instance) { this(fluent, instance, false); } - public V1ContainerImageBuilder(io.kubernetes.client.openapi.models.V1ContainerImageFluent fluent,io.kubernetes.client.openapi.models.V1ContainerImage instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ContainerImageBuilder( + io.kubernetes.client.openapi.models.V1ContainerImageFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerImage instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNames(instance.getNames()); fluent.withSizeBytes(instance.getSizeBytes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ContainerImageBuilder(io.kubernetes.client.openapi.models.V1ContainerImage instance) { - this(instance,false); + this(instance, false); } - public V1ContainerImageBuilder(io.kubernetes.client.openapi.models.V1ContainerImage instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ContainerImageBuilder( + io.kubernetes.client.openapi.models.V1ContainerImage instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNames(instance.getNames()); this.withSizeBytes(instance.getSizeBytes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ContainerImageFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ContainerImage build() { V1ContainerImage buildable = new V1ContainerImage(); buildable.setNames(fluent.getNames()); buildable.setSizeBytes(fluent.getSizeBytes()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ContainerImageBuilder that = (V1ContainerImageBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerImageFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerImageFluent.java index 99c74984d8..e75ec2e308 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerImageFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerImageFluent.java @@ -1,38 +1,57 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Long; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1ContainerImageFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToNames(java.lang.Integer index,java.lang.String item); - public A setToNames(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1ContainerImageFluent< + A extends io.kubernetes.client.openapi.models.V1ContainerImageFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToNames(java.lang.Integer index, java.lang.String item); + + public A setToNames(java.lang.Integer index, java.lang.String item); + public A addToNames(java.lang.String... items); + public A addAllToNames(java.util.Collection items); + public A removeFromNames(java.lang.String... items); + public A removeAllFromNames(java.util.Collection items); + public java.util.List getNames(); + public java.lang.String getName(java.lang.Integer index); + public java.lang.String getFirstName(); + public java.lang.String getLastName(); + public java.lang.String getMatchingName(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingName(java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingName( + java.util.function.Predicate predicate); + public A withNames(java.util.List names); + public A withNames(java.lang.String... names); + public java.lang.Boolean hasNames(); + public A addNewName(java.lang.String original); + public java.lang.Long getSizeBytes(); + public A withSizeBytes(java.lang.Long sizeBytes); + public java.lang.Boolean hasSizeBytes(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerImageFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerImageFluentImpl.java index 9e06377160..4375236ddc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerImageFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerImageFluentImpl.java @@ -1,103 +1,179 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1ContainerImageFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ContainerImageFluent{ - public V1ContainerImageFluentImpl() { - } +/** Generated */ +public class V1ContainerImageFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ContainerImageFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ContainerImageFluent { + public V1ContainerImageFluentImpl() {} + public V1ContainerImageFluentImpl(io.kubernetes.client.openapi.models.V1ContainerImage instance) { this.withNames(instance.getNames()); this.withSizeBytes(instance.getSizeBytes()); - } + private java.util.List names; private java.lang.Long sizeBytes; - public A addToNames(java.lang.Integer index,java.lang.String item) { - if (this.names == null) {this.names = new java.util.ArrayList();} + + public A addToNames(java.lang.Integer index, java.lang.String item) { + if (this.names == null) { + this.names = new java.util.ArrayList(); + } this.names.add(index, item); - return (A)this; + return (A) this; } - public A setToNames(java.lang.Integer index,java.lang.String item) { - if (this.names == null) {this.names = new java.util.ArrayList();} - this.names.set(index, item); return (A)this; + + public A setToNames(java.lang.Integer index, java.lang.String item) { + if (this.names == null) { + this.names = new java.util.ArrayList(); + } + this.names.set(index, item); + return (A) this; } + public A addToNames(java.lang.String... items) { - if (this.names == null) {this.names = new java.util.ArrayList();} - for (java.lang.String item : items) {this.names.add(item);} return (A)this; + if (this.names == null) { + this.names = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.names.add(item); + } + return (A) this; } + public A addAllToNames(java.util.Collection items) { - if (this.names == null) {this.names = new java.util.ArrayList();} - for (java.lang.String item : items) {this.names.add(item);} return (A)this; + if (this.names == null) { + this.names = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.names.add(item); + } + return (A) this; } + public A removeFromNames(java.lang.String... items) { - for (java.lang.String item : items) {if (this.names!= null){ this.names.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.names != null) { + this.names.remove(item); + } + } + return (A) this; } + public A removeAllFromNames(java.util.Collection items) { - for (java.lang.String item : items) {if (this.names!= null){ this.names.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.names != null) { + this.names.remove(item); + } + } + return (A) this; } + public java.util.List getNames() { return this.names; } + public java.lang.String getName(java.lang.Integer index) { return this.names.get(index); } + public java.lang.String getFirstName() { return this.names.get(0); } + public java.lang.String getLastName() { return this.names.get(names.size() - 1); } - public java.lang.String getMatchingName(java.util.function.Predicate predicate) { - for (java.lang.String item: names) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingName( + java.util.function.Predicate predicate) { + for (java.lang.String item : names) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingName(java.util.function.Predicate predicate) { - for (java.lang.String item: names) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingName( + java.util.function.Predicate predicate) { + for (java.lang.String item : names) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withNames(java.util.List names) { - if (names != null) {this.names = new java.util.ArrayList(); for (java.lang.String item : names){this.addToNames(item);}} else { this.names = null;} return (A) this; + if (names != null) { + this.names = new java.util.ArrayList(); + for (java.lang.String item : names) { + this.addToNames(item); + } + } else { + this.names = null; + } + return (A) this; } + public A withNames(java.lang.String... names) { - if (this.names != null) {this.names.clear();} - if (names != null) {for (java.lang.String item :names){ this.addToNames(item);}} return (A) this; + if (this.names != null) { + this.names.clear(); + } + if (names != null) { + for (java.lang.String item : names) { + this.addToNames(item); + } + } + return (A) this; } + public java.lang.Boolean hasNames() { return names != null && !names.isEmpty(); } + public A addNewName(java.lang.String original) { - return (A)addToNames(new String(original)); + return (A) addToNames(new String(original)); } + public java.lang.Long getSizeBytes() { return this.sizeBytes; } + public A withSizeBytes(java.lang.Long sizeBytes) { - this.sizeBytes=sizeBytes; return (A) this; + this.sizeBytes = sizeBytes; + return (A) this; } + public java.lang.Boolean hasSizeBytes() { return this.sizeBytes != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ContainerImageFluentImpl that = (V1ContainerImageFluentImpl) o; - if (names != null ? !names.equals(that.names) :that.names != null) return false; - if (sizeBytes != null ? !sizeBytes.equals(that.sizeBytes) :that.sizeBytes != null) return false; + if (names != null ? !names.equals(that.names) : that.names != null) return false; + if (sizeBytes != null ? !sizeBytes.equals(that.sizeBytes) : that.sizeBytes != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(names, sizeBytes, super.hashCode()); + return java.util.Objects.hash(names, sizeBytes, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerPortBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerPortBuilder.java index 9e6aa6a15d..5a2a3ba803 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerPortBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerPortBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ContainerPortBuilder extends io.kubernetes.client.openapi.models.V1ContainerPortFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ContainerPortBuilder + extends io.kubernetes.client.openapi.models.V1ContainerPortFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerPortBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ContainerPort, + io.kubernetes.client.openapi.models.V1ContainerPortBuilder> { public V1ContainerPortBuilder() { this(false); } + public V1ContainerPortBuilder(java.lang.Boolean validationEnabled) { this(new V1ContainerPort(), validationEnabled); } - public V1ContainerPortBuilder(io.kubernetes.client.openapi.models.V1ContainerPortFluent fluent) { + + public V1ContainerPortBuilder( + io.kubernetes.client.openapi.models.V1ContainerPortFluent fluent) { this(fluent, false); } - public V1ContainerPortBuilder(io.kubernetes.client.openapi.models.V1ContainerPortFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ContainerPortBuilder( + io.kubernetes.client.openapi.models.V1ContainerPortFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ContainerPort(), validationEnabled); } - public V1ContainerPortBuilder(io.kubernetes.client.openapi.models.V1ContainerPortFluent fluent,io.kubernetes.client.openapi.models.V1ContainerPort instance) { + + public V1ContainerPortBuilder( + io.kubernetes.client.openapi.models.V1ContainerPortFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerPort instance) { this(fluent, instance, false); } - public V1ContainerPortBuilder(io.kubernetes.client.openapi.models.V1ContainerPortFluent fluent,io.kubernetes.client.openapi.models.V1ContainerPort instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ContainerPortBuilder( + io.kubernetes.client.openapi.models.V1ContainerPortFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerPort instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainerPort(instance.getContainerPort()); fluent.withHostIP(instance.getHostIP()); @@ -31,13 +58,17 @@ public V1ContainerPortBuilder(io.kubernetes.client.openapi.models.V1ContainerPor fluent.withProtocol(instance.getProtocol()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ContainerPortBuilder(io.kubernetes.client.openapi.models.V1ContainerPort instance) { - this(instance,false); + this(instance, false); } - public V1ContainerPortBuilder(io.kubernetes.client.openapi.models.V1ContainerPort instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ContainerPortBuilder( + io.kubernetes.client.openapi.models.V1ContainerPort instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainerPort(instance.getContainerPort()); this.withHostIP(instance.getHostIP()); @@ -48,10 +79,12 @@ public V1ContainerPortBuilder(io.kubernetes.client.openapi.models.V1ContainerPor this.withProtocol(instance.getProtocol()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ContainerPortFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ContainerPort build() { V1ContainerPort buildable = new V1ContainerPort(); buildable.setContainerPort(fluent.getContainerPort()); @@ -61,18 +94,23 @@ public io.kubernetes.client.openapi.models.V1ContainerPort build() { buildable.setProtocol(fluent.getProtocol()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ContainerPortBuilder that = (V1ContainerPortBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerPortFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerPortFluent.java index 1f0ed342b5..5f84c49c1d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerPortFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerPortFluent.java @@ -1,42 +1,56 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ContainerPortFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ContainerPortFluent< + A extends io.kubernetes.client.openapi.models.V1ContainerPortFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getContainerPort(); + public A withContainerPort(java.lang.Integer containerPort); + public java.lang.Boolean hasContainerPort(); + public java.lang.String getHostIP(); + public A withHostIP(java.lang.String hostIP); + public java.lang.Boolean hasHostIP(); - - /** - * Method is deprecated. use withHostIP instead. - */ + + /** Method is deprecated. use withHostIP instead. */ @java.lang.Deprecated public A withNewHostIP(java.lang.String original); + public java.lang.Integer getHostPort(); + public A withHostPort(java.lang.Integer hostPort); + public java.lang.Boolean hasHostPort(); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public io.kubernetes.client.openapi.models.V1ContainerPort.ProtocolEnum getProtocol(); + public A withProtocol(io.kubernetes.client.openapi.models.V1ContainerPort.ProtocolEnum protocol); + public java.lang.Boolean hasProtocol(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerPortFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerPortFluentImpl.java index f92c845061..8087f2f577 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerPortFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerPortFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ContainerPortFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ContainerPortFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ContainerPortFluent { + public V1ContainerPortFluentImpl() {} - /** - * Generated - */ -public class V1ContainerPortFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ContainerPortFluent{ - public V1ContainerPortFluentImpl() { - } public V1ContainerPortFluentImpl(io.kubernetes.client.openapi.models.V1ContainerPort instance) { this.withContainerPort(instance.getContainerPort()); @@ -23,87 +29,107 @@ public V1ContainerPortFluentImpl(io.kubernetes.client.openapi.models.V1Container this.withName(instance.getName()); this.withProtocol(instance.getProtocol()); - } + private java.lang.Integer containerPort; private java.lang.String hostIP; private java.lang.Integer hostPort; private java.lang.String name; private io.kubernetes.client.openapi.models.V1ContainerPort.ProtocolEnum protocol; + public java.lang.Integer getContainerPort() { return this.containerPort; } + public A withContainerPort(java.lang.Integer containerPort) { - this.containerPort=containerPort; return (A) this; + this.containerPort = containerPort; + return (A) this; } + public java.lang.Boolean hasContainerPort() { return this.containerPort != null; } + public java.lang.String getHostIP() { return this.hostIP; } + public A withHostIP(java.lang.String hostIP) { - this.hostIP=hostIP; return (A) this; + this.hostIP = hostIP; + return (A) this; } + public java.lang.Boolean hasHostIP() { return this.hostIP != null; } - - /** - * Method is deprecated. use withHostIP instead. - */ + + /** Method is deprecated. use withHostIP instead. */ @java.lang.Deprecated public A withNewHostIP(java.lang.String original) { - return (A)withHostIP(new String(original)); + return (A) withHostIP(new String(original)); } + public java.lang.Integer getHostPort() { return this.hostPort; } + public A withHostPort(java.lang.Integer hostPort) { - this.hostPort=hostPort; return (A) this; + this.hostPort = hostPort; + return (A) this; } + public java.lang.Boolean hasHostPort() { return this.hostPort != null; } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public io.kubernetes.client.openapi.models.V1ContainerPort.ProtocolEnum getProtocol() { return this.protocol; } + public A withProtocol(io.kubernetes.client.openapi.models.V1ContainerPort.ProtocolEnum protocol) { - this.protocol=protocol; return (A) this; + this.protocol = protocol; + return (A) this; } + public java.lang.Boolean hasProtocol() { return this.protocol != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ContainerPortFluentImpl that = (V1ContainerPortFluentImpl) o; - if (containerPort != null ? !containerPort.equals(that.containerPort) :that.containerPort != null) return false; - if (hostIP != null ? !hostIP.equals(that.hostIP) :that.hostIP != null) return false; - if (hostPort != null ? !hostPort.equals(that.hostPort) :that.hostPort != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (protocol != null ? !protocol.equals(that.protocol) :that.protocol != null) return false; + if (containerPort != null + ? !containerPort.equals(that.containerPort) + : that.containerPort != null) return false; + if (hostIP != null ? !hostIP.equals(that.hostIP) : that.hostIP != null) return false; + if (hostPort != null ? !hostPort.equals(that.hostPort) : that.hostPort != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (protocol != null ? !protocol.equals(that.protocol) : that.protocol != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(containerPort, hostIP, hostPort, name, protocol, super.hashCode()); + return java.util.Objects.hash( + containerPort, hostIP, hostPort, name, protocol, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateBuilder.java index 1ebc7a89b2..e2f2835d1c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateBuilder.java @@ -1,49 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ContainerStateBuilder extends io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ContainerStateBuilder + extends io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerStateBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ContainerState, + io.kubernetes.client.openapi.models.V1ContainerStateBuilder> { public V1ContainerStateBuilder() { this(false); } + public V1ContainerStateBuilder(java.lang.Boolean validationEnabled) { this(new V1ContainerState(), validationEnabled); } - public V1ContainerStateBuilder(io.kubernetes.client.openapi.models.V1ContainerStateFluent fluent) { + + public V1ContainerStateBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateFluent fluent) { this(fluent, false); } - public V1ContainerStateBuilder(io.kubernetes.client.openapi.models.V1ContainerStateFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ContainerStateBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ContainerState(), validationEnabled); } - public V1ContainerStateBuilder(io.kubernetes.client.openapi.models.V1ContainerStateFluent fluent,io.kubernetes.client.openapi.models.V1ContainerState instance) { + + public V1ContainerStateBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerState instance) { this(fluent, instance, false); } - public V1ContainerStateBuilder(io.kubernetes.client.openapi.models.V1ContainerStateFluent fluent,io.kubernetes.client.openapi.models.V1ContainerState instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ContainerStateBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerState instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withRunning(instance.getRunning()); fluent.withTerminated(instance.getTerminated()); fluent.withWaiting(instance.getWaiting()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ContainerStateBuilder(io.kubernetes.client.openapi.models.V1ContainerState instance) { - this(instance,false); + this(instance, false); } - public V1ContainerStateBuilder(io.kubernetes.client.openapi.models.V1ContainerState instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ContainerStateBuilder( + io.kubernetes.client.openapi.models.V1ContainerState instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withRunning(instance.getRunning()); this.withTerminated(instance.getTerminated()); this.withWaiting(instance.getWaiting()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ContainerStateFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ContainerState build() { V1ContainerState buildable = new V1ContainerState(); buildable.setRunning(fluent.getRunning()); @@ -51,18 +84,23 @@ public io.kubernetes.client.openapi.models.V1ContainerState build() { buildable.setWaiting(fluent.getWaiting()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ContainerStateBuilder that = (V1ContainerStateBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateFluent.java index 5cbca0f7d6..c9f1090993 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateFluent.java @@ -1,75 +1,132 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ContainerStateFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1ContainerStateFluent< + A extends io.kubernetes.client.openapi.models.V1ContainerStateFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildRunning instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ContainerStateRunning getRunning(); + public io.kubernetes.client.openapi.models.V1ContainerStateRunning buildRunning(); + public A withRunning(io.kubernetes.client.openapi.models.V1ContainerStateRunning running); + public java.lang.Boolean hasRunning(); - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested withNewRunning(); - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested withNewRunningLike(io.kubernetes.client.openapi.models.V1ContainerStateRunning item); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested + withNewRunning(); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested + withNewRunningLike(io.kubernetes.client.openapi.models.V1ContainerStateRunning item); + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested editRunning(); - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested editOrNewRunning(); - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested editOrNewRunningLike(io.kubernetes.client.openapi.models.V1ContainerStateRunning item); - + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested + editOrNewRunning(); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested + editOrNewRunningLike(io.kubernetes.client.openapi.models.V1ContainerStateRunning item); + /** * This method has been deprecated, please use method buildTerminated instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ContainerStateTerminated getTerminated(); + public io.kubernetes.client.openapi.models.V1ContainerStateTerminated buildTerminated(); - public A withTerminated(io.kubernetes.client.openapi.models.V1ContainerStateTerminated terminated); + + public A withTerminated( + io.kubernetes.client.openapi.models.V1ContainerStateTerminated terminated); + public java.lang.Boolean hasTerminated(); - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested withNewTerminated(); - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested withNewTerminatedLike(io.kubernetes.client.openapi.models.V1ContainerStateTerminated item); - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested editTerminated(); - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested editOrNewTerminated(); - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested editOrNewTerminatedLike(io.kubernetes.client.openapi.models.V1ContainerStateTerminated item); - + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested + withNewTerminated(); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested + withNewTerminatedLike(io.kubernetes.client.openapi.models.V1ContainerStateTerminated item); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested + editTerminated(); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested + editOrNewTerminated(); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested + editOrNewTerminatedLike(io.kubernetes.client.openapi.models.V1ContainerStateTerminated item); + /** * This method has been deprecated, please use method buildWaiting instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ContainerStateWaiting getWaiting(); + public io.kubernetes.client.openapi.models.V1ContainerStateWaiting buildWaiting(); + public A withWaiting(io.kubernetes.client.openapi.models.V1ContainerStateWaiting waiting); + public java.lang.Boolean hasWaiting(); - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested withNewWaiting(); - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested withNewWaitingLike(io.kubernetes.client.openapi.models.V1ContainerStateWaiting item); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested + withNewWaiting(); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested + withNewWaitingLike(io.kubernetes.client.openapi.models.V1ContainerStateWaiting item); + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested editWaiting(); - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested editOrNewWaiting(); - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested editOrNewWaitingLike(io.kubernetes.client.openapi.models.V1ContainerStateWaiting item); - public interface RunningNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent>{ + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested + editOrNewWaiting(); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested + editOrNewWaitingLike(io.kubernetes.client.openapi.models.V1ContainerStateWaiting item); + + public interface RunningNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent< + io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested> { public N and(); + public N endRunning(); - } - public interface TerminatedNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent>{ + + public interface TerminatedNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent< + io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested> { public N and(); + public N endTerminated(); - } - public interface WaitingNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent>{ + + public interface WaitingNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent< + io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested> { public N and(); + public N endWaiting(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateFluentImpl.java index f6a64d2229..ae4c22a732 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateFluentImpl.java @@ -1,189 +1,295 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1ContainerStateFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ContainerStateFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ContainerStateFluent { + public V1ContainerStateFluentImpl() {} - /** - * Generated - */ -public class V1ContainerStateFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ContainerStateFluent{ - public V1ContainerStateFluentImpl() { - } public V1ContainerStateFluentImpl(io.kubernetes.client.openapi.models.V1ContainerState instance) { this.withRunning(instance.getRunning()); this.withTerminated(instance.getTerminated()); this.withWaiting(instance.getWaiting()); - } + private io.kubernetes.client.openapi.models.V1ContainerStateRunningBuilder running; private io.kubernetes.client.openapi.models.V1ContainerStateTerminatedBuilder terminated; private io.kubernetes.client.openapi.models.V1ContainerStateWaitingBuilder waiting; - + /** * This method has been deprecated, please use method buildRunning instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ContainerStateRunning getRunning() { - return this.running!=null ?this.running.build():null; + return this.running != null ? this.running.build() : null; } + public io.kubernetes.client.openapi.models.V1ContainerStateRunning buildRunning() { - return this.running!=null ?this.running.build():null; + return this.running != null ? this.running.build() : null; } + public A withRunning(io.kubernetes.client.openapi.models.V1ContainerStateRunning running) { _visitables.get("running").remove(this.running); - if (running!=null){ this.running= new io.kubernetes.client.openapi.models.V1ContainerStateRunningBuilder(running); _visitables.get("running").add(this.running);} return (A) this; + if (running != null) { + this.running = + new io.kubernetes.client.openapi.models.V1ContainerStateRunningBuilder(running); + _visitables.get("running").add(this.running); + } + return (A) this; } + public java.lang.Boolean hasRunning() { return this.running != null; } - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested withNewRunning() { + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested + withNewRunning() { return new io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl.RunningNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested withNewRunningLike(io.kubernetes.client.openapi.models.V1ContainerStateRunning item) { - return new io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl.RunningNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested + withNewRunningLike(io.kubernetes.client.openapi.models.V1ContainerStateRunning item) { + return new io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl.RunningNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested editRunning() { return withNewRunningLike(getRunning()); } - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested editOrNewRunning() { - return withNewRunningLike(getRunning() != null ? getRunning(): new io.kubernetes.client.openapi.models.V1ContainerStateRunningBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested + editOrNewRunning() { + return withNewRunningLike( + getRunning() != null + ? getRunning() + : new io.kubernetes.client.openapi.models.V1ContainerStateRunningBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested editOrNewRunningLike(io.kubernetes.client.openapi.models.V1ContainerStateRunning item) { - return withNewRunningLike(getRunning() != null ? getRunning(): item); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested + editOrNewRunningLike(io.kubernetes.client.openapi.models.V1ContainerStateRunning item) { + return withNewRunningLike(getRunning() != null ? getRunning() : item); } - + /** * This method has been deprecated, please use method buildTerminated instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ContainerStateTerminated getTerminated() { - return this.terminated!=null ?this.terminated.build():null; + return this.terminated != null ? this.terminated.build() : null; } + public io.kubernetes.client.openapi.models.V1ContainerStateTerminated buildTerminated() { - return this.terminated!=null ?this.terminated.build():null; + return this.terminated != null ? this.terminated.build() : null; } - public A withTerminated(io.kubernetes.client.openapi.models.V1ContainerStateTerminated terminated) { + + public A withTerminated( + io.kubernetes.client.openapi.models.V1ContainerStateTerminated terminated) { _visitables.get("terminated").remove(this.terminated); - if (terminated!=null){ this.terminated= new io.kubernetes.client.openapi.models.V1ContainerStateTerminatedBuilder(terminated); _visitables.get("terminated").add(this.terminated);} return (A) this; + if (terminated != null) { + this.terminated = + new io.kubernetes.client.openapi.models.V1ContainerStateTerminatedBuilder(terminated); + _visitables.get("terminated").add(this.terminated); + } + return (A) this; } + public java.lang.Boolean hasTerminated() { return this.terminated != null; } - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested withNewTerminated() { - return new io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl.TerminatedNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested + withNewTerminated() { + return new io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl + .TerminatedNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested withNewTerminatedLike(io.kubernetes.client.openapi.models.V1ContainerStateTerminated item) { - return new io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl.TerminatedNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested + withNewTerminatedLike(io.kubernetes.client.openapi.models.V1ContainerStateTerminated item) { + return new io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl.TerminatedNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested editTerminated() { + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested + editTerminated() { return withNewTerminatedLike(getTerminated()); } - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested editOrNewTerminated() { - return withNewTerminatedLike(getTerminated() != null ? getTerminated(): new io.kubernetes.client.openapi.models.V1ContainerStateTerminatedBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested + editOrNewTerminated() { + return withNewTerminatedLike( + getTerminated() != null + ? getTerminated() + : new io.kubernetes.client.openapi.models.V1ContainerStateTerminatedBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested editOrNewTerminatedLike(io.kubernetes.client.openapi.models.V1ContainerStateTerminated item) { - return withNewTerminatedLike(getTerminated() != null ? getTerminated(): item); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested + editOrNewTerminatedLike(io.kubernetes.client.openapi.models.V1ContainerStateTerminated item) { + return withNewTerminatedLike(getTerminated() != null ? getTerminated() : item); } - + /** * This method has been deprecated, please use method buildWaiting instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ContainerStateWaiting getWaiting() { - return this.waiting!=null ?this.waiting.build():null; + return this.waiting != null ? this.waiting.build() : null; } + public io.kubernetes.client.openapi.models.V1ContainerStateWaiting buildWaiting() { - return this.waiting!=null ?this.waiting.build():null; + return this.waiting != null ? this.waiting.build() : null; } + public A withWaiting(io.kubernetes.client.openapi.models.V1ContainerStateWaiting waiting) { _visitables.get("waiting").remove(this.waiting); - if (waiting!=null){ this.waiting= new io.kubernetes.client.openapi.models.V1ContainerStateWaitingBuilder(waiting); _visitables.get("waiting").add(this.waiting);} return (A) this; + if (waiting != null) { + this.waiting = + new io.kubernetes.client.openapi.models.V1ContainerStateWaitingBuilder(waiting); + _visitables.get("waiting").add(this.waiting); + } + return (A) this; } + public java.lang.Boolean hasWaiting() { return this.waiting != null; } - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested withNewWaiting() { + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested + withNewWaiting() { return new io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl.WaitingNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested withNewWaitingLike(io.kubernetes.client.openapi.models.V1ContainerStateWaiting item) { - return new io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl.WaitingNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested + withNewWaitingLike(io.kubernetes.client.openapi.models.V1ContainerStateWaiting item) { + return new io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl.WaitingNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested editWaiting() { return withNewWaitingLike(getWaiting()); } - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested editOrNewWaiting() { - return withNewWaitingLike(getWaiting() != null ? getWaiting(): new io.kubernetes.client.openapi.models.V1ContainerStateWaitingBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested + editOrNewWaiting() { + return withNewWaitingLike( + getWaiting() != null + ? getWaiting() + : new io.kubernetes.client.openapi.models.V1ContainerStateWaitingBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested editOrNewWaitingLike(io.kubernetes.client.openapi.models.V1ContainerStateWaiting item) { - return withNewWaitingLike(getWaiting() != null ? getWaiting(): item); + + public io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested + editOrNewWaitingLike(io.kubernetes.client.openapi.models.V1ContainerStateWaiting item) { + return withNewWaitingLike(getWaiting() != null ? getWaiting() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ContainerStateFluentImpl that = (V1ContainerStateFluentImpl) o; - if (running != null ? !running.equals(that.running) :that.running != null) return false; - if (terminated != null ? !terminated.equals(that.terminated) :that.terminated != null) return false; - if (waiting != null ? !waiting.equals(that.waiting) :that.waiting != null) return false; + if (running != null ? !running.equals(that.running) : that.running != null) return false; + if (terminated != null ? !terminated.equals(that.terminated) : that.terminated != null) + return false; + if (waiting != null ? !waiting.equals(that.waiting) : that.waiting != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(running, terminated, waiting, super.hashCode()); + return java.util.Objects.hash(running, terminated, waiting, super.hashCode()); } - public class RunningNestedImpl extends io.kubernetes.client.openapi.models.V1ContainerStateRunningFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested,io.kubernetes.client.fluent.Nested{ + + public class RunningNestedImpl + extends io.kubernetes.client.openapi.models.V1ContainerStateRunningFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested> + implements io.kubernetes.client.openapi.models.V1ContainerStateFluent.RunningNested, + io.kubernetes.client.fluent.Nested { RunningNestedImpl(io.kubernetes.client.openapi.models.V1ContainerStateRunning item) { - this.builder = new io.kubernetes.client.openapi.models.V1ContainerStateRunningBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ContainerStateRunningBuilder(this, item); } + RunningNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ContainerStateRunningBuilder(this); } + io.kubernetes.client.openapi.models.V1ContainerStateRunningBuilder builder; + public N and() { return (N) V1ContainerStateFluentImpl.this.withRunning(builder.build()); } + public N endRunning() { return and(); } - } - public class TerminatedNestedImpl extends io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested,io.kubernetes.client.fluent.Nested{ + + public class TerminatedNestedImpl + extends io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested> + implements io.kubernetes.client.openapi.models.V1ContainerStateFluent.TerminatedNested, + io.kubernetes.client.fluent.Nested { TerminatedNestedImpl(io.kubernetes.client.openapi.models.V1ContainerStateTerminated item) { - this.builder = new io.kubernetes.client.openapi.models.V1ContainerStateTerminatedBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ContainerStateTerminatedBuilder(this, item); } + TerminatedNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1ContainerStateTerminatedBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1ContainerStateTerminatedBuilder(this); } + io.kubernetes.client.openapi.models.V1ContainerStateTerminatedBuilder builder; + public N and() { return (N) V1ContainerStateFluentImpl.this.withTerminated(builder.build()); } + public N endTerminated() { return and(); } - } - public class WaitingNestedImpl extends io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested,io.kubernetes.client.fluent.Nested{ + + public class WaitingNestedImpl + extends io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested> + implements io.kubernetes.client.openapi.models.V1ContainerStateFluent.WaitingNested, + io.kubernetes.client.fluent.Nested { WaitingNestedImpl(io.kubernetes.client.openapi.models.V1ContainerStateWaiting item) { - this.builder = new io.kubernetes.client.openapi.models.V1ContainerStateWaitingBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ContainerStateWaitingBuilder(this, item); } + WaitingNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ContainerStateWaitingBuilder(this); } + io.kubernetes.client.openapi.models.V1ContainerStateWaitingBuilder builder; + public N and() { return (N) V1ContainerStateFluentImpl.this.withWaiting(builder.build()); } + public N endWaiting() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateRunningBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateRunningBuilder.java index 83d0dc34cd..045d3585a5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateRunningBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateRunningBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ContainerStateRunningBuilder extends io.kubernetes.client.openapi.models.V1ContainerStateRunningFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ContainerStateRunningBuilder + extends io.kubernetes.client.openapi.models.V1ContainerStateRunningFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerStateRunningBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ContainerStateRunning, + io.kubernetes.client.openapi.models.V1ContainerStateRunningBuilder> { public V1ContainerStateRunningBuilder() { this(false); } + public V1ContainerStateRunningBuilder(java.lang.Boolean validationEnabled) { this(new V1ContainerStateRunning(), validationEnabled); } - public V1ContainerStateRunningBuilder(io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent fluent) { + + public V1ContainerStateRunningBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent fluent) { this(fluent, false); } - public V1ContainerStateRunningBuilder(io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ContainerStateRunningBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ContainerStateRunning(), validationEnabled); } - public V1ContainerStateRunningBuilder(io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent fluent,io.kubernetes.client.openapi.models.V1ContainerStateRunning instance) { + + public V1ContainerStateRunningBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerStateRunning instance) { this(fluent, instance, false); } - public V1ContainerStateRunningBuilder(io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent fluent,io.kubernetes.client.openapi.models.V1ContainerStateRunning instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ContainerStateRunningBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerStateRunning instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withStartedAt(instance.getStartedAt()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ContainerStateRunningBuilder(io.kubernetes.client.openapi.models.V1ContainerStateRunning instance) { - this(instance,false); + + public V1ContainerStateRunningBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateRunning instance) { + this(instance, false); } - public V1ContainerStateRunningBuilder(io.kubernetes.client.openapi.models.V1ContainerStateRunning instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ContainerStateRunningBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateRunning instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withStartedAt(instance.getStartedAt()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ContainerStateRunning build() { V1ContainerStateRunning buildable = new V1ContainerStateRunning(); buildable.setStartedAt(fluent.getStartedAt()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ContainerStateRunningBuilder that = (V1ContainerStateRunningBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateRunningFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateRunningFluent.java index 3789a3105a..209f7a1af4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateRunningFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateRunningFluent.java @@ -1,17 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ContainerStateRunningFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ContainerStateRunningFluent< + A extends io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getStartedAt(); + public A withStartedAt(java.time.OffsetDateTime startedAt); + public java.lang.Boolean hasStartedAt(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateRunningFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateRunningFluentImpl.java index f9ed1eb7ae..bfd2ba6d8b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateRunningFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateRunningFluentImpl.java @@ -1,39 +1,54 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1ContainerStateRunningFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent { + public V1ContainerStateRunningFluentImpl() {} - /** - * Generated - */ -public class V1ContainerStateRunningFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ContainerStateRunningFluent{ - public V1ContainerStateRunningFluentImpl() { - } - public V1ContainerStateRunningFluentImpl(io.kubernetes.client.openapi.models.V1ContainerStateRunning instance) { + public V1ContainerStateRunningFluentImpl( + io.kubernetes.client.openapi.models.V1ContainerStateRunning instance) { this.withStartedAt(instance.getStartedAt()); - } + private java.time.OffsetDateTime startedAt; + public java.time.OffsetDateTime getStartedAt() { return this.startedAt; } + public A withStartedAt(java.time.OffsetDateTime startedAt) { - this.startedAt=startedAt; return (A) this; + this.startedAt = startedAt; + return (A) this; } + public java.lang.Boolean hasStartedAt() { return this.startedAt != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ContainerStateRunningFluentImpl that = (V1ContainerStateRunningFluentImpl) o; - if (startedAt != null ? !startedAt.equals(that.startedAt) :that.startedAt != null) return false; + if (startedAt != null ? !startedAt.equals(that.startedAt) : that.startedAt != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(startedAt, super.hashCode()); + return java.util.Objects.hash(startedAt, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateTerminatedBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateTerminatedBuilder.java index 78d688f54a..e7fe993908 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateTerminatedBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateTerminatedBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ContainerStateTerminatedBuilder extends io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ContainerStateTerminatedBuilder + extends io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerStateTerminatedBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ContainerStateTerminated, + io.kubernetes.client.openapi.models.V1ContainerStateTerminatedBuilder> { public V1ContainerStateTerminatedBuilder() { this(false); } + public V1ContainerStateTerminatedBuilder(java.lang.Boolean validationEnabled) { this(new V1ContainerStateTerminated(), validationEnabled); } - public V1ContainerStateTerminatedBuilder(io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent fluent) { + + public V1ContainerStateTerminatedBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent fluent) { this(fluent, false); } - public V1ContainerStateTerminatedBuilder(io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ContainerStateTerminatedBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ContainerStateTerminated(), validationEnabled); } - public V1ContainerStateTerminatedBuilder(io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent fluent,io.kubernetes.client.openapi.models.V1ContainerStateTerminated instance) { + + public V1ContainerStateTerminatedBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerStateTerminated instance) { this(fluent, instance, false); } - public V1ContainerStateTerminatedBuilder(io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent fluent,io.kubernetes.client.openapi.models.V1ContainerStateTerminated instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ContainerStateTerminatedBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerStateTerminated instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainerID(instance.getContainerID()); fluent.withExitCode(instance.getExitCode()); @@ -35,13 +62,18 @@ public V1ContainerStateTerminatedBuilder(io.kubernetes.client.openapi.models.V1C fluent.withStartedAt(instance.getStartedAt()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ContainerStateTerminatedBuilder(io.kubernetes.client.openapi.models.V1ContainerStateTerminated instance) { - this(instance,false); + + public V1ContainerStateTerminatedBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateTerminated instance) { + this(instance, false); } - public V1ContainerStateTerminatedBuilder(io.kubernetes.client.openapi.models.V1ContainerStateTerminated instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ContainerStateTerminatedBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateTerminated instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainerID(instance.getContainerID()); this.withExitCode(instance.getExitCode()); @@ -56,10 +88,12 @@ public V1ContainerStateTerminatedBuilder(io.kubernetes.client.openapi.models.V1C this.withStartedAt(instance.getStartedAt()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ContainerStateTerminated build() { V1ContainerStateTerminated buildable = new V1ContainerStateTerminated(); buildable.setContainerID(fluent.getContainerID()); @@ -71,18 +105,23 @@ public io.kubernetes.client.openapi.models.V1ContainerStateTerminated build() { buildable.setStartedAt(fluent.getStartedAt()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ContainerStateTerminatedBuilder that = (V1ContainerStateTerminatedBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateTerminatedFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateTerminatedFluent.java index 29664115f5..8c3ffef64a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateTerminatedFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateTerminatedFluent.java @@ -1,55 +1,72 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ContainerStateTerminatedFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ContainerStateTerminatedFluent< + A extends io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getContainerID(); + public A withContainerID(java.lang.String containerID); + public java.lang.Boolean hasContainerID(); - - /** - * Method is deprecated. use withContainerID instead. - */ + + /** Method is deprecated. use withContainerID instead. */ @java.lang.Deprecated public A withNewContainerID(java.lang.String original); + public java.lang.Integer getExitCode(); + public A withExitCode(java.lang.Integer exitCode); + public java.lang.Boolean hasExitCode(); + public java.time.OffsetDateTime getFinishedAt(); + public A withFinishedAt(java.time.OffsetDateTime finishedAt); + public java.lang.Boolean hasFinishedAt(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.Integer getSignal(); + public A withSignal(java.lang.Integer signal); + public java.lang.Boolean hasSignal(); + public java.time.OffsetDateTime getStartedAt(); + public A withStartedAt(java.time.OffsetDateTime startedAt); + public java.lang.Boolean hasStartedAt(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateTerminatedFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateTerminatedFluentImpl.java index 2ff88b3373..5527dc750e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateTerminatedFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateTerminatedFluentImpl.java @@ -1,20 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1ContainerStateTerminatedFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent{ - public V1ContainerStateTerminatedFluentImpl() { - } - public V1ContainerStateTerminatedFluentImpl(io.kubernetes.client.openapi.models.V1ContainerStateTerminated instance) { +/** Generated */ +public class V1ContainerStateTerminatedFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ContainerStateTerminatedFluent { + public V1ContainerStateTerminatedFluentImpl() {} + + public V1ContainerStateTerminatedFluentImpl( + io.kubernetes.client.openapi.models.V1ContainerStateTerminated instance) { this.withContainerID(instance.getContainerID()); this.withExitCode(instance.getExitCode()); @@ -28,8 +34,8 @@ public V1ContainerStateTerminatedFluentImpl(io.kubernetes.client.openapi.models. this.withSignal(instance.getSignal()); this.withStartedAt(instance.getStartedAt()); - } + private java.lang.String containerID; private java.lang.Integer exitCode; private java.time.OffsetDateTime finishedAt; @@ -37,108 +43,135 @@ public V1ContainerStateTerminatedFluentImpl(io.kubernetes.client.openapi.models. private java.lang.String reason; private java.lang.Integer signal; private java.time.OffsetDateTime startedAt; + public java.lang.String getContainerID() { return this.containerID; } + public A withContainerID(java.lang.String containerID) { - this.containerID=containerID; return (A) this; + this.containerID = containerID; + return (A) this; } + public java.lang.Boolean hasContainerID() { return this.containerID != null; } - - /** - * Method is deprecated. use withContainerID instead. - */ + + /** Method is deprecated. use withContainerID instead. */ @java.lang.Deprecated public A withNewContainerID(java.lang.String original) { - return (A)withContainerID(new String(original)); + return (A) withContainerID(new String(original)); } + public java.lang.Integer getExitCode() { return this.exitCode; } + public A withExitCode(java.lang.Integer exitCode) { - this.exitCode=exitCode; return (A) this; + this.exitCode = exitCode; + return (A) this; } + public java.lang.Boolean hasExitCode() { return this.exitCode != null; } + public java.time.OffsetDateTime getFinishedAt() { return this.finishedAt; } + public A withFinishedAt(java.time.OffsetDateTime finishedAt) { - this.finishedAt=finishedAt; return (A) this; + this.finishedAt = finishedAt; + return (A) this; } + public java.lang.Boolean hasFinishedAt() { return this.finishedAt != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.Integer getSignal() { return this.signal; } + public A withSignal(java.lang.Integer signal) { - this.signal=signal; return (A) this; + this.signal = signal; + return (A) this; } + public java.lang.Boolean hasSignal() { return this.signal != null; } + public java.time.OffsetDateTime getStartedAt() { return this.startedAt; } + public A withStartedAt(java.time.OffsetDateTime startedAt) { - this.startedAt=startedAt; return (A) this; + this.startedAt = startedAt; + return (A) this; } + public java.lang.Boolean hasStartedAt() { return this.startedAt != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ContainerStateTerminatedFluentImpl that = (V1ContainerStateTerminatedFluentImpl) o; - if (containerID != null ? !containerID.equals(that.containerID) :that.containerID != null) return false; - if (exitCode != null ? !exitCode.equals(that.exitCode) :that.exitCode != null) return false; - if (finishedAt != null ? !finishedAt.equals(that.finishedAt) :that.finishedAt != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (signal != null ? !signal.equals(that.signal) :that.signal != null) return false; - if (startedAt != null ? !startedAt.equals(that.startedAt) :that.startedAt != null) return false; + if (containerID != null ? !containerID.equals(that.containerID) : that.containerID != null) + return false; + if (exitCode != null ? !exitCode.equals(that.exitCode) : that.exitCode != null) return false; + if (finishedAt != null ? !finishedAt.equals(that.finishedAt) : that.finishedAt != null) + return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (signal != null ? !signal.equals(that.signal) : that.signal != null) return false; + if (startedAt != null ? !startedAt.equals(that.startedAt) : that.startedAt != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(containerID, exitCode, finishedAt, message, reason, signal, startedAt, super.hashCode()); + return java.util.Objects.hash( + containerID, exitCode, finishedAt, message, reason, signal, startedAt, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateWaitingBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateWaitingBuilder.java index f4e5bb539a..f59cf52ff1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateWaitingBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateWaitingBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ContainerStateWaitingBuilder extends io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ContainerStateWaitingBuilder + extends io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerStateWaitingBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ContainerStateWaiting, + io.kubernetes.client.openapi.models.V1ContainerStateWaitingBuilder> { public V1ContainerStateWaitingBuilder() { this(false); } + public V1ContainerStateWaitingBuilder(java.lang.Boolean validationEnabled) { this(new V1ContainerStateWaiting(), validationEnabled); } - public V1ContainerStateWaitingBuilder(io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent fluent) { + + public V1ContainerStateWaitingBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent fluent) { this(fluent, false); } - public V1ContainerStateWaitingBuilder(io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ContainerStateWaitingBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ContainerStateWaiting(), validationEnabled); } - public V1ContainerStateWaitingBuilder(io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent fluent,io.kubernetes.client.openapi.models.V1ContainerStateWaiting instance) { + + public V1ContainerStateWaitingBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerStateWaiting instance) { this(fluent, instance, false); } - public V1ContainerStateWaitingBuilder(io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent fluent,io.kubernetes.client.openapi.models.V1ContainerStateWaiting instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ContainerStateWaitingBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerStateWaiting instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMessage(instance.getMessage()); fluent.withReason(instance.getReason()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ContainerStateWaitingBuilder(io.kubernetes.client.openapi.models.V1ContainerStateWaiting instance) { - this(instance,false); + + public V1ContainerStateWaitingBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateWaiting instance) { + this(instance, false); } - public V1ContainerStateWaitingBuilder(io.kubernetes.client.openapi.models.V1ContainerStateWaiting instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ContainerStateWaitingBuilder( + io.kubernetes.client.openapi.models.V1ContainerStateWaiting instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMessage(instance.getMessage()); this.withReason(instance.getReason()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ContainerStateWaiting build() { V1ContainerStateWaiting buildable = new V1ContainerStateWaiting(); buildable.setMessage(fluent.getMessage()); buildable.setReason(fluent.getReason()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ContainerStateWaitingBuilder that = (V1ContainerStateWaitingBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateWaitingFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateWaitingFluent.java index 43ea213682..6178d762f8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateWaitingFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateWaitingFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ContainerStateWaitingFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ContainerStateWaitingFluent< + A extends io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateWaitingFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateWaitingFluentImpl.java index 50b96848c6..0bb32b68a9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateWaitingFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStateWaitingFluentImpl.java @@ -1,69 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ContainerStateWaitingFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent { + public V1ContainerStateWaitingFluentImpl() {} - /** - * Generated - */ -public class V1ContainerStateWaitingFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ContainerStateWaitingFluent{ - public V1ContainerStateWaitingFluentImpl() { - } - public V1ContainerStateWaitingFluentImpl(io.kubernetes.client.openapi.models.V1ContainerStateWaiting instance) { + public V1ContainerStateWaitingFluentImpl( + io.kubernetes.client.openapi.models.V1ContainerStateWaiting instance) { this.withMessage(instance.getMessage()); this.withReason(instance.getReason()); - } + private java.lang.String message; private java.lang.String reason; + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ContainerStateWaitingFluentImpl that = (V1ContainerStateWaitingFluentImpl) o; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(message, reason, super.hashCode()); + return java.util.Objects.hash(message, reason, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStatusBuilder.java index 02a929d876..7c58d53b77 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ContainerStatusBuilder extends io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ContainerStatusBuilder + extends io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ContainerStatus, + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder> { public V1ContainerStatusBuilder() { this(false); } + public V1ContainerStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1ContainerStatus(), validationEnabled); } - public V1ContainerStatusBuilder(io.kubernetes.client.openapi.models.V1ContainerStatusFluent fluent) { + + public V1ContainerStatusBuilder( + io.kubernetes.client.openapi.models.V1ContainerStatusFluent fluent) { this(fluent, false); } - public V1ContainerStatusBuilder(io.kubernetes.client.openapi.models.V1ContainerStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ContainerStatusBuilder( + io.kubernetes.client.openapi.models.V1ContainerStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ContainerStatus(), validationEnabled); } - public V1ContainerStatusBuilder(io.kubernetes.client.openapi.models.V1ContainerStatusFluent fluent,io.kubernetes.client.openapi.models.V1ContainerStatus instance) { + + public V1ContainerStatusBuilder( + io.kubernetes.client.openapi.models.V1ContainerStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerStatus instance) { this(fluent, instance, false); } - public V1ContainerStatusBuilder(io.kubernetes.client.openapi.models.V1ContainerStatusFluent fluent,io.kubernetes.client.openapi.models.V1ContainerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ContainerStatusBuilder( + io.kubernetes.client.openapi.models.V1ContainerStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ContainerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainerID(instance.getContainerID()); fluent.withImage(instance.getImage()); @@ -39,13 +66,17 @@ public V1ContainerStatusBuilder(io.kubernetes.client.openapi.models.V1ContainerS fluent.withState(instance.getState()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ContainerStatusBuilder(io.kubernetes.client.openapi.models.V1ContainerStatus instance) { - this(instance,false); + this(instance, false); } - public V1ContainerStatusBuilder(io.kubernetes.client.openapi.models.V1ContainerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ContainerStatusBuilder( + io.kubernetes.client.openapi.models.V1ContainerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainerID(instance.getContainerID()); this.withImage(instance.getImage()); @@ -64,10 +95,12 @@ public V1ContainerStatusBuilder(io.kubernetes.client.openapi.models.V1ContainerS this.withState(instance.getState()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ContainerStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ContainerStatus build() { V1ContainerStatus buildable = new V1ContainerStatus(); buildable.setContainerID(fluent.getContainerID()); @@ -81,18 +114,23 @@ public io.kubernetes.client.openapi.models.V1ContainerStatus build() { buildable.setState(fluent.getState()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ContainerStatusBuilder that = (V1ContainerStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStatusFluent.java index c11fab08a6..fa3dfa7d11 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStatusFluent.java @@ -1,101 +1,150 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ContainerStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ContainerStatusFluent< + A extends io.kubernetes.client.openapi.models.V1ContainerStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getContainerID(); + public A withContainerID(java.lang.String containerID); + public java.lang.Boolean hasContainerID(); - - /** - * Method is deprecated. use withContainerID instead. - */ + + /** Method is deprecated. use withContainerID instead. */ @java.lang.Deprecated public A withNewContainerID(java.lang.String original); + public java.lang.String getImage(); + public A withImage(java.lang.String image); + public java.lang.Boolean hasImage(); - - /** - * Method is deprecated. use withImage instead. - */ + + /** Method is deprecated. use withImage instead. */ @java.lang.Deprecated public A withNewImage(java.lang.String original); + public java.lang.String getImageID(); + public A withImageID(java.lang.String imageID); + public java.lang.Boolean hasImageID(); - - /** - * Method is deprecated. use withImageID instead. - */ + + /** Method is deprecated. use withImageID instead. */ @java.lang.Deprecated public A withNewImageID(java.lang.String original); - + /** * This method has been deprecated, please use method buildLastState instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ContainerState getLastState(); + public io.kubernetes.client.openapi.models.V1ContainerState buildLastState(); + public A withLastState(io.kubernetes.client.openapi.models.V1ContainerState lastState); + public java.lang.Boolean hasLastState(); - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested withNewLastState(); - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested withNewLastStateLike(io.kubernetes.client.openapi.models.V1ContainerState item); - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested editLastState(); - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested editOrNewLastState(); - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested editOrNewLastStateLike(io.kubernetes.client.openapi.models.V1ContainerState item); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested + withNewLastState(); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested + withNewLastStateLike(io.kubernetes.client.openapi.models.V1ContainerState item); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested + editLastState(); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested + editOrNewLastState(); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested + editOrNewLastStateLike(io.kubernetes.client.openapi.models.V1ContainerState item); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Boolean getReady(); + public A withReady(java.lang.Boolean ready); + public java.lang.Boolean hasReady(); + public java.lang.Integer getRestartCount(); + public A withRestartCount(java.lang.Integer restartCount); + public java.lang.Boolean hasRestartCount(); + public java.lang.Boolean getStarted(); + public A withStarted(java.lang.Boolean started); + public java.lang.Boolean hasStarted(); - + /** * This method has been deprecated, please use method buildState instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ContainerState getState(); + public io.kubernetes.client.openapi.models.V1ContainerState buildState(); + public A withState(io.kubernetes.client.openapi.models.V1ContainerState state); + public java.lang.Boolean hasState(); + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested withNewState(); - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested withNewStateLike(io.kubernetes.client.openapi.models.V1ContainerState item); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested + withNewStateLike(io.kubernetes.client.openapi.models.V1ContainerState item); + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested editState(); - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested editOrNewState(); - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested editOrNewStateLike(io.kubernetes.client.openapi.models.V1ContainerState item); - public interface LastStateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ContainerStateFluent>{ + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested + editOrNewState(); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested + editOrNewStateLike(io.kubernetes.client.openapi.models.V1ContainerState item); + + public interface LastStateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ContainerStateFluent< + io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested> { public N and(); + public N endLastState(); - } - public interface StateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ContainerStateFluent>{ + + public interface StateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ContainerStateFluent< + io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested> { public N and(); + public N endState(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStatusFluentImpl.java index bc76839a95..326979b60a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ContainerStatusFluentImpl.java @@ -1,20 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1ContainerStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ContainerStatusFluent{ - public V1ContainerStatusFluentImpl() { - } - public V1ContainerStatusFluentImpl(io.kubernetes.client.openapi.models.V1ContainerStatus instance) { +/** Generated */ +public class V1ContainerStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ContainerStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ContainerStatusFluent { + public V1ContainerStatusFluentImpl() {} + + public V1ContainerStatusFluentImpl( + io.kubernetes.client.openapi.models.V1ContainerStatus instance) { this.withContainerID(instance.getContainerID()); this.withImage(instance.getImage()); @@ -32,8 +38,8 @@ public V1ContainerStatusFluentImpl(io.kubernetes.client.openapi.models.V1Contain this.withStarted(instance.getStarted()); this.withState(instance.getState()); - } + private java.lang.String containerID; private java.lang.String image; private java.lang.String imageID; @@ -43,218 +49,311 @@ public V1ContainerStatusFluentImpl(io.kubernetes.client.openapi.models.V1Contain private java.lang.Integer restartCount; private java.lang.Boolean started; private io.kubernetes.client.openapi.models.V1ContainerStateBuilder state; + public java.lang.String getContainerID() { return this.containerID; } + public A withContainerID(java.lang.String containerID) { - this.containerID=containerID; return (A) this; + this.containerID = containerID; + return (A) this; } + public java.lang.Boolean hasContainerID() { return this.containerID != null; } - - /** - * Method is deprecated. use withContainerID instead. - */ + + /** Method is deprecated. use withContainerID instead. */ @java.lang.Deprecated public A withNewContainerID(java.lang.String original) { - return (A)withContainerID(new String(original)); + return (A) withContainerID(new String(original)); } + public java.lang.String getImage() { return this.image; } + public A withImage(java.lang.String image) { - this.image=image; return (A) this; + this.image = image; + return (A) this; } + public java.lang.Boolean hasImage() { return this.image != null; } - - /** - * Method is deprecated. use withImage instead. - */ + + /** Method is deprecated. use withImage instead. */ @java.lang.Deprecated public A withNewImage(java.lang.String original) { - return (A)withImage(new String(original)); + return (A) withImage(new String(original)); } + public java.lang.String getImageID() { return this.imageID; } + public A withImageID(java.lang.String imageID) { - this.imageID=imageID; return (A) this; + this.imageID = imageID; + return (A) this; } + public java.lang.Boolean hasImageID() { return this.imageID != null; } - - /** - * Method is deprecated. use withImageID instead. - */ + + /** Method is deprecated. use withImageID instead. */ @java.lang.Deprecated public A withNewImageID(java.lang.String original) { - return (A)withImageID(new String(original)); + return (A) withImageID(new String(original)); } - + /** * This method has been deprecated, please use method buildLastState instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ContainerState getLastState() { - return this.lastState!=null ?this.lastState.build():null; + return this.lastState != null ? this.lastState.build() : null; } + public io.kubernetes.client.openapi.models.V1ContainerState buildLastState() { - return this.lastState!=null ?this.lastState.build():null; + return this.lastState != null ? this.lastState.build() : null; } + public A withLastState(io.kubernetes.client.openapi.models.V1ContainerState lastState) { _visitables.get("lastState").remove(this.lastState); - if (lastState!=null){ this.lastState= new io.kubernetes.client.openapi.models.V1ContainerStateBuilder(lastState); _visitables.get("lastState").add(this.lastState);} return (A) this; + if (lastState != null) { + this.lastState = new io.kubernetes.client.openapi.models.V1ContainerStateBuilder(lastState); + _visitables.get("lastState").add(this.lastState); + } + return (A) this; } + public java.lang.Boolean hasLastState() { return this.lastState != null; } - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested withNewLastState() { - return new io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl.LastStateNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested + withNewLastState() { + return new io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl + .LastStateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested withNewLastStateLike(io.kubernetes.client.openapi.models.V1ContainerState item) { - return new io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl.LastStateNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested + withNewLastStateLike(io.kubernetes.client.openapi.models.V1ContainerState item) { + return new io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl.LastStateNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested editLastState() { + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested + editLastState() { return withNewLastStateLike(getLastState()); } - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested editOrNewLastState() { - return withNewLastStateLike(getLastState() != null ? getLastState(): new io.kubernetes.client.openapi.models.V1ContainerStateBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested + editOrNewLastState() { + return withNewLastStateLike( + getLastState() != null + ? getLastState() + : new io.kubernetes.client.openapi.models.V1ContainerStateBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested editOrNewLastStateLike(io.kubernetes.client.openapi.models.V1ContainerState item) { - return withNewLastStateLike(getLastState() != null ? getLastState(): item); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested + editOrNewLastStateLike(io.kubernetes.client.openapi.models.V1ContainerState item) { + return withNewLastStateLike(getLastState() != null ? getLastState() : item); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Boolean getReady() { return this.ready; } + public A withReady(java.lang.Boolean ready) { - this.ready=ready; return (A) this; + this.ready = ready; + return (A) this; } + public java.lang.Boolean hasReady() { return this.ready != null; } + public java.lang.Integer getRestartCount() { return this.restartCount; } + public A withRestartCount(java.lang.Integer restartCount) { - this.restartCount=restartCount; return (A) this; + this.restartCount = restartCount; + return (A) this; } + public java.lang.Boolean hasRestartCount() { return this.restartCount != null; } + public java.lang.Boolean getStarted() { return this.started; } + public A withStarted(java.lang.Boolean started) { - this.started=started; return (A) this; + this.started = started; + return (A) this; } + public java.lang.Boolean hasStarted() { return this.started != null; } - + /** * This method has been deprecated, please use method buildState instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ContainerState getState() { - return this.state!=null ?this.state.build():null; + return this.state != null ? this.state.build() : null; } + public io.kubernetes.client.openapi.models.V1ContainerState buildState() { - return this.state!=null ?this.state.build():null; + return this.state != null ? this.state.build() : null; } + public A withState(io.kubernetes.client.openapi.models.V1ContainerState state) { _visitables.get("state").remove(this.state); - if (state!=null){ this.state= new io.kubernetes.client.openapi.models.V1ContainerStateBuilder(state); _visitables.get("state").add(this.state);} return (A) this; + if (state != null) { + this.state = new io.kubernetes.client.openapi.models.V1ContainerStateBuilder(state); + _visitables.get("state").add(this.state); + } + return (A) this; } + public java.lang.Boolean hasState() { return this.state != null; } + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested withNewState() { return new io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl.StateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested withNewStateLike(io.kubernetes.client.openapi.models.V1ContainerState item) { - return new io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl.StateNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested + withNewStateLike(io.kubernetes.client.openapi.models.V1ContainerState item) { + return new io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl.StateNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested editState() { return withNewStateLike(getState()); } - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested editOrNewState() { - return withNewStateLike(getState() != null ? getState(): new io.kubernetes.client.openapi.models.V1ContainerStateBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested + editOrNewState() { + return withNewStateLike( + getState() != null + ? getState() + : new io.kubernetes.client.openapi.models.V1ContainerStateBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested editOrNewStateLike(io.kubernetes.client.openapi.models.V1ContainerState item) { - return withNewStateLike(getState() != null ? getState(): item); + + public io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested + editOrNewStateLike(io.kubernetes.client.openapi.models.V1ContainerState item) { + return withNewStateLike(getState() != null ? getState() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ContainerStatusFluentImpl that = (V1ContainerStatusFluentImpl) o; - if (containerID != null ? !containerID.equals(that.containerID) :that.containerID != null) return false; - if (image != null ? !image.equals(that.image) :that.image != null) return false; - if (imageID != null ? !imageID.equals(that.imageID) :that.imageID != null) return false; - if (lastState != null ? !lastState.equals(that.lastState) :that.lastState != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (ready != null ? !ready.equals(that.ready) :that.ready != null) return false; - if (restartCount != null ? !restartCount.equals(that.restartCount) :that.restartCount != null) return false; - if (started != null ? !started.equals(that.started) :that.started != null) return false; - if (state != null ? !state.equals(that.state) :that.state != null) return false; + if (containerID != null ? !containerID.equals(that.containerID) : that.containerID != null) + return false; + if (image != null ? !image.equals(that.image) : that.image != null) return false; + if (imageID != null ? !imageID.equals(that.imageID) : that.imageID != null) return false; + if (lastState != null ? !lastState.equals(that.lastState) : that.lastState != null) + return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (ready != null ? !ready.equals(that.ready) : that.ready != null) return false; + if (restartCount != null ? !restartCount.equals(that.restartCount) : that.restartCount != null) + return false; + if (started != null ? !started.equals(that.started) : that.started != null) return false; + if (state != null ? !state.equals(that.state) : that.state != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(containerID, image, imageID, lastState, name, ready, restartCount, started, state, super.hashCode()); + return java.util.Objects.hash( + containerID, + image, + imageID, + lastState, + name, + ready, + restartCount, + started, + state, + super.hashCode()); } - public class LastStateNestedImpl extends io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested,io.kubernetes.client.fluent.Nested{ + + public class LastStateNestedImpl + extends io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested> + implements io.kubernetes.client.openapi.models.V1ContainerStatusFluent.LastStateNested, + io.kubernetes.client.fluent.Nested { LastStateNestedImpl(io.kubernetes.client.openapi.models.V1ContainerState item) { this.builder = new io.kubernetes.client.openapi.models.V1ContainerStateBuilder(this, item); } + LastStateNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ContainerStateBuilder(this); } + io.kubernetes.client.openapi.models.V1ContainerStateBuilder builder; + public N and() { return (N) V1ContainerStatusFluentImpl.this.withLastState(builder.build()); } + public N endLastState() { return and(); } - } - public class StateNestedImpl extends io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl> implements io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested,io.kubernetes.client.fluent.Nested{ + + public class StateNestedImpl + extends io.kubernetes.client.openapi.models.V1ContainerStateFluentImpl< + io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested> + implements io.kubernetes.client.openapi.models.V1ContainerStatusFluent.StateNested, + io.kubernetes.client.fluent.Nested { StateNestedImpl(io.kubernetes.client.openapi.models.V1ContainerState item) { this.builder = new io.kubernetes.client.openapi.models.V1ContainerStateBuilder(this, item); } + StateNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ContainerStateBuilder(this); } + io.kubernetes.client.openapi.models.V1ContainerStateBuilder builder; + public N and() { return (N) V1ContainerStatusFluentImpl.this.withState(builder.build()); } + public N endState() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionBuilder.java index 9dc6ca72cc..77b46c87ec 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ControllerRevisionBuilder extends io.kubernetes.client.openapi.models.V1ControllerRevisionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ControllerRevisionBuilder + extends io.kubernetes.client.openapi.models.V1ControllerRevisionFluentImpl< + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ControllerRevision, + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder> { public V1ControllerRevisionBuilder() { this(false); } + public V1ControllerRevisionBuilder(java.lang.Boolean validationEnabled) { this(new V1ControllerRevision(), validationEnabled); } - public V1ControllerRevisionBuilder(io.kubernetes.client.openapi.models.V1ControllerRevisionFluent fluent) { + + public V1ControllerRevisionBuilder( + io.kubernetes.client.openapi.models.V1ControllerRevisionFluent fluent) { this(fluent, false); } - public V1ControllerRevisionBuilder(io.kubernetes.client.openapi.models.V1ControllerRevisionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ControllerRevisionBuilder( + io.kubernetes.client.openapi.models.V1ControllerRevisionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ControllerRevision(), validationEnabled); } - public V1ControllerRevisionBuilder(io.kubernetes.client.openapi.models.V1ControllerRevisionFluent fluent,io.kubernetes.client.openapi.models.V1ControllerRevision instance) { + + public V1ControllerRevisionBuilder( + io.kubernetes.client.openapi.models.V1ControllerRevisionFluent fluent, + io.kubernetes.client.openapi.models.V1ControllerRevision instance) { this(fluent, instance, false); } - public V1ControllerRevisionBuilder(io.kubernetes.client.openapi.models.V1ControllerRevisionFluent fluent,io.kubernetes.client.openapi.models.V1ControllerRevision instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ControllerRevisionBuilder( + io.kubernetes.client.openapi.models.V1ControllerRevisionFluent fluent, + io.kubernetes.client.openapi.models.V1ControllerRevision instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withData(instance.getData()); @@ -31,13 +58,18 @@ public V1ControllerRevisionBuilder(io.kubernetes.client.openapi.models.V1Control fluent.withRevision(instance.getRevision()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ControllerRevisionBuilder(io.kubernetes.client.openapi.models.V1ControllerRevision instance) { - this(instance,false); + + public V1ControllerRevisionBuilder( + io.kubernetes.client.openapi.models.V1ControllerRevision instance) { + this(instance, false); } - public V1ControllerRevisionBuilder(io.kubernetes.client.openapi.models.V1ControllerRevision instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ControllerRevisionBuilder( + io.kubernetes.client.openapi.models.V1ControllerRevision instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withData(instance.getData()); @@ -48,10 +80,12 @@ public V1ControllerRevisionBuilder(io.kubernetes.client.openapi.models.V1Control this.withRevision(instance.getRevision()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ControllerRevisionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ControllerRevision build() { V1ControllerRevision buildable = new V1ControllerRevision(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1ControllerRevision build() { buildable.setRevision(fluent.getRevision()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ControllerRevisionBuilder that = (V1ControllerRevisionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionFluent.java index 52c56d7f51..9af59e37a3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionFluent.java @@ -1,61 +1,88 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Long; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ControllerRevisionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ControllerRevisionFluent< + A extends io.kubernetes.client.openapi.models.V1ControllerRevisionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.Object getData(); + public A withData(java.lang.Object data); + public java.lang.Boolean hasData(); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public java.lang.Long getRevision(); + public A withRevision(java.lang.Long revision); + public java.lang.Boolean hasRevision(); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionFluentImpl.java index c72d71c996..f235ea797f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionFluentImpl.java @@ -1,20 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1ControllerRevisionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ControllerRevisionFluent{ - public V1ControllerRevisionFluentImpl() { - } - public V1ControllerRevisionFluentImpl(io.kubernetes.client.openapi.models.V1ControllerRevision instance) { +/** Generated */ +public class V1ControllerRevisionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ControllerRevisionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ControllerRevisionFluent { + public V1ControllerRevisionFluentImpl() {} + + public V1ControllerRevisionFluentImpl( + io.kubernetes.client.openapi.models.V1ControllerRevision instance) { this.withApiVersion(instance.getApiVersion()); this.withData(instance.getData()); @@ -24,128 +30,173 @@ public V1ControllerRevisionFluentImpl(io.kubernetes.client.openapi.models.V1Cont this.withMetadata(instance.getMetadata()); this.withRevision(instance.getRevision()); - } + private java.lang.String apiVersion; private java.lang.Object data; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private java.lang.Long revision; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.Object getData() { return this.data; } + public A withData(java.lang.Object data) { - this.data=data; return (A) this; + this.data = data; + return (A) this; } + public java.lang.Boolean hasData() { return this.data != null; } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1ControllerRevisionFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1ControllerRevisionFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1ControllerRevisionFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1ControllerRevisionFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public java.lang.Long getRevision() { return this.revision; } + public A withRevision(java.lang.Long revision) { - this.revision=revision; return (A) this; + this.revision = revision; + return (A) this; } + public java.lang.Boolean hasRevision() { return this.revision != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ControllerRevisionFluentImpl that = (V1ControllerRevisionFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (data != null ? !data.equals(that.data) :that.data != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (revision != null ? !revision.equals(that.revision) :that.revision != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (data != null ? !data.equals(that.data) : that.data != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (revision != null ? !revision.equals(that.revision) : that.revision != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, data, kind, metadata, revision, super.hashCode()); + return java.util.Objects.hash(apiVersion, data, kind, metadata, revision, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ControllerRevisionFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1ControllerRevisionFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionListBuilder.java index 87ae8a64b1..94ca8386ca 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ControllerRevisionListBuilder extends io.kubernetes.client.openapi.models.V1ControllerRevisionListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ControllerRevisionListBuilder + extends io.kubernetes.client.openapi.models.V1ControllerRevisionListFluentImpl< + io.kubernetes.client.openapi.models.V1ControllerRevisionListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ControllerRevisionList, + io.kubernetes.client.openapi.models.V1ControllerRevisionListBuilder> { public V1ControllerRevisionListBuilder() { this(false); } + public V1ControllerRevisionListBuilder(java.lang.Boolean validationEnabled) { this(new V1ControllerRevisionList(), validationEnabled); } - public V1ControllerRevisionListBuilder(io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent fluent) { + + public V1ControllerRevisionListBuilder( + io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent fluent) { this(fluent, false); } - public V1ControllerRevisionListBuilder(io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ControllerRevisionListBuilder( + io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ControllerRevisionList(), validationEnabled); } - public V1ControllerRevisionListBuilder(io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent fluent,io.kubernetes.client.openapi.models.V1ControllerRevisionList instance) { + + public V1ControllerRevisionListBuilder( + io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent fluent, + io.kubernetes.client.openapi.models.V1ControllerRevisionList instance) { this(fluent, instance, false); } - public V1ControllerRevisionListBuilder(io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent fluent,io.kubernetes.client.openapi.models.V1ControllerRevisionList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ControllerRevisionListBuilder( + io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent fluent, + io.kubernetes.client.openapi.models.V1ControllerRevisionList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1ControllerRevisionListBuilder(io.kubernetes.client.openapi.models.V1Con fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ControllerRevisionListBuilder(io.kubernetes.client.openapi.models.V1ControllerRevisionList instance) { - this(instance,false); + + public V1ControllerRevisionListBuilder( + io.kubernetes.client.openapi.models.V1ControllerRevisionList instance) { + this(instance, false); } - public V1ControllerRevisionListBuilder(io.kubernetes.client.openapi.models.V1ControllerRevisionList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ControllerRevisionListBuilder( + io.kubernetes.client.openapi.models.V1ControllerRevisionList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1ControllerRevisionListBuilder(io.kubernetes.client.openapi.models.V1Con this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ControllerRevisionList build() { V1ControllerRevisionList buildable = new V1ControllerRevisionList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1ControllerRevisionList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ControllerRevisionListBuilder that = (V1ControllerRevisionListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionListFluent.java index 8a7ac971f5..951f3548d9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionListFluent.java @@ -1,95 +1,163 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ControllerRevisionListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ControllerRevisionListFluent< + A extends io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ControllerRevision item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ControllerRevision item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ControllerRevision item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ControllerRevision item); + public A addToItems(io.kubernetes.client.openapi.models.V1ControllerRevision... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1ControllerRevision... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1ControllerRevision buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ControllerRevision buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ControllerRevision buildFirstItem(); + public io.kubernetes.client.openapi.models.V1ControllerRevision buildLastItem(); - public io.kubernetes.client.openapi.models.V1ControllerRevision buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1ControllerRevision buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1ControllerRevision... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ControllerRevision item); - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ControllerRevision item); - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1ControllerRevision item); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ControllerRevision item); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ControllerRevisionFluent>{ + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ControllerRevisionFluent< + io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionListFluentImpl.java index 1e8ae934ab..5b0f1603f9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ControllerRevisionListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1ControllerRevisionListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent{ - public V1ControllerRevisionListFluentImpl() { - } - public V1ControllerRevisionListFluentImpl(io.kubernetes.client.openapi.models.V1ControllerRevisionList instance) { + +/** Generated */ +public class V1ControllerRevisionListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent { + public V1ControllerRevisionListFluentImpl() {} + + public V1ControllerRevisionListFluentImpl( + io.kubernetes.client.openapi.models.V1ControllerRevisionList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,131 @@ public V1ControllerRevisionListFluentImpl(io.kubernetes.client.openapi.models.V1 this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ControllerRevision item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder = new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ControllerRevision item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder>(); + } + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder = + new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ControllerRevision item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder = new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ControllerRevision item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder>(); + } + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder = + new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1ControllerRevision... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ControllerRevision item : items) {io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder = new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ControllerRevision item : items) { + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder = + new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ControllerRevision item : items) {io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder = new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ControllerRevision item : items) { + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder = + new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1ControllerRevision... items) { - for (io.kubernetes.client.openapi.models.V1ControllerRevision item : items) {io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder = new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ControllerRevision item : items) { + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder = + new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ControllerRevision item : items) {io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder = new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ControllerRevision item : items) { + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder = + new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder = each.next(); @@ -87,174 +164,287 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1ControllerRevision buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ControllerRevision buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ControllerRevision buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ControllerRevision buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ControllerRevision buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ControllerRevision buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ControllerRevision item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ControllerRevision item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1ControllerRevision... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1ControllerRevision item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1ControllerRevision item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1ControllerRevisionListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1ControllerRevisionListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ControllerRevision item) { - return new io.kubernetes.client.openapi.models.V1ControllerRevisionListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1ControllerRevision item) { + return new io.kubernetes.client.openapi.models.V1ControllerRevisionListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ControllerRevision item) { - return new io.kubernetes.client.openapi.models.V1ControllerRevisionListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ControllerRevision item) { + return new io.kubernetes.client.openapi.models.V1ControllerRevisionListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1ControllerRevisionListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1ControllerRevisionListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1ControllerRevisionListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1ControllerRevisionListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ControllerRevisionListFluentImpl that = (V1ControllerRevisionListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1ControllerRevisionFluentImpl> implements io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ControllerRevision item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1ControllerRevisionFluentImpl< + io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ControllerRevision item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder(this); } + io.kubernetes.client.openapi.models.V1ControllerRevisionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ControllerRevisionListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1ControllerRevisionListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ControllerRevisionListFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1ControllerRevisionListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobBuilder.java index 7e785bb907..3dcfb3ef2b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CronJobBuilder extends io.kubernetes.client.openapi.models.V1CronJobFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CronJobBuilder + extends io.kubernetes.client.openapi.models.V1CronJobFluentImpl< + io.kubernetes.client.openapi.models.V1CronJobBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CronJob, + io.kubernetes.client.openapi.models.V1CronJobBuilder> { public V1CronJobBuilder() { this(false); } + public V1CronJobBuilder(java.lang.Boolean validationEnabled) { this(new V1CronJob(), validationEnabled); } + public V1CronJobBuilder(io.kubernetes.client.openapi.models.V1CronJobFluent fluent) { this(fluent, false); } - public V1CronJobBuilder(io.kubernetes.client.openapi.models.V1CronJobFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CronJobBuilder( + io.kubernetes.client.openapi.models.V1CronJobFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CronJob(), validationEnabled); } - public V1CronJobBuilder(io.kubernetes.client.openapi.models.V1CronJobFluent fluent,io.kubernetes.client.openapi.models.V1CronJob instance) { + + public V1CronJobBuilder( + io.kubernetes.client.openapi.models.V1CronJobFluent fluent, + io.kubernetes.client.openapi.models.V1CronJob instance) { this(fluent, instance, false); } - public V1CronJobBuilder(io.kubernetes.client.openapi.models.V1CronJobFluent fluent,io.kubernetes.client.openapi.models.V1CronJob instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CronJobBuilder( + io.kubernetes.client.openapi.models.V1CronJobFluent fluent, + io.kubernetes.client.openapi.models.V1CronJob instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,16 @@ public V1CronJobBuilder(io.kubernetes.client.openapi.models.V1CronJobFluent f fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1CronJobBuilder(io.kubernetes.client.openapi.models.V1CronJob instance) { - this(instance,false); + this(instance, false); } - public V1CronJobBuilder(io.kubernetes.client.openapi.models.V1CronJob instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CronJobBuilder( + io.kubernetes.client.openapi.models.V1CronJob instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +77,12 @@ public V1CronJobBuilder(io.kubernetes.client.openapi.models.V1CronJob instance,j this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CronJobFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CronJob build() { V1CronJob buildable = new V1CronJob(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +92,23 @@ public io.kubernetes.client.openapi.models.V1CronJob build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CronJobBuilder that = (V1CronJobBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobFluent.java index 1aa660edc9..b6e60202aa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobFluent.java @@ -1,93 +1,142 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CronJobFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CronJobFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CronJobSpec getSpec(); + public io.kubernetes.client.openapi.models.V1CronJobSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1CronJobSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1CronJobSpec item); + + public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1CronJobSpec item); + public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CronJobSpec item); - + + public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1CronJobSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CronJobStatus getStatus(); + public io.kubernetes.client.openapi.models.V1CronJobStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1CronJobStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1CronJobStatus item); + + public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1CronJobStatus item); + public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1CronJobStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1CronJobStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CronJobSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CronJobSpecFluent< + io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CronJobStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CronJobStatusFluent< + io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobFluentImpl.java index 65bda42f4a..6cc62235ad 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1CronJobFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CronJobFluent { + public V1CronJobFluentImpl() {} - /** - * Generated - */ -public class V1CronJobFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CronJobFluent{ - public V1CronJobFluentImpl() { - } public V1CronJobFluentImpl(io.kubernetes.client.openapi.models.V1CronJob instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +28,294 @@ public V1CronJobFluentImpl(io.kubernetes.client.openapi.models.V1CronJob instanc this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1CronJobSpecBuilder spec; private io.kubernetes.client.openapi.models.V1CronJobStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1CronJobFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1CronJobFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CronJobSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1CronJobSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1CronJobSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1CronJobSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1CronJobSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1CronJobFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1CronJobSpec item) { + + public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1CronJobSpec item) { return new io.kubernetes.client.openapi.models.V1CronJobFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1CronJobSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1CronJobSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CronJobSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1CronJobSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CronJobStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1CronJobStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1CronJobStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1CronJobStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1CronJobStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1CronJobFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1CronJobStatus item) { + + public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1CronJobStatus item) { return new io.kubernetes.client.openapi.models.V1CronJobFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1CronJobStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1CronJobStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1CronJobStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1CronJobStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CronJobFluentImpl that = (V1CronJobFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1CronJobFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1CronJobFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1CronJobSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1CronJobSpecFluentImpl< + io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1CronJobFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1CronJobSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1CronJobSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1CronJobSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1CronJobSpecBuilder builder; + public N and() { return (N) V1CronJobFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1CronJobStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1CronJobStatusFluentImpl< + io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1CronJobFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1CronJobStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1CronJobStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1CronJobStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1CronJobStatusBuilder builder; + public N and() { return (N) V1CronJobFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobListBuilder.java index a79078ed75..e8596102a4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobListBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CronJobListBuilder extends io.kubernetes.client.openapi.models.V1CronJobListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CronJobListBuilder + extends io.kubernetes.client.openapi.models.V1CronJobListFluentImpl< + io.kubernetes.client.openapi.models.V1CronJobListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CronJobList, + io.kubernetes.client.openapi.models.V1CronJobListBuilder> { public V1CronJobListBuilder() { this(false); } + public V1CronJobListBuilder(java.lang.Boolean validationEnabled) { this(new V1CronJobList(), validationEnabled); } + public V1CronJobListBuilder(io.kubernetes.client.openapi.models.V1CronJobListFluent fluent) { this(fluent, false); } - public V1CronJobListBuilder(io.kubernetes.client.openapi.models.V1CronJobListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CronJobListBuilder( + io.kubernetes.client.openapi.models.V1CronJobListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CronJobList(), validationEnabled); } - public V1CronJobListBuilder(io.kubernetes.client.openapi.models.V1CronJobListFluent fluent,io.kubernetes.client.openapi.models.V1CronJobList instance) { + + public V1CronJobListBuilder( + io.kubernetes.client.openapi.models.V1CronJobListFluent fluent, + io.kubernetes.client.openapi.models.V1CronJobList instance) { this(fluent, instance, false); } - public V1CronJobListBuilder(io.kubernetes.client.openapi.models.V1CronJobListFluent fluent,io.kubernetes.client.openapi.models.V1CronJobList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CronJobListBuilder( + io.kubernetes.client.openapi.models.V1CronJobListFluent fluent, + io.kubernetes.client.openapi.models.V1CronJobList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +55,17 @@ public V1CronJobListBuilder(io.kubernetes.client.openapi.models.V1CronJobListFlu fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1CronJobListBuilder(io.kubernetes.client.openapi.models.V1CronJobList instance) { - this(instance,false); + this(instance, false); } - public V1CronJobListBuilder(io.kubernetes.client.openapi.models.V1CronJobList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CronJobListBuilder( + io.kubernetes.client.openapi.models.V1CronJobList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +74,12 @@ public V1CronJobListBuilder(io.kubernetes.client.openapi.models.V1CronJobList in this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CronJobListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CronJobList build() { V1CronJobList buildable = new V1CronJobList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1CronJobList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CronJobListBuilder that = (V1CronJobListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobListFluent.java index 42883944b7..1f5d3c4cca 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobListFluent.java @@ -1,95 +1,146 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CronJobListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CronJobListFluent< + A extends io.kubernetes.client.openapi.models.V1CronJobListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CronJob item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CronJob item); + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1CronJob item); + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1CronJob item); + public A addToItems(io.kubernetes.client.openapi.models.V1CronJob... items); + public A addAllToItems(java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1CronJob... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1CronJob buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1CronJob buildFirstItem(); + public io.kubernetes.client.openapi.models.V1CronJob buildLastItem(); - public io.kubernetes.client.openapi.models.V1CronJob buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1CronJob buildMatchingItem( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1CronJob... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1CronJob item); - public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CronJob item); - public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1CronJob item); + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CronJob item); + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CronJobFluent>{ + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CronJobFluent< + io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobListFluentImpl.java index 572c4a04ab..95224421e5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1CronJobListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CronJobListFluent{ - public V1CronJobListFluentImpl() { - } +/** Generated */ +public class V1CronJobListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CronJobListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CronJobListFluent { + public V1CronJobListFluentImpl() {} + public V1CronJobListFluentImpl(io.kubernetes.client.openapi.models.V1CronJobList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,117 @@ public V1CronJobListFluentImpl(io.kubernetes.client.openapi.models.V1CronJobList this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CronJob item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CronJobBuilder builder = new io.kubernetes.client.openapi.models.V1CronJobBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1CronJob item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1CronJobBuilder builder = + new io.kubernetes.client.openapi.models.V1CronJobBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CronJob item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CronJobBuilder builder = new io.kubernetes.client.openapi.models.V1CronJobBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1CronJob item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1CronJobBuilder builder = + new io.kubernetes.client.openapi.models.V1CronJobBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1CronJob... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CronJob item : items) {io.kubernetes.client.openapi.models.V1CronJobBuilder builder = new io.kubernetes.client.openapi.models.V1CronJobBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1CronJob item : items) { + io.kubernetes.client.openapi.models.V1CronJobBuilder builder = + new io.kubernetes.client.openapi.models.V1CronJobBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CronJob item : items) {io.kubernetes.client.openapi.models.V1CronJobBuilder builder = new io.kubernetes.client.openapi.models.V1CronJobBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1CronJob item : items) { + io.kubernetes.client.openapi.models.V1CronJobBuilder builder = + new io.kubernetes.client.openapi.models.V1CronJobBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1CronJob... items) { - for (io.kubernetes.client.openapi.models.V1CronJob item : items) {io.kubernetes.client.openapi.models.V1CronJobBuilder builder = new io.kubernetes.client.openapi.models.V1CronJobBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1CronJob item : items) { + io.kubernetes.client.openapi.models.V1CronJobBuilder builder = + new io.kubernetes.client.openapi.models.V1CronJobBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1CronJob item : items) {io.kubernetes.client.openapi.models.V1CronJobBuilder builder = new io.kubernetes.client.openapi.models.V1CronJobBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1CronJob item : items) { + io.kubernetes.client.openapi.models.V1CronJobBuilder builder = + new io.kubernetes.client.openapi.models.V1CronJobBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +151,272 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1CronJob buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1CronJob buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1CronJob buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1CronJob buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CronJobBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1CronJob buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1CronJobBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CronJobBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1CronJobBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1CronJob item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1CronJob item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1CronJob... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1CronJob item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1CronJob item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1CronJobListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1CronJob item) { - return new io.kubernetes.client.openapi.models.V1CronJobListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1CronJob item) { + return new io.kubernetes.client.openapi.models.V1CronJobListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CronJob item) { - return new io.kubernetes.client.openapi.models.V1CronJobListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CronJob item) { + return new io.kubernetes.client.openapi.models.V1CronJobListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1CronJobListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { return new io.kubernetes.client.openapi.models.V1CronJobListFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CronJobListFluentImpl that = (V1CronJobListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1CronJobFluentImpl> implements io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CronJob item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1CronJobFluentImpl< + io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1CronJobListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1CronJob item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1CronJobBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1CronJobBuilder(this); } + io.kubernetes.client.openapi.models.V1CronJobBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1CronJobListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1CronJobListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1CronJobListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1CronJobListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobSpecBuilder.java index 7237cc7b60..d4d6fe8fa5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobSpecBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CronJobSpecBuilder extends io.kubernetes.client.openapi.models.V1CronJobSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CronJobSpecBuilder + extends io.kubernetes.client.openapi.models.V1CronJobSpecFluentImpl< + io.kubernetes.client.openapi.models.V1CronJobSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CronJobSpec, + io.kubernetes.client.openapi.models.V1CronJobSpecBuilder> { public V1CronJobSpecBuilder() { this(false); } + public V1CronJobSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1CronJobSpec(), validationEnabled); } + public V1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1CronJobSpecFluent fluent) { this(fluent, false); } - public V1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1CronJobSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CronJobSpecBuilder( + io.kubernetes.client.openapi.models.V1CronJobSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CronJobSpec(), validationEnabled); } - public V1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1CronJobSpecFluent fluent,io.kubernetes.client.openapi.models.V1CronJobSpec instance) { + + public V1CronJobSpecBuilder( + io.kubernetes.client.openapi.models.V1CronJobSpecFluent fluent, + io.kubernetes.client.openapi.models.V1CronJobSpec instance) { this(fluent, instance, false); } - public V1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1CronJobSpecFluent fluent,io.kubernetes.client.openapi.models.V1CronJobSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CronJobSpecBuilder( + io.kubernetes.client.openapi.models.V1CronJobSpecFluent fluent, + io.kubernetes.client.openapi.models.V1CronJobSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConcurrencyPolicy(instance.getConcurrencyPolicy()); fluent.withFailedJobsHistoryLimit(instance.getFailedJobsHistoryLimit()); @@ -35,13 +61,17 @@ public V1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1CronJobSpecFlu fluent.withSuspend(instance.getSuspend()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1CronJobSpec instance) { - this(instance,false); + this(instance, false); } - public V1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1CronJobSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CronJobSpecBuilder( + io.kubernetes.client.openapi.models.V1CronJobSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConcurrencyPolicy(instance.getConcurrencyPolicy()); this.withFailedJobsHistoryLimit(instance.getFailedJobsHistoryLimit()); @@ -56,10 +86,12 @@ public V1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1CronJobSpec in this.withSuspend(instance.getSuspend()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CronJobSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CronJobSpec build() { V1CronJobSpec buildable = new V1CronJobSpec(); buildable.setConcurrencyPolicy(fluent.getConcurrencyPolicy()); @@ -71,18 +103,23 @@ public io.kubernetes.client.openapi.models.V1CronJobSpec build() { buildable.setSuspend(fluent.getSuspend()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CronJobSpecBuilder that = (V1CronJobSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobSpecFluent.java index d774bebb4d..319d68fdeb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobSpecFluent.java @@ -1,61 +1,98 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Long; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CronJobSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - public io.kubernetes.client.openapi.models.V1CronJobSpec.ConcurrencyPolicyEnum getConcurrencyPolicy(); - public A withConcurrencyPolicy(io.kubernetes.client.openapi.models.V1CronJobSpec.ConcurrencyPolicyEnum concurrencyPolicy); +/** Generated */ +public interface V1CronJobSpecFluent< + A extends io.kubernetes.client.openapi.models.V1CronJobSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + public io.kubernetes.client.openapi.models.V1CronJobSpec.ConcurrencyPolicyEnum + getConcurrencyPolicy(); + + public A withConcurrencyPolicy( + io.kubernetes.client.openapi.models.V1CronJobSpec.ConcurrencyPolicyEnum concurrencyPolicy); + public java.lang.Boolean hasConcurrencyPolicy(); + public java.lang.Integer getFailedJobsHistoryLimit(); + public A withFailedJobsHistoryLimit(java.lang.Integer failedJobsHistoryLimit); + public java.lang.Boolean hasFailedJobsHistoryLimit(); - + /** * This method has been deprecated, please use method buildJobTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JobTemplateSpec getJobTemplate(); + public io.kubernetes.client.openapi.models.V1JobTemplateSpec buildJobTemplate(); + public A withJobTemplate(io.kubernetes.client.openapi.models.V1JobTemplateSpec jobTemplate); + public java.lang.Boolean hasJobTemplate(); - public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested withNewJobTemplate(); - public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested withNewJobTemplateLike(io.kubernetes.client.openapi.models.V1JobTemplateSpec item); - public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested editJobTemplate(); - public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested editOrNewJobTemplate(); - public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested editOrNewJobTemplateLike(io.kubernetes.client.openapi.models.V1JobTemplateSpec item); + + public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested + withNewJobTemplate(); + + public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested + withNewJobTemplateLike(io.kubernetes.client.openapi.models.V1JobTemplateSpec item); + + public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested + editJobTemplate(); + + public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested + editOrNewJobTemplate(); + + public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested + editOrNewJobTemplateLike(io.kubernetes.client.openapi.models.V1JobTemplateSpec item); + public java.lang.String getSchedule(); + public A withSchedule(java.lang.String schedule); + public java.lang.Boolean hasSchedule(); - - /** - * Method is deprecated. use withSchedule instead. - */ + + /** Method is deprecated. use withSchedule instead. */ @java.lang.Deprecated public A withNewSchedule(java.lang.String original); + public java.lang.Long getStartingDeadlineSeconds(); + public A withStartingDeadlineSeconds(java.lang.Long startingDeadlineSeconds); + public java.lang.Boolean hasStartingDeadlineSeconds(); + public java.lang.Integer getSuccessfulJobsHistoryLimit(); + public A withSuccessfulJobsHistoryLimit(java.lang.Integer successfulJobsHistoryLimit); + public java.lang.Boolean hasSuccessfulJobsHistoryLimit(); + public java.lang.Boolean getSuspend(); + public A withSuspend(java.lang.Boolean suspend); + public java.lang.Boolean hasSuspend(); - public interface JobTemplateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent>{ + + public interface JobTemplateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent< + io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested> { public N and(); + public N endJobTemplate(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobSpecFluentImpl.java index ffbb7140b4..3bcac5abf7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobSpecFluentImpl.java @@ -1,20 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1CronJobSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CronJobSpecFluent{ - public V1CronJobSpecFluentImpl() { - } +/** Generated */ +public class V1CronJobSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CronJobSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CronJobSpecFluent { + public V1CronJobSpecFluentImpl() {} + public V1CronJobSpecFluentImpl(io.kubernetes.client.openapi.models.V1CronJobSpec instance) { this.withConcurrencyPolicy(instance.getConcurrencyPolicy()); @@ -29,8 +33,8 @@ public V1CronJobSpecFluentImpl(io.kubernetes.client.openapi.models.V1CronJobSpec this.withSuccessfulJobsHistoryLimit(instance.getSuccessfulJobsHistoryLimit()); this.withSuspend(instance.getSuspend()); - } + private io.kubernetes.client.openapi.models.V1CronJobSpec.ConcurrencyPolicyEnum concurrencyPolicy; private java.lang.Integer failedJobsHistoryLimit; private io.kubernetes.client.openapi.models.V1JobTemplateSpecBuilder jobTemplate; @@ -38,133 +42,206 @@ public V1CronJobSpecFluentImpl(io.kubernetes.client.openapi.models.V1CronJobSpec private java.lang.Long startingDeadlineSeconds; private java.lang.Integer successfulJobsHistoryLimit; private java.lang.Boolean suspend; - public io.kubernetes.client.openapi.models.V1CronJobSpec.ConcurrencyPolicyEnum getConcurrencyPolicy() { + + public io.kubernetes.client.openapi.models.V1CronJobSpec.ConcurrencyPolicyEnum + getConcurrencyPolicy() { return this.concurrencyPolicy; } - public A withConcurrencyPolicy(io.kubernetes.client.openapi.models.V1CronJobSpec.ConcurrencyPolicyEnum concurrencyPolicy) { - this.concurrencyPolicy=concurrencyPolicy; return (A) this; + + public A withConcurrencyPolicy( + io.kubernetes.client.openapi.models.V1CronJobSpec.ConcurrencyPolicyEnum concurrencyPolicy) { + this.concurrencyPolicy = concurrencyPolicy; + return (A) this; } + public java.lang.Boolean hasConcurrencyPolicy() { return this.concurrencyPolicy != null; } + public java.lang.Integer getFailedJobsHistoryLimit() { return this.failedJobsHistoryLimit; } + public A withFailedJobsHistoryLimit(java.lang.Integer failedJobsHistoryLimit) { - this.failedJobsHistoryLimit=failedJobsHistoryLimit; return (A) this; + this.failedJobsHistoryLimit = failedJobsHistoryLimit; + return (A) this; } + public java.lang.Boolean hasFailedJobsHistoryLimit() { return this.failedJobsHistoryLimit != null; } - + /** * This method has been deprecated, please use method buildJobTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JobTemplateSpec getJobTemplate() { - return this.jobTemplate!=null ?this.jobTemplate.build():null; + return this.jobTemplate != null ? this.jobTemplate.build() : null; } + public io.kubernetes.client.openapi.models.V1JobTemplateSpec buildJobTemplate() { - return this.jobTemplate!=null ?this.jobTemplate.build():null; + return this.jobTemplate != null ? this.jobTemplate.build() : null; } + public A withJobTemplate(io.kubernetes.client.openapi.models.V1JobTemplateSpec jobTemplate) { _visitables.get("jobTemplate").remove(this.jobTemplate); - if (jobTemplate!=null){ this.jobTemplate= new io.kubernetes.client.openapi.models.V1JobTemplateSpecBuilder(jobTemplate); _visitables.get("jobTemplate").add(this.jobTemplate);} return (A) this; + if (jobTemplate != null) { + this.jobTemplate = + new io.kubernetes.client.openapi.models.V1JobTemplateSpecBuilder(jobTemplate); + _visitables.get("jobTemplate").add(this.jobTemplate); + } + return (A) this; } + public java.lang.Boolean hasJobTemplate() { return this.jobTemplate != null; } - public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested withNewJobTemplate() { + + public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested + withNewJobTemplate() { return new io.kubernetes.client.openapi.models.V1CronJobSpecFluentImpl.JobTemplateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested withNewJobTemplateLike(io.kubernetes.client.openapi.models.V1JobTemplateSpec item) { - return new io.kubernetes.client.openapi.models.V1CronJobSpecFluentImpl.JobTemplateNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested + withNewJobTemplateLike(io.kubernetes.client.openapi.models.V1JobTemplateSpec item) { + return new io.kubernetes.client.openapi.models.V1CronJobSpecFluentImpl.JobTemplateNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested editJobTemplate() { + + public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested + editJobTemplate() { return withNewJobTemplateLike(getJobTemplate()); } - public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested editOrNewJobTemplate() { - return withNewJobTemplateLike(getJobTemplate() != null ? getJobTemplate(): new io.kubernetes.client.openapi.models.V1JobTemplateSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested + editOrNewJobTemplate() { + return withNewJobTemplateLike( + getJobTemplate() != null + ? getJobTemplate() + : new io.kubernetes.client.openapi.models.V1JobTemplateSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested editOrNewJobTemplateLike(io.kubernetes.client.openapi.models.V1JobTemplateSpec item) { - return withNewJobTemplateLike(getJobTemplate() != null ? getJobTemplate(): item); + + public io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested + editOrNewJobTemplateLike(io.kubernetes.client.openapi.models.V1JobTemplateSpec item) { + return withNewJobTemplateLike(getJobTemplate() != null ? getJobTemplate() : item); } + public java.lang.String getSchedule() { return this.schedule; } + public A withSchedule(java.lang.String schedule) { - this.schedule=schedule; return (A) this; + this.schedule = schedule; + return (A) this; } + public java.lang.Boolean hasSchedule() { return this.schedule != null; } - - /** - * Method is deprecated. use withSchedule instead. - */ + + /** Method is deprecated. use withSchedule instead. */ @java.lang.Deprecated public A withNewSchedule(java.lang.String original) { - return (A)withSchedule(new String(original)); + return (A) withSchedule(new String(original)); } + public java.lang.Long getStartingDeadlineSeconds() { return this.startingDeadlineSeconds; } + public A withStartingDeadlineSeconds(java.lang.Long startingDeadlineSeconds) { - this.startingDeadlineSeconds=startingDeadlineSeconds; return (A) this; + this.startingDeadlineSeconds = startingDeadlineSeconds; + return (A) this; } + public java.lang.Boolean hasStartingDeadlineSeconds() { return this.startingDeadlineSeconds != null; } + public java.lang.Integer getSuccessfulJobsHistoryLimit() { return this.successfulJobsHistoryLimit; } + public A withSuccessfulJobsHistoryLimit(java.lang.Integer successfulJobsHistoryLimit) { - this.successfulJobsHistoryLimit=successfulJobsHistoryLimit; return (A) this; + this.successfulJobsHistoryLimit = successfulJobsHistoryLimit; + return (A) this; } + public java.lang.Boolean hasSuccessfulJobsHistoryLimit() { return this.successfulJobsHistoryLimit != null; } + public java.lang.Boolean getSuspend() { return this.suspend; } + public A withSuspend(java.lang.Boolean suspend) { - this.suspend=suspend; return (A) this; + this.suspend = suspend; + return (A) this; } + public java.lang.Boolean hasSuspend() { return this.suspend != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CronJobSpecFluentImpl that = (V1CronJobSpecFluentImpl) o; - if (concurrencyPolicy != null ? !concurrencyPolicy.equals(that.concurrencyPolicy) :that.concurrencyPolicy != null) return false; - if (failedJobsHistoryLimit != null ? !failedJobsHistoryLimit.equals(that.failedJobsHistoryLimit) :that.failedJobsHistoryLimit != null) return false; - if (jobTemplate != null ? !jobTemplate.equals(that.jobTemplate) :that.jobTemplate != null) return false; - if (schedule != null ? !schedule.equals(that.schedule) :that.schedule != null) return false; - if (startingDeadlineSeconds != null ? !startingDeadlineSeconds.equals(that.startingDeadlineSeconds) :that.startingDeadlineSeconds != null) return false; - if (successfulJobsHistoryLimit != null ? !successfulJobsHistoryLimit.equals(that.successfulJobsHistoryLimit) :that.successfulJobsHistoryLimit != null) return false; - if (suspend != null ? !suspend.equals(that.suspend) :that.suspend != null) return false; + if (concurrencyPolicy != null + ? !concurrencyPolicy.equals(that.concurrencyPolicy) + : that.concurrencyPolicy != null) return false; + if (failedJobsHistoryLimit != null + ? !failedJobsHistoryLimit.equals(that.failedJobsHistoryLimit) + : that.failedJobsHistoryLimit != null) return false; + if (jobTemplate != null ? !jobTemplate.equals(that.jobTemplate) : that.jobTemplate != null) + return false; + if (schedule != null ? !schedule.equals(that.schedule) : that.schedule != null) return false; + if (startingDeadlineSeconds != null + ? !startingDeadlineSeconds.equals(that.startingDeadlineSeconds) + : that.startingDeadlineSeconds != null) return false; + if (successfulJobsHistoryLimit != null + ? !successfulJobsHistoryLimit.equals(that.successfulJobsHistoryLimit) + : that.successfulJobsHistoryLimit != null) return false; + if (suspend != null ? !suspend.equals(that.suspend) : that.suspend != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(concurrencyPolicy, failedJobsHistoryLimit, jobTemplate, schedule, startingDeadlineSeconds, successfulJobsHistoryLimit, suspend, super.hashCode()); + return java.util.Objects.hash( + concurrencyPolicy, + failedJobsHistoryLimit, + jobTemplate, + schedule, + startingDeadlineSeconds, + successfulJobsHistoryLimit, + suspend, + super.hashCode()); } - public class JobTemplateNestedImpl extends io.kubernetes.client.openapi.models.V1JobTemplateSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested,io.kubernetes.client.fluent.Nested{ + + public class JobTemplateNestedImpl + extends io.kubernetes.client.openapi.models.V1JobTemplateSpecFluentImpl< + io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested> + implements io.kubernetes.client.openapi.models.V1CronJobSpecFluent.JobTemplateNested, + io.kubernetes.client.fluent.Nested { JobTemplateNestedImpl(io.kubernetes.client.openapi.models.V1JobTemplateSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1JobTemplateSpecBuilder(this, item); } + JobTemplateNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1JobTemplateSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1JobTemplateSpecBuilder builder; + public N and() { return (N) V1CronJobSpecFluentImpl.this.withJobTemplate(builder.build()); } + public N endJobTemplate() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobStatusBuilder.java index b94a6fa3da..26e5253182 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobStatusBuilder.java @@ -1,49 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CronJobStatusBuilder extends io.kubernetes.client.openapi.models.V1CronJobStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CronJobStatusBuilder + extends io.kubernetes.client.openapi.models.V1CronJobStatusFluentImpl< + io.kubernetes.client.openapi.models.V1CronJobStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CronJobStatus, + io.kubernetes.client.openapi.models.V1CronJobStatusBuilder> { public V1CronJobStatusBuilder() { this(false); } + public V1CronJobStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1CronJobStatus(), validationEnabled); } - public V1CronJobStatusBuilder(io.kubernetes.client.openapi.models.V1CronJobStatusFluent fluent) { + + public V1CronJobStatusBuilder( + io.kubernetes.client.openapi.models.V1CronJobStatusFluent fluent) { this(fluent, false); } - public V1CronJobStatusBuilder(io.kubernetes.client.openapi.models.V1CronJobStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CronJobStatusBuilder( + io.kubernetes.client.openapi.models.V1CronJobStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CronJobStatus(), validationEnabled); } - public V1CronJobStatusBuilder(io.kubernetes.client.openapi.models.V1CronJobStatusFluent fluent,io.kubernetes.client.openapi.models.V1CronJobStatus instance) { + + public V1CronJobStatusBuilder( + io.kubernetes.client.openapi.models.V1CronJobStatusFluent fluent, + io.kubernetes.client.openapi.models.V1CronJobStatus instance) { this(fluent, instance, false); } - public V1CronJobStatusBuilder(io.kubernetes.client.openapi.models.V1CronJobStatusFluent fluent,io.kubernetes.client.openapi.models.V1CronJobStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CronJobStatusBuilder( + io.kubernetes.client.openapi.models.V1CronJobStatusFluent fluent, + io.kubernetes.client.openapi.models.V1CronJobStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withActive(instance.getActive()); fluent.withLastScheduleTime(instance.getLastScheduleTime()); fluent.withLastSuccessfulTime(instance.getLastSuccessfulTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1CronJobStatusBuilder(io.kubernetes.client.openapi.models.V1CronJobStatus instance) { - this(instance,false); + this(instance, false); } - public V1CronJobStatusBuilder(io.kubernetes.client.openapi.models.V1CronJobStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CronJobStatusBuilder( + io.kubernetes.client.openapi.models.V1CronJobStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withActive(instance.getActive()); this.withLastScheduleTime(instance.getLastScheduleTime()); this.withLastSuccessfulTime(instance.getLastSuccessfulTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CronJobStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CronJobStatus build() { V1CronJobStatus buildable = new V1CronJobStatus(); buildable.setActive(fluent.getActive()); @@ -51,18 +84,23 @@ public io.kubernetes.client.openapi.models.V1CronJobStatus build() { buildable.setLastSuccessfulTime(fluent.getLastSuccessfulTime()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CronJobStatusBuilder that = (V1CronJobStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobStatusFluent.java index 91de7b0e12..aff58b78b1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobStatusFluent.java @@ -1,64 +1,110 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CronJobStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToActive(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item); - public A setToActive(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item); +/** Generated */ +public interface V1CronJobStatusFluent< + A extends io.kubernetes.client.openapi.models.V1CronJobStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToActive( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item); + + public A setToActive( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item); + public A addToActive(io.kubernetes.client.openapi.models.V1ObjectReference... items); - public A addAllToActive(java.util.Collection items); + + public A addAllToActive( + java.util.Collection items); + public A removeFromActive(io.kubernetes.client.openapi.models.V1ObjectReference... items); - public A removeAllFromActive(java.util.Collection items); - public A removeMatchingFromActive(java.util.function.Predicate predicate); - + + public A removeAllFromActive( + java.util.Collection items); + + public A removeMatchingFromActive( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildActive instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getActive(); + public java.util.List buildActive(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildActive(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ObjectReference buildFirstActive(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildLastActive(); - public io.kubernetes.client.openapi.models.V1ObjectReference buildMatchingActive(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingActive(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ObjectReference buildMatchingActive( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingActive( + java.util.function.Predicate + predicate); + public A withActive(java.util.List active); + public A withActive(io.kubernetes.client.openapi.models.V1ObjectReference... active); + public java.lang.Boolean hasActive(); + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested addNewActive(); - public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested addNewActiveLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested setNewActiveLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item); - public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested editActive(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested editFirstActive(); + + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested addNewActiveLike( + io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested setNewActiveLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested editActive( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested + editFirstActive(); + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested editLastActive(); - public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested editMatchingActive(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested + editMatchingActive( + java.util.function.Predicate + predicate); + public java.time.OffsetDateTime getLastScheduleTime(); + public A withLastScheduleTime(java.time.OffsetDateTime lastScheduleTime); + public java.lang.Boolean hasLastScheduleTime(); + public java.time.OffsetDateTime getLastSuccessfulTime(); + public A withLastSuccessfulTime(java.time.OffsetDateTime lastSuccessfulTime); + public java.lang.Boolean hasLastSuccessfulTime(); - public interface ActiveNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface ActiveNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested> { public N and(); + public N endActive(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobStatusFluentImpl.java index 658bcc1cda..1ea1dc7daf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CronJobStatusFluentImpl.java @@ -1,64 +1,133 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1CronJobStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CronJobStatusFluent{ - public V1CronJobStatusFluentImpl() { - } +/** Generated */ +public class V1CronJobStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CronJobStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CronJobStatusFluent { + public V1CronJobStatusFluentImpl() {} + public V1CronJobStatusFluentImpl(io.kubernetes.client.openapi.models.V1CronJobStatus instance) { this.withActive(instance.getActive()); this.withLastScheduleTime(instance.getLastScheduleTime()); this.withLastSuccessfulTime(instance.getLastSuccessfulTime()); - } + private java.util.ArrayList active; private java.time.OffsetDateTime lastScheduleTime; private java.time.OffsetDateTime lastSuccessfulTime; - public A addToActive(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item) { - if (this.active == null) {this.active = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("active").add(index >= 0 ? index : _visitables.get("active").size(), builder);this.active.add(index >= 0 ? index : active.size(), builder); return (A)this; + + public A addToActive( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item) { + if (this.active == null) { + this.active = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("active").add(index >= 0 ? index : _visitables.get("active").size(), builder); + this.active.add(index >= 0 ? index : active.size(), builder); + return (A) this; } - public A setToActive(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item) { - if (this.active == null) {this.active = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); - if (index < 0 || index >= _visitables.get("active").size()) { _visitables.get("active").add(builder); } else { _visitables.get("active").set(index, builder);} - if (index < 0 || index >= active.size()) { active.add(builder); } else { active.set(index, builder);} - return (A)this; + + public A setToActive( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item) { + if (this.active == null) { + this.active = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + if (index < 0 || index >= _visitables.get("active").size()) { + _visitables.get("active").add(builder); + } else { + _visitables.get("active").set(index, builder); + } + if (index < 0 || index >= active.size()) { + active.add(builder); + } else { + active.set(index, builder); + } + return (A) this; } + public A addToActive(io.kubernetes.client.openapi.models.V1ObjectReference... items) { - if (this.active == null) {this.active = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) {io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("active").add(builder);this.active.add(builder);} return (A)this; + if (this.active == null) { + this.active = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) { + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("active").add(builder); + this.active.add(builder); + } + return (A) this; } - public A addAllToActive(java.util.Collection items) { - if (this.active == null) {this.active = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) {io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("active").add(builder);this.active.add(builder);} return (A)this; + + public A addAllToActive( + java.util.Collection items) { + if (this.active == null) { + this.active = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) { + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("active").add(builder); + this.active.add(builder); + } + return (A) this; } + public A removeFromActive(io.kubernetes.client.openapi.models.V1ObjectReference... items) { - for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) {io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("active").remove(builder);if (this.active != null) {this.active.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) { + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("active").remove(builder); + if (this.active != null) { + this.active.remove(builder); + } + } + return (A) this; } - public A removeAllFromActive(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) {io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("active").remove(builder);if (this.active != null) {this.active.remove(builder);}} return (A)this; + + public A removeAllFromActive( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) { + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("active").remove(builder); + if (this.active != null) { + this.active.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromActive(java.util.function.Predicate predicate) { + + public A removeMatchingFromActive( + java.util.function.Predicate + predicate) { if (active == null) return (A) this; - final Iterator each = active.iterator(); + final Iterator each = + active.iterator(); final List visitables = _visitables.get("active"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = each.next(); @@ -67,124 +136,211 @@ public A removeMatchingFromActive(java.util.function.Predicate getActive() { return active != null ? build(active) : null; } + public java.util.List buildActive() { return active != null ? build(active) : null; } - public io.kubernetes.client.openapi.models.V1ObjectReference buildActive(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ObjectReference buildActive( + java.lang.Integer index) { return this.active.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ObjectReference buildFirstActive() { return this.active.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ObjectReference buildLastActive() { return this.active.get(active.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ObjectReference buildMatchingActive(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder item: active) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ObjectReference buildMatchingActive( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder item : active) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingActive(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder item: active) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingActive( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder item : active) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withActive(java.util.List active) { - if (this.active != null) { _visitables.get("active").removeAll(this.active);} - if (active != null) {this.active = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ObjectReference item : active){this.addToActive(item);}} else { this.active = null;} return (A) this; + + public A withActive( + java.util.List active) { + if (this.active != null) { + _visitables.get("active").removeAll(this.active); + } + if (active != null) { + this.active = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ObjectReference item : active) { + this.addToActive(item); + } + } else { + this.active = null; + } + return (A) this; } + public A withActive(io.kubernetes.client.openapi.models.V1ObjectReference... active) { - if (this.active != null) {this.active.clear();} - if (active != null) {for (io.kubernetes.client.openapi.models.V1ObjectReference item :active){ this.addToActive(item);}} return (A) this; + if (this.active != null) { + this.active.clear(); + } + if (active != null) { + for (io.kubernetes.client.openapi.models.V1ObjectReference item : active) { + this.addToActive(item); + } + } + return (A) this; } + public java.lang.Boolean hasActive() { return active != null && !active.isEmpty(); } + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested addNewActive() { return new io.kubernetes.client.openapi.models.V1CronJobStatusFluentImpl.ActiveNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested addNewActiveLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return new io.kubernetes.client.openapi.models.V1CronJobStatusFluentImpl.ActiveNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested addNewActiveLike( + io.kubernetes.client.openapi.models.V1ObjectReference item) { + return new io.kubernetes.client.openapi.models.V1CronJobStatusFluentImpl.ActiveNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested setNewActiveLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item) { - return new io.kubernetes.client.openapi.models.V1CronJobStatusFluentImpl.ActiveNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested setNewActiveLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item) { + return new io.kubernetes.client.openapi.models.V1CronJobStatusFluentImpl.ActiveNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested editActive(java.lang.Integer index) { - if (active.size() <= index) throw new RuntimeException("Can't edit active. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested editActive( + java.lang.Integer index) { + if (active.size() <= index) + throw new RuntimeException("Can't edit active. Index exceeds size."); return setNewActiveLike(index, buildActive(index)); } - public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested editFirstActive() { - if (active.size() == 0) throw new RuntimeException("Can't edit first active. The list is empty."); + + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested + editFirstActive() { + if (active.size() == 0) + throw new RuntimeException("Can't edit first active. The list is empty."); return setNewActiveLike(0, buildActive(0)); } - public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested editLastActive() { + + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested + editLastActive() { int index = active.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last active. The list is empty."); return setNewActiveLike(index, buildActive(index)); } - public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested editMatchingActive(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested + editMatchingActive( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested,io.kubernetes.client.fluent.Nested{ - ActiveNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item) { + + public class ActiveNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested> + implements io.kubernetes.client.openapi.models.V1CronJobStatusFluent.ActiveNested, + io.kubernetes.client.fluent.Nested { + ActiveNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + ActiveNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1CronJobStatusFluentImpl.this.setToActive(index,builder.build()); + return (N) V1CronJobStatusFluentImpl.this.setToActive(index, builder.build()); } + public N endActive() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CrossVersionObjectReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CrossVersionObjectReferenceBuilder.java index 6a9f557802..fa3e76fa7d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CrossVersionObjectReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CrossVersionObjectReferenceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CrossVersionObjectReferenceBuilder extends io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CrossVersionObjectReferenceBuilder + extends io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CrossVersionObjectReference, + io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceBuilder> { public V1CrossVersionObjectReferenceBuilder() { this(false); } + public V1CrossVersionObjectReferenceBuilder(java.lang.Boolean validationEnabled) { this(new V1CrossVersionObjectReference(), validationEnabled); } - public V1CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent fluent) { + + public V1CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent fluent) { this(fluent, false); } - public V1CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CrossVersionObjectReference(), validationEnabled); } - public V1CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V1CrossVersionObjectReference instance) { + + public V1CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1CrossVersionObjectReference instance) { this(fluent, instance, false); } - public V1CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V1CrossVersionObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1CrossVersionObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1CrossVersionObjectReference instance) { - this(instance,false); + + public V1CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReference instance) { + this(instance, false); } - public V1CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1CrossVersionObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CrossVersionObjectReference build() { V1CrossVersionObjectReference buildable = new V1CrossVersionObjectReference(); buildable.setApiVersion(fluent.getApiVersion()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1CrossVersionObjectReference build() buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CrossVersionObjectReferenceBuilder that = (V1CrossVersionObjectReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CrossVersionObjectReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CrossVersionObjectReferenceFluent.java index c453a50bb9..0e49388a25 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CrossVersionObjectReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CrossVersionObjectReferenceFluent.java @@ -1,41 +1,48 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CrossVersionObjectReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CrossVersionObjectReferenceFluent< + A extends io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CrossVersionObjectReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CrossVersionObjectReferenceFluentImpl.java index 2bd657513e..7ed37c5941 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CrossVersionObjectReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CrossVersionObjectReferenceFluentImpl.java @@ -1,90 +1,106 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1CrossVersionObjectReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent{ - public V1CrossVersionObjectReferenceFluentImpl() { - } - public V1CrossVersionObjectReferenceFluentImpl(io.kubernetes.client.openapi.models.V1CrossVersionObjectReference instance) { +/** Generated */ +public class V1CrossVersionObjectReferenceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent { + public V1CrossVersionObjectReferenceFluentImpl() {} + + public V1CrossVersionObjectReferenceFluentImpl( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReference instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); this.withName(instance.getName()); - } + private java.lang.String apiVersion; private java.lang.String kind; private java.lang.String name; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CrossVersionObjectReferenceFluentImpl that = (V1CrossVersionObjectReferenceFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, name, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceColumnDefinitionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceColumnDefinitionBuilder.java index f2fff38f39..99e7a09315 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceColumnDefinitionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceColumnDefinitionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CustomResourceColumnDefinitionBuilder extends io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CustomResourceColumnDefinitionBuilder + extends io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition, + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder> { public V1CustomResourceColumnDefinitionBuilder() { this(false); } + public V1CustomResourceColumnDefinitionBuilder(java.lang.Boolean validationEnabled) { this(new V1CustomResourceColumnDefinition(), validationEnabled); } - public V1CustomResourceColumnDefinitionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent fluent) { + + public V1CustomResourceColumnDefinitionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent fluent) { this(fluent, false); } - public V1CustomResourceColumnDefinitionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CustomResourceColumnDefinitionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CustomResourceColumnDefinition(), validationEnabled); } - public V1CustomResourceColumnDefinitionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition instance) { + + public V1CustomResourceColumnDefinitionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition instance) { this(fluent, instance, false); } - public V1CustomResourceColumnDefinitionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CustomResourceColumnDefinitionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDescription(instance.getDescription()); fluent.withFormat(instance.getFormat()); @@ -33,13 +60,18 @@ public V1CustomResourceColumnDefinitionBuilder(io.kubernetes.client.openapi.mode fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CustomResourceColumnDefinitionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition instance) { - this(instance,false); + + public V1CustomResourceColumnDefinitionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition instance) { + this(instance, false); } - public V1CustomResourceColumnDefinitionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CustomResourceColumnDefinitionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDescription(instance.getDescription()); this.withFormat(instance.getFormat()); @@ -52,10 +84,12 @@ public V1CustomResourceColumnDefinitionBuilder(io.kubernetes.client.openapi.mode this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition build() { V1CustomResourceColumnDefinition buildable = new V1CustomResourceColumnDefinition(); buildable.setDescription(fluent.getDescription()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition buil buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CustomResourceColumnDefinitionBuilder that = (V1CustomResourceColumnDefinitionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceColumnDefinitionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceColumnDefinitionFluent.java index 23a5e146e1..6878fc96d6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceColumnDefinitionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceColumnDefinitionFluent.java @@ -1,63 +1,74 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CustomResourceColumnDefinitionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CustomResourceColumnDefinitionFluent< + A extends io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getDescription(); + public A withDescription(java.lang.String description); + public java.lang.Boolean hasDescription(); - - /** - * Method is deprecated. use withDescription instead. - */ + + /** Method is deprecated. use withDescription instead. */ @java.lang.Deprecated public A withNewDescription(java.lang.String original); + public java.lang.String getFormat(); + public A withFormat(java.lang.String format); + public java.lang.Boolean hasFormat(); - - /** - * Method is deprecated. use withFormat instead. - */ + + /** Method is deprecated. use withFormat instead. */ @java.lang.Deprecated public A withNewFormat(java.lang.String original); + public java.lang.String getJsonPath(); + public A withJsonPath(java.lang.String jsonPath); + public java.lang.Boolean hasJsonPath(); - - /** - * Method is deprecated. use withJsonPath instead. - */ + + /** Method is deprecated. use withJsonPath instead. */ @java.lang.Deprecated public A withNewJsonPath(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Integer getPriority(); + public A withPriority(java.lang.Integer priority); + public java.lang.Boolean hasPriority(); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceColumnDefinitionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceColumnDefinitionFluentImpl.java index 0857396a43..25c05e67da 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceColumnDefinitionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceColumnDefinitionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1CustomResourceColumnDefinitionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent { + public V1CustomResourceColumnDefinitionFluentImpl() {} - /** - * Generated - */ -public class V1CustomResourceColumnDefinitionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent{ - public V1CustomResourceColumnDefinitionFluentImpl() { - } - public V1CustomResourceColumnDefinitionFluentImpl(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition instance) { + public V1CustomResourceColumnDefinitionFluentImpl( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition instance) { this.withDescription(instance.getDescription()); this.withFormat(instance.getFormat()); @@ -25,122 +32,140 @@ public V1CustomResourceColumnDefinitionFluentImpl(io.kubernetes.client.openapi.m this.withPriority(instance.getPriority()); this.withType(instance.getType()); - } + private java.lang.String description; private java.lang.String format; private java.lang.String jsonPath; private java.lang.String name; private java.lang.Integer priority; private java.lang.String type; + public java.lang.String getDescription() { return this.description; } + public A withDescription(java.lang.String description) { - this.description=description; return (A) this; + this.description = description; + return (A) this; } + public java.lang.Boolean hasDescription() { return this.description != null; } - - /** - * Method is deprecated. use withDescription instead. - */ + + /** Method is deprecated. use withDescription instead. */ @java.lang.Deprecated public A withNewDescription(java.lang.String original) { - return (A)withDescription(new String(original)); + return (A) withDescription(new String(original)); } + public java.lang.String getFormat() { return this.format; } + public A withFormat(java.lang.String format) { - this.format=format; return (A) this; + this.format = format; + return (A) this; } + public java.lang.Boolean hasFormat() { return this.format != null; } - - /** - * Method is deprecated. use withFormat instead. - */ + + /** Method is deprecated. use withFormat instead. */ @java.lang.Deprecated public A withNewFormat(java.lang.String original) { - return (A)withFormat(new String(original)); + return (A) withFormat(new String(original)); } + public java.lang.String getJsonPath() { return this.jsonPath; } + public A withJsonPath(java.lang.String jsonPath) { - this.jsonPath=jsonPath; return (A) this; + this.jsonPath = jsonPath; + return (A) this; } + public java.lang.Boolean hasJsonPath() { return this.jsonPath != null; } - - /** - * Method is deprecated. use withJsonPath instead. - */ + + /** Method is deprecated. use withJsonPath instead. */ @java.lang.Deprecated public A withNewJsonPath(java.lang.String original) { - return (A)withJsonPath(new String(original)); + return (A) withJsonPath(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Integer getPriority() { return this.priority; } + public A withPriority(java.lang.Integer priority) { - this.priority=priority; return (A) this; + this.priority = priority; + return (A) this; } + public java.lang.Boolean hasPriority() { return this.priority != null; } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1CustomResourceColumnDefinitionFluentImpl that = (V1CustomResourceColumnDefinitionFluentImpl) o; - if (description != null ? !description.equals(that.description) :that.description != null) return false; - if (format != null ? !format.equals(that.format) :that.format != null) return false; - if (jsonPath != null ? !jsonPath.equals(that.jsonPath) :that.jsonPath != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (priority != null ? !priority.equals(that.priority) :that.priority != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + V1CustomResourceColumnDefinitionFluentImpl that = + (V1CustomResourceColumnDefinitionFluentImpl) o; + if (description != null ? !description.equals(that.description) : that.description != null) + return false; + if (format != null ? !format.equals(that.format) : that.format != null) return false; + if (jsonPath != null ? !jsonPath.equals(that.jsonPath) : that.jsonPath != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (priority != null ? !priority.equals(that.priority) : that.priority != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(description, format, jsonPath, name, priority, type, super.hashCode()); + return java.util.Objects.hash( + description, format, jsonPath, name, priority, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceConversionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceConversionBuilder.java index 2b139e89c6..5a20fe343d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceConversionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceConversionBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CustomResourceConversionBuilder extends io.kubernetes.client.openapi.models.V1CustomResourceConversionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CustomResourceConversionBuilder + extends io.kubernetes.client.openapi.models.V1CustomResourceConversionFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceConversionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CustomResourceConversion, + io.kubernetes.client.openapi.models.V1CustomResourceConversionBuilder> { public V1CustomResourceConversionBuilder() { this(false); } + public V1CustomResourceConversionBuilder(java.lang.Boolean validationEnabled) { this(new V1CustomResourceConversion(), validationEnabled); } - public V1CustomResourceConversionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent fluent) { + + public V1CustomResourceConversionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent fluent) { this(fluent, false); } - public V1CustomResourceConversionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CustomResourceConversionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CustomResourceConversion(), validationEnabled); } - public V1CustomResourceConversionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceConversion instance) { + + public V1CustomResourceConversionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceConversion instance) { this(fluent, instance, false); } - public V1CustomResourceConversionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceConversion instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CustomResourceConversionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceConversion instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withStrategy(instance.getStrategy()); fluent.withWebhook(instance.getWebhook()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CustomResourceConversionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceConversion instance) { - this(instance,false); + + public V1CustomResourceConversionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceConversion instance) { + this(instance, false); } - public V1CustomResourceConversionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceConversion instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CustomResourceConversionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceConversion instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withStrategy(instance.getStrategy()); this.withWebhook(instance.getWebhook()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CustomResourceConversion build() { V1CustomResourceConversion buildable = new V1CustomResourceConversion(); buildable.setStrategy(fluent.getStrategy()); buildable.setWebhook(fluent.getWebhook()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CustomResourceConversionBuilder that = (V1CustomResourceConversionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceConversionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceConversionFluent.java index b17846330c..e9011e6ddc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceConversionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceConversionFluent.java @@ -1,44 +1,67 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CustomResourceConversionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CustomResourceConversionFluent< + A extends io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getStrategy(); + public A withStrategy(java.lang.String strategy); + public java.lang.Boolean hasStrategy(); - - /** - * Method is deprecated. use withStrategy instead. - */ + + /** Method is deprecated. use withStrategy instead. */ @java.lang.Deprecated public A withNewStrategy(java.lang.String original); - + /** * This method has been deprecated, please use method buildWebhook instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1WebhookConversion getWebhook(); + public io.kubernetes.client.openapi.models.V1WebhookConversion buildWebhook(); + public A withWebhook(io.kubernetes.client.openapi.models.V1WebhookConversion webhook); + public java.lang.Boolean hasWebhook(); - public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested withNewWebhook(); - public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested withNewWebhookLike(io.kubernetes.client.openapi.models.V1WebhookConversion item); - public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested editWebhook(); - public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested editOrNewWebhook(); - public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested editOrNewWebhookLike(io.kubernetes.client.openapi.models.V1WebhookConversion item); - public interface WebhookNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1WebhookConversionFluent>{ + + public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested + withNewWebhook(); + + public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested + withNewWebhookLike(io.kubernetes.client.openapi.models.V1WebhookConversion item); + + public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested + editWebhook(); + + public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested + editOrNewWebhook(); + + public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested + editOrNewWebhookLike(io.kubernetes.client.openapi.models.V1WebhookConversion item); + + public interface WebhookNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1WebhookConversionFluent< + io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested< + N>> { public N and(); + public N endWebhook(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceConversionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceConversionFluentImpl.java index 59e58a8414..c44655c988 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceConversionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceConversionFluentImpl.java @@ -1,103 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1CustomResourceConversionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent { + public V1CustomResourceConversionFluentImpl() {} - /** - * Generated - */ -public class V1CustomResourceConversionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent{ - public V1CustomResourceConversionFluentImpl() { - } - public V1CustomResourceConversionFluentImpl(io.kubernetes.client.openapi.models.V1CustomResourceConversion instance) { + public V1CustomResourceConversionFluentImpl( + io.kubernetes.client.openapi.models.V1CustomResourceConversion instance) { this.withStrategy(instance.getStrategy()); this.withWebhook(instance.getWebhook()); - } + private java.lang.String strategy; private io.kubernetes.client.openapi.models.V1WebhookConversionBuilder webhook; + public java.lang.String getStrategy() { return this.strategy; } + public A withStrategy(java.lang.String strategy) { - this.strategy=strategy; return (A) this; + this.strategy = strategy; + return (A) this; } + public java.lang.Boolean hasStrategy() { return this.strategy != null; } - - /** - * Method is deprecated. use withStrategy instead. - */ + + /** Method is deprecated. use withStrategy instead. */ @java.lang.Deprecated public A withNewStrategy(java.lang.String original) { - return (A)withStrategy(new String(original)); + return (A) withStrategy(new String(original)); } - + /** * This method has been deprecated, please use method buildWebhook instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1WebhookConversion getWebhook() { - return this.webhook!=null ?this.webhook.build():null; + return this.webhook != null ? this.webhook.build() : null; } + public io.kubernetes.client.openapi.models.V1WebhookConversion buildWebhook() { - return this.webhook!=null ?this.webhook.build():null; + return this.webhook != null ? this.webhook.build() : null; } + public A withWebhook(io.kubernetes.client.openapi.models.V1WebhookConversion webhook) { _visitables.get("webhook").remove(this.webhook); - if (webhook!=null){ this.webhook= new io.kubernetes.client.openapi.models.V1WebhookConversionBuilder(webhook); _visitables.get("webhook").add(this.webhook);} return (A) this; + if (webhook != null) { + this.webhook = new io.kubernetes.client.openapi.models.V1WebhookConversionBuilder(webhook); + _visitables.get("webhook").add(this.webhook); + } + return (A) this; } + public java.lang.Boolean hasWebhook() { return this.webhook != null; } - public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested withNewWebhook() { - return new io.kubernetes.client.openapi.models.V1CustomResourceConversionFluentImpl.WebhookNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested + withNewWebhook() { + return new io.kubernetes.client.openapi.models.V1CustomResourceConversionFluentImpl + .WebhookNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested withNewWebhookLike(io.kubernetes.client.openapi.models.V1WebhookConversion item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceConversionFluentImpl.WebhookNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested + withNewWebhookLike(io.kubernetes.client.openapi.models.V1WebhookConversion item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceConversionFluentImpl + .WebhookNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested editWebhook() { + + public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested + editWebhook() { return withNewWebhookLike(getWebhook()); } - public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested editOrNewWebhook() { - return withNewWebhookLike(getWebhook() != null ? getWebhook(): new io.kubernetes.client.openapi.models.V1WebhookConversionBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested + editOrNewWebhook() { + return withNewWebhookLike( + getWebhook() != null + ? getWebhook() + : new io.kubernetes.client.openapi.models.V1WebhookConversionBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested editOrNewWebhookLike(io.kubernetes.client.openapi.models.V1WebhookConversion item) { - return withNewWebhookLike(getWebhook() != null ? getWebhook(): item); + + public io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested + editOrNewWebhookLike(io.kubernetes.client.openapi.models.V1WebhookConversion item) { + return withNewWebhookLike(getWebhook() != null ? getWebhook() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CustomResourceConversionFluentImpl that = (V1CustomResourceConversionFluentImpl) o; - if (strategy != null ? !strategy.equals(that.strategy) :that.strategy != null) return false; - if (webhook != null ? !webhook.equals(that.webhook) :that.webhook != null) return false; + if (strategy != null ? !strategy.equals(that.strategy) : that.strategy != null) return false; + if (webhook != null ? !webhook.equals(that.webhook) : that.webhook != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(strategy, webhook, super.hashCode()); + return java.util.Objects.hash(strategy, webhook, super.hashCode()); } - public class WebhookNestedImpl extends io.kubernetes.client.openapi.models.V1WebhookConversionFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested,io.kubernetes.client.fluent.Nested{ + + public class WebhookNestedImpl + extends io.kubernetes.client.openapi.models.V1WebhookConversionFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested> + implements io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent.WebhookNested< + N>, + io.kubernetes.client.fluent.Nested { WebhookNestedImpl(io.kubernetes.client.openapi.models.V1WebhookConversion item) { this.builder = new io.kubernetes.client.openapi.models.V1WebhookConversionBuilder(this, item); } + WebhookNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1WebhookConversionBuilder(this); } + io.kubernetes.client.openapi.models.V1WebhookConversionBuilder builder; + public N and() { return (N) V1CustomResourceConversionFluentImpl.this.withWebhook(builder.build()); } + public N endWebhook() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionBuilder.java index 8cc1868180..ad27e1caa8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CustomResourceDefinitionBuilder extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CustomResourceDefinitionBuilder + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CustomResourceDefinition, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder> { public V1CustomResourceDefinitionBuilder() { this(false); } + public V1CustomResourceDefinitionBuilder(java.lang.Boolean validationEnabled) { this(new V1CustomResourceDefinition(), validationEnabled); } - public V1CustomResourceDefinitionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent fluent) { + + public V1CustomResourceDefinitionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent fluent) { this(fluent, false); } - public V1CustomResourceDefinitionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CustomResourceDefinitionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CustomResourceDefinition(), validationEnabled); } - public V1CustomResourceDefinitionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinition instance) { + + public V1CustomResourceDefinitionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinition instance) { this(fluent, instance, false); } - public V1CustomResourceDefinitionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CustomResourceDefinitionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1CustomResourceDefinitionBuilder(io.kubernetes.client.openapi.models.V1C fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CustomResourceDefinitionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinition instance) { - this(instance,false); + + public V1CustomResourceDefinitionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinition instance) { + this(instance, false); } - public V1CustomResourceDefinitionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CustomResourceDefinitionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1CustomResourceDefinitionBuilder(io.kubernetes.client.openapi.models.V1C this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CustomResourceDefinition build() { V1CustomResourceDefinition buildable = new V1CustomResourceDefinition(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1CustomResourceDefinition build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CustomResourceDefinitionBuilder that = (V1CustomResourceDefinitionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionConditionBuilder.java index b00746dbe5..df4cef87b3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CustomResourceDefinitionConditionBuilder extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CustomResourceDefinitionConditionBuilder + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder> { public V1CustomResourceDefinitionConditionBuilder() { this(false); } + public V1CustomResourceDefinitionConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1CustomResourceDefinitionCondition(), validationEnabled); } - public V1CustomResourceDefinitionConditionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent fluent) { + + public V1CustomResourceDefinitionConditionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent fluent) { this(fluent, false); } - public V1CustomResourceDefinitionConditionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CustomResourceDefinitionConditionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CustomResourceDefinitionCondition(), validationEnabled); } - public V1CustomResourceDefinitionConditionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition instance) { + + public V1CustomResourceDefinitionConditionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition instance) { this(fluent, instance, false); } - public V1CustomResourceDefinitionConditionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CustomResourceDefinitionConditionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +58,18 @@ public V1CustomResourceDefinitionConditionBuilder(io.kubernetes.client.openapi.m fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CustomResourceDefinitionConditionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition instance) { - this(instance,false); + + public V1CustomResourceDefinitionConditionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition instance) { + this(instance, false); } - public V1CustomResourceDefinitionConditionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CustomResourceDefinitionConditionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,10 +80,12 @@ public V1CustomResourceDefinitionConditionBuilder(io.kubernetes.client.openapi.m this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition build() { V1CustomResourceDefinitionCondition buildable = new V1CustomResourceDefinitionCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -61,18 +95,24 @@ public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition b buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1CustomResourceDefinitionConditionBuilder that = (V1CustomResourceDefinitionConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1CustomResourceDefinitionConditionBuilder that = + (V1CustomResourceDefinitionConditionBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionConditionFluent.java index d9bfb962fd..6430310172 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionConditionFluent.java @@ -1,54 +1,64 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CustomResourceDefinitionConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CustomResourceDefinitionConditionFluent< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionConditionFluentImpl.java index fc2a22644d..d29320db47 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionConditionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1CustomResourceDefinitionConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent { + public V1CustomResourceDefinitionConditionFluentImpl() {} - /** - * Generated - */ -public class V1CustomResourceDefinitionConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent{ - public V1CustomResourceDefinitionConditionFluentImpl() { - } - public V1CustomResourceDefinitionConditionFluentImpl(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition instance) { + public V1CustomResourceDefinitionConditionFluentImpl( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,103 +30,120 @@ public V1CustomResourceDefinitionConditionFluentImpl(io.kubernetes.client.openap this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1CustomResourceDefinitionConditionFluentImpl that = (V1CustomResourceDefinitionConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + V1CustomResourceDefinitionConditionFluentImpl that = + (V1CustomResourceDefinitionConditionFluentImpl) o; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionFluent.java index 268f1c203a..3b16f6c8c9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionFluent.java @@ -1,93 +1,155 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CustomResourceDefinitionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CustomResourceDefinitionFluent< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec getSpec(); + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec item); - + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus getStatus(); + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested< + N>> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionFluentImpl.java index 2247edbd82..4ea2f5b412 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1CustomResourceDefinitionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent { + public V1CustomResourceDefinitionFluentImpl() {} - /** - * Generated - */ -public class V1CustomResourceDefinitionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent{ - public V1CustomResourceDefinitionFluentImpl() { - } - public V1CustomResourceDefinitionFluentImpl(io.kubernetes.client.openapi.models.V1CustomResourceDefinition instance) { + public V1CustomResourceDefinitionFluentImpl( + io.kubernetes.client.openapi.models.V1CustomResourceDefinition instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,322 @@ public V1CustomResourceDefinitionFluentImpl(io.kubernetes.client.openapi.models. this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecBuilder spec; private io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CustomResourceDefinitionFluentImpl that = (V1CustomResourceDefinitionFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1CustomResourceDefinitionFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecBuilder(this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecBuilder builder; + public N and() { return (N) V1CustomResourceDefinitionFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent.StatusNested< + N>, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusBuilder( + this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusBuilder builder; + public N and() { return (N) V1CustomResourceDefinitionFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionListBuilder.java index a0f17b6e60..251692bf20 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CustomResourceDefinitionListBuilder extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CustomResourceDefinitionListBuilder + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionList, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListBuilder> { public V1CustomResourceDefinitionListBuilder() { this(false); } + public V1CustomResourceDefinitionListBuilder(java.lang.Boolean validationEnabled) { this(new V1CustomResourceDefinitionList(), validationEnabled); } - public V1CustomResourceDefinitionListBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent fluent) { + + public V1CustomResourceDefinitionListBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent fluent) { this(fluent, false); } - public V1CustomResourceDefinitionListBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CustomResourceDefinitionListBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CustomResourceDefinitionList(), validationEnabled); } - public V1CustomResourceDefinitionListBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionList instance) { + + public V1CustomResourceDefinitionListBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionList instance) { this(fluent, instance, false); } - public V1CustomResourceDefinitionListBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CustomResourceDefinitionListBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1CustomResourceDefinitionListBuilder(io.kubernetes.client.openapi.models fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CustomResourceDefinitionListBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionList instance) { - this(instance,false); + + public V1CustomResourceDefinitionListBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionList instance) { + this(instance, false); } - public V1CustomResourceDefinitionListBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CustomResourceDefinitionListBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1CustomResourceDefinitionListBuilder(io.kubernetes.client.openapi.models this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionList build() { V1CustomResourceDefinitionList buildable = new V1CustomResourceDefinitionList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionList build( buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CustomResourceDefinitionListBuilder that = (V1CustomResourceDefinitionListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionListFluent.java index aa2eaea3c4..69705add84 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionListFluent.java @@ -1,95 +1,170 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CustomResourceDefinitionListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CustomResourceDefinitionListFluent< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinition item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinition item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CustomResourceDefinition item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1CustomResourceDefinition item); + public A addToItems(io.kubernetes.client.openapi.models.V1CustomResourceDefinition... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1CustomResourceDefinition... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); - public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinition buildItem(java.lang.Integer index); + + public java.util.List + buildItems(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinition buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1CustomResourceDefinition buildFirstItem(); + public io.kubernetes.client.openapi.models.V1CustomResourceDefinition buildLastItem(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinition buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinition buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1CustomResourceDefinition... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinition item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinition item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinition item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinition item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent>{ + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluent< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionListFluentImpl.java index e2e5b7b30a..7f3421cedf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1CustomResourceDefinitionListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent{ - public V1CustomResourceDefinitionListFluentImpl() { - } - public V1CustomResourceDefinitionListFluentImpl(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionList instance) { + +/** Generated */ +public class V1CustomResourceDefinitionListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent { + public V1CustomResourceDefinitionListFluentImpl() {} + + public V1CustomResourceDefinitionListFluentImpl( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,135 @@ public V1CustomResourceDefinitionListFluentImpl(io.kubernetes.client.openapi.mod this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinition item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinition item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder>(); + } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinition item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinition item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder>(); + } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1CustomResourceDefinition... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinition item : items) {io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinition item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinition item : items) {io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinition item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A removeFromItems(io.kubernetes.client.openapi.models.V1CustomResourceDefinition... items) { - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinition item : items) {io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeFromItems( + io.kubernetes.client.openapi.models.V1CustomResourceDefinition... items) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinition item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinition item : items) {io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinition item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder = each.next(); @@ -87,174 +168,297 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } - public java.util.List buildItems() { + + public java.util.List + buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinition buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinition buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1CustomResourceDefinition buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1CustomResourceDefinition buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinition buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinition buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1CustomResourceDefinition item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinition item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1CustomResourceDefinition... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1CustomResourceDefinition item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinition item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinition item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinition item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinition item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinition item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CustomResourceDefinitionListFluentImpl that = (V1CustomResourceDefinitionListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinition item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent + .ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder(this); } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1CustomResourceDefinitionListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1CustomResourceDefinitionListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent.MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1CustomResourceDefinitionListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionNamesBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionNamesBuilder.java index 028d8bf69b..ce6036b103 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionNamesBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionNamesBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CustomResourceDefinitionNamesBuilder extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CustomResourceDefinitionNamesBuilder + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder> { public V1CustomResourceDefinitionNamesBuilder() { this(false); } + public V1CustomResourceDefinitionNamesBuilder(java.lang.Boolean validationEnabled) { this(new V1CustomResourceDefinitionNames(), validationEnabled); } - public V1CustomResourceDefinitionNamesBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent fluent) { + + public V1CustomResourceDefinitionNamesBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent fluent) { this(fluent, false); } - public V1CustomResourceDefinitionNamesBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CustomResourceDefinitionNamesBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CustomResourceDefinitionNames(), validationEnabled); } - public V1CustomResourceDefinitionNamesBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames instance) { + + public V1CustomResourceDefinitionNamesBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames instance) { this(fluent, instance, false); } - public V1CustomResourceDefinitionNamesBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CustomResourceDefinitionNamesBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCategories(instance.getCategories()); fluent.withKind(instance.getKind()); @@ -33,13 +60,18 @@ public V1CustomResourceDefinitionNamesBuilder(io.kubernetes.client.openapi.model fluent.withSingular(instance.getSingular()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CustomResourceDefinitionNamesBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames instance) { - this(instance,false); + + public V1CustomResourceDefinitionNamesBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames instance) { + this(instance, false); } - public V1CustomResourceDefinitionNamesBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CustomResourceDefinitionNamesBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCategories(instance.getCategories()); this.withKind(instance.getKind()); @@ -52,10 +84,12 @@ public V1CustomResourceDefinitionNamesBuilder(io.kubernetes.client.openapi.model this.withSingular(instance.getSingular()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames build() { V1CustomResourceDefinitionNames buildable = new V1CustomResourceDefinitionNames(); buildable.setCategories(fluent.getCategories()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames build buildable.setSingular(fluent.getSingular()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CustomResourceDefinitionNamesBuilder that = (V1CustomResourceDefinitionNamesBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionNamesFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionNamesFluent.java index 57049825e4..337f75f88a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionNamesFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionNamesFluent.java @@ -1,87 +1,126 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1CustomResourceDefinitionNamesFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToCategories(java.lang.Integer index,java.lang.String item); - public A setToCategories(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1CustomResourceDefinitionNamesFluent< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToCategories(java.lang.Integer index, java.lang.String item); + + public A setToCategories(java.lang.Integer index, java.lang.String item); + public A addToCategories(java.lang.String... items); + public A addAllToCategories(java.util.Collection items); + public A removeFromCategories(java.lang.String... items); + public A removeAllFromCategories(java.util.Collection items); + public java.util.List getCategories(); + public java.lang.String getCategory(java.lang.Integer index); + public java.lang.String getFirstCategory(); + public java.lang.String getLastCategory(); - public java.lang.String getMatchingCategory(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCategory(java.util.function.Predicate predicate); + + public java.lang.String getMatchingCategory( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingCategory( + java.util.function.Predicate predicate); + public A withCategories(java.util.List categories); + public A withCategories(java.lang.String... categories); + public java.lang.Boolean hasCategories(); + public A addNewCategory(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getListKind(); + public A withListKind(java.lang.String listKind); + public java.lang.Boolean hasListKind(); - - /** - * Method is deprecated. use withListKind instead. - */ + + /** Method is deprecated. use withListKind instead. */ @java.lang.Deprecated public A withNewListKind(java.lang.String original); + public java.lang.String getPlural(); + public A withPlural(java.lang.String plural); + public java.lang.Boolean hasPlural(); - - /** - * Method is deprecated. use withPlural instead. - */ + + /** Method is deprecated. use withPlural instead. */ @java.lang.Deprecated public A withNewPlural(java.lang.String original); - public A addToShortNames(java.lang.Integer index,java.lang.String item); - public A setToShortNames(java.lang.Integer index,java.lang.String item); + + public A addToShortNames(java.lang.Integer index, java.lang.String item); + + public A setToShortNames(java.lang.Integer index, java.lang.String item); + public A addToShortNames(java.lang.String... items); + public A addAllToShortNames(java.util.Collection items); + public A removeFromShortNames(java.lang.String... items); + public A removeAllFromShortNames(java.util.Collection items); + public java.util.List getShortNames(); + public java.lang.String getShortName(java.lang.Integer index); + public java.lang.String getFirstShortName(); + public java.lang.String getLastShortName(); - public java.lang.String getMatchingShortName(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingShortName(java.util.function.Predicate predicate); + + public java.lang.String getMatchingShortName( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingShortName( + java.util.function.Predicate predicate); + public A withShortNames(java.util.List shortNames); + public A withShortNames(java.lang.String... shortNames); + public java.lang.Boolean hasShortNames(); + public A addNewShortName(java.lang.String original); + public java.lang.String getSingular(); + public A withSingular(java.lang.String singular); + public java.lang.Boolean hasSingular(); - - /** - * Method is deprecated. use withSingular instead. - */ + + /** Method is deprecated. use withSingular instead. */ @java.lang.Deprecated public A withNewSingular(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionNamesFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionNamesFluentImpl.java index 5a4c90e740..c2b69965d3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionNamesFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionNamesFluentImpl.java @@ -1,23 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1CustomResourceDefinitionNamesFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent{ - public V1CustomResourceDefinitionNamesFluentImpl() { - } - public V1CustomResourceDefinitionNamesFluentImpl(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames instance) { +/** Generated */ +public class V1CustomResourceDefinitionNamesFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent { + public V1CustomResourceDefinitionNamesFluentImpl() {} + + public V1CustomResourceDefinitionNamesFluentImpl( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames instance) { this.withCategories(instance.getCategories()); this.withKind(instance.getKind()); @@ -29,204 +32,352 @@ public V1CustomResourceDefinitionNamesFluentImpl(io.kubernetes.client.openapi.mo this.withShortNames(instance.getShortNames()); this.withSingular(instance.getSingular()); - } + private java.util.List categories; private java.lang.String kind; private java.lang.String listKind; private java.lang.String plural; private java.util.List shortNames; private java.lang.String singular; - public A addToCategories(java.lang.Integer index,java.lang.String item) { - if (this.categories == null) {this.categories = new java.util.ArrayList();} + + public A addToCategories(java.lang.Integer index, java.lang.String item) { + if (this.categories == null) { + this.categories = new java.util.ArrayList(); + } this.categories.add(index, item); - return (A)this; + return (A) this; } - public A setToCategories(java.lang.Integer index,java.lang.String item) { - if (this.categories == null) {this.categories = new java.util.ArrayList();} - this.categories.set(index, item); return (A)this; + + public A setToCategories(java.lang.Integer index, java.lang.String item) { + if (this.categories == null) { + this.categories = new java.util.ArrayList(); + } + this.categories.set(index, item); + return (A) this; } + public A addToCategories(java.lang.String... items) { - if (this.categories == null) {this.categories = new java.util.ArrayList();} - for (java.lang.String item : items) {this.categories.add(item);} return (A)this; + if (this.categories == null) { + this.categories = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.categories.add(item); + } + return (A) this; } + public A addAllToCategories(java.util.Collection items) { - if (this.categories == null) {this.categories = new java.util.ArrayList();} - for (java.lang.String item : items) {this.categories.add(item);} return (A)this; + if (this.categories == null) { + this.categories = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.categories.add(item); + } + return (A) this; } + public A removeFromCategories(java.lang.String... items) { - for (java.lang.String item : items) {if (this.categories!= null){ this.categories.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.categories != null) { + this.categories.remove(item); + } + } + return (A) this; } + public A removeAllFromCategories(java.util.Collection items) { - for (java.lang.String item : items) {if (this.categories!= null){ this.categories.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.categories != null) { + this.categories.remove(item); + } + } + return (A) this; } + public java.util.List getCategories() { return this.categories; } + public java.lang.String getCategory(java.lang.Integer index) { return this.categories.get(index); } + public java.lang.String getFirstCategory() { return this.categories.get(0); } + public java.lang.String getLastCategory() { return this.categories.get(categories.size() - 1); } - public java.lang.String getMatchingCategory(java.util.function.Predicate predicate) { - for (java.lang.String item: categories) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingCategory( + java.util.function.Predicate predicate) { + for (java.lang.String item : categories) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingCategory(java.util.function.Predicate predicate) { - for (java.lang.String item: categories) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCategory( + java.util.function.Predicate predicate) { + for (java.lang.String item : categories) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withCategories(java.util.List categories) { - if (categories != null) {this.categories = new java.util.ArrayList(); for (java.lang.String item : categories){this.addToCategories(item);}} else { this.categories = null;} return (A) this; + if (categories != null) { + this.categories = new java.util.ArrayList(); + for (java.lang.String item : categories) { + this.addToCategories(item); + } + } else { + this.categories = null; + } + return (A) this; } + public A withCategories(java.lang.String... categories) { - if (this.categories != null) {this.categories.clear();} - if (categories != null) {for (java.lang.String item :categories){ this.addToCategories(item);}} return (A) this; + if (this.categories != null) { + this.categories.clear(); + } + if (categories != null) { + for (java.lang.String item : categories) { + this.addToCategories(item); + } + } + return (A) this; } + public java.lang.Boolean hasCategories() { return categories != null && !categories.isEmpty(); } + public A addNewCategory(java.lang.String original) { - return (A)addToCategories(new String(original)); + return (A) addToCategories(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getListKind() { return this.listKind; } + public A withListKind(java.lang.String listKind) { - this.listKind=listKind; return (A) this; + this.listKind = listKind; + return (A) this; } + public java.lang.Boolean hasListKind() { return this.listKind != null; } - - /** - * Method is deprecated. use withListKind instead. - */ + + /** Method is deprecated. use withListKind instead. */ @java.lang.Deprecated public A withNewListKind(java.lang.String original) { - return (A)withListKind(new String(original)); + return (A) withListKind(new String(original)); } + public java.lang.String getPlural() { return this.plural; } + public A withPlural(java.lang.String plural) { - this.plural=plural; return (A) this; + this.plural = plural; + return (A) this; } + public java.lang.Boolean hasPlural() { return this.plural != null; } - - /** - * Method is deprecated. use withPlural instead. - */ + + /** Method is deprecated. use withPlural instead. */ @java.lang.Deprecated public A withNewPlural(java.lang.String original) { - return (A)withPlural(new String(original)); + return (A) withPlural(new String(original)); } - public A addToShortNames(java.lang.Integer index,java.lang.String item) { - if (this.shortNames == null) {this.shortNames = new java.util.ArrayList();} + + public A addToShortNames(java.lang.Integer index, java.lang.String item) { + if (this.shortNames == null) { + this.shortNames = new java.util.ArrayList(); + } this.shortNames.add(index, item); - return (A)this; + return (A) this; } - public A setToShortNames(java.lang.Integer index,java.lang.String item) { - if (this.shortNames == null) {this.shortNames = new java.util.ArrayList();} - this.shortNames.set(index, item); return (A)this; + + public A setToShortNames(java.lang.Integer index, java.lang.String item) { + if (this.shortNames == null) { + this.shortNames = new java.util.ArrayList(); + } + this.shortNames.set(index, item); + return (A) this; } + public A addToShortNames(java.lang.String... items) { - if (this.shortNames == null) {this.shortNames = new java.util.ArrayList();} - for (java.lang.String item : items) {this.shortNames.add(item);} return (A)this; + if (this.shortNames == null) { + this.shortNames = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.shortNames.add(item); + } + return (A) this; } + public A addAllToShortNames(java.util.Collection items) { - if (this.shortNames == null) {this.shortNames = new java.util.ArrayList();} - for (java.lang.String item : items) {this.shortNames.add(item);} return (A)this; + if (this.shortNames == null) { + this.shortNames = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.shortNames.add(item); + } + return (A) this; } + public A removeFromShortNames(java.lang.String... items) { - for (java.lang.String item : items) {if (this.shortNames!= null){ this.shortNames.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.shortNames != null) { + this.shortNames.remove(item); + } + } + return (A) this; } + public A removeAllFromShortNames(java.util.Collection items) { - for (java.lang.String item : items) {if (this.shortNames!= null){ this.shortNames.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.shortNames != null) { + this.shortNames.remove(item); + } + } + return (A) this; } + public java.util.List getShortNames() { return this.shortNames; } + public java.lang.String getShortName(java.lang.Integer index) { return this.shortNames.get(index); } + public java.lang.String getFirstShortName() { return this.shortNames.get(0); } + public java.lang.String getLastShortName() { return this.shortNames.get(shortNames.size() - 1); } - public java.lang.String getMatchingShortName(java.util.function.Predicate predicate) { - for (java.lang.String item: shortNames) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingShortName( + java.util.function.Predicate predicate) { + for (java.lang.String item : shortNames) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingShortName(java.util.function.Predicate predicate) { - for (java.lang.String item: shortNames) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingShortName( + java.util.function.Predicate predicate) { + for (java.lang.String item : shortNames) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withShortNames(java.util.List shortNames) { - if (shortNames != null) {this.shortNames = new java.util.ArrayList(); for (java.lang.String item : shortNames){this.addToShortNames(item);}} else { this.shortNames = null;} return (A) this; + if (shortNames != null) { + this.shortNames = new java.util.ArrayList(); + for (java.lang.String item : shortNames) { + this.addToShortNames(item); + } + } else { + this.shortNames = null; + } + return (A) this; } + public A withShortNames(java.lang.String... shortNames) { - if (this.shortNames != null) {this.shortNames.clear();} - if (shortNames != null) {for (java.lang.String item :shortNames){ this.addToShortNames(item);}} return (A) this; + if (this.shortNames != null) { + this.shortNames.clear(); + } + if (shortNames != null) { + for (java.lang.String item : shortNames) { + this.addToShortNames(item); + } + } + return (A) this; } + public java.lang.Boolean hasShortNames() { return shortNames != null && !shortNames.isEmpty(); } + public A addNewShortName(java.lang.String original) { - return (A)addToShortNames(new String(original)); + return (A) addToShortNames(new String(original)); } + public java.lang.String getSingular() { return this.singular; } + public A withSingular(java.lang.String singular) { - this.singular=singular; return (A) this; + this.singular = singular; + return (A) this; } + public java.lang.Boolean hasSingular() { return this.singular != null; } - - /** - * Method is deprecated. use withSingular instead. - */ + + /** Method is deprecated. use withSingular instead. */ @java.lang.Deprecated public A withNewSingular(java.lang.String original) { - return (A)withSingular(new String(original)); + return (A) withSingular(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CustomResourceDefinitionNamesFluentImpl that = (V1CustomResourceDefinitionNamesFluentImpl) o; - if (categories != null ? !categories.equals(that.categories) :that.categories != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (listKind != null ? !listKind.equals(that.listKind) :that.listKind != null) return false; - if (plural != null ? !plural.equals(that.plural) :that.plural != null) return false; - if (shortNames != null ? !shortNames.equals(that.shortNames) :that.shortNames != null) return false; - if (singular != null ? !singular.equals(that.singular) :that.singular != null) return false; + if (categories != null ? !categories.equals(that.categories) : that.categories != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (listKind != null ? !listKind.equals(that.listKind) : that.listKind != null) return false; + if (plural != null ? !plural.equals(that.plural) : that.plural != null) return false; + if (shortNames != null ? !shortNames.equals(that.shortNames) : that.shortNames != null) + return false; + if (singular != null ? !singular.equals(that.singular) : that.singular != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(categories, kind, listKind, plural, shortNames, singular, super.hashCode()); + return java.util.Objects.hash( + categories, kind, listKind, plural, shortNames, singular, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionSpecBuilder.java index 490323fd9b..7fe3c3bc8b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CustomResourceDefinitionSpecBuilder extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CustomResourceDefinitionSpecBuilder + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecBuilder> { public V1CustomResourceDefinitionSpecBuilder() { this(false); } + public V1CustomResourceDefinitionSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1CustomResourceDefinitionSpec(), validationEnabled); } - public V1CustomResourceDefinitionSpecBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent fluent) { + + public V1CustomResourceDefinitionSpecBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent fluent) { this(fluent, false); } - public V1CustomResourceDefinitionSpecBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CustomResourceDefinitionSpecBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CustomResourceDefinitionSpec(), validationEnabled); } - public V1CustomResourceDefinitionSpecBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec instance) { + + public V1CustomResourceDefinitionSpecBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec instance) { this(fluent, instance, false); } - public V1CustomResourceDefinitionSpecBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CustomResourceDefinitionSpecBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConversion(instance.getConversion()); fluent.withGroup(instance.getGroup()); @@ -33,13 +60,18 @@ public V1CustomResourceDefinitionSpecBuilder(io.kubernetes.client.openapi.models fluent.withVersions(instance.getVersions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CustomResourceDefinitionSpecBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec instance) { - this(instance,false); + + public V1CustomResourceDefinitionSpecBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec instance) { + this(instance, false); } - public V1CustomResourceDefinitionSpecBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CustomResourceDefinitionSpecBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConversion(instance.getConversion()); this.withGroup(instance.getGroup()); @@ -52,10 +84,12 @@ public V1CustomResourceDefinitionSpecBuilder(io.kubernetes.client.openapi.models this.withVersions(instance.getVersions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec build() { V1CustomResourceDefinitionSpec buildable = new V1CustomResourceDefinitionSpec(); buildable.setConversion(fluent.getConversion()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec build( buildable.setVersions(fluent.getVersions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CustomResourceDefinitionSpecBuilder that = (V1CustomResourceDefinitionSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionSpecFluent.java index 91bf823589..14183a4c78 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionSpecFluent.java @@ -1,118 +1,232 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1CustomResourceDefinitionSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1CustomResourceDefinitionSpecFluent< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildConversion instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceConversion getConversion(); + public io.kubernetes.client.openapi.models.V1CustomResourceConversion buildConversion(); - public A withConversion(io.kubernetes.client.openapi.models.V1CustomResourceConversion conversion); + + public A withConversion( + io.kubernetes.client.openapi.models.V1CustomResourceConversion conversion); + public java.lang.Boolean hasConversion(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested withNewConversion(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested withNewConversionLike(io.kubernetes.client.openapi.models.V1CustomResourceConversion item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested editConversion(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested editOrNewConversion(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested editOrNewConversionLike(io.kubernetes.client.openapi.models.V1CustomResourceConversion item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested< + A> + withNewConversion(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested< + A> + withNewConversionLike(io.kubernetes.client.openapi.models.V1CustomResourceConversion item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested< + A> + editConversion(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested< + A> + editOrNewConversion(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested< + A> + editOrNewConversionLike(io.kubernetes.client.openapi.models.V1CustomResourceConversion item); + public java.lang.String getGroup(); + public A withGroup(java.lang.String group); + public java.lang.Boolean hasGroup(); - - /** - * Method is deprecated. use withGroup instead. - */ + + /** Method is deprecated. use withGroup instead. */ @java.lang.Deprecated public A withNewGroup(java.lang.String original); - + /** * This method has been deprecated, please use method buildNames instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames getNames(); + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames buildNames(); + public A withNames(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames names); + public java.lang.Boolean hasNames(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested withNewNames(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested withNewNamesLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested editNames(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested editOrNewNames(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested editOrNewNamesLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested + withNewNames(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested + withNewNamesLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested + editNames(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested + editOrNewNames(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested + editOrNewNamesLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item); + public java.lang.Boolean getPreserveUnknownFields(); + public A withPreserveUnknownFields(java.lang.Boolean preserveUnknownFields); + public java.lang.Boolean hasPreserveUnknownFields(); + public java.lang.String getScope(); + public A withScope(java.lang.String scope); + public java.lang.Boolean hasScope(); - - /** - * Method is deprecated. use withScope instead. - */ + + /** Method is deprecated. use withScope instead. */ @java.lang.Deprecated public A withNewScope(java.lang.String original); - public A addToVersions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item); - public A setToVersions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item); - public A addToVersions(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion... items); - public A addAllToVersions(java.util.Collection items); - public A removeFromVersions(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion... items); - public A removeAllFromVersions(java.util.Collection items); - public A removeMatchingFromVersions(java.util.function.Predicate predicate); - + + public A addToVersions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item); + + public A setToVersions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item); + + public A addToVersions( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion... items); + + public A addAllToVersions( + java.util.Collection + items); + + public A removeFromVersions( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion... items); + + public A removeAllFromVersions( + java.util.Collection + items); + + public A removeMatchingFromVersions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder> + predicate); + /** * This method has been deprecated, please use method buildVersions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getVersions(); - public java.util.List buildVersions(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion buildVersion(java.lang.Integer index); + public java.util.List + getVersions(); + + public java.util.List + buildVersions(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion buildVersion( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion buildFirstVersion(); + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion buildLastVersion(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion buildMatchingVersion(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVersion(java.util.function.Predicate predicate); - public A withVersions(java.util.List versions); - public A withVersions(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion... versions); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion buildMatchingVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder> + predicate); + + public java.lang.Boolean hasMatchingVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder> + predicate); + + public A withVersions( + java.util.List + versions); + + public A withVersions( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion... versions); + public java.lang.Boolean hasVersions(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested addNewVersion(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested addNewVersionLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested setNewVersionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested editVersion(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested editFirstVersion(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested editLastVersion(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested editMatchingVersion(java.util.function.Predicate predicate); - public interface ConversionNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent>{ + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + addNewVersion(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + addNewVersionLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + setNewVersionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + editVersion(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + editFirstVersion(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + editLastVersion(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + editMatchingVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder> + predicate); + + public interface ConversionNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CustomResourceConversionFluent< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent + .ConversionNested< + N>> { public N and(); + public N endConversion(); - } - public interface NamesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent>{ + + public interface NamesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested< + N>> { public N and(); + public N endNames(); - } - public interface VersionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent>{ + + public interface VersionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent + .VersionsNested< + N>> { public N and(); + public N endVersion(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionSpecFluentImpl.java index 54fd6febdd..f1ca143b87 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionSpecFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1CustomResourceDefinitionSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent{ - public V1CustomResourceDefinitionSpecFluentImpl() { - } - public V1CustomResourceDefinitionSpecFluentImpl(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec instance) { + +/** Generated */ +public class V1CustomResourceDefinitionSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent { + public V1CustomResourceDefinitionSpecFluentImpl() {} + + public V1CustomResourceDefinitionSpecFluentImpl( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpec instance) { this.withConversion(instance.getConversion()); this.withGroup(instance.getGroup()); @@ -32,296 +35,569 @@ public V1CustomResourceDefinitionSpecFluentImpl(io.kubernetes.client.openapi.mod this.withScope(instance.getScope()); this.withVersions(instance.getVersions()); - } + private io.kubernetes.client.openapi.models.V1CustomResourceConversionBuilder conversion; private java.lang.String group; private io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder names; private java.lang.Boolean preserveUnknownFields; private java.lang.String scope; - private java.util.ArrayList versions; - + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder> + versions; + /** * This method has been deprecated, please use method buildConversion instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceConversion getConversion() { - return this.conversion!=null ?this.conversion.build():null; + return this.conversion != null ? this.conversion.build() : null; } + public io.kubernetes.client.openapi.models.V1CustomResourceConversion buildConversion() { - return this.conversion!=null ?this.conversion.build():null; + return this.conversion != null ? this.conversion.build() : null; } - public A withConversion(io.kubernetes.client.openapi.models.V1CustomResourceConversion conversion) { + + public A withConversion( + io.kubernetes.client.openapi.models.V1CustomResourceConversion conversion) { _visitables.get("conversion").remove(this.conversion); - if (conversion!=null){ this.conversion= new io.kubernetes.client.openapi.models.V1CustomResourceConversionBuilder(conversion); _visitables.get("conversion").add(this.conversion);} return (A) this; + if (conversion != null) { + this.conversion = + new io.kubernetes.client.openapi.models.V1CustomResourceConversionBuilder(conversion); + _visitables.get("conversion").add(this.conversion); + } + return (A) this; } + public java.lang.Boolean hasConversion() { return this.conversion != null; } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested withNewConversion() { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl.ConversionNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested< + A> + withNewConversion() { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl + .ConversionNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested withNewConversionLike(io.kubernetes.client.openapi.models.V1CustomResourceConversion item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl.ConversionNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested< + A> + withNewConversionLike(io.kubernetes.client.openapi.models.V1CustomResourceConversion item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl + .ConversionNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested editConversion() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested< + A> + editConversion() { return withNewConversionLike(getConversion()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested editOrNewConversion() { - return withNewConversionLike(getConversion() != null ? getConversion(): new io.kubernetes.client.openapi.models.V1CustomResourceConversionBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested< + A> + editOrNewConversion() { + return withNewConversionLike( + getConversion() != null + ? getConversion() + : new io.kubernetes.client.openapi.models.V1CustomResourceConversionBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested editOrNewConversionLike(io.kubernetes.client.openapi.models.V1CustomResourceConversion item) { - return withNewConversionLike(getConversion() != null ? getConversion(): item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested< + A> + editOrNewConversionLike(io.kubernetes.client.openapi.models.V1CustomResourceConversion item) { + return withNewConversionLike(getConversion() != null ? getConversion() : item); } + public java.lang.String getGroup() { return this.group; } + public A withGroup(java.lang.String group) { - this.group=group; return (A) this; + this.group = group; + return (A) this; } + public java.lang.Boolean hasGroup() { return this.group != null; } - - /** - * Method is deprecated. use withGroup instead. - */ + + /** Method is deprecated. use withGroup instead. */ @java.lang.Deprecated public A withNewGroup(java.lang.String original) { - return (A)withGroup(new String(original)); + return (A) withGroup(new String(original)); } - + /** * This method has been deprecated, please use method buildNames instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames getNames() { - return this.names!=null ?this.names.build():null; + return this.names != null ? this.names.build() : null; } + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames buildNames() { - return this.names!=null ?this.names.build():null; + return this.names != null ? this.names.build() : null; } + public A withNames(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames names) { _visitables.get("names").remove(this.names); - if (names!=null){ this.names= new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder(names); _visitables.get("names").add(this.names);} return (A) this; + if (names != null) { + this.names = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder(names); + _visitables.get("names").add(this.names); + } + return (A) this; } + public java.lang.Boolean hasNames() { return this.names != null; } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested withNewNames() { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl.NamesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested + withNewNames() { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl + .NamesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested withNewNamesLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl.NamesNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested + withNewNamesLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl + .NamesNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested editNames() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested + editNames() { return withNewNamesLike(getNames()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested editOrNewNames() { - return withNewNamesLike(getNames() != null ? getNames(): new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested + editOrNewNames() { + return withNewNamesLike( + getNames() != null + ? getNames() + : new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested editOrNewNamesLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item) { - return withNewNamesLike(getNames() != null ? getNames(): item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested + editOrNewNamesLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item) { + return withNewNamesLike(getNames() != null ? getNames() : item); } + public java.lang.Boolean getPreserveUnknownFields() { return this.preserveUnknownFields; } + public A withPreserveUnknownFields(java.lang.Boolean preserveUnknownFields) { - this.preserveUnknownFields=preserveUnknownFields; return (A) this; + this.preserveUnknownFields = preserveUnknownFields; + return (A) this; } + public java.lang.Boolean hasPreserveUnknownFields() { return this.preserveUnknownFields != null; } + public java.lang.String getScope() { return this.scope; } + public A withScope(java.lang.String scope) { - this.scope=scope; return (A) this; + this.scope = scope; + return (A) this; } + public java.lang.Boolean hasScope() { return this.scope != null; } - - /** - * Method is deprecated. use withScope instead. - */ + + /** Method is deprecated. use withScope instead. */ @java.lang.Deprecated public A withNewScope(java.lang.String original) { - return (A)withScope(new String(original)); + return (A) withScope(new String(original)); } - public A addToVersions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item) { - if (this.versions == null) {this.versions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(item);_visitables.get("versions").add(index >= 0 ? index : _visitables.get("versions").size(), builder);this.versions.add(index >= 0 ? index : versions.size(), builder); return (A)this; + + public A addToVersions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item) { + if (this.versions == null) { + this.versions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder>(); + } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(item); + _visitables + .get("versions") + .add(index >= 0 ? index : _visitables.get("versions").size(), builder); + this.versions.add(index >= 0 ? index : versions.size(), builder); + return (A) this; } - public A setToVersions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item) { - if (this.versions == null) {this.versions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(item); - if (index < 0 || index >= _visitables.get("versions").size()) { _visitables.get("versions").add(builder); } else { _visitables.get("versions").set(index, builder);} - if (index < 0 || index >= versions.size()) { versions.add(builder); } else { versions.set(index, builder);} - return (A)this; + + public A setToVersions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item) { + if (this.versions == null) { + this.versions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder>(); + } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(item); + if (index < 0 || index >= _visitables.get("versions").size()) { + _visitables.get("versions").add(builder); + } else { + _visitables.get("versions").set(index, builder); + } + if (index < 0 || index >= versions.size()) { + versions.add(builder); + } else { + versions.set(index, builder); + } + return (A) this; } - public A addToVersions(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion... items) { - if (this.versions == null) {this.versions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item : items) {io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(item);_visitables.get("versions").add(builder);this.versions.add(builder);} return (A)this; + + public A addToVersions( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion... items) { + if (this.versions == null) { + this.versions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(item); + _visitables.get("versions").add(builder); + this.versions.add(builder); + } + return (A) this; } - public A addAllToVersions(java.util.Collection items) { - if (this.versions == null) {this.versions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item : items) {io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(item);_visitables.get("versions").add(builder);this.versions.add(builder);} return (A)this; + + public A addAllToVersions( + java.util.Collection + items) { + if (this.versions == null) { + this.versions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(item); + _visitables.get("versions").add(builder); + this.versions.add(builder); + } + return (A) this; } - public A removeFromVersions(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion... items) { - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item : items) {io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(item);_visitables.get("versions").remove(builder);if (this.versions != null) {this.versions.remove(builder);}} return (A)this; + + public A removeFromVersions( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion... items) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(item); + _visitables.get("versions").remove(builder); + if (this.versions != null) { + this.versions.remove(builder); + } + } + return (A) this; } - public A removeAllFromVersions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item : items) {io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(item);_visitables.get("versions").remove(builder);if (this.versions != null) {this.versions.remove(builder);}} return (A)this; + + public A removeAllFromVersions( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(item); + _visitables.get("versions").remove(builder); + if (this.versions != null) { + this.versions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromVersions(java.util.function.Predicate predicate) { + + public A removeMatchingFromVersions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder> + predicate) { if (versions == null) return (A) this; - final Iterator each = versions.iterator(); + final Iterator + each = versions.iterator(); final List visitables = _visitables.get("versions"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildVersions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getVersions() { + public java.util.List + getVersions() { return versions != null ? build(versions) : null; } - public java.util.List buildVersions() { + + public java.util.List + buildVersions() { return versions != null ? build(versions) : null; } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion buildVersion(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion buildVersion( + java.lang.Integer index) { return this.versions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion buildFirstVersion() { return this.versions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion buildLastVersion() { return this.versions.get(versions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion buildMatchingVersion(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder item: versions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion buildMatchingVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder item : + versions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingVersion(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder item: versions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder item : + versions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withVersions(java.util.List versions) { - if (this.versions != null) { _visitables.get("versions").removeAll(this.versions);} - if (versions != null) {this.versions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item : versions){this.addToVersions(item);}} else { this.versions = null;} return (A) this; + + public A withVersions( + java.util.List + versions) { + if (this.versions != null) { + _visitables.get("versions").removeAll(this.versions); + } + if (versions != null) { + this.versions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item : versions) { + this.addToVersions(item); + } + } else { + this.versions = null; + } + return (A) this; } - public A withVersions(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion... versions) { - if (this.versions != null) {this.versions.clear();} - if (versions != null) {for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item :versions){ this.addToVersions(item);}} return (A) this; + + public A withVersions( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion... versions) { + if (this.versions != null) { + this.versions.clear(); + } + if (versions != null) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item : versions) { + this.addToVersions(item); + } + } + return (A) this; } + public java.lang.Boolean hasVersions() { return versions != null && !versions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested addNewVersion() { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl.VersionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + addNewVersion() { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl + .VersionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested addNewVersionLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl.VersionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + addNewVersionLike( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl + .VersionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested setNewVersionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl.VersionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + setNewVersionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluentImpl + .VersionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested editVersion(java.lang.Integer index) { - if (versions.size() <= index) throw new RuntimeException("Can't edit versions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + editVersion(java.lang.Integer index) { + if (versions.size() <= index) + throw new RuntimeException("Can't edit versions. Index exceeds size."); return setNewVersionLike(index, buildVersion(index)); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested editFirstVersion() { - if (versions.size() == 0) throw new RuntimeException("Can't edit first versions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + editFirstVersion() { + if (versions.size() == 0) + throw new RuntimeException("Can't edit first versions. The list is empty."); return setNewVersionLike(0, buildVersion(0)); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested editLastVersion() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + editLastVersion() { int index = versions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last versions. The list is empty."); return setNewVersionLike(index, buildVersion(index)); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested editMatchingVersion(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested + editMatchingVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1CustomResourceConversionFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested,io.kubernetes.client.fluent.Nested{ + + public class ConversionNestedImpl + extends io.kubernetes.client.openapi.models.V1CustomResourceConversionFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.ConversionNested< + N>> + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent + .ConversionNested< + N>, + io.kubernetes.client.fluent.Nested { ConversionNestedImpl(io.kubernetes.client.openapi.models.V1CustomResourceConversion item) { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceConversionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceConversionBuilder(this, item); } + ConversionNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceConversionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceConversionBuilder(this); } + io.kubernetes.client.openapi.models.V1CustomResourceConversionBuilder builder; + public N and() { return (N) V1CustomResourceDefinitionSpecFluentImpl.this.withConversion(builder.build()); } + public N endConversion() { return and(); } - } - public class NamesNestedImpl extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested,io.kubernetes.client.fluent.Nested{ + + public class NamesNestedImpl + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.NamesNested> + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent + .NamesNested< + N>, + io.kubernetes.client.fluent.Nested { NamesNestedImpl(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item) { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder( + this, item); } + NamesNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder(this); } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder builder; + public N and() { return (N) V1CustomResourceDefinitionSpecFluentImpl.this.withNames(builder.build()); } + public N endNames() { return and(); } - } - public class VersionsNestedImpl extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested,io.kubernetes.client.fluent.Nested{ - VersionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item) { + + public class VersionsNestedImpl + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent.VersionsNested< + N>> + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionSpecFluent + .VersionsNested< + N>, + io.kubernetes.client.fluent.Nested { + VersionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder( + this, item); } + VersionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder(this); } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1CustomResourceDefinitionSpecFluentImpl.this.setToVersions(index,builder.build()); + return (N) + V1CustomResourceDefinitionSpecFluentImpl.this.setToVersions(index, builder.build()); } + public N endVersion() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionStatusBuilder.java index 5cd000806e..63309ce6e3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionStatusBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CustomResourceDefinitionStatusBuilder extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CustomResourceDefinitionStatusBuilder + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusBuilder> { public V1CustomResourceDefinitionStatusBuilder() { this(false); } + public V1CustomResourceDefinitionStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1CustomResourceDefinitionStatus(), validationEnabled); } - public V1CustomResourceDefinitionStatusBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent fluent) { + + public V1CustomResourceDefinitionStatusBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent fluent) { this(fluent, false); } - public V1CustomResourceDefinitionStatusBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CustomResourceDefinitionStatusBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CustomResourceDefinitionStatus(), validationEnabled); } - public V1CustomResourceDefinitionStatusBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus instance) { + + public V1CustomResourceDefinitionStatusBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus instance) { this(fluent, instance, false); } - public V1CustomResourceDefinitionStatusBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CustomResourceDefinitionStatusBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAcceptedNames(instance.getAcceptedNames()); fluent.withConditions(instance.getConditions()); fluent.withStoredVersions(instance.getStoredVersions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CustomResourceDefinitionStatusBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus instance) { - this(instance,false); + + public V1CustomResourceDefinitionStatusBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus instance) { + this(instance, false); } - public V1CustomResourceDefinitionStatusBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CustomResourceDefinitionStatusBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAcceptedNames(instance.getAcceptedNames()); this.withConditions(instance.getConditions()); this.withStoredVersions(instance.getStoredVersions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus build() { V1CustomResourceDefinitionStatus buildable = new V1CustomResourceDefinitionStatus(); buildable.setAcceptedNames(fluent.getAcceptedNames()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus buil buildable.setStoredVersions(fluent.getStoredVersions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CustomResourceDefinitionStatusBuilder that = (V1CustomResourceDefinitionStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionStatusFluent.java index 6a10b3555a..9ba0d33ab5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionStatusFluent.java @@ -1,93 +1,226 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CustomResourceDefinitionStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1CustomResourceDefinitionStatusFluent< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildAcceptedNames instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames getAcceptedNames(); + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames buildAcceptedNames(); - public A withAcceptedNames(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames acceptedNames); + + public A withAcceptedNames( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames acceptedNames); + public java.lang.Boolean hasAcceptedNames(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.AcceptedNamesNested withNewAcceptedNames(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.AcceptedNamesNested withNewAcceptedNamesLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.AcceptedNamesNested editAcceptedNames(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.AcceptedNamesNested editOrNewAcceptedNames(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.AcceptedNamesNested editOrNewAcceptedNamesLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item); - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item); - public A addToConditions(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition... items); - public A addAllToConditions(java.util.Collection items); - public A removeFromConditions(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .AcceptedNamesNested< + A> + withNewAcceptedNames(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .AcceptedNamesNested< + A> + withNewAcceptedNamesLike( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .AcceptedNamesNested< + A> + editAcceptedNames(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .AcceptedNamesNested< + A> + editOrNewAcceptedNames(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .AcceptedNamesNested< + A> + editOrNewAcceptedNamesLike( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item); + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item); + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item); + + public A addToConditions( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition... items); + + public A addAllToConditions( + java.util.Collection + items); + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition... items); + + public A removeAllFromConditions( + java.util.Collection + items); + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder> + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition buildCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition buildFirstCondition(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); - public A withConditions(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition... conditions); + public java.util.List + getConditions(); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition buildCondition( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition + buildFirstCondition(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition + buildLastCondition(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder> + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder> + predicate); + + public A withConditions( + java.util.List + conditions); + + public A withConditions( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - public A addToStoredVersions(java.lang.Integer index,java.lang.String item); - public A setToStoredVersions(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder> + predicate); + + public A addToStoredVersions(java.lang.Integer index, java.lang.String item); + + public A setToStoredVersions(java.lang.Integer index, java.lang.String item); + public A addToStoredVersions(java.lang.String... items); + public A addAllToStoredVersions(java.util.Collection items); + public A removeFromStoredVersions(java.lang.String... items); + public A removeAllFromStoredVersions(java.util.Collection items); + public java.util.List getStoredVersions(); + public java.lang.String getStoredVersion(java.lang.Integer index); + public java.lang.String getFirstStoredVersion(); + public java.lang.String getLastStoredVersion(); - public java.lang.String getMatchingStoredVersion(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingStoredVersion(java.util.function.Predicate predicate); + + public java.lang.String getMatchingStoredVersion( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingStoredVersion( + java.util.function.Predicate predicate); + public A withStoredVersions(java.util.List storedVersions); + public A withStoredVersions(java.lang.String... storedVersions); + public java.lang.Boolean hasStoredVersions(); + public A addNewStoredVersion(java.lang.String original); - public interface AcceptedNamesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent>{ + + public interface AcceptedNamesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluent< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .AcceptedNamesNested< + N>> { public N and(); + public N endAcceptedNames(); - } - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluent< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionStatusFluentImpl.java index dab2a4f300..a8299075e2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionStatusFluentImpl.java @@ -1,276 +1,608 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1CustomResourceDefinitionStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent{ - public V1CustomResourceDefinitionStatusFluentImpl() { - } - public V1CustomResourceDefinitionStatusFluentImpl(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus instance) { + +/** Generated */ +public class V1CustomResourceDefinitionStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent { + public V1CustomResourceDefinitionStatusFluentImpl() {} + + public V1CustomResourceDefinitionStatusFluentImpl( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatus instance) { this.withAcceptedNames(instance.getAcceptedNames()); this.withConditions(instance.getConditions()); this.withStoredVersions(instance.getStoredVersions()); - } + private io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder acceptedNames; - private java.util.ArrayList conditions; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder> + conditions; private java.util.List storedVersions; - + /** * This method has been deprecated, please use method buildAcceptedNames instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames getAcceptedNames() { - return this.acceptedNames!=null ?this.acceptedNames.build():null; + return this.acceptedNames != null ? this.acceptedNames.build() : null; } + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames buildAcceptedNames() { - return this.acceptedNames!=null ?this.acceptedNames.build():null; + return this.acceptedNames != null ? this.acceptedNames.build() : null; } - public A withAcceptedNames(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames acceptedNames) { + + public A withAcceptedNames( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames acceptedNames) { _visitables.get("acceptedNames").remove(this.acceptedNames); - if (acceptedNames!=null){ this.acceptedNames= new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder(acceptedNames); _visitables.get("acceptedNames").add(this.acceptedNames);} return (A) this; + if (acceptedNames != null) { + this.acceptedNames = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder( + acceptedNames); + _visitables.get("acceptedNames").add(this.acceptedNames); + } + return (A) this; } + public java.lang.Boolean hasAcceptedNames() { return this.acceptedNames != null; } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.AcceptedNamesNested withNewAcceptedNames() { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl.AcceptedNamesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .AcceptedNamesNested< + A> + withNewAcceptedNames() { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl + .AcceptedNamesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.AcceptedNamesNested withNewAcceptedNamesLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl.AcceptedNamesNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .AcceptedNamesNested< + A> + withNewAcceptedNamesLike( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl + .AcceptedNamesNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.AcceptedNamesNested editAcceptedNames() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .AcceptedNamesNested< + A> + editAcceptedNames() { return withNewAcceptedNamesLike(getAcceptedNames()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.AcceptedNamesNested editOrNewAcceptedNames() { - return withNewAcceptedNamesLike(getAcceptedNames() != null ? getAcceptedNames(): new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .AcceptedNamesNested< + A> + editOrNewAcceptedNames() { + return withNewAcceptedNamesLike( + getAcceptedNames() != null + ? getAcceptedNames() + : new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.AcceptedNamesNested editOrNewAcceptedNamesLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item) { - return withNewAcceptedNamesLike(getAcceptedNames() != null ? getAcceptedNames(): item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .AcceptedNamesNested< + A> + editOrNewAcceptedNamesLike( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item) { + return withNewAcceptedNamesLike(getAcceptedNames() != null ? getAcceptedNames() : item); } - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } - public A addToConditions(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item : items) {io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addToConditions( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition... items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item : items) {io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection + items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition... items) { - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item : items) {io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition... items) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item : items) {io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder> + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator + each = conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions() { + public java.util.List + getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition buildFirstCondition() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition + buildFirstCondition() { return this.conditions.get(0).build(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition buildLastCondition() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition + buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List + conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item : + conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } - public A withConditions(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item :conditions){ this.addToConditions(item);}} return (A) this; + + public A withConditions( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition... conditions) { + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item : + conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder> + predicate) { int index = -1; - for (int i=0;i();} + + public A addToStoredVersions(java.lang.Integer index, java.lang.String item) { + if (this.storedVersions == null) { + this.storedVersions = new java.util.ArrayList(); + } this.storedVersions.add(index, item); - return (A)this; + return (A) this; } - public A setToStoredVersions(java.lang.Integer index,java.lang.String item) { - if (this.storedVersions == null) {this.storedVersions = new java.util.ArrayList();} - this.storedVersions.set(index, item); return (A)this; + + public A setToStoredVersions(java.lang.Integer index, java.lang.String item) { + if (this.storedVersions == null) { + this.storedVersions = new java.util.ArrayList(); + } + this.storedVersions.set(index, item); + return (A) this; } + public A addToStoredVersions(java.lang.String... items) { - if (this.storedVersions == null) {this.storedVersions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.storedVersions.add(item);} return (A)this; + if (this.storedVersions == null) { + this.storedVersions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.storedVersions.add(item); + } + return (A) this; } + public A addAllToStoredVersions(java.util.Collection items) { - if (this.storedVersions == null) {this.storedVersions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.storedVersions.add(item);} return (A)this; + if (this.storedVersions == null) { + this.storedVersions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.storedVersions.add(item); + } + return (A) this; } + public A removeFromStoredVersions(java.lang.String... items) { - for (java.lang.String item : items) {if (this.storedVersions!= null){ this.storedVersions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.storedVersions != null) { + this.storedVersions.remove(item); + } + } + return (A) this; } + public A removeAllFromStoredVersions(java.util.Collection items) { - for (java.lang.String item : items) {if (this.storedVersions!= null){ this.storedVersions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.storedVersions != null) { + this.storedVersions.remove(item); + } + } + return (A) this; } + public java.util.List getStoredVersions() { return this.storedVersions; } + public java.lang.String getStoredVersion(java.lang.Integer index) { return this.storedVersions.get(index); } + public java.lang.String getFirstStoredVersion() { return this.storedVersions.get(0); } + public java.lang.String getLastStoredVersion() { return this.storedVersions.get(storedVersions.size() - 1); } - public java.lang.String getMatchingStoredVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: storedVersions) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingStoredVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : storedVersions) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingStoredVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: storedVersions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingStoredVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : storedVersions) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withStoredVersions(java.util.List storedVersions) { - if (storedVersions != null) {this.storedVersions = new java.util.ArrayList(); for (java.lang.String item : storedVersions){this.addToStoredVersions(item);}} else { this.storedVersions = null;} return (A) this; + if (storedVersions != null) { + this.storedVersions = new java.util.ArrayList(); + for (java.lang.String item : storedVersions) { + this.addToStoredVersions(item); + } + } else { + this.storedVersions = null; + } + return (A) this; } + public A withStoredVersions(java.lang.String... storedVersions) { - if (this.storedVersions != null) {this.storedVersions.clear();} - if (storedVersions != null) {for (java.lang.String item :storedVersions){ this.addToStoredVersions(item);}} return (A) this; + if (this.storedVersions != null) { + this.storedVersions.clear(); + } + if (storedVersions != null) { + for (java.lang.String item : storedVersions) { + this.addToStoredVersions(item); + } + } + return (A) this; } + public java.lang.Boolean hasStoredVersions() { return storedVersions != null && !storedVersions.isEmpty(); } + public A addNewStoredVersion(java.lang.String original) { - return (A)addToStoredVersions(new String(original)); + return (A) addToStoredVersions(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1CustomResourceDefinitionStatusFluentImpl that = (V1CustomResourceDefinitionStatusFluentImpl) o; - if (acceptedNames != null ? !acceptedNames.equals(that.acceptedNames) :that.acceptedNames != null) return false; - if (conditions != null ? !conditions.equals(that.conditions) :that.conditions != null) return false; - if (storedVersions != null ? !storedVersions.equals(that.storedVersions) :that.storedVersions != null) return false; + V1CustomResourceDefinitionStatusFluentImpl that = + (V1CustomResourceDefinitionStatusFluentImpl) o; + if (acceptedNames != null + ? !acceptedNames.equals(that.acceptedNames) + : that.acceptedNames != null) return false; + if (conditions != null ? !conditions.equals(that.conditions) : that.conditions != null) + return false; + if (storedVersions != null + ? !storedVersions.equals(that.storedVersions) + : that.storedVersions != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(acceptedNames, conditions, storedVersions, super.hashCode()); + return java.util.Objects.hash(acceptedNames, conditions, storedVersions, super.hashCode()); } - public class AcceptedNamesNestedImpl extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.AcceptedNamesNested,io.kubernetes.client.fluent.Nested{ - AcceptedNamesNestedImpl(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item) { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder(this, item); + + public class AcceptedNamesNestedImpl + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .AcceptedNamesNested< + N>> + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .AcceptedNamesNested< + N>, + io.kubernetes.client.fluent.Nested { + AcceptedNamesNestedImpl( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNames item) { + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder( + this, item); } + AcceptedNamesNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder(this); } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionNamesBuilder builder; + public N and() { return (N) V1CustomResourceDefinitionStatusFluentImpl.this.withAcceptedNames(builder.build()); } + public N endAcceptedNames() { return and(); } - } - public class ConditionsNestedImpl extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + N>> + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionStatusFluent + .ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder( + this, item); } + ConditionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1CustomResourceDefinitionStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) + V1CustomResourceDefinitionStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionVersionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionVersionBuilder.java index d39170a511..0ea41ee5ef 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionVersionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionVersionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CustomResourceDefinitionVersionBuilder extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CustomResourceDefinitionVersionBuilder + extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionBuilder> { public V1CustomResourceDefinitionVersionBuilder() { this(false); } + public V1CustomResourceDefinitionVersionBuilder(java.lang.Boolean validationEnabled) { this(new V1CustomResourceDefinitionVersion(), validationEnabled); } - public V1CustomResourceDefinitionVersionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent fluent) { + + public V1CustomResourceDefinitionVersionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent fluent) { this(fluent, false); } - public V1CustomResourceDefinitionVersionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CustomResourceDefinitionVersionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CustomResourceDefinitionVersion(), validationEnabled); } - public V1CustomResourceDefinitionVersionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion instance) { + + public V1CustomResourceDefinitionVersionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion instance) { this(fluent, instance, false); } - public V1CustomResourceDefinitionVersionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CustomResourceDefinitionVersionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAdditionalPrinterColumns(instance.getAdditionalPrinterColumns()); fluent.withDeprecated(instance.getDeprecated()); @@ -37,13 +64,18 @@ public V1CustomResourceDefinitionVersionBuilder(io.kubernetes.client.openapi.mod fluent.withSubresources(instance.getSubresources()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CustomResourceDefinitionVersionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion instance) { - this(instance,false); + + public V1CustomResourceDefinitionVersionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion instance) { + this(instance, false); } - public V1CustomResourceDefinitionVersionBuilder(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CustomResourceDefinitionVersionBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAdditionalPrinterColumns(instance.getAdditionalPrinterColumns()); this.withDeprecated(instance.getDeprecated()); @@ -60,10 +92,12 @@ public V1CustomResourceDefinitionVersionBuilder(io.kubernetes.client.openapi.mod this.withSubresources(instance.getSubresources()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion build() { V1CustomResourceDefinitionVersion buildable = new V1CustomResourceDefinitionVersion(); buildable.setAdditionalPrinterColumns(fluent.getAdditionalPrinterColumns()); @@ -76,18 +110,23 @@ public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion bui buildable.setSubresources(fluent.getSubresources()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CustomResourceDefinitionVersionBuilder that = (V1CustomResourceDefinitionVersionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionVersionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionVersionFluent.java index aa7064b4c3..570d1bc329 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionVersionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionVersionFluent.java @@ -1,124 +1,270 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1CustomResourceDefinitionVersionFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAdditionalPrinterColumns(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item); - public A setToAdditionalPrinterColumns(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item); - public A addToAdditionalPrinterColumns(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition... items); - public A addAllToAdditionalPrinterColumns(java.util.Collection items); - public A removeFromAdditionalPrinterColumns(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition... items); - public A removeAllFromAdditionalPrinterColumns(java.util.Collection items); - public A removeMatchingFromAdditionalPrinterColumns(java.util.function.Predicate predicate); - +/** Generated */ +public interface V1CustomResourceDefinitionVersionFluent< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAdditionalPrinterColumns( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item); + + public A setToAdditionalPrinterColumns( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item); + + public A addToAdditionalPrinterColumns( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition... items); + + public A addAllToAdditionalPrinterColumns( + java.util.Collection + items); + + public A removeFromAdditionalPrinterColumns( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition... items); + + public A removeAllFromAdditionalPrinterColumns( + java.util.Collection + items); + + public A removeMatchingFromAdditionalPrinterColumns( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder> + predicate); + /** * This method has been deprecated, please use method buildAdditionalPrinterColumns instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getAdditionalPrinterColumns(); - public java.util.List buildAdditionalPrinterColumns(); - public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition buildAdditionalPrinterColumn(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition buildFirstAdditionalPrinterColumn(); - public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition buildLastAdditionalPrinterColumn(); - public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition buildMatchingAdditionalPrinterColumn(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAdditionalPrinterColumn(java.util.function.Predicate predicate); - public A withAdditionalPrinterColumns(java.util.List additionalPrinterColumns); - public A withAdditionalPrinterColumns(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition... additionalPrinterColumns); + public java.util.List + getAdditionalPrinterColumns(); + + public java.util.List + buildAdditionalPrinterColumns(); + + public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition + buildAdditionalPrinterColumn(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition + buildFirstAdditionalPrinterColumn(); + + public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition + buildLastAdditionalPrinterColumn(); + + public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition + buildMatchingAdditionalPrinterColumn( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder> + predicate); + + public java.lang.Boolean hasMatchingAdditionalPrinterColumn( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder> + predicate); + + public A withAdditionalPrinterColumns( + java.util.List + additionalPrinterColumns); + + public A withAdditionalPrinterColumns( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition... + additionalPrinterColumns); + public java.lang.Boolean hasAdditionalPrinterColumns(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested addNewAdditionalPrinterColumn(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested addNewAdditionalPrinterColumnLike(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested setNewAdditionalPrinterColumnLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested editAdditionalPrinterColumn(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested editFirstAdditionalPrinterColumn(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested editLastAdditionalPrinterColumn(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested editMatchingAdditionalPrinterColumn(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + addNewAdditionalPrinterColumn(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + addNewAdditionalPrinterColumnLike( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + setNewAdditionalPrinterColumnLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + editAdditionalPrinterColumn(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + editFirstAdditionalPrinterColumn(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + editLastAdditionalPrinterColumn(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + editMatchingAdditionalPrinterColumn( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder> + predicate); + public java.lang.Boolean getDeprecated(); + public A withDeprecated(java.lang.Boolean deprecated); + public java.lang.Boolean hasDeprecated(); + public java.lang.String getDeprecationWarning(); + public A withDeprecationWarning(java.lang.String deprecationWarning); + public java.lang.Boolean hasDeprecationWarning(); - - /** - * Method is deprecated. use withDeprecationWarning instead. - */ + + /** Method is deprecated. use withDeprecationWarning instead. */ @java.lang.Deprecated public A withNewDeprecationWarning(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - + /** * This method has been deprecated, please use method buildSchema instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceValidation getSchema(); + public io.kubernetes.client.openapi.models.V1CustomResourceValidation buildSchema(); + public A withSchema(io.kubernetes.client.openapi.models.V1CustomResourceValidation schema); + public java.lang.Boolean hasSchema(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested withNewSchema(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested withNewSchemaLike(io.kubernetes.client.openapi.models.V1CustomResourceValidation item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested editSchema(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested editOrNewSchema(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested editOrNewSchemaLike(io.kubernetes.client.openapi.models.V1CustomResourceValidation item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested + withNewSchema(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested + withNewSchemaLike(io.kubernetes.client.openapi.models.V1CustomResourceValidation item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested + editSchema(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested + editOrNewSchema(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested + editOrNewSchemaLike(io.kubernetes.client.openapi.models.V1CustomResourceValidation item); + public java.lang.Boolean getServed(); + public A withServed(java.lang.Boolean served); + public java.lang.Boolean hasServed(); + public java.lang.Boolean getStorage(); + public A withStorage(java.lang.Boolean storage); + public java.lang.Boolean hasStorage(); - + /** * This method has been deprecated, please use method buildSubresources instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceSubresources getSubresources(); + public io.kubernetes.client.openapi.models.V1CustomResourceSubresources buildSubresources(); - public A withSubresources(io.kubernetes.client.openapi.models.V1CustomResourceSubresources subresources); + + public A withSubresources( + io.kubernetes.client.openapi.models.V1CustomResourceSubresources subresources); + public java.lang.Boolean hasSubresources(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SubresourcesNested withNewSubresources(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SubresourcesNested withNewSubresourcesLike(io.kubernetes.client.openapi.models.V1CustomResourceSubresources item); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SubresourcesNested editSubresources(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SubresourcesNested editOrNewSubresources(); - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SubresourcesNested editOrNewSubresourcesLike(io.kubernetes.client.openapi.models.V1CustomResourceSubresources item); - public interface AdditionalPrinterColumnsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent>{ + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SubresourcesNested< + A> + withNewSubresources(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SubresourcesNested< + A> + withNewSubresourcesLike( + io.kubernetes.client.openapi.models.V1CustomResourceSubresources item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SubresourcesNested< + A> + editSubresources(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SubresourcesNested< + A> + editOrNewSubresources(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SubresourcesNested< + A> + editOrNewSubresourcesLike( + io.kubernetes.client.openapi.models.V1CustomResourceSubresources item); + + public interface AdditionalPrinterColumnsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluent< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + N>> { public N and(); + public N endAdditionalPrinterColumn(); - } - public interface SchemaNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent>{ + + public interface SchemaNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SchemaNested< + N>> { public N and(); + public N endSchema(); - } - public interface SubresourcesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent>{ + + public interface SubresourcesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SubresourcesNested< + N>> { public N and(); + public N endSubresources(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionVersionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionVersionFluentImpl.java index d006650669..62931de6e2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionVersionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceDefinitionVersionFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1CustomResourceDefinitionVersionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent{ - public V1CustomResourceDefinitionVersionFluentImpl() { - } - public V1CustomResourceDefinitionVersionFluentImpl(io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion instance) { + +/** Generated */ +public class V1CustomResourceDefinitionVersionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent { + public V1CustomResourceDefinitionVersionFluentImpl() {} + + public V1CustomResourceDefinitionVersionFluentImpl( + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersion instance) { this.withAdditionalPrinterColumns(instance.getAdditionalPrinterColumns()); this.withDeprecated(instance.getDeprecated()); @@ -36,9 +39,11 @@ public V1CustomResourceDefinitionVersionFluentImpl(io.kubernetes.client.openapi. this.withStorage(instance.getStorage()); this.withSubresources(instance.getSubresources()); - } - private java.util.ArrayList additionalPrinterColumns; + + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder> + additionalPrinterColumns; private java.lang.Boolean deprecated; private java.lang.String deprecationWarning; private java.lang.String name; @@ -46,308 +51,632 @@ public V1CustomResourceDefinitionVersionFluentImpl(io.kubernetes.client.openapi. private java.lang.Boolean served; private java.lang.Boolean storage; private io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesBuilder subresources; - public A addToAdditionalPrinterColumns(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item) { - if (this.additionalPrinterColumns == null) {this.additionalPrinterColumns = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(item);_visitables.get("additionalPrinterColumns").add(index >= 0 ? index : _visitables.get("additionalPrinterColumns").size(), builder);this.additionalPrinterColumns.add(index >= 0 ? index : additionalPrinterColumns.size(), builder); return (A)this; + + public A addToAdditionalPrinterColumns( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item) { + if (this.additionalPrinterColumns == null) { + this.additionalPrinterColumns = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder>(); + } + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(item); + _visitables + .get("additionalPrinterColumns") + .add(index >= 0 ? index : _visitables.get("additionalPrinterColumns").size(), builder); + this.additionalPrinterColumns.add( + index >= 0 ? index : additionalPrinterColumns.size(), builder); + return (A) this; } - public A setToAdditionalPrinterColumns(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item) { - if (this.additionalPrinterColumns == null) {this.additionalPrinterColumns = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(item); - if (index < 0 || index >= _visitables.get("additionalPrinterColumns").size()) { _visitables.get("additionalPrinterColumns").add(builder); } else { _visitables.get("additionalPrinterColumns").set(index, builder);} - if (index < 0 || index >= additionalPrinterColumns.size()) { additionalPrinterColumns.add(builder); } else { additionalPrinterColumns.set(index, builder);} - return (A)this; + + public A setToAdditionalPrinterColumns( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item) { + if (this.additionalPrinterColumns == null) { + this.additionalPrinterColumns = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder>(); + } + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(item); + if (index < 0 || index >= _visitables.get("additionalPrinterColumns").size()) { + _visitables.get("additionalPrinterColumns").add(builder); + } else { + _visitables.get("additionalPrinterColumns").set(index, builder); + } + if (index < 0 || index >= additionalPrinterColumns.size()) { + additionalPrinterColumns.add(builder); + } else { + additionalPrinterColumns.set(index, builder); + } + return (A) this; } - public A addToAdditionalPrinterColumns(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition... items) { - if (this.additionalPrinterColumns == null) {this.additionalPrinterColumns = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item : items) {io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(item);_visitables.get("additionalPrinterColumns").add(builder);this.additionalPrinterColumns.add(builder);} return (A)this; + + public A addToAdditionalPrinterColumns( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition... items) { + if (this.additionalPrinterColumns == null) { + this.additionalPrinterColumns = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(item); + _visitables.get("additionalPrinterColumns").add(builder); + this.additionalPrinterColumns.add(builder); + } + return (A) this; } - public A addAllToAdditionalPrinterColumns(java.util.Collection items) { - if (this.additionalPrinterColumns == null) {this.additionalPrinterColumns = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item : items) {io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(item);_visitables.get("additionalPrinterColumns").add(builder);this.additionalPrinterColumns.add(builder);} return (A)this; + + public A addAllToAdditionalPrinterColumns( + java.util.Collection + items) { + if (this.additionalPrinterColumns == null) { + this.additionalPrinterColumns = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(item); + _visitables.get("additionalPrinterColumns").add(builder); + this.additionalPrinterColumns.add(builder); + } + return (A) this; } - public A removeFromAdditionalPrinterColumns(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition... items) { - for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item : items) {io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(item);_visitables.get("additionalPrinterColumns").remove(builder);if (this.additionalPrinterColumns != null) {this.additionalPrinterColumns.remove(builder);}} return (A)this; + + public A removeFromAdditionalPrinterColumns( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition... items) { + for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(item); + _visitables.get("additionalPrinterColumns").remove(builder); + if (this.additionalPrinterColumns != null) { + this.additionalPrinterColumns.remove(builder); + } + } + return (A) this; } - public A removeAllFromAdditionalPrinterColumns(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item : items) {io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(item);_visitables.get("additionalPrinterColumns").remove(builder);if (this.additionalPrinterColumns != null) {this.additionalPrinterColumns.remove(builder);}} return (A)this; + + public A removeAllFromAdditionalPrinterColumns( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item : items) { + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = + new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(item); + _visitables.get("additionalPrinterColumns").remove(builder); + if (this.additionalPrinterColumns != null) { + this.additionalPrinterColumns.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromAdditionalPrinterColumns(java.util.function.Predicate predicate) { + + public A removeMatchingFromAdditionalPrinterColumns( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder> + predicate) { if (additionalPrinterColumns == null) return (A) this; - final Iterator each = additionalPrinterColumns.iterator(); + final Iterator + each = additionalPrinterColumns.iterator(); final List visitables = _visitables.get("additionalPrinterColumns"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildAdditionalPrinterColumns instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getAdditionalPrinterColumns() { + public java.util.List + getAdditionalPrinterColumns() { return additionalPrinterColumns != null ? build(additionalPrinterColumns) : null; } - public java.util.List buildAdditionalPrinterColumns() { + + public java.util.List + buildAdditionalPrinterColumns() { return additionalPrinterColumns != null ? build(additionalPrinterColumns) : null; } - public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition buildAdditionalPrinterColumn(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition + buildAdditionalPrinterColumn(java.lang.Integer index) { return this.additionalPrinterColumns.get(index).build(); } - public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition buildFirstAdditionalPrinterColumn() { + + public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition + buildFirstAdditionalPrinterColumn() { return this.additionalPrinterColumns.get(0).build(); } - public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition buildLastAdditionalPrinterColumn() { + + public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition + buildLastAdditionalPrinterColumn() { return this.additionalPrinterColumns.get(additionalPrinterColumns.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition buildMatchingAdditionalPrinterColumn(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder item: additionalPrinterColumns) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition + buildMatchingAdditionalPrinterColumn( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder item : + additionalPrinterColumns) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingAdditionalPrinterColumn(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder item: additionalPrinterColumns) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAdditionalPrinterColumn( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder item : + additionalPrinterColumns) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withAdditionalPrinterColumns(java.util.List additionalPrinterColumns) { - if (this.additionalPrinterColumns != null) { _visitables.get("additionalPrinterColumns").removeAll(this.additionalPrinterColumns);} - if (additionalPrinterColumns != null) {this.additionalPrinterColumns = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item : additionalPrinterColumns){this.addToAdditionalPrinterColumns(item);}} else { this.additionalPrinterColumns = null;} return (A) this; + + public A withAdditionalPrinterColumns( + java.util.List + additionalPrinterColumns) { + if (this.additionalPrinterColumns != null) { + _visitables.get("additionalPrinterColumns").removeAll(this.additionalPrinterColumns); + } + if (additionalPrinterColumns != null) { + this.additionalPrinterColumns = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item : + additionalPrinterColumns) { + this.addToAdditionalPrinterColumns(item); + } + } else { + this.additionalPrinterColumns = null; + } + return (A) this; } - public A withAdditionalPrinterColumns(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition... additionalPrinterColumns) { - if (this.additionalPrinterColumns != null) {this.additionalPrinterColumns.clear();} - if (additionalPrinterColumns != null) {for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item :additionalPrinterColumns){ this.addToAdditionalPrinterColumns(item);}} return (A) this; + + public A withAdditionalPrinterColumns( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition... + additionalPrinterColumns) { + if (this.additionalPrinterColumns != null) { + this.additionalPrinterColumns.clear(); + } + if (additionalPrinterColumns != null) { + for (io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item : + additionalPrinterColumns) { + this.addToAdditionalPrinterColumns(item); + } + } + return (A) this; } + public java.lang.Boolean hasAdditionalPrinterColumns() { return additionalPrinterColumns != null && !additionalPrinterColumns.isEmpty(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested addNewAdditionalPrinterColumn() { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl.AdditionalPrinterColumnsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + addNewAdditionalPrinterColumn() { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl + .AdditionalPrinterColumnsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested addNewAdditionalPrinterColumnLike(io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl.AdditionalPrinterColumnsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + addNewAdditionalPrinterColumnLike( + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl + .AdditionalPrinterColumnsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested setNewAdditionalPrinterColumnLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl.AdditionalPrinterColumnsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + setNewAdditionalPrinterColumnLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl + .AdditionalPrinterColumnsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested editAdditionalPrinterColumn(java.lang.Integer index) { - if (additionalPrinterColumns.size() <= index) throw new RuntimeException("Can't edit additionalPrinterColumns. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + editAdditionalPrinterColumn(java.lang.Integer index) { + if (additionalPrinterColumns.size() <= index) + throw new RuntimeException("Can't edit additionalPrinterColumns. Index exceeds size."); return setNewAdditionalPrinterColumnLike(index, buildAdditionalPrinterColumn(index)); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested editFirstAdditionalPrinterColumn() { - if (additionalPrinterColumns.size() == 0) throw new RuntimeException("Can't edit first additionalPrinterColumns. The list is empty."); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + editFirstAdditionalPrinterColumn() { + if (additionalPrinterColumns.size() == 0) + throw new RuntimeException("Can't edit first additionalPrinterColumns. The list is empty."); return setNewAdditionalPrinterColumnLike(0, buildAdditionalPrinterColumn(0)); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested editLastAdditionalPrinterColumn() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + editLastAdditionalPrinterColumn() { int index = additionalPrinterColumns.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last additionalPrinterColumns. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last additionalPrinterColumns. The list is empty."); return setNewAdditionalPrinterColumnLike(index, buildAdditionalPrinterColumn(index)); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested editMatchingAdditionalPrinterColumn(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + A> + editMatchingAdditionalPrinterColumn( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder> + predicate) { int index = -1; - for (int i=0;i withNewSchema() { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl.SchemaNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested + withNewSchema() { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl + .SchemaNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested withNewSchemaLike(io.kubernetes.client.openapi.models.V1CustomResourceValidation item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl.SchemaNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested + withNewSchemaLike(io.kubernetes.client.openapi.models.V1CustomResourceValidation item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl + .SchemaNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested editSchema() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested + editSchema() { return withNewSchemaLike(getSchema()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested editOrNewSchema() { - return withNewSchemaLike(getSchema() != null ? getSchema(): new io.kubernetes.client.openapi.models.V1CustomResourceValidationBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested + editOrNewSchema() { + return withNewSchemaLike( + getSchema() != null + ? getSchema() + : new io.kubernetes.client.openapi.models.V1CustomResourceValidationBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested editOrNewSchemaLike(io.kubernetes.client.openapi.models.V1CustomResourceValidation item) { - return withNewSchemaLike(getSchema() != null ? getSchema(): item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested + editOrNewSchemaLike(io.kubernetes.client.openapi.models.V1CustomResourceValidation item) { + return withNewSchemaLike(getSchema() != null ? getSchema() : item); } + public java.lang.Boolean getServed() { return this.served; } + public A withServed(java.lang.Boolean served) { - this.served=served; return (A) this; + this.served = served; + return (A) this; } + public java.lang.Boolean hasServed() { return this.served != null; } + public java.lang.Boolean getStorage() { return this.storage; } + public A withStorage(java.lang.Boolean storage) { - this.storage=storage; return (A) this; + this.storage = storage; + return (A) this; } + public java.lang.Boolean hasStorage() { return this.storage != null; } - + /** * This method has been deprecated, please use method buildSubresources instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceSubresources getSubresources() { - return this.subresources!=null ?this.subresources.build():null; + return this.subresources != null ? this.subresources.build() : null; } + public io.kubernetes.client.openapi.models.V1CustomResourceSubresources buildSubresources() { - return this.subresources!=null ?this.subresources.build():null; + return this.subresources != null ? this.subresources.build() : null; } - public A withSubresources(io.kubernetes.client.openapi.models.V1CustomResourceSubresources subresources) { + + public A withSubresources( + io.kubernetes.client.openapi.models.V1CustomResourceSubresources subresources) { _visitables.get("subresources").remove(this.subresources); - if (subresources!=null){ this.subresources= new io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesBuilder(subresources); _visitables.get("subresources").add(this.subresources);} return (A) this; + if (subresources != null) { + this.subresources = + new io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesBuilder(subresources); + _visitables.get("subresources").add(this.subresources); + } + return (A) this; } + public java.lang.Boolean hasSubresources() { return this.subresources != null; } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SubresourcesNested withNewSubresources() { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl.SubresourcesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SubresourcesNested< + A> + withNewSubresources() { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl + .SubresourcesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SubresourcesNested withNewSubresourcesLike(io.kubernetes.client.openapi.models.V1CustomResourceSubresources item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl.SubresourcesNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SubresourcesNested< + A> + withNewSubresourcesLike( + io.kubernetes.client.openapi.models.V1CustomResourceSubresources item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluentImpl + .SubresourcesNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SubresourcesNested editSubresources() { + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SubresourcesNested< + A> + editSubresources() { return withNewSubresourcesLike(getSubresources()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SubresourcesNested editOrNewSubresources() { - return withNewSubresourcesLike(getSubresources() != null ? getSubresources(): new io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SubresourcesNested< + A> + editOrNewSubresources() { + return withNewSubresourcesLike( + getSubresources() != null + ? getSubresources() + : new io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SubresourcesNested editOrNewSubresourcesLike(io.kubernetes.client.openapi.models.V1CustomResourceSubresources item) { - return withNewSubresourcesLike(getSubresources() != null ? getSubresources(): item); + + public io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SubresourcesNested< + A> + editOrNewSubresourcesLike( + io.kubernetes.client.openapi.models.V1CustomResourceSubresources item) { + return withNewSubresourcesLike(getSubresources() != null ? getSubresources() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1CustomResourceDefinitionVersionFluentImpl that = (V1CustomResourceDefinitionVersionFluentImpl) o; - if (additionalPrinterColumns != null ? !additionalPrinterColumns.equals(that.additionalPrinterColumns) :that.additionalPrinterColumns != null) return false; - if (deprecated != null ? !deprecated.equals(that.deprecated) :that.deprecated != null) return false; - if (deprecationWarning != null ? !deprecationWarning.equals(that.deprecationWarning) :that.deprecationWarning != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (schema != null ? !schema.equals(that.schema) :that.schema != null) return false; - if (served != null ? !served.equals(that.served) :that.served != null) return false; - if (storage != null ? !storage.equals(that.storage) :that.storage != null) return false; - if (subresources != null ? !subresources.equals(that.subresources) :that.subresources != null) return false; + V1CustomResourceDefinitionVersionFluentImpl that = + (V1CustomResourceDefinitionVersionFluentImpl) o; + if (additionalPrinterColumns != null + ? !additionalPrinterColumns.equals(that.additionalPrinterColumns) + : that.additionalPrinterColumns != null) return false; + if (deprecated != null ? !deprecated.equals(that.deprecated) : that.deprecated != null) + return false; + if (deprecationWarning != null + ? !deprecationWarning.equals(that.deprecationWarning) + : that.deprecationWarning != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (schema != null ? !schema.equals(that.schema) : that.schema != null) return false; + if (served != null ? !served.equals(that.served) : that.served != null) return false; + if (storage != null ? !storage.equals(that.storage) : that.storage != null) return false; + if (subresources != null ? !subresources.equals(that.subresources) : that.subresources != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(additionalPrinterColumns, deprecated, deprecationWarning, name, schema, served, storage, subresources, super.hashCode()); + return java.util.Objects.hash( + additionalPrinterColumns, + deprecated, + deprecationWarning, + name, + schema, + served, + storage, + subresources, + super.hashCode()); } - public class AdditionalPrinterColumnsNestedImpl extends io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.AdditionalPrinterColumnsNested,io.kubernetes.client.fluent.Nested{ - AdditionalPrinterColumnsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item) { + + public class AdditionalPrinterColumnsNestedImpl + extends io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + N>> + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .AdditionalPrinterColumnsNested< + N>, + io.kubernetes.client.fluent.Nested { + AdditionalPrinterColumnsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder( + this, item); } + AdditionalPrinterColumnsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder(this); } + io.kubernetes.client.openapi.models.V1CustomResourceColumnDefinitionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1CustomResourceDefinitionVersionFluentImpl.this.setToAdditionalPrinterColumns(index,builder.build()); + return (N) + V1CustomResourceDefinitionVersionFluentImpl.this.setToAdditionalPrinterColumns( + index, builder.build()); } + public N endAdditionalPrinterColumn() { return and(); } - } - public class SchemaNestedImpl extends io.kubernetes.client.openapi.models.V1CustomResourceValidationFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested,io.kubernetes.client.fluent.Nested{ + + public class SchemaNestedImpl + extends io.kubernetes.client.openapi.models.V1CustomResourceValidationFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SchemaNested< + N>> + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SchemaNested< + N>, + io.kubernetes.client.fluent.Nested { SchemaNestedImpl(io.kubernetes.client.openapi.models.V1CustomResourceValidation item) { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceValidationBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceValidationBuilder(this, item); } + SchemaNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceValidationBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceValidationBuilder(this); } + io.kubernetes.client.openapi.models.V1CustomResourceValidationBuilder builder; + public N and() { return (N) V1CustomResourceDefinitionVersionFluentImpl.this.withSchema(builder.build()); } + public N endSchema() { return and(); } - } - public class SubresourcesNestedImpl extends io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent.SubresourcesNested,io.kubernetes.client.fluent.Nested{ + + public class SubresourcesNestedImpl + extends io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SubresourcesNested< + N>> + implements io.kubernetes.client.openapi.models.V1CustomResourceDefinitionVersionFluent + .SubresourcesNested< + N>, + io.kubernetes.client.fluent.Nested { SubresourcesNestedImpl(io.kubernetes.client.openapi.models.V1CustomResourceSubresources item) { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesBuilder(this, item); } + SubresourcesNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesBuilder(this); } + io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesBuilder builder; + public N and() { return (N) V1CustomResourceDefinitionVersionFluentImpl.this.withSubresources(builder.build()); } + public N endSubresources() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourceScaleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourceScaleBuilder.java index 4463bf9388..75734ea943 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourceScaleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourceScaleBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CustomResourceSubresourceScaleBuilder extends io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CustomResourceSubresourceScaleBuilder + extends io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale, + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleBuilder> { public V1CustomResourceSubresourceScaleBuilder() { this(false); } + public V1CustomResourceSubresourceScaleBuilder(java.lang.Boolean validationEnabled) { this(new V1CustomResourceSubresourceScale(), validationEnabled); } - public V1CustomResourceSubresourceScaleBuilder(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent fluent) { + + public V1CustomResourceSubresourceScaleBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent fluent) { this(fluent, false); } - public V1CustomResourceSubresourceScaleBuilder(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CustomResourceSubresourceScaleBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CustomResourceSubresourceScale(), validationEnabled); } - public V1CustomResourceSubresourceScaleBuilder(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale instance) { + + public V1CustomResourceSubresourceScaleBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale instance) { this(fluent, instance, false); } - public V1CustomResourceSubresourceScaleBuilder(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CustomResourceSubresourceScaleBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLabelSelectorPath(instance.getLabelSelectorPath()); fluent.withSpecReplicasPath(instance.getSpecReplicasPath()); fluent.withStatusReplicasPath(instance.getStatusReplicasPath()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CustomResourceSubresourceScaleBuilder(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale instance) { - this(instance,false); + + public V1CustomResourceSubresourceScaleBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale instance) { + this(instance, false); } - public V1CustomResourceSubresourceScaleBuilder(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CustomResourceSubresourceScaleBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLabelSelectorPath(instance.getLabelSelectorPath()); this.withSpecReplicasPath(instance.getSpecReplicasPath()); this.withStatusReplicasPath(instance.getStatusReplicasPath()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale build() { V1CustomResourceSubresourceScale buildable = new V1CustomResourceSubresourceScale(); buildable.setLabelSelectorPath(fluent.getLabelSelectorPath()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale buil buildable.setStatusReplicasPath(fluent.getStatusReplicasPath()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CustomResourceSubresourceScaleBuilder that = (V1CustomResourceSubresourceScaleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourceScaleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourceScaleFluent.java index 5a1142e1b8..301e4af45b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourceScaleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourceScaleFluent.java @@ -1,41 +1,48 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CustomResourceSubresourceScaleFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1CustomResourceSubresourceScaleFluent< + A extends io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getLabelSelectorPath(); + public A withLabelSelectorPath(java.lang.String labelSelectorPath); + public java.lang.Boolean hasLabelSelectorPath(); - - /** - * Method is deprecated. use withLabelSelectorPath instead. - */ + + /** Method is deprecated. use withLabelSelectorPath instead. */ @java.lang.Deprecated public A withNewLabelSelectorPath(java.lang.String original); + public java.lang.String getSpecReplicasPath(); + public A withSpecReplicasPath(java.lang.String specReplicasPath); + public java.lang.Boolean hasSpecReplicasPath(); - - /** - * Method is deprecated. use withSpecReplicasPath instead. - */ + + /** Method is deprecated. use withSpecReplicasPath instead. */ @java.lang.Deprecated public A withNewSpecReplicasPath(java.lang.String original); + public java.lang.String getStatusReplicasPath(); + public A withStatusReplicasPath(java.lang.String statusReplicasPath); + public java.lang.Boolean hasStatusReplicasPath(); - - /** - * Method is deprecated. use withStatusReplicasPath instead. - */ + + /** Method is deprecated. use withStatusReplicasPath instead. */ @java.lang.Deprecated public A withNewStatusReplicasPath(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourceScaleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourceScaleFluentImpl.java index 0d28172b5f..20382fdce6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourceScaleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourceScaleFluentImpl.java @@ -1,90 +1,113 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1CustomResourceSubresourceScaleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent{ - public V1CustomResourceSubresourceScaleFluentImpl() { - } - public V1CustomResourceSubresourceScaleFluentImpl(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale instance) { +/** Generated */ +public class V1CustomResourceSubresourceScaleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent { + public V1CustomResourceSubresourceScaleFluentImpl() {} + + public V1CustomResourceSubresourceScaleFluentImpl( + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale instance) { this.withLabelSelectorPath(instance.getLabelSelectorPath()); this.withSpecReplicasPath(instance.getSpecReplicasPath()); this.withStatusReplicasPath(instance.getStatusReplicasPath()); - } + private java.lang.String labelSelectorPath; private java.lang.String specReplicasPath; private java.lang.String statusReplicasPath; + public java.lang.String getLabelSelectorPath() { return this.labelSelectorPath; } + public A withLabelSelectorPath(java.lang.String labelSelectorPath) { - this.labelSelectorPath=labelSelectorPath; return (A) this; + this.labelSelectorPath = labelSelectorPath; + return (A) this; } + public java.lang.Boolean hasLabelSelectorPath() { return this.labelSelectorPath != null; } - - /** - * Method is deprecated. use withLabelSelectorPath instead. - */ + + /** Method is deprecated. use withLabelSelectorPath instead. */ @java.lang.Deprecated public A withNewLabelSelectorPath(java.lang.String original) { - return (A)withLabelSelectorPath(new String(original)); + return (A) withLabelSelectorPath(new String(original)); } + public java.lang.String getSpecReplicasPath() { return this.specReplicasPath; } + public A withSpecReplicasPath(java.lang.String specReplicasPath) { - this.specReplicasPath=specReplicasPath; return (A) this; + this.specReplicasPath = specReplicasPath; + return (A) this; } + public java.lang.Boolean hasSpecReplicasPath() { return this.specReplicasPath != null; } - - /** - * Method is deprecated. use withSpecReplicasPath instead. - */ + + /** Method is deprecated. use withSpecReplicasPath instead. */ @java.lang.Deprecated public A withNewSpecReplicasPath(java.lang.String original) { - return (A)withSpecReplicasPath(new String(original)); + return (A) withSpecReplicasPath(new String(original)); } + public java.lang.String getStatusReplicasPath() { return this.statusReplicasPath; } + public A withStatusReplicasPath(java.lang.String statusReplicasPath) { - this.statusReplicasPath=statusReplicasPath; return (A) this; + this.statusReplicasPath = statusReplicasPath; + return (A) this; } + public java.lang.Boolean hasStatusReplicasPath() { return this.statusReplicasPath != null; } - - /** - * Method is deprecated. use withStatusReplicasPath instead. - */ + + /** Method is deprecated. use withStatusReplicasPath instead. */ @java.lang.Deprecated public A withNewStatusReplicasPath(java.lang.String original) { - return (A)withStatusReplicasPath(new String(original)); + return (A) withStatusReplicasPath(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1CustomResourceSubresourceScaleFluentImpl that = (V1CustomResourceSubresourceScaleFluentImpl) o; - if (labelSelectorPath != null ? !labelSelectorPath.equals(that.labelSelectorPath) :that.labelSelectorPath != null) return false; - if (specReplicasPath != null ? !specReplicasPath.equals(that.specReplicasPath) :that.specReplicasPath != null) return false; - if (statusReplicasPath != null ? !statusReplicasPath.equals(that.statusReplicasPath) :that.statusReplicasPath != null) return false; + V1CustomResourceSubresourceScaleFluentImpl that = + (V1CustomResourceSubresourceScaleFluentImpl) o; + if (labelSelectorPath != null + ? !labelSelectorPath.equals(that.labelSelectorPath) + : that.labelSelectorPath != null) return false; + if (specReplicasPath != null + ? !specReplicasPath.equals(that.specReplicasPath) + : that.specReplicasPath != null) return false; + if (statusReplicasPath != null + ? !statusReplicasPath.equals(that.statusReplicasPath) + : that.statusReplicasPath != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(labelSelectorPath, specReplicasPath, statusReplicasPath, super.hashCode()); + return java.util.Objects.hash( + labelSelectorPath, specReplicasPath, statusReplicasPath, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourcesBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourcesBuilder.java index 2f6c8f3bd9..f70bf4f952 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourcesBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourcesBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CustomResourceSubresourcesBuilder extends io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CustomResourceSubresourcesBuilder + extends io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CustomResourceSubresources, + io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesBuilder> { public V1CustomResourceSubresourcesBuilder() { this(false); } + public V1CustomResourceSubresourcesBuilder(java.lang.Boolean validationEnabled) { this(new V1CustomResourceSubresources(), validationEnabled); } - public V1CustomResourceSubresourcesBuilder(io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent fluent) { + + public V1CustomResourceSubresourcesBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent fluent) { this(fluent, false); } - public V1CustomResourceSubresourcesBuilder(io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CustomResourceSubresourcesBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CustomResourceSubresources(), validationEnabled); } - public V1CustomResourceSubresourcesBuilder(io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceSubresources instance) { + + public V1CustomResourceSubresourcesBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceSubresources instance) { this(fluent, instance, false); } - public V1CustomResourceSubresourcesBuilder(io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceSubresources instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CustomResourceSubresourcesBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceSubresources instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withScale(instance.getScale()); fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CustomResourceSubresourcesBuilder(io.kubernetes.client.openapi.models.V1CustomResourceSubresources instance) { - this(instance,false); + + public V1CustomResourceSubresourcesBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceSubresources instance) { + this(instance, false); } - public V1CustomResourceSubresourcesBuilder(io.kubernetes.client.openapi.models.V1CustomResourceSubresources instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CustomResourceSubresourcesBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceSubresources instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withScale(instance.getScale()); this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CustomResourceSubresources build() { V1CustomResourceSubresources buildable = new V1CustomResourceSubresources(); buildable.setScale(fluent.getScale()); buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CustomResourceSubresourcesBuilder that = (V1CustomResourceSubresourcesBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourcesFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourcesFluent.java index 2540a414f5..a9a9ab020a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourcesFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourcesFluent.java @@ -1,39 +1,64 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CustomResourceSubresourcesFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1CustomResourceSubresourcesFluent< + A extends io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildScale instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale getScale(); + public io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale buildScale(); + public A withScale(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale scale); + public java.lang.Boolean hasScale(); - public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested withNewScale(); - public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested withNewScaleLike(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale item); - public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested editScale(); - public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested editOrNewScale(); - public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested editOrNewScaleLike(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale item); + + public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested + withNewScale(); + + public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested + withNewScaleLike(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale item); + + public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested + editScale(); + + public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested + editOrNewScale(); + + public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested + editOrNewScaleLike(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale item); + public java.lang.Object getStatus(); + public A withStatus(java.lang.Object status); + public java.lang.Boolean hasStatus(); - public interface ScaleNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent>{ + + public interface ScaleNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluent< + io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested< + N>> { public N and(); + public N endScale(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourcesFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourcesFluentImpl.java index 93a595a014..8a69926620 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourcesFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceSubresourcesFluentImpl.java @@ -1,94 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1CustomResourceSubresourcesFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent { + public V1CustomResourceSubresourcesFluentImpl() {} - /** - * Generated - */ -public class V1CustomResourceSubresourcesFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent{ - public V1CustomResourceSubresourcesFluentImpl() { - } - public V1CustomResourceSubresourcesFluentImpl(io.kubernetes.client.openapi.models.V1CustomResourceSubresources instance) { + public V1CustomResourceSubresourcesFluentImpl( + io.kubernetes.client.openapi.models.V1CustomResourceSubresources instance) { this.withScale(instance.getScale()); this.withStatus(instance.getStatus()); - } + private io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleBuilder scale; private java.lang.Object status; - + /** * This method has been deprecated, please use method buildScale instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale getScale() { - return this.scale!=null ?this.scale.build():null; + return this.scale != null ? this.scale.build() : null; } + public io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale buildScale() { - return this.scale!=null ?this.scale.build():null; + return this.scale != null ? this.scale.build() : null; } + public A withScale(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale scale) { _visitables.get("scale").remove(this.scale); - if (scale!=null){ this.scale= new io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleBuilder(scale); _visitables.get("scale").add(this.scale);} return (A) this; + if (scale != null) { + this.scale = + new io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleBuilder(scale); + _visitables.get("scale").add(this.scale); + } + return (A) this; } + public java.lang.Boolean hasScale() { return this.scale != null; } - public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested withNewScale() { - return new io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluentImpl.ScaleNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested + withNewScale() { + return new io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluentImpl + .ScaleNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested withNewScaleLike(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluentImpl.ScaleNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested + withNewScaleLike(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluentImpl + .ScaleNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested editScale() { + + public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested + editScale() { return withNewScaleLike(getScale()); } - public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested editOrNewScale() { - return withNewScaleLike(getScale() != null ? getScale(): new io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested + editOrNewScale() { + return withNewScaleLike( + getScale() != null + ? getScale() + : new io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested editOrNewScaleLike(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale item) { - return withNewScaleLike(getScale() != null ? getScale(): item); + + public io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested + editOrNewScaleLike( + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale item) { + return withNewScaleLike(getScale() != null ? getScale() : item); } + public java.lang.Object getStatus() { return this.status; } + public A withStatus(java.lang.Object status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CustomResourceSubresourcesFluentImpl that = (V1CustomResourceSubresourcesFluentImpl) o; - if (scale != null ? !scale.equals(that.scale) :that.scale != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (scale != null ? !scale.equals(that.scale) : that.scale != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(scale, status, super.hashCode()); + return java.util.Objects.hash(scale, status, super.hashCode()); } - public class ScaleNestedImpl extends io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested,io.kubernetes.client.fluent.Nested{ + + public class ScaleNestedImpl + extends io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested> + implements io.kubernetes.client.openapi.models.V1CustomResourceSubresourcesFluent.ScaleNested< + N>, + io.kubernetes.client.fluent.Nested { ScaleNestedImpl(io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScale item) { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleBuilder( + this, item); } + ScaleNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleBuilder(this); } + io.kubernetes.client.openapi.models.V1CustomResourceSubresourceScaleBuilder builder; + public N and() { return (N) V1CustomResourceSubresourcesFluentImpl.this.withScale(builder.build()); } + public N endScale() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceValidationBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceValidationBuilder.java index c896338ff7..22ca243a7e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceValidationBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceValidationBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1CustomResourceValidationBuilder extends io.kubernetes.client.openapi.models.V1CustomResourceValidationFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1CustomResourceValidationBuilder + extends io.kubernetes.client.openapi.models.V1CustomResourceValidationFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceValidationBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1CustomResourceValidation, + io.kubernetes.client.openapi.models.V1CustomResourceValidationBuilder> { public V1CustomResourceValidationBuilder() { this(false); } + public V1CustomResourceValidationBuilder(java.lang.Boolean validationEnabled) { this(new V1CustomResourceValidation(), validationEnabled); } - public V1CustomResourceValidationBuilder(io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent fluent) { + + public V1CustomResourceValidationBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent fluent) { this(fluent, false); } - public V1CustomResourceValidationBuilder(io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent fluent,java.lang.Boolean validationEnabled) { + + public V1CustomResourceValidationBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1CustomResourceValidation(), validationEnabled); } - public V1CustomResourceValidationBuilder(io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceValidation instance) { + + public V1CustomResourceValidationBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceValidation instance) { this(fluent, instance, false); } - public V1CustomResourceValidationBuilder(io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent fluent,io.kubernetes.client.openapi.models.V1CustomResourceValidation instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1CustomResourceValidationBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent fluent, + io.kubernetes.client.openapi.models.V1CustomResourceValidation instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withOpenAPIV3Schema(instance.getOpenAPIV3Schema()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1CustomResourceValidationBuilder(io.kubernetes.client.openapi.models.V1CustomResourceValidation instance) { - this(instance,false); + + public V1CustomResourceValidationBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceValidation instance) { + this(instance, false); } - public V1CustomResourceValidationBuilder(io.kubernetes.client.openapi.models.V1CustomResourceValidation instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1CustomResourceValidationBuilder( + io.kubernetes.client.openapi.models.V1CustomResourceValidation instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withOpenAPIV3Schema(instance.getOpenAPIV3Schema()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1CustomResourceValidation build() { V1CustomResourceValidation buildable = new V1CustomResourceValidation(); buildable.setOpenAPIV3Schema(fluent.getOpenAPIV3Schema()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1CustomResourceValidationBuilder that = (V1CustomResourceValidationBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceValidationFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceValidationFluent.java index 0867a5c4c4..e669c6d07d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceValidationFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceValidationFluent.java @@ -1,35 +1,65 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1CustomResourceValidationFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1CustomResourceValidationFluent< + A extends io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildOpenAPIV3Schema instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JSONSchemaProps getOpenAPIV3Schema(); + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildOpenAPIV3Schema(); - public A withOpenAPIV3Schema(io.kubernetes.client.openapi.models.V1JSONSchemaProps openAPIV3Schema); + + public A withOpenAPIV3Schema( + io.kubernetes.client.openapi.models.V1JSONSchemaProps openAPIV3Schema); + public java.lang.Boolean hasOpenAPIV3Schema(); - public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested withNewOpenAPIV3Schema(); - public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested withNewOpenAPIV3SchemaLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item); - public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested editOpenAPIV3Schema(); - public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested editOrNewOpenAPIV3Schema(); - public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested editOrNewOpenAPIV3SchemaLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item); - public interface OpenAPIV3SchemaNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent>{ + + public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested< + A> + withNewOpenAPIV3Schema(); + + public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested< + A> + withNewOpenAPIV3SchemaLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested< + A> + editOpenAPIV3Schema(); + + public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested< + A> + editOrNewOpenAPIV3Schema(); + + public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested< + A> + editOrNewOpenAPIV3SchemaLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public interface OpenAPIV3SchemaNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent< + io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent + .OpenAPIV3SchemaNested< + N>> { public N and(); + public N endOpenAPIV3Schema(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceValidationFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceValidationFluentImpl.java index 01acf2d730..9b4cd16bcb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceValidationFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1CustomResourceValidationFluentImpl.java @@ -1,81 +1,134 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1CustomResourceValidationFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent{ - public V1CustomResourceValidationFluentImpl() { - } - public V1CustomResourceValidationFluentImpl(io.kubernetes.client.openapi.models.V1CustomResourceValidation instance) { - this.withOpenAPIV3Schema(instance.getOpenAPIV3Schema()); +/** Generated */ +public class V1CustomResourceValidationFluentImpl< + A extends io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent { + public V1CustomResourceValidationFluentImpl() {} + public V1CustomResourceValidationFluentImpl( + io.kubernetes.client.openapi.models.V1CustomResourceValidation instance) { + this.withOpenAPIV3Schema(instance.getOpenAPIV3Schema()); } + private io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder openAPIV3Schema; - + /** * This method has been deprecated, please use method buildOpenAPIV3Schema instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JSONSchemaProps getOpenAPIV3Schema() { - return this.openAPIV3Schema!=null ?this.openAPIV3Schema.build():null; + return this.openAPIV3Schema != null ? this.openAPIV3Schema.build() : null; } + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildOpenAPIV3Schema() { - return this.openAPIV3Schema!=null ?this.openAPIV3Schema.build():null; + return this.openAPIV3Schema != null ? this.openAPIV3Schema.build() : null; } - public A withOpenAPIV3Schema(io.kubernetes.client.openapi.models.V1JSONSchemaProps openAPIV3Schema) { + + public A withOpenAPIV3Schema( + io.kubernetes.client.openapi.models.V1JSONSchemaProps openAPIV3Schema) { _visitables.get("openAPIV3Schema").remove(this.openAPIV3Schema); - if (openAPIV3Schema!=null){ this.openAPIV3Schema= new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(openAPIV3Schema); _visitables.get("openAPIV3Schema").add(this.openAPIV3Schema);} return (A) this; + if (openAPIV3Schema != null) { + this.openAPIV3Schema = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(openAPIV3Schema); + _visitables.get("openAPIV3Schema").add(this.openAPIV3Schema); + } + return (A) this; } + public java.lang.Boolean hasOpenAPIV3Schema() { return this.openAPIV3Schema != null; } - public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested withNewOpenAPIV3Schema() { - return new io.kubernetes.client.openapi.models.V1CustomResourceValidationFluentImpl.OpenAPIV3SchemaNestedImpl(); + + public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested< + A> + withNewOpenAPIV3Schema() { + return new io.kubernetes.client.openapi.models.V1CustomResourceValidationFluentImpl + .OpenAPIV3SchemaNestedImpl(); } - public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested withNewOpenAPIV3SchemaLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - return new io.kubernetes.client.openapi.models.V1CustomResourceValidationFluentImpl.OpenAPIV3SchemaNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested< + A> + withNewOpenAPIV3SchemaLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + return new io.kubernetes.client.openapi.models.V1CustomResourceValidationFluentImpl + .OpenAPIV3SchemaNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested editOpenAPIV3Schema() { + + public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested< + A> + editOpenAPIV3Schema() { return withNewOpenAPIV3SchemaLike(getOpenAPIV3Schema()); } - public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested editOrNewOpenAPIV3Schema() { - return withNewOpenAPIV3SchemaLike(getOpenAPIV3Schema() != null ? getOpenAPIV3Schema(): new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested< + A> + editOrNewOpenAPIV3Schema() { + return withNewOpenAPIV3SchemaLike( + getOpenAPIV3Schema() != null + ? getOpenAPIV3Schema() + : new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested editOrNewOpenAPIV3SchemaLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - return withNewOpenAPIV3SchemaLike(getOpenAPIV3Schema() != null ? getOpenAPIV3Schema(): item); + + public io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested< + A> + editOrNewOpenAPIV3SchemaLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + return withNewOpenAPIV3SchemaLike(getOpenAPIV3Schema() != null ? getOpenAPIV3Schema() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1CustomResourceValidationFluentImpl that = (V1CustomResourceValidationFluentImpl) o; - if (openAPIV3Schema != null ? !openAPIV3Schema.equals(that.openAPIV3Schema) :that.openAPIV3Schema != null) return false; + if (openAPIV3Schema != null + ? !openAPIV3Schema.equals(that.openAPIV3Schema) + : that.openAPIV3Schema != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(openAPIV3Schema, super.hashCode()); + return java.util.Objects.hash(openAPIV3Schema, super.hashCode()); } - public class OpenAPIV3SchemaNestedImpl extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl> implements io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent.OpenAPIV3SchemaNested,io.kubernetes.client.fluent.Nested{ + + public class OpenAPIV3SchemaNestedImpl + extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl< + io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent + .OpenAPIV3SchemaNested< + N>> + implements io.kubernetes.client.openapi.models.V1CustomResourceValidationFluent + .OpenAPIV3SchemaNested< + N>, + io.kubernetes.client.fluent.Nested { OpenAPIV3SchemaNestedImpl(io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { this.builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(this, item); } + OpenAPIV3SchemaNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(this); } + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder; + public N and() { return (N) V1CustomResourceValidationFluentImpl.this.withOpenAPIV3Schema(builder.build()); } + public N endOpenAPIV3Schema() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonEndpointBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonEndpointBuilder.java index 623079302d..781b28ab61 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonEndpointBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonEndpointBuilder.java @@ -1,58 +1,96 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DaemonEndpointBuilder extends io.kubernetes.client.openapi.models.V1DaemonEndpointFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DaemonEndpointBuilder + extends io.kubernetes.client.openapi.models.V1DaemonEndpointFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonEndpointBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DaemonEndpoint, + io.kubernetes.client.openapi.models.V1DaemonEndpointBuilder> { public V1DaemonEndpointBuilder() { this(false); } + public V1DaemonEndpointBuilder(java.lang.Boolean validationEnabled) { this(new V1DaemonEndpoint(), validationEnabled); } - public V1DaemonEndpointBuilder(io.kubernetes.client.openapi.models.V1DaemonEndpointFluent fluent) { + + public V1DaemonEndpointBuilder( + io.kubernetes.client.openapi.models.V1DaemonEndpointFluent fluent) { this(fluent, false); } - public V1DaemonEndpointBuilder(io.kubernetes.client.openapi.models.V1DaemonEndpointFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DaemonEndpointBuilder( + io.kubernetes.client.openapi.models.V1DaemonEndpointFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DaemonEndpoint(), validationEnabled); } - public V1DaemonEndpointBuilder(io.kubernetes.client.openapi.models.V1DaemonEndpointFluent fluent,io.kubernetes.client.openapi.models.V1DaemonEndpoint instance) { + + public V1DaemonEndpointBuilder( + io.kubernetes.client.openapi.models.V1DaemonEndpointFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonEndpoint instance) { this(fluent, instance, false); } - public V1DaemonEndpointBuilder(io.kubernetes.client.openapi.models.V1DaemonEndpointFluent fluent,io.kubernetes.client.openapi.models.V1DaemonEndpoint instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DaemonEndpointBuilder( + io.kubernetes.client.openapi.models.V1DaemonEndpointFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonEndpoint instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPort(instance.getPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1DaemonEndpointBuilder(io.kubernetes.client.openapi.models.V1DaemonEndpoint instance) { - this(instance,false); + this(instance, false); } - public V1DaemonEndpointBuilder(io.kubernetes.client.openapi.models.V1DaemonEndpoint instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DaemonEndpointBuilder( + io.kubernetes.client.openapi.models.V1DaemonEndpoint instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPort(instance.getPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DaemonEndpointFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DaemonEndpoint build() { V1DaemonEndpoint buildable = new V1DaemonEndpoint(); buildable.setPort(fluent.getPort()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DaemonEndpointBuilder that = (V1DaemonEndpointBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonEndpointFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonEndpointFluent.java index b7413b04b5..c558d7026a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonEndpointFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonEndpointFluent.java @@ -1,17 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DaemonEndpointFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1DaemonEndpointFluent< + A extends io.kubernetes.client.openapi.models.V1DaemonEndpointFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getPort(); + public A withPort(java.lang.Integer port); + public java.lang.Boolean hasPort(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonEndpointFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonEndpointFluentImpl.java index 2ca6791efe..bc6777ce6a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonEndpointFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonEndpointFluentImpl.java @@ -1,39 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1DaemonEndpointFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DaemonEndpointFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DaemonEndpointFluent { + public V1DaemonEndpointFluentImpl() {} - /** - * Generated - */ -public class V1DaemonEndpointFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DaemonEndpointFluent{ - public V1DaemonEndpointFluentImpl() { - } public V1DaemonEndpointFluentImpl(io.kubernetes.client.openapi.models.V1DaemonEndpoint instance) { this.withPort(instance.getPort()); - } + private java.lang.Integer port; + public java.lang.Integer getPort() { return this.port; } + public A withPort(java.lang.Integer port) { - this.port=port; return (A) this; + this.port = port; + return (A) this; } + public java.lang.Boolean hasPort() { return this.port != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1DaemonEndpointFluentImpl that = (V1DaemonEndpointFluentImpl) o; - if (port != null ? !port.equals(that.port) :that.port != null) return false; + if (port != null ? !port.equals(that.port) : that.port != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(port, super.hashCode()); + return java.util.Objects.hash(port, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetBuilder.java index ace3a8f0e6..707a624504 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DaemonSetBuilder extends io.kubernetes.client.openapi.models.V1DaemonSetFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DaemonSetBuilder + extends io.kubernetes.client.openapi.models.V1DaemonSetFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DaemonSet, + io.kubernetes.client.openapi.models.V1DaemonSetBuilder> { public V1DaemonSetBuilder() { this(false); } + public V1DaemonSetBuilder(java.lang.Boolean validationEnabled) { this(new V1DaemonSet(), validationEnabled); } + public V1DaemonSetBuilder(io.kubernetes.client.openapi.models.V1DaemonSetFluent fluent) { this(fluent, false); } - public V1DaemonSetBuilder(io.kubernetes.client.openapi.models.V1DaemonSetFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DaemonSetBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DaemonSet(), validationEnabled); } - public V1DaemonSetBuilder(io.kubernetes.client.openapi.models.V1DaemonSetFluent fluent,io.kubernetes.client.openapi.models.V1DaemonSet instance) { + + public V1DaemonSetBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonSet instance) { this(fluent, instance, false); } - public V1DaemonSetBuilder(io.kubernetes.client.openapi.models.V1DaemonSetFluent fluent,io.kubernetes.client.openapi.models.V1DaemonSet instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DaemonSetBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonSet instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,17 @@ public V1DaemonSetBuilder(io.kubernetes.client.openapi.models.V1DaemonSetFluent< fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1DaemonSetBuilder(io.kubernetes.client.openapi.models.V1DaemonSet instance) { - this(instance,false); + this(instance, false); } - public V1DaemonSetBuilder(io.kubernetes.client.openapi.models.V1DaemonSet instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DaemonSetBuilder( + io.kubernetes.client.openapi.models.V1DaemonSet instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +78,12 @@ public V1DaemonSetBuilder(io.kubernetes.client.openapi.models.V1DaemonSet instan this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DaemonSetFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DaemonSet build() { V1DaemonSet buildable = new V1DaemonSet(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +93,23 @@ public io.kubernetes.client.openapi.models.V1DaemonSet build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DaemonSetBuilder that = (V1DaemonSetBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetConditionBuilder.java index a87fadd91a..1b7cd901f2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DaemonSetConditionBuilder extends io.kubernetes.client.openapi.models.V1DaemonSetConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DaemonSetConditionBuilder + extends io.kubernetes.client.openapi.models.V1DaemonSetConditionFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DaemonSetCondition, + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder> { public V1DaemonSetConditionBuilder() { this(false); } + public V1DaemonSetConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1DaemonSetCondition(), validationEnabled); } - public V1DaemonSetConditionBuilder(io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent fluent) { + + public V1DaemonSetConditionBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent fluent) { this(fluent, false); } - public V1DaemonSetConditionBuilder(io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DaemonSetConditionBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DaemonSetCondition(), validationEnabled); } - public V1DaemonSetConditionBuilder(io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent fluent,io.kubernetes.client.openapi.models.V1DaemonSetCondition instance) { + + public V1DaemonSetConditionBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonSetCondition instance) { this(fluent, instance, false); } - public V1DaemonSetConditionBuilder(io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent fluent,io.kubernetes.client.openapi.models.V1DaemonSetCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DaemonSetConditionBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonSetCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +58,18 @@ public V1DaemonSetConditionBuilder(io.kubernetes.client.openapi.models.V1DaemonS fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1DaemonSetConditionBuilder(io.kubernetes.client.openapi.models.V1DaemonSetCondition instance) { - this(instance,false); + + public V1DaemonSetConditionBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetCondition instance) { + this(instance, false); } - public V1DaemonSetConditionBuilder(io.kubernetes.client.openapi.models.V1DaemonSetCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DaemonSetConditionBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,10 +80,12 @@ public V1DaemonSetConditionBuilder(io.kubernetes.client.openapi.models.V1DaemonS this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DaemonSetCondition build() { V1DaemonSetCondition buildable = new V1DaemonSetCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1DaemonSetCondition build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DaemonSetConditionBuilder that = (V1DaemonSetConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetConditionFluent.java index 8789a1c35e..57cbd72918 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetConditionFluent.java @@ -1,54 +1,64 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DaemonSetConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1DaemonSetConditionFluent< + A extends io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetConditionFluentImpl.java index cff57baa69..fae47deb15 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetConditionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1DaemonSetConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent { + public V1DaemonSetConditionFluentImpl() {} - /** - * Generated - */ -public class V1DaemonSetConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent{ - public V1DaemonSetConditionFluentImpl() { - } - public V1DaemonSetConditionFluentImpl(io.kubernetes.client.openapi.models.V1DaemonSetCondition instance) { + public V1DaemonSetConditionFluentImpl( + io.kubernetes.client.openapi.models.V1DaemonSetCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,103 +30,119 @@ public V1DaemonSetConditionFluentImpl(io.kubernetes.client.openapi.models.V1Daem this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1DaemonSetConditionFluentImpl that = (V1DaemonSetConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetFluent.java index d20b78f221..d9cb423349 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetFluent.java @@ -1,93 +1,144 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DaemonSetFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1DaemonSetFluent< + A extends io.kubernetes.client.openapi.models.V1DaemonSetFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DaemonSetSpec getSpec(); + public io.kubernetes.client.openapi.models.V1DaemonSetSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1DaemonSetSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1DaemonSetSpec item); + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1DaemonSetSpec item); + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1DaemonSetSpec item); - + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1DaemonSetSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DaemonSetStatus getStatus(); + public io.kubernetes.client.openapi.models.V1DaemonSetStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1DaemonSetStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1DaemonSetStatus item); + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1DaemonSetStatus item); + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1DaemonSetStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1DaemonSetStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent< + io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent< + io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetFluentImpl.java index 6045a9eec7..eed3e84972 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1DaemonSetFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DaemonSetFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DaemonSetFluent { + public V1DaemonSetFluentImpl() {} - /** - * Generated - */ -public class V1DaemonSetFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DaemonSetFluent{ - public V1DaemonSetFluentImpl() { - } public V1DaemonSetFluentImpl(io.kubernetes.client.openapi.models.V1DaemonSet instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +29,295 @@ public V1DaemonSetFluentImpl(io.kubernetes.client.openapi.models.V1DaemonSet ins this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1DaemonSetSpecBuilder spec; private io.kubernetes.client.openapi.models.V1DaemonSetStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1DaemonSetFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1DaemonSetFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DaemonSetSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1DaemonSetSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1DaemonSetSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1DaemonSetSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1DaemonSetSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1DaemonSetFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1DaemonSetSpec item) { + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1DaemonSetSpec item) { return new io.kubernetes.client.openapi.models.V1DaemonSetFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1DaemonSetSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1DaemonSetSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1DaemonSetSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1DaemonSetSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DaemonSetStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1DaemonSetStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1DaemonSetStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1DaemonSetStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1DaemonSetStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1DaemonSetFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1DaemonSetStatus item) { + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1DaemonSetStatus item) { return new io.kubernetes.client.openapi.models.V1DaemonSetFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1DaemonSetStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1DaemonSetStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1DaemonSetStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1DaemonSetStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1DaemonSetFluentImpl that = (V1DaemonSetFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1DaemonSetFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1DaemonSetFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1DaemonSetFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1DaemonSetSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1DaemonSetSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1DaemonSetSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1DaemonSetSpecBuilder builder; + public N and() { return (N) V1DaemonSetFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1DaemonSetStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1DaemonSetStatusFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1DaemonSetFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1DaemonSetStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1DaemonSetStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1DaemonSetStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1DaemonSetStatusBuilder builder; + public N and() { return (N) V1DaemonSetFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetListBuilder.java index 3302afc6eb..4624e2c265 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DaemonSetListBuilder extends io.kubernetes.client.openapi.models.V1DaemonSetListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DaemonSetListBuilder + extends io.kubernetes.client.openapi.models.V1DaemonSetListFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DaemonSetList, + io.kubernetes.client.openapi.models.V1DaemonSetListBuilder> { public V1DaemonSetListBuilder() { this(false); } + public V1DaemonSetListBuilder(java.lang.Boolean validationEnabled) { this(new V1DaemonSetList(), validationEnabled); } - public V1DaemonSetListBuilder(io.kubernetes.client.openapi.models.V1DaemonSetListFluent fluent) { + + public V1DaemonSetListBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetListFluent fluent) { this(fluent, false); } - public V1DaemonSetListBuilder(io.kubernetes.client.openapi.models.V1DaemonSetListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DaemonSetListBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DaemonSetList(), validationEnabled); } - public V1DaemonSetListBuilder(io.kubernetes.client.openapi.models.V1DaemonSetListFluent fluent,io.kubernetes.client.openapi.models.V1DaemonSetList instance) { + + public V1DaemonSetListBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetListFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonSetList instance) { this(fluent, instance, false); } - public V1DaemonSetListBuilder(io.kubernetes.client.openapi.models.V1DaemonSetListFluent fluent,io.kubernetes.client.openapi.models.V1DaemonSetList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DaemonSetListBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetListFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonSetList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1DaemonSetListBuilder(io.kubernetes.client.openapi.models.V1DaemonSetLis fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1DaemonSetListBuilder(io.kubernetes.client.openapi.models.V1DaemonSetList instance) { - this(instance,false); + this(instance, false); } - public V1DaemonSetListBuilder(io.kubernetes.client.openapi.models.V1DaemonSetList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DaemonSetListBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1DaemonSetListBuilder(io.kubernetes.client.openapi.models.V1DaemonSetLis this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DaemonSetListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DaemonSetList build() { V1DaemonSetList buildable = new V1DaemonSetList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1DaemonSetList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DaemonSetListBuilder that = (V1DaemonSetListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetListFluent.java index fa6cc29529..4573d7cd94 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetListFluent.java @@ -1,95 +1,153 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DaemonSetListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1DaemonSetListFluent< + A extends io.kubernetes.client.openapi.models.V1DaemonSetListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSet item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSet item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSet item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSet item); + public A addToItems(io.kubernetes.client.openapi.models.V1DaemonSet... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1DaemonSet... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1DaemonSet buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1DaemonSet buildFirstItem(); + public io.kubernetes.client.openapi.models.V1DaemonSet buildLastItem(); - public io.kubernetes.client.openapi.models.V1DaemonSet buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1DaemonSet buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1DaemonSet... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1DaemonSet item); - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSet item); - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1DaemonSet item); + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSet item); + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DaemonSetFluent>{ + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DaemonSetFluent< + io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetListFluentImpl.java index 03d07374c3..53d281d924 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1DaemonSetListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DaemonSetListFluent{ - public V1DaemonSetListFluentImpl() { - } +/** Generated */ +public class V1DaemonSetListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DaemonSetListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DaemonSetListFluent { + public V1DaemonSetListFluentImpl() {} + public V1DaemonSetListFluentImpl(io.kubernetes.client.openapi.models.V1DaemonSetList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,123 @@ public V1DaemonSetListFluentImpl(io.kubernetes.client.openapi.models.V1DaemonSet this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSet item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1DaemonSetBuilder builder = new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSet item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1DaemonSetBuilder builder = + new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSet item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1DaemonSetBuilder builder = new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSet item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1DaemonSetBuilder builder = + new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1DaemonSet... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1DaemonSet item : items) {io.kubernetes.client.openapi.models.V1DaemonSetBuilder builder = new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1DaemonSet item : items) { + io.kubernetes.client.openapi.models.V1DaemonSetBuilder builder = + new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1DaemonSet item : items) {io.kubernetes.client.openapi.models.V1DaemonSetBuilder builder = new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1DaemonSet item : items) { + io.kubernetes.client.openapi.models.V1DaemonSetBuilder builder = + new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1DaemonSet... items) { - for (io.kubernetes.client.openapi.models.V1DaemonSet item : items) {io.kubernetes.client.openapi.models.V1DaemonSetBuilder builder = new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1DaemonSet item : items) { + io.kubernetes.client.openapi.models.V1DaemonSetBuilder builder = + new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1DaemonSet item : items) {io.kubernetes.client.openapi.models.V1DaemonSetBuilder builder = new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1DaemonSet item : items) { + io.kubernetes.client.openapi.models.V1DaemonSetBuilder builder = + new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +157,274 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1DaemonSet buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1DaemonSet buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1DaemonSet buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1DaemonSet buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1DaemonSetBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1DaemonSet buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1DaemonSetBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1DaemonSetBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1DaemonSetBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1DaemonSet item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1DaemonSet item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1DaemonSet... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1DaemonSet item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1DaemonSet item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1DaemonSetListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1DaemonSet item) { - return new io.kubernetes.client.openapi.models.V1DaemonSetListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1DaemonSet item) { + return new io.kubernetes.client.openapi.models.V1DaemonSetListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSet item) { - return new io.kubernetes.client.openapi.models.V1DaemonSetListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSet item) { + return new io.kubernetes.client.openapi.models.V1DaemonSetListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1DaemonSetListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1DaemonSetListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1DaemonSetListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1DaemonSetListFluentImpl that = (V1DaemonSetListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1DaemonSetFluentImpl> implements io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSet item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1DaemonSetFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1DaemonSetListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSet item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1DaemonSetBuilder(this); } + io.kubernetes.client.openapi.models.V1DaemonSetBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1DaemonSetListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1DaemonSetListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1DaemonSetListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1DaemonSetListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetSpecBuilder.java index 6f01f87b2e..eff895c06f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DaemonSetSpecBuilder extends io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DaemonSetSpecBuilder + extends io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DaemonSetSpec, + io.kubernetes.client.openapi.models.V1DaemonSetSpecBuilder> { public V1DaemonSetSpecBuilder() { this(false); } + public V1DaemonSetSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1DaemonSetSpec(), validationEnabled); } - public V1DaemonSetSpecBuilder(io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent fluent) { + + public V1DaemonSetSpecBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent fluent) { this(fluent, false); } - public V1DaemonSetSpecBuilder(io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DaemonSetSpecBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DaemonSetSpec(), validationEnabled); } - public V1DaemonSetSpecBuilder(io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent fluent,io.kubernetes.client.openapi.models.V1DaemonSetSpec instance) { + + public V1DaemonSetSpecBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonSetSpec instance) { this(fluent, instance, false); } - public V1DaemonSetSpecBuilder(io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent fluent,io.kubernetes.client.openapi.models.V1DaemonSetSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DaemonSetSpecBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonSetSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMinReadySeconds(instance.getMinReadySeconds()); fluent.withRevisionHistoryLimit(instance.getRevisionHistoryLimit()); @@ -31,13 +58,17 @@ public V1DaemonSetSpecBuilder(io.kubernetes.client.openapi.models.V1DaemonSetSpe fluent.withUpdateStrategy(instance.getUpdateStrategy()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1DaemonSetSpecBuilder(io.kubernetes.client.openapi.models.V1DaemonSetSpec instance) { - this(instance,false); + this(instance, false); } - public V1DaemonSetSpecBuilder(io.kubernetes.client.openapi.models.V1DaemonSetSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DaemonSetSpecBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMinReadySeconds(instance.getMinReadySeconds()); this.withRevisionHistoryLimit(instance.getRevisionHistoryLimit()); @@ -48,10 +79,12 @@ public V1DaemonSetSpecBuilder(io.kubernetes.client.openapi.models.V1DaemonSetSpe this.withUpdateStrategy(instance.getUpdateStrategy()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DaemonSetSpec build() { V1DaemonSetSpec buildable = new V1DaemonSetSpec(); buildable.setMinReadySeconds(fluent.getMinReadySeconds()); @@ -61,18 +94,23 @@ public io.kubernetes.client.openapi.models.V1DaemonSetSpec build() { buildable.setUpdateStrategy(fluent.getUpdateStrategy()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DaemonSetSpecBuilder that = (V1DaemonSetSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetSpecFluent.java index 818d947d1a..30ee7c9ed8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetSpecFluent.java @@ -1,82 +1,144 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DaemonSetSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1DaemonSetSpecFluent< + A extends io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getMinReadySeconds(); + public A withMinReadySeconds(java.lang.Integer minReadySeconds); + public java.lang.Boolean hasMinReadySeconds(); + public java.lang.Integer getRevisionHistoryLimit(); + public A withRevisionHistoryLimit(java.lang.Integer revisionHistoryLimit); + public java.lang.Boolean hasRevisionHistoryLimit(); - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested + withNewSelector(); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested editSelector(); - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested + editOrNewSelector(); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate(); + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate(); + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template); + public java.lang.Boolean hasTemplate(); - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested withNewTemplate(); - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested + withNewTemplate(); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested + withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested editTemplate(); - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested editOrNewTemplate(); - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); - + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested + editOrNewTemplate(); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + /** * This method has been deprecated, please use method buildUpdateStrategy instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy getUpdateStrategy(); + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy buildUpdateStrategy(); - public A withUpdateStrategy(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy updateStrategy); + + public A withUpdateStrategy( + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy updateStrategy); + public java.lang.Boolean hasUpdateStrategy(); - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested withNewUpdateStrategy(); - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested withNewUpdateStrategyLike(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy item); - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested editUpdateStrategy(); - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested editOrNewUpdateStrategy(); - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested editOrNewUpdateStrategyLike(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy item); - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested + withNewUpdateStrategy(); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested + withNewUpdateStrategyLike(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy item); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested + editUpdateStrategy(); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested + editOrNewUpdateStrategy(); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested + editOrNewUpdateStrategyLike( + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy item); + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested> { public N and(); + public N endSelector(); - } - public interface TemplateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent>{ + + public interface TemplateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent< + io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested> { public N and(); + public N endTemplate(); - } - public interface UpdateStrategyNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent>{ + + public interface UpdateStrategyNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent< + io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested> { public N and(); + public N endUpdateStrategy(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetSpecFluentImpl.java index ea35a12f35..055065c1dd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetSpecFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1DaemonSetSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent { + public V1DaemonSetSpecFluentImpl() {} - /** - * Generated - */ -public class V1DaemonSetSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent{ - public V1DaemonSetSpecFluentImpl() { - } public V1DaemonSetSpecFluentImpl(io.kubernetes.client.openapi.models.V1DaemonSetSpec instance) { this.withMinReadySeconds(instance.getMinReadySeconds()); @@ -23,194 +29,311 @@ public V1DaemonSetSpecFluentImpl(io.kubernetes.client.openapi.models.V1DaemonSet this.withTemplate(instance.getTemplate()); this.withUpdateStrategy(instance.getUpdateStrategy()); - } + private java.lang.Integer minReadySeconds; private java.lang.Integer revisionHistoryLimit; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder selector; private io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder template; private io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyBuilder updateStrategy; + public java.lang.Integer getMinReadySeconds() { return this.minReadySeconds; } + public A withMinReadySeconds(java.lang.Integer minReadySeconds) { - this.minReadySeconds=minReadySeconds; return (A) this; + this.minReadySeconds = minReadySeconds; + return (A) this; } + public java.lang.Boolean hasMinReadySeconds() { return this.minReadySeconds != null; } + public java.lang.Integer getRevisionHistoryLimit() { return this.revisionHistoryLimit; } + public A withRevisionHistoryLimit(java.lang.Integer revisionHistoryLimit) { - this.revisionHistoryLimit=revisionHistoryLimit; return (A) this; + this.revisionHistoryLimit = revisionHistoryLimit; + return (A) this; } + public java.lang.Boolean hasRevisionHistoryLimit() { return this.revisionHistoryLimit != null; } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested withNewSelector() { + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested + withNewSelector() { return new io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl.SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl.SelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl.SelectorNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested editSelector() { + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested + editSelector() { return withNewSelectorLike(getSelector()); } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested + editOrNewSelector() { + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } - + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template) { _visitables.get("template").remove(this.template); - if (template!=null){ this.template= new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); _visitables.get("template").add(this.template);} return (A) this; + if (template != null) { + this.template = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); + _visitables.get("template").add(this.template); + } + return (A) this; } + public java.lang.Boolean hasTemplate() { return this.template != null; } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested withNewTemplate() { + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested + withNewTemplate() { return new io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl.TemplateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { - return new io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl.TemplateNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested + withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + return new io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl.TemplateNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested editTemplate() { + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested + editTemplate() { return withNewTemplateLike(getTemplate()); } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested editOrNewTemplate() { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested + editOrNewTemplate() { + return withNewTemplateLike( + getTemplate() != null + ? getTemplate() + : new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): item); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + return withNewTemplateLike(getTemplate() != null ? getTemplate() : item); } - + /** * This method has been deprecated, please use method buildUpdateStrategy instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy getUpdateStrategy() { - return this.updateStrategy!=null ?this.updateStrategy.build():null; + return this.updateStrategy != null ? this.updateStrategy.build() : null; } + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy buildUpdateStrategy() { - return this.updateStrategy!=null ?this.updateStrategy.build():null; + return this.updateStrategy != null ? this.updateStrategy.build() : null; } - public A withUpdateStrategy(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy updateStrategy) { + + public A withUpdateStrategy( + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy updateStrategy) { _visitables.get("updateStrategy").remove(this.updateStrategy); - if (updateStrategy!=null){ this.updateStrategy= new io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyBuilder(updateStrategy); _visitables.get("updateStrategy").add(this.updateStrategy);} return (A) this; + if (updateStrategy != null) { + this.updateStrategy = + new io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyBuilder(updateStrategy); + _visitables.get("updateStrategy").add(this.updateStrategy); + } + return (A) this; } + public java.lang.Boolean hasUpdateStrategy() { return this.updateStrategy != null; } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested withNewUpdateStrategy() { - return new io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl.UpdateStrategyNestedImpl(); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested + withNewUpdateStrategy() { + return new io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl + .UpdateStrategyNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested withNewUpdateStrategyLike(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy item) { - return new io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl.UpdateStrategyNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested + withNewUpdateStrategyLike( + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy item) { + return new io.kubernetes.client.openapi.models.V1DaemonSetSpecFluentImpl + .UpdateStrategyNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested editUpdateStrategy() { + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested + editUpdateStrategy() { return withNewUpdateStrategyLike(getUpdateStrategy()); } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested editOrNewUpdateStrategy() { - return withNewUpdateStrategyLike(getUpdateStrategy() != null ? getUpdateStrategy(): new io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested + editOrNewUpdateStrategy() { + return withNewUpdateStrategyLike( + getUpdateStrategy() != null + ? getUpdateStrategy() + : new io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested editOrNewUpdateStrategyLike(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy item) { - return withNewUpdateStrategyLike(getUpdateStrategy() != null ? getUpdateStrategy(): item); + + public io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested + editOrNewUpdateStrategyLike( + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy item) { + return withNewUpdateStrategyLike(getUpdateStrategy() != null ? getUpdateStrategy() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1DaemonSetSpecFluentImpl that = (V1DaemonSetSpecFluentImpl) o; - if (minReadySeconds != null ? !minReadySeconds.equals(that.minReadySeconds) :that.minReadySeconds != null) return false; - if (revisionHistoryLimit != null ? !revisionHistoryLimit.equals(that.revisionHistoryLimit) :that.revisionHistoryLimit != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; - if (template != null ? !template.equals(that.template) :that.template != null) return false; - if (updateStrategy != null ? !updateStrategy.equals(that.updateStrategy) :that.updateStrategy != null) return false; + if (minReadySeconds != null + ? !minReadySeconds.equals(that.minReadySeconds) + : that.minReadySeconds != null) return false; + if (revisionHistoryLimit != null + ? !revisionHistoryLimit.equals(that.revisionHistoryLimit) + : that.revisionHistoryLimit != null) return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; + if (template != null ? !template.equals(that.template) : that.template != null) return false; + if (updateStrategy != null + ? !updateStrategy.equals(that.updateStrategy) + : that.updateStrategy != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(minReadySeconds, revisionHistoryLimit, selector, template, updateStrategy, super.hashCode()); + return java.util.Objects.hash( + minReadySeconds, + revisionHistoryLimit, + selector, + template, + updateStrategy, + super.hashCode()); } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested> + implements io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.SelectorNested, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1DaemonSetSpecFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - public class TemplateNestedImpl extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested,io.kubernetes.client.fluent.Nested{ + + public class TemplateNestedImpl + extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested> + implements io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.TemplateNested, + io.kubernetes.client.fluent.Nested { TemplateNestedImpl(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this, item); } + TemplateNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder builder; + public N and() { return (N) V1DaemonSetSpecFluentImpl.this.withTemplate(builder.build()); } + public N endTemplate() { return and(); } - } - public class UpdateStrategyNestedImpl extends io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluentImpl> implements io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested,io.kubernetes.client.fluent.Nested{ + + public class UpdateStrategyNestedImpl + extends io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested> + implements io.kubernetes.client.openapi.models.V1DaemonSetSpecFluent.UpdateStrategyNested, + io.kubernetes.client.fluent.Nested { UpdateStrategyNestedImpl(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy item) { - this.builder = new io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyBuilder(this, item); } + UpdateStrategyNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyBuilder(this); } + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyBuilder builder; + public N and() { return (N) V1DaemonSetSpecFluentImpl.this.withUpdateStrategy(builder.build()); } + public N endUpdateStrategy() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetStatusBuilder.java index 97059c2c0b..772d637947 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DaemonSetStatusBuilder extends io.kubernetes.client.openapi.models.V1DaemonSetStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DaemonSetStatusBuilder + extends io.kubernetes.client.openapi.models.V1DaemonSetStatusFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DaemonSetStatus, + io.kubernetes.client.openapi.models.V1DaemonSetStatusBuilder> { public V1DaemonSetStatusBuilder() { this(false); } + public V1DaemonSetStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1DaemonSetStatus(), validationEnabled); } - public V1DaemonSetStatusBuilder(io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent fluent) { + + public V1DaemonSetStatusBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent fluent) { this(fluent, false); } - public V1DaemonSetStatusBuilder(io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DaemonSetStatusBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DaemonSetStatus(), validationEnabled); } - public V1DaemonSetStatusBuilder(io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent fluent,io.kubernetes.client.openapi.models.V1DaemonSetStatus instance) { + + public V1DaemonSetStatusBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonSetStatus instance) { this(fluent, instance, false); } - public V1DaemonSetStatusBuilder(io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent fluent,io.kubernetes.client.openapi.models.V1DaemonSetStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DaemonSetStatusBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonSetStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCollisionCount(instance.getCollisionCount()); fluent.withConditions(instance.getConditions()); @@ -41,13 +68,17 @@ public V1DaemonSetStatusBuilder(io.kubernetes.client.openapi.models.V1DaemonSetS fluent.withUpdatedNumberScheduled(instance.getUpdatedNumberScheduled()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1DaemonSetStatusBuilder(io.kubernetes.client.openapi.models.V1DaemonSetStatus instance) { - this(instance,false); + this(instance, false); } - public V1DaemonSetStatusBuilder(io.kubernetes.client.openapi.models.V1DaemonSetStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DaemonSetStatusBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCollisionCount(instance.getCollisionCount()); this.withConditions(instance.getConditions()); @@ -68,10 +99,12 @@ public V1DaemonSetStatusBuilder(io.kubernetes.client.openapi.models.V1DaemonSetS this.withUpdatedNumberScheduled(instance.getUpdatedNumberScheduled()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DaemonSetStatus build() { V1DaemonSetStatus buildable = new V1DaemonSetStatus(); buildable.setCollisionCount(fluent.getCollisionCount()); @@ -86,18 +119,23 @@ public io.kubernetes.client.openapi.models.V1DaemonSetStatus build() { buildable.setUpdatedNumberScheduled(fluent.getUpdatedNumberScheduled()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DaemonSetStatusBuilder that = (V1DaemonSetStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetStatusFluent.java index ef2f5375e5..2ae228e782 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetStatusFluent.java @@ -1,85 +1,158 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Long; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DaemonSetStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1DaemonSetStatusFluent< + A extends io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getCollisionCount(); + public A withCollisionCount(java.lang.Integer collisionCount); + public java.lang.Boolean hasCollisionCount(); - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSetCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSetCondition item); + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSetCondition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSetCondition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1DaemonSetCondition... items); - public A addAllToConditions(java.util.Collection items); + + public A addAllToConditions( + java.util.Collection items); + public A removeFromConditions(io.kubernetes.client.openapi.models.V1DaemonSetCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getConditions(); + public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1DaemonSetCondition buildCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1DaemonSetCondition buildCondition( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1DaemonSetCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1DaemonSetCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1DaemonSetCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); + + public io.kubernetes.client.openapi.models.V1DaemonSetCondition buildMatchingCondition( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate); + + public A withConditions( + java.util.List conditions); + public A withConditions(io.kubernetes.client.openapi.models.V1DaemonSetCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1DaemonSetCondition item); - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSetCondition item); - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1DaemonSetCondition item); + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSetCondition item); + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder> + predicate); + public java.lang.Integer getCurrentNumberScheduled(); + public A withCurrentNumberScheduled(java.lang.Integer currentNumberScheduled); + public java.lang.Boolean hasCurrentNumberScheduled(); + public java.lang.Integer getDesiredNumberScheduled(); + public A withDesiredNumberScheduled(java.lang.Integer desiredNumberScheduled); + public java.lang.Boolean hasDesiredNumberScheduled(); + public java.lang.Integer getNumberAvailable(); + public A withNumberAvailable(java.lang.Integer numberAvailable); + public java.lang.Boolean hasNumberAvailable(); + public java.lang.Integer getNumberMisscheduled(); + public A withNumberMisscheduled(java.lang.Integer numberMisscheduled); + public java.lang.Boolean hasNumberMisscheduled(); + public java.lang.Integer getNumberReady(); + public A withNumberReady(java.lang.Integer numberReady); + public java.lang.Boolean hasNumberReady(); + public java.lang.Integer getNumberUnavailable(); + public A withNumberUnavailable(java.lang.Integer numberUnavailable); + public java.lang.Boolean hasNumberUnavailable(); + public java.lang.Long getObservedGeneration(); + public A withObservedGeneration(java.lang.Long observedGeneration); + public java.lang.Boolean hasObservedGeneration(); + public java.lang.Integer getUpdatedNumberScheduled(); + public A withUpdatedNumberScheduled(java.lang.Integer updatedNumberScheduled); + public java.lang.Boolean hasUpdatedNumberScheduled(); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DaemonSetConditionFluent< + io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetStatusFluentImpl.java index e1b77ac1cf..c2b33a72e2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetStatusFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1DaemonSetStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent{ - public V1DaemonSetStatusFluentImpl() { - } - public V1DaemonSetStatusFluentImpl(io.kubernetes.client.openapi.models.V1DaemonSetStatus instance) { +/** Generated */ +public class V1DaemonSetStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent { + public V1DaemonSetStatusFluentImpl() {} + + public V1DaemonSetStatusFluentImpl( + io.kubernetes.client.openapi.models.V1DaemonSetStatus instance) { this.withCollisionCount(instance.getCollisionCount()); this.withConditions(instance.getConditions()); @@ -40,10 +43,11 @@ public V1DaemonSetStatusFluentImpl(io.kubernetes.client.openapi.models.V1DaemonS this.withObservedGeneration(instance.getObservedGeneration()); this.withUpdatedNumberScheduled(instance.getUpdatedNumberScheduled()); - } + private java.lang.Integer collisionCount; - private java.util.ArrayList conditions; + private java.util.ArrayList + conditions; private java.lang.Integer currentNumberScheduled; private java.lang.Integer desiredNumberScheduled; private java.lang.Integer numberAvailable; @@ -52,43 +56,120 @@ public V1DaemonSetStatusFluentImpl(io.kubernetes.client.openapi.models.V1DaemonS private java.lang.Integer numberUnavailable; private java.lang.Long observedGeneration; private java.lang.Integer updatedNumberScheduled; + public java.lang.Integer getCollisionCount() { return this.collisionCount; } + public A withCollisionCount(java.lang.Integer collisionCount) { - this.collisionCount=collisionCount; return (A) this; + this.collisionCount = collisionCount; + return (A) this; } + public java.lang.Boolean hasCollisionCount() { return this.collisionCount != null; } - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSetCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSetCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSetCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSetCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } + public A addToConditions(io.kubernetes.client.openapi.models.V1DaemonSetCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1DaemonSetCondition item : items) {io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1DaemonSetCondition item : items) { + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1DaemonSetCondition item : items) {io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1DaemonSetCondition item : items) { + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } + public A removeFromConditions(io.kubernetes.client.openapi.models.V1DaemonSetCondition... items) { - for (io.kubernetes.client.openapi.models.V1DaemonSetCondition item : items) {io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1DaemonSetCondition item : items) { + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1DaemonSetCondition item : items) {io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1DaemonSetCondition item : items) { + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder = each.next(); @@ -97,185 +178,327 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1DaemonSetCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1DaemonSetCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1DaemonSetCondition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1DaemonSetCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1DaemonSetCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1DaemonSetCondition buildMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1DaemonSetCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1DaemonSetCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } + public A withConditions(io.kubernetes.client.openapi.models.V1DaemonSetCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1DaemonSetCondition item :conditions){ this.addToConditions(item);}} return (A) this; + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1DaemonSetCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1DaemonSetStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1DaemonSetStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1DaemonSetCondition item) { - return new io.kubernetes.client.openapi.models.V1DaemonSetStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1DaemonSetCondition item) { + return new io.kubernetes.client.openapi.models.V1DaemonSetStatusFluentImpl.ConditionsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSetCondition item) { - return new io.kubernetes.client.openapi.models.V1DaemonSetStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSetCondition item) { + return new io.kubernetes.client.openapi.models.V1DaemonSetStatusFluentImpl.ConditionsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1DaemonSetConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DaemonSetCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1DaemonSetConditionFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1DaemonSetStatusFluent.ConditionsNested, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DaemonSetCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1DaemonSetConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1DaemonSetStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1DaemonSetStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetUpdateStrategyBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetUpdateStrategyBuilder.java index 089d5b6814..483c1c8793 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetUpdateStrategyBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetUpdateStrategyBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DaemonSetUpdateStrategyBuilder extends io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DaemonSetUpdateStrategyBuilder + extends io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy, + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyBuilder> { public V1DaemonSetUpdateStrategyBuilder() { this(false); } + public V1DaemonSetUpdateStrategyBuilder(java.lang.Boolean validationEnabled) { this(new V1DaemonSetUpdateStrategy(), validationEnabled); } - public V1DaemonSetUpdateStrategyBuilder(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent fluent) { + + public V1DaemonSetUpdateStrategyBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent fluent) { this(fluent, false); } - public V1DaemonSetUpdateStrategyBuilder(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DaemonSetUpdateStrategyBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DaemonSetUpdateStrategy(), validationEnabled); } - public V1DaemonSetUpdateStrategyBuilder(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent fluent,io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy instance) { + + public V1DaemonSetUpdateStrategyBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy instance) { this(fluent, instance, false); } - public V1DaemonSetUpdateStrategyBuilder(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent fluent,io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DaemonSetUpdateStrategyBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent fluent, + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withRollingUpdate(instance.getRollingUpdate()); fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1DaemonSetUpdateStrategyBuilder(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy instance) { - this(instance,false); + + public V1DaemonSetUpdateStrategyBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy instance) { + this(instance, false); } - public V1DaemonSetUpdateStrategyBuilder(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DaemonSetUpdateStrategyBuilder( + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withRollingUpdate(instance.getRollingUpdate()); this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy build() { V1DaemonSetUpdateStrategy buildable = new V1DaemonSetUpdateStrategy(); buildable.setRollingUpdate(fluent.getRollingUpdate()); buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DaemonSetUpdateStrategyBuilder that = (V1DaemonSetUpdateStrategyBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetUpdateStrategyFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetUpdateStrategyFluent.java index 4337b51bb9..b81594a399 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetUpdateStrategyFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetUpdateStrategyFluent.java @@ -1,38 +1,66 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DaemonSetUpdateStrategyFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1DaemonSetUpdateStrategyFluent< + A extends io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildRollingUpdate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet getRollingUpdate(); + public io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet buildRollingUpdate(); - public A withRollingUpdate(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet rollingUpdate); + + public A withRollingUpdate( + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet rollingUpdate); + public java.lang.Boolean hasRollingUpdate(); - public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested withNewRollingUpdate(); - public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested withNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet item); - public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested editRollingUpdate(); - public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested editOrNewRollingUpdate(); - public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested editOrNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet item); + + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested + withNewRollingUpdate(); + + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested + withNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet item); + + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested + editRollingUpdate(); + + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested + editOrNewRollingUpdate(); + + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested + editOrNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet item); + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy.TypeEnum getType(); + public A withType(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy.TypeEnum type); + public java.lang.Boolean hasType(); - public interface RollingUpdateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent>{ + + public interface RollingUpdateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent< + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent + .RollingUpdateNested< + N>> { public N and(); + public N endRollingUpdate(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetUpdateStrategyFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetUpdateStrategyFluentImpl.java index 46bd509cbc..b73cc94f8e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetUpdateStrategyFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DaemonSetUpdateStrategyFluentImpl.java @@ -1,94 +1,147 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1DaemonSetUpdateStrategyFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent { + public V1DaemonSetUpdateStrategyFluentImpl() {} - /** - * Generated - */ -public class V1DaemonSetUpdateStrategyFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent{ - public V1DaemonSetUpdateStrategyFluentImpl() { - } - public V1DaemonSetUpdateStrategyFluentImpl(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy instance) { + public V1DaemonSetUpdateStrategyFluentImpl( + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy instance) { this.withRollingUpdate(instance.getRollingUpdate()); this.withType(instance.getType()); - } + private io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetBuilder rollingUpdate; private io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy.TypeEnum type; - + /** * This method has been deprecated, please use method buildRollingUpdate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet getRollingUpdate() { - return this.rollingUpdate!=null ?this.rollingUpdate.build():null; + return this.rollingUpdate != null ? this.rollingUpdate.build() : null; } + public io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet buildRollingUpdate() { - return this.rollingUpdate!=null ?this.rollingUpdate.build():null; + return this.rollingUpdate != null ? this.rollingUpdate.build() : null; } - public A withRollingUpdate(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet rollingUpdate) { + + public A withRollingUpdate( + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet rollingUpdate) { _visitables.get("rollingUpdate").remove(this.rollingUpdate); - if (rollingUpdate!=null){ this.rollingUpdate= new io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetBuilder(rollingUpdate); _visitables.get("rollingUpdate").add(this.rollingUpdate);} return (A) this; + if (rollingUpdate != null) { + this.rollingUpdate = + new io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetBuilder(rollingUpdate); + _visitables.get("rollingUpdate").add(this.rollingUpdate); + } + return (A) this; } + public java.lang.Boolean hasRollingUpdate() { return this.rollingUpdate != null; } - public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested withNewRollingUpdate() { - return new io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluentImpl.RollingUpdateNestedImpl(); + + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested + withNewRollingUpdate() { + return new io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluentImpl + .RollingUpdateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested withNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet item) { - return new io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluentImpl.RollingUpdateNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested + withNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet item) { + return new io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluentImpl + .RollingUpdateNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested editRollingUpdate() { + + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested + editRollingUpdate() { return withNewRollingUpdateLike(getRollingUpdate()); } - public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested editOrNewRollingUpdate() { - return withNewRollingUpdateLike(getRollingUpdate() != null ? getRollingUpdate(): new io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested + editOrNewRollingUpdate() { + return withNewRollingUpdateLike( + getRollingUpdate() != null + ? getRollingUpdate() + : new io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested editOrNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet item) { - return withNewRollingUpdateLike(getRollingUpdate() != null ? getRollingUpdate(): item); + + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested + editOrNewRollingUpdateLike( + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet item) { + return withNewRollingUpdateLike(getRollingUpdate() != null ? getRollingUpdate() : item); } + public io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy.TypeEnum getType() { return this.type; } + public A withType(io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategy.TypeEnum type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1DaemonSetUpdateStrategyFluentImpl that = (V1DaemonSetUpdateStrategyFluentImpl) o; - if (rollingUpdate != null ? !rollingUpdate.equals(that.rollingUpdate) :that.rollingUpdate != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (rollingUpdate != null + ? !rollingUpdate.equals(that.rollingUpdate) + : that.rollingUpdate != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(rollingUpdate, type, super.hashCode()); + return java.util.Objects.hash(rollingUpdate, type, super.hashCode()); } - public class RollingUpdateNestedImpl extends io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluentImpl> implements io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested,io.kubernetes.client.fluent.Nested{ + + public class RollingUpdateNestedImpl + extends io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluentImpl< + io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent.RollingUpdateNested< + N>> + implements io.kubernetes.client.openapi.models.V1DaemonSetUpdateStrategyFluent + .RollingUpdateNested< + N>, + io.kubernetes.client.fluent.Nested { RollingUpdateNestedImpl(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet item) { - this.builder = new io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetBuilder(this, item); } + RollingUpdateNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetBuilder(this); } + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetBuilder builder; + public N and() { return (N) V1DaemonSetUpdateStrategyFluentImpl.this.withRollingUpdate(builder.build()); } + public N endRollingUpdate() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeleteOptionsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeleteOptionsBuilder.java index be3f6ed92a..ca323b83da 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeleteOptionsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeleteOptionsBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DeleteOptionsBuilder extends io.kubernetes.client.openapi.models.V1DeleteOptionsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DeleteOptionsBuilder + extends io.kubernetes.client.openapi.models.V1DeleteOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1DeleteOptionsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DeleteOptions, + io.kubernetes.client.openapi.models.V1DeleteOptionsBuilder> { public V1DeleteOptionsBuilder() { this(false); } + public V1DeleteOptionsBuilder(java.lang.Boolean validationEnabled) { this(new V1DeleteOptions(), validationEnabled); } - public V1DeleteOptionsBuilder(io.kubernetes.client.openapi.models.V1DeleteOptionsFluent fluent) { + + public V1DeleteOptionsBuilder( + io.kubernetes.client.openapi.models.V1DeleteOptionsFluent fluent) { this(fluent, false); } - public V1DeleteOptionsBuilder(io.kubernetes.client.openapi.models.V1DeleteOptionsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DeleteOptionsBuilder( + io.kubernetes.client.openapi.models.V1DeleteOptionsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DeleteOptions(), validationEnabled); } - public V1DeleteOptionsBuilder(io.kubernetes.client.openapi.models.V1DeleteOptionsFluent fluent,io.kubernetes.client.openapi.models.V1DeleteOptions instance) { + + public V1DeleteOptionsBuilder( + io.kubernetes.client.openapi.models.V1DeleteOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1DeleteOptions instance) { this(fluent, instance, false); } - public V1DeleteOptionsBuilder(io.kubernetes.client.openapi.models.V1DeleteOptionsFluent fluent,io.kubernetes.client.openapi.models.V1DeleteOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DeleteOptionsBuilder( + io.kubernetes.client.openapi.models.V1DeleteOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1DeleteOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withDryRun(instance.getDryRun()); @@ -35,13 +62,17 @@ public V1DeleteOptionsBuilder(io.kubernetes.client.openapi.models.V1DeleteOption fluent.withPropagationPolicy(instance.getPropagationPolicy()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1DeleteOptionsBuilder(io.kubernetes.client.openapi.models.V1DeleteOptions instance) { - this(instance,false); + this(instance, false); } - public V1DeleteOptionsBuilder(io.kubernetes.client.openapi.models.V1DeleteOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DeleteOptionsBuilder( + io.kubernetes.client.openapi.models.V1DeleteOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withDryRun(instance.getDryRun()); @@ -56,10 +87,12 @@ public V1DeleteOptionsBuilder(io.kubernetes.client.openapi.models.V1DeleteOption this.withPropagationPolicy(instance.getPropagationPolicy()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DeleteOptionsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DeleteOptions build() { V1DeleteOptions buildable = new V1DeleteOptions(); buildable.setApiVersion(fluent.getApiVersion()); @@ -71,18 +104,23 @@ public io.kubernetes.client.openapi.models.V1DeleteOptions build() { buildable.setPropagationPolicy(fluent.getPropagationPolicy()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DeleteOptionsBuilder that = (V1DeleteOptionsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeleteOptionsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeleteOptionsFluent.java index 97d60925a4..02f4452aba 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeleteOptionsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeleteOptionsFluent.java @@ -1,90 +1,132 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Long; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DeleteOptionsFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1DeleteOptionsFluent< + A extends io.kubernetes.client.openapi.models.V1DeleteOptionsFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToDryRun(java.lang.Integer index,java.lang.String item); - public A setToDryRun(java.lang.Integer index,java.lang.String item); + + public A addToDryRun(java.lang.Integer index, java.lang.String item); + + public A setToDryRun(java.lang.Integer index, java.lang.String item); + public A addToDryRun(java.lang.String... items); + public A addAllToDryRun(java.util.Collection items); + public A removeFromDryRun(java.lang.String... items); + public A removeAllFromDryRun(java.util.Collection items); + public java.util.List getDryRun(); + public java.lang.String getDryRun(java.lang.Integer index); + public java.lang.String getFirstDryRun(); + public java.lang.String getLastDryRun(); - public java.lang.String getMatchingDryRun(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingDryRun(java.util.function.Predicate predicate); + + public java.lang.String getMatchingDryRun( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingDryRun( + java.util.function.Predicate predicate); + public A withDryRun(java.util.List dryRun); + public A withDryRun(java.lang.String... dryRun); + public java.lang.Boolean hasDryRun(); + public A addNewDryRun(java.lang.String original); + public java.lang.Long getGracePeriodSeconds(); + public A withGracePeriodSeconds(java.lang.Long gracePeriodSeconds); + public java.lang.Boolean hasGracePeriodSeconds(); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.Boolean getOrphanDependents(); + public A withOrphanDependents(java.lang.Boolean orphanDependents); + public java.lang.Boolean hasOrphanDependents(); - + /** * This method has been deprecated, please use method buildPreconditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Preconditions getPreconditions(); + public io.kubernetes.client.openapi.models.V1Preconditions buildPreconditions(); + public A withPreconditions(io.kubernetes.client.openapi.models.V1Preconditions preconditions); + public java.lang.Boolean hasPreconditions(); - public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested withNewPreconditions(); - public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested withNewPreconditionsLike(io.kubernetes.client.openapi.models.V1Preconditions item); - public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested editPreconditions(); - public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested editOrNewPreconditions(); - public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested editOrNewPreconditionsLike(io.kubernetes.client.openapi.models.V1Preconditions item); + + public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested + withNewPreconditions(); + + public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested + withNewPreconditionsLike(io.kubernetes.client.openapi.models.V1Preconditions item); + + public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested + editPreconditions(); + + public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested + editOrNewPreconditions(); + + public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested + editOrNewPreconditionsLike(io.kubernetes.client.openapi.models.V1Preconditions item); + public java.lang.String getPropagationPolicy(); + public A withPropagationPolicy(java.lang.String propagationPolicy); + public java.lang.Boolean hasPropagationPolicy(); - - /** - * Method is deprecated. use withPropagationPolicy instead. - */ + + /** Method is deprecated. use withPropagationPolicy instead. */ @java.lang.Deprecated public A withNewPropagationPolicy(java.lang.String original); - public interface PreconditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PreconditionsFluent>{ + + public interface PreconditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PreconditionsFluent< + io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested> { public N and(); + public N endPreconditions(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeleteOptionsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeleteOptionsFluentImpl.java index a62845709e..0c47db21e3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeleteOptionsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeleteOptionsFluentImpl.java @@ -1,24 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1DeleteOptionsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DeleteOptionsFluent{ - public V1DeleteOptionsFluentImpl() { - } +/** Generated */ +public class V1DeleteOptionsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DeleteOptionsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DeleteOptionsFluent { + public V1DeleteOptionsFluentImpl() {} + public V1DeleteOptionsFluentImpl(io.kubernetes.client.openapi.models.V1DeleteOptions instance) { this.withApiVersion(instance.getApiVersion()); @@ -33,8 +33,8 @@ public V1DeleteOptionsFluentImpl(io.kubernetes.client.openapi.models.V1DeleteOpt this.withPreconditions(instance.getPreconditions()); this.withPropagationPolicy(instance.getPropagationPolicy()); - } + private java.lang.String apiVersion; private java.util.List dryRun; private java.lang.Long gracePeriodSeconds; @@ -42,194 +42,326 @@ public V1DeleteOptionsFluentImpl(io.kubernetes.client.openapi.models.V1DeleteOpt private java.lang.Boolean orphanDependents; private io.kubernetes.client.openapi.models.V1PreconditionsBuilder preconditions; private java.lang.String propagationPolicy; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToDryRun(java.lang.Integer index,java.lang.String item) { - if (this.dryRun == null) {this.dryRun = new java.util.ArrayList();} + + public A addToDryRun(java.lang.Integer index, java.lang.String item) { + if (this.dryRun == null) { + this.dryRun = new java.util.ArrayList(); + } this.dryRun.add(index, item); - return (A)this; + return (A) this; } - public A setToDryRun(java.lang.Integer index,java.lang.String item) { - if (this.dryRun == null) {this.dryRun = new java.util.ArrayList();} - this.dryRun.set(index, item); return (A)this; + + public A setToDryRun(java.lang.Integer index, java.lang.String item) { + if (this.dryRun == null) { + this.dryRun = new java.util.ArrayList(); + } + this.dryRun.set(index, item); + return (A) this; } + public A addToDryRun(java.lang.String... items) { - if (this.dryRun == null) {this.dryRun = new java.util.ArrayList();} - for (java.lang.String item : items) {this.dryRun.add(item);} return (A)this; + if (this.dryRun == null) { + this.dryRun = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.dryRun.add(item); + } + return (A) this; } + public A addAllToDryRun(java.util.Collection items) { - if (this.dryRun == null) {this.dryRun = new java.util.ArrayList();} - for (java.lang.String item : items) {this.dryRun.add(item);} return (A)this; + if (this.dryRun == null) { + this.dryRun = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.dryRun.add(item); + } + return (A) this; } + public A removeFromDryRun(java.lang.String... items) { - for (java.lang.String item : items) {if (this.dryRun!= null){ this.dryRun.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.dryRun != null) { + this.dryRun.remove(item); + } + } + return (A) this; } + public A removeAllFromDryRun(java.util.Collection items) { - for (java.lang.String item : items) {if (this.dryRun!= null){ this.dryRun.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.dryRun != null) { + this.dryRun.remove(item); + } + } + return (A) this; } + public java.util.List getDryRun() { return this.dryRun; } + public java.lang.String getDryRun(java.lang.Integer index) { return this.dryRun.get(index); } + public java.lang.String getFirstDryRun() { return this.dryRun.get(0); } + public java.lang.String getLastDryRun() { return this.dryRun.get(dryRun.size() - 1); } - public java.lang.String getMatchingDryRun(java.util.function.Predicate predicate) { - for (java.lang.String item: dryRun) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingDryRun( + java.util.function.Predicate predicate) { + for (java.lang.String item : dryRun) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingDryRun(java.util.function.Predicate predicate) { - for (java.lang.String item: dryRun) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingDryRun( + java.util.function.Predicate predicate) { + for (java.lang.String item : dryRun) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withDryRun(java.util.List dryRun) { - if (dryRun != null) {this.dryRun = new java.util.ArrayList(); for (java.lang.String item : dryRun){this.addToDryRun(item);}} else { this.dryRun = null;} return (A) this; + if (dryRun != null) { + this.dryRun = new java.util.ArrayList(); + for (java.lang.String item : dryRun) { + this.addToDryRun(item); + } + } else { + this.dryRun = null; + } + return (A) this; } + public A withDryRun(java.lang.String... dryRun) { - if (this.dryRun != null) {this.dryRun.clear();} - if (dryRun != null) {for (java.lang.String item :dryRun){ this.addToDryRun(item);}} return (A) this; + if (this.dryRun != null) { + this.dryRun.clear(); + } + if (dryRun != null) { + for (java.lang.String item : dryRun) { + this.addToDryRun(item); + } + } + return (A) this; } + public java.lang.Boolean hasDryRun() { return dryRun != null && !dryRun.isEmpty(); } + public A addNewDryRun(java.lang.String original) { - return (A)addToDryRun(new String(original)); + return (A) addToDryRun(new String(original)); } + public java.lang.Long getGracePeriodSeconds() { return this.gracePeriodSeconds; } + public A withGracePeriodSeconds(java.lang.Long gracePeriodSeconds) { - this.gracePeriodSeconds=gracePeriodSeconds; return (A) this; + this.gracePeriodSeconds = gracePeriodSeconds; + return (A) this; } + public java.lang.Boolean hasGracePeriodSeconds() { return this.gracePeriodSeconds != null; } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.Boolean getOrphanDependents() { return this.orphanDependents; } + public A withOrphanDependents(java.lang.Boolean orphanDependents) { - this.orphanDependents=orphanDependents; return (A) this; + this.orphanDependents = orphanDependents; + return (A) this; } + public java.lang.Boolean hasOrphanDependents() { return this.orphanDependents != null; } - + /** * This method has been deprecated, please use method buildPreconditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Preconditions getPreconditions() { - return this.preconditions!=null ?this.preconditions.build():null; + return this.preconditions != null ? this.preconditions.build() : null; } + public io.kubernetes.client.openapi.models.V1Preconditions buildPreconditions() { - return this.preconditions!=null ?this.preconditions.build():null; + return this.preconditions != null ? this.preconditions.build() : null; } + public A withPreconditions(io.kubernetes.client.openapi.models.V1Preconditions preconditions) { _visitables.get("preconditions").remove(this.preconditions); - if (preconditions!=null){ this.preconditions= new io.kubernetes.client.openapi.models.V1PreconditionsBuilder(preconditions); _visitables.get("preconditions").add(this.preconditions);} return (A) this; + if (preconditions != null) { + this.preconditions = + new io.kubernetes.client.openapi.models.V1PreconditionsBuilder(preconditions); + _visitables.get("preconditions").add(this.preconditions); + } + return (A) this; } + public java.lang.Boolean hasPreconditions() { return this.preconditions != null; } - public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested withNewPreconditions() { - return new io.kubernetes.client.openapi.models.V1DeleteOptionsFluentImpl.PreconditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested + withNewPreconditions() { + return new io.kubernetes.client.openapi.models.V1DeleteOptionsFluentImpl + .PreconditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested withNewPreconditionsLike(io.kubernetes.client.openapi.models.V1Preconditions item) { - return new io.kubernetes.client.openapi.models.V1DeleteOptionsFluentImpl.PreconditionsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested + withNewPreconditionsLike(io.kubernetes.client.openapi.models.V1Preconditions item) { + return new io.kubernetes.client.openapi.models.V1DeleteOptionsFluentImpl + .PreconditionsNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested editPreconditions() { + + public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested + editPreconditions() { return withNewPreconditionsLike(getPreconditions()); } - public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested editOrNewPreconditions() { - return withNewPreconditionsLike(getPreconditions() != null ? getPreconditions(): new io.kubernetes.client.openapi.models.V1PreconditionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested + editOrNewPreconditions() { + return withNewPreconditionsLike( + getPreconditions() != null + ? getPreconditions() + : new io.kubernetes.client.openapi.models.V1PreconditionsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested editOrNewPreconditionsLike(io.kubernetes.client.openapi.models.V1Preconditions item) { - return withNewPreconditionsLike(getPreconditions() != null ? getPreconditions(): item); + + public io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested + editOrNewPreconditionsLike(io.kubernetes.client.openapi.models.V1Preconditions item) { + return withNewPreconditionsLike(getPreconditions() != null ? getPreconditions() : item); } + public java.lang.String getPropagationPolicy() { return this.propagationPolicy; } + public A withPropagationPolicy(java.lang.String propagationPolicy) { - this.propagationPolicy=propagationPolicy; return (A) this; + this.propagationPolicy = propagationPolicy; + return (A) this; } + public java.lang.Boolean hasPropagationPolicy() { return this.propagationPolicy != null; } - - /** - * Method is deprecated. use withPropagationPolicy instead. - */ + + /** Method is deprecated. use withPropagationPolicy instead. */ @java.lang.Deprecated public A withNewPropagationPolicy(java.lang.String original) { - return (A)withPropagationPolicy(new String(original)); + return (A) withPropagationPolicy(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1DeleteOptionsFluentImpl that = (V1DeleteOptionsFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (dryRun != null ? !dryRun.equals(that.dryRun) :that.dryRun != null) return false; - if (gracePeriodSeconds != null ? !gracePeriodSeconds.equals(that.gracePeriodSeconds) :that.gracePeriodSeconds != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (orphanDependents != null ? !orphanDependents.equals(that.orphanDependents) :that.orphanDependents != null) return false; - if (preconditions != null ? !preconditions.equals(that.preconditions) :that.preconditions != null) return false; - if (propagationPolicy != null ? !propagationPolicy.equals(that.propagationPolicy) :that.propagationPolicy != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (dryRun != null ? !dryRun.equals(that.dryRun) : that.dryRun != null) return false; + if (gracePeriodSeconds != null + ? !gracePeriodSeconds.equals(that.gracePeriodSeconds) + : that.gracePeriodSeconds != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (orphanDependents != null + ? !orphanDependents.equals(that.orphanDependents) + : that.orphanDependents != null) return false; + if (preconditions != null + ? !preconditions.equals(that.preconditions) + : that.preconditions != null) return false; + if (propagationPolicy != null + ? !propagationPolicy.equals(that.propagationPolicy) + : that.propagationPolicy != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, dryRun, gracePeriodSeconds, kind, orphanDependents, preconditions, propagationPolicy, super.hashCode()); + return java.util.Objects.hash( + apiVersion, + dryRun, + gracePeriodSeconds, + kind, + orphanDependents, + preconditions, + propagationPolicy, + super.hashCode()); } - public class PreconditionsNestedImpl extends io.kubernetes.client.openapi.models.V1PreconditionsFluentImpl> implements io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested,io.kubernetes.client.fluent.Nested{ + + public class PreconditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1PreconditionsFluentImpl< + io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested> + implements io.kubernetes.client.openapi.models.V1DeleteOptionsFluent.PreconditionsNested, + io.kubernetes.client.fluent.Nested { PreconditionsNestedImpl(io.kubernetes.client.openapi.models.V1Preconditions item) { this.builder = new io.kubernetes.client.openapi.models.V1PreconditionsBuilder(this, item); } + PreconditionsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PreconditionsBuilder(this); } + io.kubernetes.client.openapi.models.V1PreconditionsBuilder builder; + public N and() { return (N) V1DeleteOptionsFluentImpl.this.withPreconditions(builder.build()); } + public N endPreconditions() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentBuilder.java index 5762bd2921..688ed7419c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DeploymentBuilder extends io.kubernetes.client.openapi.models.V1DeploymentFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DeploymentBuilder + extends io.kubernetes.client.openapi.models.V1DeploymentFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Deployment, + io.kubernetes.client.openapi.models.V1DeploymentBuilder> { public V1DeploymentBuilder() { this(false); } + public V1DeploymentBuilder(java.lang.Boolean validationEnabled) { this(new V1Deployment(), validationEnabled); } + public V1DeploymentBuilder(io.kubernetes.client.openapi.models.V1DeploymentFluent fluent) { this(fluent, false); } - public V1DeploymentBuilder(io.kubernetes.client.openapi.models.V1DeploymentFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DeploymentBuilder( + io.kubernetes.client.openapi.models.V1DeploymentFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Deployment(), validationEnabled); } - public V1DeploymentBuilder(io.kubernetes.client.openapi.models.V1DeploymentFluent fluent,io.kubernetes.client.openapi.models.V1Deployment instance) { + + public V1DeploymentBuilder( + io.kubernetes.client.openapi.models.V1DeploymentFluent fluent, + io.kubernetes.client.openapi.models.V1Deployment instance) { this(fluent, instance, false); } - public V1DeploymentBuilder(io.kubernetes.client.openapi.models.V1DeploymentFluent fluent,io.kubernetes.client.openapi.models.V1Deployment instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DeploymentBuilder( + io.kubernetes.client.openapi.models.V1DeploymentFluent fluent, + io.kubernetes.client.openapi.models.V1Deployment instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,17 @@ public V1DeploymentBuilder(io.kubernetes.client.openapi.models.V1DeploymentFluen fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1DeploymentBuilder(io.kubernetes.client.openapi.models.V1Deployment instance) { - this(instance,false); + this(instance, false); } - public V1DeploymentBuilder(io.kubernetes.client.openapi.models.V1Deployment instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DeploymentBuilder( + io.kubernetes.client.openapi.models.V1Deployment instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +78,12 @@ public V1DeploymentBuilder(io.kubernetes.client.openapi.models.V1Deployment inst this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DeploymentFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Deployment build() { V1Deployment buildable = new V1Deployment(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +93,23 @@ public io.kubernetes.client.openapi.models.V1Deployment build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DeploymentBuilder that = (V1DeploymentBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentConditionBuilder.java index b13dbeda44..4d05f9168c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DeploymentConditionBuilder extends io.kubernetes.client.openapi.models.V1DeploymentConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DeploymentConditionBuilder + extends io.kubernetes.client.openapi.models.V1DeploymentConditionFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DeploymentCondition, + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder> { public V1DeploymentConditionBuilder() { this(false); } + public V1DeploymentConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1DeploymentCondition(), validationEnabled); } - public V1DeploymentConditionBuilder(io.kubernetes.client.openapi.models.V1DeploymentConditionFluent fluent) { + + public V1DeploymentConditionBuilder( + io.kubernetes.client.openapi.models.V1DeploymentConditionFluent fluent) { this(fluent, false); } - public V1DeploymentConditionBuilder(io.kubernetes.client.openapi.models.V1DeploymentConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DeploymentConditionBuilder( + io.kubernetes.client.openapi.models.V1DeploymentConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DeploymentCondition(), validationEnabled); } - public V1DeploymentConditionBuilder(io.kubernetes.client.openapi.models.V1DeploymentConditionFluent fluent,io.kubernetes.client.openapi.models.V1DeploymentCondition instance) { + + public V1DeploymentConditionBuilder( + io.kubernetes.client.openapi.models.V1DeploymentConditionFluent fluent, + io.kubernetes.client.openapi.models.V1DeploymentCondition instance) { this(fluent, instance, false); } - public V1DeploymentConditionBuilder(io.kubernetes.client.openapi.models.V1DeploymentConditionFluent fluent,io.kubernetes.client.openapi.models.V1DeploymentCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DeploymentConditionBuilder( + io.kubernetes.client.openapi.models.V1DeploymentConditionFluent fluent, + io.kubernetes.client.openapi.models.V1DeploymentCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withLastUpdateTime(instance.getLastUpdateTime()); @@ -33,13 +60,18 @@ public V1DeploymentConditionBuilder(io.kubernetes.client.openapi.models.V1Deploy fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1DeploymentConditionBuilder(io.kubernetes.client.openapi.models.V1DeploymentCondition instance) { - this(instance,false); + + public V1DeploymentConditionBuilder( + io.kubernetes.client.openapi.models.V1DeploymentCondition instance) { + this(instance, false); } - public V1DeploymentConditionBuilder(io.kubernetes.client.openapi.models.V1DeploymentCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DeploymentConditionBuilder( + io.kubernetes.client.openapi.models.V1DeploymentCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withLastUpdateTime(instance.getLastUpdateTime()); @@ -52,10 +84,12 @@ public V1DeploymentConditionBuilder(io.kubernetes.client.openapi.models.V1Deploy this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DeploymentConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DeploymentCondition build() { V1DeploymentCondition buildable = new V1DeploymentCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1DeploymentCondition build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DeploymentConditionBuilder that = (V1DeploymentConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentConditionFluent.java index d4ef8a30dd..30d28025ba 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentConditionFluent.java @@ -1,57 +1,70 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DeploymentConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1DeploymentConditionFluent< + A extends io.kubernetes.client.openapi.models.V1DeploymentConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.time.OffsetDateTime getLastUpdateTime(); + public A withLastUpdateTime(java.time.OffsetDateTime lastUpdateTime); + public java.lang.Boolean hasLastUpdateTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentConditionFluentImpl.java index f8dd221648..51e518b5a7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentConditionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1DeploymentConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DeploymentConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DeploymentConditionFluent { + public V1DeploymentConditionFluentImpl() {} - /** - * Generated - */ -public class V1DeploymentConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DeploymentConditionFluent{ - public V1DeploymentConditionFluentImpl() { - } - public V1DeploymentConditionFluentImpl(io.kubernetes.client.openapi.models.V1DeploymentCondition instance) { + public V1DeploymentConditionFluentImpl( + io.kubernetes.client.openapi.models.V1DeploymentCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withLastUpdateTime(instance.getLastUpdateTime()); @@ -25,114 +32,136 @@ public V1DeploymentConditionFluentImpl(io.kubernetes.client.openapi.models.V1Dep this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.time.OffsetDateTime lastUpdateTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.time.OffsetDateTime getLastUpdateTime() { return this.lastUpdateTime; } + public A withLastUpdateTime(java.time.OffsetDateTime lastUpdateTime) { - this.lastUpdateTime=lastUpdateTime; return (A) this; + this.lastUpdateTime = lastUpdateTime; + return (A) this; } + public java.lang.Boolean hasLastUpdateTime() { return this.lastUpdateTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1DeploymentConditionFluentImpl that = (V1DeploymentConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (lastUpdateTime != null ? !lastUpdateTime.equals(that.lastUpdateTime) :that.lastUpdateTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (lastUpdateTime != null + ? !lastUpdateTime.equals(that.lastUpdateTime) + : that.lastUpdateTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, lastUpdateTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, lastUpdateTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentFluent.java index a50046d8de..fd895992ed 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentFluent.java @@ -1,93 +1,144 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DeploymentFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1DeploymentFluent< + A extends io.kubernetes.client.openapi.models.V1DeploymentFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DeploymentSpec getSpec(); + public io.kubernetes.client.openapi.models.V1DeploymentSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1DeploymentSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1DeploymentSpec item); + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1DeploymentSpec item); + public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1DeploymentSpec item); - + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1DeploymentSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DeploymentStatus getStatus(); + public io.kubernetes.client.openapi.models.V1DeploymentStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1DeploymentStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1DeploymentStatus item); + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1DeploymentStatus item); + public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1DeploymentStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1DeploymentStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DeploymentSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DeploymentSpecFluent< + io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DeploymentStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DeploymentStatusFluent< + io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentFluentImpl.java index 743bdd0399..d8922f984d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1DeploymentFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DeploymentFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DeploymentFluent { + public V1DeploymentFluentImpl() {} - /** - * Generated - */ -public class V1DeploymentFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DeploymentFluent{ - public V1DeploymentFluentImpl() { - } public V1DeploymentFluentImpl(io.kubernetes.client.openapi.models.V1Deployment instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +29,296 @@ public V1DeploymentFluentImpl(io.kubernetes.client.openapi.models.V1Deployment i this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1DeploymentSpecBuilder spec; private io.kubernetes.client.openapi.models.V1DeploymentStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1DeploymentFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1DeploymentFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DeploymentSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1DeploymentSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1DeploymentSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1DeploymentSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1DeploymentSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1DeploymentFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1DeploymentSpec item) { + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1DeploymentSpec item) { return new io.kubernetes.client.openapi.models.V1DeploymentFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1DeploymentSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1DeploymentSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1DeploymentSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1DeploymentSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DeploymentStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1DeploymentStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1DeploymentStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1DeploymentStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1DeploymentStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1DeploymentFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1DeploymentStatus item) { + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1DeploymentStatus item) { return new io.kubernetes.client.openapi.models.V1DeploymentFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1DeploymentStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1DeploymentStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1DeploymentStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1DeploymentStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1DeploymentFluentImpl that = (V1DeploymentFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1DeploymentFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1DeploymentFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1DeploymentSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1DeploymentSpecFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1DeploymentFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1DeploymentSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1DeploymentSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1DeploymentSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1DeploymentSpecBuilder builder; + public N and() { return (N) V1DeploymentFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1DeploymentStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1DeploymentStatusFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1DeploymentFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1DeploymentStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1DeploymentStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1DeploymentStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1DeploymentStatusBuilder builder; + public N and() { return (N) V1DeploymentFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentListBuilder.java index 5df4168e0e..14c8d6a5b1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DeploymentListBuilder extends io.kubernetes.client.openapi.models.V1DeploymentListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DeploymentListBuilder + extends io.kubernetes.client.openapi.models.V1DeploymentListFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DeploymentList, + io.kubernetes.client.openapi.models.V1DeploymentListBuilder> { public V1DeploymentListBuilder() { this(false); } + public V1DeploymentListBuilder(java.lang.Boolean validationEnabled) { this(new V1DeploymentList(), validationEnabled); } - public V1DeploymentListBuilder(io.kubernetes.client.openapi.models.V1DeploymentListFluent fluent) { + + public V1DeploymentListBuilder( + io.kubernetes.client.openapi.models.V1DeploymentListFluent fluent) { this(fluent, false); } - public V1DeploymentListBuilder(io.kubernetes.client.openapi.models.V1DeploymentListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DeploymentListBuilder( + io.kubernetes.client.openapi.models.V1DeploymentListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DeploymentList(), validationEnabled); } - public V1DeploymentListBuilder(io.kubernetes.client.openapi.models.V1DeploymentListFluent fluent,io.kubernetes.client.openapi.models.V1DeploymentList instance) { + + public V1DeploymentListBuilder( + io.kubernetes.client.openapi.models.V1DeploymentListFluent fluent, + io.kubernetes.client.openapi.models.V1DeploymentList instance) { this(fluent, instance, false); } - public V1DeploymentListBuilder(io.kubernetes.client.openapi.models.V1DeploymentListFluent fluent,io.kubernetes.client.openapi.models.V1DeploymentList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DeploymentListBuilder( + io.kubernetes.client.openapi.models.V1DeploymentListFluent fluent, + io.kubernetes.client.openapi.models.V1DeploymentList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1DeploymentListBuilder(io.kubernetes.client.openapi.models.V1DeploymentL fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1DeploymentListBuilder(io.kubernetes.client.openapi.models.V1DeploymentList instance) { - this(instance,false); + this(instance, false); } - public V1DeploymentListBuilder(io.kubernetes.client.openapi.models.V1DeploymentList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DeploymentListBuilder( + io.kubernetes.client.openapi.models.V1DeploymentList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1DeploymentListBuilder(io.kubernetes.client.openapi.models.V1DeploymentL this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DeploymentListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DeploymentList build() { V1DeploymentList buildable = new V1DeploymentList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1DeploymentList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DeploymentListBuilder that = (V1DeploymentListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentListFluent.java index 36c93905f5..9b8a0051a4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentListFluent.java @@ -1,95 +1,154 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DeploymentListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1DeploymentListFluent< + A extends io.kubernetes.client.openapi.models.V1DeploymentListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Deployment item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Deployment item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Deployment item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Deployment item); + public A addToItems(io.kubernetes.client.openapi.models.V1Deployment... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1Deployment... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1Deployment buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Deployment buildFirstItem(); + public io.kubernetes.client.openapi.models.V1Deployment buildLastItem(); - public io.kubernetes.client.openapi.models.V1Deployment buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Deployment buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1Deployment... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Deployment item); - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Deployment item); - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Deployment item); + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Deployment item); + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DeploymentFluent>{ + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DeploymentFluent< + io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentListFluentImpl.java index 8602c491b9..1de2e8c2ba 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1DeploymentListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DeploymentListFluent{ - public V1DeploymentListFluentImpl() { - } +/** Generated */ +public class V1DeploymentListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DeploymentListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DeploymentListFluent { + public V1DeploymentListFluentImpl() {} + public V1DeploymentListFluentImpl(io.kubernetes.client.openapi.models.V1DeploymentList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,123 @@ public V1DeploymentListFluentImpl(io.kubernetes.client.openapi.models.V1Deployme this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Deployment item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1DeploymentBuilder builder = new io.kubernetes.client.openapi.models.V1DeploymentBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Deployment item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1DeploymentBuilder builder = + new io.kubernetes.client.openapi.models.V1DeploymentBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Deployment item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1DeploymentBuilder builder = new io.kubernetes.client.openapi.models.V1DeploymentBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Deployment item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1DeploymentBuilder builder = + new io.kubernetes.client.openapi.models.V1DeploymentBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1Deployment... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Deployment item : items) {io.kubernetes.client.openapi.models.V1DeploymentBuilder builder = new io.kubernetes.client.openapi.models.V1DeploymentBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Deployment item : items) { + io.kubernetes.client.openapi.models.V1DeploymentBuilder builder = + new io.kubernetes.client.openapi.models.V1DeploymentBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Deployment item : items) {io.kubernetes.client.openapi.models.V1DeploymentBuilder builder = new io.kubernetes.client.openapi.models.V1DeploymentBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Deployment item : items) { + io.kubernetes.client.openapi.models.V1DeploymentBuilder builder = + new io.kubernetes.client.openapi.models.V1DeploymentBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1Deployment... items) { - for (io.kubernetes.client.openapi.models.V1Deployment item : items) {io.kubernetes.client.openapi.models.V1DeploymentBuilder builder = new io.kubernetes.client.openapi.models.V1DeploymentBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Deployment item : items) { + io.kubernetes.client.openapi.models.V1DeploymentBuilder builder = + new io.kubernetes.client.openapi.models.V1DeploymentBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Deployment item : items) {io.kubernetes.client.openapi.models.V1DeploymentBuilder builder = new io.kubernetes.client.openapi.models.V1DeploymentBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Deployment item : items) { + io.kubernetes.client.openapi.models.V1DeploymentBuilder builder = + new io.kubernetes.client.openapi.models.V1DeploymentBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +157,275 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1Deployment buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Deployment buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Deployment buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Deployment buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1DeploymentBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Deployment buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1DeploymentBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1DeploymentBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1DeploymentBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Deployment item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Deployment item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1Deployment... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1Deployment item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1Deployment item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1DeploymentListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Deployment item) { - return new io.kubernetes.client.openapi.models.V1DeploymentListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Deployment item) { + return new io.kubernetes.client.openapi.models.V1DeploymentListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Deployment item) { - return new io.kubernetes.client.openapi.models.V1DeploymentListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Deployment item) { + return new io.kubernetes.client.openapi.models.V1DeploymentListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1DeploymentListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1DeploymentListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1DeploymentListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1DeploymentListFluentImpl that = (V1DeploymentListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1DeploymentFluentImpl> implements io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Deployment item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1DeploymentFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1DeploymentListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Deployment item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1DeploymentBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1DeploymentBuilder(this); } + io.kubernetes.client.openapi.models.V1DeploymentBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1DeploymentListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1DeploymentListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1DeploymentListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1DeploymentListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentSpecBuilder.java index 3e50907280..2a1297bdb1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DeploymentSpecBuilder extends io.kubernetes.client.openapi.models.V1DeploymentSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DeploymentSpecBuilder + extends io.kubernetes.client.openapi.models.V1DeploymentSpecFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DeploymentSpec, + io.kubernetes.client.openapi.models.V1DeploymentSpecBuilder> { public V1DeploymentSpecBuilder() { this(false); } + public V1DeploymentSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1DeploymentSpec(), validationEnabled); } - public V1DeploymentSpecBuilder(io.kubernetes.client.openapi.models.V1DeploymentSpecFluent fluent) { + + public V1DeploymentSpecBuilder( + io.kubernetes.client.openapi.models.V1DeploymentSpecFluent fluent) { this(fluent, false); } - public V1DeploymentSpecBuilder(io.kubernetes.client.openapi.models.V1DeploymentSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DeploymentSpecBuilder( + io.kubernetes.client.openapi.models.V1DeploymentSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DeploymentSpec(), validationEnabled); } - public V1DeploymentSpecBuilder(io.kubernetes.client.openapi.models.V1DeploymentSpecFluent fluent,io.kubernetes.client.openapi.models.V1DeploymentSpec instance) { + + public V1DeploymentSpecBuilder( + io.kubernetes.client.openapi.models.V1DeploymentSpecFluent fluent, + io.kubernetes.client.openapi.models.V1DeploymentSpec instance) { this(fluent, instance, false); } - public V1DeploymentSpecBuilder(io.kubernetes.client.openapi.models.V1DeploymentSpecFluent fluent,io.kubernetes.client.openapi.models.V1DeploymentSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DeploymentSpecBuilder( + io.kubernetes.client.openapi.models.V1DeploymentSpecFluent fluent, + io.kubernetes.client.openapi.models.V1DeploymentSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMinReadySeconds(instance.getMinReadySeconds()); fluent.withPaused(instance.getPaused()); @@ -37,13 +64,17 @@ public V1DeploymentSpecBuilder(io.kubernetes.client.openapi.models.V1DeploymentS fluent.withTemplate(instance.getTemplate()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1DeploymentSpecBuilder(io.kubernetes.client.openapi.models.V1DeploymentSpec instance) { - this(instance,false); + this(instance, false); } - public V1DeploymentSpecBuilder(io.kubernetes.client.openapi.models.V1DeploymentSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DeploymentSpecBuilder( + io.kubernetes.client.openapi.models.V1DeploymentSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMinReadySeconds(instance.getMinReadySeconds()); this.withPaused(instance.getPaused()); @@ -60,10 +91,12 @@ public V1DeploymentSpecBuilder(io.kubernetes.client.openapi.models.V1DeploymentS this.withTemplate(instance.getTemplate()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DeploymentSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DeploymentSpec build() { V1DeploymentSpec buildable = new V1DeploymentSpec(); buildable.setMinReadySeconds(fluent.getMinReadySeconds()); @@ -76,18 +109,23 @@ public io.kubernetes.client.openapi.models.V1DeploymentSpec build() { buildable.setTemplate(fluent.getTemplate()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DeploymentSpecBuilder that = (V1DeploymentSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentSpecFluent.java index c4ab53f93a..d60609df08 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentSpecFluent.java @@ -1,91 +1,162 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DeploymentSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1DeploymentSpecFluent< + A extends io.kubernetes.client.openapi.models.V1DeploymentSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getMinReadySeconds(); + public A withMinReadySeconds(java.lang.Integer minReadySeconds); + public java.lang.Boolean hasMinReadySeconds(); + public java.lang.Boolean getPaused(); + public A withPaused(java.lang.Boolean paused); + public java.lang.Boolean hasPaused(); + public java.lang.Integer getProgressDeadlineSeconds(); + public A withProgressDeadlineSeconds(java.lang.Integer progressDeadlineSeconds); + public java.lang.Boolean hasProgressDeadlineSeconds(); + public java.lang.Integer getReplicas(); + public A withReplicas(java.lang.Integer replicas); + public java.lang.Boolean hasReplicas(); + public java.lang.Integer getRevisionHistoryLimit(); + public A withRevisionHistoryLimit(java.lang.Integer revisionHistoryLimit); + public java.lang.Boolean hasRevisionHistoryLimit(); - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested editSelector(); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested + withNewSelector(); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested + editSelector(); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested + editOrNewSelector(); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + /** * This method has been deprecated, please use method buildStrategy instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DeploymentStrategy getStrategy(); + public io.kubernetes.client.openapi.models.V1DeploymentStrategy buildStrategy(); + public A withStrategy(io.kubernetes.client.openapi.models.V1DeploymentStrategy strategy); + public java.lang.Boolean hasStrategy(); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested withNewStrategy(); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested withNewStrategyLike(io.kubernetes.client.openapi.models.V1DeploymentStrategy item); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested editStrategy(); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested editOrNewStrategy(); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested editOrNewStrategyLike(io.kubernetes.client.openapi.models.V1DeploymentStrategy item); - + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested + withNewStrategy(); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested + withNewStrategyLike(io.kubernetes.client.openapi.models.V1DeploymentStrategy item); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested + editStrategy(); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested + editOrNewStrategy(); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested + editOrNewStrategyLike(io.kubernetes.client.openapi.models.V1DeploymentStrategy item); + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate(); + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate(); + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template); + public java.lang.Boolean hasTemplate(); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested withNewTemplate(); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested editTemplate(); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested editOrNewTemplate(); - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested + withNewTemplate(); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested + withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested + editTemplate(); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested + editOrNewTemplate(); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested> { public N and(); + public N endSelector(); - } - public interface StrategyNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent>{ + + public interface StrategyNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent< + io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested> { public N and(); + public N endStrategy(); - } - public interface TemplateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent>{ + + public interface TemplateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent< + io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested> { public N and(); + public N endTemplate(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentSpecFluentImpl.java index ba68030439..7481b5b225 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentSpecFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1DeploymentSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DeploymentSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DeploymentSpecFluent { + public V1DeploymentSpecFluentImpl() {} - /** - * Generated - */ -public class V1DeploymentSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DeploymentSpecFluent{ - public V1DeploymentSpecFluentImpl() { - } public V1DeploymentSpecFluentImpl(io.kubernetes.client.openapi.models.V1DeploymentSpec instance) { this.withMinReadySeconds(instance.getMinReadySeconds()); @@ -29,8 +35,8 @@ public V1DeploymentSpecFluentImpl(io.kubernetes.client.openapi.models.V1Deployme this.withStrategy(instance.getStrategy()); this.withTemplate(instance.getTemplate()); - } + private java.lang.Integer minReadySeconds; private java.lang.Boolean paused; private java.lang.Integer progressDeadlineSeconds; @@ -39,217 +45,344 @@ public V1DeploymentSpecFluentImpl(io.kubernetes.client.openapi.models.V1Deployme private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder selector; private io.kubernetes.client.openapi.models.V1DeploymentStrategyBuilder strategy; private io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder template; + public java.lang.Integer getMinReadySeconds() { return this.minReadySeconds; } + public A withMinReadySeconds(java.lang.Integer minReadySeconds) { - this.minReadySeconds=minReadySeconds; return (A) this; + this.minReadySeconds = minReadySeconds; + return (A) this; } + public java.lang.Boolean hasMinReadySeconds() { return this.minReadySeconds != null; } + public java.lang.Boolean getPaused() { return this.paused; } + public A withPaused(java.lang.Boolean paused) { - this.paused=paused; return (A) this; + this.paused = paused; + return (A) this; } + public java.lang.Boolean hasPaused() { return this.paused != null; } + public java.lang.Integer getProgressDeadlineSeconds() { return this.progressDeadlineSeconds; } + public A withProgressDeadlineSeconds(java.lang.Integer progressDeadlineSeconds) { - this.progressDeadlineSeconds=progressDeadlineSeconds; return (A) this; + this.progressDeadlineSeconds = progressDeadlineSeconds; + return (A) this; } + public java.lang.Boolean hasProgressDeadlineSeconds() { return this.progressDeadlineSeconds != null; } + public java.lang.Integer getReplicas() { return this.replicas; } + public A withReplicas(java.lang.Integer replicas) { - this.replicas=replicas; return (A) this; + this.replicas = replicas; + return (A) this; } + public java.lang.Boolean hasReplicas() { return this.replicas != null; } + public java.lang.Integer getRevisionHistoryLimit() { return this.revisionHistoryLimit; } + public A withRevisionHistoryLimit(java.lang.Integer revisionHistoryLimit) { - this.revisionHistoryLimit=revisionHistoryLimit; return (A) this; + this.revisionHistoryLimit = revisionHistoryLimit; + return (A) this; } + public java.lang.Boolean hasRevisionHistoryLimit() { return this.revisionHistoryLimit != null; } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested withNewSelector() { + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested + withNewSelector() { return new io.kubernetes.client.openapi.models.V1DeploymentSpecFluentImpl.SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1DeploymentSpecFluentImpl.SelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1DeploymentSpecFluentImpl.SelectorNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested editSelector() { + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested + editSelector() { return withNewSelectorLike(getSelector()); } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested + editOrNewSelector() { + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } - + /** * This method has been deprecated, please use method buildStrategy instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DeploymentStrategy getStrategy() { - return this.strategy!=null ?this.strategy.build():null; + return this.strategy != null ? this.strategy.build() : null; } + public io.kubernetes.client.openapi.models.V1DeploymentStrategy buildStrategy() { - return this.strategy!=null ?this.strategy.build():null; + return this.strategy != null ? this.strategy.build() : null; } + public A withStrategy(io.kubernetes.client.openapi.models.V1DeploymentStrategy strategy) { _visitables.get("strategy").remove(this.strategy); - if (strategy!=null){ this.strategy= new io.kubernetes.client.openapi.models.V1DeploymentStrategyBuilder(strategy); _visitables.get("strategy").add(this.strategy);} return (A) this; + if (strategy != null) { + this.strategy = new io.kubernetes.client.openapi.models.V1DeploymentStrategyBuilder(strategy); + _visitables.get("strategy").add(this.strategy); + } + return (A) this; } + public java.lang.Boolean hasStrategy() { return this.strategy != null; } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested withNewStrategy() { + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested + withNewStrategy() { return new io.kubernetes.client.openapi.models.V1DeploymentSpecFluentImpl.StrategyNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested withNewStrategyLike(io.kubernetes.client.openapi.models.V1DeploymentStrategy item) { - return new io.kubernetes.client.openapi.models.V1DeploymentSpecFluentImpl.StrategyNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested + withNewStrategyLike(io.kubernetes.client.openapi.models.V1DeploymentStrategy item) { + return new io.kubernetes.client.openapi.models.V1DeploymentSpecFluentImpl.StrategyNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested editStrategy() { + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested + editStrategy() { return withNewStrategyLike(getStrategy()); } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested editOrNewStrategy() { - return withNewStrategyLike(getStrategy() != null ? getStrategy(): new io.kubernetes.client.openapi.models.V1DeploymentStrategyBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested + editOrNewStrategy() { + return withNewStrategyLike( + getStrategy() != null + ? getStrategy() + : new io.kubernetes.client.openapi.models.V1DeploymentStrategyBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested editOrNewStrategyLike(io.kubernetes.client.openapi.models.V1DeploymentStrategy item) { - return withNewStrategyLike(getStrategy() != null ? getStrategy(): item); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested + editOrNewStrategyLike(io.kubernetes.client.openapi.models.V1DeploymentStrategy item) { + return withNewStrategyLike(getStrategy() != null ? getStrategy() : item); } - + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template) { _visitables.get("template").remove(this.template); - if (template!=null){ this.template= new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); _visitables.get("template").add(this.template);} return (A) this; + if (template != null) { + this.template = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); + _visitables.get("template").add(this.template); + } + return (A) this; } + public java.lang.Boolean hasTemplate() { return this.template != null; } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested withNewTemplate() { + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested + withNewTemplate() { return new io.kubernetes.client.openapi.models.V1DeploymentSpecFluentImpl.TemplateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { - return new io.kubernetes.client.openapi.models.V1DeploymentSpecFluentImpl.TemplateNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested + withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + return new io.kubernetes.client.openapi.models.V1DeploymentSpecFluentImpl.TemplateNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested editTemplate() { + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested + editTemplate() { return withNewTemplateLike(getTemplate()); } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested editOrNewTemplate() { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested + editOrNewTemplate() { + return withNewTemplateLike( + getTemplate() != null + ? getTemplate() + : new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): item); + + public io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + return withNewTemplateLike(getTemplate() != null ? getTemplate() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1DeploymentSpecFluentImpl that = (V1DeploymentSpecFluentImpl) o; - if (minReadySeconds != null ? !minReadySeconds.equals(that.minReadySeconds) :that.minReadySeconds != null) return false; - if (paused != null ? !paused.equals(that.paused) :that.paused != null) return false; - if (progressDeadlineSeconds != null ? !progressDeadlineSeconds.equals(that.progressDeadlineSeconds) :that.progressDeadlineSeconds != null) return false; - if (replicas != null ? !replicas.equals(that.replicas) :that.replicas != null) return false; - if (revisionHistoryLimit != null ? !revisionHistoryLimit.equals(that.revisionHistoryLimit) :that.revisionHistoryLimit != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; - if (strategy != null ? !strategy.equals(that.strategy) :that.strategy != null) return false; - if (template != null ? !template.equals(that.template) :that.template != null) return false; + if (minReadySeconds != null + ? !minReadySeconds.equals(that.minReadySeconds) + : that.minReadySeconds != null) return false; + if (paused != null ? !paused.equals(that.paused) : that.paused != null) return false; + if (progressDeadlineSeconds != null + ? !progressDeadlineSeconds.equals(that.progressDeadlineSeconds) + : that.progressDeadlineSeconds != null) return false; + if (replicas != null ? !replicas.equals(that.replicas) : that.replicas != null) return false; + if (revisionHistoryLimit != null + ? !revisionHistoryLimit.equals(that.revisionHistoryLimit) + : that.revisionHistoryLimit != null) return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; + if (strategy != null ? !strategy.equals(that.strategy) : that.strategy != null) return false; + if (template != null ? !template.equals(that.template) : that.template != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(minReadySeconds, paused, progressDeadlineSeconds, replicas, revisionHistoryLimit, selector, strategy, template, super.hashCode()); + return java.util.Objects.hash( + minReadySeconds, + paused, + progressDeadlineSeconds, + replicas, + revisionHistoryLimit, + selector, + strategy, + template, + super.hashCode()); } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested> + implements io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.SelectorNested, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1DeploymentSpecFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - public class StrategyNestedImpl extends io.kubernetes.client.openapi.models.V1DeploymentStrategyFluentImpl> implements io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested,io.kubernetes.client.fluent.Nested{ + + public class StrategyNestedImpl + extends io.kubernetes.client.openapi.models.V1DeploymentStrategyFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested> + implements io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.StrategyNested, + io.kubernetes.client.fluent.Nested { StrategyNestedImpl(io.kubernetes.client.openapi.models.V1DeploymentStrategy item) { - this.builder = new io.kubernetes.client.openapi.models.V1DeploymentStrategyBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1DeploymentStrategyBuilder(this, item); } + StrategyNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1DeploymentStrategyBuilder(this); } + io.kubernetes.client.openapi.models.V1DeploymentStrategyBuilder builder; + public N and() { return (N) V1DeploymentSpecFluentImpl.this.withStrategy(builder.build()); } + public N endStrategy() { return and(); } - } - public class TemplateNestedImpl extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested,io.kubernetes.client.fluent.Nested{ + + public class TemplateNestedImpl + extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested> + implements io.kubernetes.client.openapi.models.V1DeploymentSpecFluent.TemplateNested, + io.kubernetes.client.fluent.Nested { TemplateNestedImpl(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this, item); } + TemplateNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder builder; + public N and() { return (N) V1DeploymentSpecFluentImpl.this.withTemplate(builder.build()); } + public N endTemplate() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStatusBuilder.java index fc2f613ed7..46cb51b13b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DeploymentStatusBuilder extends io.kubernetes.client.openapi.models.V1DeploymentStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DeploymentStatusBuilder + extends io.kubernetes.client.openapi.models.V1DeploymentStatusFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DeploymentStatus, + io.kubernetes.client.openapi.models.V1DeploymentStatusBuilder> { public V1DeploymentStatusBuilder() { this(false); } + public V1DeploymentStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1DeploymentStatus(), validationEnabled); } - public V1DeploymentStatusBuilder(io.kubernetes.client.openapi.models.V1DeploymentStatusFluent fluent) { + + public V1DeploymentStatusBuilder( + io.kubernetes.client.openapi.models.V1DeploymentStatusFluent fluent) { this(fluent, false); } - public V1DeploymentStatusBuilder(io.kubernetes.client.openapi.models.V1DeploymentStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DeploymentStatusBuilder( + io.kubernetes.client.openapi.models.V1DeploymentStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DeploymentStatus(), validationEnabled); } - public V1DeploymentStatusBuilder(io.kubernetes.client.openapi.models.V1DeploymentStatusFluent fluent,io.kubernetes.client.openapi.models.V1DeploymentStatus instance) { + + public V1DeploymentStatusBuilder( + io.kubernetes.client.openapi.models.V1DeploymentStatusFluent fluent, + io.kubernetes.client.openapi.models.V1DeploymentStatus instance) { this(fluent, instance, false); } - public V1DeploymentStatusBuilder(io.kubernetes.client.openapi.models.V1DeploymentStatusFluent fluent,io.kubernetes.client.openapi.models.V1DeploymentStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DeploymentStatusBuilder( + io.kubernetes.client.openapi.models.V1DeploymentStatusFluent fluent, + io.kubernetes.client.openapi.models.V1DeploymentStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAvailableReplicas(instance.getAvailableReplicas()); fluent.withCollisionCount(instance.getCollisionCount()); @@ -37,13 +64,18 @@ public V1DeploymentStatusBuilder(io.kubernetes.client.openapi.models.V1Deploymen fluent.withUpdatedReplicas(instance.getUpdatedReplicas()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1DeploymentStatusBuilder(io.kubernetes.client.openapi.models.V1DeploymentStatus instance) { - this(instance,false); + + public V1DeploymentStatusBuilder( + io.kubernetes.client.openapi.models.V1DeploymentStatus instance) { + this(instance, false); } - public V1DeploymentStatusBuilder(io.kubernetes.client.openapi.models.V1DeploymentStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DeploymentStatusBuilder( + io.kubernetes.client.openapi.models.V1DeploymentStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAvailableReplicas(instance.getAvailableReplicas()); this.withCollisionCount(instance.getCollisionCount()); @@ -60,10 +92,12 @@ public V1DeploymentStatusBuilder(io.kubernetes.client.openapi.models.V1Deploymen this.withUpdatedReplicas(instance.getUpdatedReplicas()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DeploymentStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DeploymentStatus build() { V1DeploymentStatus buildable = new V1DeploymentStatus(); buildable.setAvailableReplicas(fluent.getAvailableReplicas()); @@ -76,18 +110,23 @@ public io.kubernetes.client.openapi.models.V1DeploymentStatus build() { buildable.setUpdatedReplicas(fluent.getUpdatedReplicas()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DeploymentStatusBuilder that = (V1DeploymentStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStatusFluent.java index 8a4bbcc580..8b925fab5c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStatusFluent.java @@ -1,79 +1,147 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Long; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DeploymentStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1DeploymentStatusFluent< + A extends io.kubernetes.client.openapi.models.V1DeploymentStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getAvailableReplicas(); + public A withAvailableReplicas(java.lang.Integer availableReplicas); + public java.lang.Boolean hasAvailableReplicas(); + public java.lang.Integer getCollisionCount(); + public A withCollisionCount(java.lang.Integer collisionCount); + public java.lang.Boolean hasCollisionCount(); - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DeploymentCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DeploymentCondition item); + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DeploymentCondition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DeploymentCondition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1DeploymentCondition... items); - public A addAllToConditions(java.util.Collection items); + + public A addAllToConditions( + java.util.Collection items); + public A removeFromConditions(io.kubernetes.client.openapi.models.V1DeploymentCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1DeploymentCondition buildCondition(java.lang.Integer index); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V1DeploymentCondition buildCondition( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1DeploymentCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1DeploymentCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1DeploymentCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); + + public io.kubernetes.client.openapi.models.V1DeploymentCondition buildMatchingCondition( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate); + + public A withConditions( + java.util.List conditions); + public A withConditions(io.kubernetes.client.openapi.models.V1DeploymentCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1DeploymentCondition item); - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DeploymentCondition item); - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1DeploymentCondition item); + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DeploymentCondition item); + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder> + predicate); + public java.lang.Long getObservedGeneration(); + public A withObservedGeneration(java.lang.Long observedGeneration); + public java.lang.Boolean hasObservedGeneration(); + public java.lang.Integer getReadyReplicas(); + public A withReadyReplicas(java.lang.Integer readyReplicas); + public java.lang.Boolean hasReadyReplicas(); + public java.lang.Integer getReplicas(); + public A withReplicas(java.lang.Integer replicas); + public java.lang.Boolean hasReplicas(); + public java.lang.Integer getUnavailableReplicas(); + public A withUnavailableReplicas(java.lang.Integer unavailableReplicas); + public java.lang.Boolean hasUnavailableReplicas(); + public java.lang.Integer getUpdatedReplicas(); + public A withUpdatedReplicas(java.lang.Integer updatedReplicas); + public java.lang.Boolean hasUpdatedReplicas(); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DeploymentConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DeploymentConditionFluent< + io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStatusFluentImpl.java index ece5fb1ccd..25ae841390 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStatusFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1DeploymentStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DeploymentStatusFluent{ - public V1DeploymentStatusFluentImpl() { - } - public V1DeploymentStatusFluentImpl(io.kubernetes.client.openapi.models.V1DeploymentStatus instance) { +/** Generated */ +public class V1DeploymentStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DeploymentStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DeploymentStatusFluent { + public V1DeploymentStatusFluentImpl() {} + + public V1DeploymentStatusFluentImpl( + io.kubernetes.client.openapi.models.V1DeploymentStatus instance) { this.withAvailableReplicas(instance.getAvailableReplicas()); this.withCollisionCount(instance.getCollisionCount()); @@ -36,62 +39,145 @@ public V1DeploymentStatusFluentImpl(io.kubernetes.client.openapi.models.V1Deploy this.withUnavailableReplicas(instance.getUnavailableReplicas()); this.withUpdatedReplicas(instance.getUpdatedReplicas()); - } + private java.lang.Integer availableReplicas; private java.lang.Integer collisionCount; - private java.util.ArrayList conditions; + private java.util.ArrayList + conditions; private java.lang.Long observedGeneration; private java.lang.Integer readyReplicas; private java.lang.Integer replicas; private java.lang.Integer unavailableReplicas; private java.lang.Integer updatedReplicas; + public java.lang.Integer getAvailableReplicas() { return this.availableReplicas; } + public A withAvailableReplicas(java.lang.Integer availableReplicas) { - this.availableReplicas=availableReplicas; return (A) this; + this.availableReplicas = availableReplicas; + return (A) this; } + public java.lang.Boolean hasAvailableReplicas() { return this.availableReplicas != null; } + public java.lang.Integer getCollisionCount() { return this.collisionCount; } + public A withCollisionCount(java.lang.Integer collisionCount) { - this.collisionCount=collisionCount; return (A) this; + this.collisionCount = collisionCount; + return (A) this; } + public java.lang.Boolean hasCollisionCount() { return this.collisionCount != null; } - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DeploymentCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder = new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DeploymentCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DeploymentCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder = new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DeploymentCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } + public A addToConditions(io.kubernetes.client.openapi.models.V1DeploymentCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1DeploymentCondition item : items) {io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder = new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1DeploymentCondition item : items) { + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1DeploymentCondition item : items) {io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder = new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1DeploymentCondition item : items) { + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V1DeploymentCondition... items) { - for (io.kubernetes.client.openapi.models.V1DeploymentCondition item : items) {io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder = new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1DeploymentCondition... items) { + for (io.kubernetes.client.openapi.models.V1DeploymentCondition item : items) { + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1DeploymentCondition item : items) {io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder = new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1DeploymentCondition item : items) { + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder = each.next(); @@ -100,156 +186,279 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1DeploymentCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1DeploymentCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1DeploymentCondition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1DeploymentCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1DeploymentCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1DeploymentCondition buildMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1DeploymentCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1DeploymentCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } + public A withConditions(io.kubernetes.client.openapi.models.V1DeploymentCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1DeploymentCondition item :conditions){ this.addToConditions(item);}} return (A) this; + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1DeploymentCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1DeploymentStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1DeploymentStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1DeploymentCondition item) { - return new io.kubernetes.client.openapi.models.V1DeploymentStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1DeploymentCondition item) { + return new io.kubernetes.client.openapi.models.V1DeploymentStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DeploymentCondition item) { - return new io.kubernetes.client.openapi.models.V1DeploymentStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DeploymentCondition item) { + return new io.kubernetes.client.openapi.models.V1DeploymentStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1DeploymentConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DeploymentCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1DeploymentConditionFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1DeploymentStatusFluent.ConditionsNested, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DeploymentCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1DeploymentConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1DeploymentStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1DeploymentStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStrategyBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStrategyBuilder.java index 325c59c95d..6485c8fb80 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStrategyBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStrategyBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DeploymentStrategyBuilder extends io.kubernetes.client.openapi.models.V1DeploymentStrategyFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DeploymentStrategyBuilder + extends io.kubernetes.client.openapi.models.V1DeploymentStrategyFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentStrategyBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DeploymentStrategy, + io.kubernetes.client.openapi.models.V1DeploymentStrategyBuilder> { public V1DeploymentStrategyBuilder() { this(false); } + public V1DeploymentStrategyBuilder(java.lang.Boolean validationEnabled) { this(new V1DeploymentStrategy(), validationEnabled); } - public V1DeploymentStrategyBuilder(io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent fluent) { + + public V1DeploymentStrategyBuilder( + io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent fluent) { this(fluent, false); } - public V1DeploymentStrategyBuilder(io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DeploymentStrategyBuilder( + io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DeploymentStrategy(), validationEnabled); } - public V1DeploymentStrategyBuilder(io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent fluent,io.kubernetes.client.openapi.models.V1DeploymentStrategy instance) { + + public V1DeploymentStrategyBuilder( + io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent fluent, + io.kubernetes.client.openapi.models.V1DeploymentStrategy instance) { this(fluent, instance, false); } - public V1DeploymentStrategyBuilder(io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent fluent,io.kubernetes.client.openapi.models.V1DeploymentStrategy instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DeploymentStrategyBuilder( + io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent fluent, + io.kubernetes.client.openapi.models.V1DeploymentStrategy instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withRollingUpdate(instance.getRollingUpdate()); fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1DeploymentStrategyBuilder(io.kubernetes.client.openapi.models.V1DeploymentStrategy instance) { - this(instance,false); + + public V1DeploymentStrategyBuilder( + io.kubernetes.client.openapi.models.V1DeploymentStrategy instance) { + this(instance, false); } - public V1DeploymentStrategyBuilder(io.kubernetes.client.openapi.models.V1DeploymentStrategy instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DeploymentStrategyBuilder( + io.kubernetes.client.openapi.models.V1DeploymentStrategy instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withRollingUpdate(instance.getRollingUpdate()); this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DeploymentStrategy build() { V1DeploymentStrategy buildable = new V1DeploymentStrategy(); buildable.setRollingUpdate(fluent.getRollingUpdate()); buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DeploymentStrategyBuilder that = (V1DeploymentStrategyBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStrategyFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStrategyFluent.java index b2039ca8ef..075432feb7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStrategyFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStrategyFluent.java @@ -1,38 +1,66 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DeploymentStrategyFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1DeploymentStrategyFluent< + A extends io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildRollingUpdate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RollingUpdateDeployment getRollingUpdate(); + public io.kubernetes.client.openapi.models.V1RollingUpdateDeployment buildRollingUpdate(); - public A withRollingUpdate(io.kubernetes.client.openapi.models.V1RollingUpdateDeployment rollingUpdate); + + public A withRollingUpdate( + io.kubernetes.client.openapi.models.V1RollingUpdateDeployment rollingUpdate); + public java.lang.Boolean hasRollingUpdate(); - public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested withNewRollingUpdate(); - public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested withNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateDeployment item); - public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested editRollingUpdate(); - public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested editOrNewRollingUpdate(); - public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested editOrNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateDeployment item); + + public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested + withNewRollingUpdate(); + + public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested + withNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateDeployment item); + + public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested + editRollingUpdate(); + + public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested + editOrNewRollingUpdate(); + + public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested + editOrNewRollingUpdateLike( + io.kubernetes.client.openapi.models.V1RollingUpdateDeployment item); + public io.kubernetes.client.openapi.models.V1DeploymentStrategy.TypeEnum getType(); + public A withType(io.kubernetes.client.openapi.models.V1DeploymentStrategy.TypeEnum type); + public java.lang.Boolean hasType(); - public interface RollingUpdateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent>{ + + public interface RollingUpdateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent< + io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested< + N>> { public N and(); + public N endRollingUpdate(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStrategyFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStrategyFluentImpl.java index f2a80fe128..e46a5060ed 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStrategyFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DeploymentStrategyFluentImpl.java @@ -1,94 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1DeploymentStrategyFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent { + public V1DeploymentStrategyFluentImpl() {} - /** - * Generated - */ -public class V1DeploymentStrategyFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent{ - public V1DeploymentStrategyFluentImpl() { - } - public V1DeploymentStrategyFluentImpl(io.kubernetes.client.openapi.models.V1DeploymentStrategy instance) { + public V1DeploymentStrategyFluentImpl( + io.kubernetes.client.openapi.models.V1DeploymentStrategy instance) { this.withRollingUpdate(instance.getRollingUpdate()); this.withType(instance.getType()); - } + private io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentBuilder rollingUpdate; private io.kubernetes.client.openapi.models.V1DeploymentStrategy.TypeEnum type; - + /** * This method has been deprecated, please use method buildRollingUpdate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RollingUpdateDeployment getRollingUpdate() { - return this.rollingUpdate!=null ?this.rollingUpdate.build():null; + return this.rollingUpdate != null ? this.rollingUpdate.build() : null; } + public io.kubernetes.client.openapi.models.V1RollingUpdateDeployment buildRollingUpdate() { - return this.rollingUpdate!=null ?this.rollingUpdate.build():null; + return this.rollingUpdate != null ? this.rollingUpdate.build() : null; } - public A withRollingUpdate(io.kubernetes.client.openapi.models.V1RollingUpdateDeployment rollingUpdate) { + + public A withRollingUpdate( + io.kubernetes.client.openapi.models.V1RollingUpdateDeployment rollingUpdate) { _visitables.get("rollingUpdate").remove(this.rollingUpdate); - if (rollingUpdate!=null){ this.rollingUpdate= new io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentBuilder(rollingUpdate); _visitables.get("rollingUpdate").add(this.rollingUpdate);} return (A) this; + if (rollingUpdate != null) { + this.rollingUpdate = + new io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentBuilder(rollingUpdate); + _visitables.get("rollingUpdate").add(this.rollingUpdate); + } + return (A) this; } + public java.lang.Boolean hasRollingUpdate() { return this.rollingUpdate != null; } - public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested withNewRollingUpdate() { - return new io.kubernetes.client.openapi.models.V1DeploymentStrategyFluentImpl.RollingUpdateNestedImpl(); + + public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested + withNewRollingUpdate() { + return new io.kubernetes.client.openapi.models.V1DeploymentStrategyFluentImpl + .RollingUpdateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested withNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateDeployment item) { - return new io.kubernetes.client.openapi.models.V1DeploymentStrategyFluentImpl.RollingUpdateNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested + withNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateDeployment item) { + return new io.kubernetes.client.openapi.models.V1DeploymentStrategyFluentImpl + .RollingUpdateNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested editRollingUpdate() { + + public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested + editRollingUpdate() { return withNewRollingUpdateLike(getRollingUpdate()); } - public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested editOrNewRollingUpdate() { - return withNewRollingUpdateLike(getRollingUpdate() != null ? getRollingUpdate(): new io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested + editOrNewRollingUpdate() { + return withNewRollingUpdateLike( + getRollingUpdate() != null + ? getRollingUpdate() + : new io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested editOrNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateDeployment item) { - return withNewRollingUpdateLike(getRollingUpdate() != null ? getRollingUpdate(): item); + + public io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested + editOrNewRollingUpdateLike( + io.kubernetes.client.openapi.models.V1RollingUpdateDeployment item) { + return withNewRollingUpdateLike(getRollingUpdate() != null ? getRollingUpdate() : item); } + public io.kubernetes.client.openapi.models.V1DeploymentStrategy.TypeEnum getType() { return this.type; } + public A withType(io.kubernetes.client.openapi.models.V1DeploymentStrategy.TypeEnum type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1DeploymentStrategyFluentImpl that = (V1DeploymentStrategyFluentImpl) o; - if (rollingUpdate != null ? !rollingUpdate.equals(that.rollingUpdate) :that.rollingUpdate != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (rollingUpdate != null + ? !rollingUpdate.equals(that.rollingUpdate) + : that.rollingUpdate != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(rollingUpdate, type, super.hashCode()); + return java.util.Objects.hash(rollingUpdate, type, super.hashCode()); } - public class RollingUpdateNestedImpl extends io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluentImpl> implements io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested,io.kubernetes.client.fluent.Nested{ + + public class RollingUpdateNestedImpl + extends io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluentImpl< + io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested> + implements io.kubernetes.client.openapi.models.V1DeploymentStrategyFluent.RollingUpdateNested< + N>, + io.kubernetes.client.fluent.Nested { RollingUpdateNestedImpl(io.kubernetes.client.openapi.models.V1RollingUpdateDeployment item) { - this.builder = new io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentBuilder(this, item); } + RollingUpdateNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentBuilder(this); } + io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentBuilder builder; + public N and() { return (N) V1DeploymentStrategyFluentImpl.this.withRollingUpdate(builder.build()); } + public N endRollingUpdate() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIProjectionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIProjectionBuilder.java index f2e64f78ae..6dcc0fa29c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIProjectionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIProjectionBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DownwardAPIProjectionBuilder extends io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DownwardAPIProjectionBuilder + extends io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluentImpl< + io.kubernetes.client.openapi.models.V1DownwardAPIProjectionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DownwardAPIProjection, + io.kubernetes.client.openapi.models.V1DownwardAPIProjectionBuilder> { public V1DownwardAPIProjectionBuilder() { this(false); } + public V1DownwardAPIProjectionBuilder(java.lang.Boolean validationEnabled) { this(new V1DownwardAPIProjection(), validationEnabled); } - public V1DownwardAPIProjectionBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent fluent) { + + public V1DownwardAPIProjectionBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent fluent) { this(fluent, false); } - public V1DownwardAPIProjectionBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DownwardAPIProjectionBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DownwardAPIProjection(), validationEnabled); } - public V1DownwardAPIProjectionBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent fluent,io.kubernetes.client.openapi.models.V1DownwardAPIProjection instance) { + + public V1DownwardAPIProjectionBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent fluent, + io.kubernetes.client.openapi.models.V1DownwardAPIProjection instance) { this(fluent, instance, false); } - public V1DownwardAPIProjectionBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent fluent,io.kubernetes.client.openapi.models.V1DownwardAPIProjection instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DownwardAPIProjectionBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent fluent, + io.kubernetes.client.openapi.models.V1DownwardAPIProjection instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withItems(instance.getItems()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1DownwardAPIProjectionBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIProjection instance) { - this(instance,false); + + public V1DownwardAPIProjectionBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIProjection instance) { + this(instance, false); } - public V1DownwardAPIProjectionBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIProjection instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DownwardAPIProjectionBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIProjection instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withItems(instance.getItems()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DownwardAPIProjection build() { V1DownwardAPIProjection buildable = new V1DownwardAPIProjection(); buildable.setItems(fluent.getItems()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DownwardAPIProjectionBuilder that = (V1DownwardAPIProjectionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIProjectionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIProjectionFluent.java index 7002a6227c..deda9ca50a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIProjectionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIProjectionFluent.java @@ -1,57 +1,108 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DownwardAPIProjectionFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); +/** Generated */ +public interface V1DownwardAPIProjectionFluent< + A extends io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); + public A addToItems(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildFirstItem(); + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildLastItem(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent>{ + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent< + io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested> { public N and(); + public N endItem(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIProjectionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIProjectionFluentImpl.java index f4fa2ccc45..5c163dc6e6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIProjectionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIProjectionFluentImpl.java @@ -1,57 +1,134 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1DownwardAPIProjectionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent{ - public V1DownwardAPIProjectionFluentImpl() { - } - public V1DownwardAPIProjectionFluentImpl(io.kubernetes.client.openapi.models.V1DownwardAPIProjection instance) { - this.withItems(instance.getItems()); +/** Generated */ +public class V1DownwardAPIProjectionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent { + public V1DownwardAPIProjectionFluentImpl() {} + public V1DownwardAPIProjectionFluentImpl( + io.kubernetes.client.openapi.models.V1DownwardAPIProjection instance) { + this.withItems(instance.getItems()); } - private java.util.ArrayList items; - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + private java.util.ArrayList + items; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder>(); + } + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder>(); + } + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) {io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) { + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) {io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) { + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile... items) { - for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) {io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) { + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) {io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) { + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = each.next(); @@ -60,104 +137,185 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { - return new io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { + return new io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { - return new io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { + return new io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl> implements io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl< + io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(this); } + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1DownwardAPIProjectionFluentImpl.this.setToItems(index,builder.build()); + return (N) V1DownwardAPIProjectionFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeFileBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeFileBuilder.java index a097286e2d..4ebef501f9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeFileBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeFileBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DownwardAPIVolumeFileBuilder extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DownwardAPIVolumeFileBuilder + extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile, + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> { public V1DownwardAPIVolumeFileBuilder() { this(false); } + public V1DownwardAPIVolumeFileBuilder(java.lang.Boolean validationEnabled) { this(new V1DownwardAPIVolumeFile(), validationEnabled); } - public V1DownwardAPIVolumeFileBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent fluent) { + + public V1DownwardAPIVolumeFileBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent fluent) { this(fluent, false); } - public V1DownwardAPIVolumeFileBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DownwardAPIVolumeFileBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DownwardAPIVolumeFile(), validationEnabled); } - public V1DownwardAPIVolumeFileBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent fluent,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile instance) { + + public V1DownwardAPIVolumeFileBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent fluent, + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile instance) { this(fluent, instance, false); } - public V1DownwardAPIVolumeFileBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent fluent,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DownwardAPIVolumeFileBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent fluent, + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFieldRef(instance.getFieldRef()); fluent.withMode(instance.getMode()); @@ -29,13 +56,18 @@ public V1DownwardAPIVolumeFileBuilder(io.kubernetes.client.openapi.models.V1Down fluent.withResourceFieldRef(instance.getResourceFieldRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1DownwardAPIVolumeFileBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile instance) { - this(instance,false); + + public V1DownwardAPIVolumeFileBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile instance) { + this(instance, false); } - public V1DownwardAPIVolumeFileBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DownwardAPIVolumeFileBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFieldRef(instance.getFieldRef()); this.withMode(instance.getMode()); @@ -44,10 +76,12 @@ public V1DownwardAPIVolumeFileBuilder(io.kubernetes.client.openapi.models.V1Down this.withResourceFieldRef(instance.getResourceFieldRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile build() { V1DownwardAPIVolumeFile buildable = new V1DownwardAPIVolumeFile(); buildable.setFieldRef(fluent.getFieldRef()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile build() { buildable.setResourceFieldRef(fluent.getResourceFieldRef()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DownwardAPIVolumeFileBuilder that = (V1DownwardAPIVolumeFileBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeFileFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeFileFluent.java index e40b8ae75e..7e7ab31c5e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeFileFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeFileFluent.java @@ -1,68 +1,115 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DownwardAPIVolumeFileFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1DownwardAPIVolumeFileFluent< + A extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildFieldRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectFieldSelector getFieldRef(); + public io.kubernetes.client.openapi.models.V1ObjectFieldSelector buildFieldRef(); + public A withFieldRef(io.kubernetes.client.openapi.models.V1ObjectFieldSelector fieldRef); + public java.lang.Boolean hasFieldRef(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested withNewFieldRef(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested withNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested editFieldRef(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested editOrNewFieldRef(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested editOrNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested + withNewFieldRef(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested + withNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested + editFieldRef(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested + editOrNewFieldRef(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested + editOrNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item); + public java.lang.Integer getMode(); + public A withMode(java.lang.Integer mode); + public java.lang.Boolean hasMode(); + public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); - + /** * This method has been deprecated, please use method buildResourceFieldRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceFieldSelector getResourceFieldRef(); + public io.kubernetes.client.openapi.models.V1ResourceFieldSelector buildResourceFieldRef(); - public A withResourceFieldRef(io.kubernetes.client.openapi.models.V1ResourceFieldSelector resourceFieldRef); + + public A withResourceFieldRef( + io.kubernetes.client.openapi.models.V1ResourceFieldSelector resourceFieldRef); + public java.lang.Boolean hasResourceFieldRef(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested withNewResourceFieldRef(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested withNewResourceFieldRefLike(io.kubernetes.client.openapi.models.V1ResourceFieldSelector item); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested editResourceFieldRef(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested editOrNewResourceFieldRef(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested editOrNewResourceFieldRefLike(io.kubernetes.client.openapi.models.V1ResourceFieldSelector item); - public interface FieldRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent>{ + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested + withNewResourceFieldRef(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested + withNewResourceFieldRefLike(io.kubernetes.client.openapi.models.V1ResourceFieldSelector item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested + editResourceFieldRef(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested + editOrNewResourceFieldRef(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested + editOrNewResourceFieldRefLike( + io.kubernetes.client.openapi.models.V1ResourceFieldSelector item); + + public interface FieldRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested> { public N and(); + public N endFieldRef(); - } - public interface ResourceFieldRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent>{ + + public interface ResourceFieldRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent + .ResourceFieldRefNested< + N>> { public N and(); + public N endResourceFieldRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeFileFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeFileFluentImpl.java index a62dc09911..4a5d393a75 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeFileFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeFileFluentImpl.java @@ -1,20 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1DownwardAPIVolumeFileFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent{ - public V1DownwardAPIVolumeFileFluentImpl() { - } - public V1DownwardAPIVolumeFileFluentImpl(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile instance) { +/** Generated */ +public class V1DownwardAPIVolumeFileFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent { + public V1DownwardAPIVolumeFileFluentImpl() {} + + public V1DownwardAPIVolumeFileFluentImpl( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile instance) { this.withFieldRef(instance.getFieldRef()); this.withMode(instance.getMode()); @@ -22,150 +28,233 @@ public V1DownwardAPIVolumeFileFluentImpl(io.kubernetes.client.openapi.models.V1D this.withPath(instance.getPath()); this.withResourceFieldRef(instance.getResourceFieldRef()); - } + private io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder fieldRef; private java.lang.Integer mode; private java.lang.String path; private io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder resourceFieldRef; - + /** * This method has been deprecated, please use method buildFieldRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectFieldSelector getFieldRef() { - return this.fieldRef!=null ?this.fieldRef.build():null; + return this.fieldRef != null ? this.fieldRef.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectFieldSelector buildFieldRef() { - return this.fieldRef!=null ?this.fieldRef.build():null; + return this.fieldRef != null ? this.fieldRef.build() : null; } + public A withFieldRef(io.kubernetes.client.openapi.models.V1ObjectFieldSelector fieldRef) { _visitables.get("fieldRef").remove(this.fieldRef); - if (fieldRef!=null){ this.fieldRef= new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder(fieldRef); _visitables.get("fieldRef").add(this.fieldRef);} return (A) this; + if (fieldRef != null) { + this.fieldRef = + new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder(fieldRef); + _visitables.get("fieldRef").add(this.fieldRef); + } + return (A) this; } + public java.lang.Boolean hasFieldRef() { return this.fieldRef != null; } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested withNewFieldRef() { - return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl.FieldRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested + withNewFieldRef() { + return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl + .FieldRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested withNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item) { - return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl.FieldRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested + withNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item) { + return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl + .FieldRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested editFieldRef() { + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested + editFieldRef() { return withNewFieldRefLike(getFieldRef()); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested editOrNewFieldRef() { - return withNewFieldRefLike(getFieldRef() != null ? getFieldRef(): new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested + editOrNewFieldRef() { + return withNewFieldRefLike( + getFieldRef() != null + ? getFieldRef() + : new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested editOrNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item) { - return withNewFieldRefLike(getFieldRef() != null ? getFieldRef(): item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested + editOrNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item) { + return withNewFieldRefLike(getFieldRef() != null ? getFieldRef() : item); } + public java.lang.Integer getMode() { return this.mode; } + public A withMode(java.lang.Integer mode) { - this.mode=mode; return (A) this; + this.mode = mode; + return (A) this; } + public java.lang.Boolean hasMode() { return this.mode != null; } + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } - + /** * This method has been deprecated, please use method buildResourceFieldRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceFieldSelector getResourceFieldRef() { - return this.resourceFieldRef!=null ?this.resourceFieldRef.build():null; + return this.resourceFieldRef != null ? this.resourceFieldRef.build() : null; } + public io.kubernetes.client.openapi.models.V1ResourceFieldSelector buildResourceFieldRef() { - return this.resourceFieldRef!=null ?this.resourceFieldRef.build():null; + return this.resourceFieldRef != null ? this.resourceFieldRef.build() : null; } - public A withResourceFieldRef(io.kubernetes.client.openapi.models.V1ResourceFieldSelector resourceFieldRef) { + + public A withResourceFieldRef( + io.kubernetes.client.openapi.models.V1ResourceFieldSelector resourceFieldRef) { _visitables.get("resourceFieldRef").remove(this.resourceFieldRef); - if (resourceFieldRef!=null){ this.resourceFieldRef= new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder(resourceFieldRef); _visitables.get("resourceFieldRef").add(this.resourceFieldRef);} return (A) this; + if (resourceFieldRef != null) { + this.resourceFieldRef = + new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder(resourceFieldRef); + _visitables.get("resourceFieldRef").add(this.resourceFieldRef); + } + return (A) this; } + public java.lang.Boolean hasResourceFieldRef() { return this.resourceFieldRef != null; } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested withNewResourceFieldRef() { - return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl.ResourceFieldRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested + withNewResourceFieldRef() { + return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl + .ResourceFieldRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested withNewResourceFieldRefLike(io.kubernetes.client.openapi.models.V1ResourceFieldSelector item) { - return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl.ResourceFieldRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested + withNewResourceFieldRefLike( + io.kubernetes.client.openapi.models.V1ResourceFieldSelector item) { + return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl + .ResourceFieldRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested editResourceFieldRef() { + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested + editResourceFieldRef() { return withNewResourceFieldRefLike(getResourceFieldRef()); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested editOrNewResourceFieldRef() { - return withNewResourceFieldRefLike(getResourceFieldRef() != null ? getResourceFieldRef(): new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested + editOrNewResourceFieldRef() { + return withNewResourceFieldRefLike( + getResourceFieldRef() != null + ? getResourceFieldRef() + : new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested editOrNewResourceFieldRefLike(io.kubernetes.client.openapi.models.V1ResourceFieldSelector item) { - return withNewResourceFieldRefLike(getResourceFieldRef() != null ? getResourceFieldRef(): item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested + editOrNewResourceFieldRefLike( + io.kubernetes.client.openapi.models.V1ResourceFieldSelector item) { + return withNewResourceFieldRefLike( + getResourceFieldRef() != null ? getResourceFieldRef() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1DownwardAPIVolumeFileFluentImpl that = (V1DownwardAPIVolumeFileFluentImpl) o; - if (fieldRef != null ? !fieldRef.equals(that.fieldRef) :that.fieldRef != null) return false; - if (mode != null ? !mode.equals(that.mode) :that.mode != null) return false; - if (path != null ? !path.equals(that.path) :that.path != null) return false; - if (resourceFieldRef != null ? !resourceFieldRef.equals(that.resourceFieldRef) :that.resourceFieldRef != null) return false; + if (fieldRef != null ? !fieldRef.equals(that.fieldRef) : that.fieldRef != null) return false; + if (mode != null ? !mode.equals(that.mode) : that.mode != null) return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; + if (resourceFieldRef != null + ? !resourceFieldRef.equals(that.resourceFieldRef) + : that.resourceFieldRef != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fieldRef, mode, path, resourceFieldRef, super.hashCode()); + return java.util.Objects.hash(fieldRef, mode, path, resourceFieldRef, super.hashCode()); } - public class FieldRefNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested,io.kubernetes.client.fluent.Nested{ + + public class FieldRefNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested> + implements io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.FieldRefNested< + N>, + io.kubernetes.client.fluent.Nested { FieldRefNestedImpl(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item) { - this.builder = new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder(this, item); } + FieldRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder builder; + public N and() { return (N) V1DownwardAPIVolumeFileFluentImpl.this.withFieldRef(builder.build()); } + public N endFieldRef() { return and(); } - } - public class ResourceFieldRefNestedImpl extends io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested,io.kubernetes.client.fluent.Nested{ + + public class ResourceFieldRefNestedImpl + extends io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent.ResourceFieldRefNested< + N>> + implements io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent + .ResourceFieldRefNested< + N>, + io.kubernetes.client.fluent.Nested { ResourceFieldRefNestedImpl(io.kubernetes.client.openapi.models.V1ResourceFieldSelector item) { - this.builder = new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder(this, item); } + ResourceFieldRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder builder; + public N and() { return (N) V1DownwardAPIVolumeFileFluentImpl.this.withResourceFieldRef(builder.build()); } + public N endResourceFieldRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeSourceBuilder.java index 70ba0ca3f2..b3b44068bb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1DownwardAPIVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1DownwardAPIVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource, + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceBuilder> { public V1DownwardAPIVolumeSourceBuilder() { this(false); } + public V1DownwardAPIVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1DownwardAPIVolumeSource(), validationEnabled); } - public V1DownwardAPIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent fluent) { + + public V1DownwardAPIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent fluent) { this(fluent, false); } - public V1DownwardAPIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1DownwardAPIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1DownwardAPIVolumeSource(), validationEnabled); } - public V1DownwardAPIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource instance) { + + public V1DownwardAPIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource instance) { this(fluent, instance, false); } - public V1DownwardAPIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1DownwardAPIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDefaultMode(instance.getDefaultMode()); fluent.withItems(instance.getItems()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1DownwardAPIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource instance) { - this(instance,false); + + public V1DownwardAPIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource instance) { + this(instance, false); } - public V1DownwardAPIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1DownwardAPIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDefaultMode(instance.getDefaultMode()); this.withItems(instance.getItems()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource build() { V1DownwardAPIVolumeSource buildable = new V1DownwardAPIVolumeSource(); buildable.setDefaultMode(fluent.getDefaultMode()); buildable.setItems(fluent.getItems()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1DownwardAPIVolumeSourceBuilder that = (V1DownwardAPIVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeSourceFluent.java index c3e48c180b..0c4492d552 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeSourceFluent.java @@ -1,60 +1,114 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1DownwardAPIVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1DownwardAPIVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getDefaultMode(); + public A withDefaultMode(java.lang.Integer defaultMode); + public java.lang.Boolean hasDefaultMode(); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); + public A addToItems(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildFirstItem(); + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildLastItem(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent>{ + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluent< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested> { public N and(); + public N endItem(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeSourceFluentImpl.java index d017aeeadb..ffab1bbeee 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1DownwardAPIVolumeSourceFluentImpl.java @@ -1,69 +1,150 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1DownwardAPIVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent{ - public V1DownwardAPIVolumeSourceFluentImpl() { - } - public V1DownwardAPIVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource instance) { +/** Generated */ +public class V1DownwardAPIVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent { + public V1DownwardAPIVolumeSourceFluentImpl() {} + + public V1DownwardAPIVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource instance) { this.withDefaultMode(instance.getDefaultMode()); this.withItems(instance.getItems()); - } + private java.lang.Integer defaultMode; - private java.util.ArrayList items; + private java.util.ArrayList + items; + public java.lang.Integer getDefaultMode() { return this.defaultMode; } + public A withDefaultMode(java.lang.Integer defaultMode) { - this.defaultMode=defaultMode; return (A) this; + this.defaultMode = defaultMode; + return (A) this; } + public java.lang.Boolean hasDefaultMode() { return this.defaultMode != null; } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder>(); + } + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder>(); + } + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) {io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) { + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) {io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) { + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile... items) { - for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) {io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) { + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) {io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) { + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder = each.next(); @@ -72,105 +153,187 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { - return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { + return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { - return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { + return new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl> implements io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileFluentImpl< + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFile item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder(this); } + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeFileBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1DownwardAPIVolumeSourceFluentImpl.this.setToItems(index,builder.build()); + return (N) V1DownwardAPIVolumeSourceFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EmptyDirVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EmptyDirVolumeSourceBuilder.java index baa13d2b81..8b9089efa6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EmptyDirVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EmptyDirVolumeSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EmptyDirVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EmptyDirVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource, + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceBuilder> { public V1EmptyDirVolumeSourceBuilder() { this(false); } + public V1EmptyDirVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1EmptyDirVolumeSource(), validationEnabled); } - public V1EmptyDirVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent fluent) { + + public V1EmptyDirVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent fluent) { this(fluent, false); } - public V1EmptyDirVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EmptyDirVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EmptyDirVolumeSource(), validationEnabled); } - public V1EmptyDirVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource instance) { + + public V1EmptyDirVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource instance) { this(fluent, instance, false); } - public V1EmptyDirVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EmptyDirVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMedium(instance.getMedium()); fluent.withSizeLimit(instance.getSizeLimit()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1EmptyDirVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource instance) { - this(instance,false); + + public V1EmptyDirVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource instance) { + this(instance, false); } - public V1EmptyDirVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EmptyDirVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMedium(instance.getMedium()); this.withSizeLimit(instance.getSizeLimit()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource build() { V1EmptyDirVolumeSource buildable = new V1EmptyDirVolumeSource(); buildable.setMedium(fluent.getMedium()); buildable.setSizeLimit(fluent.getSizeLimit()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EmptyDirVolumeSourceBuilder that = (V1EmptyDirVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EmptyDirVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EmptyDirVolumeSourceFluent.java index 13bf5d48be..14d7a6d3bf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EmptyDirVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EmptyDirVolumeSourceFluent.java @@ -1,28 +1,36 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1EmptyDirVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1EmptyDirVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getMedium(); + public A withMedium(java.lang.String medium); + public java.lang.Boolean hasMedium(); - - /** - * Method is deprecated. use withMedium instead. - */ + + /** Method is deprecated. use withMedium instead. */ @java.lang.Deprecated public A withNewMedium(java.lang.String original); + public io.kubernetes.client.custom.Quantity getSizeLimit(); + public A withSizeLimit(io.kubernetes.client.custom.Quantity sizeLimit); + public java.lang.Boolean hasSizeLimit(); + public A withNewSizeLimit(java.lang.String value); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EmptyDirVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EmptyDirVolumeSourceFluentImpl.java index fbc00df84a..6d413c04af 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EmptyDirVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EmptyDirVolumeSourceFluentImpl.java @@ -1,65 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - /** - * Generated - */ -public class V1EmptyDirVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent{ - public V1EmptyDirVolumeSourceFluentImpl() { - } - public V1EmptyDirVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource instance) { +/** Generated */ +public class V1EmptyDirVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent { + public V1EmptyDirVolumeSourceFluentImpl() {} + + public V1EmptyDirVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource instance) { this.withMedium(instance.getMedium()); this.withSizeLimit(instance.getSizeLimit()); - } + private java.lang.String medium; private io.kubernetes.client.custom.Quantity sizeLimit; + public java.lang.String getMedium() { return this.medium; } + public A withMedium(java.lang.String medium) { - this.medium=medium; return (A) this; + this.medium = medium; + return (A) this; } + public java.lang.Boolean hasMedium() { return this.medium != null; } - - /** - * Method is deprecated. use withMedium instead. - */ + + /** Method is deprecated. use withMedium instead. */ @java.lang.Deprecated public A withNewMedium(java.lang.String original) { - return (A)withMedium(new String(original)); + return (A) withMedium(new String(original)); } + public io.kubernetes.client.custom.Quantity getSizeLimit() { return this.sizeLimit; } + public A withSizeLimit(io.kubernetes.client.custom.Quantity sizeLimit) { - this.sizeLimit=sizeLimit; return (A) this; + this.sizeLimit = sizeLimit; + return (A) this; } + public java.lang.Boolean hasSizeLimit() { return this.sizeLimit != null; } + public A withNewSizeLimit(java.lang.String value) { - return (A)withSizeLimit(new Quantity(value)); + return (A) withSizeLimit(new Quantity(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1EmptyDirVolumeSourceFluentImpl that = (V1EmptyDirVolumeSourceFluentImpl) o; - if (medium != null ? !medium.equals(that.medium) :that.medium != null) return false; - if (sizeLimit != null ? !sizeLimit.equals(that.sizeLimit) :that.sizeLimit != null) return false; + if (medium != null ? !medium.equals(that.medium) : that.medium != null) return false; + if (sizeLimit != null ? !sizeLimit.equals(that.sizeLimit) : that.sizeLimit != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(medium, sizeLimit, super.hashCode()); + return java.util.Objects.hash(medium, sizeLimit, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointAddressBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointAddressBuilder.java index bf4208e10f..d6338c6230 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointAddressBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointAddressBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EndpointAddressBuilder extends io.kubernetes.client.openapi.models.V1EndpointAddressFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EndpointAddressBuilder + extends io.kubernetes.client.openapi.models.V1EndpointAddressFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EndpointAddress, + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder> { public V1EndpointAddressBuilder() { this(false); } + public V1EndpointAddressBuilder(java.lang.Boolean validationEnabled) { this(new V1EndpointAddress(), validationEnabled); } - public V1EndpointAddressBuilder(io.kubernetes.client.openapi.models.V1EndpointAddressFluent fluent) { + + public V1EndpointAddressBuilder( + io.kubernetes.client.openapi.models.V1EndpointAddressFluent fluent) { this(fluent, false); } - public V1EndpointAddressBuilder(io.kubernetes.client.openapi.models.V1EndpointAddressFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EndpointAddressBuilder( + io.kubernetes.client.openapi.models.V1EndpointAddressFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EndpointAddress(), validationEnabled); } - public V1EndpointAddressBuilder(io.kubernetes.client.openapi.models.V1EndpointAddressFluent fluent,io.kubernetes.client.openapi.models.V1EndpointAddress instance) { + + public V1EndpointAddressBuilder( + io.kubernetes.client.openapi.models.V1EndpointAddressFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointAddress instance) { this(fluent, instance, false); } - public V1EndpointAddressBuilder(io.kubernetes.client.openapi.models.V1EndpointAddressFluent fluent,io.kubernetes.client.openapi.models.V1EndpointAddress instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EndpointAddressBuilder( + io.kubernetes.client.openapi.models.V1EndpointAddressFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointAddress instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withHostname(instance.getHostname()); fluent.withIp(instance.getIp()); @@ -29,13 +56,17 @@ public V1EndpointAddressBuilder(io.kubernetes.client.openapi.models.V1EndpointAd fluent.withTargetRef(instance.getTargetRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1EndpointAddressBuilder(io.kubernetes.client.openapi.models.V1EndpointAddress instance) { - this(instance,false); + this(instance, false); } - public V1EndpointAddressBuilder(io.kubernetes.client.openapi.models.V1EndpointAddress instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EndpointAddressBuilder( + io.kubernetes.client.openapi.models.V1EndpointAddress instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withHostname(instance.getHostname()); this.withIp(instance.getIp()); @@ -44,10 +75,12 @@ public V1EndpointAddressBuilder(io.kubernetes.client.openapi.models.V1EndpointAd this.withTargetRef(instance.getTargetRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EndpointAddressFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EndpointAddress build() { V1EndpointAddress buildable = new V1EndpointAddress(); buildable.setHostname(fluent.getHostname()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1EndpointAddress build() { buildable.setTargetRef(fluent.getTargetRef()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EndpointAddressBuilder that = (V1EndpointAddressBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointAddressFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointAddressFluent.java index c5a725e7a8..e69fb2293e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointAddressFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointAddressFluent.java @@ -1,62 +1,86 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1EndpointAddressFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1EndpointAddressFluent< + A extends io.kubernetes.client.openapi.models.V1EndpointAddressFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getHostname(); + public A withHostname(java.lang.String hostname); + public java.lang.Boolean hasHostname(); - - /** - * Method is deprecated. use withHostname instead. - */ + + /** Method is deprecated. use withHostname instead. */ @java.lang.Deprecated public A withNewHostname(java.lang.String original); + public java.lang.String getIp(); + public A withIp(java.lang.String ip); + public java.lang.Boolean hasIp(); - - /** - * Method is deprecated. use withIp instead. - */ + + /** Method is deprecated. use withIp instead. */ @java.lang.Deprecated public A withNewIp(java.lang.String original); + public java.lang.String getNodeName(); + public A withNodeName(java.lang.String nodeName); + public java.lang.Boolean hasNodeName(); - - /** - * Method is deprecated. use withNodeName instead. - */ + + /** Method is deprecated. use withNodeName instead. */ @java.lang.Deprecated public A withNewNodeName(java.lang.String original); - + /** * This method has been deprecated, please use method buildTargetRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getTargetRef(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildTargetRef(); + public A withTargetRef(io.kubernetes.client.openapi.models.V1ObjectReference targetRef); + public java.lang.Boolean hasTargetRef(); - public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested withNewTargetRef(); - public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested withNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested editTargetRef(); - public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested editOrNewTargetRef(); - public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested editOrNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - public interface TargetRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested + withNewTargetRef(); + + public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested + withNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested + editTargetRef(); + + public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested + editOrNewTargetRef(); + + public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested + editOrNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public interface TargetRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested> { public N and(); + public N endTargetRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointAddressFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointAddressFluentImpl.java index e6516f5ca3..3b38d60a4e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointAddressFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointAddressFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1EndpointAddressFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EndpointAddressFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EndpointAddressFluent { + public V1EndpointAddressFluentImpl() {} - /** - * Generated - */ -public class V1EndpointAddressFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EndpointAddressFluent{ - public V1EndpointAddressFluentImpl() { - } - public V1EndpointAddressFluentImpl(io.kubernetes.client.openapi.models.V1EndpointAddress instance) { + public V1EndpointAddressFluentImpl( + io.kubernetes.client.openapi.models.V1EndpointAddress instance) { this.withHostname(instance.getHostname()); this.withIp(instance.getIp()); @@ -21,125 +28,164 @@ public V1EndpointAddressFluentImpl(io.kubernetes.client.openapi.models.V1Endpoin this.withNodeName(instance.getNodeName()); this.withTargetRef(instance.getTargetRef()); - } + private java.lang.String hostname; private java.lang.String ip; private java.lang.String nodeName; private io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder targetRef; + public java.lang.String getHostname() { return this.hostname; } + public A withHostname(java.lang.String hostname) { - this.hostname=hostname; return (A) this; + this.hostname = hostname; + return (A) this; } + public java.lang.Boolean hasHostname() { return this.hostname != null; } - - /** - * Method is deprecated. use withHostname instead. - */ + + /** Method is deprecated. use withHostname instead. */ @java.lang.Deprecated public A withNewHostname(java.lang.String original) { - return (A)withHostname(new String(original)); + return (A) withHostname(new String(original)); } + public java.lang.String getIp() { return this.ip; } + public A withIp(java.lang.String ip) { - this.ip=ip; return (A) this; + this.ip = ip; + return (A) this; } + public java.lang.Boolean hasIp() { return this.ip != null; } - - /** - * Method is deprecated. use withIp instead. - */ + + /** Method is deprecated. use withIp instead. */ @java.lang.Deprecated public A withNewIp(java.lang.String original) { - return (A)withIp(new String(original)); + return (A) withIp(new String(original)); } + public java.lang.String getNodeName() { return this.nodeName; } + public A withNodeName(java.lang.String nodeName) { - this.nodeName=nodeName; return (A) this; + this.nodeName = nodeName; + return (A) this; } + public java.lang.Boolean hasNodeName() { return this.nodeName != null; } - - /** - * Method is deprecated. use withNodeName instead. - */ + + /** Method is deprecated. use withNodeName instead. */ @java.lang.Deprecated public A withNewNodeName(java.lang.String original) { - return (A)withNodeName(new String(original)); + return (A) withNodeName(new String(original)); } - + /** * This method has been deprecated, please use method buildTargetRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getTargetRef() { - return this.targetRef!=null ?this.targetRef.build():null; + return this.targetRef != null ? this.targetRef.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectReference buildTargetRef() { - return this.targetRef!=null ?this.targetRef.build():null; + return this.targetRef != null ? this.targetRef.build() : null; } + public A withTargetRef(io.kubernetes.client.openapi.models.V1ObjectReference targetRef) { _visitables.get("targetRef").remove(this.targetRef); - if (targetRef!=null){ this.targetRef= new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(targetRef); _visitables.get("targetRef").add(this.targetRef);} return (A) this; + if (targetRef != null) { + this.targetRef = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(targetRef); + _visitables.get("targetRef").add(this.targetRef); + } + return (A) this; } + public java.lang.Boolean hasTargetRef() { return this.targetRef != null; } - public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested withNewTargetRef() { - return new io.kubernetes.client.openapi.models.V1EndpointAddressFluentImpl.TargetRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested + withNewTargetRef() { + return new io.kubernetes.client.openapi.models.V1EndpointAddressFluentImpl + .TargetRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested withNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return new io.kubernetes.client.openapi.models.V1EndpointAddressFluentImpl.TargetRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested + withNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return new io.kubernetes.client.openapi.models.V1EndpointAddressFluentImpl.TargetRefNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested editTargetRef() { + + public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested + editTargetRef() { return withNewTargetRefLike(getTargetRef()); } - public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested editOrNewTargetRef() { - return withNewTargetRefLike(getTargetRef() != null ? getTargetRef(): new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested + editOrNewTargetRef() { + return withNewTargetRefLike( + getTargetRef() != null + ? getTargetRef() + : new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested editOrNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return withNewTargetRefLike(getTargetRef() != null ? getTargetRef(): item); + + public io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested + editOrNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return withNewTargetRefLike(getTargetRef() != null ? getTargetRef() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1EndpointAddressFluentImpl that = (V1EndpointAddressFluentImpl) o; - if (hostname != null ? !hostname.equals(that.hostname) :that.hostname != null) return false; - if (ip != null ? !ip.equals(that.ip) :that.ip != null) return false; - if (nodeName != null ? !nodeName.equals(that.nodeName) :that.nodeName != null) return false; - if (targetRef != null ? !targetRef.equals(that.targetRef) :that.targetRef != null) return false; + if (hostname != null ? !hostname.equals(that.hostname) : that.hostname != null) return false; + if (ip != null ? !ip.equals(that.ip) : that.ip != null) return false; + if (nodeName != null ? !nodeName.equals(that.nodeName) : that.nodeName != null) return false; + if (targetRef != null ? !targetRef.equals(that.targetRef) : that.targetRef != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(hostname, ip, nodeName, targetRef, super.hashCode()); + return java.util.Objects.hash(hostname, ip, nodeName, targetRef, super.hashCode()); } - public class TargetRefNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested,io.kubernetes.client.fluent.Nested{ + + public class TargetRefNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested> + implements io.kubernetes.client.openapi.models.V1EndpointAddressFluent.TargetRefNested, + io.kubernetes.client.fluent.Nested { TargetRefNestedImpl(io.kubernetes.client.openapi.models.V1ObjectReference item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + TargetRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; + public N and() { return (N) V1EndpointAddressFluentImpl.this.withTargetRef(builder.build()); } + public N endTargetRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointBuilder.java index 41b84d9854..e897d31e80 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EndpointBuilder extends io.kubernetes.client.openapi.models.V1EndpointFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EndpointBuilder + extends io.kubernetes.client.openapi.models.V1EndpointFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Endpoint, + io.kubernetes.client.openapi.models.V1EndpointBuilder> { public V1EndpointBuilder() { this(false); } + public V1EndpointBuilder(java.lang.Boolean validationEnabled) { this(new V1Endpoint(), validationEnabled); } + public V1EndpointBuilder(io.kubernetes.client.openapi.models.V1EndpointFluent fluent) { this(fluent, false); } - public V1EndpointBuilder(io.kubernetes.client.openapi.models.V1EndpointFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EndpointBuilder( + io.kubernetes.client.openapi.models.V1EndpointFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Endpoint(), validationEnabled); } - public V1EndpointBuilder(io.kubernetes.client.openapi.models.V1EndpointFluent fluent,io.kubernetes.client.openapi.models.V1Endpoint instance) { + + public V1EndpointBuilder( + io.kubernetes.client.openapi.models.V1EndpointFluent fluent, + io.kubernetes.client.openapi.models.V1Endpoint instance) { this(fluent, instance, false); } - public V1EndpointBuilder(io.kubernetes.client.openapi.models.V1EndpointFluent fluent,io.kubernetes.client.openapi.models.V1Endpoint instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EndpointBuilder( + io.kubernetes.client.openapi.models.V1EndpointFluent fluent, + io.kubernetes.client.openapi.models.V1Endpoint instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAddresses(instance.getAddresses()); fluent.withConditions(instance.getConditions()); @@ -37,13 +63,17 @@ public V1EndpointBuilder(io.kubernetes.client.openapi.models.V1EndpointFluent fluent.withZone(instance.getZone()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1EndpointBuilder(io.kubernetes.client.openapi.models.V1Endpoint instance) { - this(instance,false); + this(instance, false); } - public V1EndpointBuilder(io.kubernetes.client.openapi.models.V1Endpoint instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EndpointBuilder( + io.kubernetes.client.openapi.models.V1Endpoint instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAddresses(instance.getAddresses()); this.withConditions(instance.getConditions()); @@ -60,10 +90,12 @@ public V1EndpointBuilder(io.kubernetes.client.openapi.models.V1Endpoint instance this.withZone(instance.getZone()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EndpointFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Endpoint build() { V1Endpoint buildable = new V1Endpoint(); buildable.setAddresses(fluent.getAddresses()); @@ -76,18 +108,23 @@ public io.kubernetes.client.openapi.models.V1Endpoint build() { buildable.setZone(fluent.getZone()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EndpointBuilder that = (V1EndpointBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointConditionsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointConditionsBuilder.java index cdaf2099af..c689212753 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointConditionsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointConditionsBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EndpointConditionsBuilder extends io.kubernetes.client.openapi.models.V1EndpointConditionsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EndpointConditionsBuilder + extends io.kubernetes.client.openapi.models.V1EndpointConditionsFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointConditionsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EndpointConditions, + io.kubernetes.client.openapi.models.V1EndpointConditionsBuilder> { public V1EndpointConditionsBuilder() { this(false); } + public V1EndpointConditionsBuilder(java.lang.Boolean validationEnabled) { this(new V1EndpointConditions(), validationEnabled); } - public V1EndpointConditionsBuilder(io.kubernetes.client.openapi.models.V1EndpointConditionsFluent fluent) { + + public V1EndpointConditionsBuilder( + io.kubernetes.client.openapi.models.V1EndpointConditionsFluent fluent) { this(fluent, false); } - public V1EndpointConditionsBuilder(io.kubernetes.client.openapi.models.V1EndpointConditionsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EndpointConditionsBuilder( + io.kubernetes.client.openapi.models.V1EndpointConditionsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EndpointConditions(), validationEnabled); } - public V1EndpointConditionsBuilder(io.kubernetes.client.openapi.models.V1EndpointConditionsFluent fluent,io.kubernetes.client.openapi.models.V1EndpointConditions instance) { + + public V1EndpointConditionsBuilder( + io.kubernetes.client.openapi.models.V1EndpointConditionsFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointConditions instance) { this(fluent, instance, false); } - public V1EndpointConditionsBuilder(io.kubernetes.client.openapi.models.V1EndpointConditionsFluent fluent,io.kubernetes.client.openapi.models.V1EndpointConditions instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EndpointConditionsBuilder( + io.kubernetes.client.openapi.models.V1EndpointConditionsFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointConditions instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withReady(instance.getReady()); fluent.withServing(instance.getServing()); fluent.withTerminating(instance.getTerminating()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1EndpointConditionsBuilder(io.kubernetes.client.openapi.models.V1EndpointConditions instance) { - this(instance,false); + + public V1EndpointConditionsBuilder( + io.kubernetes.client.openapi.models.V1EndpointConditions instance) { + this(instance, false); } - public V1EndpointConditionsBuilder(io.kubernetes.client.openapi.models.V1EndpointConditions instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EndpointConditionsBuilder( + io.kubernetes.client.openapi.models.V1EndpointConditions instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withReady(instance.getReady()); this.withServing(instance.getServing()); this.withTerminating(instance.getTerminating()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EndpointConditionsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EndpointConditions build() { V1EndpointConditions buildable = new V1EndpointConditions(); buildable.setReady(fluent.getReady()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1EndpointConditions build() { buildable.setTerminating(fluent.getTerminating()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EndpointConditionsBuilder that = (V1EndpointConditionsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointConditionsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointConditionsFluent.java index a08b18abd7..0b031355de 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointConditionsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointConditionsFluent.java @@ -1,22 +1,36 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1EndpointConditionsFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1EndpointConditionsFluent< + A extends io.kubernetes.client.openapi.models.V1EndpointConditionsFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Boolean getReady(); + public A withReady(java.lang.Boolean ready); + public java.lang.Boolean hasReady(); + public java.lang.Boolean getServing(); + public A withServing(java.lang.Boolean serving); + public java.lang.Boolean hasServing(); + public java.lang.Boolean getTerminating(); + public A withTerminating(java.lang.Boolean terminating); + public java.lang.Boolean hasTerminating(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointConditionsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointConditionsFluentImpl.java index 7223a96d5a..98cbe92033 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointConditionsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointConditionsFluentImpl.java @@ -1,64 +1,88 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1EndpointConditionsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EndpointConditionsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EndpointConditionsFluent { + public V1EndpointConditionsFluentImpl() {} - /** - * Generated - */ -public class V1EndpointConditionsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EndpointConditionsFluent{ - public V1EndpointConditionsFluentImpl() { - } - public V1EndpointConditionsFluentImpl(io.kubernetes.client.openapi.models.V1EndpointConditions instance) { + public V1EndpointConditionsFluentImpl( + io.kubernetes.client.openapi.models.V1EndpointConditions instance) { this.withReady(instance.getReady()); this.withServing(instance.getServing()); this.withTerminating(instance.getTerminating()); - } + private java.lang.Boolean ready; private java.lang.Boolean serving; private java.lang.Boolean terminating; + public java.lang.Boolean getReady() { return this.ready; } + public A withReady(java.lang.Boolean ready) { - this.ready=ready; return (A) this; + this.ready = ready; + return (A) this; } + public java.lang.Boolean hasReady() { return this.ready != null; } + public java.lang.Boolean getServing() { return this.serving; } + public A withServing(java.lang.Boolean serving) { - this.serving=serving; return (A) this; + this.serving = serving; + return (A) this; } + public java.lang.Boolean hasServing() { return this.serving != null; } + public java.lang.Boolean getTerminating() { return this.terminating; } + public A withTerminating(java.lang.Boolean terminating) { - this.terminating=terminating; return (A) this; + this.terminating = terminating; + return (A) this; } + public java.lang.Boolean hasTerminating() { return this.terminating != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1EndpointConditionsFluentImpl that = (V1EndpointConditionsFluentImpl) o; - if (ready != null ? !ready.equals(that.ready) :that.ready != null) return false; - if (serving != null ? !serving.equals(that.serving) :that.serving != null) return false; - if (terminating != null ? !terminating.equals(that.terminating) :that.terminating != null) return false; + if (ready != null ? !ready.equals(that.ready) : that.ready != null) return false; + if (serving != null ? !serving.equals(that.serving) : that.serving != null) return false; + if (terminating != null ? !terminating.equals(that.terminating) : that.terminating != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(ready, serving, terminating, super.hashCode()); + return java.util.Objects.hash(ready, serving, terminating, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointFluent.java index e4fa2bdbc1..7f68cecba1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointFluent.java @@ -1,132 +1,204 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; -import java.util.Map; - - /** - * Generated - */ -public interface V1EndpointFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAddresses(java.lang.Integer index,java.lang.String item); - public A setToAddresses(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1EndpointFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAddresses(java.lang.Integer index, java.lang.String item); + + public A setToAddresses(java.lang.Integer index, java.lang.String item); + public A addToAddresses(java.lang.String... items); + public A addAllToAddresses(java.util.Collection items); + public A removeFromAddresses(java.lang.String... items); + public A removeAllFromAddresses(java.util.Collection items); + public java.util.List getAddresses(); + public java.lang.String getAddress(java.lang.Integer index); + public java.lang.String getFirstAddress(); + public java.lang.String getLastAddress(); - public java.lang.String getMatchingAddress(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAddress(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAddress( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAddress( + java.util.function.Predicate predicate); + public A withAddresses(java.util.List addresses); + public A withAddresses(java.lang.String... addresses); + public java.lang.Boolean hasAddresses(); + public A addNewAddress(java.lang.String original); - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EndpointConditions getConditions(); + public io.kubernetes.client.openapi.models.V1EndpointConditions buildConditions(); + public A withConditions(io.kubernetes.client.openapi.models.V1EndpointConditions conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested withNewConditions(); - public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested withNewConditionsLike(io.kubernetes.client.openapi.models.V1EndpointConditions item); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested + withNewConditions(); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested + withNewConditionsLike(io.kubernetes.client.openapi.models.V1EndpointConditions item); + public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested editConditions(); - public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested editOrNewConditions(); - public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested editOrNewConditionsLike(io.kubernetes.client.openapi.models.V1EndpointConditions item); - public A addToDeprecatedTopology(java.lang.String key,java.lang.String value); - public A addToDeprecatedTopology(java.util.Map map); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested + editOrNewConditions(); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested + editOrNewConditionsLike(io.kubernetes.client.openapi.models.V1EndpointConditions item); + + public A addToDeprecatedTopology(java.lang.String key, java.lang.String value); + + public A addToDeprecatedTopology(java.util.Map map); + public A removeFromDeprecatedTopology(java.lang.String key); - public A removeFromDeprecatedTopology(java.util.Map map); - public java.util.Map getDeprecatedTopology(); - public A withDeprecatedTopology(java.util.Map deprecatedTopology); + + public A removeFromDeprecatedTopology(java.util.Map map); + + public java.util.Map getDeprecatedTopology(); + + public A withDeprecatedTopology( + java.util.Map deprecatedTopology); + public java.lang.Boolean hasDeprecatedTopology(); - + /** * This method has been deprecated, please use method buildHints instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EndpointHints getHints(); + public io.kubernetes.client.openapi.models.V1EndpointHints buildHints(); + public A withHints(io.kubernetes.client.openapi.models.V1EndpointHints hints); + public java.lang.Boolean hasHints(); + public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested withNewHints(); - public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested withNewHintsLike(io.kubernetes.client.openapi.models.V1EndpointHints item); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested withNewHintsLike( + io.kubernetes.client.openapi.models.V1EndpointHints item); + public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested editHints(); + public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested editOrNewHints(); - public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested editOrNewHintsLike(io.kubernetes.client.openapi.models.V1EndpointHints item); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested editOrNewHintsLike( + io.kubernetes.client.openapi.models.V1EndpointHints item); + public java.lang.String getHostname(); + public A withHostname(java.lang.String hostname); + public java.lang.Boolean hasHostname(); - - /** - * Method is deprecated. use withHostname instead. - */ + + /** Method is deprecated. use withHostname instead. */ @java.lang.Deprecated public A withNewHostname(java.lang.String original); + public java.lang.String getNodeName(); + public A withNodeName(java.lang.String nodeName); + public java.lang.Boolean hasNodeName(); - - /** - * Method is deprecated. use withNodeName instead. - */ + + /** Method is deprecated. use withNodeName instead. */ @java.lang.Deprecated public A withNewNodeName(java.lang.String original); - + /** * This method has been deprecated, please use method buildTargetRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getTargetRef(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildTargetRef(); + public A withTargetRef(io.kubernetes.client.openapi.models.V1ObjectReference targetRef); + public java.lang.Boolean hasTargetRef(); + public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested withNewTargetRef(); - public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested withNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested + withNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested editTargetRef(); - public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested editOrNewTargetRef(); - public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested editOrNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested + editOrNewTargetRef(); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested + editOrNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + public java.lang.String getZone(); + public A withZone(java.lang.String zone); + public java.lang.Boolean hasZone(); - - /** - * Method is deprecated. use withZone instead. - */ + + /** Method is deprecated. use withZone instead. */ @java.lang.Deprecated public A withNewZone(java.lang.String original); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EndpointConditionsFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EndpointConditionsFluent< + io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested> { public N and(); + public N endConditions(); - } - public interface HintsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EndpointHintsFluent>{ + + public interface HintsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EndpointHintsFluent< + io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested> { public N and(); + public N endHints(); - } - public interface TargetRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface TargetRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested> { public N and(); + public N endTargetRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointFluentImpl.java index c4e4dc029e..1ae95b28ca 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointFluentImpl.java @@ -1,25 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; -import java.util.Map; - - /** - * Generated - */ -public class V1EndpointFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EndpointFluent{ - public V1EndpointFluentImpl() { - } +/** Generated */ +public class V1EndpointFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EndpointFluent { + public V1EndpointFluentImpl() {} + public V1EndpointFluentImpl(io.kubernetes.client.openapi.models.V1Endpoint instance) { this.withAddresses(instance.getAddresses()); @@ -36,312 +34,522 @@ public V1EndpointFluentImpl(io.kubernetes.client.openapi.models.V1Endpoint insta this.withTargetRef(instance.getTargetRef()); this.withZone(instance.getZone()); - } + private java.util.List addresses; private io.kubernetes.client.openapi.models.V1EndpointConditionsBuilder conditions; - private java.util.Map deprecatedTopology; + private java.util.Map deprecatedTopology; private io.kubernetes.client.openapi.models.V1EndpointHintsBuilder hints; private java.lang.String hostname; private java.lang.String nodeName; private io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder targetRef; private java.lang.String zone; - public A addToAddresses(java.lang.Integer index,java.lang.String item) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} + + public A addToAddresses(java.lang.Integer index, java.lang.String item) { + if (this.addresses == null) { + this.addresses = new java.util.ArrayList(); + } this.addresses.add(index, item); - return (A)this; + return (A) this; } - public A setToAddresses(java.lang.Integer index,java.lang.String item) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - this.addresses.set(index, item); return (A)this; + + public A setToAddresses(java.lang.Integer index, java.lang.String item) { + if (this.addresses == null) { + this.addresses = new java.util.ArrayList(); + } + this.addresses.set(index, item); + return (A) this; } + public A addToAddresses(java.lang.String... items) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - for (java.lang.String item : items) {this.addresses.add(item);} return (A)this; + if (this.addresses == null) { + this.addresses = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.addresses.add(item); + } + return (A) this; } + public A addAllToAddresses(java.util.Collection items) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - for (java.lang.String item : items) {this.addresses.add(item);} return (A)this; + if (this.addresses == null) { + this.addresses = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.addresses.add(item); + } + return (A) this; } + public A removeFromAddresses(java.lang.String... items) { - for (java.lang.String item : items) {if (this.addresses!= null){ this.addresses.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.addresses != null) { + this.addresses.remove(item); + } + } + return (A) this; } + public A removeAllFromAddresses(java.util.Collection items) { - for (java.lang.String item : items) {if (this.addresses!= null){ this.addresses.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.addresses != null) { + this.addresses.remove(item); + } + } + return (A) this; } + public java.util.List getAddresses() { return this.addresses; } + public java.lang.String getAddress(java.lang.Integer index) { return this.addresses.get(index); } + public java.lang.String getFirstAddress() { return this.addresses.get(0); } + public java.lang.String getLastAddress() { return this.addresses.get(addresses.size() - 1); } - public java.lang.String getMatchingAddress(java.util.function.Predicate predicate) { - for (java.lang.String item: addresses) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAddress( + java.util.function.Predicate predicate) { + for (java.lang.String item : addresses) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAddress(java.util.function.Predicate predicate) { - for (java.lang.String item: addresses) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAddress( + java.util.function.Predicate predicate) { + for (java.lang.String item : addresses) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAddresses(java.util.List addresses) { - if (addresses != null) {this.addresses = new java.util.ArrayList(); for (java.lang.String item : addresses){this.addToAddresses(item);}} else { this.addresses = null;} return (A) this; + if (addresses != null) { + this.addresses = new java.util.ArrayList(); + for (java.lang.String item : addresses) { + this.addToAddresses(item); + } + } else { + this.addresses = null; + } + return (A) this; } + public A withAddresses(java.lang.String... addresses) { - if (this.addresses != null) {this.addresses.clear();} - if (addresses != null) {for (java.lang.String item :addresses){ this.addToAddresses(item);}} return (A) this; + if (this.addresses != null) { + this.addresses.clear(); + } + if (addresses != null) { + for (java.lang.String item : addresses) { + this.addToAddresses(item); + } + } + return (A) this; } + public java.lang.Boolean hasAddresses() { return addresses != null && !addresses.isEmpty(); } + public A addNewAddress(java.lang.String original) { - return (A)addToAddresses(new String(original)); + return (A) addToAddresses(new String(original)); } - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EndpointConditions getConditions() { - return this.conditions!=null ?this.conditions.build():null; + return this.conditions != null ? this.conditions.build() : null; } + public io.kubernetes.client.openapi.models.V1EndpointConditions buildConditions() { - return this.conditions!=null ?this.conditions.build():null; + return this.conditions != null ? this.conditions.build() : null; } + public A withConditions(io.kubernetes.client.openapi.models.V1EndpointConditions conditions) { _visitables.get("conditions").remove(this.conditions); - if (conditions!=null){ this.conditions= new io.kubernetes.client.openapi.models.V1EndpointConditionsBuilder(conditions); _visitables.get("conditions").add(this.conditions);} return (A) this; + if (conditions != null) { + this.conditions = + new io.kubernetes.client.openapi.models.V1EndpointConditionsBuilder(conditions); + _visitables.get("conditions").add(this.conditions); + } + return (A) this; } + public java.lang.Boolean hasConditions() { return this.conditions != null; } - public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested withNewConditions() { + + public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested + withNewConditions() { return new io.kubernetes.client.openapi.models.V1EndpointFluentImpl.ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested withNewConditionsLike(io.kubernetes.client.openapi.models.V1EndpointConditions item) { + + public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested + withNewConditionsLike(io.kubernetes.client.openapi.models.V1EndpointConditions item) { return new io.kubernetes.client.openapi.models.V1EndpointFluentImpl.ConditionsNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested editConditions() { return withNewConditionsLike(getConditions()); } - public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested editOrNewConditions() { - return withNewConditionsLike(getConditions() != null ? getConditions(): new io.kubernetes.client.openapi.models.V1EndpointConditionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested + editOrNewConditions() { + return withNewConditionsLike( + getConditions() != null + ? getConditions() + : new io.kubernetes.client.openapi.models.V1EndpointConditionsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested editOrNewConditionsLike(io.kubernetes.client.openapi.models.V1EndpointConditions item) { - return withNewConditionsLike(getConditions() != null ? getConditions(): item); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested + editOrNewConditionsLike(io.kubernetes.client.openapi.models.V1EndpointConditions item) { + return withNewConditionsLike(getConditions() != null ? getConditions() : item); } - public A addToDeprecatedTopology(java.lang.String key,java.lang.String value) { - if(this.deprecatedTopology == null && key != null && value != null) { this.deprecatedTopology = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.deprecatedTopology.put(key, value);} return (A)this; + + public A addToDeprecatedTopology(java.lang.String key, java.lang.String value) { + if (this.deprecatedTopology == null && key != null && value != null) { + this.deprecatedTopology = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.deprecatedTopology.put(key, value); + } + return (A) this; } - public A addToDeprecatedTopology(java.util.Map map) { - if(this.deprecatedTopology == null && map != null) { this.deprecatedTopology = new java.util.LinkedHashMap(); } - if(map != null) { this.deprecatedTopology.putAll(map);} return (A)this; + + public A addToDeprecatedTopology(java.util.Map map) { + if (this.deprecatedTopology == null && map != null) { + this.deprecatedTopology = new java.util.LinkedHashMap(); + } + if (map != null) { + this.deprecatedTopology.putAll(map); + } + return (A) this; } + public A removeFromDeprecatedTopology(java.lang.String key) { - if(this.deprecatedTopology == null) { return (A) this; } - if(key != null && this.deprecatedTopology != null) {this.deprecatedTopology.remove(key);} return (A)this; + if (this.deprecatedTopology == null) { + return (A) this; + } + if (key != null && this.deprecatedTopology != null) { + this.deprecatedTopology.remove(key); + } + return (A) this; } - public A removeFromDeprecatedTopology(java.util.Map map) { - if(this.deprecatedTopology == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.deprecatedTopology != null){this.deprecatedTopology.remove(key);}}} return (A)this; + + public A removeFromDeprecatedTopology(java.util.Map map) { + if (this.deprecatedTopology == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.deprecatedTopology != null) { + this.deprecatedTopology.remove(key); + } + } + } + return (A) this; } - public java.util.Map getDeprecatedTopology() { + + public java.util.Map getDeprecatedTopology() { return this.deprecatedTopology; } - public A withDeprecatedTopology(java.util.Map deprecatedTopology) { - if (deprecatedTopology == null) { this.deprecatedTopology = null;} else {this.deprecatedTopology = new java.util.LinkedHashMap(deprecatedTopology);} return (A) this; + + public A withDeprecatedTopology( + java.util.Map deprecatedTopology) { + if (deprecatedTopology == null) { + this.deprecatedTopology = null; + } else { + this.deprecatedTopology = new java.util.LinkedHashMap(deprecatedTopology); + } + return (A) this; } + public java.lang.Boolean hasDeprecatedTopology() { return this.deprecatedTopology != null; } - + /** * This method has been deprecated, please use method buildHints instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EndpointHints getHints() { - return this.hints!=null ?this.hints.build():null; + return this.hints != null ? this.hints.build() : null; } + public io.kubernetes.client.openapi.models.V1EndpointHints buildHints() { - return this.hints!=null ?this.hints.build():null; + return this.hints != null ? this.hints.build() : null; } + public A withHints(io.kubernetes.client.openapi.models.V1EndpointHints hints) { _visitables.get("hints").remove(this.hints); - if (hints!=null){ this.hints= new io.kubernetes.client.openapi.models.V1EndpointHintsBuilder(hints); _visitables.get("hints").add(this.hints);} return (A) this; + if (hints != null) { + this.hints = new io.kubernetes.client.openapi.models.V1EndpointHintsBuilder(hints); + _visitables.get("hints").add(this.hints); + } + return (A) this; } + public java.lang.Boolean hasHints() { return this.hints != null; } + public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested withNewHints() { return new io.kubernetes.client.openapi.models.V1EndpointFluentImpl.HintsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested withNewHintsLike(io.kubernetes.client.openapi.models.V1EndpointHints item) { + + public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested withNewHintsLike( + io.kubernetes.client.openapi.models.V1EndpointHints item) { return new io.kubernetes.client.openapi.models.V1EndpointFluentImpl.HintsNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested editHints() { return withNewHintsLike(getHints()); } + public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested editOrNewHints() { - return withNewHintsLike(getHints() != null ? getHints(): new io.kubernetes.client.openapi.models.V1EndpointHintsBuilder().build()); + return withNewHintsLike( + getHints() != null + ? getHints() + : new io.kubernetes.client.openapi.models.V1EndpointHintsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested editOrNewHintsLike(io.kubernetes.client.openapi.models.V1EndpointHints item) { - return withNewHintsLike(getHints() != null ? getHints(): item); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested editOrNewHintsLike( + io.kubernetes.client.openapi.models.V1EndpointHints item) { + return withNewHintsLike(getHints() != null ? getHints() : item); } + public java.lang.String getHostname() { return this.hostname; } + public A withHostname(java.lang.String hostname) { - this.hostname=hostname; return (A) this; + this.hostname = hostname; + return (A) this; } + public java.lang.Boolean hasHostname() { return this.hostname != null; } - - /** - * Method is deprecated. use withHostname instead. - */ + + /** Method is deprecated. use withHostname instead. */ @java.lang.Deprecated public A withNewHostname(java.lang.String original) { - return (A)withHostname(new String(original)); + return (A) withHostname(new String(original)); } + public java.lang.String getNodeName() { return this.nodeName; } + public A withNodeName(java.lang.String nodeName) { - this.nodeName=nodeName; return (A) this; + this.nodeName = nodeName; + return (A) this; } + public java.lang.Boolean hasNodeName() { return this.nodeName != null; } - - /** - * Method is deprecated. use withNodeName instead. - */ + + /** Method is deprecated. use withNodeName instead. */ @java.lang.Deprecated public A withNewNodeName(java.lang.String original) { - return (A)withNodeName(new String(original)); + return (A) withNodeName(new String(original)); } - + /** * This method has been deprecated, please use method buildTargetRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getTargetRef() { - return this.targetRef!=null ?this.targetRef.build():null; + return this.targetRef != null ? this.targetRef.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectReference buildTargetRef() { - return this.targetRef!=null ?this.targetRef.build():null; + return this.targetRef != null ? this.targetRef.build() : null; } + public A withTargetRef(io.kubernetes.client.openapi.models.V1ObjectReference targetRef) { _visitables.get("targetRef").remove(this.targetRef); - if (targetRef!=null){ this.targetRef= new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(targetRef); _visitables.get("targetRef").add(this.targetRef);} return (A) this; + if (targetRef != null) { + this.targetRef = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(targetRef); + _visitables.get("targetRef").add(this.targetRef); + } + return (A) this; } + public java.lang.Boolean hasTargetRef() { return this.targetRef != null; } - public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested withNewTargetRef() { + + public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested + withNewTargetRef() { return new io.kubernetes.client.openapi.models.V1EndpointFluentImpl.TargetRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested withNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + + public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested + withNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { return new io.kubernetes.client.openapi.models.V1EndpointFluentImpl.TargetRefNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested editTargetRef() { return withNewTargetRefLike(getTargetRef()); } - public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested editOrNewTargetRef() { - return withNewTargetRefLike(getTargetRef() != null ? getTargetRef(): new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested + editOrNewTargetRef() { + return withNewTargetRefLike( + getTargetRef() != null + ? getTargetRef() + : new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested editOrNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return withNewTargetRefLike(getTargetRef() != null ? getTargetRef(): item); + + public io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested + editOrNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return withNewTargetRefLike(getTargetRef() != null ? getTargetRef() : item); } + public java.lang.String getZone() { return this.zone; } + public A withZone(java.lang.String zone) { - this.zone=zone; return (A) this; + this.zone = zone; + return (A) this; } + public java.lang.Boolean hasZone() { return this.zone != null; } - - /** - * Method is deprecated. use withZone instead. - */ + + /** Method is deprecated. use withZone instead. */ @java.lang.Deprecated public A withNewZone(java.lang.String original) { - return (A)withZone(new String(original)); + return (A) withZone(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1EndpointFluentImpl that = (V1EndpointFluentImpl) o; - if (addresses != null ? !addresses.equals(that.addresses) :that.addresses != null) return false; - if (conditions != null ? !conditions.equals(that.conditions) :that.conditions != null) return false; - if (deprecatedTopology != null ? !deprecatedTopology.equals(that.deprecatedTopology) :that.deprecatedTopology != null) return false; - if (hints != null ? !hints.equals(that.hints) :that.hints != null) return false; - if (hostname != null ? !hostname.equals(that.hostname) :that.hostname != null) return false; - if (nodeName != null ? !nodeName.equals(that.nodeName) :that.nodeName != null) return false; - if (targetRef != null ? !targetRef.equals(that.targetRef) :that.targetRef != null) return false; - if (zone != null ? !zone.equals(that.zone) :that.zone != null) return false; + if (addresses != null ? !addresses.equals(that.addresses) : that.addresses != null) + return false; + if (conditions != null ? !conditions.equals(that.conditions) : that.conditions != null) + return false; + if (deprecatedTopology != null + ? !deprecatedTopology.equals(that.deprecatedTopology) + : that.deprecatedTopology != null) return false; + if (hints != null ? !hints.equals(that.hints) : that.hints != null) return false; + if (hostname != null ? !hostname.equals(that.hostname) : that.hostname != null) return false; + if (nodeName != null ? !nodeName.equals(that.nodeName) : that.nodeName != null) return false; + if (targetRef != null ? !targetRef.equals(that.targetRef) : that.targetRef != null) + return false; + if (zone != null ? !zone.equals(that.zone) : that.zone != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(addresses, conditions, deprecatedTopology, hints, hostname, nodeName, targetRef, zone, super.hashCode()); + return java.util.Objects.hash( + addresses, + conditions, + deprecatedTopology, + hints, + hostname, + nodeName, + targetRef, + zone, + super.hashCode()); } - public class ConditionsNestedImpl extends io.kubernetes.client.openapi.models.V1EndpointConditionsFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1EndpointConditionsFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1EndpointFluent.ConditionsNested, + io.kubernetes.client.fluent.Nested { ConditionsNestedImpl(io.kubernetes.client.openapi.models.V1EndpointConditions item) { - this.builder = new io.kubernetes.client.openapi.models.V1EndpointConditionsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1EndpointConditionsBuilder(this, item); } + ConditionsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1EndpointConditionsBuilder(this); } + io.kubernetes.client.openapi.models.V1EndpointConditionsBuilder builder; + public N and() { return (N) V1EndpointFluentImpl.this.withConditions(builder.build()); } + public N endConditions() { return and(); } - } - public class HintsNestedImpl extends io.kubernetes.client.openapi.models.V1EndpointHintsFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested,io.kubernetes.client.fluent.Nested{ + + public class HintsNestedImpl + extends io.kubernetes.client.openapi.models.V1EndpointHintsFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested> + implements io.kubernetes.client.openapi.models.V1EndpointFluent.HintsNested, + io.kubernetes.client.fluent.Nested { HintsNestedImpl(io.kubernetes.client.openapi.models.V1EndpointHints item) { this.builder = new io.kubernetes.client.openapi.models.V1EndpointHintsBuilder(this, item); } + HintsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1EndpointHintsBuilder(this); } + io.kubernetes.client.openapi.models.V1EndpointHintsBuilder builder; + public N and() { return (N) V1EndpointFluentImpl.this.withHints(builder.build()); } + public N endHints() { return and(); } - } - public class TargetRefNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested,io.kubernetes.client.fluent.Nested{ + + public class TargetRefNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested> + implements io.kubernetes.client.openapi.models.V1EndpointFluent.TargetRefNested, + io.kubernetes.client.fluent.Nested { TargetRefNestedImpl(io.kubernetes.client.openapi.models.V1ObjectReference item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + TargetRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; + public N and() { return (N) V1EndpointFluentImpl.this.withTargetRef(builder.build()); } + public N endTargetRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointHintsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointHintsBuilder.java index 982b08b54d..dffbd92bed 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointHintsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointHintsBuilder.java @@ -1,58 +1,96 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EndpointHintsBuilder extends io.kubernetes.client.openapi.models.V1EndpointHintsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EndpointHintsBuilder + extends io.kubernetes.client.openapi.models.V1EndpointHintsFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointHintsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EndpointHints, + io.kubernetes.client.openapi.models.V1EndpointHintsBuilder> { public V1EndpointHintsBuilder() { this(false); } + public V1EndpointHintsBuilder(java.lang.Boolean validationEnabled) { this(new V1EndpointHints(), validationEnabled); } - public V1EndpointHintsBuilder(io.kubernetes.client.openapi.models.V1EndpointHintsFluent fluent) { + + public V1EndpointHintsBuilder( + io.kubernetes.client.openapi.models.V1EndpointHintsFluent fluent) { this(fluent, false); } - public V1EndpointHintsBuilder(io.kubernetes.client.openapi.models.V1EndpointHintsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EndpointHintsBuilder( + io.kubernetes.client.openapi.models.V1EndpointHintsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EndpointHints(), validationEnabled); } - public V1EndpointHintsBuilder(io.kubernetes.client.openapi.models.V1EndpointHintsFluent fluent,io.kubernetes.client.openapi.models.V1EndpointHints instance) { + + public V1EndpointHintsBuilder( + io.kubernetes.client.openapi.models.V1EndpointHintsFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointHints instance) { this(fluent, instance, false); } - public V1EndpointHintsBuilder(io.kubernetes.client.openapi.models.V1EndpointHintsFluent fluent,io.kubernetes.client.openapi.models.V1EndpointHints instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EndpointHintsBuilder( + io.kubernetes.client.openapi.models.V1EndpointHintsFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointHints instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withForZones(instance.getForZones()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1EndpointHintsBuilder(io.kubernetes.client.openapi.models.V1EndpointHints instance) { - this(instance,false); + this(instance, false); } - public V1EndpointHintsBuilder(io.kubernetes.client.openapi.models.V1EndpointHints instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EndpointHintsBuilder( + io.kubernetes.client.openapi.models.V1EndpointHints instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withForZones(instance.getForZones()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EndpointHintsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EndpointHints build() { V1EndpointHints buildable = new V1EndpointHints(); buildable.setForZones(fluent.getForZones()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EndpointHintsBuilder that = (V1EndpointHintsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointHintsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointHintsFluent.java index 7726887bbf..508b03a064 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointHintsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointHintsFluent.java @@ -1,57 +1,98 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1EndpointHintsFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToForZones(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ForZone item); - public A setToForZones(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ForZone item); +/** Generated */ +public interface V1EndpointHintsFluent< + A extends io.kubernetes.client.openapi.models.V1EndpointHintsFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToForZones( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ForZone item); + + public A setToForZones( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ForZone item); + public A addToForZones(io.kubernetes.client.openapi.models.V1ForZone... items); - public A addAllToForZones(java.util.Collection items); + + public A addAllToForZones( + java.util.Collection items); + public A removeFromForZones(io.kubernetes.client.openapi.models.V1ForZone... items); - public A removeAllFromForZones(java.util.Collection items); - public A removeMatchingFromForZones(java.util.function.Predicate predicate); - + + public A removeAllFromForZones( + java.util.Collection items); + + public A removeMatchingFromForZones( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildForZones instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getForZones(); + public java.util.List buildForZones(); + public io.kubernetes.client.openapi.models.V1ForZone buildForZone(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ForZone buildFirstForZone(); + public io.kubernetes.client.openapi.models.V1ForZone buildLastForZone(); - public io.kubernetes.client.openapi.models.V1ForZone buildMatchingForZone(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingForZone(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ForZone buildMatchingForZone( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingForZone( + java.util.function.Predicate predicate); + public A withForZones(java.util.List forZones); + public A withForZones(io.kubernetes.client.openapi.models.V1ForZone... forZones); + public java.lang.Boolean hasForZones(); - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested addNewForZone(); - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested addNewForZoneLike(io.kubernetes.client.openapi.models.V1ForZone item); - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested setNewForZoneLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ForZone item); - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested editForZone(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested editFirstForZone(); - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested editLastForZone(); - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested editMatchingForZone(java.util.function.Predicate predicate); - public interface ForZonesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ForZoneFluent>{ + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested + addNewForZone(); + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested + addNewForZoneLike(io.kubernetes.client.openapi.models.V1ForZone item); + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested + setNewForZoneLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ForZone item); + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested editForZone( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested + editFirstForZone(); + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested + editLastForZone(); + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested + editMatchingForZone( + java.util.function.Predicate + predicate); + + public interface ForZonesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ForZoneFluent< + io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested> { public N and(); + public N endForZone(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointHintsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointHintsFluentImpl.java index 8691fd627f..32275bc226 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointHintsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointHintsFluentImpl.java @@ -1,55 +1,126 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1EndpointHintsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EndpointHintsFluent{ - public V1EndpointHintsFluentImpl() { - } +/** Generated */ +public class V1EndpointHintsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EndpointHintsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EndpointHintsFluent { + public V1EndpointHintsFluentImpl() {} + public V1EndpointHintsFluentImpl(io.kubernetes.client.openapi.models.V1EndpointHints instance) { this.withForZones(instance.getForZones()); - } + private java.util.ArrayList forZones; - public A addToForZones(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ForZone item) { - if (this.forZones == null) {this.forZones = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ForZoneBuilder builder = new io.kubernetes.client.openapi.models.V1ForZoneBuilder(item);_visitables.get("forZones").add(index >= 0 ? index : _visitables.get("forZones").size(), builder);this.forZones.add(index >= 0 ? index : forZones.size(), builder); return (A)this; + + public A addToForZones( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ForZone item) { + if (this.forZones == null) { + this.forZones = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ForZoneBuilder builder = + new io.kubernetes.client.openapi.models.V1ForZoneBuilder(item); + _visitables + .get("forZones") + .add(index >= 0 ? index : _visitables.get("forZones").size(), builder); + this.forZones.add(index >= 0 ? index : forZones.size(), builder); + return (A) this; } - public A setToForZones(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ForZone item) { - if (this.forZones == null) {this.forZones = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ForZoneBuilder builder = new io.kubernetes.client.openapi.models.V1ForZoneBuilder(item); - if (index < 0 || index >= _visitables.get("forZones").size()) { _visitables.get("forZones").add(builder); } else { _visitables.get("forZones").set(index, builder);} - if (index < 0 || index >= forZones.size()) { forZones.add(builder); } else { forZones.set(index, builder);} - return (A)this; + + public A setToForZones( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ForZone item) { + if (this.forZones == null) { + this.forZones = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ForZoneBuilder builder = + new io.kubernetes.client.openapi.models.V1ForZoneBuilder(item); + if (index < 0 || index >= _visitables.get("forZones").size()) { + _visitables.get("forZones").add(builder); + } else { + _visitables.get("forZones").set(index, builder); + } + if (index < 0 || index >= forZones.size()) { + forZones.add(builder); + } else { + forZones.set(index, builder); + } + return (A) this; } + public A addToForZones(io.kubernetes.client.openapi.models.V1ForZone... items) { - if (this.forZones == null) {this.forZones = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ForZone item : items) {io.kubernetes.client.openapi.models.V1ForZoneBuilder builder = new io.kubernetes.client.openapi.models.V1ForZoneBuilder(item);_visitables.get("forZones").add(builder);this.forZones.add(builder);} return (A)this; + if (this.forZones == null) { + this.forZones = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ForZone item : items) { + io.kubernetes.client.openapi.models.V1ForZoneBuilder builder = + new io.kubernetes.client.openapi.models.V1ForZoneBuilder(item); + _visitables.get("forZones").add(builder); + this.forZones.add(builder); + } + return (A) this; } - public A addAllToForZones(java.util.Collection items) { - if (this.forZones == null) {this.forZones = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ForZone item : items) {io.kubernetes.client.openapi.models.V1ForZoneBuilder builder = new io.kubernetes.client.openapi.models.V1ForZoneBuilder(item);_visitables.get("forZones").add(builder);this.forZones.add(builder);} return (A)this; + + public A addAllToForZones( + java.util.Collection items) { + if (this.forZones == null) { + this.forZones = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ForZone item : items) { + io.kubernetes.client.openapi.models.V1ForZoneBuilder builder = + new io.kubernetes.client.openapi.models.V1ForZoneBuilder(item); + _visitables.get("forZones").add(builder); + this.forZones.add(builder); + } + return (A) this; } + public A removeFromForZones(io.kubernetes.client.openapi.models.V1ForZone... items) { - for (io.kubernetes.client.openapi.models.V1ForZone item : items) {io.kubernetes.client.openapi.models.V1ForZoneBuilder builder = new io.kubernetes.client.openapi.models.V1ForZoneBuilder(item);_visitables.get("forZones").remove(builder);if (this.forZones != null) {this.forZones.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ForZone item : items) { + io.kubernetes.client.openapi.models.V1ForZoneBuilder builder = + new io.kubernetes.client.openapi.models.V1ForZoneBuilder(item); + _visitables.get("forZones").remove(builder); + if (this.forZones != null) { + this.forZones.remove(builder); + } + } + return (A) this; } - public A removeAllFromForZones(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ForZone item : items) {io.kubernetes.client.openapi.models.V1ForZoneBuilder builder = new io.kubernetes.client.openapi.models.V1ForZoneBuilder(item);_visitables.get("forZones").remove(builder);if (this.forZones != null) {this.forZones.remove(builder);}} return (A)this; + + public A removeAllFromForZones( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ForZone item : items) { + io.kubernetes.client.openapi.models.V1ForZoneBuilder builder = + new io.kubernetes.client.openapi.models.V1ForZoneBuilder(item); + _visitables.get("forZones").remove(builder); + if (this.forZones != null) { + this.forZones.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromForZones(java.util.function.Predicate predicate) { + + public A removeMatchingFromForZones( + java.util.function.Predicate + predicate) { if (forZones == null) return (A) this; final Iterator each = forZones.iterator(); final List visitables = _visitables.get("forZones"); @@ -60,104 +131,179 @@ public A removeMatchingFromForZones(java.util.function.Predicate getForZones() { return forZones != null ? build(forZones) : null; } + public java.util.List buildForZones() { return forZones != null ? build(forZones) : null; } + public io.kubernetes.client.openapi.models.V1ForZone buildForZone(java.lang.Integer index) { return this.forZones.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ForZone buildFirstForZone() { return this.forZones.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ForZone buildLastForZone() { return this.forZones.get(forZones.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ForZone buildMatchingForZone(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ForZoneBuilder item: forZones) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ForZone buildMatchingForZone( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ForZoneBuilder item : forZones) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingForZone(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ForZoneBuilder item: forZones) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingForZone( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ForZoneBuilder item : forZones) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withForZones(java.util.List forZones) { - if (this.forZones != null) { _visitables.get("forZones").removeAll(this.forZones);} - if (forZones != null) {this.forZones = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ForZone item : forZones){this.addToForZones(item);}} else { this.forZones = null;} return (A) this; + if (this.forZones != null) { + _visitables.get("forZones").removeAll(this.forZones); + } + if (forZones != null) { + this.forZones = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ForZone item : forZones) { + this.addToForZones(item); + } + } else { + this.forZones = null; + } + return (A) this; } + public A withForZones(io.kubernetes.client.openapi.models.V1ForZone... forZones) { - if (this.forZones != null) {this.forZones.clear();} - if (forZones != null) {for (io.kubernetes.client.openapi.models.V1ForZone item :forZones){ this.addToForZones(item);}} return (A) this; + if (this.forZones != null) { + this.forZones.clear(); + } + if (forZones != null) { + for (io.kubernetes.client.openapi.models.V1ForZone item : forZones) { + this.addToForZones(item); + } + } + return (A) this; } + public java.lang.Boolean hasForZones() { return forZones != null && !forZones.isEmpty(); } - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested addNewForZone() { + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested + addNewForZone() { return new io.kubernetes.client.openapi.models.V1EndpointHintsFluentImpl.ForZonesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested addNewForZoneLike(io.kubernetes.client.openapi.models.V1ForZone item) { - return new io.kubernetes.client.openapi.models.V1EndpointHintsFluentImpl.ForZonesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested + addNewForZoneLike(io.kubernetes.client.openapi.models.V1ForZone item) { + return new io.kubernetes.client.openapi.models.V1EndpointHintsFluentImpl.ForZonesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested setNewForZoneLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ForZone item) { - return new io.kubernetes.client.openapi.models.V1EndpointHintsFluentImpl.ForZonesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested + setNewForZoneLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ForZone item) { + return new io.kubernetes.client.openapi.models.V1EndpointHintsFluentImpl.ForZonesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested editForZone(java.lang.Integer index) { - if (forZones.size() <= index) throw new RuntimeException("Can't edit forZones. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested editForZone( + java.lang.Integer index) { + if (forZones.size() <= index) + throw new RuntimeException("Can't edit forZones. Index exceeds size."); return setNewForZoneLike(index, buildForZone(index)); } - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested editFirstForZone() { - if (forZones.size() == 0) throw new RuntimeException("Can't edit first forZones. The list is empty."); + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested + editFirstForZone() { + if (forZones.size() == 0) + throw new RuntimeException("Can't edit first forZones. The list is empty."); return setNewForZoneLike(0, buildForZone(0)); } - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested editLastForZone() { + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested + editLastForZone() { int index = forZones.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last forZones. The list is empty."); return setNewForZoneLike(index, buildForZone(index)); } - public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested editMatchingForZone(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested + editMatchingForZone( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1ForZoneFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested,io.kubernetes.client.fluent.Nested{ - ForZonesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ForZone item) { + + public class ForZonesNestedImpl + extends io.kubernetes.client.openapi.models.V1ForZoneFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested> + implements io.kubernetes.client.openapi.models.V1EndpointHintsFluent.ForZonesNested, + io.kubernetes.client.fluent.Nested { + ForZonesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ForZone item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ForZoneBuilder(this, item); } + ForZonesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ForZoneBuilder(this); } + io.kubernetes.client.openapi.models.V1ForZoneBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EndpointHintsFluentImpl.this.setToForZones(index,builder.build()); + return (N) V1EndpointHintsFluentImpl.this.setToForZones(index, builder.build()); } + public N endForZone() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceBuilder.java index 6c7812d13b..8f0a37608e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EndpointSliceBuilder extends io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EndpointSliceBuilder + extends io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointSliceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EndpointSlice, + io.kubernetes.client.openapi.models.V1EndpointSliceBuilder> { public V1EndpointSliceBuilder() { this(false); } + public V1EndpointSliceBuilder(java.lang.Boolean validationEnabled) { this(new V1EndpointSlice(), validationEnabled); } - public V1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1EndpointSliceFluent fluent) { + + public V1EndpointSliceBuilder( + io.kubernetes.client.openapi.models.V1EndpointSliceFluent fluent) { this(fluent, false); } - public V1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1EndpointSliceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EndpointSliceBuilder( + io.kubernetes.client.openapi.models.V1EndpointSliceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EndpointSlice(), validationEnabled); } - public V1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1EndpointSliceFluent fluent,io.kubernetes.client.openapi.models.V1EndpointSlice instance) { + + public V1EndpointSliceBuilder( + io.kubernetes.client.openapi.models.V1EndpointSliceFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointSlice instance) { this(fluent, instance, false); } - public V1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1EndpointSliceFluent fluent,io.kubernetes.client.openapi.models.V1EndpointSlice instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EndpointSliceBuilder( + io.kubernetes.client.openapi.models.V1EndpointSliceFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointSlice instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAddressType(instance.getAddressType()); fluent.withApiVersion(instance.getApiVersion()); @@ -33,13 +60,17 @@ public V1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1EndpointSlic fluent.withPorts(instance.getPorts()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1EndpointSlice instance) { - this(instance,false); + this(instance, false); } - public V1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1EndpointSlice instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EndpointSliceBuilder( + io.kubernetes.client.openapi.models.V1EndpointSlice instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAddressType(instance.getAddressType()); this.withApiVersion(instance.getApiVersion()); @@ -52,10 +83,12 @@ public V1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1EndpointSlic this.withPorts(instance.getPorts()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EndpointSliceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EndpointSlice build() { V1EndpointSlice buildable = new V1EndpointSlice(); buildable.setAddressType(fluent.getAddressType()); @@ -66,18 +99,23 @@ public io.kubernetes.client.openapi.models.V1EndpointSlice build() { buildable.setPorts(fluent.getPorts()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EndpointSliceBuilder that = (V1EndpointSliceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceFluent.java index db51eef059..97496112f9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceFluent.java @@ -1,133 +1,249 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1EndpointSliceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1EndpointSliceFluent< + A extends io.kubernetes.client.openapi.models.V1EndpointSliceFluent> + extends io.kubernetes.client.fluent.Fluent { public io.kubernetes.client.openapi.models.V1EndpointSlice.AddressTypeEnum getAddressType(); - public A withAddressType(io.kubernetes.client.openapi.models.V1EndpointSlice.AddressTypeEnum addressType); + + public A withAddressType( + io.kubernetes.client.openapi.models.V1EndpointSlice.AddressTypeEnum addressType); + public java.lang.Boolean hasAddressType(); + public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToEndpoints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoint item); - public A setToEndpoints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoint item); + + public A addToEndpoints( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoint item); + + public A setToEndpoints( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoint item); + public A addToEndpoints(io.kubernetes.client.openapi.models.V1Endpoint... items); - public A addAllToEndpoints(java.util.Collection items); + + public A addAllToEndpoints( + java.util.Collection items); + public A removeFromEndpoints(io.kubernetes.client.openapi.models.V1Endpoint... items); - public A removeAllFromEndpoints(java.util.Collection items); - public A removeMatchingFromEndpoints(java.util.function.Predicate predicate); - + + public A removeAllFromEndpoints( + java.util.Collection items); + + public A removeMatchingFromEndpoints( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildEndpoints instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getEndpoints(); + public java.util.List buildEndpoints(); + public io.kubernetes.client.openapi.models.V1Endpoint buildEndpoint(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Endpoint buildFirstEndpoint(); + public io.kubernetes.client.openapi.models.V1Endpoint buildLastEndpoint(); - public io.kubernetes.client.openapi.models.V1Endpoint buildMatchingEndpoint(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingEndpoint(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Endpoint buildMatchingEndpoint( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingEndpoint( + java.util.function.Predicate + predicate); + public A withEndpoints(java.util.List endpoints); + public A withEndpoints(io.kubernetes.client.openapi.models.V1Endpoint... endpoints); + public java.lang.Boolean hasEndpoints(); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested addNewEndpoint(); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested addNewEndpointLike(io.kubernetes.client.openapi.models.V1Endpoint item); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested setNewEndpointLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoint item); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested editEndpoint(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested editFirstEndpoint(); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested editLastEndpoint(); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested editMatchingEndpoint(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested + addNewEndpoint(); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested + addNewEndpointLike(io.kubernetes.client.openapi.models.V1Endpoint item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested + setNewEndpointLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoint item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested editEndpoint( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested + editFirstEndpoint(); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested + editLastEndpoint(); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested + editMatchingEndpoint( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item); - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item); + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item); + public A addToPorts(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort... items); - public A addAllToPorts(java.util.Collection items); + + public A addAllToPorts( + java.util.Collection items); + public A removeFromPorts(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort... items); - public A removeAllFromPorts(java.util.Collection items); - public A removeMatchingFromPorts(java.util.function.Predicate predicate); - + + public A removeAllFromPorts( + java.util.Collection items); + + public A removeMatchingFromPorts( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder> + predicate); + /** * This method has been deprecated, please use method buildPorts instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getPorts(); + public java.util.List buildPorts(); - public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort buildPort(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort buildPort( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort buildFirstPort(); + public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort buildLastPort(); - public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort buildMatchingPort(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate); - public A withPorts(java.util.List ports); + + public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort buildMatchingPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder> + predicate); + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder> + predicate); + + public A withPorts( + java.util.List ports); + public A withPorts(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort... ports); + public java.lang.Boolean hasPorts(); + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested addNewPort(); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested editPort(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested addNewPortLike( + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested editPort( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested editFirstPort(); + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested editLastPort(); - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate); - public interface EndpointsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EndpointFluent>{ + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested editMatchingPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder> + predicate); + + public interface EndpointsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EndpointFluent< + io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested> { public N and(); + public N endEndpoint(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface PortsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent>{ + + public interface PortsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluent< + io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested> { public N and(); + public N endPort(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceFluentImpl.java index 4be3a01eb1..9dc9f6ce20 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1EndpointSliceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EndpointSliceFluent{ - public V1EndpointSliceFluentImpl() { - } +/** Generated */ +public class V1EndpointSliceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EndpointSliceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EndpointSliceFluent { + public V1EndpointSliceFluentImpl() {} + public V1EndpointSliceFluentImpl(io.kubernetes.client.openapi.models.V1EndpointSlice instance) { this.withAddressType(instance.getAddressType()); @@ -32,68 +34,145 @@ public V1EndpointSliceFluentImpl(io.kubernetes.client.openapi.models.V1EndpointS this.withMetadata(instance.getMetadata()); this.withPorts(instance.getPorts()); - } + private io.kubernetes.client.openapi.models.V1EndpointSlice.AddressTypeEnum addressType; private java.lang.String apiVersion; private java.util.ArrayList endpoints; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; - private java.util.ArrayList ports; + private java.util.ArrayList + ports; + public io.kubernetes.client.openapi.models.V1EndpointSlice.AddressTypeEnum getAddressType() { return this.addressType; } - public A withAddressType(io.kubernetes.client.openapi.models.V1EndpointSlice.AddressTypeEnum addressType) { - this.addressType=addressType; return (A) this; + + public A withAddressType( + io.kubernetes.client.openapi.models.V1EndpointSlice.AddressTypeEnum addressType) { + this.addressType = addressType; + return (A) this; } + public java.lang.Boolean hasAddressType() { return this.addressType != null; } + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToEndpoints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoint item) { - if (this.endpoints == null) {this.endpoints = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EndpointBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointBuilder(item);_visitables.get("endpoints").add(index >= 0 ? index : _visitables.get("endpoints").size(), builder);this.endpoints.add(index >= 0 ? index : endpoints.size(), builder); return (A)this; + + public A addToEndpoints( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoint item) { + if (this.endpoints == null) { + this.endpoints = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EndpointBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointBuilder(item); + _visitables + .get("endpoints") + .add(index >= 0 ? index : _visitables.get("endpoints").size(), builder); + this.endpoints.add(index >= 0 ? index : endpoints.size(), builder); + return (A) this; } - public A setToEndpoints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoint item) { - if (this.endpoints == null) {this.endpoints = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EndpointBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointBuilder(item); - if (index < 0 || index >= _visitables.get("endpoints").size()) { _visitables.get("endpoints").add(builder); } else { _visitables.get("endpoints").set(index, builder);} - if (index < 0 || index >= endpoints.size()) { endpoints.add(builder); } else { endpoints.set(index, builder);} - return (A)this; + + public A setToEndpoints( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoint item) { + if (this.endpoints == null) { + this.endpoints = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EndpointBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointBuilder(item); + if (index < 0 || index >= _visitables.get("endpoints").size()) { + _visitables.get("endpoints").add(builder); + } else { + _visitables.get("endpoints").set(index, builder); + } + if (index < 0 || index >= endpoints.size()) { + endpoints.add(builder); + } else { + endpoints.set(index, builder); + } + return (A) this; } + public A addToEndpoints(io.kubernetes.client.openapi.models.V1Endpoint... items) { - if (this.endpoints == null) {this.endpoints = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Endpoint item : items) {io.kubernetes.client.openapi.models.V1EndpointBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointBuilder(item);_visitables.get("endpoints").add(builder);this.endpoints.add(builder);} return (A)this; + if (this.endpoints == null) { + this.endpoints = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Endpoint item : items) { + io.kubernetes.client.openapi.models.V1EndpointBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointBuilder(item); + _visitables.get("endpoints").add(builder); + this.endpoints.add(builder); + } + return (A) this; } - public A addAllToEndpoints(java.util.Collection items) { - if (this.endpoints == null) {this.endpoints = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Endpoint item : items) {io.kubernetes.client.openapi.models.V1EndpointBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointBuilder(item);_visitables.get("endpoints").add(builder);this.endpoints.add(builder);} return (A)this; + + public A addAllToEndpoints( + java.util.Collection items) { + if (this.endpoints == null) { + this.endpoints = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Endpoint item : items) { + io.kubernetes.client.openapi.models.V1EndpointBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointBuilder(item); + _visitables.get("endpoints").add(builder); + this.endpoints.add(builder); + } + return (A) this; } + public A removeFromEndpoints(io.kubernetes.client.openapi.models.V1Endpoint... items) { - for (io.kubernetes.client.openapi.models.V1Endpoint item : items) {io.kubernetes.client.openapi.models.V1EndpointBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointBuilder(item);_visitables.get("endpoints").remove(builder);if (this.endpoints != null) {this.endpoints.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Endpoint item : items) { + io.kubernetes.client.openapi.models.V1EndpointBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointBuilder(item); + _visitables.get("endpoints").remove(builder); + if (this.endpoints != null) { + this.endpoints.remove(builder); + } + } + return (A) this; } - public A removeAllFromEndpoints(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Endpoint item : items) {io.kubernetes.client.openapi.models.V1EndpointBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointBuilder(item);_visitables.get("endpoints").remove(builder);if (this.endpoints != null) {this.endpoints.remove(builder);}} return (A)this; + + public A removeAllFromEndpoints( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Endpoint item : items) { + io.kubernetes.client.openapi.models.V1EndpointBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointBuilder(item); + _visitables.get("endpoints").remove(builder); + if (this.endpoints != null) { + this.endpoints.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromEndpoints(java.util.function.Predicate predicate) { + + public A removeMatchingFromEndpoints( + java.util.function.Predicate + predicate) { if (endpoints == null) return (A) this; - final Iterator each = endpoints.iterator(); + final Iterator each = + endpoints.iterator(); final List visitables = _visitables.get("endpoints"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1EndpointBuilder builder = each.next(); @@ -102,155 +181,316 @@ public A removeMatchingFromEndpoints(java.util.function.Predicate getEndpoints() { return endpoints != null ? build(endpoints) : null; } + public java.util.List buildEndpoints() { return endpoints != null ? build(endpoints) : null; } + public io.kubernetes.client.openapi.models.V1Endpoint buildEndpoint(java.lang.Integer index) { return this.endpoints.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Endpoint buildFirstEndpoint() { return this.endpoints.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Endpoint buildLastEndpoint() { return this.endpoints.get(endpoints.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Endpoint buildMatchingEndpoint(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EndpointBuilder item: endpoints) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Endpoint buildMatchingEndpoint( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EndpointBuilder item : endpoints) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingEndpoint(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EndpointBuilder item: endpoints) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingEndpoint( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EndpointBuilder item : endpoints) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withEndpoints(java.util.List endpoints) { - if (this.endpoints != null) { _visitables.get("endpoints").removeAll(this.endpoints);} - if (endpoints != null) {this.endpoints = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Endpoint item : endpoints){this.addToEndpoints(item);}} else { this.endpoints = null;} return (A) this; + if (this.endpoints != null) { + _visitables.get("endpoints").removeAll(this.endpoints); + } + if (endpoints != null) { + this.endpoints = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Endpoint item : endpoints) { + this.addToEndpoints(item); + } + } else { + this.endpoints = null; + } + return (A) this; } + public A withEndpoints(io.kubernetes.client.openapi.models.V1Endpoint... endpoints) { - if (this.endpoints != null) {this.endpoints.clear();} - if (endpoints != null) {for (io.kubernetes.client.openapi.models.V1Endpoint item :endpoints){ this.addToEndpoints(item);}} return (A) this; + if (this.endpoints != null) { + this.endpoints.clear(); + } + if (endpoints != null) { + for (io.kubernetes.client.openapi.models.V1Endpoint item : endpoints) { + this.addToEndpoints(item); + } + } + return (A) this; } + public java.lang.Boolean hasEndpoints() { return endpoints != null && !endpoints.isEmpty(); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested addNewEndpoint() { + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested + addNewEndpoint() { return new io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl.EndpointsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested addNewEndpointLike(io.kubernetes.client.openapi.models.V1Endpoint item) { - return new io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl.EndpointsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested + addNewEndpointLike(io.kubernetes.client.openapi.models.V1Endpoint item) { + return new io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl.EndpointsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested setNewEndpointLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoint item) { - return new io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl.EndpointsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested + setNewEndpointLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoint item) { + return new io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl.EndpointsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested editEndpoint(java.lang.Integer index) { - if (endpoints.size() <= index) throw new RuntimeException("Can't edit endpoints. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested editEndpoint( + java.lang.Integer index) { + if (endpoints.size() <= index) + throw new RuntimeException("Can't edit endpoints. Index exceeds size."); return setNewEndpointLike(index, buildEndpoint(index)); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested editFirstEndpoint() { - if (endpoints.size() == 0) throw new RuntimeException("Can't edit first endpoints. The list is empty."); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested + editFirstEndpoint() { + if (endpoints.size() == 0) + throw new RuntimeException("Can't edit first endpoints. The list is empty."); return setNewEndpointLike(0, buildEndpoint(0)); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested editLastEndpoint() { + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested + editLastEndpoint() { int index = endpoints.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last endpoints. The list is empty."); return setNewEndpointLike(index, buildEndpoint(index)); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested editMatchingEndpoint(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested + editMatchingEndpoint( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(item);_visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder);this.ports.add(index >= 0 ? index : ports.size(), builder); return (A)this; + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder>(); + } + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(item); + _visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder); + this.ports.add(index >= 0 ? index : ports.size(), builder); + return (A) this; } - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(item); - if (index < 0 || index >= _visitables.get("ports").size()) { _visitables.get("ports").add(builder); } else { _visitables.get("ports").set(index, builder);} - if (index < 0 || index >= ports.size()) { ports.add(builder); } else { ports.set(index, builder);} - return (A)this; + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder>(); + } + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(item); + if (index < 0 || index >= _visitables.get("ports").size()) { + _visitables.get("ports").add(builder); + } else { + _visitables.get("ports").set(index, builder); + } + if (index < 0 || index >= ports.size()) { + ports.add(builder); + } else { + ports.set(index, builder); + } + return (A) this; } + public A addToPorts(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort... items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item : items) {io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + if (this.ports == null) { + this.ports = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder>(); + } + for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item : items) { + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } - public A addAllToPorts(java.util.Collection items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item : items) {io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + + public A addAllToPorts( + java.util.Collection items) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder>(); + } + for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item : items) { + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } + public A removeFromPorts(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort... items) { - for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item : items) {io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item : items) { + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeAllFromPorts(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item : items) {io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + + public A removeAllFromPorts( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item : items) { + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPorts(java.util.function.Predicate predicate) { + + public A removeMatchingFromPorts( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder> + predicate) { if (ports == null) return (A) this; - final Iterator each = ports.iterator(); + final Iterator each = + ports.iterator(); final List visitables = _visitables.get("ports"); while (each.hasNext()) { io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder = each.next(); @@ -259,144 +499,239 @@ public A removeMatchingFromPorts(java.util.function.Predicate getPorts() { return ports != null ? build(ports) : null; } + public java.util.List buildPorts() { return ports != null ? build(ports) : null; } - public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort buildPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort buildPort( + java.lang.Integer index) { return this.ports.get(index).build(); } + public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort buildFirstPort() { return this.ports.get(0).build(); } + public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort buildLastPort() { return this.ports.get(ports.size() - 1).build(); } - public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort buildMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder item: ports) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort buildMatchingPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder item : ports) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder item: ports) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder item : ports) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withPorts(java.util.List ports) { - if (this.ports != null) { _visitables.get("ports").removeAll(this.ports);} - if (ports != null) {this.ports = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item : ports){this.addToPorts(item);}} else { this.ports = null;} return (A) this; + + public A withPorts( + java.util.List ports) { + if (this.ports != null) { + _visitables.get("ports").removeAll(this.ports); + } + if (ports != null) { + this.ports = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item : ports) { + this.addToPorts(item); + } + } else { + this.ports = null; + } + return (A) this; } + public A withPorts(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort... ports) { - if (this.ports != null) {this.ports.clear();} - if (ports != null) {for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item :ports){ this.addToPorts(item);}} return (A) this; + if (this.ports != null) { + this.ports.clear(); + } + if (ports != null) { + for (io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item : ports) { + this.addToPorts(item); + } + } + return (A) this; } + public java.lang.Boolean hasPorts() { return ports != null && !ports.isEmpty(); } + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested addNewPort() { return new io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl.PortsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item) { - return new io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl.PortsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested addNewPortLike( + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item) { + return new io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl.PortsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item) { - return new io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl.PortsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item) { + return new io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl.PortsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested editPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested editPort( + java.lang.Integer index) { if (ports.size() <= index) throw new RuntimeException("Can't edit ports. Index exceeds size."); return setNewPortLike(index, buildPort(index)); } + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested editFirstPort() { if (ports.size() == 0) throw new RuntimeException("Can't edit first ports. The list is empty."); return setNewPortLike(0, buildPort(0)); } + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested editLastPort() { int index = ports.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ports. The list is empty."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested editMatchingPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1EndpointFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested,io.kubernetes.client.fluent.Nested{ - EndpointsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoint item) { + + public class EndpointsNestedImpl + extends io.kubernetes.client.openapi.models.V1EndpointFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested> + implements io.kubernetes.client.openapi.models.V1EndpointSliceFluent.EndpointsNested, + io.kubernetes.client.fluent.Nested { + EndpointsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoint item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1EndpointBuilder(this, item); } + EndpointsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1EndpointBuilder(this); } + io.kubernetes.client.openapi.models.V1EndpointBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EndpointSliceFluentImpl.this.setToEndpoints(index,builder.build()); + return (N) V1EndpointSliceFluentImpl.this.setToEndpoints(index, builder.build()); } + public N endEndpoint() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1EndpointSliceFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1EndpointSliceFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class PortsNestedImpl extends io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested,io.kubernetes.client.fluent.Nested{ - PortsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item) { + + public class PortsNestedImpl + extends io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested> + implements io.kubernetes.client.openapi.models.V1EndpointSliceFluent.PortsNested, + io.kubernetes.client.fluent.Nested { + PortsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.DiscoveryV1EndpointPort item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(this, item); } + PortsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder(this); } + io.kubernetes.client.openapi.models.DiscoveryV1EndpointPortBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EndpointSliceFluentImpl.this.setToPorts(index,builder.build()); + return (N) V1EndpointSliceFluentImpl.this.setToPorts(index, builder.build()); } + public N endPort() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceListBuilder.java index 76d7124528..c9f1aae2ef 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EndpointSliceListBuilder extends io.kubernetes.client.openapi.models.V1EndpointSliceListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EndpointSliceListBuilder + extends io.kubernetes.client.openapi.models.V1EndpointSliceListFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointSliceListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EndpointSliceList, + io.kubernetes.client.openapi.models.V1EndpointSliceListBuilder> { public V1EndpointSliceListBuilder() { this(false); } + public V1EndpointSliceListBuilder(java.lang.Boolean validationEnabled) { this(new V1EndpointSliceList(), validationEnabled); } - public V1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1EndpointSliceListFluent fluent) { + + public V1EndpointSliceListBuilder( + io.kubernetes.client.openapi.models.V1EndpointSliceListFluent fluent) { this(fluent, false); } - public V1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1EndpointSliceListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EndpointSliceListBuilder( + io.kubernetes.client.openapi.models.V1EndpointSliceListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EndpointSliceList(), validationEnabled); } - public V1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1EndpointSliceListFluent fluent,io.kubernetes.client.openapi.models.V1EndpointSliceList instance) { + + public V1EndpointSliceListBuilder( + io.kubernetes.client.openapi.models.V1EndpointSliceListFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointSliceList instance) { this(fluent, instance, false); } - public V1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1EndpointSliceListFluent fluent,io.kubernetes.client.openapi.models.V1EndpointSliceList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EndpointSliceListBuilder( + io.kubernetes.client.openapi.models.V1EndpointSliceListFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointSliceList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1Endpoint fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1EndpointSliceList instance) { - this(instance,false); + + public V1EndpointSliceListBuilder( + io.kubernetes.client.openapi.models.V1EndpointSliceList instance) { + this(instance, false); } - public V1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1EndpointSliceList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EndpointSliceListBuilder( + io.kubernetes.client.openapi.models.V1EndpointSliceList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1Endpoint this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EndpointSliceListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EndpointSliceList build() { V1EndpointSliceList buildable = new V1EndpointSliceList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1EndpointSliceList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EndpointSliceListBuilder that = (V1EndpointSliceListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceListFluent.java index 5dfc9f8892..cb4e9fee24 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceListFluent.java @@ -1,95 +1,158 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1EndpointSliceListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1EndpointSliceListFluent< + A extends io.kubernetes.client.openapi.models.V1EndpointSliceListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSlice item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSlice item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSlice item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSlice item); + public A addToItems(io.kubernetes.client.openapi.models.V1EndpointSlice... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1EndpointSlice... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1EndpointSlice buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EndpointSlice buildFirstItem(); + public io.kubernetes.client.openapi.models.V1EndpointSlice buildLastItem(); - public io.kubernetes.client.openapi.models.V1EndpointSlice buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1EndpointSlice buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1EndpointSlice... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1EndpointSlice item); - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSlice item); - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1EndpointSlice item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSlice item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EndpointSliceFluent>{ + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EndpointSliceFluent< + io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceListFluentImpl.java index 9e41474ac7..a1a85bf820 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSliceListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1EndpointSliceListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EndpointSliceListFluent{ - public V1EndpointSliceListFluentImpl() { - } - public V1EndpointSliceListFluentImpl(io.kubernetes.client.openapi.models.V1EndpointSliceList instance) { + +/** Generated */ +public class V1EndpointSliceListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EndpointSliceListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EndpointSliceListFluent { + public V1EndpointSliceListFluentImpl() {} + + public V1EndpointSliceListFluentImpl( + io.kubernetes.client.openapi.models.V1EndpointSliceList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1EndpointSliceListFluentImpl(io.kubernetes.client.openapi.models.V1Endpo this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSlice item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSlice item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSlice item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSlice item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1EndpointSlice... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EndpointSlice item : items) {io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EndpointSlice item : items) { + io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EndpointSlice item : items) {io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EndpointSlice item : items) { + io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1EndpointSlice... items) { - for (io.kubernetes.client.openapi.models.V1EndpointSlice item : items) {io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1EndpointSlice item : items) { + io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1EndpointSlice item : items) {io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1EndpointSlice item : items) { + io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder = each.next(); @@ -87,174 +159,280 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1EndpointSlice buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1EndpointSlice buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1EndpointSlice buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1EndpointSlice buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EndpointSliceBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1EndpointSlice buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EndpointSliceBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EndpointSliceBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EndpointSliceBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1EndpointSlice item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1EndpointSlice item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1EndpointSlice... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1EndpointSlice item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1EndpointSlice item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1EndpointSliceListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1EndpointSlice item) { - return new io.kubernetes.client.openapi.models.V1EndpointSliceListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1EndpointSlice item) { + return new io.kubernetes.client.openapi.models.V1EndpointSliceListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSlice item) { - return new io.kubernetes.client.openapi.models.V1EndpointSliceListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSlice item) { + return new io.kubernetes.client.openapi.models.V1EndpointSliceListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1EndpointSliceListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1EndpointSliceListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1EndpointSliceListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1EndpointSliceListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1EndpointSliceListFluentImpl that = (V1EndpointSliceListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSlice item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1EndpointSliceFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSlice item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1EndpointSliceBuilder(this); } + io.kubernetes.client.openapi.models.V1EndpointSliceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EndpointSliceListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1EndpointSliceListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1EndpointSliceListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1EndpointSliceListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSubsetBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSubsetBuilder.java index b434813871..389018fc06 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSubsetBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSubsetBuilder.java @@ -1,49 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EndpointSubsetBuilder extends io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EndpointSubsetBuilder + extends io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EndpointSubset, + io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder> { public V1EndpointSubsetBuilder() { this(false); } + public V1EndpointSubsetBuilder(java.lang.Boolean validationEnabled) { this(new V1EndpointSubset(), validationEnabled); } - public V1EndpointSubsetBuilder(io.kubernetes.client.openapi.models.V1EndpointSubsetFluent fluent) { + + public V1EndpointSubsetBuilder( + io.kubernetes.client.openapi.models.V1EndpointSubsetFluent fluent) { this(fluent, false); } - public V1EndpointSubsetBuilder(io.kubernetes.client.openapi.models.V1EndpointSubsetFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EndpointSubsetBuilder( + io.kubernetes.client.openapi.models.V1EndpointSubsetFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EndpointSubset(), validationEnabled); } - public V1EndpointSubsetBuilder(io.kubernetes.client.openapi.models.V1EndpointSubsetFluent fluent,io.kubernetes.client.openapi.models.V1EndpointSubset instance) { + + public V1EndpointSubsetBuilder( + io.kubernetes.client.openapi.models.V1EndpointSubsetFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointSubset instance) { this(fluent, instance, false); } - public V1EndpointSubsetBuilder(io.kubernetes.client.openapi.models.V1EndpointSubsetFluent fluent,io.kubernetes.client.openapi.models.V1EndpointSubset instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EndpointSubsetBuilder( + io.kubernetes.client.openapi.models.V1EndpointSubsetFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointSubset instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAddresses(instance.getAddresses()); fluent.withNotReadyAddresses(instance.getNotReadyAddresses()); fluent.withPorts(instance.getPorts()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1EndpointSubsetBuilder(io.kubernetes.client.openapi.models.V1EndpointSubset instance) { - this(instance,false); + this(instance, false); } - public V1EndpointSubsetBuilder(io.kubernetes.client.openapi.models.V1EndpointSubset instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EndpointSubsetBuilder( + io.kubernetes.client.openapi.models.V1EndpointSubset instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAddresses(instance.getAddresses()); this.withNotReadyAddresses(instance.getNotReadyAddresses()); this.withPorts(instance.getPorts()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EndpointSubsetFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EndpointSubset build() { V1EndpointSubset buildable = new V1EndpointSubset(); buildable.setAddresses(fluent.getAddresses()); @@ -51,18 +84,23 @@ public io.kubernetes.client.openapi.models.V1EndpointSubset build() { buildable.setPorts(fluent.getPorts()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EndpointSubsetBuilder that = (V1EndpointSubsetBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSubsetFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSubsetFluent.java index 5b436102e5..dd9f5ef308 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSubsetFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSubsetFluent.java @@ -1,127 +1,271 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1EndpointSubsetFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAddresses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointAddress item); - public A setToAddresses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointAddress item); +/** Generated */ +public interface V1EndpointSubsetFluent< + A extends io.kubernetes.client.openapi.models.V1EndpointSubsetFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAddresses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item); + + public A setToAddresses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item); + public A addToAddresses(io.kubernetes.client.openapi.models.V1EndpointAddress... items); - public A addAllToAddresses(java.util.Collection items); + + public A addAllToAddresses( + java.util.Collection items); + public A removeFromAddresses(io.kubernetes.client.openapi.models.V1EndpointAddress... items); - public A removeAllFromAddresses(java.util.Collection items); - public A removeMatchingFromAddresses(java.util.function.Predicate predicate); - + + public A removeAllFromAddresses( + java.util.Collection items); + + public A removeMatchingFromAddresses( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildAddresses instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getAddresses(); + public java.util.List buildAddresses(); - public io.kubernetes.client.openapi.models.V1EndpointAddress buildAddress(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EndpointAddress buildAddress( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EndpointAddress buildFirstAddress(); + public io.kubernetes.client.openapi.models.V1EndpointAddress buildLastAddress(); - public io.kubernetes.client.openapi.models.V1EndpointAddress buildMatchingAddress(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAddress(java.util.function.Predicate predicate); - public A withAddresses(java.util.List addresses); + + public io.kubernetes.client.openapi.models.V1EndpointAddress buildMatchingAddress( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingAddress( + java.util.function.Predicate + predicate); + + public A withAddresses( + java.util.List addresses); + public A withAddresses(io.kubernetes.client.openapi.models.V1EndpointAddress... addresses); + public java.lang.Boolean hasAddresses(); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested addNewAddress(); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested addNewAddressLike(io.kubernetes.client.openapi.models.V1EndpointAddress item); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested setNewAddressLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointAddress item); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested editAddress(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested editFirstAddress(); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested editLastAddress(); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested editMatchingAddress(java.util.function.Predicate predicate); - public A addToNotReadyAddresses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointAddress item); - public A setToNotReadyAddresses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointAddress item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested + addNewAddress(); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested + addNewAddressLike(io.kubernetes.client.openapi.models.V1EndpointAddress item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested + setNewAddressLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested editAddress( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested + editFirstAddress(); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested + editLastAddress(); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested + editMatchingAddress( + java.util.function.Predicate + predicate); + + public A addToNotReadyAddresses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item); + + public A setToNotReadyAddresses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item); + public A addToNotReadyAddresses(io.kubernetes.client.openapi.models.V1EndpointAddress... items); - public A addAllToNotReadyAddresses(java.util.Collection items); - public A removeFromNotReadyAddresses(io.kubernetes.client.openapi.models.V1EndpointAddress... items); - public A removeAllFromNotReadyAddresses(java.util.Collection items); - public A removeMatchingFromNotReadyAddresses(java.util.function.Predicate predicate); - + + public A addAllToNotReadyAddresses( + java.util.Collection items); + + public A removeFromNotReadyAddresses( + io.kubernetes.client.openapi.models.V1EndpointAddress... items); + + public A removeAllFromNotReadyAddresses( + java.util.Collection items); + + public A removeMatchingFromNotReadyAddresses( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildNotReadyAddresses instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getNotReadyAddresses(); - public java.util.List buildNotReadyAddresses(); - public io.kubernetes.client.openapi.models.V1EndpointAddress buildNotReadyAddress(java.lang.Integer index); + public java.util.List + getNotReadyAddresses(); + + public java.util.List + buildNotReadyAddresses(); + + public io.kubernetes.client.openapi.models.V1EndpointAddress buildNotReadyAddress( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EndpointAddress buildFirstNotReadyAddress(); + public io.kubernetes.client.openapi.models.V1EndpointAddress buildLastNotReadyAddress(); - public io.kubernetes.client.openapi.models.V1EndpointAddress buildMatchingNotReadyAddress(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingNotReadyAddress(java.util.function.Predicate predicate); - public A withNotReadyAddresses(java.util.List notReadyAddresses); - public A withNotReadyAddresses(io.kubernetes.client.openapi.models.V1EndpointAddress... notReadyAddresses); + + public io.kubernetes.client.openapi.models.V1EndpointAddress buildMatchingNotReadyAddress( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingNotReadyAddress( + java.util.function.Predicate + predicate); + + public A withNotReadyAddresses( + java.util.List notReadyAddresses); + + public A withNotReadyAddresses( + io.kubernetes.client.openapi.models.V1EndpointAddress... notReadyAddresses); + public java.lang.Boolean hasNotReadyAddresses(); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested addNewNotReadyAddress(); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested addNewNotReadyAddressLike(io.kubernetes.client.openapi.models.V1EndpointAddress item); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested setNewNotReadyAddressLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointAddress item); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested editNotReadyAddress(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested editFirstNotReadyAddress(); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested editLastNotReadyAddress(); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested editMatchingNotReadyAddress(java.util.function.Predicate predicate); - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.CoreV1EndpointPort item); - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.CoreV1EndpointPort item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + addNewNotReadyAddress(); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + addNewNotReadyAddressLike(io.kubernetes.client.openapi.models.V1EndpointAddress item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + setNewNotReadyAddressLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + editNotReadyAddress(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + editFirstNotReadyAddress(); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + editLastNotReadyAddress(); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + editMatchingNotReadyAddress( + java.util.function.Predicate + predicate); + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1EndpointPort item); + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1EndpointPort item); + public A addToPorts(io.kubernetes.client.openapi.models.CoreV1EndpointPort... items); - public A addAllToPorts(java.util.Collection items); + + public A addAllToPorts( + java.util.Collection items); + public A removeFromPorts(io.kubernetes.client.openapi.models.CoreV1EndpointPort... items); - public A removeAllFromPorts(java.util.Collection items); - public A removeMatchingFromPorts(java.util.function.Predicate predicate); - + + public A removeAllFromPorts( + java.util.Collection items); + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildPorts instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getPorts(); + public java.util.List buildPorts(); + public io.kubernetes.client.openapi.models.CoreV1EndpointPort buildPort(java.lang.Integer index); + public io.kubernetes.client.openapi.models.CoreV1EndpointPort buildFirstPort(); + public io.kubernetes.client.openapi.models.CoreV1EndpointPort buildLastPort(); - public io.kubernetes.client.openapi.models.CoreV1EndpointPort buildMatchingPort(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.CoreV1EndpointPort buildMatchingPort( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate); + public A withPorts(java.util.List ports); + public A withPorts(io.kubernetes.client.openapi.models.CoreV1EndpointPort... ports); + public java.lang.Boolean hasPorts(); + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested addNewPort(); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.CoreV1EndpointPort item); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.CoreV1EndpointPort item); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested editPort(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested addNewPortLike( + io.kubernetes.client.openapi.models.CoreV1EndpointPort item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1EndpointPort item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested editPort( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested editFirstPort(); + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested editLastPort(); - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate); - public interface AddressesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EndpointAddressFluent>{ + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested editMatchingPort( + java.util.function.Predicate + predicate); + + public interface AddressesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EndpointAddressFluent< + io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested> { public N and(); + public N endAddress(); - } - public interface NotReadyAddressesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EndpointAddressFluent>{ + + public interface NotReadyAddressesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EndpointAddressFluent< + io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested< + N>> { public N and(); + public N endNotReadyAddress(); - } - public interface PortsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent>{ + + public interface PortsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.CoreV1EndpointPortFluent< + io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested> { public N and(); + public N endPort(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSubsetFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSubsetFluentImpl.java index f136a5813d..66826f7e10 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSubsetFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointSubsetFluentImpl.java @@ -1,63 +1,137 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1EndpointSubsetFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EndpointSubsetFluent{ - public V1EndpointSubsetFluentImpl() { - } +/** Generated */ +public class V1EndpointSubsetFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EndpointSubsetFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EndpointSubsetFluent { + public V1EndpointSubsetFluentImpl() {} + public V1EndpointSubsetFluentImpl(io.kubernetes.client.openapi.models.V1EndpointSubset instance) { this.withAddresses(instance.getAddresses()); this.withNotReadyAddresses(instance.getNotReadyAddresses()); this.withPorts(instance.getPorts()); - } - private java.util.ArrayList addresses; - private java.util.ArrayList notReadyAddresses; + + private java.util.ArrayList + addresses; + private java.util.ArrayList + notReadyAddresses; private java.util.ArrayList ports; - public A addToAddresses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointAddress item) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item);_visitables.get("addresses").add(index >= 0 ? index : _visitables.get("addresses").size(), builder);this.addresses.add(index >= 0 ? index : addresses.size(), builder); return (A)this; + + public A addToAddresses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item) { + if (this.addresses == null) { + this.addresses = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); + _visitables + .get("addresses") + .add(index >= 0 ? index : _visitables.get("addresses").size(), builder); + this.addresses.add(index >= 0 ? index : addresses.size(), builder); + return (A) this; } - public A setToAddresses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointAddress item) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); - if (index < 0 || index >= _visitables.get("addresses").size()) { _visitables.get("addresses").add(builder); } else { _visitables.get("addresses").set(index, builder);} - if (index < 0 || index >= addresses.size()) { addresses.add(builder); } else { addresses.set(index, builder);} - return (A)this; + + public A setToAddresses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item) { + if (this.addresses == null) { + this.addresses = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); + if (index < 0 || index >= _visitables.get("addresses").size()) { + _visitables.get("addresses").add(builder); + } else { + _visitables.get("addresses").set(index, builder); + } + if (index < 0 || index >= addresses.size()) { + addresses.add(builder); + } else { + addresses.set(index, builder); + } + return (A) this; } + public A addToAddresses(io.kubernetes.client.openapi.models.V1EndpointAddress... items) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) {io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item);_visitables.get("addresses").add(builder);this.addresses.add(builder);} return (A)this; + if (this.addresses == null) { + this.addresses = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) { + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); + _visitables.get("addresses").add(builder); + this.addresses.add(builder); + } + return (A) this; } - public A addAllToAddresses(java.util.Collection items) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) {io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item);_visitables.get("addresses").add(builder);this.addresses.add(builder);} return (A)this; + + public A addAllToAddresses( + java.util.Collection items) { + if (this.addresses == null) { + this.addresses = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) { + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); + _visitables.get("addresses").add(builder); + this.addresses.add(builder); + } + return (A) this; } + public A removeFromAddresses(io.kubernetes.client.openapi.models.V1EndpointAddress... items) { - for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) {io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item);_visitables.get("addresses").remove(builder);if (this.addresses != null) {this.addresses.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) { + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); + _visitables.get("addresses").remove(builder); + if (this.addresses != null) { + this.addresses.remove(builder); + } + } + return (A) this; } - public A removeAllFromAddresses(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) {io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item);_visitables.get("addresses").remove(builder);if (this.addresses != null) {this.addresses.remove(builder);}} return (A)this; + + public A removeAllFromAddresses( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) { + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); + _visitables.get("addresses").remove(builder); + if (this.addresses != null) { + this.addresses.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromAddresses(java.util.function.Predicate predicate) { + + public A removeMatchingFromAddresses( + java.util.function.Predicate + predicate) { if (addresses == null) return (A) this; - final Iterator each = addresses.iterator(); + final Iterator each = + addresses.iterator(); final List visitables = _visitables.get("addresses"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = each.next(); @@ -66,104 +140,241 @@ public A removeMatchingFromAddresses(java.util.function.Predicate getAddresses() { return addresses != null ? build(addresses) : null; } + public java.util.List buildAddresses() { return addresses != null ? build(addresses) : null; } - public io.kubernetes.client.openapi.models.V1EndpointAddress buildAddress(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1EndpointAddress buildAddress( + java.lang.Integer index) { return this.addresses.get(index).build(); } + public io.kubernetes.client.openapi.models.V1EndpointAddress buildFirstAddress() { return this.addresses.get(0).build(); } + public io.kubernetes.client.openapi.models.V1EndpointAddress buildLastAddress() { return this.addresses.get(addresses.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1EndpointAddress buildMatchingAddress(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EndpointAddressBuilder item: addresses) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1EndpointAddress buildMatchingAddress( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EndpointAddressBuilder item : addresses) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingAddress(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EndpointAddressBuilder item: addresses) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAddress( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EndpointAddressBuilder item : addresses) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withAddresses(java.util.List addresses) { - if (this.addresses != null) { _visitables.get("addresses").removeAll(this.addresses);} - if (addresses != null) {this.addresses = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1EndpointAddress item : addresses){this.addToAddresses(item);}} else { this.addresses = null;} return (A) this; + + public A withAddresses( + java.util.List addresses) { + if (this.addresses != null) { + _visitables.get("addresses").removeAll(this.addresses); + } + if (addresses != null) { + this.addresses = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1EndpointAddress item : addresses) { + this.addToAddresses(item); + } + } else { + this.addresses = null; + } + return (A) this; } + public A withAddresses(io.kubernetes.client.openapi.models.V1EndpointAddress... addresses) { - if (this.addresses != null) {this.addresses.clear();} - if (addresses != null) {for (io.kubernetes.client.openapi.models.V1EndpointAddress item :addresses){ this.addToAddresses(item);}} return (A) this; + if (this.addresses != null) { + this.addresses.clear(); + } + if (addresses != null) { + for (io.kubernetes.client.openapi.models.V1EndpointAddress item : addresses) { + this.addToAddresses(item); + } + } + return (A) this; } + public java.lang.Boolean hasAddresses() { return addresses != null && !addresses.isEmpty(); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested addNewAddress() { + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested + addNewAddress() { return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl.AddressesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested addNewAddressLike(io.kubernetes.client.openapi.models.V1EndpointAddress item) { - return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl.AddressesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested + addNewAddressLike(io.kubernetes.client.openapi.models.V1EndpointAddress item) { + return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl.AddressesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested setNewAddressLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointAddress item) { - return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl.AddressesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested + setNewAddressLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item) { + return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl.AddressesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested editAddress(java.lang.Integer index) { - if (addresses.size() <= index) throw new RuntimeException("Can't edit addresses. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested editAddress( + java.lang.Integer index) { + if (addresses.size() <= index) + throw new RuntimeException("Can't edit addresses. Index exceeds size."); return setNewAddressLike(index, buildAddress(index)); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested editFirstAddress() { - if (addresses.size() == 0) throw new RuntimeException("Can't edit first addresses. The list is empty."); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested + editFirstAddress() { + if (addresses.size() == 0) + throw new RuntimeException("Can't edit first addresses. The list is empty."); return setNewAddressLike(0, buildAddress(0)); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested editLastAddress() { + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested + editLastAddress() { int index = addresses.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last addresses. The list is empty."); return setNewAddressLike(index, buildAddress(index)); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested editMatchingAddress(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested + editMatchingAddress( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item);_visitables.get("notReadyAddresses").add(index >= 0 ? index : _visitables.get("notReadyAddresses").size(), builder);this.notReadyAddresses.add(index >= 0 ? index : notReadyAddresses.size(), builder); return (A)this; + + public A addToNotReadyAddresses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item) { + if (this.notReadyAddresses == null) { + this.notReadyAddresses = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); + _visitables + .get("notReadyAddresses") + .add(index >= 0 ? index : _visitables.get("notReadyAddresses").size(), builder); + this.notReadyAddresses.add(index >= 0 ? index : notReadyAddresses.size(), builder); + return (A) this; } - public A setToNotReadyAddresses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointAddress item) { - if (this.notReadyAddresses == null) {this.notReadyAddresses = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); - if (index < 0 || index >= _visitables.get("notReadyAddresses").size()) { _visitables.get("notReadyAddresses").add(builder); } else { _visitables.get("notReadyAddresses").set(index, builder);} - if (index < 0 || index >= notReadyAddresses.size()) { notReadyAddresses.add(builder); } else { notReadyAddresses.set(index, builder);} - return (A)this; + + public A setToNotReadyAddresses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item) { + if (this.notReadyAddresses == null) { + this.notReadyAddresses = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); + if (index < 0 || index >= _visitables.get("notReadyAddresses").size()) { + _visitables.get("notReadyAddresses").add(builder); + } else { + _visitables.get("notReadyAddresses").set(index, builder); + } + if (index < 0 || index >= notReadyAddresses.size()) { + notReadyAddresses.add(builder); + } else { + notReadyAddresses.set(index, builder); + } + return (A) this; } + public A addToNotReadyAddresses(io.kubernetes.client.openapi.models.V1EndpointAddress... items) { - if (this.notReadyAddresses == null) {this.notReadyAddresses = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) {io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item);_visitables.get("notReadyAddresses").add(builder);this.notReadyAddresses.add(builder);} return (A)this; + if (this.notReadyAddresses == null) { + this.notReadyAddresses = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) { + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); + _visitables.get("notReadyAddresses").add(builder); + this.notReadyAddresses.add(builder); + } + return (A) this; } - public A addAllToNotReadyAddresses(java.util.Collection items) { - if (this.notReadyAddresses == null) {this.notReadyAddresses = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) {io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item);_visitables.get("notReadyAddresses").add(builder);this.notReadyAddresses.add(builder);} return (A)this; + + public A addAllToNotReadyAddresses( + java.util.Collection items) { + if (this.notReadyAddresses == null) { + this.notReadyAddresses = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) { + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); + _visitables.get("notReadyAddresses").add(builder); + this.notReadyAddresses.add(builder); + } + return (A) this; } - public A removeFromNotReadyAddresses(io.kubernetes.client.openapi.models.V1EndpointAddress... items) { - for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) {io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item);_visitables.get("notReadyAddresses").remove(builder);if (this.notReadyAddresses != null) {this.notReadyAddresses.remove(builder);}} return (A)this; + + public A removeFromNotReadyAddresses( + io.kubernetes.client.openapi.models.V1EndpointAddress... items) { + for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) { + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); + _visitables.get("notReadyAddresses").remove(builder); + if (this.notReadyAddresses != null) { + this.notReadyAddresses.remove(builder); + } + } + return (A) this; } - public A removeAllFromNotReadyAddresses(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) {io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item);_visitables.get("notReadyAddresses").remove(builder);if (this.notReadyAddresses != null) {this.notReadyAddresses.remove(builder);}} return (A)this; + + public A removeAllFromNotReadyAddresses( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1EndpointAddress item : items) { + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(item); + _visitables.get("notReadyAddresses").remove(builder); + if (this.notReadyAddresses != null) { + this.notReadyAddresses.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromNotReadyAddresses(java.util.function.Predicate predicate) { + + public A removeMatchingFromNotReadyAddresses( + java.util.function.Predicate + predicate) { if (notReadyAddresses == null) return (A) this; - final Iterator each = notReadyAddresses.iterator(); + final Iterator each = + notReadyAddresses.iterator(); final List visitables = _visitables.get("notReadyAddresses"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder = each.next(); @@ -172,104 +383,244 @@ public A removeMatchingFromNotReadyAddresses(java.util.function.Predicate getNotReadyAddresses() { + public java.util.List + getNotReadyAddresses() { return notReadyAddresses != null ? build(notReadyAddresses) : null; } - public java.util.List buildNotReadyAddresses() { + + public java.util.List + buildNotReadyAddresses() { return notReadyAddresses != null ? build(notReadyAddresses) : null; } - public io.kubernetes.client.openapi.models.V1EndpointAddress buildNotReadyAddress(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1EndpointAddress buildNotReadyAddress( + java.lang.Integer index) { return this.notReadyAddresses.get(index).build(); } + public io.kubernetes.client.openapi.models.V1EndpointAddress buildFirstNotReadyAddress() { return this.notReadyAddresses.get(0).build(); } + public io.kubernetes.client.openapi.models.V1EndpointAddress buildLastNotReadyAddress() { return this.notReadyAddresses.get(notReadyAddresses.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1EndpointAddress buildMatchingNotReadyAddress(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EndpointAddressBuilder item: notReadyAddresses) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1EndpointAddress buildMatchingNotReadyAddress( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EndpointAddressBuilder item : notReadyAddresses) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingNotReadyAddress(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EndpointAddressBuilder item: notReadyAddresses) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingNotReadyAddress( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EndpointAddressBuilder item : notReadyAddresses) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withNotReadyAddresses(java.util.List notReadyAddresses) { - if (this.notReadyAddresses != null) { _visitables.get("notReadyAddresses").removeAll(this.notReadyAddresses);} - if (notReadyAddresses != null) {this.notReadyAddresses = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1EndpointAddress item : notReadyAddresses){this.addToNotReadyAddresses(item);}} else { this.notReadyAddresses = null;} return (A) this; + + public A withNotReadyAddresses( + java.util.List notReadyAddresses) { + if (this.notReadyAddresses != null) { + _visitables.get("notReadyAddresses").removeAll(this.notReadyAddresses); + } + if (notReadyAddresses != null) { + this.notReadyAddresses = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1EndpointAddress item : notReadyAddresses) { + this.addToNotReadyAddresses(item); + } + } else { + this.notReadyAddresses = null; + } + return (A) this; } - public A withNotReadyAddresses(io.kubernetes.client.openapi.models.V1EndpointAddress... notReadyAddresses) { - if (this.notReadyAddresses != null) {this.notReadyAddresses.clear();} - if (notReadyAddresses != null) {for (io.kubernetes.client.openapi.models.V1EndpointAddress item :notReadyAddresses){ this.addToNotReadyAddresses(item);}} return (A) this; + + public A withNotReadyAddresses( + io.kubernetes.client.openapi.models.V1EndpointAddress... notReadyAddresses) { + if (this.notReadyAddresses != null) { + this.notReadyAddresses.clear(); + } + if (notReadyAddresses != null) { + for (io.kubernetes.client.openapi.models.V1EndpointAddress item : notReadyAddresses) { + this.addToNotReadyAddresses(item); + } + } + return (A) this; } + public java.lang.Boolean hasNotReadyAddresses() { return notReadyAddresses != null && !notReadyAddresses.isEmpty(); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested addNewNotReadyAddress() { - return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl.NotReadyAddressesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + addNewNotReadyAddress() { + return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl + .NotReadyAddressesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested addNewNotReadyAddressLike(io.kubernetes.client.openapi.models.V1EndpointAddress item) { - return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl.NotReadyAddressesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + addNewNotReadyAddressLike(io.kubernetes.client.openapi.models.V1EndpointAddress item) { + return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl + .NotReadyAddressesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested setNewNotReadyAddressLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointAddress item) { - return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl.NotReadyAddressesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + setNewNotReadyAddressLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item) { + return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl + .NotReadyAddressesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested editNotReadyAddress(java.lang.Integer index) { - if (notReadyAddresses.size() <= index) throw new RuntimeException("Can't edit notReadyAddresses. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + editNotReadyAddress(java.lang.Integer index) { + if (notReadyAddresses.size() <= index) + throw new RuntimeException("Can't edit notReadyAddresses. Index exceeds size."); return setNewNotReadyAddressLike(index, buildNotReadyAddress(index)); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested editFirstNotReadyAddress() { - if (notReadyAddresses.size() == 0) throw new RuntimeException("Can't edit first notReadyAddresses. The list is empty."); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + editFirstNotReadyAddress() { + if (notReadyAddresses.size() == 0) + throw new RuntimeException("Can't edit first notReadyAddresses. The list is empty."); return setNewNotReadyAddressLike(0, buildNotReadyAddress(0)); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested editLastNotReadyAddress() { + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + editLastNotReadyAddress() { int index = notReadyAddresses.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last notReadyAddresses. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last notReadyAddresses. The list is empty."); return setNewNotReadyAddressLike(index, buildNotReadyAddress(index)); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested editMatchingNotReadyAddress(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested + editMatchingNotReadyAddress( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(item);_visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder);this.ports.add(index >= 0 ? index : ports.size(), builder); return (A)this; + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1EndpointPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(item); + _visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder); + this.ports.add(index >= 0 ? index : ports.size(), builder); + return (A) this; } - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.CoreV1EndpointPort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(item); - if (index < 0 || index >= _visitables.get("ports").size()) { _visitables.get("ports").add(builder); } else { _visitables.get("ports").set(index, builder);} - if (index < 0 || index >= ports.size()) { ports.add(builder); } else { ports.set(index, builder);} - return (A)this; + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1EndpointPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(item); + if (index < 0 || index >= _visitables.get("ports").size()) { + _visitables.get("ports").add(builder); + } else { + _visitables.get("ports").set(index, builder); + } + if (index < 0 || index >= ports.size()) { + ports.add(builder); + } else { + ports.set(index, builder); + } + return (A) this; } + public A addToPorts(io.kubernetes.client.openapi.models.CoreV1EndpointPort... items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.CoreV1EndpointPort item : items) {io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.CoreV1EndpointPort item : items) { + io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } - public A addAllToPorts(java.util.Collection items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.CoreV1EndpointPort item : items) {io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + + public A addAllToPorts( + java.util.Collection items) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.CoreV1EndpointPort item : items) { + io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } + public A removeFromPorts(io.kubernetes.client.openapi.models.CoreV1EndpointPort... items) { - for (io.kubernetes.client.openapi.models.CoreV1EndpointPort item : items) {io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.CoreV1EndpointPort item : items) { + io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeAllFromPorts(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.CoreV1EndpointPort item : items) {io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + + public A removeAllFromPorts( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.CoreV1EndpointPort item : items) { + io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPorts(java.util.function.Predicate predicate) { + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate) { if (ports == null) return (A) this; - final Iterator each = ports.iterator(); + final Iterator each = + ports.iterator(); final List visitables = _visitables.get("ports"); while (each.hasNext()) { io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder = each.next(); @@ -278,144 +629,234 @@ public A removeMatchingFromPorts(java.util.function.Predicate getPorts() { return ports != null ? build(ports) : null; } + public java.util.List buildPorts() { return ports != null ? build(ports) : null; } + public io.kubernetes.client.openapi.models.CoreV1EndpointPort buildPort(java.lang.Integer index) { return this.ports.get(index).build(); } + public io.kubernetes.client.openapi.models.CoreV1EndpointPort buildFirstPort() { return this.ports.get(0).build(); } + public io.kubernetes.client.openapi.models.CoreV1EndpointPort buildLastPort() { return this.ports.get(ports.size() - 1).build(); } - public io.kubernetes.client.openapi.models.CoreV1EndpointPort buildMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder item: ports) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.CoreV1EndpointPort buildMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder item : ports) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder item: ports) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder item : ports) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withPorts(java.util.List ports) { - if (this.ports != null) { _visitables.get("ports").removeAll(this.ports);} - if (ports != null) {this.ports = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.CoreV1EndpointPort item : ports){this.addToPorts(item);}} else { this.ports = null;} return (A) this; + if (this.ports != null) { + _visitables.get("ports").removeAll(this.ports); + } + if (ports != null) { + this.ports = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.CoreV1EndpointPort item : ports) { + this.addToPorts(item); + } + } else { + this.ports = null; + } + return (A) this; } + public A withPorts(io.kubernetes.client.openapi.models.CoreV1EndpointPort... ports) { - if (this.ports != null) {this.ports.clear();} - if (ports != null) {for (io.kubernetes.client.openapi.models.CoreV1EndpointPort item :ports){ this.addToPorts(item);}} return (A) this; + if (this.ports != null) { + this.ports.clear(); + } + if (ports != null) { + for (io.kubernetes.client.openapi.models.CoreV1EndpointPort item : ports) { + this.addToPorts(item); + } + } + return (A) this; } + public java.lang.Boolean hasPorts() { return ports != null && !ports.isEmpty(); } + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested addNewPort() { return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl.PortsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.CoreV1EndpointPort item) { - return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl.PortsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested addNewPortLike( + io.kubernetes.client.openapi.models.CoreV1EndpointPort item) { + return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl.PortsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.CoreV1EndpointPort item) { - return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl.PortsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1EndpointPort item) { + return new io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl.PortsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested editPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested editPort( + java.lang.Integer index) { if (ports.size() <= index) throw new RuntimeException("Can't edit ports. Index exceeds size."); return setNewPortLike(index, buildPort(index)); } + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested editFirstPort() { if (ports.size() == 0) throw new RuntimeException("Can't edit first ports. The list is empty."); return setNewPortLike(0, buildPort(0)); } + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested editLastPort() { int index = ports.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ports. The list is empty."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested editMatchingPort( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1EndpointAddressFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested,io.kubernetes.client.fluent.Nested{ - AddressesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointAddress item) { + + public class AddressesNestedImpl + extends io.kubernetes.client.openapi.models.V1EndpointAddressFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested> + implements io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.AddressesNested, + io.kubernetes.client.fluent.Nested { + AddressesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(this, item); } + AddressesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(this); } + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EndpointSubsetFluentImpl.this.setToAddresses(index,builder.build()); + return (N) V1EndpointSubsetFluentImpl.this.setToAddresses(index, builder.build()); } + public N endAddress() { return and(); } - } - public class NotReadyAddressesNestedImpl extends io.kubernetes.client.openapi.models.V1EndpointAddressFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested,io.kubernetes.client.fluent.Nested{ - NotReadyAddressesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointAddress item) { + + public class NotReadyAddressesNestedImpl + extends io.kubernetes.client.openapi.models.V1EndpointAddressFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested> + implements io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.NotReadyAddressesNested< + N>, + io.kubernetes.client.fluent.Nested { + NotReadyAddressesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointAddress item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(this, item); } + NotReadyAddressesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1EndpointAddressBuilder(this); } + io.kubernetes.client.openapi.models.V1EndpointAddressBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EndpointSubsetFluentImpl.this.setToNotReadyAddresses(index,builder.build()); + return (N) V1EndpointSubsetFluentImpl.this.setToNotReadyAddresses(index, builder.build()); } + public N endNotReadyAddress() { return and(); } - } - public class PortsNestedImpl extends io.kubernetes.client.openapi.models.CoreV1EndpointPortFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested,io.kubernetes.client.fluent.Nested{ - PortsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.CoreV1EndpointPort item) { + + public class PortsNestedImpl + extends io.kubernetes.client.openapi.models.CoreV1EndpointPortFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested> + implements io.kubernetes.client.openapi.models.V1EndpointSubsetFluent.PortsNested, + io.kubernetes.client.fluent.Nested { + PortsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.CoreV1EndpointPort item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(this, item); } + PortsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder(this); } + io.kubernetes.client.openapi.models.CoreV1EndpointPortBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EndpointSubsetFluentImpl.this.setToPorts(index,builder.build()); + return (N) V1EndpointSubsetFluentImpl.this.setToPorts(index, builder.build()); } + public N endPort() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsBuilder.java index 7e3da75c3b..1cafb41fa4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EndpointsBuilder extends io.kubernetes.client.openapi.models.V1EndpointsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EndpointsBuilder + extends io.kubernetes.client.openapi.models.V1EndpointsFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Endpoints, + io.kubernetes.client.openapi.models.V1EndpointsBuilder> { public V1EndpointsBuilder() { this(false); } + public V1EndpointsBuilder(java.lang.Boolean validationEnabled) { this(new V1Endpoints(), validationEnabled); } + public V1EndpointsBuilder(io.kubernetes.client.openapi.models.V1EndpointsFluent fluent) { this(fluent, false); } - public V1EndpointsBuilder(io.kubernetes.client.openapi.models.V1EndpointsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EndpointsBuilder( + io.kubernetes.client.openapi.models.V1EndpointsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Endpoints(), validationEnabled); } - public V1EndpointsBuilder(io.kubernetes.client.openapi.models.V1EndpointsFluent fluent,io.kubernetes.client.openapi.models.V1Endpoints instance) { + + public V1EndpointsBuilder( + io.kubernetes.client.openapi.models.V1EndpointsFluent fluent, + io.kubernetes.client.openapi.models.V1Endpoints instance) { this(fluent, instance, false); } - public V1EndpointsBuilder(io.kubernetes.client.openapi.models.V1EndpointsFluent fluent,io.kubernetes.client.openapi.models.V1Endpoints instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EndpointsBuilder( + io.kubernetes.client.openapi.models.V1EndpointsFluent fluent, + io.kubernetes.client.openapi.models.V1Endpoints instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +55,17 @@ public V1EndpointsBuilder(io.kubernetes.client.openapi.models.V1EndpointsFluent< fluent.withSubsets(instance.getSubsets()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1EndpointsBuilder(io.kubernetes.client.openapi.models.V1Endpoints instance) { - this(instance,false); + this(instance, false); } - public V1EndpointsBuilder(io.kubernetes.client.openapi.models.V1Endpoints instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EndpointsBuilder( + io.kubernetes.client.openapi.models.V1Endpoints instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +74,12 @@ public V1EndpointsBuilder(io.kubernetes.client.openapi.models.V1Endpoints instan this.withSubsets(instance.getSubsets()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EndpointsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Endpoints build() { V1Endpoints buildable = new V1Endpoints(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1Endpoints build() { buildable.setSubsets(fluent.getSubsets()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EndpointsBuilder that = (V1EndpointsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsFluent.java index 36b78316cc..71f23453b3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsFluent.java @@ -1,95 +1,153 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1EndpointsFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1EndpointsFluent< + A extends io.kubernetes.client.openapi.models.V1EndpointsFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public A addToSubsets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSubset item); - public A setToSubsets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSubset item); + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public A addToSubsets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSubset item); + + public A setToSubsets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSubset item); + public A addToSubsets(io.kubernetes.client.openapi.models.V1EndpointSubset... items); - public A addAllToSubsets(java.util.Collection items); + + public A addAllToSubsets( + java.util.Collection items); + public A removeFromSubsets(io.kubernetes.client.openapi.models.V1EndpointSubset... items); - public A removeAllFromSubsets(java.util.Collection items); - public A removeMatchingFromSubsets(java.util.function.Predicate predicate); - + + public A removeAllFromSubsets( + java.util.Collection items); + + public A removeMatchingFromSubsets( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildSubsets instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getSubsets(); + public java.util.List buildSubsets(); + public io.kubernetes.client.openapi.models.V1EndpointSubset buildSubset(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EndpointSubset buildFirstSubset(); + public io.kubernetes.client.openapi.models.V1EndpointSubset buildLastSubset(); - public io.kubernetes.client.openapi.models.V1EndpointSubset buildMatchingSubset(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingSubset(java.util.function.Predicate predicate); - public A withSubsets(java.util.List subsets); + + public io.kubernetes.client.openapi.models.V1EndpointSubset buildMatchingSubset( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingSubset( + java.util.function.Predicate + predicate); + + public A withSubsets( + java.util.List subsets); + public A withSubsets(io.kubernetes.client.openapi.models.V1EndpointSubset... subsets); + public java.lang.Boolean hasSubsets(); + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested addNewSubset(); - public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested addNewSubsetLike(io.kubernetes.client.openapi.models.V1EndpointSubset item); - public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested setNewSubsetLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSubset item); - public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested editSubset(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested addNewSubsetLike( + io.kubernetes.client.openapi.models.V1EndpointSubset item); + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested setNewSubsetLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSubset item); + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested editSubset( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested editFirstSubset(); + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested editLastSubset(); - public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested editMatchingSubset(java.util.function.Predicate predicate); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested editMatchingSubset( + java.util.function.Predicate + predicate); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SubsetsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EndpointSubsetFluent>{ + + public interface SubsetsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EndpointSubsetFluent< + io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested> { public N and(); + public N endSubset(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsFluentImpl.java index 0466cdf6be..08999daaec 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1EndpointsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EndpointsFluent{ - public V1EndpointsFluentImpl() { - } +/** Generated */ +public class V1EndpointsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EndpointsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EndpointsFluent { + public V1EndpointsFluentImpl() {} + public V1EndpointsFluentImpl(io.kubernetes.client.openapi.models.V1Endpoints instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,108 +30,198 @@ public V1EndpointsFluentImpl(io.kubernetes.client.openapi.models.V1Endpoints ins this.withMetadata(instance.getMetadata()); this.withSubsets(instance.getSubsets()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private java.util.ArrayList subsets; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1EndpointsFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1EndpointsFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - public A addToSubsets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSubset item) { - if (this.subsets == null) {this.subsets = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(item);_visitables.get("subsets").add(index >= 0 ? index : _visitables.get("subsets").size(), builder);this.subsets.add(index >= 0 ? index : subsets.size(), builder); return (A)this; + + public A addToSubsets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSubset item) { + if (this.subsets == null) { + this.subsets = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(item); + _visitables.get("subsets").add(index >= 0 ? index : _visitables.get("subsets").size(), builder); + this.subsets.add(index >= 0 ? index : subsets.size(), builder); + return (A) this; } - public A setToSubsets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSubset item) { - if (this.subsets == null) {this.subsets = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(item); - if (index < 0 || index >= _visitables.get("subsets").size()) { _visitables.get("subsets").add(builder); } else { _visitables.get("subsets").set(index, builder);} - if (index < 0 || index >= subsets.size()) { subsets.add(builder); } else { subsets.set(index, builder);} - return (A)this; + + public A setToSubsets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSubset item) { + if (this.subsets == null) { + this.subsets = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(item); + if (index < 0 || index >= _visitables.get("subsets").size()) { + _visitables.get("subsets").add(builder); + } else { + _visitables.get("subsets").set(index, builder); + } + if (index < 0 || index >= subsets.size()) { + subsets.add(builder); + } else { + subsets.set(index, builder); + } + return (A) this; } + public A addToSubsets(io.kubernetes.client.openapi.models.V1EndpointSubset... items) { - if (this.subsets == null) {this.subsets = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EndpointSubset item : items) {io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(item);_visitables.get("subsets").add(builder);this.subsets.add(builder);} return (A)this; + if (this.subsets == null) { + this.subsets = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EndpointSubset item : items) { + io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(item); + _visitables.get("subsets").add(builder); + this.subsets.add(builder); + } + return (A) this; } - public A addAllToSubsets(java.util.Collection items) { - if (this.subsets == null) {this.subsets = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EndpointSubset item : items) {io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(item);_visitables.get("subsets").add(builder);this.subsets.add(builder);} return (A)this; + + public A addAllToSubsets( + java.util.Collection items) { + if (this.subsets == null) { + this.subsets = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EndpointSubset item : items) { + io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(item); + _visitables.get("subsets").add(builder); + this.subsets.add(builder); + } + return (A) this; } + public A removeFromSubsets(io.kubernetes.client.openapi.models.V1EndpointSubset... items) { - for (io.kubernetes.client.openapi.models.V1EndpointSubset item : items) {io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(item);_visitables.get("subsets").remove(builder);if (this.subsets != null) {this.subsets.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1EndpointSubset item : items) { + io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(item); + _visitables.get("subsets").remove(builder); + if (this.subsets != null) { + this.subsets.remove(builder); + } + } + return (A) this; } - public A removeAllFromSubsets(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1EndpointSubset item : items) {io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(item);_visitables.get("subsets").remove(builder);if (this.subsets != null) {this.subsets.remove(builder);}} return (A)this; + + public A removeAllFromSubsets( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1EndpointSubset item : items) { + io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(item); + _visitables.get("subsets").remove(builder); + if (this.subsets != null) { + this.subsets.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromSubsets(java.util.function.Predicate predicate) { + + public A removeMatchingFromSubsets( + java.util.function.Predicate + predicate) { if (subsets == null) return (A) this; - final Iterator each = subsets.iterator(); + final Iterator each = + subsets.iterator(); final List visitables = _visitables.get("subsets"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder = each.next(); @@ -138,123 +230,203 @@ public A removeMatchingFromSubsets(java.util.function.Predicate getSubsets() { return subsets != null ? build(subsets) : null; } + public java.util.List buildSubsets() { return subsets != null ? build(subsets) : null; } + public io.kubernetes.client.openapi.models.V1EndpointSubset buildSubset(java.lang.Integer index) { return this.subsets.get(index).build(); } + public io.kubernetes.client.openapi.models.V1EndpointSubset buildFirstSubset() { return this.subsets.get(0).build(); } + public io.kubernetes.client.openapi.models.V1EndpointSubset buildLastSubset() { return this.subsets.get(subsets.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1EndpointSubset buildMatchingSubset(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder item: subsets) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1EndpointSubset buildMatchingSubset( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder item : subsets) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingSubset(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder item: subsets) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingSubset( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder item : subsets) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withSubsets(java.util.List subsets) { - if (this.subsets != null) { _visitables.get("subsets").removeAll(this.subsets);} - if (subsets != null) {this.subsets = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1EndpointSubset item : subsets){this.addToSubsets(item);}} else { this.subsets = null;} return (A) this; + + public A withSubsets( + java.util.List subsets) { + if (this.subsets != null) { + _visitables.get("subsets").removeAll(this.subsets); + } + if (subsets != null) { + this.subsets = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1EndpointSubset item : subsets) { + this.addToSubsets(item); + } + } else { + this.subsets = null; + } + return (A) this; } + public A withSubsets(io.kubernetes.client.openapi.models.V1EndpointSubset... subsets) { - if (this.subsets != null) {this.subsets.clear();} - if (subsets != null) {for (io.kubernetes.client.openapi.models.V1EndpointSubset item :subsets){ this.addToSubsets(item);}} return (A) this; + if (this.subsets != null) { + this.subsets.clear(); + } + if (subsets != null) { + for (io.kubernetes.client.openapi.models.V1EndpointSubset item : subsets) { + this.addToSubsets(item); + } + } + return (A) this; } + public java.lang.Boolean hasSubsets() { return subsets != null && !subsets.isEmpty(); } + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested addNewSubset() { return new io.kubernetes.client.openapi.models.V1EndpointsFluentImpl.SubsetsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested addNewSubsetLike(io.kubernetes.client.openapi.models.V1EndpointSubset item) { - return new io.kubernetes.client.openapi.models.V1EndpointsFluentImpl.SubsetsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested addNewSubsetLike( + io.kubernetes.client.openapi.models.V1EndpointSubset item) { + return new io.kubernetes.client.openapi.models.V1EndpointsFluentImpl.SubsetsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested setNewSubsetLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSubset item) { - return new io.kubernetes.client.openapi.models.V1EndpointsFluentImpl.SubsetsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested setNewSubsetLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSubset item) { + return new io.kubernetes.client.openapi.models.V1EndpointsFluentImpl.SubsetsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested editSubset(java.lang.Integer index) { - if (subsets.size() <= index) throw new RuntimeException("Can't edit subsets. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested editSubset( + java.lang.Integer index) { + if (subsets.size() <= index) + throw new RuntimeException("Can't edit subsets. Index exceeds size."); return setNewSubsetLike(index, buildSubset(index)); } + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested editFirstSubset() { - if (subsets.size() == 0) throw new RuntimeException("Can't edit first subsets. The list is empty."); + if (subsets.size() == 0) + throw new RuntimeException("Can't edit first subsets. The list is empty."); return setNewSubsetLike(0, buildSubset(0)); } + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested editLastSubset() { int index = subsets.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last subsets. The list is empty."); return setNewSubsetLike(index, buildSubset(index)); } - public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested editMatchingSubset(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested editMatchingSubset( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1EndpointsFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1EndpointsFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SubsetsNestedImpl extends io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested,io.kubernetes.client.fluent.Nested{ - SubsetsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EndpointSubset item) { + + public class SubsetsNestedImpl + extends io.kubernetes.client.openapi.models.V1EndpointSubsetFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested> + implements io.kubernetes.client.openapi.models.V1EndpointsFluent.SubsetsNested, + io.kubernetes.client.fluent.Nested { + SubsetsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EndpointSubset item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(this, item); } + SubsetsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder(this); } + io.kubernetes.client.openapi.models.V1EndpointSubsetBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EndpointsFluentImpl.this.setToSubsets(index,builder.build()); + return (N) V1EndpointsFluentImpl.this.setToSubsets(index, builder.build()); } + public N endSubset() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsListBuilder.java index 7c1cf6f2eb..ffcdc8997b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EndpointsListBuilder extends io.kubernetes.client.openapi.models.V1EndpointsListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EndpointsListBuilder + extends io.kubernetes.client.openapi.models.V1EndpointsListFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointsListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EndpointsList, + io.kubernetes.client.openapi.models.V1EndpointsListBuilder> { public V1EndpointsListBuilder() { this(false); } + public V1EndpointsListBuilder(java.lang.Boolean validationEnabled) { this(new V1EndpointsList(), validationEnabled); } - public V1EndpointsListBuilder(io.kubernetes.client.openapi.models.V1EndpointsListFluent fluent) { + + public V1EndpointsListBuilder( + io.kubernetes.client.openapi.models.V1EndpointsListFluent fluent) { this(fluent, false); } - public V1EndpointsListBuilder(io.kubernetes.client.openapi.models.V1EndpointsListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EndpointsListBuilder( + io.kubernetes.client.openapi.models.V1EndpointsListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EndpointsList(), validationEnabled); } - public V1EndpointsListBuilder(io.kubernetes.client.openapi.models.V1EndpointsListFluent fluent,io.kubernetes.client.openapi.models.V1EndpointsList instance) { + + public V1EndpointsListBuilder( + io.kubernetes.client.openapi.models.V1EndpointsListFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointsList instance) { this(fluent, instance, false); } - public V1EndpointsListBuilder(io.kubernetes.client.openapi.models.V1EndpointsListFluent fluent,io.kubernetes.client.openapi.models.V1EndpointsList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EndpointsListBuilder( + io.kubernetes.client.openapi.models.V1EndpointsListFluent fluent, + io.kubernetes.client.openapi.models.V1EndpointsList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1EndpointsListBuilder(io.kubernetes.client.openapi.models.V1EndpointsLis fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1EndpointsListBuilder(io.kubernetes.client.openapi.models.V1EndpointsList instance) { - this(instance,false); + this(instance, false); } - public V1EndpointsListBuilder(io.kubernetes.client.openapi.models.V1EndpointsList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EndpointsListBuilder( + io.kubernetes.client.openapi.models.V1EndpointsList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1EndpointsListBuilder(io.kubernetes.client.openapi.models.V1EndpointsLis this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EndpointsListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EndpointsList build() { V1EndpointsList buildable = new V1EndpointsList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1EndpointsList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EndpointsListBuilder that = (V1EndpointsListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsListFluent.java index 74e5395880..3c32448181 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsListFluent.java @@ -1,95 +1,153 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1EndpointsListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1EndpointsListFluent< + A extends io.kubernetes.client.openapi.models.V1EndpointsListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoints item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoints item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoints item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoints item); + public A addToItems(io.kubernetes.client.openapi.models.V1Endpoints... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1Endpoints... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1Endpoints buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Endpoints buildFirstItem(); + public io.kubernetes.client.openapi.models.V1Endpoints buildLastItem(); - public io.kubernetes.client.openapi.models.V1Endpoints buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Endpoints buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1Endpoints... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Endpoints item); - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoints item); - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Endpoints item); + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoints item); + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EndpointsFluent>{ + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EndpointsFluent< + io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsListFluentImpl.java index f904f09e58..df5c55d40d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EndpointsListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1EndpointsListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EndpointsListFluent{ - public V1EndpointsListFluentImpl() { - } +/** Generated */ +public class V1EndpointsListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EndpointsListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EndpointsListFluent { + public V1EndpointsListFluentImpl() {} + public V1EndpointsListFluentImpl(io.kubernetes.client.openapi.models.V1EndpointsList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,123 @@ public V1EndpointsListFluentImpl(io.kubernetes.client.openapi.models.V1Endpoints this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoints item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EndpointsBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointsBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoints item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EndpointsBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointsBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoints item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EndpointsBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointsBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoints item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EndpointsBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointsBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1Endpoints... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Endpoints item : items) {io.kubernetes.client.openapi.models.V1EndpointsBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointsBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Endpoints item : items) { + io.kubernetes.client.openapi.models.V1EndpointsBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointsBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Endpoints item : items) {io.kubernetes.client.openapi.models.V1EndpointsBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointsBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Endpoints item : items) { + io.kubernetes.client.openapi.models.V1EndpointsBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointsBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1Endpoints... items) { - for (io.kubernetes.client.openapi.models.V1Endpoints item : items) {io.kubernetes.client.openapi.models.V1EndpointsBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointsBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Endpoints item : items) { + io.kubernetes.client.openapi.models.V1EndpointsBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointsBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Endpoints item : items) {io.kubernetes.client.openapi.models.V1EndpointsBuilder builder = new io.kubernetes.client.openapi.models.V1EndpointsBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Endpoints item : items) { + io.kubernetes.client.openapi.models.V1EndpointsBuilder builder = + new io.kubernetes.client.openapi.models.V1EndpointsBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +157,274 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1Endpoints buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Endpoints buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Endpoints buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Endpoints buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EndpointsBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Endpoints buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EndpointsBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EndpointsBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EndpointsBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Endpoints item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Endpoints item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1Endpoints... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1Endpoints item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1Endpoints item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1EndpointsListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Endpoints item) { - return new io.kubernetes.client.openapi.models.V1EndpointsListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Endpoints item) { + return new io.kubernetes.client.openapi.models.V1EndpointsListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoints item) { - return new io.kubernetes.client.openapi.models.V1EndpointsListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoints item) { + return new io.kubernetes.client.openapi.models.V1EndpointsListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1EndpointsListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1EndpointsListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1EndpointsListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1EndpointsListFluentImpl that = (V1EndpointsListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1EndpointsFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Endpoints item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1EndpointsFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1EndpointsListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Endpoints item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1EndpointsBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1EndpointsBuilder(this); } + io.kubernetes.client.openapi.models.V1EndpointsBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EndpointsListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1EndpointsListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1EndpointsListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1EndpointsListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvFromSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvFromSourceBuilder.java index 4cb455bff7..bc6d7132e0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvFromSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvFromSourceBuilder.java @@ -1,49 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EnvFromSourceBuilder extends io.kubernetes.client.openapi.models.V1EnvFromSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EnvFromSourceBuilder + extends io.kubernetes.client.openapi.models.V1EnvFromSourceFluentImpl< + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EnvFromSource, + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder> { public V1EnvFromSourceBuilder() { this(false); } + public V1EnvFromSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1EnvFromSource(), validationEnabled); } - public V1EnvFromSourceBuilder(io.kubernetes.client.openapi.models.V1EnvFromSourceFluent fluent) { + + public V1EnvFromSourceBuilder( + io.kubernetes.client.openapi.models.V1EnvFromSourceFluent fluent) { this(fluent, false); } - public V1EnvFromSourceBuilder(io.kubernetes.client.openapi.models.V1EnvFromSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EnvFromSourceBuilder( + io.kubernetes.client.openapi.models.V1EnvFromSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EnvFromSource(), validationEnabled); } - public V1EnvFromSourceBuilder(io.kubernetes.client.openapi.models.V1EnvFromSourceFluent fluent,io.kubernetes.client.openapi.models.V1EnvFromSource instance) { + + public V1EnvFromSourceBuilder( + io.kubernetes.client.openapi.models.V1EnvFromSourceFluent fluent, + io.kubernetes.client.openapi.models.V1EnvFromSource instance) { this(fluent, instance, false); } - public V1EnvFromSourceBuilder(io.kubernetes.client.openapi.models.V1EnvFromSourceFluent fluent,io.kubernetes.client.openapi.models.V1EnvFromSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EnvFromSourceBuilder( + io.kubernetes.client.openapi.models.V1EnvFromSourceFluent fluent, + io.kubernetes.client.openapi.models.V1EnvFromSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConfigMapRef(instance.getConfigMapRef()); fluent.withPrefix(instance.getPrefix()); fluent.withSecretRef(instance.getSecretRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1EnvFromSourceBuilder(io.kubernetes.client.openapi.models.V1EnvFromSource instance) { - this(instance,false); + this(instance, false); } - public V1EnvFromSourceBuilder(io.kubernetes.client.openapi.models.V1EnvFromSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EnvFromSourceBuilder( + io.kubernetes.client.openapi.models.V1EnvFromSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConfigMapRef(instance.getConfigMapRef()); this.withPrefix(instance.getPrefix()); this.withSecretRef(instance.getSecretRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EnvFromSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EnvFromSource build() { V1EnvFromSource buildable = new V1EnvFromSource(); buildable.setConfigMapRef(fluent.getConfigMapRef()); @@ -51,18 +84,23 @@ public io.kubernetes.client.openapi.models.V1EnvFromSource build() { buildable.setSecretRef(fluent.getSecretRef()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EnvFromSourceBuilder that = (V1EnvFromSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvFromSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvFromSourceFluent.java index 6164236192..57202d9ffe 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvFromSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvFromSourceFluent.java @@ -1,64 +1,105 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1EnvFromSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1EnvFromSourceFluent< + A extends io.kubernetes.client.openapi.models.V1EnvFromSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildConfigMapRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ConfigMapEnvSource getConfigMapRef(); + public io.kubernetes.client.openapi.models.V1ConfigMapEnvSource buildConfigMapRef(); + public A withConfigMapRef(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource configMapRef); + public java.lang.Boolean hasConfigMapRef(); - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested withNewConfigMapRef(); - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested withNewConfigMapRefLike(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource item); - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested editConfigMapRef(); - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested editOrNewConfigMapRef(); - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested editOrNewConfigMapRefLike(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource item); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested + withNewConfigMapRef(); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested + withNewConfigMapRefLike(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource item); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested + editConfigMapRef(); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested + editOrNewConfigMapRef(); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested + editOrNewConfigMapRefLike(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource item); + public java.lang.String getPrefix(); + public A withPrefix(java.lang.String prefix); + public java.lang.Boolean hasPrefix(); - - /** - * Method is deprecated. use withPrefix instead. - */ + + /** Method is deprecated. use withPrefix instead. */ @java.lang.Deprecated public A withNewPrefix(java.lang.String original); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretEnvSource getSecretRef(); + public io.kubernetes.client.openapi.models.V1SecretEnvSource buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretEnvSource secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretEnvSource item); - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretEnvSource item); - public interface ConfigMapRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent>{ + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretEnvSource item); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretEnvSource item); + + public interface ConfigMapRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluent< + io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested> { public N and(); + public N endConfigMapRef(); - } - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent>{ + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent< + io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvFromSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvFromSourceFluentImpl.java index d51f4dae23..9a759142b5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvFromSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvFromSourceFluentImpl.java @@ -1,157 +1,231 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1EnvFromSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EnvFromSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EnvFromSourceFluent { + public V1EnvFromSourceFluentImpl() {} - /** - * Generated - */ -public class V1EnvFromSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EnvFromSourceFluent{ - public V1EnvFromSourceFluentImpl() { - } public V1EnvFromSourceFluentImpl(io.kubernetes.client.openapi.models.V1EnvFromSource instance) { this.withConfigMapRef(instance.getConfigMapRef()); this.withPrefix(instance.getPrefix()); this.withSecretRef(instance.getSecretRef()); - } + private io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceBuilder configMapRef; private java.lang.String prefix; private io.kubernetes.client.openapi.models.V1SecretEnvSourceBuilder secretRef; - + /** * This method has been deprecated, please use method buildConfigMapRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ConfigMapEnvSource getConfigMapRef() { - return this.configMapRef!=null ?this.configMapRef.build():null; + return this.configMapRef != null ? this.configMapRef.build() : null; } + public io.kubernetes.client.openapi.models.V1ConfigMapEnvSource buildConfigMapRef() { - return this.configMapRef!=null ?this.configMapRef.build():null; + return this.configMapRef != null ? this.configMapRef.build() : null; } + public A withConfigMapRef(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource configMapRef) { _visitables.get("configMapRef").remove(this.configMapRef); - if (configMapRef!=null){ this.configMapRef= new io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceBuilder(configMapRef); _visitables.get("configMapRef").add(this.configMapRef);} return (A) this; + if (configMapRef != null) { + this.configMapRef = + new io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceBuilder(configMapRef); + _visitables.get("configMapRef").add(this.configMapRef); + } + return (A) this; } + public java.lang.Boolean hasConfigMapRef() { return this.configMapRef != null; } - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested withNewConfigMapRef() { - return new io.kubernetes.client.openapi.models.V1EnvFromSourceFluentImpl.ConfigMapRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested + withNewConfigMapRef() { + return new io.kubernetes.client.openapi.models.V1EnvFromSourceFluentImpl + .ConfigMapRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested withNewConfigMapRefLike(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource item) { - return new io.kubernetes.client.openapi.models.V1EnvFromSourceFluentImpl.ConfigMapRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested + withNewConfigMapRefLike(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource item) { + return new io.kubernetes.client.openapi.models.V1EnvFromSourceFluentImpl.ConfigMapRefNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested editConfigMapRef() { + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested + editConfigMapRef() { return withNewConfigMapRefLike(getConfigMapRef()); } - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested editOrNewConfigMapRef() { - return withNewConfigMapRefLike(getConfigMapRef() != null ? getConfigMapRef(): new io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested + editOrNewConfigMapRef() { + return withNewConfigMapRefLike( + getConfigMapRef() != null + ? getConfigMapRef() + : new io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested editOrNewConfigMapRefLike(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource item) { - return withNewConfigMapRefLike(getConfigMapRef() != null ? getConfigMapRef(): item); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested + editOrNewConfigMapRefLike(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource item) { + return withNewConfigMapRefLike(getConfigMapRef() != null ? getConfigMapRef() : item); } + public java.lang.String getPrefix() { return this.prefix; } + public A withPrefix(java.lang.String prefix) { - this.prefix=prefix; return (A) this; + this.prefix = prefix; + return (A) this; } + public java.lang.Boolean hasPrefix() { return this.prefix != null; } - - /** - * Method is deprecated. use withPrefix instead. - */ + + /** Method is deprecated. use withPrefix instead. */ @java.lang.Deprecated public A withNewPrefix(java.lang.String original) { - return (A)withPrefix(new String(original)); + return (A) withPrefix(new String(original)); } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretEnvSource getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretEnvSource buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretEnvSource secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1SecretEnvSourceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = new io.kubernetes.client.openapi.models.V1SecretEnvSourceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested withNewSecretRef() { + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested + withNewSecretRef() { return new io.kubernetes.client.openapi.models.V1EnvFromSourceFluentImpl.SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretEnvSource item) { - return new io.kubernetes.client.openapi.models.V1EnvFromSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretEnvSource item) { + return new io.kubernetes.client.openapi.models.V1EnvFromSourceFluentImpl.SecretRefNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1SecretEnvSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1SecretEnvSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretEnvSource item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretEnvSource item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1EnvFromSourceFluentImpl that = (V1EnvFromSourceFluentImpl) o; - if (configMapRef != null ? !configMapRef.equals(that.configMapRef) :that.configMapRef != null) return false; - if (prefix != null ? !prefix.equals(that.prefix) :that.prefix != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; + if (configMapRef != null ? !configMapRef.equals(that.configMapRef) : that.configMapRef != null) + return false; + if (prefix != null ? !prefix.equals(that.prefix) : that.prefix != null) return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(configMapRef, prefix, secretRef, super.hashCode()); + return java.util.Objects.hash(configMapRef, prefix, secretRef, super.hashCode()); } - public class ConfigMapRefNestedImpl extends io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested,io.kubernetes.client.fluent.Nested{ + + public class ConfigMapRefNestedImpl + extends io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceFluentImpl< + io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested> + implements io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.ConfigMapRefNested, + io.kubernetes.client.fluent.Nested { ConfigMapRefNestedImpl(io.kubernetes.client.openapi.models.V1ConfigMapEnvSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceBuilder(this, item); } + ConfigMapRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1ConfigMapEnvSourceBuilder builder; + public N and() { return (N) V1EnvFromSourceFluentImpl.this.withConfigMapRef(builder.build()); } + public N endConfigMapRef() { return and(); } - } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1SecretEnvSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretEnvSourceFluentImpl< + io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested> + implements io.kubernetes.client.openapi.models.V1EnvFromSourceFluent.SecretRefNested, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1SecretEnvSource item) { this.builder = new io.kubernetes.client.openapi.models.V1SecretEnvSourceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretEnvSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretEnvSourceBuilder builder; + public N and() { return (N) V1EnvFromSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarBuilder.java index 6715990d47..7a7da3b628 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarBuilder.java @@ -1,49 +1,80 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EnvVarBuilder extends io.kubernetes.client.openapi.models.V1EnvVarFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EnvVarBuilder + extends io.kubernetes.client.openapi.models.V1EnvVarFluentImpl< + io.kubernetes.client.openapi.models.V1EnvVarBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EnvVar, + io.kubernetes.client.openapi.models.V1EnvVarBuilder> { public V1EnvVarBuilder() { this(false); } + public V1EnvVarBuilder(java.lang.Boolean validationEnabled) { this(new V1EnvVar(), validationEnabled); } + public V1EnvVarBuilder(io.kubernetes.client.openapi.models.V1EnvVarFluent fluent) { this(fluent, false); } - public V1EnvVarBuilder(io.kubernetes.client.openapi.models.V1EnvVarFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EnvVarBuilder( + io.kubernetes.client.openapi.models.V1EnvVarFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EnvVar(), validationEnabled); } - public V1EnvVarBuilder(io.kubernetes.client.openapi.models.V1EnvVarFluent fluent,io.kubernetes.client.openapi.models.V1EnvVar instance) { + + public V1EnvVarBuilder( + io.kubernetes.client.openapi.models.V1EnvVarFluent fluent, + io.kubernetes.client.openapi.models.V1EnvVar instance) { this(fluent, instance, false); } - public V1EnvVarBuilder(io.kubernetes.client.openapi.models.V1EnvVarFluent fluent,io.kubernetes.client.openapi.models.V1EnvVar instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EnvVarBuilder( + io.kubernetes.client.openapi.models.V1EnvVarFluent fluent, + io.kubernetes.client.openapi.models.V1EnvVar instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withValue(instance.getValue()); fluent.withValueFrom(instance.getValueFrom()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1EnvVarBuilder(io.kubernetes.client.openapi.models.V1EnvVar instance) { - this(instance,false); + this(instance, false); } - public V1EnvVarBuilder(io.kubernetes.client.openapi.models.V1EnvVar instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EnvVarBuilder( + io.kubernetes.client.openapi.models.V1EnvVar instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withValue(instance.getValue()); this.withValueFrom(instance.getValueFrom()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EnvVarFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EnvVar build() { V1EnvVar buildable = new V1EnvVar(); buildable.setName(fluent.getName()); @@ -51,18 +82,23 @@ public io.kubernetes.client.openapi.models.V1EnvVar build() { buildable.setValueFrom(fluent.getValueFrom()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EnvVarBuilder that = (V1EnvVarBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarFluent.java index e51c4c89f5..b2d4af9b4f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarFluent.java @@ -1,53 +1,72 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1EnvVarFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1EnvVarFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getValue(); + public A withValue(java.lang.String value); + public java.lang.Boolean hasValue(); - - /** - * Method is deprecated. use withValue instead. - */ + + /** Method is deprecated. use withValue instead. */ @java.lang.Deprecated public A withNewValue(java.lang.String original); - + /** * This method has been deprecated, please use method buildValueFrom instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EnvVarSource getValueFrom(); + public io.kubernetes.client.openapi.models.V1EnvVarSource buildValueFrom(); + public A withValueFrom(io.kubernetes.client.openapi.models.V1EnvVarSource valueFrom); + public java.lang.Boolean hasValueFrom(); + public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested withNewValueFrom(); - public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested withNewValueFromLike(io.kubernetes.client.openapi.models.V1EnvVarSource item); + + public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested withNewValueFromLike( + io.kubernetes.client.openapi.models.V1EnvVarSource item); + public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested editValueFrom(); + public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested editOrNewValueFrom(); - public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested editOrNewValueFromLike(io.kubernetes.client.openapi.models.V1EnvVarSource item); - public interface ValueFromNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EnvVarSourceFluent>{ + + public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested + editOrNewValueFromLike(io.kubernetes.client.openapi.models.V1EnvVarSource item); + + public interface ValueFromNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EnvVarSourceFluent< + io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested> { public N and(); + public N endValueFrom(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarFluentImpl.java index 75f87880f2..7bcf1f0f47 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarFluentImpl.java @@ -1,124 +1,162 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1EnvVarFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EnvVarFluent { + public V1EnvVarFluentImpl() {} - /** - * Generated - */ -public class V1EnvVarFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EnvVarFluent{ - public V1EnvVarFluentImpl() { - } public V1EnvVarFluentImpl(io.kubernetes.client.openapi.models.V1EnvVar instance) { this.withName(instance.getName()); this.withValue(instance.getValue()); this.withValueFrom(instance.getValueFrom()); - } + private java.lang.String name; private java.lang.String value; private io.kubernetes.client.openapi.models.V1EnvVarSourceBuilder valueFrom; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getValue() { return this.value; } + public A withValue(java.lang.String value) { - this.value=value; return (A) this; + this.value = value; + return (A) this; } + public java.lang.Boolean hasValue() { return this.value != null; } - - /** - * Method is deprecated. use withValue instead. - */ + + /** Method is deprecated. use withValue instead. */ @java.lang.Deprecated public A withNewValue(java.lang.String original) { - return (A)withValue(new String(original)); + return (A) withValue(new String(original)); } - + /** * This method has been deprecated, please use method buildValueFrom instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EnvVarSource getValueFrom() { - return this.valueFrom!=null ?this.valueFrom.build():null; + return this.valueFrom != null ? this.valueFrom.build() : null; } + public io.kubernetes.client.openapi.models.V1EnvVarSource buildValueFrom() { - return this.valueFrom!=null ?this.valueFrom.build():null; + return this.valueFrom != null ? this.valueFrom.build() : null; } + public A withValueFrom(io.kubernetes.client.openapi.models.V1EnvVarSource valueFrom) { _visitables.get("valueFrom").remove(this.valueFrom); - if (valueFrom!=null){ this.valueFrom= new io.kubernetes.client.openapi.models.V1EnvVarSourceBuilder(valueFrom); _visitables.get("valueFrom").add(this.valueFrom);} return (A) this; + if (valueFrom != null) { + this.valueFrom = new io.kubernetes.client.openapi.models.V1EnvVarSourceBuilder(valueFrom); + _visitables.get("valueFrom").add(this.valueFrom); + } + return (A) this; } + public java.lang.Boolean hasValueFrom() { return this.valueFrom != null; } + public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested withNewValueFrom() { return new io.kubernetes.client.openapi.models.V1EnvVarFluentImpl.ValueFromNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested withNewValueFromLike(io.kubernetes.client.openapi.models.V1EnvVarSource item) { + + public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested withNewValueFromLike( + io.kubernetes.client.openapi.models.V1EnvVarSource item) { return new io.kubernetes.client.openapi.models.V1EnvVarFluentImpl.ValueFromNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested editValueFrom() { return withNewValueFromLike(getValueFrom()); } - public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested editOrNewValueFrom() { - return withNewValueFromLike(getValueFrom() != null ? getValueFrom(): new io.kubernetes.client.openapi.models.V1EnvVarSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested + editOrNewValueFrom() { + return withNewValueFromLike( + getValueFrom() != null + ? getValueFrom() + : new io.kubernetes.client.openapi.models.V1EnvVarSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested editOrNewValueFromLike(io.kubernetes.client.openapi.models.V1EnvVarSource item) { - return withNewValueFromLike(getValueFrom() != null ? getValueFrom(): item); + + public io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested + editOrNewValueFromLike(io.kubernetes.client.openapi.models.V1EnvVarSource item) { + return withNewValueFromLike(getValueFrom() != null ? getValueFrom() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1EnvVarFluentImpl that = (V1EnvVarFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (value != null ? !value.equals(that.value) :that.value != null) return false; - if (valueFrom != null ? !valueFrom.equals(that.valueFrom) :that.valueFrom != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (value != null ? !value.equals(that.value) : that.value != null) return false; + if (valueFrom != null ? !valueFrom.equals(that.valueFrom) : that.valueFrom != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, value, valueFrom, super.hashCode()); + return java.util.Objects.hash(name, value, valueFrom, super.hashCode()); } - public class ValueFromNestedImpl extends io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested,io.kubernetes.client.fluent.Nested{ + + public class ValueFromNestedImpl + extends io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl< + io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested> + implements io.kubernetes.client.openapi.models.V1EnvVarFluent.ValueFromNested, + io.kubernetes.client.fluent.Nested { ValueFromNestedImpl(io.kubernetes.client.openapi.models.V1EnvVarSource item) { this.builder = new io.kubernetes.client.openapi.models.V1EnvVarSourceBuilder(this, item); } + ValueFromNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1EnvVarSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1EnvVarSourceBuilder builder; + public N and() { return (N) V1EnvVarFluentImpl.this.withValueFrom(builder.build()); } + public N endValueFrom() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarSourceBuilder.java index 1178888693..f5d56ffe2d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarSourceBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EnvVarSourceBuilder extends io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EnvVarSourceBuilder + extends io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl< + io.kubernetes.client.openapi.models.V1EnvVarSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EnvVarSource, + io.kubernetes.client.openapi.models.V1EnvVarSourceBuilder> { public V1EnvVarSourceBuilder() { this(false); } + public V1EnvVarSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1EnvVarSource(), validationEnabled); } + public V1EnvVarSourceBuilder(io.kubernetes.client.openapi.models.V1EnvVarSourceFluent fluent) { this(fluent, false); } - public V1EnvVarSourceBuilder(io.kubernetes.client.openapi.models.V1EnvVarSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EnvVarSourceBuilder( + io.kubernetes.client.openapi.models.V1EnvVarSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EnvVarSource(), validationEnabled); } - public V1EnvVarSourceBuilder(io.kubernetes.client.openapi.models.V1EnvVarSourceFluent fluent,io.kubernetes.client.openapi.models.V1EnvVarSource instance) { + + public V1EnvVarSourceBuilder( + io.kubernetes.client.openapi.models.V1EnvVarSourceFluent fluent, + io.kubernetes.client.openapi.models.V1EnvVarSource instance) { this(fluent, instance, false); } - public V1EnvVarSourceBuilder(io.kubernetes.client.openapi.models.V1EnvVarSourceFluent fluent,io.kubernetes.client.openapi.models.V1EnvVarSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EnvVarSourceBuilder( + io.kubernetes.client.openapi.models.V1EnvVarSourceFluent fluent, + io.kubernetes.client.openapi.models.V1EnvVarSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConfigMapKeyRef(instance.getConfigMapKeyRef()); fluent.withFieldRef(instance.getFieldRef()); @@ -29,13 +55,17 @@ public V1EnvVarSourceBuilder(io.kubernetes.client.openapi.models.V1EnvVarSourceF fluent.withSecretKeyRef(instance.getSecretKeyRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1EnvVarSourceBuilder(io.kubernetes.client.openapi.models.V1EnvVarSource instance) { - this(instance,false); + this(instance, false); } - public V1EnvVarSourceBuilder(io.kubernetes.client.openapi.models.V1EnvVarSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EnvVarSourceBuilder( + io.kubernetes.client.openapi.models.V1EnvVarSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConfigMapKeyRef(instance.getConfigMapKeyRef()); this.withFieldRef(instance.getFieldRef()); @@ -44,10 +74,12 @@ public V1EnvVarSourceBuilder(io.kubernetes.client.openapi.models.V1EnvVarSource this.withSecretKeyRef(instance.getSecretKeyRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EnvVarSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EnvVarSource build() { V1EnvVarSource buildable = new V1EnvVarSource(); buildable.setConfigMapKeyRef(fluent.getConfigMapKeyRef()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1EnvVarSource build() { buildable.setSecretKeyRef(fluent.getSecretKeyRef()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EnvVarSourceBuilder that = (V1EnvVarSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarSourceFluent.java index 0a434bc356..35ad87ffe8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarSourceFluent.java @@ -1,95 +1,173 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; - - /** - * Generated - */ -public interface V1EnvVarSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1EnvVarSourceFluent< + A extends io.kubernetes.client.openapi.models.V1EnvVarSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildConfigMapKeyRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ConfigMapKeySelector getConfigMapKeyRef(); + public io.kubernetes.client.openapi.models.V1ConfigMapKeySelector buildConfigMapKeyRef(); - public A withConfigMapKeyRef(io.kubernetes.client.openapi.models.V1ConfigMapKeySelector configMapKeyRef); + + public A withConfigMapKeyRef( + io.kubernetes.client.openapi.models.V1ConfigMapKeySelector configMapKeyRef); + public java.lang.Boolean hasConfigMapKeyRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested withNewConfigMapKeyRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested withNewConfigMapKeyRefLike(io.kubernetes.client.openapi.models.V1ConfigMapKeySelector item); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested editConfigMapKeyRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested editOrNewConfigMapKeyRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested editOrNewConfigMapKeyRefLike(io.kubernetes.client.openapi.models.V1ConfigMapKeySelector item); - + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested + withNewConfigMapKeyRef(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested + withNewConfigMapKeyRefLike(io.kubernetes.client.openapi.models.V1ConfigMapKeySelector item); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested + editConfigMapKeyRef(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested + editOrNewConfigMapKeyRef(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested + editOrNewConfigMapKeyRefLike(io.kubernetes.client.openapi.models.V1ConfigMapKeySelector item); + /** * This method has been deprecated, please use method buildFieldRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectFieldSelector getFieldRef(); + public io.kubernetes.client.openapi.models.V1ObjectFieldSelector buildFieldRef(); + public A withFieldRef(io.kubernetes.client.openapi.models.V1ObjectFieldSelector fieldRef); + public java.lang.Boolean hasFieldRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested withNewFieldRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested withNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested + withNewFieldRef(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested + withNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item); + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested editFieldRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested editOrNewFieldRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested editOrNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item); - + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested + editOrNewFieldRef(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested + editOrNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item); + /** * This method has been deprecated, please use method buildResourceFieldRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceFieldSelector getResourceFieldRef(); + public io.kubernetes.client.openapi.models.V1ResourceFieldSelector buildResourceFieldRef(); - public A withResourceFieldRef(io.kubernetes.client.openapi.models.V1ResourceFieldSelector resourceFieldRef); + + public A withResourceFieldRef( + io.kubernetes.client.openapi.models.V1ResourceFieldSelector resourceFieldRef); + public java.lang.Boolean hasResourceFieldRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested withNewResourceFieldRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested withNewResourceFieldRefLike(io.kubernetes.client.openapi.models.V1ResourceFieldSelector item); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested editResourceFieldRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested editOrNewResourceFieldRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested editOrNewResourceFieldRefLike(io.kubernetes.client.openapi.models.V1ResourceFieldSelector item); - + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested + withNewResourceFieldRef(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested + withNewResourceFieldRefLike(io.kubernetes.client.openapi.models.V1ResourceFieldSelector item); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested + editResourceFieldRef(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested + editOrNewResourceFieldRef(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested + editOrNewResourceFieldRefLike( + io.kubernetes.client.openapi.models.V1ResourceFieldSelector item); + /** * This method has been deprecated, please use method buildSecretKeyRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretKeySelector getSecretKeyRef(); + public io.kubernetes.client.openapi.models.V1SecretKeySelector buildSecretKeyRef(); + public A withSecretKeyRef(io.kubernetes.client.openapi.models.V1SecretKeySelector secretKeyRef); + public java.lang.Boolean hasSecretKeyRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested withNewSecretKeyRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested withNewSecretKeyRefLike(io.kubernetes.client.openapi.models.V1SecretKeySelector item); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested editSecretKeyRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested editOrNewSecretKeyRef(); - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested editOrNewSecretKeyRefLike(io.kubernetes.client.openapi.models.V1SecretKeySelector item); - public interface ConfigMapKeyRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent>{ + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested + withNewSecretKeyRef(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested + withNewSecretKeyRefLike(io.kubernetes.client.openapi.models.V1SecretKeySelector item); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested + editSecretKeyRef(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested + editOrNewSecretKeyRef(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested + editOrNewSecretKeyRefLike(io.kubernetes.client.openapi.models.V1SecretKeySelector item); + + public interface ConfigMapKeyRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluent< + io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested> { public N and(); + public N endConfigMapKeyRef(); - } - public interface FieldRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent>{ + + public interface FieldRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent< + io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested> { public N and(); + public N endFieldRef(); - } - public interface ResourceFieldRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent>{ + + public interface ResourceFieldRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent< + io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested> { public N and(); + public N endResourceFieldRef(); - } - public interface SecretKeyRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent>{ + + public interface SecretKeyRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent< + io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested> { public N and(); + public N endSecretKeyRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarSourceFluentImpl.java index 69cc591045..0020f35a2c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EnvVarSourceFluentImpl.java @@ -1,17 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Object; +/** Generated */ +public class V1EnvVarSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EnvVarSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EnvVarSourceFluent { + public V1EnvVarSourceFluentImpl() {} - /** - * Generated - */ -public class V1EnvVarSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EnvVarSourceFluent{ - public V1EnvVarSourceFluentImpl() { - } public V1EnvVarSourceFluentImpl(io.kubernetes.client.openapi.models.V1EnvVarSource instance) { this.withConfigMapKeyRef(instance.getConfigMapKeyRef()); @@ -20,224 +27,366 @@ public V1EnvVarSourceFluentImpl(io.kubernetes.client.openapi.models.V1EnvVarSour this.withResourceFieldRef(instance.getResourceFieldRef()); this.withSecretKeyRef(instance.getSecretKeyRef()); - } + private io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorBuilder configMapKeyRef; private io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder fieldRef; private io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder resourceFieldRef; private io.kubernetes.client.openapi.models.V1SecretKeySelectorBuilder secretKeyRef; - + /** * This method has been deprecated, please use method buildConfigMapKeyRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ConfigMapKeySelector getConfigMapKeyRef() { - return this.configMapKeyRef!=null ?this.configMapKeyRef.build():null; + return this.configMapKeyRef != null ? this.configMapKeyRef.build() : null; } + public io.kubernetes.client.openapi.models.V1ConfigMapKeySelector buildConfigMapKeyRef() { - return this.configMapKeyRef!=null ?this.configMapKeyRef.build():null; + return this.configMapKeyRef != null ? this.configMapKeyRef.build() : null; } - public A withConfigMapKeyRef(io.kubernetes.client.openapi.models.V1ConfigMapKeySelector configMapKeyRef) { + + public A withConfigMapKeyRef( + io.kubernetes.client.openapi.models.V1ConfigMapKeySelector configMapKeyRef) { _visitables.get("configMapKeyRef").remove(this.configMapKeyRef); - if (configMapKeyRef!=null){ this.configMapKeyRef= new io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorBuilder(configMapKeyRef); _visitables.get("configMapKeyRef").add(this.configMapKeyRef);} return (A) this; + if (configMapKeyRef != null) { + this.configMapKeyRef = + new io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorBuilder(configMapKeyRef); + _visitables.get("configMapKeyRef").add(this.configMapKeyRef); + } + return (A) this; } + public java.lang.Boolean hasConfigMapKeyRef() { return this.configMapKeyRef != null; } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested withNewConfigMapKeyRef() { - return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl.ConfigMapKeyRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested + withNewConfigMapKeyRef() { + return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl + .ConfigMapKeyRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested withNewConfigMapKeyRefLike(io.kubernetes.client.openapi.models.V1ConfigMapKeySelector item) { - return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl.ConfigMapKeyRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested + withNewConfigMapKeyRefLike(io.kubernetes.client.openapi.models.V1ConfigMapKeySelector item) { + return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl + .ConfigMapKeyRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested editConfigMapKeyRef() { + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested + editConfigMapKeyRef() { return withNewConfigMapKeyRefLike(getConfigMapKeyRef()); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested editOrNewConfigMapKeyRef() { - return withNewConfigMapKeyRefLike(getConfigMapKeyRef() != null ? getConfigMapKeyRef(): new io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested + editOrNewConfigMapKeyRef() { + return withNewConfigMapKeyRefLike( + getConfigMapKeyRef() != null + ? getConfigMapKeyRef() + : new io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested editOrNewConfigMapKeyRefLike(io.kubernetes.client.openapi.models.V1ConfigMapKeySelector item) { - return withNewConfigMapKeyRefLike(getConfigMapKeyRef() != null ? getConfigMapKeyRef(): item); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested + editOrNewConfigMapKeyRefLike( + io.kubernetes.client.openapi.models.V1ConfigMapKeySelector item) { + return withNewConfigMapKeyRefLike(getConfigMapKeyRef() != null ? getConfigMapKeyRef() : item); } - + /** * This method has been deprecated, please use method buildFieldRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectFieldSelector getFieldRef() { - return this.fieldRef!=null ?this.fieldRef.build():null; + return this.fieldRef != null ? this.fieldRef.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectFieldSelector buildFieldRef() { - return this.fieldRef!=null ?this.fieldRef.build():null; + return this.fieldRef != null ? this.fieldRef.build() : null; } + public A withFieldRef(io.kubernetes.client.openapi.models.V1ObjectFieldSelector fieldRef) { _visitables.get("fieldRef").remove(this.fieldRef); - if (fieldRef!=null){ this.fieldRef= new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder(fieldRef); _visitables.get("fieldRef").add(this.fieldRef);} return (A) this; + if (fieldRef != null) { + this.fieldRef = + new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder(fieldRef); + _visitables.get("fieldRef").add(this.fieldRef); + } + return (A) this; } + public java.lang.Boolean hasFieldRef() { return this.fieldRef != null; } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested withNewFieldRef() { + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested + withNewFieldRef() { return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl.FieldRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested withNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item) { - return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl.FieldRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested + withNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item) { + return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl.FieldRefNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested editFieldRef() { return withNewFieldRefLike(getFieldRef()); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested editOrNewFieldRef() { - return withNewFieldRefLike(getFieldRef() != null ? getFieldRef(): new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested + editOrNewFieldRef() { + return withNewFieldRefLike( + getFieldRef() != null + ? getFieldRef() + : new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested editOrNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item) { - return withNewFieldRefLike(getFieldRef() != null ? getFieldRef(): item); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested + editOrNewFieldRefLike(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item) { + return withNewFieldRefLike(getFieldRef() != null ? getFieldRef() : item); } - + /** * This method has been deprecated, please use method buildResourceFieldRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceFieldSelector getResourceFieldRef() { - return this.resourceFieldRef!=null ?this.resourceFieldRef.build():null; + return this.resourceFieldRef != null ? this.resourceFieldRef.build() : null; } + public io.kubernetes.client.openapi.models.V1ResourceFieldSelector buildResourceFieldRef() { - return this.resourceFieldRef!=null ?this.resourceFieldRef.build():null; + return this.resourceFieldRef != null ? this.resourceFieldRef.build() : null; } - public A withResourceFieldRef(io.kubernetes.client.openapi.models.V1ResourceFieldSelector resourceFieldRef) { + + public A withResourceFieldRef( + io.kubernetes.client.openapi.models.V1ResourceFieldSelector resourceFieldRef) { _visitables.get("resourceFieldRef").remove(this.resourceFieldRef); - if (resourceFieldRef!=null){ this.resourceFieldRef= new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder(resourceFieldRef); _visitables.get("resourceFieldRef").add(this.resourceFieldRef);} return (A) this; + if (resourceFieldRef != null) { + this.resourceFieldRef = + new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder(resourceFieldRef); + _visitables.get("resourceFieldRef").add(this.resourceFieldRef); + } + return (A) this; } + public java.lang.Boolean hasResourceFieldRef() { return this.resourceFieldRef != null; } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested withNewResourceFieldRef() { - return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl.ResourceFieldRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested + withNewResourceFieldRef() { + return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl + .ResourceFieldRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested withNewResourceFieldRefLike(io.kubernetes.client.openapi.models.V1ResourceFieldSelector item) { - return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl.ResourceFieldRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested + withNewResourceFieldRefLike( + io.kubernetes.client.openapi.models.V1ResourceFieldSelector item) { + return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl + .ResourceFieldRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested editResourceFieldRef() { + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested + editResourceFieldRef() { return withNewResourceFieldRefLike(getResourceFieldRef()); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested editOrNewResourceFieldRef() { - return withNewResourceFieldRefLike(getResourceFieldRef() != null ? getResourceFieldRef(): new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested + editOrNewResourceFieldRef() { + return withNewResourceFieldRefLike( + getResourceFieldRef() != null + ? getResourceFieldRef() + : new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested editOrNewResourceFieldRefLike(io.kubernetes.client.openapi.models.V1ResourceFieldSelector item) { - return withNewResourceFieldRefLike(getResourceFieldRef() != null ? getResourceFieldRef(): item); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested + editOrNewResourceFieldRefLike( + io.kubernetes.client.openapi.models.V1ResourceFieldSelector item) { + return withNewResourceFieldRefLike( + getResourceFieldRef() != null ? getResourceFieldRef() : item); } - + /** * This method has been deprecated, please use method buildSecretKeyRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretKeySelector getSecretKeyRef() { - return this.secretKeyRef!=null ?this.secretKeyRef.build():null; + return this.secretKeyRef != null ? this.secretKeyRef.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretKeySelector buildSecretKeyRef() { - return this.secretKeyRef!=null ?this.secretKeyRef.build():null; + return this.secretKeyRef != null ? this.secretKeyRef.build() : null; } + public A withSecretKeyRef(io.kubernetes.client.openapi.models.V1SecretKeySelector secretKeyRef) { _visitables.get("secretKeyRef").remove(this.secretKeyRef); - if (secretKeyRef!=null){ this.secretKeyRef= new io.kubernetes.client.openapi.models.V1SecretKeySelectorBuilder(secretKeyRef); _visitables.get("secretKeyRef").add(this.secretKeyRef);} return (A) this; + if (secretKeyRef != null) { + this.secretKeyRef = + new io.kubernetes.client.openapi.models.V1SecretKeySelectorBuilder(secretKeyRef); + _visitables.get("secretKeyRef").add(this.secretKeyRef); + } + return (A) this; } + public java.lang.Boolean hasSecretKeyRef() { return this.secretKeyRef != null; } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested withNewSecretKeyRef() { - return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl.SecretKeyRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested + withNewSecretKeyRef() { + return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl + .SecretKeyRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested withNewSecretKeyRefLike(io.kubernetes.client.openapi.models.V1SecretKeySelector item) { - return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl.SecretKeyRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested + withNewSecretKeyRefLike(io.kubernetes.client.openapi.models.V1SecretKeySelector item) { + return new io.kubernetes.client.openapi.models.V1EnvVarSourceFluentImpl.SecretKeyRefNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested editSecretKeyRef() { + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested + editSecretKeyRef() { return withNewSecretKeyRefLike(getSecretKeyRef()); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested editOrNewSecretKeyRef() { - return withNewSecretKeyRefLike(getSecretKeyRef() != null ? getSecretKeyRef(): new io.kubernetes.client.openapi.models.V1SecretKeySelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested + editOrNewSecretKeyRef() { + return withNewSecretKeyRefLike( + getSecretKeyRef() != null + ? getSecretKeyRef() + : new io.kubernetes.client.openapi.models.V1SecretKeySelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested editOrNewSecretKeyRefLike(io.kubernetes.client.openapi.models.V1SecretKeySelector item) { - return withNewSecretKeyRefLike(getSecretKeyRef() != null ? getSecretKeyRef(): item); + + public io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested + editOrNewSecretKeyRefLike(io.kubernetes.client.openapi.models.V1SecretKeySelector item) { + return withNewSecretKeyRefLike(getSecretKeyRef() != null ? getSecretKeyRef() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1EnvVarSourceFluentImpl that = (V1EnvVarSourceFluentImpl) o; - if (configMapKeyRef != null ? !configMapKeyRef.equals(that.configMapKeyRef) :that.configMapKeyRef != null) return false; - if (fieldRef != null ? !fieldRef.equals(that.fieldRef) :that.fieldRef != null) return false; - if (resourceFieldRef != null ? !resourceFieldRef.equals(that.resourceFieldRef) :that.resourceFieldRef != null) return false; - if (secretKeyRef != null ? !secretKeyRef.equals(that.secretKeyRef) :that.secretKeyRef != null) return false; + if (configMapKeyRef != null + ? !configMapKeyRef.equals(that.configMapKeyRef) + : that.configMapKeyRef != null) return false; + if (fieldRef != null ? !fieldRef.equals(that.fieldRef) : that.fieldRef != null) return false; + if (resourceFieldRef != null + ? !resourceFieldRef.equals(that.resourceFieldRef) + : that.resourceFieldRef != null) return false; + if (secretKeyRef != null ? !secretKeyRef.equals(that.secretKeyRef) : that.secretKeyRef != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(configMapKeyRef, fieldRef, resourceFieldRef, secretKeyRef, super.hashCode()); + return java.util.Objects.hash( + configMapKeyRef, fieldRef, resourceFieldRef, secretKeyRef, super.hashCode()); } - public class ConfigMapKeyRefNestedImpl extends io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested,io.kubernetes.client.fluent.Nested{ + + public class ConfigMapKeyRefNestedImpl + extends io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorFluentImpl< + io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested> + implements io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ConfigMapKeyRefNested, + io.kubernetes.client.fluent.Nested { ConfigMapKeyRefNestedImpl(io.kubernetes.client.openapi.models.V1ConfigMapKeySelector item) { - this.builder = new io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorBuilder(this, item); } + ConfigMapKeyRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1ConfigMapKeySelectorBuilder builder; + public N and() { return (N) V1EnvVarSourceFluentImpl.this.withConfigMapKeyRef(builder.build()); } + public N endConfigMapKeyRef() { return and(); } - } - public class FieldRefNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested,io.kubernetes.client.fluent.Nested{ + + public class FieldRefNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested> + implements io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.FieldRefNested, + io.kubernetes.client.fluent.Nested { FieldRefNestedImpl(io.kubernetes.client.openapi.models.V1ObjectFieldSelector item) { - this.builder = new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder(this, item); } + FieldRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder builder; + public N and() { return (N) V1EnvVarSourceFluentImpl.this.withFieldRef(builder.build()); } + public N endFieldRef() { return and(); } - } - public class ResourceFieldRefNestedImpl extends io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested,io.kubernetes.client.fluent.Nested{ + + public class ResourceFieldRefNestedImpl + extends io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested> + implements io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.ResourceFieldRefNested, + io.kubernetes.client.fluent.Nested { ResourceFieldRefNestedImpl(io.kubernetes.client.openapi.models.V1ResourceFieldSelector item) { - this.builder = new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder(this, item); } + ResourceFieldRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder builder; + public N and() { return (N) V1EnvVarSourceFluentImpl.this.withResourceFieldRef(builder.build()); } + public N endResourceFieldRef() { return and(); } - } - public class SecretKeyRefNestedImpl extends io.kubernetes.client.openapi.models.V1SecretKeySelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretKeyRefNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretKeySelectorFluentImpl< + io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested> + implements io.kubernetes.client.openapi.models.V1EnvVarSourceFluent.SecretKeyRefNested, + io.kubernetes.client.fluent.Nested { SecretKeyRefNestedImpl(io.kubernetes.client.openapi.models.V1SecretKeySelector item) { this.builder = new io.kubernetes.client.openapi.models.V1SecretKeySelectorBuilder(this, item); } + SecretKeyRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretKeySelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretKeySelectorBuilder builder; + public N and() { return (N) V1EnvVarSourceFluentImpl.this.withSecretKeyRef(builder.build()); } + public N endSecretKeyRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralContainerBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralContainerBuilder.java index e6aeb0d4ef..6ff2f5740e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralContainerBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralContainerBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EphemeralContainerBuilder extends io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EphemeralContainerBuilder + extends io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EphemeralContainer, + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder> { public V1EphemeralContainerBuilder() { this(false); } + public V1EphemeralContainerBuilder(java.lang.Boolean validationEnabled) { this(new V1EphemeralContainer(), validationEnabled); } - public V1EphemeralContainerBuilder(io.kubernetes.client.openapi.models.V1EphemeralContainerFluent fluent) { + + public V1EphemeralContainerBuilder( + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent fluent) { this(fluent, false); } - public V1EphemeralContainerBuilder(io.kubernetes.client.openapi.models.V1EphemeralContainerFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EphemeralContainerBuilder( + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EphemeralContainer(), validationEnabled); } - public V1EphemeralContainerBuilder(io.kubernetes.client.openapi.models.V1EphemeralContainerFluent fluent,io.kubernetes.client.openapi.models.V1EphemeralContainer instance) { + + public V1EphemeralContainerBuilder( + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent fluent, + io.kubernetes.client.openapi.models.V1EphemeralContainer instance) { this(fluent, instance, false); } - public V1EphemeralContainerBuilder(io.kubernetes.client.openapi.models.V1EphemeralContainerFluent fluent,io.kubernetes.client.openapi.models.V1EphemeralContainer instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EphemeralContainerBuilder( + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent fluent, + io.kubernetes.client.openapi.models.V1EphemeralContainer instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withArgs(instance.getArgs()); fluent.withCommand(instance.getCommand()); @@ -67,13 +94,18 @@ public V1EphemeralContainerBuilder(io.kubernetes.client.openapi.models.V1Ephemer fluent.withWorkingDir(instance.getWorkingDir()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1EphemeralContainerBuilder(io.kubernetes.client.openapi.models.V1EphemeralContainer instance) { - this(instance,false); + + public V1EphemeralContainerBuilder( + io.kubernetes.client.openapi.models.V1EphemeralContainer instance) { + this(instance, false); } - public V1EphemeralContainerBuilder(io.kubernetes.client.openapi.models.V1EphemeralContainer instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EphemeralContainerBuilder( + io.kubernetes.client.openapi.models.V1EphemeralContainer instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withArgs(instance.getArgs()); this.withCommand(instance.getCommand()); @@ -120,10 +152,12 @@ public V1EphemeralContainerBuilder(io.kubernetes.client.openapi.models.V1Ephemer this.withWorkingDir(instance.getWorkingDir()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EphemeralContainer build() { V1EphemeralContainer buildable = new V1EphemeralContainer(); buildable.setArgs(fluent.getArgs()); @@ -151,18 +185,23 @@ public io.kubernetes.client.openapi.models.V1EphemeralContainer build() { buildable.setWorkingDir(fluent.getWorkingDir()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EphemeralContainerBuilder that = (V1EphemeralContainerBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralContainerFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralContainerFluent.java index 978dbe65bf..e49ee35bec 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralContainerFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralContainerFluent.java @@ -1,409 +1,812 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.util.Collection; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import java.util.Iterator; -import java.lang.Integer; - - /** - * Generated - */ -public interface V1EphemeralContainerFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToArgs(java.lang.Integer index,java.lang.String item); - public A setToArgs(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1EphemeralContainerFluent< + A extends io.kubernetes.client.openapi.models.V1EphemeralContainerFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToArgs(java.lang.Integer index, java.lang.String item); + + public A setToArgs(java.lang.Integer index, java.lang.String item); + public A addToArgs(java.lang.String... items); + public A addAllToArgs(java.util.Collection items); + public A removeFromArgs(java.lang.String... items); + public A removeAllFromArgs(java.util.Collection items); + public java.util.List getArgs(); + public java.lang.String getArg(java.lang.Integer index); + public java.lang.String getFirstArg(); + public java.lang.String getLastArg(); + public java.lang.String getMatchingArg(java.util.function.Predicate predicate); + public java.lang.Boolean hasMatchingArg(java.util.function.Predicate predicate); + public A withArgs(java.util.List args); + public A withArgs(java.lang.String... args); + public java.lang.Boolean hasArgs(); + public A addNewArg(java.lang.String original); - public A addToCommand(java.lang.Integer index,java.lang.String item); - public A setToCommand(java.lang.Integer index,java.lang.String item); + + public A addToCommand(java.lang.Integer index, java.lang.String item); + + public A setToCommand(java.lang.Integer index, java.lang.String item); + public A addToCommand(java.lang.String... items); + public A addAllToCommand(java.util.Collection items); + public A removeFromCommand(java.lang.String... items); + public A removeAllFromCommand(java.util.Collection items); + public java.util.List getCommand(); + public java.lang.String getCommand(java.lang.Integer index); + public java.lang.String getFirstCommand(); + public java.lang.String getLastCommand(); - public java.lang.String getMatchingCommand(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCommand(java.util.function.Predicate predicate); + + public java.lang.String getMatchingCommand( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingCommand( + java.util.function.Predicate predicate); + public A withCommand(java.util.List command); + public A withCommand(java.lang.String... command); + public java.lang.Boolean hasCommand(); + public A addNewCommand(java.lang.String original); - public A addToEnv(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item); - public A setToEnv(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item); + + public A addToEnv(java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item); + + public A setToEnv(java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item); + public A addToEnv(io.kubernetes.client.openapi.models.V1EnvVar... items); + public A addAllToEnv(java.util.Collection items); + public A removeFromEnv(io.kubernetes.client.openapi.models.V1EnvVar... items); - public A removeAllFromEnv(java.util.Collection items); - public A removeMatchingFromEnv(java.util.function.Predicate predicate); - + + public A removeAllFromEnv( + java.util.Collection items); + + public A removeMatchingFromEnv( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildEnv instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getEnv(); + public java.util.List buildEnv(); + public io.kubernetes.client.openapi.models.V1EnvVar buildEnv(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EnvVar buildFirstEnv(); + public io.kubernetes.client.openapi.models.V1EnvVar buildLastEnv(); - public io.kubernetes.client.openapi.models.V1EnvVar buildMatchingEnv(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingEnv(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1EnvVar buildMatchingEnv( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingEnv( + java.util.function.Predicate predicate); + public A withEnv(java.util.List env); + public A withEnv(io.kubernetes.client.openapi.models.V1EnvVar... env); + public java.lang.Boolean hasEnv(); + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested addNewEnv(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested addNewEnvLike(io.kubernetes.client.openapi.models.V1EnvVar item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested setNewEnvLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested editEnv(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested addNewEnvLike( + io.kubernetes.client.openapi.models.V1EnvVar item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested setNewEnvLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested editEnv( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested editFirstEnv(); + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested editLastEnv(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested editMatchingEnv(java.util.function.Predicate predicate); - public A addToEnvFrom(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvFromSource item); - public A setToEnvFrom(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvFromSource item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested + editMatchingEnv( + java.util.function.Predicate + predicate); + + public A addToEnvFrom( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item); + + public A setToEnvFrom( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item); + public A addToEnvFrom(io.kubernetes.client.openapi.models.V1EnvFromSource... items); - public A addAllToEnvFrom(java.util.Collection items); + + public A addAllToEnvFrom( + java.util.Collection items); + public A removeFromEnvFrom(io.kubernetes.client.openapi.models.V1EnvFromSource... items); - public A removeAllFromEnvFrom(java.util.Collection items); - public A removeMatchingFromEnvFrom(java.util.function.Predicate predicate); - + + public A removeAllFromEnvFrom( + java.util.Collection items); + + public A removeMatchingFromEnvFrom( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildEnvFrom instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getEnvFrom(); + public java.util.List buildEnvFrom(); + public io.kubernetes.client.openapi.models.V1EnvFromSource buildEnvFrom(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EnvFromSource buildFirstEnvFrom(); + public io.kubernetes.client.openapi.models.V1EnvFromSource buildLastEnvFrom(); - public io.kubernetes.client.openapi.models.V1EnvFromSource buildMatchingEnvFrom(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingEnvFrom(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1EnvFromSource buildMatchingEnvFrom( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingEnvFrom( + java.util.function.Predicate + predicate); + public A withEnvFrom(java.util.List envFrom); + public A withEnvFrom(io.kubernetes.client.openapi.models.V1EnvFromSource... envFrom); + public java.lang.Boolean hasEnvFrom(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested addNewEnvFrom(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested addNewEnvFromLike(io.kubernetes.client.openapi.models.V1EnvFromSource item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested setNewEnvFromLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvFromSource item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested editEnvFrom(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested editFirstEnvFrom(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested editLastEnvFrom(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested editMatchingEnvFrom(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + addNewEnvFrom(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + addNewEnvFromLike(io.kubernetes.client.openapi.models.V1EnvFromSource item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + setNewEnvFromLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + editEnvFrom(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + editFirstEnvFrom(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + editLastEnvFrom(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + editMatchingEnvFrom( + java.util.function.Predicate + predicate); + public java.lang.String getImage(); + public A withImage(java.lang.String image); + public java.lang.Boolean hasImage(); - - /** - * Method is deprecated. use withImage instead. - */ + + /** Method is deprecated. use withImage instead. */ @java.lang.Deprecated public A withNewImage(java.lang.String original); - public io.kubernetes.client.openapi.models.V1EphemeralContainer.ImagePullPolicyEnum getImagePullPolicy(); - public A withImagePullPolicy(io.kubernetes.client.openapi.models.V1EphemeralContainer.ImagePullPolicyEnum imagePullPolicy); + + public io.kubernetes.client.openapi.models.V1EphemeralContainer.ImagePullPolicyEnum + getImagePullPolicy(); + + public A withImagePullPolicy( + io.kubernetes.client.openapi.models.V1EphemeralContainer.ImagePullPolicyEnum imagePullPolicy); + public java.lang.Boolean hasImagePullPolicy(); - + /** * This method has been deprecated, please use method buildLifecycle instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Lifecycle getLifecycle(); + public io.kubernetes.client.openapi.models.V1Lifecycle buildLifecycle(); + public A withLifecycle(io.kubernetes.client.openapi.models.V1Lifecycle lifecycle); + public java.lang.Boolean hasLifecycle(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested withNewLifecycle(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested withNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested editLifecycle(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested editOrNewLifecycle(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested editOrNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item); - + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested + withNewLifecycle(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested + withNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested + editLifecycle(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested + editOrNewLifecycle(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested + editOrNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item); + /** * This method has been deprecated, please use method buildLivenessProbe instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Probe getLivenessProbe(); + public io.kubernetes.client.openapi.models.V1Probe buildLivenessProbe(); + public A withLivenessProbe(io.kubernetes.client.openapi.models.V1Probe livenessProbe); + public java.lang.Boolean hasLivenessProbe(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested withNewLivenessProbe(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested withNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested editLivenessProbe(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested editOrNewLivenessProbe(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested editOrNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested + withNewLivenessProbe(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested + withNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested + editLivenessProbe(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested + editOrNewLivenessProbe(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested + editOrNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item); - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item); + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item); + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item); + public A addToPorts(io.kubernetes.client.openapi.models.V1ContainerPort... items); - public A addAllToPorts(java.util.Collection items); + + public A addAllToPorts( + java.util.Collection items); + public A removeFromPorts(io.kubernetes.client.openapi.models.V1ContainerPort... items); - public A removeAllFromPorts(java.util.Collection items); - public A removeMatchingFromPorts(java.util.function.Predicate predicate); - + + public A removeAllFromPorts( + java.util.Collection items); + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildPorts instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getPorts(); + public java.util.List buildPorts(); + public io.kubernetes.client.openapi.models.V1ContainerPort buildPort(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ContainerPort buildFirstPort(); + public io.kubernetes.client.openapi.models.V1ContainerPort buildLastPort(); - public io.kubernetes.client.openapi.models.V1ContainerPort buildMatchingPort(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ContainerPort buildMatchingPort( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate); + public A withPorts(java.util.List ports); + public A withPorts(io.kubernetes.client.openapi.models.V1ContainerPort... ports); + public java.lang.Boolean hasPorts(); + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested addNewPort(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1ContainerPort item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested editPort(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested editFirstPort(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested editLastPort(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested + addNewPortLike(io.kubernetes.client.openapi.models.V1ContainerPort item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested + setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested editPort( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested + editFirstPort(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested + editLastPort(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested + editMatchingPort( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildReadinessProbe instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Probe getReadinessProbe(); + public io.kubernetes.client.openapi.models.V1Probe buildReadinessProbe(); + public A withReadinessProbe(io.kubernetes.client.openapi.models.V1Probe readinessProbe); + public java.lang.Boolean hasReadinessProbe(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested withNewReadinessProbe(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested withNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested editReadinessProbe(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested editOrNewReadinessProbe(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested editOrNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); - + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested + withNewReadinessProbe(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested + withNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested + editReadinessProbe(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested + editOrNewReadinessProbe(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested + editOrNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + /** * This method has been deprecated, please use method buildResources instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceRequirements getResources(); + public io.kubernetes.client.openapi.models.V1ResourceRequirements buildResources(); + public A withResources(io.kubernetes.client.openapi.models.V1ResourceRequirements resources); + public java.lang.Boolean hasResources(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested withNewResources(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested withNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested editResources(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested editOrNewResources(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested editOrNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item); - + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested + withNewResources(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested + withNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested + editResources(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested + editOrNewResources(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested + editOrNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item); + /** * This method has been deprecated, please use method buildSecurityContext instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecurityContext getSecurityContext(); + public io.kubernetes.client.openapi.models.V1SecurityContext buildSecurityContext(); - public A withSecurityContext(io.kubernetes.client.openapi.models.V1SecurityContext securityContext); + + public A withSecurityContext( + io.kubernetes.client.openapi.models.V1SecurityContext securityContext); + public java.lang.Boolean hasSecurityContext(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested withNewSecurityContext(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested withNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested editSecurityContext(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested editOrNewSecurityContext(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested editOrNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item); - + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested + withNewSecurityContext(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested + withNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested + editSecurityContext(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested + editOrNewSecurityContext(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested + editOrNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item); + /** * This method has been deprecated, please use method buildStartupProbe instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Probe getStartupProbe(); + public io.kubernetes.client.openapi.models.V1Probe buildStartupProbe(); + public A withStartupProbe(io.kubernetes.client.openapi.models.V1Probe startupProbe); + public java.lang.Boolean hasStartupProbe(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested withNewStartupProbe(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested withNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested editStartupProbe(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested editOrNewStartupProbe(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested editOrNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested + withNewStartupProbe(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested + withNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested + editStartupProbe(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested + editOrNewStartupProbe(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested + editOrNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item); + public java.lang.Boolean getStdin(); + public A withStdin(java.lang.Boolean stdin); + public java.lang.Boolean hasStdin(); + public java.lang.Boolean getStdinOnce(); + public A withStdinOnce(java.lang.Boolean stdinOnce); + public java.lang.Boolean hasStdinOnce(); + public java.lang.String getTargetContainerName(); + public A withTargetContainerName(java.lang.String targetContainerName); + public java.lang.Boolean hasTargetContainerName(); - - /** - * Method is deprecated. use withTargetContainerName instead. - */ + + /** Method is deprecated. use withTargetContainerName instead. */ @java.lang.Deprecated public A withNewTargetContainerName(java.lang.String original); + public java.lang.String getTerminationMessagePath(); + public A withTerminationMessagePath(java.lang.String terminationMessagePath); + public java.lang.Boolean hasTerminationMessagePath(); - - /** - * Method is deprecated. use withTerminationMessagePath instead. - */ + + /** Method is deprecated. use withTerminationMessagePath instead. */ @java.lang.Deprecated public A withNewTerminationMessagePath(java.lang.String original); - public io.kubernetes.client.openapi.models.V1EphemeralContainer.TerminationMessagePolicyEnum getTerminationMessagePolicy(); - public A withTerminationMessagePolicy(io.kubernetes.client.openapi.models.V1EphemeralContainer.TerminationMessagePolicyEnum terminationMessagePolicy); + + public io.kubernetes.client.openapi.models.V1EphemeralContainer.TerminationMessagePolicyEnum + getTerminationMessagePolicy(); + + public A withTerminationMessagePolicy( + io.kubernetes.client.openapi.models.V1EphemeralContainer.TerminationMessagePolicyEnum + terminationMessagePolicy); + public java.lang.Boolean hasTerminationMessagePolicy(); + public java.lang.Boolean getTty(); + public A withTty(java.lang.Boolean tty); + public java.lang.Boolean hasTty(); - public A addToVolumeDevices(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item); - public A setToVolumeDevices(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item); + + public A addToVolumeDevices( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item); + + public A setToVolumeDevices( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item); + public A addToVolumeDevices(io.kubernetes.client.openapi.models.V1VolumeDevice... items); - public A addAllToVolumeDevices(java.util.Collection items); + + public A addAllToVolumeDevices( + java.util.Collection items); + public A removeFromVolumeDevices(io.kubernetes.client.openapi.models.V1VolumeDevice... items); - public A removeAllFromVolumeDevices(java.util.Collection items); - public A removeMatchingFromVolumeDevices(java.util.function.Predicate predicate); - + + public A removeAllFromVolumeDevices( + java.util.Collection items); + + public A removeMatchingFromVolumeDevices( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildVolumeDevices instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getVolumeDevices(); + public java.util.List buildVolumeDevices(); - public io.kubernetes.client.openapi.models.V1VolumeDevice buildVolumeDevice(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1VolumeDevice buildVolumeDevice( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1VolumeDevice buildFirstVolumeDevice(); + public io.kubernetes.client.openapi.models.V1VolumeDevice buildLastVolumeDevice(); - public io.kubernetes.client.openapi.models.V1VolumeDevice buildMatchingVolumeDevice(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVolumeDevice(java.util.function.Predicate predicate); - public A withVolumeDevices(java.util.List volumeDevices); + + public io.kubernetes.client.openapi.models.V1VolumeDevice buildMatchingVolumeDevice( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingVolumeDevice( + java.util.function.Predicate + predicate); + + public A withVolumeDevices( + java.util.List volumeDevices); + public A withVolumeDevices(io.kubernetes.client.openapi.models.V1VolumeDevice... volumeDevices); + public java.lang.Boolean hasVolumeDevices(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested addNewVolumeDevice(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested addNewVolumeDeviceLike(io.kubernetes.client.openapi.models.V1VolumeDevice item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested setNewVolumeDeviceLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested editVolumeDevice(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested editFirstVolumeDevice(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested editLastVolumeDevice(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested editMatchingVolumeDevice(java.util.function.Predicate predicate); - public A addToVolumeMounts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeMount item); - public A setToVolumeMounts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeMount item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + addNewVolumeDevice(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + addNewVolumeDeviceLike(io.kubernetes.client.openapi.models.V1VolumeDevice item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + setNewVolumeDeviceLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + editVolumeDevice(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + editFirstVolumeDevice(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + editLastVolumeDevice(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + editMatchingVolumeDevice( + java.util.function.Predicate + predicate); + + public A addToVolumeMounts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item); + + public A setToVolumeMounts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item); + public A addToVolumeMounts(io.kubernetes.client.openapi.models.V1VolumeMount... items); - public A addAllToVolumeMounts(java.util.Collection items); + + public A addAllToVolumeMounts( + java.util.Collection items); + public A removeFromVolumeMounts(io.kubernetes.client.openapi.models.V1VolumeMount... items); - public A removeAllFromVolumeMounts(java.util.Collection items); - public A removeMatchingFromVolumeMounts(java.util.function.Predicate predicate); - + + public A removeAllFromVolumeMounts( + java.util.Collection items); + + public A removeMatchingFromVolumeMounts( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildVolumeMounts instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getVolumeMounts(); + public java.util.List buildVolumeMounts(); - public io.kubernetes.client.openapi.models.V1VolumeMount buildVolumeMount(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1VolumeMount buildVolumeMount( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1VolumeMount buildFirstVolumeMount(); + public io.kubernetes.client.openapi.models.V1VolumeMount buildLastVolumeMount(); - public io.kubernetes.client.openapi.models.V1VolumeMount buildMatchingVolumeMount(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVolumeMount(java.util.function.Predicate predicate); - public A withVolumeMounts(java.util.List volumeMounts); + + public io.kubernetes.client.openapi.models.V1VolumeMount buildMatchingVolumeMount( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingVolumeMount( + java.util.function.Predicate + predicate); + + public A withVolumeMounts( + java.util.List volumeMounts); + public A withVolumeMounts(io.kubernetes.client.openapi.models.V1VolumeMount... volumeMounts); + public java.lang.Boolean hasVolumeMounts(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested addNewVolumeMount(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested addNewVolumeMountLike(io.kubernetes.client.openapi.models.V1VolumeMount item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested setNewVolumeMountLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeMount item); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested editVolumeMount(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested editFirstVolumeMount(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested editLastVolumeMount(); - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested editMatchingVolumeMount(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + addNewVolumeMount(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + addNewVolumeMountLike(io.kubernetes.client.openapi.models.V1VolumeMount item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + setNewVolumeMountLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + editVolumeMount(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + editFirstVolumeMount(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + editLastVolumeMount(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + editMatchingVolumeMount( + java.util.function.Predicate + predicate); + public java.lang.String getWorkingDir(); + public A withWorkingDir(java.lang.String workingDir); + public java.lang.Boolean hasWorkingDir(); - - /** - * Method is deprecated. use withWorkingDir instead. - */ + + /** Method is deprecated. use withWorkingDir instead. */ @java.lang.Deprecated public A withNewWorkingDir(java.lang.String original); - public interface EnvNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EnvVarFluent>{ + + public interface EnvNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EnvVarFluent< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested> { public N and(); + public N endEnv(); - } - public interface EnvFromNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EnvFromSourceFluent>{ + + public interface EnvFromNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EnvFromSourceFluent< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested> { public N and(); + public N endEnvFrom(); - } - public interface LifecycleNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LifecycleFluent>{ + + public interface LifecycleNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LifecycleFluent< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested> { public N and(); + public N endLifecycle(); - } - public interface LivenessProbeNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ProbeFluent>{ + + public interface LivenessProbeNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ProbeFluent< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested< + N>> { public N and(); + public N endLivenessProbe(); - } - public interface PortsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ContainerPortFluent>{ + + public interface PortsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ContainerPortFluent< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested> { public N and(); + public N endPort(); - } - public interface ReadinessProbeNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ProbeFluent>{ + + public interface ReadinessProbeNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ProbeFluent< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested< + N>> { public N and(); + public N endReadinessProbe(); - } - public interface ResourcesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent>{ + + public interface ResourcesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested> { public N and(); + public N endResources(); - } - public interface SecurityContextNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecurityContextFluent>{ + + public interface SecurityContextNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecurityContextFluent< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested< + N>> { public N and(); + public N endSecurityContext(); - } - public interface StartupProbeNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ProbeFluent>{ + + public interface StartupProbeNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ProbeFluent< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested< + N>> { public N and(); + public N endStartupProbe(); - } - public interface VolumeDevicesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeDeviceFluent>{ + + public interface VolumeDevicesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeDeviceFluent< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested< + N>> { public N and(); + public N endVolumeDevice(); - } - public interface VolumeMountsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeMountFluent>{ + + public interface VolumeMountsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeMountFluent< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested< + N>> { public N and(); + public N endVolumeMount(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralContainerFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralContainerFluentImpl.java index 5b150ddc11..c948711e3b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralContainerFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralContainerFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.List; -import java.lang.Boolean; -import java.util.Collection; -import java.lang.Object; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; import java.util.Iterator; -import java.lang.Integer; +import java.util.List; - /** - * Generated - */ -public class V1EphemeralContainerFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent{ - public V1EphemeralContainerFluentImpl() { - } - public V1EphemeralContainerFluentImpl(io.kubernetes.client.openapi.models.V1EphemeralContainer instance) { +/** Generated */ +public class V1EphemeralContainerFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EphemeralContainerFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent { + public V1EphemeralContainerFluentImpl() {} + + public V1EphemeralContainerFluentImpl( + io.kubernetes.client.openapi.models.V1EphemeralContainer instance) { this.withArgs(instance.getArgs()); this.withCommand(instance.getCommand()); @@ -66,14 +69,15 @@ public V1EphemeralContainerFluentImpl(io.kubernetes.client.openapi.models.V1Ephe this.withVolumeMounts(instance.getVolumeMounts()); this.withWorkingDir(instance.getWorkingDir()); - } + private java.util.List args; private java.util.List command; private java.util.ArrayList env; private java.util.ArrayList envFrom; private java.lang.String image; - private io.kubernetes.client.openapi.models.V1EphemeralContainer.ImagePullPolicyEnum imagePullPolicy; + private io.kubernetes.client.openapi.models.V1EphemeralContainer.ImagePullPolicyEnum + imagePullPolicy; private io.kubernetes.client.openapi.models.V1LifecycleBuilder lifecycle; private io.kubernetes.client.openapi.models.V1ProbeBuilder livenessProbe; private java.lang.String name; @@ -86,145 +90,341 @@ public V1EphemeralContainerFluentImpl(io.kubernetes.client.openapi.models.V1Ephe private java.lang.Boolean stdinOnce; private java.lang.String targetContainerName; private java.lang.String terminationMessagePath; - private io.kubernetes.client.openapi.models.V1EphemeralContainer.TerminationMessagePolicyEnum terminationMessagePolicy; + private io.kubernetes.client.openapi.models.V1EphemeralContainer.TerminationMessagePolicyEnum + terminationMessagePolicy; private java.lang.Boolean tty; - private java.util.ArrayList volumeDevices; - private java.util.ArrayList volumeMounts; + private java.util.ArrayList + volumeDevices; + private java.util.ArrayList + volumeMounts; private java.lang.String workingDir; - public A addToArgs(java.lang.Integer index,java.lang.String item) { - if (this.args == null) {this.args = new java.util.ArrayList();} + + public A addToArgs(java.lang.Integer index, java.lang.String item) { + if (this.args == null) { + this.args = new java.util.ArrayList(); + } this.args.add(index, item); - return (A)this; + return (A) this; } - public A setToArgs(java.lang.Integer index,java.lang.String item) { - if (this.args == null) {this.args = new java.util.ArrayList();} - this.args.set(index, item); return (A)this; + + public A setToArgs(java.lang.Integer index, java.lang.String item) { + if (this.args == null) { + this.args = new java.util.ArrayList(); + } + this.args.set(index, item); + return (A) this; } + public A addToArgs(java.lang.String... items) { - if (this.args == null) {this.args = new java.util.ArrayList();} - for (java.lang.String item : items) {this.args.add(item);} return (A)this; + if (this.args == null) { + this.args = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.args.add(item); + } + return (A) this; } + public A addAllToArgs(java.util.Collection items) { - if (this.args == null) {this.args = new java.util.ArrayList();} - for (java.lang.String item : items) {this.args.add(item);} return (A)this; + if (this.args == null) { + this.args = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.args.add(item); + } + return (A) this; } + public A removeFromArgs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.args!= null){ this.args.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.args != null) { + this.args.remove(item); + } + } + return (A) this; } + public A removeAllFromArgs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.args!= null){ this.args.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.args != null) { + this.args.remove(item); + } + } + return (A) this; } + public java.util.List getArgs() { return this.args; } + public java.lang.String getArg(java.lang.Integer index) { return this.args.get(index); } + public java.lang.String getFirstArg() { return this.args.get(0); } + public java.lang.String getLastArg() { return this.args.get(args.size() - 1); } + public java.lang.String getMatchingArg(java.util.function.Predicate predicate) { - for (java.lang.String item: args) { if(predicate.test(item)){ return item;} } return null; + for (java.lang.String item : args) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingArg(java.util.function.Predicate predicate) { - for (java.lang.String item: args) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingArg( + java.util.function.Predicate predicate) { + for (java.lang.String item : args) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withArgs(java.util.List args) { - if (args != null) {this.args = new java.util.ArrayList(); for (java.lang.String item : args){this.addToArgs(item);}} else { this.args = null;} return (A) this; + if (args != null) { + this.args = new java.util.ArrayList(); + for (java.lang.String item : args) { + this.addToArgs(item); + } + } else { + this.args = null; + } + return (A) this; } + public A withArgs(java.lang.String... args) { - if (this.args != null) {this.args.clear();} - if (args != null) {for (java.lang.String item :args){ this.addToArgs(item);}} return (A) this; + if (this.args != null) { + this.args.clear(); + } + if (args != null) { + for (java.lang.String item : args) { + this.addToArgs(item); + } + } + return (A) this; } + public java.lang.Boolean hasArgs() { return args != null && !args.isEmpty(); } + public A addNewArg(java.lang.String original) { - return (A)addToArgs(new String(original)); + return (A) addToArgs(new String(original)); } - public A addToCommand(java.lang.Integer index,java.lang.String item) { - if (this.command == null) {this.command = new java.util.ArrayList();} + + public A addToCommand(java.lang.Integer index, java.lang.String item) { + if (this.command == null) { + this.command = new java.util.ArrayList(); + } this.command.add(index, item); - return (A)this; + return (A) this; } - public A setToCommand(java.lang.Integer index,java.lang.String item) { - if (this.command == null) {this.command = new java.util.ArrayList();} - this.command.set(index, item); return (A)this; + + public A setToCommand(java.lang.Integer index, java.lang.String item) { + if (this.command == null) { + this.command = new java.util.ArrayList(); + } + this.command.set(index, item); + return (A) this; } + public A addToCommand(java.lang.String... items) { - if (this.command == null) {this.command = new java.util.ArrayList();} - for (java.lang.String item : items) {this.command.add(item);} return (A)this; + if (this.command == null) { + this.command = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.command.add(item); + } + return (A) this; } + public A addAllToCommand(java.util.Collection items) { - if (this.command == null) {this.command = new java.util.ArrayList();} - for (java.lang.String item : items) {this.command.add(item);} return (A)this; + if (this.command == null) { + this.command = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.command.add(item); + } + return (A) this; } + public A removeFromCommand(java.lang.String... items) { - for (java.lang.String item : items) {if (this.command!= null){ this.command.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.command != null) { + this.command.remove(item); + } + } + return (A) this; } + public A removeAllFromCommand(java.util.Collection items) { - for (java.lang.String item : items) {if (this.command!= null){ this.command.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.command != null) { + this.command.remove(item); + } + } + return (A) this; } + public java.util.List getCommand() { return this.command; } + public java.lang.String getCommand(java.lang.Integer index) { return this.command.get(index); } + public java.lang.String getFirstCommand() { return this.command.get(0); } + public java.lang.String getLastCommand() { return this.command.get(command.size() - 1); } - public java.lang.String getMatchingCommand(java.util.function.Predicate predicate) { - for (java.lang.String item: command) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingCommand( + java.util.function.Predicate predicate) { + for (java.lang.String item : command) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingCommand(java.util.function.Predicate predicate) { - for (java.lang.String item: command) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCommand( + java.util.function.Predicate predicate) { + for (java.lang.String item : command) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withCommand(java.util.List command) { - if (command != null) {this.command = new java.util.ArrayList(); for (java.lang.String item : command){this.addToCommand(item);}} else { this.command = null;} return (A) this; + if (command != null) { + this.command = new java.util.ArrayList(); + for (java.lang.String item : command) { + this.addToCommand(item); + } + } else { + this.command = null; + } + return (A) this; } + public A withCommand(java.lang.String... command) { - if (this.command != null) {this.command.clear();} - if (command != null) {for (java.lang.String item :command){ this.addToCommand(item);}} return (A) this; + if (this.command != null) { + this.command.clear(); + } + if (command != null) { + for (java.lang.String item : command) { + this.addToCommand(item); + } + } + return (A) this; } + public java.lang.Boolean hasCommand() { return command != null && !command.isEmpty(); } + public A addNewCommand(java.lang.String original) { - return (A)addToCommand(new String(original)); + return (A) addToCommand(new String(original)); } - public A addToEnv(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item) { - if (this.env == null) {this.env = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item);_visitables.get("env").add(index >= 0 ? index : _visitables.get("env").size(), builder);this.env.add(index >= 0 ? index : env.size(), builder); return (A)this; + + public A addToEnv(java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item) { + if (this.env == null) { + this.env = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); + _visitables.get("env").add(index >= 0 ? index : _visitables.get("env").size(), builder); + this.env.add(index >= 0 ? index : env.size(), builder); + return (A) this; } - public A setToEnv(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item) { - if (this.env == null) {this.env = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); - if (index < 0 || index >= _visitables.get("env").size()) { _visitables.get("env").add(builder); } else { _visitables.get("env").set(index, builder);} - if (index < 0 || index >= env.size()) { env.add(builder); } else { env.set(index, builder);} - return (A)this; + + public A setToEnv(java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item) { + if (this.env == null) { + this.env = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); + if (index < 0 || index >= _visitables.get("env").size()) { + _visitables.get("env").add(builder); + } else { + _visitables.get("env").set(index, builder); + } + if (index < 0 || index >= env.size()) { + env.add(builder); + } else { + env.set(index, builder); + } + return (A) this; } + public A addToEnv(io.kubernetes.client.openapi.models.V1EnvVar... items) { - if (this.env == null) {this.env = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EnvVar item : items) {io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item);_visitables.get("env").add(builder);this.env.add(builder);} return (A)this; + if (this.env == null) { + this.env = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EnvVar item : items) { + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); + _visitables.get("env").add(builder); + this.env.add(builder); + } + return (A) this; } + public A addAllToEnv(java.util.Collection items) { - if (this.env == null) {this.env = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EnvVar item : items) {io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item);_visitables.get("env").add(builder);this.env.add(builder);} return (A)this; + if (this.env == null) { + this.env = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EnvVar item : items) { + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); + _visitables.get("env").add(builder); + this.env.add(builder); + } + return (A) this; } + public A removeFromEnv(io.kubernetes.client.openapi.models.V1EnvVar... items) { - for (io.kubernetes.client.openapi.models.V1EnvVar item : items) {io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item);_visitables.get("env").remove(builder);if (this.env != null) {this.env.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1EnvVar item : items) { + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); + _visitables.get("env").remove(builder); + if (this.env != null) { + this.env.remove(builder); + } + } + return (A) this; } - public A removeAllFromEnv(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1EnvVar item : items) {io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item);_visitables.get("env").remove(builder);if (this.env != null) {this.env.remove(builder);}} return (A)this; + + public A removeAllFromEnv( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1EnvVar item : items) { + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvVarBuilder(item); + _visitables.get("env").remove(builder); + if (this.env != null) { + this.env.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromEnv(java.util.function.Predicate predicate) { + + public A removeMatchingFromEnv( + java.util.function.Predicate predicate) { if (env == null) return (A) this; final Iterator each = env.iterator(); final List visitables = _visitables.get("env"); @@ -235,104 +435,229 @@ public A removeMatchingFromEnv(java.util.function.Predicate getEnv() { return env != null ? build(env) : null; } + public java.util.List buildEnv() { return env != null ? build(env) : null; } + public io.kubernetes.client.openapi.models.V1EnvVar buildEnv(java.lang.Integer index) { return this.env.get(index).build(); } + public io.kubernetes.client.openapi.models.V1EnvVar buildFirstEnv() { return this.env.get(0).build(); } + public io.kubernetes.client.openapi.models.V1EnvVar buildLastEnv() { return this.env.get(env.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1EnvVar buildMatchingEnv(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EnvVarBuilder item: env) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1EnvVar buildMatchingEnv( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1EnvVarBuilder item : env) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingEnv(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EnvVarBuilder item: env) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingEnv( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1EnvVarBuilder item : env) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withEnv(java.util.List env) { - if (this.env != null) { _visitables.get("env").removeAll(this.env);} - if (env != null) {this.env = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1EnvVar item : env){this.addToEnv(item);}} else { this.env = null;} return (A) this; + if (this.env != null) { + _visitables.get("env").removeAll(this.env); + } + if (env != null) { + this.env = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1EnvVar item : env) { + this.addToEnv(item); + } + } else { + this.env = null; + } + return (A) this; } + public A withEnv(io.kubernetes.client.openapi.models.V1EnvVar... env) { - if (this.env != null) {this.env.clear();} - if (env != null) {for (io.kubernetes.client.openapi.models.V1EnvVar item :env){ this.addToEnv(item);}} return (A) this; + if (this.env != null) { + this.env.clear(); + } + if (env != null) { + for (io.kubernetes.client.openapi.models.V1EnvVar item : env) { + this.addToEnv(item); + } + } + return (A) this; } + public java.lang.Boolean hasEnv() { return env != null && !env.isEmpty(); } + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested addNewEnv() { return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.EnvNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested addNewEnvLike(io.kubernetes.client.openapi.models.V1EnvVar item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.EnvNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested addNewEnvLike( + io.kubernetes.client.openapi.models.V1EnvVar item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.EnvNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested setNewEnvLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.EnvNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested setNewEnvLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.EnvNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested editEnv(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested editEnv( + java.lang.Integer index) { if (env.size() <= index) throw new RuntimeException("Can't edit env. Index exceeds size."); return setNewEnvLike(index, buildEnv(index)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested editFirstEnv() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested + editFirstEnv() { if (env.size() == 0) throw new RuntimeException("Can't edit first env. The list is empty."); return setNewEnvLike(0, buildEnv(0)); } + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested editLastEnv() { int index = env.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last env. The list is empty."); return setNewEnvLike(index, buildEnv(index)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested editMatchingEnv(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested + editMatchingEnv( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item);_visitables.get("envFrom").add(index >= 0 ? index : _visitables.get("envFrom").size(), builder);this.envFrom.add(index >= 0 ? index : envFrom.size(), builder); return (A)this; + + public A addToEnvFrom( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item) { + if (this.envFrom == null) { + this.envFrom = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); + _visitables.get("envFrom").add(index >= 0 ? index : _visitables.get("envFrom").size(), builder); + this.envFrom.add(index >= 0 ? index : envFrom.size(), builder); + return (A) this; } - public A setToEnvFrom(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvFromSource item) { - if (this.envFrom == null) {this.envFrom = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); - if (index < 0 || index >= _visitables.get("envFrom").size()) { _visitables.get("envFrom").add(builder); } else { _visitables.get("envFrom").set(index, builder);} - if (index < 0 || index >= envFrom.size()) { envFrom.add(builder); } else { envFrom.set(index, builder);} - return (A)this; + + public A setToEnvFrom( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item) { + if (this.envFrom == null) { + this.envFrom = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); + if (index < 0 || index >= _visitables.get("envFrom").size()) { + _visitables.get("envFrom").add(builder); + } else { + _visitables.get("envFrom").set(index, builder); + } + if (index < 0 || index >= envFrom.size()) { + envFrom.add(builder); + } else { + envFrom.set(index, builder); + } + return (A) this; } + public A addToEnvFrom(io.kubernetes.client.openapi.models.V1EnvFromSource... items) { - if (this.envFrom == null) {this.envFrom = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) {io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item);_visitables.get("envFrom").add(builder);this.envFrom.add(builder);} return (A)this; + if (this.envFrom == null) { + this.envFrom = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) { + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); + _visitables.get("envFrom").add(builder); + this.envFrom.add(builder); + } + return (A) this; } - public A addAllToEnvFrom(java.util.Collection items) { - if (this.envFrom == null) {this.envFrom = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) {io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item);_visitables.get("envFrom").add(builder);this.envFrom.add(builder);} return (A)this; + + public A addAllToEnvFrom( + java.util.Collection items) { + if (this.envFrom == null) { + this.envFrom = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) { + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); + _visitables.get("envFrom").add(builder); + this.envFrom.add(builder); + } + return (A) this; } + public A removeFromEnvFrom(io.kubernetes.client.openapi.models.V1EnvFromSource... items) { - for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) {io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item);_visitables.get("envFrom").remove(builder);if (this.envFrom != null) {this.envFrom.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) { + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); + _visitables.get("envFrom").remove(builder); + if (this.envFrom != null) { + this.envFrom.remove(builder); + } + } + return (A) this; } - public A removeAllFromEnvFrom(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) {io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item);_visitables.get("envFrom").remove(builder);if (this.envFrom != null) {this.envFrom.remove(builder);}} return (A)this; + + public A removeAllFromEnvFrom( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1EnvFromSource item : items) { + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = + new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(item); + _visitables.get("envFrom").remove(builder); + if (this.envFrom != null) { + this.envFrom.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromEnvFrom(java.util.function.Predicate predicate) { + + public A removeMatchingFromEnvFrom( + java.util.function.Predicate + predicate) { if (envFrom == null) return (A) this; - final Iterator each = envFrom.iterator(); + final Iterator each = + envFrom.iterator(); final List visitables = _visitables.get("envFrom"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder = each.next(); @@ -341,215 +666,406 @@ public A removeMatchingFromEnvFrom(java.util.function.Predicate getEnvFrom() { return envFrom != null ? build(envFrom) : null; } + public java.util.List buildEnvFrom() { return envFrom != null ? build(envFrom) : null; } + public io.kubernetes.client.openapi.models.V1EnvFromSource buildEnvFrom(java.lang.Integer index) { return this.envFrom.get(index).build(); } + public io.kubernetes.client.openapi.models.V1EnvFromSource buildFirstEnvFrom() { return this.envFrom.get(0).build(); } + public io.kubernetes.client.openapi.models.V1EnvFromSource buildLastEnvFrom() { return this.envFrom.get(envFrom.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1EnvFromSource buildMatchingEnvFrom(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder item: envFrom) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1EnvFromSource buildMatchingEnvFrom( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder item : envFrom) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingEnvFrom(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder item: envFrom) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingEnvFrom( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder item : envFrom) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withEnvFrom(java.util.List envFrom) { - if (this.envFrom != null) { _visitables.get("envFrom").removeAll(this.envFrom);} - if (envFrom != null) {this.envFrom = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1EnvFromSource item : envFrom){this.addToEnvFrom(item);}} else { this.envFrom = null;} return (A) this; + + public A withEnvFrom( + java.util.List envFrom) { + if (this.envFrom != null) { + _visitables.get("envFrom").removeAll(this.envFrom); + } + if (envFrom != null) { + this.envFrom = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1EnvFromSource item : envFrom) { + this.addToEnvFrom(item); + } + } else { + this.envFrom = null; + } + return (A) this; } + public A withEnvFrom(io.kubernetes.client.openapi.models.V1EnvFromSource... envFrom) { - if (this.envFrom != null) {this.envFrom.clear();} - if (envFrom != null) {for (io.kubernetes.client.openapi.models.V1EnvFromSource item :envFrom){ this.addToEnvFrom(item);}} return (A) this; + if (this.envFrom != null) { + this.envFrom.clear(); + } + if (envFrom != null) { + for (io.kubernetes.client.openapi.models.V1EnvFromSource item : envFrom) { + this.addToEnvFrom(item); + } + } + return (A) this; } + public java.lang.Boolean hasEnvFrom() { return envFrom != null && !envFrom.isEmpty(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested addNewEnvFrom() { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.EnvFromNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + addNewEnvFrom() { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .EnvFromNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested addNewEnvFromLike(io.kubernetes.client.openapi.models.V1EnvFromSource item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.EnvFromNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + addNewEnvFromLike(io.kubernetes.client.openapi.models.V1EnvFromSource item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.EnvFromNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested setNewEnvFromLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvFromSource item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.EnvFromNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + setNewEnvFromLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.EnvFromNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested editEnvFrom(java.lang.Integer index) { - if (envFrom.size() <= index) throw new RuntimeException("Can't edit envFrom. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + editEnvFrom(java.lang.Integer index) { + if (envFrom.size() <= index) + throw new RuntimeException("Can't edit envFrom. Index exceeds size."); return setNewEnvFromLike(index, buildEnvFrom(index)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested editFirstEnvFrom() { - if (envFrom.size() == 0) throw new RuntimeException("Can't edit first envFrom. The list is empty."); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + editFirstEnvFrom() { + if (envFrom.size() == 0) + throw new RuntimeException("Can't edit first envFrom. The list is empty."); return setNewEnvFromLike(0, buildEnvFrom(0)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested editLastEnvFrom() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + editLastEnvFrom() { int index = envFrom.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last envFrom. The list is empty."); return setNewEnvFromLike(index, buildEnvFrom(index)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested editMatchingEnvFrom(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested + editMatchingEnvFrom( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewLifecycle() { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.LifecycleNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested + withNewLifecycle() { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .LifecycleNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested withNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.LifecycleNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested + withNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .LifecycleNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested editLifecycle() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested + editLifecycle() { return withNewLifecycleLike(getLifecycle()); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested editOrNewLifecycle() { - return withNewLifecycleLike(getLifecycle() != null ? getLifecycle(): new io.kubernetes.client.openapi.models.V1LifecycleBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested + editOrNewLifecycle() { + return withNewLifecycleLike( + getLifecycle() != null + ? getLifecycle() + : new io.kubernetes.client.openapi.models.V1LifecycleBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested editOrNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item) { - return withNewLifecycleLike(getLifecycle() != null ? getLifecycle(): item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested + editOrNewLifecycleLike(io.kubernetes.client.openapi.models.V1Lifecycle item) { + return withNewLifecycleLike(getLifecycle() != null ? getLifecycle() : item); } - + /** * This method has been deprecated, please use method buildLivenessProbe instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Probe getLivenessProbe() { - return this.livenessProbe!=null ?this.livenessProbe.build():null; + return this.livenessProbe != null ? this.livenessProbe.build() : null; } + public io.kubernetes.client.openapi.models.V1Probe buildLivenessProbe() { - return this.livenessProbe!=null ?this.livenessProbe.build():null; + return this.livenessProbe != null ? this.livenessProbe.build() : null; } + public A withLivenessProbe(io.kubernetes.client.openapi.models.V1Probe livenessProbe) { _visitables.get("livenessProbe").remove(this.livenessProbe); - if (livenessProbe!=null){ this.livenessProbe= new io.kubernetes.client.openapi.models.V1ProbeBuilder(livenessProbe); _visitables.get("livenessProbe").add(this.livenessProbe);} return (A) this; + if (livenessProbe != null) { + this.livenessProbe = new io.kubernetes.client.openapi.models.V1ProbeBuilder(livenessProbe); + _visitables.get("livenessProbe").add(this.livenessProbe); + } + return (A) this; } + public java.lang.Boolean hasLivenessProbe() { return this.livenessProbe != null; } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested withNewLivenessProbe() { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.LivenessProbeNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested + withNewLivenessProbe() { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .LivenessProbeNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested withNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.LivenessProbeNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested + withNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .LivenessProbeNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested editLivenessProbe() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested + editLivenessProbe() { return withNewLivenessProbeLike(getLivenessProbe()); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested editOrNewLivenessProbe() { - return withNewLivenessProbeLike(getLivenessProbe() != null ? getLivenessProbe(): new io.kubernetes.client.openapi.models.V1ProbeBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested + editOrNewLivenessProbe() { + return withNewLivenessProbeLike( + getLivenessProbe() != null + ? getLivenessProbe() + : new io.kubernetes.client.openapi.models.V1ProbeBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested editOrNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { - return withNewLivenessProbeLike(getLivenessProbe() != null ? getLivenessProbe(): item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested + editOrNewLivenessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { + return withNewLivenessProbeLike(getLivenessProbe() != null ? getLivenessProbe() : item); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item);_visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder);this.ports.add(index >= 0 ? index : ports.size(), builder); return (A)this; + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); + _visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder); + this.ports.add(index >= 0 ? index : ports.size(), builder); + return (A) this; } - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); - if (index < 0 || index >= _visitables.get("ports").size()) { _visitables.get("ports").add(builder); } else { _visitables.get("ports").set(index, builder);} - if (index < 0 || index >= ports.size()) { ports.add(builder); } else { ports.set(index, builder);} - return (A)this; + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); + if (index < 0 || index >= _visitables.get("ports").size()) { + _visitables.get("ports").add(builder); + } else { + _visitables.get("ports").set(index, builder); + } + if (index < 0 || index >= ports.size()) { + ports.add(builder); + } else { + ports.set(index, builder); + } + return (A) this; } + public A addToPorts(io.kubernetes.client.openapi.models.V1ContainerPort... items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) {io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) { + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } - public A addAllToPorts(java.util.Collection items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) {io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + + public A addAllToPorts( + java.util.Collection items) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) { + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } + public A removeFromPorts(io.kubernetes.client.openapi.models.V1ContainerPort... items) { - for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) {io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) { + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeAllFromPorts(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) {io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + + public A removeAllFromPorts( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ContainerPort item : items) { + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPorts(java.util.function.Predicate predicate) { + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate) { if (ports == null) return (A) this; - final Iterator each = ports.iterator(); + final Iterator each = + ports.iterator(); final List visitables = _visitables.get("ports"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder = each.next(); @@ -558,310 +1074,560 @@ public A removeMatchingFromPorts(java.util.function.Predicate getPorts() { return ports != null ? build(ports) : null; } + public java.util.List buildPorts() { return ports != null ? build(ports) : null; } + public io.kubernetes.client.openapi.models.V1ContainerPort buildPort(java.lang.Integer index) { return this.ports.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ContainerPort buildFirstPort() { return this.ports.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ContainerPort buildLastPort() { return this.ports.get(ports.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ContainerPort buildMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerPortBuilder item: ports) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ContainerPort buildMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerPortBuilder item : ports) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerPortBuilder item: ports) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerPortBuilder item : ports) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withPorts(java.util.List ports) { - if (this.ports != null) { _visitables.get("ports").removeAll(this.ports);} - if (ports != null) {this.ports = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ContainerPort item : ports){this.addToPorts(item);}} else { this.ports = null;} return (A) this; + if (this.ports != null) { + _visitables.get("ports").removeAll(this.ports); + } + if (ports != null) { + this.ports = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ContainerPort item : ports) { + this.addToPorts(item); + } + } else { + this.ports = null; + } + return (A) this; } + public A withPorts(io.kubernetes.client.openapi.models.V1ContainerPort... ports) { - if (this.ports != null) {this.ports.clear();} - if (ports != null) {for (io.kubernetes.client.openapi.models.V1ContainerPort item :ports){ this.addToPorts(item);}} return (A) this; + if (this.ports != null) { + this.ports.clear(); + } + if (ports != null) { + for (io.kubernetes.client.openapi.models.V1ContainerPort item : ports) { + this.addToPorts(item); + } + } + return (A) this; } + public java.lang.Boolean hasPorts() { return ports != null && !ports.isEmpty(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested addNewPort() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested + addNewPort() { return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.PortsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1ContainerPort item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.PortsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested + addNewPortLike(io.kubernetes.client.openapi.models.V1ContainerPort item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.PortsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.PortsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested + setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.PortsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested editPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested editPort( + java.lang.Integer index) { if (ports.size() <= index) throw new RuntimeException("Can't edit ports. Index exceeds size."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested editFirstPort() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested + editFirstPort() { if (ports.size() == 0) throw new RuntimeException("Can't edit first ports. The list is empty."); return setNewPortLike(0, buildPort(0)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested editLastPort() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested + editLastPort() { int index = ports.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ports. The list is empty."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested + editMatchingPort( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewReadinessProbe() { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.ReadinessProbeNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested + withNewReadinessProbe() { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .ReadinessProbeNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested withNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.ReadinessProbeNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested + withNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .ReadinessProbeNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested editReadinessProbe() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested + editReadinessProbe() { return withNewReadinessProbeLike(getReadinessProbe()); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested editOrNewReadinessProbe() { - return withNewReadinessProbeLike(getReadinessProbe() != null ? getReadinessProbe(): new io.kubernetes.client.openapi.models.V1ProbeBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested + editOrNewReadinessProbe() { + return withNewReadinessProbeLike( + getReadinessProbe() != null + ? getReadinessProbe() + : new io.kubernetes.client.openapi.models.V1ProbeBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested editOrNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { - return withNewReadinessProbeLike(getReadinessProbe() != null ? getReadinessProbe(): item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested + editOrNewReadinessProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { + return withNewReadinessProbeLike(getReadinessProbe() != null ? getReadinessProbe() : item); } - + /** * This method has been deprecated, please use method buildResources instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceRequirements getResources() { - return this.resources!=null ?this.resources.build():null; + return this.resources != null ? this.resources.build() : null; } + public io.kubernetes.client.openapi.models.V1ResourceRequirements buildResources() { - return this.resources!=null ?this.resources.build():null; + return this.resources != null ? this.resources.build() : null; } + public A withResources(io.kubernetes.client.openapi.models.V1ResourceRequirements resources) { _visitables.get("resources").remove(this.resources); - if (resources!=null){ this.resources= new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(resources); _visitables.get("resources").add(this.resources);} return (A) this; + if (resources != null) { + this.resources = + new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(resources); + _visitables.get("resources").add(this.resources); + } + return (A) this; } + public java.lang.Boolean hasResources() { return this.resources != null; } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested withNewResources() { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.ResourcesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested + withNewResources() { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .ResourcesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested withNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.ResourcesNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested + withNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .ResourcesNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested editResources() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested + editResources() { return withNewResourcesLike(getResources()); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested editOrNewResources() { - return withNewResourcesLike(getResources() != null ? getResources(): new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested + editOrNewResources() { + return withNewResourcesLike( + getResources() != null + ? getResources() + : new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested editOrNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { - return withNewResourcesLike(getResources() != null ? getResources(): item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested + editOrNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { + return withNewResourcesLike(getResources() != null ? getResources() : item); } - + /** * This method has been deprecated, please use method buildSecurityContext instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecurityContext getSecurityContext() { - return this.securityContext!=null ?this.securityContext.build():null; + return this.securityContext != null ? this.securityContext.build() : null; } + public io.kubernetes.client.openapi.models.V1SecurityContext buildSecurityContext() { - return this.securityContext!=null ?this.securityContext.build():null; + return this.securityContext != null ? this.securityContext.build() : null; } - public A withSecurityContext(io.kubernetes.client.openapi.models.V1SecurityContext securityContext) { + + public A withSecurityContext( + io.kubernetes.client.openapi.models.V1SecurityContext securityContext) { _visitables.get("securityContext").remove(this.securityContext); - if (securityContext!=null){ this.securityContext= new io.kubernetes.client.openapi.models.V1SecurityContextBuilder(securityContext); _visitables.get("securityContext").add(this.securityContext);} return (A) this; + if (securityContext != null) { + this.securityContext = + new io.kubernetes.client.openapi.models.V1SecurityContextBuilder(securityContext); + _visitables.get("securityContext").add(this.securityContext); + } + return (A) this; } + public java.lang.Boolean hasSecurityContext() { return this.securityContext != null; } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested withNewSecurityContext() { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.SecurityContextNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested + withNewSecurityContext() { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .SecurityContextNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested withNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.SecurityContextNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested + withNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .SecurityContextNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested editSecurityContext() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested + editSecurityContext() { return withNewSecurityContextLike(getSecurityContext()); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested editOrNewSecurityContext() { - return withNewSecurityContextLike(getSecurityContext() != null ? getSecurityContext(): new io.kubernetes.client.openapi.models.V1SecurityContextBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested + editOrNewSecurityContext() { + return withNewSecurityContextLike( + getSecurityContext() != null + ? getSecurityContext() + : new io.kubernetes.client.openapi.models.V1SecurityContextBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested editOrNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item) { - return withNewSecurityContextLike(getSecurityContext() != null ? getSecurityContext(): item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested + editOrNewSecurityContextLike(io.kubernetes.client.openapi.models.V1SecurityContext item) { + return withNewSecurityContextLike(getSecurityContext() != null ? getSecurityContext() : item); } - + /** * This method has been deprecated, please use method buildStartupProbe instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Probe getStartupProbe() { - return this.startupProbe!=null ?this.startupProbe.build():null; + return this.startupProbe != null ? this.startupProbe.build() : null; } + public io.kubernetes.client.openapi.models.V1Probe buildStartupProbe() { - return this.startupProbe!=null ?this.startupProbe.build():null; + return this.startupProbe != null ? this.startupProbe.build() : null; } + public A withStartupProbe(io.kubernetes.client.openapi.models.V1Probe startupProbe) { _visitables.get("startupProbe").remove(this.startupProbe); - if (startupProbe!=null){ this.startupProbe= new io.kubernetes.client.openapi.models.V1ProbeBuilder(startupProbe); _visitables.get("startupProbe").add(this.startupProbe);} return (A) this; + if (startupProbe != null) { + this.startupProbe = new io.kubernetes.client.openapi.models.V1ProbeBuilder(startupProbe); + _visitables.get("startupProbe").add(this.startupProbe); + } + return (A) this; } + public java.lang.Boolean hasStartupProbe() { return this.startupProbe != null; } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested withNewStartupProbe() { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.StartupProbeNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested + withNewStartupProbe() { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .StartupProbeNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested withNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.StartupProbeNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested + withNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .StartupProbeNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested editStartupProbe() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested + editStartupProbe() { return withNewStartupProbeLike(getStartupProbe()); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested editOrNewStartupProbe() { - return withNewStartupProbeLike(getStartupProbe() != null ? getStartupProbe(): new io.kubernetes.client.openapi.models.V1ProbeBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested + editOrNewStartupProbe() { + return withNewStartupProbeLike( + getStartupProbe() != null + ? getStartupProbe() + : new io.kubernetes.client.openapi.models.V1ProbeBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested editOrNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { - return withNewStartupProbeLike(getStartupProbe() != null ? getStartupProbe(): item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested + editOrNewStartupProbeLike(io.kubernetes.client.openapi.models.V1Probe item) { + return withNewStartupProbeLike(getStartupProbe() != null ? getStartupProbe() : item); } + public java.lang.Boolean getStdin() { return this.stdin; } + public A withStdin(java.lang.Boolean stdin) { - this.stdin=stdin; return (A) this; + this.stdin = stdin; + return (A) this; } + public java.lang.Boolean hasStdin() { return this.stdin != null; } + public java.lang.Boolean getStdinOnce() { return this.stdinOnce; } + public A withStdinOnce(java.lang.Boolean stdinOnce) { - this.stdinOnce=stdinOnce; return (A) this; + this.stdinOnce = stdinOnce; + return (A) this; } + public java.lang.Boolean hasStdinOnce() { return this.stdinOnce != null; } + public java.lang.String getTargetContainerName() { return this.targetContainerName; } + public A withTargetContainerName(java.lang.String targetContainerName) { - this.targetContainerName=targetContainerName; return (A) this; + this.targetContainerName = targetContainerName; + return (A) this; } + public java.lang.Boolean hasTargetContainerName() { return this.targetContainerName != null; } - - /** - * Method is deprecated. use withTargetContainerName instead. - */ + + /** Method is deprecated. use withTargetContainerName instead. */ @java.lang.Deprecated public A withNewTargetContainerName(java.lang.String original) { - return (A)withTargetContainerName(new String(original)); + return (A) withTargetContainerName(new String(original)); } + public java.lang.String getTerminationMessagePath() { return this.terminationMessagePath; } + public A withTerminationMessagePath(java.lang.String terminationMessagePath) { - this.terminationMessagePath=terminationMessagePath; return (A) this; + this.terminationMessagePath = terminationMessagePath; + return (A) this; } + public java.lang.Boolean hasTerminationMessagePath() { return this.terminationMessagePath != null; } - - /** - * Method is deprecated. use withTerminationMessagePath instead. - */ + + /** Method is deprecated. use withTerminationMessagePath instead. */ @java.lang.Deprecated public A withNewTerminationMessagePath(java.lang.String original) { - return (A)withTerminationMessagePath(new String(original)); + return (A) withTerminationMessagePath(new String(original)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainer.TerminationMessagePolicyEnum getTerminationMessagePolicy() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainer.TerminationMessagePolicyEnum + getTerminationMessagePolicy() { return this.terminationMessagePolicy; } - public A withTerminationMessagePolicy(io.kubernetes.client.openapi.models.V1EphemeralContainer.TerminationMessagePolicyEnum terminationMessagePolicy) { - this.terminationMessagePolicy=terminationMessagePolicy; return (A) this; + + public A withTerminationMessagePolicy( + io.kubernetes.client.openapi.models.V1EphemeralContainer.TerminationMessagePolicyEnum + terminationMessagePolicy) { + this.terminationMessagePolicy = terminationMessagePolicy; + return (A) this; } + public java.lang.Boolean hasTerminationMessagePolicy() { return this.terminationMessagePolicy != null; } + public java.lang.Boolean getTty() { return this.tty; } + public A withTty(java.lang.Boolean tty) { - this.tty=tty; return (A) this; + this.tty = tty; + return (A) this; } + public java.lang.Boolean hasTty() { return this.tty != null; } - public A addToVolumeDevices(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item) { - if (this.volumeDevices == null) {this.volumeDevices = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item);_visitables.get("volumeDevices").add(index >= 0 ? index : _visitables.get("volumeDevices").size(), builder);this.volumeDevices.add(index >= 0 ? index : volumeDevices.size(), builder); return (A)this; + + public A addToVolumeDevices( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item) { + if (this.volumeDevices == null) { + this.volumeDevices = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); + _visitables + .get("volumeDevices") + .add(index >= 0 ? index : _visitables.get("volumeDevices").size(), builder); + this.volumeDevices.add(index >= 0 ? index : volumeDevices.size(), builder); + return (A) this; } - public A setToVolumeDevices(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item) { - if (this.volumeDevices == null) {this.volumeDevices = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); - if (index < 0 || index >= _visitables.get("volumeDevices").size()) { _visitables.get("volumeDevices").add(builder); } else { _visitables.get("volumeDevices").set(index, builder);} - if (index < 0 || index >= volumeDevices.size()) { volumeDevices.add(builder); } else { volumeDevices.set(index, builder);} - return (A)this; + + public A setToVolumeDevices( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item) { + if (this.volumeDevices == null) { + this.volumeDevices = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); + if (index < 0 || index >= _visitables.get("volumeDevices").size()) { + _visitables.get("volumeDevices").add(builder); + } else { + _visitables.get("volumeDevices").set(index, builder); + } + if (index < 0 || index >= volumeDevices.size()) { + volumeDevices.add(builder); + } else { + volumeDevices.set(index, builder); + } + return (A) this; } + public A addToVolumeDevices(io.kubernetes.client.openapi.models.V1VolumeDevice... items) { - if (this.volumeDevices == null) {this.volumeDevices = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) {io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item);_visitables.get("volumeDevices").add(builder);this.volumeDevices.add(builder);} return (A)this; + if (this.volumeDevices == null) { + this.volumeDevices = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) { + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); + _visitables.get("volumeDevices").add(builder); + this.volumeDevices.add(builder); + } + return (A) this; } - public A addAllToVolumeDevices(java.util.Collection items) { - if (this.volumeDevices == null) {this.volumeDevices = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) {io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item);_visitables.get("volumeDevices").add(builder);this.volumeDevices.add(builder);} return (A)this; + + public A addAllToVolumeDevices( + java.util.Collection items) { + if (this.volumeDevices == null) { + this.volumeDevices = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) { + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); + _visitables.get("volumeDevices").add(builder); + this.volumeDevices.add(builder); + } + return (A) this; } + public A removeFromVolumeDevices(io.kubernetes.client.openapi.models.V1VolumeDevice... items) { - for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) {io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item);_visitables.get("volumeDevices").remove(builder);if (this.volumeDevices != null) {this.volumeDevices.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) { + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); + _visitables.get("volumeDevices").remove(builder); + if (this.volumeDevices != null) { + this.volumeDevices.remove(builder); + } + } + return (A) this; } - public A removeAllFromVolumeDevices(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) {io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item);_visitables.get("volumeDevices").remove(builder);if (this.volumeDevices != null) {this.volumeDevices.remove(builder);}} return (A)this; + + public A removeAllFromVolumeDevices( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1VolumeDevice item : items) { + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(item); + _visitables.get("volumeDevices").remove(builder); + if (this.volumeDevices != null) { + this.volumeDevices.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromVolumeDevices(java.util.function.Predicate predicate) { + + public A removeMatchingFromVolumeDevices( + java.util.function.Predicate + predicate) { if (volumeDevices == null) return (A) this; - final Iterator each = volumeDevices.iterator(); + final Iterator each = + volumeDevices.iterator(); final List visitables = _visitables.get("volumeDevices"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder = each.next(); @@ -870,104 +1636,241 @@ public A removeMatchingFromVolumeDevices(java.util.function.Predicate getVolumeDevices() { return volumeDevices != null ? build(volumeDevices) : null; } + public java.util.List buildVolumeDevices() { return volumeDevices != null ? build(volumeDevices) : null; } - public io.kubernetes.client.openapi.models.V1VolumeDevice buildVolumeDevice(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1VolumeDevice buildVolumeDevice( + java.lang.Integer index) { return this.volumeDevices.get(index).build(); } + public io.kubernetes.client.openapi.models.V1VolumeDevice buildFirstVolumeDevice() { return this.volumeDevices.get(0).build(); } + public io.kubernetes.client.openapi.models.V1VolumeDevice buildLastVolumeDevice() { return this.volumeDevices.get(volumeDevices.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1VolumeDevice buildMatchingVolumeDevice(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder item: volumeDevices) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1VolumeDevice buildMatchingVolumeDevice( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder item : volumeDevices) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingVolumeDevice(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder item: volumeDevices) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVolumeDevice( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder item : volumeDevices) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withVolumeDevices(java.util.List volumeDevices) { - if (this.volumeDevices != null) { _visitables.get("volumeDevices").removeAll(this.volumeDevices);} - if (volumeDevices != null) {this.volumeDevices = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1VolumeDevice item : volumeDevices){this.addToVolumeDevices(item);}} else { this.volumeDevices = null;} return (A) this; + + public A withVolumeDevices( + java.util.List volumeDevices) { + if (this.volumeDevices != null) { + _visitables.get("volumeDevices").removeAll(this.volumeDevices); + } + if (volumeDevices != null) { + this.volumeDevices = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1VolumeDevice item : volumeDevices) { + this.addToVolumeDevices(item); + } + } else { + this.volumeDevices = null; + } + return (A) this; } + public A withVolumeDevices(io.kubernetes.client.openapi.models.V1VolumeDevice... volumeDevices) { - if (this.volumeDevices != null) {this.volumeDevices.clear();} - if (volumeDevices != null) {for (io.kubernetes.client.openapi.models.V1VolumeDevice item :volumeDevices){ this.addToVolumeDevices(item);}} return (A) this; + if (this.volumeDevices != null) { + this.volumeDevices.clear(); + } + if (volumeDevices != null) { + for (io.kubernetes.client.openapi.models.V1VolumeDevice item : volumeDevices) { + this.addToVolumeDevices(item); + } + } + return (A) this; } + public java.lang.Boolean hasVolumeDevices() { return volumeDevices != null && !volumeDevices.isEmpty(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested addNewVolumeDevice() { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.VolumeDevicesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + addNewVolumeDevice() { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .VolumeDevicesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested addNewVolumeDeviceLike(io.kubernetes.client.openapi.models.V1VolumeDevice item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.VolumeDevicesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + addNewVolumeDeviceLike(io.kubernetes.client.openapi.models.V1VolumeDevice item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .VolumeDevicesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested setNewVolumeDeviceLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.VolumeDevicesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + setNewVolumeDeviceLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .VolumeDevicesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested editVolumeDevice(java.lang.Integer index) { - if (volumeDevices.size() <= index) throw new RuntimeException("Can't edit volumeDevices. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + editVolumeDevice(java.lang.Integer index) { + if (volumeDevices.size() <= index) + throw new RuntimeException("Can't edit volumeDevices. Index exceeds size."); return setNewVolumeDeviceLike(index, buildVolumeDevice(index)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested editFirstVolumeDevice() { - if (volumeDevices.size() == 0) throw new RuntimeException("Can't edit first volumeDevices. The list is empty."); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + editFirstVolumeDevice() { + if (volumeDevices.size() == 0) + throw new RuntimeException("Can't edit first volumeDevices. The list is empty."); return setNewVolumeDeviceLike(0, buildVolumeDevice(0)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested editLastVolumeDevice() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + editLastVolumeDevice() { int index = volumeDevices.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last volumeDevices. The list is empty."); return setNewVolumeDeviceLike(index, buildVolumeDevice(index)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested editMatchingVolumeDevice(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested + editMatchingVolumeDevice( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item);_visitables.get("volumeMounts").add(index >= 0 ? index : _visitables.get("volumeMounts").size(), builder);this.volumeMounts.add(index >= 0 ? index : volumeMounts.size(), builder); return (A)this; + + public A addToVolumeMounts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item) { + if (this.volumeMounts == null) { + this.volumeMounts = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); + _visitables + .get("volumeMounts") + .add(index >= 0 ? index : _visitables.get("volumeMounts").size(), builder); + this.volumeMounts.add(index >= 0 ? index : volumeMounts.size(), builder); + return (A) this; } - public A setToVolumeMounts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeMount item) { - if (this.volumeMounts == null) {this.volumeMounts = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); - if (index < 0 || index >= _visitables.get("volumeMounts").size()) { _visitables.get("volumeMounts").add(builder); } else { _visitables.get("volumeMounts").set(index, builder);} - if (index < 0 || index >= volumeMounts.size()) { volumeMounts.add(builder); } else { volumeMounts.set(index, builder);} - return (A)this; + + public A setToVolumeMounts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item) { + if (this.volumeMounts == null) { + this.volumeMounts = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); + if (index < 0 || index >= _visitables.get("volumeMounts").size()) { + _visitables.get("volumeMounts").add(builder); + } else { + _visitables.get("volumeMounts").set(index, builder); + } + if (index < 0 || index >= volumeMounts.size()) { + volumeMounts.add(builder); + } else { + volumeMounts.set(index, builder); + } + return (A) this; } + public A addToVolumeMounts(io.kubernetes.client.openapi.models.V1VolumeMount... items) { - if (this.volumeMounts == null) {this.volumeMounts = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) {io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item);_visitables.get("volumeMounts").add(builder);this.volumeMounts.add(builder);} return (A)this; + if (this.volumeMounts == null) { + this.volumeMounts = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) { + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); + _visitables.get("volumeMounts").add(builder); + this.volumeMounts.add(builder); + } + return (A) this; } - public A addAllToVolumeMounts(java.util.Collection items) { - if (this.volumeMounts == null) {this.volumeMounts = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) {io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item);_visitables.get("volumeMounts").add(builder);this.volumeMounts.add(builder);} return (A)this; + + public A addAllToVolumeMounts( + java.util.Collection items) { + if (this.volumeMounts == null) { + this.volumeMounts = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) { + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); + _visitables.get("volumeMounts").add(builder); + this.volumeMounts.add(builder); + } + return (A) this; } + public A removeFromVolumeMounts(io.kubernetes.client.openapi.models.V1VolumeMount... items) { - for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) {io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item);_visitables.get("volumeMounts").remove(builder);if (this.volumeMounts != null) {this.volumeMounts.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) { + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); + _visitables.get("volumeMounts").remove(builder); + if (this.volumeMounts != null) { + this.volumeMounts.remove(builder); + } + } + return (A) this; } - public A removeAllFromVolumeMounts(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) {io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item);_visitables.get("volumeMounts").remove(builder);if (this.volumeMounts != null) {this.volumeMounts.remove(builder);}} return (A)this; + + public A removeAllFromVolumeMounts( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1VolumeMount item : items) { + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(item); + _visitables.get("volumeMounts").remove(builder); + if (this.volumeMounts != null) { + this.volumeMounts.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromVolumeMounts(java.util.function.Predicate predicate) { + + public A removeMatchingFromVolumeMounts( + java.util.function.Predicate + predicate) { if (volumeMounts == null) return (A) this; - final Iterator each = volumeMounts.iterator(); + final Iterator each = + volumeMounts.iterator(); final List visitables = _visitables.get("volumeMounts"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder = each.next(); @@ -976,315 +1879,533 @@ public A removeMatchingFromVolumeMounts(java.util.function.Predicate getVolumeMounts() { return volumeMounts != null ? build(volumeMounts) : null; } + public java.util.List buildVolumeMounts() { return volumeMounts != null ? build(volumeMounts) : null; } - public io.kubernetes.client.openapi.models.V1VolumeMount buildVolumeMount(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1VolumeMount buildVolumeMount( + java.lang.Integer index) { return this.volumeMounts.get(index).build(); } + public io.kubernetes.client.openapi.models.V1VolumeMount buildFirstVolumeMount() { return this.volumeMounts.get(0).build(); } + public io.kubernetes.client.openapi.models.V1VolumeMount buildLastVolumeMount() { return this.volumeMounts.get(volumeMounts.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1VolumeMount buildMatchingVolumeMount(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeMountBuilder item: volumeMounts) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1VolumeMount buildMatchingVolumeMount( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeMountBuilder item : volumeMounts) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingVolumeMount(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeMountBuilder item: volumeMounts) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVolumeMount( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeMountBuilder item : volumeMounts) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withVolumeMounts(java.util.List volumeMounts) { - if (this.volumeMounts != null) { _visitables.get("volumeMounts").removeAll(this.volumeMounts);} - if (volumeMounts != null) {this.volumeMounts = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1VolumeMount item : volumeMounts){this.addToVolumeMounts(item);}} else { this.volumeMounts = null;} return (A) this; + + public A withVolumeMounts( + java.util.List volumeMounts) { + if (this.volumeMounts != null) { + _visitables.get("volumeMounts").removeAll(this.volumeMounts); + } + if (volumeMounts != null) { + this.volumeMounts = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1VolumeMount item : volumeMounts) { + this.addToVolumeMounts(item); + } + } else { + this.volumeMounts = null; + } + return (A) this; } + public A withVolumeMounts(io.kubernetes.client.openapi.models.V1VolumeMount... volumeMounts) { - if (this.volumeMounts != null) {this.volumeMounts.clear();} - if (volumeMounts != null) {for (io.kubernetes.client.openapi.models.V1VolumeMount item :volumeMounts){ this.addToVolumeMounts(item);}} return (A) this; + if (this.volumeMounts != null) { + this.volumeMounts.clear(); + } + if (volumeMounts != null) { + for (io.kubernetes.client.openapi.models.V1VolumeMount item : volumeMounts) { + this.addToVolumeMounts(item); + } + } + return (A) this; } + public java.lang.Boolean hasVolumeMounts() { return volumeMounts != null && !volumeMounts.isEmpty(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested addNewVolumeMount() { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.VolumeMountsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + addNewVolumeMount() { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .VolumeMountsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested addNewVolumeMountLike(io.kubernetes.client.openapi.models.V1VolumeMount item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.VolumeMountsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + addNewVolumeMountLike(io.kubernetes.client.openapi.models.V1VolumeMount item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .VolumeMountsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested setNewVolumeMountLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeMount item) { - return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl.VolumeMountsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + setNewVolumeMountLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item) { + return new io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl + .VolumeMountsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested editVolumeMount(java.lang.Integer index) { - if (volumeMounts.size() <= index) throw new RuntimeException("Can't edit volumeMounts. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + editVolumeMount(java.lang.Integer index) { + if (volumeMounts.size() <= index) + throw new RuntimeException("Can't edit volumeMounts. Index exceeds size."); return setNewVolumeMountLike(index, buildVolumeMount(index)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested editFirstVolumeMount() { - if (volumeMounts.size() == 0) throw new RuntimeException("Can't edit first volumeMounts. The list is empty."); + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + editFirstVolumeMount() { + if (volumeMounts.size() == 0) + throw new RuntimeException("Can't edit first volumeMounts. The list is empty."); return setNewVolumeMountLike(0, buildVolumeMount(0)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested editLastVolumeMount() { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + editLastVolumeMount() { int index = volumeMounts.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last volumeMounts. The list is empty."); return setNewVolumeMountLike(index, buildVolumeMount(index)); } - public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested editMatchingVolumeMount(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested + editMatchingVolumeMount( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1EnvVarFluentImpl> implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested,io.kubernetes.client.fluent.Nested{ - EnvNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvVar item) { + + public class EnvNestedImpl + extends io.kubernetes.client.openapi.models.V1EnvVarFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested> + implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvNested, + io.kubernetes.client.fluent.Nested { + EnvNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvVar item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(this, item); } + EnvNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1EnvVarBuilder(this); } + io.kubernetes.client.openapi.models.V1EnvVarBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EphemeralContainerFluentImpl.this.setToEnv(index,builder.build()); + return (N) V1EphemeralContainerFluentImpl.this.setToEnv(index, builder.build()); } + public N endEnv() { return and(); } - } - public class EnvFromNestedImpl extends io.kubernetes.client.openapi.models.V1EnvFromSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested,io.kubernetes.client.fluent.Nested{ - EnvFromNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EnvFromSource item) { + + public class EnvFromNestedImpl + extends io.kubernetes.client.openapi.models.V1EnvFromSourceFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested> + implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.EnvFromNested, + io.kubernetes.client.fluent.Nested { + EnvFromNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EnvFromSource item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(this, item); } + EnvFromNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1EnvFromSourceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EphemeralContainerFluentImpl.this.setToEnvFrom(index,builder.build()); + return (N) V1EphemeralContainerFluentImpl.this.setToEnvFrom(index, builder.build()); } + public N endEnvFrom() { return and(); } - } - public class LifecycleNestedImpl extends io.kubernetes.client.openapi.models.V1LifecycleFluentImpl> implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested,io.kubernetes.client.fluent.Nested{ + + public class LifecycleNestedImpl + extends io.kubernetes.client.openapi.models.V1LifecycleFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested> + implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LifecycleNested, + io.kubernetes.client.fluent.Nested { LifecycleNestedImpl(io.kubernetes.client.openapi.models.V1Lifecycle item) { this.builder = new io.kubernetes.client.openapi.models.V1LifecycleBuilder(this, item); } + LifecycleNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LifecycleBuilder(this); } + io.kubernetes.client.openapi.models.V1LifecycleBuilder builder; + public N and() { return (N) V1EphemeralContainerFluentImpl.this.withLifecycle(builder.build()); } + public N endLifecycle() { return and(); } - } - public class LivenessProbeNestedImpl extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl> implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested,io.kubernetes.client.fluent.Nested{ + + public class LivenessProbeNestedImpl + extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested> + implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.LivenessProbeNested< + N>, + io.kubernetes.client.fluent.Nested { LivenessProbeNestedImpl(io.kubernetes.client.openapi.models.V1Probe item) { this.builder = new io.kubernetes.client.openapi.models.V1ProbeBuilder(this, item); } + LivenessProbeNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ProbeBuilder(this); } + io.kubernetes.client.openapi.models.V1ProbeBuilder builder; + public N and() { return (N) V1EphemeralContainerFluentImpl.this.withLivenessProbe(builder.build()); } + public N endLivenessProbe() { return and(); } - } - public class PortsNestedImpl extends io.kubernetes.client.openapi.models.V1ContainerPortFluentImpl> implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested,io.kubernetes.client.fluent.Nested{ - PortsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerPort item) { + + public class PortsNestedImpl + extends io.kubernetes.client.openapi.models.V1ContainerPortFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested> + implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.PortsNested, + io.kubernetes.client.fluent.Nested { + PortsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerPort item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(this, item); } + PortsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ContainerPortBuilder(this); } + io.kubernetes.client.openapi.models.V1ContainerPortBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EphemeralContainerFluentImpl.this.setToPorts(index,builder.build()); + return (N) V1EphemeralContainerFluentImpl.this.setToPorts(index, builder.build()); } + public N endPort() { return and(); } - } - public class ReadinessProbeNestedImpl extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl> implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested,io.kubernetes.client.fluent.Nested{ + + public class ReadinessProbeNestedImpl + extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ReadinessProbeNested> + implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent + .ReadinessProbeNested< + N>, + io.kubernetes.client.fluent.Nested { ReadinessProbeNestedImpl(io.kubernetes.client.openapi.models.V1Probe item) { this.builder = new io.kubernetes.client.openapi.models.V1ProbeBuilder(this, item); } + ReadinessProbeNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ProbeBuilder(this); } + io.kubernetes.client.openapi.models.V1ProbeBuilder builder; + public N and() { return (N) V1EphemeralContainerFluentImpl.this.withReadinessProbe(builder.build()); } + public N endReadinessProbe() { return and(); } - } - public class ResourcesNestedImpl extends io.kubernetes.client.openapi.models.V1ResourceRequirementsFluentImpl> implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested,io.kubernetes.client.fluent.Nested{ + + public class ResourcesNestedImpl + extends io.kubernetes.client.openapi.models.V1ResourceRequirementsFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested> + implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.ResourcesNested, + io.kubernetes.client.fluent.Nested { ResourcesNestedImpl(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { - this.builder = new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(this, item); } + ResourcesNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(this); } + io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder builder; + public N and() { return (N) V1EphemeralContainerFluentImpl.this.withResources(builder.build()); } + public N endResources() { return and(); } - } - public class SecurityContextNestedImpl extends io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl> implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested,io.kubernetes.client.fluent.Nested{ + + public class SecurityContextNestedImpl + extends io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.SecurityContextNested> + implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent + .SecurityContextNested< + N>, + io.kubernetes.client.fluent.Nested { SecurityContextNestedImpl(io.kubernetes.client.openapi.models.V1SecurityContext item) { this.builder = new io.kubernetes.client.openapi.models.V1SecurityContextBuilder(this, item); } + SecurityContextNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecurityContextBuilder(this); } + io.kubernetes.client.openapi.models.V1SecurityContextBuilder builder; + public N and() { return (N) V1EphemeralContainerFluentImpl.this.withSecurityContext(builder.build()); } + public N endSecurityContext() { return and(); } - } - public class StartupProbeNestedImpl extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl> implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested,io.kubernetes.client.fluent.Nested{ + + public class StartupProbeNestedImpl + extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested> + implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.StartupProbeNested< + N>, + io.kubernetes.client.fluent.Nested { StartupProbeNestedImpl(io.kubernetes.client.openapi.models.V1Probe item) { this.builder = new io.kubernetes.client.openapi.models.V1ProbeBuilder(this, item); } + StartupProbeNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ProbeBuilder(this); } + io.kubernetes.client.openapi.models.V1ProbeBuilder builder; + public N and() { return (N) V1EphemeralContainerFluentImpl.this.withStartupProbe(builder.build()); } + public N endStartupProbe() { return and(); } - } - public class VolumeDevicesNestedImpl extends io.kubernetes.client.openapi.models.V1VolumeDeviceFluentImpl> implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested,io.kubernetes.client.fluent.Nested{ - VolumeDevicesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeDevice item) { + + public class VolumeDevicesNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeDeviceFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested> + implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeDevicesNested< + N>, + io.kubernetes.client.fluent.Nested { + VolumeDevicesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeDevice item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(this, item); } + VolumeDevicesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EphemeralContainerFluentImpl.this.setToVolumeDevices(index,builder.build()); + return (N) V1EphemeralContainerFluentImpl.this.setToVolumeDevices(index, builder.build()); } + public N endVolumeDevice() { return and(); } - } - public class VolumeMountsNestedImpl extends io.kubernetes.client.openapi.models.V1VolumeMountFluentImpl> implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested,io.kubernetes.client.fluent.Nested{ - VolumeMountsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeMount item) { + + public class VolumeMountsNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeMountFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested> + implements io.kubernetes.client.openapi.models.V1EphemeralContainerFluent.VolumeMountsNested< + N>, + io.kubernetes.client.fluent.Nested { + VolumeMountsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeMount item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(this, item); } + VolumeMountsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1VolumeMountBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeMountBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1EphemeralContainerFluentImpl.this.setToVolumeMounts(index,builder.build()); + return (N) V1EphemeralContainerFluentImpl.this.setToVolumeMounts(index, builder.build()); } + public N endVolumeMount() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralVolumeSourceBuilder.java index 12093fb491..91f4350aa2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralVolumeSourceBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EphemeralVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EphemeralVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EphemeralVolumeSource, + io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceBuilder> { public V1EphemeralVolumeSourceBuilder() { this(false); } + public V1EphemeralVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1EphemeralVolumeSource(), validationEnabled); } - public V1EphemeralVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent fluent) { + + public V1EphemeralVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent fluent) { this(fluent, false); } - public V1EphemeralVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EphemeralVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EphemeralVolumeSource(), validationEnabled); } - public V1EphemeralVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1EphemeralVolumeSource instance) { + + public V1EphemeralVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1EphemeralVolumeSource instance) { this(fluent, instance, false); } - public V1EphemeralVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1EphemeralVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EphemeralVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1EphemeralVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withVolumeClaimTemplate(instance.getVolumeClaimTemplate()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1EphemeralVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1EphemeralVolumeSource instance) { - this(instance,false); + + public V1EphemeralVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1EphemeralVolumeSource instance) { + this(instance, false); } - public V1EphemeralVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1EphemeralVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EphemeralVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1EphemeralVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withVolumeClaimTemplate(instance.getVolumeClaimTemplate()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EphemeralVolumeSource build() { V1EphemeralVolumeSource buildable = new V1EphemeralVolumeSource(); buildable.setVolumeClaimTemplate(fluent.getVolumeClaimTemplate()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EphemeralVolumeSourceBuilder that = (V1EphemeralVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralVolumeSourceFluent.java index 2f6cace6bf..67bdefae29 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralVolumeSourceFluent.java @@ -1,35 +1,74 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1EphemeralVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1EphemeralVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildVolumeClaimTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate getVolumeClaimTemplate(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate buildVolumeClaimTemplate(); - public A withVolumeClaimTemplate(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate volumeClaimTemplate); + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate + getVolumeClaimTemplate(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate + buildVolumeClaimTemplate(); + + public A withVolumeClaimTemplate( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate volumeClaimTemplate); + public java.lang.Boolean hasVolumeClaimTemplate(); - public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent.VolumeClaimTemplateNested withNewVolumeClaimTemplate(); - public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent.VolumeClaimTemplateNested withNewVolumeClaimTemplateLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate item); - public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent.VolumeClaimTemplateNested editVolumeClaimTemplate(); - public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent.VolumeClaimTemplateNested editOrNewVolumeClaimTemplate(); - public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent.VolumeClaimTemplateNested editOrNewVolumeClaimTemplateLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate item); - public interface VolumeClaimTemplateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent>{ + + public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent + .VolumeClaimTemplateNested< + A> + withNewVolumeClaimTemplate(); + + public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent + .VolumeClaimTemplateNested< + A> + withNewVolumeClaimTemplateLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate item); + + public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent + .VolumeClaimTemplateNested< + A> + editVolumeClaimTemplate(); + + public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent + .VolumeClaimTemplateNested< + A> + editOrNewVolumeClaimTemplate(); + + public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent + .VolumeClaimTemplateNested< + A> + editOrNewVolumeClaimTemplateLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate item); + + public interface VolumeClaimTemplateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent< + io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent + .VolumeClaimTemplateNested< + N>> { public N and(); + public N endVolumeClaimTemplate(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralVolumeSourceFluentImpl.java index 339a8a9643..cfba286c76 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EphemeralVolumeSourceFluentImpl.java @@ -1,81 +1,151 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1EphemeralVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent{ - public V1EphemeralVolumeSourceFluentImpl() { - } - public V1EphemeralVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1EphemeralVolumeSource instance) { - this.withVolumeClaimTemplate(instance.getVolumeClaimTemplate()); +/** Generated */ +public class V1EphemeralVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent { + public V1EphemeralVolumeSourceFluentImpl() {} + public V1EphemeralVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1EphemeralVolumeSource instance) { + this.withVolumeClaimTemplate(instance.getVolumeClaimTemplate()); } - private io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateBuilder volumeClaimTemplate; - + + private io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateBuilder + volumeClaimTemplate; + /** * This method has been deprecated, please use method buildVolumeClaimTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate getVolumeClaimTemplate() { - return this.volumeClaimTemplate!=null ?this.volumeClaimTemplate.build():null; + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate + getVolumeClaimTemplate() { + return this.volumeClaimTemplate != null ? this.volumeClaimTemplate.build() : null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate buildVolumeClaimTemplate() { - return this.volumeClaimTemplate!=null ?this.volumeClaimTemplate.build():null; + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate + buildVolumeClaimTemplate() { + return this.volumeClaimTemplate != null ? this.volumeClaimTemplate.build() : null; } - public A withVolumeClaimTemplate(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate volumeClaimTemplate) { + + public A withVolumeClaimTemplate( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate volumeClaimTemplate) { _visitables.get("volumeClaimTemplate").remove(this.volumeClaimTemplate); - if (volumeClaimTemplate!=null){ this.volumeClaimTemplate= new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateBuilder(volumeClaimTemplate); _visitables.get("volumeClaimTemplate").add(this.volumeClaimTemplate);} return (A) this; + if (volumeClaimTemplate != null) { + this.volumeClaimTemplate = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateBuilder( + volumeClaimTemplate); + _visitables.get("volumeClaimTemplate").add(this.volumeClaimTemplate); + } + return (A) this; } + public java.lang.Boolean hasVolumeClaimTemplate() { return this.volumeClaimTemplate != null; } - public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent.VolumeClaimTemplateNested withNewVolumeClaimTemplate() { - return new io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluentImpl.VolumeClaimTemplateNestedImpl(); + + public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent + .VolumeClaimTemplateNested< + A> + withNewVolumeClaimTemplate() { + return new io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluentImpl + .VolumeClaimTemplateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent.VolumeClaimTemplateNested withNewVolumeClaimTemplateLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate item) { - return new io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluentImpl.VolumeClaimTemplateNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent + .VolumeClaimTemplateNested< + A> + withNewVolumeClaimTemplateLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate item) { + return new io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluentImpl + .VolumeClaimTemplateNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent.VolumeClaimTemplateNested editVolumeClaimTemplate() { + + public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent + .VolumeClaimTemplateNested< + A> + editVolumeClaimTemplate() { return withNewVolumeClaimTemplateLike(getVolumeClaimTemplate()); } - public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent.VolumeClaimTemplateNested editOrNewVolumeClaimTemplate() { - return withNewVolumeClaimTemplateLike(getVolumeClaimTemplate() != null ? getVolumeClaimTemplate(): new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent + .VolumeClaimTemplateNested< + A> + editOrNewVolumeClaimTemplate() { + return withNewVolumeClaimTemplateLike( + getVolumeClaimTemplate() != null + ? getVolumeClaimTemplate() + : new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent.VolumeClaimTemplateNested editOrNewVolumeClaimTemplateLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate item) { - return withNewVolumeClaimTemplateLike(getVolumeClaimTemplate() != null ? getVolumeClaimTemplate(): item); + + public io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent + .VolumeClaimTemplateNested< + A> + editOrNewVolumeClaimTemplateLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate item) { + return withNewVolumeClaimTemplateLike( + getVolumeClaimTemplate() != null ? getVolumeClaimTemplate() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1EphemeralVolumeSourceFluentImpl that = (V1EphemeralVolumeSourceFluentImpl) o; - if (volumeClaimTemplate != null ? !volumeClaimTemplate.equals(that.volumeClaimTemplate) :that.volumeClaimTemplate != null) return false; + if (volumeClaimTemplate != null + ? !volumeClaimTemplate.equals(that.volumeClaimTemplate) + : that.volumeClaimTemplate != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(volumeClaimTemplate, super.hashCode()); + return java.util.Objects.hash(volumeClaimTemplate, super.hashCode()); } - public class VolumeClaimTemplateNestedImpl extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluentImpl> implements io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent.VolumeClaimTemplateNested,io.kubernetes.client.fluent.Nested{ - VolumeClaimTemplateNestedImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate item) { - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateBuilder(this, item); + + public class VolumeClaimTemplateNestedImpl + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluentImpl< + io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent + .VolumeClaimTemplateNested< + N>> + implements io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent + .VolumeClaimTemplateNested< + N>, + io.kubernetes.client.fluent.Nested { + VolumeClaimTemplateNestedImpl( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate item) { + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateBuilder( + this, item); } + VolumeClaimTemplateNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateBuilder(this); } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateBuilder builder; + public N and() { return (N) V1EphemeralVolumeSourceFluentImpl.this.withVolumeClaimTemplate(builder.build()); } + public N endVolumeClaimTemplate() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EventSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EventSourceBuilder.java index 988a0f04f1..da386802d8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EventSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EventSourceBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EventSourceBuilder extends io.kubernetes.client.openapi.models.V1EventSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EventSourceBuilder + extends io.kubernetes.client.openapi.models.V1EventSourceFluentImpl< + io.kubernetes.client.openapi.models.V1EventSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1EventSource, + io.kubernetes.client.openapi.models.V1EventSourceBuilder> { public V1EventSourceBuilder() { this(false); } + public V1EventSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1EventSource(), validationEnabled); } + public V1EventSourceBuilder(io.kubernetes.client.openapi.models.V1EventSourceFluent fluent) { this(fluent, false); } - public V1EventSourceBuilder(io.kubernetes.client.openapi.models.V1EventSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EventSourceBuilder( + io.kubernetes.client.openapi.models.V1EventSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1EventSource(), validationEnabled); } - public V1EventSourceBuilder(io.kubernetes.client.openapi.models.V1EventSourceFluent fluent,io.kubernetes.client.openapi.models.V1EventSource instance) { + + public V1EventSourceBuilder( + io.kubernetes.client.openapi.models.V1EventSourceFluent fluent, + io.kubernetes.client.openapi.models.V1EventSource instance) { this(fluent, instance, false); } - public V1EventSourceBuilder(io.kubernetes.client.openapi.models.V1EventSourceFluent fluent,io.kubernetes.client.openapi.models.V1EventSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EventSourceBuilder( + io.kubernetes.client.openapi.models.V1EventSourceFluent fluent, + io.kubernetes.client.openapi.models.V1EventSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withComponent(instance.getComponent()); fluent.withHost(instance.getHost()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1EventSourceBuilder(io.kubernetes.client.openapi.models.V1EventSource instance) { - this(instance,false); + this(instance, false); } - public V1EventSourceBuilder(io.kubernetes.client.openapi.models.V1EventSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EventSourceBuilder( + io.kubernetes.client.openapi.models.V1EventSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withComponent(instance.getComponent()); this.withHost(instance.getHost()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EventSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1EventSource build() { V1EventSource buildable = new V1EventSource(); buildable.setComponent(fluent.getComponent()); buildable.setHost(fluent.getHost()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EventSourceBuilder that = (V1EventSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EventSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EventSourceFluent.java index 21f7158a3c..c8fcc87962 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EventSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EventSourceFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1EventSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1EventSourceFluent< + A extends io.kubernetes.client.openapi.models.V1EventSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getComponent(); + public A withComponent(java.lang.String component); + public java.lang.Boolean hasComponent(); - - /** - * Method is deprecated. use withComponent instead. - */ + + /** Method is deprecated. use withComponent instead. */ @java.lang.Deprecated public A withNewComponent(java.lang.String original); + public java.lang.String getHost(); + public A withHost(java.lang.String host); + public java.lang.Boolean hasHost(); - - /** - * Method is deprecated. use withHost instead. - */ + + /** Method is deprecated. use withHost instead. */ @java.lang.Deprecated public A withNewHost(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EventSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EventSourceFluentImpl.java index 43e592e9ad..6fa549fba7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EventSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EventSourceFluentImpl.java @@ -1,69 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1EventSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1EventSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EventSourceFluent { + public V1EventSourceFluentImpl() {} - /** - * Generated - */ -public class V1EventSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EventSourceFluent{ - public V1EventSourceFluentImpl() { - } public V1EventSourceFluentImpl(io.kubernetes.client.openapi.models.V1EventSource instance) { this.withComponent(instance.getComponent()); this.withHost(instance.getHost()); - } + private java.lang.String component; private java.lang.String host; + public java.lang.String getComponent() { return this.component; } + public A withComponent(java.lang.String component) { - this.component=component; return (A) this; + this.component = component; + return (A) this; } + public java.lang.Boolean hasComponent() { return this.component != null; } - - /** - * Method is deprecated. use withComponent instead. - */ + + /** Method is deprecated. use withComponent instead. */ @java.lang.Deprecated public A withNewComponent(java.lang.String original) { - return (A)withComponent(new String(original)); + return (A) withComponent(new String(original)); } + public java.lang.String getHost() { return this.host; } + public A withHost(java.lang.String host) { - this.host=host; return (A) this; + this.host = host; + return (A) this; } + public java.lang.Boolean hasHost() { return this.host != null; } - - /** - * Method is deprecated. use withHost instead. - */ + + /** Method is deprecated. use withHost instead. */ @java.lang.Deprecated public A withNewHost(java.lang.String original) { - return (A)withHost(new String(original)); + return (A) withHost(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1EventSourceFluentImpl that = (V1EventSourceFluentImpl) o; - if (component != null ? !component.equals(that.component) :that.component != null) return false; - if (host != null ? !host.equals(that.host) :that.host != null) return false; + if (component != null ? !component.equals(that.component) : that.component != null) + return false; + if (host != null ? !host.equals(that.host) : that.host != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(component, host, super.hashCode()); + return java.util.Objects.hash(component, host, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EvictionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EvictionBuilder.java index 4272585dce..def6e1f229 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EvictionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EvictionBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1EvictionBuilder extends io.kubernetes.client.openapi.models.V1EvictionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1EvictionBuilder + extends io.kubernetes.client.openapi.models.V1EvictionFluentImpl< + io.kubernetes.client.openapi.models.V1EvictionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Eviction, + io.kubernetes.client.openapi.models.V1EvictionBuilder> { public V1EvictionBuilder() { this(false); } + public V1EvictionBuilder(java.lang.Boolean validationEnabled) { this(new V1Eviction(), validationEnabled); } + public V1EvictionBuilder(io.kubernetes.client.openapi.models.V1EvictionFluent fluent) { this(fluent, false); } - public V1EvictionBuilder(io.kubernetes.client.openapi.models.V1EvictionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1EvictionBuilder( + io.kubernetes.client.openapi.models.V1EvictionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Eviction(), validationEnabled); } - public V1EvictionBuilder(io.kubernetes.client.openapi.models.V1EvictionFluent fluent,io.kubernetes.client.openapi.models.V1Eviction instance) { + + public V1EvictionBuilder( + io.kubernetes.client.openapi.models.V1EvictionFluent fluent, + io.kubernetes.client.openapi.models.V1Eviction instance) { this(fluent, instance, false); } - public V1EvictionBuilder(io.kubernetes.client.openapi.models.V1EvictionFluent fluent,io.kubernetes.client.openapi.models.V1Eviction instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1EvictionBuilder( + io.kubernetes.client.openapi.models.V1EvictionFluent fluent, + io.kubernetes.client.openapi.models.V1Eviction instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withDeleteOptions(instance.getDeleteOptions()); @@ -29,13 +55,17 @@ public V1EvictionBuilder(io.kubernetes.client.openapi.models.V1EvictionFluent fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1EvictionBuilder(io.kubernetes.client.openapi.models.V1Eviction instance) { - this(instance,false); + this(instance, false); } - public V1EvictionBuilder(io.kubernetes.client.openapi.models.V1Eviction instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1EvictionBuilder( + io.kubernetes.client.openapi.models.V1Eviction instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withDeleteOptions(instance.getDeleteOptions()); @@ -44,10 +74,12 @@ public V1EvictionBuilder(io.kubernetes.client.openapi.models.V1Eviction instance this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1EvictionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Eviction build() { V1Eviction buildable = new V1Eviction(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1Eviction build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1EvictionBuilder that = (V1EvictionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EvictionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EvictionFluent.java index 63c1f7841a..542c8a3f8d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EvictionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EvictionFluent.java @@ -1,73 +1,110 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1EvictionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1EvictionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - + /** * This method has been deprecated, please use method buildDeleteOptions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DeleteOptions getDeleteOptions(); + public io.kubernetes.client.openapi.models.V1DeleteOptions buildDeleteOptions(); + public A withDeleteOptions(io.kubernetes.client.openapi.models.V1DeleteOptions deleteOptions); + public java.lang.Boolean hasDeleteOptions(); - public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested withNewDeleteOptions(); - public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested withNewDeleteOptionsLike(io.kubernetes.client.openapi.models.V1DeleteOptions item); - public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested editDeleteOptions(); - public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested editOrNewDeleteOptions(); - public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested editOrNewDeleteOptionsLike(io.kubernetes.client.openapi.models.V1DeleteOptions item); + + public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested + withNewDeleteOptions(); + + public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested + withNewDeleteOptionsLike(io.kubernetes.client.openapi.models.V1DeleteOptions item); + + public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested + editDeleteOptions(); + + public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested + editOrNewDeleteOptions(); + + public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested + editOrNewDeleteOptionsLike(io.kubernetes.client.openapi.models.V1DeleteOptions item); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public interface DeleteOptionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DeleteOptionsFluent>{ + + public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public interface DeleteOptionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DeleteOptionsFluent< + io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested> { public N and(); + public N endDeleteOptions(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EvictionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EvictionFluentImpl.java index 1425d13bfb..3a5d6b172a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EvictionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1EvictionFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1EvictionFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1EvictionFluent { + public V1EvictionFluentImpl() {} - /** - * Generated - */ -public class V1EvictionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1EvictionFluent{ - public V1EvictionFluentImpl() { - } public V1EvictionFluentImpl(io.kubernetes.client.openapi.models.V1Eviction instance) { this.withApiVersion(instance.getApiVersion()); @@ -21,158 +26,224 @@ public V1EvictionFluentImpl(io.kubernetes.client.openapi.models.V1Eviction insta this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private io.kubernetes.client.openapi.models.V1DeleteOptionsBuilder deleteOptions; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - + /** * This method has been deprecated, please use method buildDeleteOptions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DeleteOptions getDeleteOptions() { - return this.deleteOptions!=null ?this.deleteOptions.build():null; + return this.deleteOptions != null ? this.deleteOptions.build() : null; } + public io.kubernetes.client.openapi.models.V1DeleteOptions buildDeleteOptions() { - return this.deleteOptions!=null ?this.deleteOptions.build():null; + return this.deleteOptions != null ? this.deleteOptions.build() : null; } + public A withDeleteOptions(io.kubernetes.client.openapi.models.V1DeleteOptions deleteOptions) { _visitables.get("deleteOptions").remove(this.deleteOptions); - if (deleteOptions!=null){ this.deleteOptions= new io.kubernetes.client.openapi.models.V1DeleteOptionsBuilder(deleteOptions); _visitables.get("deleteOptions").add(this.deleteOptions);} return (A) this; + if (deleteOptions != null) { + this.deleteOptions = + new io.kubernetes.client.openapi.models.V1DeleteOptionsBuilder(deleteOptions); + _visitables.get("deleteOptions").add(this.deleteOptions); + } + return (A) this; } + public java.lang.Boolean hasDeleteOptions() { return this.deleteOptions != null; } - public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested withNewDeleteOptions() { + + public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested + withNewDeleteOptions() { return new io.kubernetes.client.openapi.models.V1EvictionFluentImpl.DeleteOptionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested withNewDeleteOptionsLike(io.kubernetes.client.openapi.models.V1DeleteOptions item) { - return new io.kubernetes.client.openapi.models.V1EvictionFluentImpl.DeleteOptionsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested + withNewDeleteOptionsLike(io.kubernetes.client.openapi.models.V1DeleteOptions item) { + return new io.kubernetes.client.openapi.models.V1EvictionFluentImpl.DeleteOptionsNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested editDeleteOptions() { + + public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested + editDeleteOptions() { return withNewDeleteOptionsLike(getDeleteOptions()); } - public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested editOrNewDeleteOptions() { - return withNewDeleteOptionsLike(getDeleteOptions() != null ? getDeleteOptions(): new io.kubernetes.client.openapi.models.V1DeleteOptionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested + editOrNewDeleteOptions() { + return withNewDeleteOptionsLike( + getDeleteOptions() != null + ? getDeleteOptions() + : new io.kubernetes.client.openapi.models.V1DeleteOptionsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested editOrNewDeleteOptionsLike(io.kubernetes.client.openapi.models.V1DeleteOptions item) { - return withNewDeleteOptionsLike(getDeleteOptions() != null ? getDeleteOptions(): item); + + public io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested + editOrNewDeleteOptionsLike(io.kubernetes.client.openapi.models.V1DeleteOptions item) { + return withNewDeleteOptionsLike(getDeleteOptions() != null ? getDeleteOptions() : item); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1EvictionFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1EvictionFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1EvictionFluentImpl that = (V1EvictionFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (deleteOptions != null ? !deleteOptions.equals(that.deleteOptions) :that.deleteOptions != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (deleteOptions != null + ? !deleteOptions.equals(that.deleteOptions) + : that.deleteOptions != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, deleteOptions, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, deleteOptions, kind, metadata, super.hashCode()); } - public class DeleteOptionsNestedImpl extends io.kubernetes.client.openapi.models.V1DeleteOptionsFluentImpl> implements io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested,io.kubernetes.client.fluent.Nested{ + + public class DeleteOptionsNestedImpl + extends io.kubernetes.client.openapi.models.V1DeleteOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested> + implements io.kubernetes.client.openapi.models.V1EvictionFluent.DeleteOptionsNested, + io.kubernetes.client.fluent.Nested { DeleteOptionsNestedImpl(io.kubernetes.client.openapi.models.V1DeleteOptions item) { this.builder = new io.kubernetes.client.openapi.models.V1DeleteOptionsBuilder(this, item); } + DeleteOptionsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1DeleteOptionsBuilder(this); } + io.kubernetes.client.openapi.models.V1DeleteOptionsBuilder builder; + public N and() { return (N) V1EvictionFluentImpl.this.withDeleteOptions(builder.build()); } + public N endDeleteOptions() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1EvictionFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1EvictionFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExecActionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExecActionBuilder.java index 897cd60313..0ea08cb7a8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExecActionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExecActionBuilder.java @@ -1,58 +1,95 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ExecActionBuilder extends io.kubernetes.client.openapi.models.V1ExecActionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ExecActionBuilder + extends io.kubernetes.client.openapi.models.V1ExecActionFluentImpl< + io.kubernetes.client.openapi.models.V1ExecActionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ExecAction, + io.kubernetes.client.openapi.models.V1ExecActionBuilder> { public V1ExecActionBuilder() { this(false); } + public V1ExecActionBuilder(java.lang.Boolean validationEnabled) { this(new V1ExecAction(), validationEnabled); } + public V1ExecActionBuilder(io.kubernetes.client.openapi.models.V1ExecActionFluent fluent) { this(fluent, false); } - public V1ExecActionBuilder(io.kubernetes.client.openapi.models.V1ExecActionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ExecActionBuilder( + io.kubernetes.client.openapi.models.V1ExecActionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ExecAction(), validationEnabled); } - public V1ExecActionBuilder(io.kubernetes.client.openapi.models.V1ExecActionFluent fluent,io.kubernetes.client.openapi.models.V1ExecAction instance) { + + public V1ExecActionBuilder( + io.kubernetes.client.openapi.models.V1ExecActionFluent fluent, + io.kubernetes.client.openapi.models.V1ExecAction instance) { this(fluent, instance, false); } - public V1ExecActionBuilder(io.kubernetes.client.openapi.models.V1ExecActionFluent fluent,io.kubernetes.client.openapi.models.V1ExecAction instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ExecActionBuilder( + io.kubernetes.client.openapi.models.V1ExecActionFluent fluent, + io.kubernetes.client.openapi.models.V1ExecAction instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCommand(instance.getCommand()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ExecActionBuilder(io.kubernetes.client.openapi.models.V1ExecAction instance) { - this(instance,false); + this(instance, false); } - public V1ExecActionBuilder(io.kubernetes.client.openapi.models.V1ExecAction instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ExecActionBuilder( + io.kubernetes.client.openapi.models.V1ExecAction instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCommand(instance.getCommand()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ExecActionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ExecAction build() { V1ExecAction buildable = new V1ExecAction(); buildable.setCommand(fluent.getCommand()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ExecActionBuilder that = (V1ExecActionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExecActionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExecActionFluent.java index 6d04ae1870..7739537e5e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExecActionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExecActionFluent.java @@ -1,34 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1ExecActionFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToCommand(java.lang.Integer index,java.lang.String item); - public A setToCommand(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1ExecActionFluent< + A extends io.kubernetes.client.openapi.models.V1ExecActionFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToCommand(java.lang.Integer index, java.lang.String item); + + public A setToCommand(java.lang.Integer index, java.lang.String item); + public A addToCommand(java.lang.String... items); + public A addAllToCommand(java.util.Collection items); + public A removeFromCommand(java.lang.String... items); + public A removeAllFromCommand(java.util.Collection items); + public java.util.List getCommand(); + public java.lang.String getCommand(java.lang.Integer index); + public java.lang.String getFirstCommand(); + public java.lang.String getLastCommand(); - public java.lang.String getMatchingCommand(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCommand(java.util.function.Predicate predicate); + + public java.lang.String getMatchingCommand( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingCommand( + java.util.function.Predicate predicate); + public A withCommand(java.util.List command); + public A withCommand(java.lang.String... command); + public java.lang.Boolean hasCommand(); + public A addNewCommand(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExecActionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExecActionFluentImpl.java index aa5c241446..922a76e7c5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExecActionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExecActionFluentImpl.java @@ -1,89 +1,161 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.ArrayList; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public class V1ExecActionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ExecActionFluent{ - public V1ExecActionFluentImpl() { - } +/** Generated */ +public class V1ExecActionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ExecActionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ExecActionFluent { + public V1ExecActionFluentImpl() {} + public V1ExecActionFluentImpl(io.kubernetes.client.openapi.models.V1ExecAction instance) { this.withCommand(instance.getCommand()); - } + private java.util.List command; - public A addToCommand(java.lang.Integer index,java.lang.String item) { - if (this.command == null) {this.command = new java.util.ArrayList();} + + public A addToCommand(java.lang.Integer index, java.lang.String item) { + if (this.command == null) { + this.command = new java.util.ArrayList(); + } this.command.add(index, item); - return (A)this; + return (A) this; } - public A setToCommand(java.lang.Integer index,java.lang.String item) { - if (this.command == null) {this.command = new java.util.ArrayList();} - this.command.set(index, item); return (A)this; + + public A setToCommand(java.lang.Integer index, java.lang.String item) { + if (this.command == null) { + this.command = new java.util.ArrayList(); + } + this.command.set(index, item); + return (A) this; } + public A addToCommand(java.lang.String... items) { - if (this.command == null) {this.command = new java.util.ArrayList();} - for (java.lang.String item : items) {this.command.add(item);} return (A)this; + if (this.command == null) { + this.command = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.command.add(item); + } + return (A) this; } + public A addAllToCommand(java.util.Collection items) { - if (this.command == null) {this.command = new java.util.ArrayList();} - for (java.lang.String item : items) {this.command.add(item);} return (A)this; + if (this.command == null) { + this.command = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.command.add(item); + } + return (A) this; } + public A removeFromCommand(java.lang.String... items) { - for (java.lang.String item : items) {if (this.command!= null){ this.command.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.command != null) { + this.command.remove(item); + } + } + return (A) this; } + public A removeAllFromCommand(java.util.Collection items) { - for (java.lang.String item : items) {if (this.command!= null){ this.command.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.command != null) { + this.command.remove(item); + } + } + return (A) this; } + public java.util.List getCommand() { return this.command; } + public java.lang.String getCommand(java.lang.Integer index) { return this.command.get(index); } + public java.lang.String getFirstCommand() { return this.command.get(0); } + public java.lang.String getLastCommand() { return this.command.get(command.size() - 1); } - public java.lang.String getMatchingCommand(java.util.function.Predicate predicate) { - for (java.lang.String item: command) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingCommand( + java.util.function.Predicate predicate) { + for (java.lang.String item : command) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingCommand(java.util.function.Predicate predicate) { - for (java.lang.String item: command) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCommand( + java.util.function.Predicate predicate) { + for (java.lang.String item : command) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withCommand(java.util.List command) { - if (command != null) {this.command = new java.util.ArrayList(); for (java.lang.String item : command){this.addToCommand(item);}} else { this.command = null;} return (A) this; + if (command != null) { + this.command = new java.util.ArrayList(); + for (java.lang.String item : command) { + this.addToCommand(item); + } + } else { + this.command = null; + } + return (A) this; } + public A withCommand(java.lang.String... command) { - if (this.command != null) {this.command.clear();} - if (command != null) {for (java.lang.String item :command){ this.addToCommand(item);}} return (A) this; + if (this.command != null) { + this.command.clear(); + } + if (command != null) { + for (java.lang.String item : command) { + this.addToCommand(item); + } + } + return (A) this; } + public java.lang.Boolean hasCommand() { return command != null && !command.isEmpty(); } + public A addNewCommand(java.lang.String original) { - return (A)addToCommand(new String(original)); + return (A) addToCommand(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ExecActionFluentImpl that = (V1ExecActionFluentImpl) o; - if (command != null ? !command.equals(that.command) :that.command != null) return false; + if (command != null ? !command.equals(that.command) : that.command != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(command, super.hashCode()); + return java.util.Objects.hash(command, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExternalDocumentationBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExternalDocumentationBuilder.java index de0e22a759..80feb4e6f3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExternalDocumentationBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExternalDocumentationBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ExternalDocumentationBuilder extends io.kubernetes.client.openapi.models.V1ExternalDocumentationFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ExternalDocumentationBuilder + extends io.kubernetes.client.openapi.models.V1ExternalDocumentationFluentImpl< + io.kubernetes.client.openapi.models.V1ExternalDocumentationBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ExternalDocumentation, + io.kubernetes.client.openapi.models.V1ExternalDocumentationBuilder> { public V1ExternalDocumentationBuilder() { this(false); } + public V1ExternalDocumentationBuilder(java.lang.Boolean validationEnabled) { this(new V1ExternalDocumentation(), validationEnabled); } - public V1ExternalDocumentationBuilder(io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent fluent) { + + public V1ExternalDocumentationBuilder( + io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent fluent) { this(fluent, false); } - public V1ExternalDocumentationBuilder(io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ExternalDocumentationBuilder( + io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ExternalDocumentation(), validationEnabled); } - public V1ExternalDocumentationBuilder(io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent fluent,io.kubernetes.client.openapi.models.V1ExternalDocumentation instance) { + + public V1ExternalDocumentationBuilder( + io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent fluent, + io.kubernetes.client.openapi.models.V1ExternalDocumentation instance) { this(fluent, instance, false); } - public V1ExternalDocumentationBuilder(io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent fluent,io.kubernetes.client.openapi.models.V1ExternalDocumentation instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ExternalDocumentationBuilder( + io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent fluent, + io.kubernetes.client.openapi.models.V1ExternalDocumentation instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDescription(instance.getDescription()); fluent.withUrl(instance.getUrl()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ExternalDocumentationBuilder(io.kubernetes.client.openapi.models.V1ExternalDocumentation instance) { - this(instance,false); + + public V1ExternalDocumentationBuilder( + io.kubernetes.client.openapi.models.V1ExternalDocumentation instance) { + this(instance, false); } - public V1ExternalDocumentationBuilder(io.kubernetes.client.openapi.models.V1ExternalDocumentation instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ExternalDocumentationBuilder( + io.kubernetes.client.openapi.models.V1ExternalDocumentation instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDescription(instance.getDescription()); this.withUrl(instance.getUrl()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ExternalDocumentation build() { V1ExternalDocumentation buildable = new V1ExternalDocumentation(); buildable.setDescription(fluent.getDescription()); buildable.setUrl(fluent.getUrl()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ExternalDocumentationBuilder that = (V1ExternalDocumentationBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExternalDocumentationFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExternalDocumentationFluent.java index 239a77bcfd..09b54383f9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExternalDocumentationFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExternalDocumentationFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ExternalDocumentationFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ExternalDocumentationFluent< + A extends io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getDescription(); + public A withDescription(java.lang.String description); + public java.lang.Boolean hasDescription(); - - /** - * Method is deprecated. use withDescription instead. - */ + + /** Method is deprecated. use withDescription instead. */ @java.lang.Deprecated public A withNewDescription(java.lang.String original); + public java.lang.String getUrl(); + public A withUrl(java.lang.String url); + public java.lang.Boolean hasUrl(); - - /** - * Method is deprecated. use withUrl instead. - */ + + /** Method is deprecated. use withUrl instead. */ @java.lang.Deprecated public A withNewUrl(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExternalDocumentationFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExternalDocumentationFluentImpl.java index 82ad038acc..e3b08f6185 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExternalDocumentationFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ExternalDocumentationFluentImpl.java @@ -1,69 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ExternalDocumentationFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent { + public V1ExternalDocumentationFluentImpl() {} - /** - * Generated - */ -public class V1ExternalDocumentationFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent{ - public V1ExternalDocumentationFluentImpl() { - } - public V1ExternalDocumentationFluentImpl(io.kubernetes.client.openapi.models.V1ExternalDocumentation instance) { + public V1ExternalDocumentationFluentImpl( + io.kubernetes.client.openapi.models.V1ExternalDocumentation instance) { this.withDescription(instance.getDescription()); this.withUrl(instance.getUrl()); - } + private java.lang.String description; private java.lang.String url; + public java.lang.String getDescription() { return this.description; } + public A withDescription(java.lang.String description) { - this.description=description; return (A) this; + this.description = description; + return (A) this; } + public java.lang.Boolean hasDescription() { return this.description != null; } - - /** - * Method is deprecated. use withDescription instead. - */ + + /** Method is deprecated. use withDescription instead. */ @java.lang.Deprecated public A withNewDescription(java.lang.String original) { - return (A)withDescription(new String(original)); + return (A) withDescription(new String(original)); } + public java.lang.String getUrl() { return this.url; } + public A withUrl(java.lang.String url) { - this.url=url; return (A) this; + this.url = url; + return (A) this; } + public java.lang.Boolean hasUrl() { return this.url != null; } - - /** - * Method is deprecated. use withUrl instead. - */ + + /** Method is deprecated. use withUrl instead. */ @java.lang.Deprecated public A withNewUrl(java.lang.String original) { - return (A)withUrl(new String(original)); + return (A) withUrl(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ExternalDocumentationFluentImpl that = (V1ExternalDocumentationFluentImpl) o; - if (description != null ? !description.equals(that.description) :that.description != null) return false; - if (url != null ? !url.equals(that.url) :that.url != null) return false; + if (description != null ? !description.equals(that.description) : that.description != null) + return false; + if (url != null ? !url.equals(that.url) : that.url != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(description, url, super.hashCode()); + return java.util.Objects.hash(description, url, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FCVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FCVolumeSourceBuilder.java index 5deb300be6..e0792fce9b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FCVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FCVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1FCVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1FCVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1FCVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1FCVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1FCVolumeSource, + io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder> { public V1FCVolumeSourceBuilder() { this(false); } + public V1FCVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1FCVolumeSource(), validationEnabled); } - public V1FCVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent fluent) { + + public V1FCVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent fluent) { this(fluent, false); } - public V1FCVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1FCVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1FCVolumeSource(), validationEnabled); } - public V1FCVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1FCVolumeSource instance) { + + public V1FCVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1FCVolumeSource instance) { this(fluent, instance, false); } - public V1FCVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1FCVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1FCVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1FCVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withLun(instance.getLun()); @@ -31,13 +58,17 @@ public V1FCVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FCVolumeSou fluent.withWwids(instance.getWwids()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1FCVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FCVolumeSource instance) { - this(instance,false); + this(instance, false); } - public V1FCVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FCVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1FCVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FCVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withLun(instance.getLun()); @@ -48,10 +79,12 @@ public V1FCVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FCVolumeSou this.withWwids(instance.getWwids()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1FCVolumeSource build() { V1FCVolumeSource buildable = new V1FCVolumeSource(); buildable.setFsType(fluent.getFsType()); @@ -61,18 +94,23 @@ public io.kubernetes.client.openapi.models.V1FCVolumeSource build() { buildable.setWwids(fluent.getWwids()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1FCVolumeSourceBuilder that = (V1FCVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FCVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FCVolumeSourceFluent.java index fd1d52b5a6..d597d35d59 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FCVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FCVolumeSourceFluent.java @@ -1,66 +1,107 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1FCVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1FCVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.Integer getLun(); + public A withLun(java.lang.Integer lun); + public java.lang.Boolean hasLun(); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - public A addToTargetWWNs(java.lang.Integer index,java.lang.String item); - public A setToTargetWWNs(java.lang.Integer index,java.lang.String item); + + public A addToTargetWWNs(java.lang.Integer index, java.lang.String item); + + public A setToTargetWWNs(java.lang.Integer index, java.lang.String item); + public A addToTargetWWNs(java.lang.String... items); + public A addAllToTargetWWNs(java.util.Collection items); + public A removeFromTargetWWNs(java.lang.String... items); + public A removeAllFromTargetWWNs(java.util.Collection items); + public java.util.List getTargetWWNs(); + public java.lang.String getTargetWWN(java.lang.Integer index); + public java.lang.String getFirstTargetWWN(); + public java.lang.String getLastTargetWWN(); - public java.lang.String getMatchingTargetWWN(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingTargetWWN(java.util.function.Predicate predicate); + + public java.lang.String getMatchingTargetWWN( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingTargetWWN( + java.util.function.Predicate predicate); + public A withTargetWWNs(java.util.List targetWWNs); + public A withTargetWWNs(java.lang.String... targetWWNs); + public java.lang.Boolean hasTargetWWNs(); + public A addNewTargetWWN(java.lang.String original); - public A addToWwids(java.lang.Integer index,java.lang.String item); - public A setToWwids(java.lang.Integer index,java.lang.String item); + + public A addToWwids(java.lang.Integer index, java.lang.String item); + + public A setToWwids(java.lang.Integer index, java.lang.String item); + public A addToWwids(java.lang.String... items); + public A addAllToWwids(java.util.Collection items); + public A removeFromWwids(java.lang.String... items); + public A removeAllFromWwids(java.util.Collection items); + public java.util.List getWwids(); + public java.lang.String getWwid(java.lang.Integer index); + public java.lang.String getFirstWwid(); + public java.lang.String getLastWwid(); + public java.lang.String getMatchingWwid(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingWwid(java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingWwid( + java.util.function.Predicate predicate); + public A withWwids(java.util.List wwids); + public A withWwids(java.lang.String... wwids); + public java.lang.Boolean hasWwids(); + public A addNewWwid(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FCVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FCVolumeSourceFluentImpl.java index 7c3374c338..cbe74831c1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FCVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FCVolumeSourceFluentImpl.java @@ -1,22 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1FCVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent{ - public V1FCVolumeSourceFluentImpl() { - } +/** Generated */ +public class V1FCVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent { + public V1FCVolumeSourceFluentImpl() {} + public V1FCVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1FCVolumeSource instance) { this.withFsType(instance.getFsType()); @@ -27,169 +29,317 @@ public V1FCVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1FCVolume this.withTargetWWNs(instance.getTargetWWNs()); this.withWwids(instance.getWwids()); - } + private java.lang.String fsType; private java.lang.Integer lun; private java.lang.Boolean readOnly; private java.util.List targetWWNs; private java.util.List wwids; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.Integer getLun() { return this.lun; } + public A withLun(java.lang.Integer lun) { - this.lun=lun; return (A) this; + this.lun = lun; + return (A) this; } + public java.lang.Boolean hasLun() { return this.lun != null; } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - public A addToTargetWWNs(java.lang.Integer index,java.lang.String item) { - if (this.targetWWNs == null) {this.targetWWNs = new java.util.ArrayList();} + + public A addToTargetWWNs(java.lang.Integer index, java.lang.String item) { + if (this.targetWWNs == null) { + this.targetWWNs = new java.util.ArrayList(); + } this.targetWWNs.add(index, item); - return (A)this; + return (A) this; } - public A setToTargetWWNs(java.lang.Integer index,java.lang.String item) { - if (this.targetWWNs == null) {this.targetWWNs = new java.util.ArrayList();} - this.targetWWNs.set(index, item); return (A)this; + + public A setToTargetWWNs(java.lang.Integer index, java.lang.String item) { + if (this.targetWWNs == null) { + this.targetWWNs = new java.util.ArrayList(); + } + this.targetWWNs.set(index, item); + return (A) this; } + public A addToTargetWWNs(java.lang.String... items) { - if (this.targetWWNs == null) {this.targetWWNs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.targetWWNs.add(item);} return (A)this; + if (this.targetWWNs == null) { + this.targetWWNs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.targetWWNs.add(item); + } + return (A) this; } + public A addAllToTargetWWNs(java.util.Collection items) { - if (this.targetWWNs == null) {this.targetWWNs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.targetWWNs.add(item);} return (A)this; + if (this.targetWWNs == null) { + this.targetWWNs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.targetWWNs.add(item); + } + return (A) this; } + public A removeFromTargetWWNs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.targetWWNs!= null){ this.targetWWNs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.targetWWNs != null) { + this.targetWWNs.remove(item); + } + } + return (A) this; } + public A removeAllFromTargetWWNs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.targetWWNs!= null){ this.targetWWNs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.targetWWNs != null) { + this.targetWWNs.remove(item); + } + } + return (A) this; } + public java.util.List getTargetWWNs() { return this.targetWWNs; } + public java.lang.String getTargetWWN(java.lang.Integer index) { return this.targetWWNs.get(index); } + public java.lang.String getFirstTargetWWN() { return this.targetWWNs.get(0); } + public java.lang.String getLastTargetWWN() { return this.targetWWNs.get(targetWWNs.size() - 1); } - public java.lang.String getMatchingTargetWWN(java.util.function.Predicate predicate) { - for (java.lang.String item: targetWWNs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingTargetWWN( + java.util.function.Predicate predicate) { + for (java.lang.String item : targetWWNs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingTargetWWN(java.util.function.Predicate predicate) { - for (java.lang.String item: targetWWNs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingTargetWWN( + java.util.function.Predicate predicate) { + for (java.lang.String item : targetWWNs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withTargetWWNs(java.util.List targetWWNs) { - if (targetWWNs != null) {this.targetWWNs = new java.util.ArrayList(); for (java.lang.String item : targetWWNs){this.addToTargetWWNs(item);}} else { this.targetWWNs = null;} return (A) this; + if (targetWWNs != null) { + this.targetWWNs = new java.util.ArrayList(); + for (java.lang.String item : targetWWNs) { + this.addToTargetWWNs(item); + } + } else { + this.targetWWNs = null; + } + return (A) this; } + public A withTargetWWNs(java.lang.String... targetWWNs) { - if (this.targetWWNs != null) {this.targetWWNs.clear();} - if (targetWWNs != null) {for (java.lang.String item :targetWWNs){ this.addToTargetWWNs(item);}} return (A) this; + if (this.targetWWNs != null) { + this.targetWWNs.clear(); + } + if (targetWWNs != null) { + for (java.lang.String item : targetWWNs) { + this.addToTargetWWNs(item); + } + } + return (A) this; } + public java.lang.Boolean hasTargetWWNs() { return targetWWNs != null && !targetWWNs.isEmpty(); } + public A addNewTargetWWN(java.lang.String original) { - return (A)addToTargetWWNs(new String(original)); + return (A) addToTargetWWNs(new String(original)); } - public A addToWwids(java.lang.Integer index,java.lang.String item) { - if (this.wwids == null) {this.wwids = new java.util.ArrayList();} + + public A addToWwids(java.lang.Integer index, java.lang.String item) { + if (this.wwids == null) { + this.wwids = new java.util.ArrayList(); + } this.wwids.add(index, item); - return (A)this; + return (A) this; } - public A setToWwids(java.lang.Integer index,java.lang.String item) { - if (this.wwids == null) {this.wwids = new java.util.ArrayList();} - this.wwids.set(index, item); return (A)this; + + public A setToWwids(java.lang.Integer index, java.lang.String item) { + if (this.wwids == null) { + this.wwids = new java.util.ArrayList(); + } + this.wwids.set(index, item); + return (A) this; } + public A addToWwids(java.lang.String... items) { - if (this.wwids == null) {this.wwids = new java.util.ArrayList();} - for (java.lang.String item : items) {this.wwids.add(item);} return (A)this; + if (this.wwids == null) { + this.wwids = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.wwids.add(item); + } + return (A) this; } + public A addAllToWwids(java.util.Collection items) { - if (this.wwids == null) {this.wwids = new java.util.ArrayList();} - for (java.lang.String item : items) {this.wwids.add(item);} return (A)this; + if (this.wwids == null) { + this.wwids = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.wwids.add(item); + } + return (A) this; } + public A removeFromWwids(java.lang.String... items) { - for (java.lang.String item : items) {if (this.wwids!= null){ this.wwids.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.wwids != null) { + this.wwids.remove(item); + } + } + return (A) this; } + public A removeAllFromWwids(java.util.Collection items) { - for (java.lang.String item : items) {if (this.wwids!= null){ this.wwids.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.wwids != null) { + this.wwids.remove(item); + } + } + return (A) this; } + public java.util.List getWwids() { return this.wwids; } + public java.lang.String getWwid(java.lang.Integer index) { return this.wwids.get(index); } + public java.lang.String getFirstWwid() { return this.wwids.get(0); } + public java.lang.String getLastWwid() { return this.wwids.get(wwids.size() - 1); } - public java.lang.String getMatchingWwid(java.util.function.Predicate predicate) { - for (java.lang.String item: wwids) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingWwid( + java.util.function.Predicate predicate) { + for (java.lang.String item : wwids) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingWwid(java.util.function.Predicate predicate) { - for (java.lang.String item: wwids) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingWwid( + java.util.function.Predicate predicate) { + for (java.lang.String item : wwids) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withWwids(java.util.List wwids) { - if (wwids != null) {this.wwids = new java.util.ArrayList(); for (java.lang.String item : wwids){this.addToWwids(item);}} else { this.wwids = null;} return (A) this; + if (wwids != null) { + this.wwids = new java.util.ArrayList(); + for (java.lang.String item : wwids) { + this.addToWwids(item); + } + } else { + this.wwids = null; + } + return (A) this; } + public A withWwids(java.lang.String... wwids) { - if (this.wwids != null) {this.wwids.clear();} - if (wwids != null) {for (java.lang.String item :wwids){ this.addToWwids(item);}} return (A) this; + if (this.wwids != null) { + this.wwids.clear(); + } + if (wwids != null) { + for (java.lang.String item : wwids) { + this.addToWwids(item); + } + } + return (A) this; } + public java.lang.Boolean hasWwids() { return wwids != null && !wwids.isEmpty(); } + public A addNewWwid(java.lang.String original) { - return (A)addToWwids(new String(original)); + return (A) addToWwids(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1FCVolumeSourceFluentImpl that = (V1FCVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (lun != null ? !lun.equals(that.lun) :that.lun != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (targetWWNs != null ? !targetWWNs.equals(that.targetWWNs) :that.targetWWNs != null) return false; - if (wwids != null ? !wwids.equals(that.wwids) :that.wwids != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (lun != null ? !lun.equals(that.lun) : that.lun != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (targetWWNs != null ? !targetWWNs.equals(that.targetWWNs) : that.targetWWNs != null) + return false; + if (wwids != null ? !wwids.equals(that.wwids) : that.wwids != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, lun, readOnly, targetWWNs, wwids, super.hashCode()); + return java.util.Objects.hash(fsType, lun, readOnly, targetWWNs, wwids, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexPersistentVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexPersistentVolumeSourceBuilder.java index 434dbc6ae1..7b38ed10ca 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexPersistentVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexPersistentVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1FlexPersistentVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1FlexPersistentVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource, + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceBuilder> { public V1FlexPersistentVolumeSourceBuilder() { this(false); } + public V1FlexPersistentVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1FlexPersistentVolumeSource(), validationEnabled); } - public V1FlexPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent fluent) { + + public V1FlexPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent fluent) { this(fluent, false); } - public V1FlexPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1FlexPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1FlexPersistentVolumeSource(), validationEnabled); } - public V1FlexPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource instance) { + + public V1FlexPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource instance) { this(fluent, instance, false); } - public V1FlexPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1FlexPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDriver(instance.getDriver()); fluent.withFsType(instance.getFsType()); @@ -31,13 +58,18 @@ public V1FlexPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V fluent.withSecretRef(instance.getSecretRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1FlexPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource instance) { - this(instance,false); + + public V1FlexPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource instance) { + this(instance, false); } - public V1FlexPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1FlexPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDriver(instance.getDriver()); this.withFsType(instance.getFsType()); @@ -48,10 +80,12 @@ public V1FlexPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V this.withSecretRef(instance.getSecretRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource build() { V1FlexPersistentVolumeSource buildable = new V1FlexPersistentVolumeSource(); buildable.setDriver(fluent.getDriver()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource build() buildable.setSecretRef(fluent.getSecretRef()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1FlexPersistentVolumeSourceBuilder that = (V1FlexPersistentVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexPersistentVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexPersistentVolumeSourceFluent.java index 3099a83540..a4fcb8b711 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexPersistentVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexPersistentVolumeSourceFluent.java @@ -1,65 +1,98 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1FlexPersistentVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1FlexPersistentVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getDriver(); + public A withDriver(java.lang.String driver); + public java.lang.Boolean hasDriver(); - - /** - * Method is deprecated. use withDriver instead. - */ + + /** Method is deprecated. use withDriver instead. */ @java.lang.Deprecated public A withNewDriver(java.lang.String original); + public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); - public A addToOptions(java.lang.String key,java.lang.String value); - public A addToOptions(java.util.Map map); + + public A addToOptions(java.lang.String key, java.lang.String value); + + public A addToOptions(java.util.Map map); + public A removeFromOptions(java.lang.String key); - public A removeFromOptions(java.util.Map map); - public java.util.Map getOptions(); - public A withOptions(java.util.Map options); + + public A removeFromOptions(java.util.Map map); + + public java.util.Map getOptions(); + + public A withOptions(java.util.Map options); + public java.lang.Boolean hasOptions(); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1SecretReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); - public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretReferenceFluent>{ + + public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretReferenceFluent< + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent + .SecretRefNested< + N>> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexPersistentVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexPersistentVolumeSourceFluentImpl.java index a90d78d5e2..6002b1df62 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexPersistentVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexPersistentVolumeSourceFluentImpl.java @@ -1,21 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public class V1FlexPersistentVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent{ - public V1FlexPersistentVolumeSourceFluentImpl() { - } - public V1FlexPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource instance) { +/** Generated */ +public class V1FlexPersistentVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent { + public V1FlexPersistentVolumeSourceFluentImpl() {} + + public V1FlexPersistentVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource instance) { this.withDriver(instance.getDriver()); this.withFsType(instance.getFsType()); @@ -25,144 +30,223 @@ public V1FlexPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.model this.withReadOnly(instance.getReadOnly()); this.withSecretRef(instance.getSecretRef()); - } + private java.lang.String driver; private java.lang.String fsType; - private java.util.Map options; + private java.util.Map options; private java.lang.Boolean readOnly; private io.kubernetes.client.openapi.models.V1SecretReferenceBuilder secretRef; + public java.lang.String getDriver() { return this.driver; } + public A withDriver(java.lang.String driver) { - this.driver=driver; return (A) this; + this.driver = driver; + return (A) this; } + public java.lang.Boolean hasDriver() { return this.driver != null; } - - /** - * Method is deprecated. use withDriver instead. - */ + + /** Method is deprecated. use withDriver instead. */ @java.lang.Deprecated public A withNewDriver(java.lang.String original) { - return (A)withDriver(new String(original)); + return (A) withDriver(new String(original)); } + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } - public A addToOptions(java.lang.String key,java.lang.String value) { - if(this.options == null && key != null && value != null) { this.options = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.options.put(key, value);} return (A)this; + + public A addToOptions(java.lang.String key, java.lang.String value) { + if (this.options == null && key != null && value != null) { + this.options = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.options.put(key, value); + } + return (A) this; } - public A addToOptions(java.util.Map map) { - if(this.options == null && map != null) { this.options = new java.util.LinkedHashMap(); } - if(map != null) { this.options.putAll(map);} return (A)this; + + public A addToOptions(java.util.Map map) { + if (this.options == null && map != null) { + this.options = new java.util.LinkedHashMap(); + } + if (map != null) { + this.options.putAll(map); + } + return (A) this; } + public A removeFromOptions(java.lang.String key) { - if(this.options == null) { return (A) this; } - if(key != null && this.options != null) {this.options.remove(key);} return (A)this; + if (this.options == null) { + return (A) this; + } + if (key != null && this.options != null) { + this.options.remove(key); + } + return (A) this; } - public A removeFromOptions(java.util.Map map) { - if(this.options == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.options != null){this.options.remove(key);}}} return (A)this; + + public A removeFromOptions(java.util.Map map) { + if (this.options == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.options != null) { + this.options.remove(key); + } + } + } + return (A) this; } - public java.util.Map getOptions() { + + public java.util.Map getOptions() { return this.options; } - public A withOptions(java.util.Map options) { - if (options == null) { this.options = null;} else {this.options = new java.util.LinkedHashMap(options);} return (A) this; + + public A withOptions(java.util.Map options) { + if (options == null) { + this.options = null; + } else { + this.options = new java.util.LinkedHashMap(options); + } + return (A) this; } + public java.lang.Boolean hasOptions() { return this.options != null; } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return new io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return new io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1FlexPersistentVolumeSourceFluentImpl that = (V1FlexPersistentVolumeSourceFluentImpl) o; - if (driver != null ? !driver.equals(that.driver) :that.driver != null) return false; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (options != null ? !options.equals(that.options) :that.options != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; + if (driver != null ? !driver.equals(that.driver) : that.driver != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (options != null ? !options.equals(that.options) : that.options != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(driver, fsType, options, readOnly, secretRef, super.hashCode()); + return java.util.Objects.hash(driver, fsType, options, readOnly, secretRef, super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent.SecretRefNested> + implements io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent + .SecretRefNested< + N>, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1SecretReference item) { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretReferenceBuilder builder; + public N and() { return (N) V1FlexPersistentVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexVolumeSourceBuilder.java index 20d0a99e03..d480c63d7c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1FlexVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1FlexVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1FlexVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1FlexVolumeSource, + io.kubernetes.client.openapi.models.V1FlexVolumeSourceBuilder> { public V1FlexVolumeSourceBuilder() { this(false); } + public V1FlexVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1FlexVolumeSource(), validationEnabled); } - public V1FlexVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent fluent) { + + public V1FlexVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent fluent) { this(fluent, false); } - public V1FlexVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1FlexVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1FlexVolumeSource(), validationEnabled); } - public V1FlexVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1FlexVolumeSource instance) { + + public V1FlexVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1FlexVolumeSource instance) { this(fluent, instance, false); } - public V1FlexVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1FlexVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1FlexVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1FlexVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDriver(instance.getDriver()); fluent.withFsType(instance.getFsType()); @@ -31,13 +58,18 @@ public V1FlexVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexVolum fluent.withSecretRef(instance.getSecretRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1FlexVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexVolumeSource instance) { - this(instance,false); + + public V1FlexVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlexVolumeSource instance) { + this(instance, false); } - public V1FlexVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1FlexVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlexVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDriver(instance.getDriver()); this.withFsType(instance.getFsType()); @@ -48,10 +80,12 @@ public V1FlexVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlexVolum this.withSecretRef(instance.getSecretRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1FlexVolumeSource build() { V1FlexVolumeSource buildable = new V1FlexVolumeSource(); buildable.setDriver(fluent.getDriver()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1FlexVolumeSource build() { buildable.setSecretRef(fluent.getSecretRef()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1FlexVolumeSourceBuilder that = (V1FlexVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexVolumeSourceFluent.java index 4778e73ab7..dfb9c6e596 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexVolumeSourceFluent.java @@ -1,65 +1,96 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1FlexVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1FlexVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getDriver(); + public A withDriver(java.lang.String driver); + public java.lang.Boolean hasDriver(); - - /** - * Method is deprecated. use withDriver instead. - */ + + /** Method is deprecated. use withDriver instead. */ @java.lang.Deprecated public A withNewDriver(java.lang.String original); + public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); - public A addToOptions(java.lang.String key,java.lang.String value); - public A addToOptions(java.util.Map map); + + public A addToOptions(java.lang.String key, java.lang.String value); + + public A addToOptions(java.util.Map map); + public A removeFromOptions(java.lang.String key); - public A removeFromOptions(java.util.Map map); - public java.util.Map getOptions(); - public A withOptions(java.util.Map options); + + public A removeFromOptions(java.util.Map map); + + public java.util.Map getOptions(); + + public A withOptions(java.util.Map options); + public java.lang.Boolean hasOptions(); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent>{ + + public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexVolumeSourceFluentImpl.java index 5193d3c46f..5c48d99545 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlexVolumeSourceFluentImpl.java @@ -1,21 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public class V1FlexVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent{ - public V1FlexVolumeSourceFluentImpl() { - } - public V1FlexVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1FlexVolumeSource instance) { +/** Generated */ +public class V1FlexVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent { + public V1FlexVolumeSourceFluentImpl() {} + + public V1FlexVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1FlexVolumeSource instance) { this.withDriver(instance.getDriver()); this.withFsType(instance.getFsType()); @@ -25,144 +30,223 @@ public V1FlexVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1FlexVo this.withReadOnly(instance.getReadOnly()); this.withSecretRef(instance.getSecretRef()); - } + private java.lang.String driver; private java.lang.String fsType; - private java.util.Map options; + private java.util.Map options; private java.lang.Boolean readOnly; private io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder secretRef; + public java.lang.String getDriver() { return this.driver; } + public A withDriver(java.lang.String driver) { - this.driver=driver; return (A) this; + this.driver = driver; + return (A) this; } + public java.lang.Boolean hasDriver() { return this.driver != null; } - - /** - * Method is deprecated. use withDriver instead. - */ + + /** Method is deprecated. use withDriver instead. */ @java.lang.Deprecated public A withNewDriver(java.lang.String original) { - return (A)withDriver(new String(original)); + return (A) withDriver(new String(original)); } + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } - public A addToOptions(java.lang.String key,java.lang.String value) { - if(this.options == null && key != null && value != null) { this.options = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.options.put(key, value);} return (A)this; + + public A addToOptions(java.lang.String key, java.lang.String value) { + if (this.options == null && key != null && value != null) { + this.options = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.options.put(key, value); + } + return (A) this; } - public A addToOptions(java.util.Map map) { - if(this.options == null && map != null) { this.options = new java.util.LinkedHashMap(); } - if(map != null) { this.options.putAll(map);} return (A)this; + + public A addToOptions(java.util.Map map) { + if (this.options == null && map != null) { + this.options = new java.util.LinkedHashMap(); + } + if (map != null) { + this.options.putAll(map); + } + return (A) this; } + public A removeFromOptions(java.lang.String key) { - if(this.options == null) { return (A) this; } - if(key != null && this.options != null) {this.options.remove(key);} return (A)this; + if (this.options == null) { + return (A) this; + } + if (key != null && this.options != null) { + this.options.remove(key); + } + return (A) this; } - public A removeFromOptions(java.util.Map map) { - if(this.options == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.options != null){this.options.remove(key);}}} return (A)this; + + public A removeFromOptions(java.util.Map map) { + if (this.options == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.options != null) { + this.options.remove(key); + } + } + } + return (A) this; } - public java.util.Map getOptions() { + + public java.util.Map getOptions() { return this.options; } - public A withOptions(java.util.Map options) { - if (options == null) { this.options = null;} else {this.options = new java.util.LinkedHashMap(options);} return (A) this; + + public A withOptions(java.util.Map options) { + if (options == null) { + this.options = null; + } else { + this.options = new java.util.LinkedHashMap(options); + } + return (A) this; } + public java.lang.Boolean hasOptions() { return this.options != null; } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluentImpl.SecretRefNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1FlexVolumeSourceFluentImpl that = (V1FlexVolumeSourceFluentImpl) o; - if (driver != null ? !driver.equals(that.driver) :that.driver != null) return false; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (options != null ? !options.equals(that.options) :that.options != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; + if (driver != null ? !driver.equals(that.driver) : that.driver != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (options != null ? !options.equals(that.options) : that.options != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(driver, fsType, options, readOnly, secretRef, super.hashCode()); + return java.util.Objects.hash(driver, fsType, options, readOnly, secretRef, super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested> + implements io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent.SecretRefNested, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder; + public N and() { return (N) V1FlexVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlockerVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlockerVolumeSourceBuilder.java index 07c14e12be..87e5829c31 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlockerVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlockerVolumeSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1FlockerVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1FlockerVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1FlockerVolumeSource, + io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder> { public V1FlockerVolumeSourceBuilder() { this(false); } + public V1FlockerVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1FlockerVolumeSource(), validationEnabled); } - public V1FlockerVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent fluent) { + + public V1FlockerVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent fluent) { this(fluent, false); } - public V1FlockerVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1FlockerVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1FlockerVolumeSource(), validationEnabled); } - public V1FlockerVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1FlockerVolumeSource instance) { + + public V1FlockerVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1FlockerVolumeSource instance) { this(fluent, instance, false); } - public V1FlockerVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1FlockerVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1FlockerVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1FlockerVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDatasetName(instance.getDatasetName()); fluent.withDatasetUUID(instance.getDatasetUUID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1FlockerVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlockerVolumeSource instance) { - this(instance,false); + + public V1FlockerVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlockerVolumeSource instance) { + this(instance, false); } - public V1FlockerVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1FlockerVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1FlockerVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1FlockerVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDatasetName(instance.getDatasetName()); this.withDatasetUUID(instance.getDatasetUUID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1FlockerVolumeSource build() { V1FlockerVolumeSource buildable = new V1FlockerVolumeSource(); buildable.setDatasetName(fluent.getDatasetName()); buildable.setDatasetUUID(fluent.getDatasetUUID()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1FlockerVolumeSourceBuilder that = (V1FlockerVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlockerVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlockerVolumeSourceFluent.java index f12863e075..bf48d74e40 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlockerVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlockerVolumeSourceFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1FlockerVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1FlockerVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getDatasetName(); + public A withDatasetName(java.lang.String datasetName); + public java.lang.Boolean hasDatasetName(); - - /** - * Method is deprecated. use withDatasetName instead. - */ + + /** Method is deprecated. use withDatasetName instead. */ @java.lang.Deprecated public A withNewDatasetName(java.lang.String original); + public java.lang.String getDatasetUUID(); + public A withDatasetUUID(java.lang.String datasetUUID); + public java.lang.Boolean hasDatasetUUID(); - - /** - * Method is deprecated. use withDatasetUUID instead. - */ + + /** Method is deprecated. use withDatasetUUID instead. */ @java.lang.Deprecated public A withNewDatasetUUID(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlockerVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlockerVolumeSourceFluentImpl.java index 1bd33f90fb..407dd2e676 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlockerVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1FlockerVolumeSourceFluentImpl.java @@ -1,69 +1,84 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1FlockerVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent { + public V1FlockerVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1FlockerVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent{ - public V1FlockerVolumeSourceFluentImpl() { - } - public V1FlockerVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1FlockerVolumeSource instance) { + public V1FlockerVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1FlockerVolumeSource instance) { this.withDatasetName(instance.getDatasetName()); this.withDatasetUUID(instance.getDatasetUUID()); - } + private java.lang.String datasetName; private java.lang.String datasetUUID; + public java.lang.String getDatasetName() { return this.datasetName; } + public A withDatasetName(java.lang.String datasetName) { - this.datasetName=datasetName; return (A) this; + this.datasetName = datasetName; + return (A) this; } + public java.lang.Boolean hasDatasetName() { return this.datasetName != null; } - - /** - * Method is deprecated. use withDatasetName instead. - */ + + /** Method is deprecated. use withDatasetName instead. */ @java.lang.Deprecated public A withNewDatasetName(java.lang.String original) { - return (A)withDatasetName(new String(original)); + return (A) withDatasetName(new String(original)); } + public java.lang.String getDatasetUUID() { return this.datasetUUID; } + public A withDatasetUUID(java.lang.String datasetUUID) { - this.datasetUUID=datasetUUID; return (A) this; + this.datasetUUID = datasetUUID; + return (A) this; } + public java.lang.Boolean hasDatasetUUID() { return this.datasetUUID != null; } - - /** - * Method is deprecated. use withDatasetUUID instead. - */ + + /** Method is deprecated. use withDatasetUUID instead. */ @java.lang.Deprecated public A withNewDatasetUUID(java.lang.String original) { - return (A)withDatasetUUID(new String(original)); + return (A) withDatasetUUID(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1FlockerVolumeSourceFluentImpl that = (V1FlockerVolumeSourceFluentImpl) o; - if (datasetName != null ? !datasetName.equals(that.datasetName) :that.datasetName != null) return false; - if (datasetUUID != null ? !datasetUUID.equals(that.datasetUUID) :that.datasetUUID != null) return false; + if (datasetName != null ? !datasetName.equals(that.datasetName) : that.datasetName != null) + return false; + if (datasetUUID != null ? !datasetUUID.equals(that.datasetUUID) : that.datasetUUID != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(datasetName, datasetUUID, super.hashCode()); + return java.util.Objects.hash(datasetName, datasetUUID, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ForZoneBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ForZoneBuilder.java index 4490390410..4d74bc2b60 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ForZoneBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ForZoneBuilder.java @@ -1,58 +1,94 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ForZoneBuilder extends io.kubernetes.client.openapi.models.V1ForZoneFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ForZoneBuilder + extends io.kubernetes.client.openapi.models.V1ForZoneFluentImpl< + io.kubernetes.client.openapi.models.V1ForZoneBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ForZone, + io.kubernetes.client.openapi.models.V1ForZoneBuilder> { public V1ForZoneBuilder() { this(false); } + public V1ForZoneBuilder(java.lang.Boolean validationEnabled) { this(new V1ForZone(), validationEnabled); } + public V1ForZoneBuilder(io.kubernetes.client.openapi.models.V1ForZoneFluent fluent) { this(fluent, false); } - public V1ForZoneBuilder(io.kubernetes.client.openapi.models.V1ForZoneFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ForZoneBuilder( + io.kubernetes.client.openapi.models.V1ForZoneFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ForZone(), validationEnabled); } - public V1ForZoneBuilder(io.kubernetes.client.openapi.models.V1ForZoneFluent fluent,io.kubernetes.client.openapi.models.V1ForZone instance) { + + public V1ForZoneBuilder( + io.kubernetes.client.openapi.models.V1ForZoneFluent fluent, + io.kubernetes.client.openapi.models.V1ForZone instance) { this(fluent, instance, false); } - public V1ForZoneBuilder(io.kubernetes.client.openapi.models.V1ForZoneFluent fluent,io.kubernetes.client.openapi.models.V1ForZone instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ForZoneBuilder( + io.kubernetes.client.openapi.models.V1ForZoneFluent fluent, + io.kubernetes.client.openapi.models.V1ForZone instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ForZoneBuilder(io.kubernetes.client.openapi.models.V1ForZone instance) { - this(instance,false); + this(instance, false); } - public V1ForZoneBuilder(io.kubernetes.client.openapi.models.V1ForZone instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ForZoneBuilder( + io.kubernetes.client.openapi.models.V1ForZone instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ForZoneFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ForZone build() { V1ForZone buildable = new V1ForZone(); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ForZoneBuilder that = (V1ForZoneBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ForZoneFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ForZoneFluent.java index 3a812dd94d..780be9de50 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ForZoneFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ForZoneFluent.java @@ -1,23 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ForZoneFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ForZoneFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ForZoneFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ForZoneFluentImpl.java index 5e6f790b11..a228e0890d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ForZoneFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ForZoneFluentImpl.java @@ -1,48 +1,57 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1ForZoneFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ForZoneFluent{ - public V1ForZoneFluentImpl() { - } +/** Generated */ +public class V1ForZoneFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ForZoneFluent { + public V1ForZoneFluentImpl() {} + public V1ForZoneFluentImpl(io.kubernetes.client.openapi.models.V1ForZone instance) { this.withName(instance.getName()); - } + private java.lang.String name; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ForZoneFluentImpl that = (V1ForZoneFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, super.hashCode()); + return java.util.Objects.hash(name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GCEPersistentDiskVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GCEPersistentDiskVolumeSourceBuilder.java index dc6a06220c..64efc749dc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GCEPersistentDiskVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GCEPersistentDiskVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1GCEPersistentDiskVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1GCEPersistentDiskVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource, + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder> { public V1GCEPersistentDiskVolumeSourceBuilder() { this(false); } + public V1GCEPersistentDiskVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1GCEPersistentDiskVolumeSource(), validationEnabled); } - public V1GCEPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent fluent) { + + public V1GCEPersistentDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent fluent) { this(fluent, false); } - public V1GCEPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1GCEPersistentDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1GCEPersistentDiskVolumeSource(), validationEnabled); } - public V1GCEPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource instance) { + + public V1GCEPersistentDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource instance) { this(fluent, instance, false); } - public V1GCEPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1GCEPersistentDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withPartition(instance.getPartition()); @@ -29,13 +56,18 @@ public V1GCEPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.model fluent.withReadOnly(instance.getReadOnly()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1GCEPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource instance) { - this(instance,false); + + public V1GCEPersistentDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource instance) { + this(instance, false); } - public V1GCEPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1GCEPersistentDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withPartition(instance.getPartition()); @@ -44,10 +76,12 @@ public V1GCEPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.model this.withReadOnly(instance.getReadOnly()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource build() { V1GCEPersistentDiskVolumeSource buildable = new V1GCEPersistentDiskVolumeSource(); buildable.setFsType(fluent.getFsType()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource build buildable.setReadOnly(fluent.getReadOnly()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1GCEPersistentDiskVolumeSourceBuilder that = (V1GCEPersistentDiskVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GCEPersistentDiskVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GCEPersistentDiskVolumeSourceFluent.java index a34f6780c5..dfb9b063c3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GCEPersistentDiskVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GCEPersistentDiskVolumeSourceFluent.java @@ -1,39 +1,50 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1GCEPersistentDiskVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1GCEPersistentDiskVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.Integer getPartition(); + public A withPartition(java.lang.Integer partition); + public java.lang.Boolean hasPartition(); + public java.lang.String getPdName(); + public A withPdName(java.lang.String pdName); + public java.lang.Boolean hasPdName(); - - /** - * Method is deprecated. use withPdName instead. - */ + + /** Method is deprecated. use withPdName instead. */ @java.lang.Deprecated public A withNewPdName(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GCEPersistentDiskVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GCEPersistentDiskVolumeSourceFluentImpl.java index 4cb1e6274c..c564b66af9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GCEPersistentDiskVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GCEPersistentDiskVolumeSourceFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1GCEPersistentDiskVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent { + public V1GCEPersistentDiskVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1GCEPersistentDiskVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent{ - public V1GCEPersistentDiskVolumeSourceFluentImpl() { - } - public V1GCEPersistentDiskVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource instance) { + public V1GCEPersistentDiskVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource instance) { this.withFsType(instance.getFsType()); this.withPartition(instance.getPartition()); @@ -21,76 +28,90 @@ public V1GCEPersistentDiskVolumeSourceFluentImpl(io.kubernetes.client.openapi.mo this.withPdName(instance.getPdName()); this.withReadOnly(instance.getReadOnly()); - } + private java.lang.String fsType; private java.lang.Integer partition; private java.lang.String pdName; private java.lang.Boolean readOnly; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.Integer getPartition() { return this.partition; } + public A withPartition(java.lang.Integer partition) { - this.partition=partition; return (A) this; + this.partition = partition; + return (A) this; } + public java.lang.Boolean hasPartition() { return this.partition != null; } + public java.lang.String getPdName() { return this.pdName; } + public A withPdName(java.lang.String pdName) { - this.pdName=pdName; return (A) this; + this.pdName = pdName; + return (A) this; } + public java.lang.Boolean hasPdName() { return this.pdName != null; } - - /** - * Method is deprecated. use withPdName instead. - */ + + /** Method is deprecated. use withPdName instead. */ @java.lang.Deprecated public A withNewPdName(java.lang.String original) { - return (A)withPdName(new String(original)); + return (A) withPdName(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1GCEPersistentDiskVolumeSourceFluentImpl that = (V1GCEPersistentDiskVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (partition != null ? !partition.equals(that.partition) :that.partition != null) return false; - if (pdName != null ? !pdName.equals(that.pdName) :that.pdName != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (partition != null ? !partition.equals(that.partition) : that.partition != null) + return false; + if (pdName != null ? !pdName.equals(that.pdName) : that.pdName != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, partition, pdName, readOnly, super.hashCode()); + return java.util.Objects.hash(fsType, partition, pdName, readOnly, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GRPCActionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GRPCActionBuilder.java index 63df600ae0..c2b9fc7f48 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GRPCActionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GRPCActionBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1GRPCActionBuilder extends io.kubernetes.client.openapi.models.V1GRPCActionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1GRPCActionBuilder + extends io.kubernetes.client.openapi.models.V1GRPCActionFluentImpl< + io.kubernetes.client.openapi.models.V1GRPCActionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1GRPCAction, + io.kubernetes.client.openapi.models.V1GRPCActionBuilder> { public V1GRPCActionBuilder() { this(false); } + public V1GRPCActionBuilder(java.lang.Boolean validationEnabled) { this(new V1GRPCAction(), validationEnabled); } + public V1GRPCActionBuilder(io.kubernetes.client.openapi.models.V1GRPCActionFluent fluent) { this(fluent, false); } - public V1GRPCActionBuilder(io.kubernetes.client.openapi.models.V1GRPCActionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1GRPCActionBuilder( + io.kubernetes.client.openapi.models.V1GRPCActionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1GRPCAction(), validationEnabled); } - public V1GRPCActionBuilder(io.kubernetes.client.openapi.models.V1GRPCActionFluent fluent,io.kubernetes.client.openapi.models.V1GRPCAction instance) { + + public V1GRPCActionBuilder( + io.kubernetes.client.openapi.models.V1GRPCActionFluent fluent, + io.kubernetes.client.openapi.models.V1GRPCAction instance) { this(fluent, instance, false); } - public V1GRPCActionBuilder(io.kubernetes.client.openapi.models.V1GRPCActionFluent fluent,io.kubernetes.client.openapi.models.V1GRPCAction instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1GRPCActionBuilder( + io.kubernetes.client.openapi.models.V1GRPCActionFluent fluent, + io.kubernetes.client.openapi.models.V1GRPCAction instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPort(instance.getPort()); fluent.withService(instance.getService()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1GRPCActionBuilder(io.kubernetes.client.openapi.models.V1GRPCAction instance) { - this(instance,false); + this(instance, false); } - public V1GRPCActionBuilder(io.kubernetes.client.openapi.models.V1GRPCAction instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1GRPCActionBuilder( + io.kubernetes.client.openapi.models.V1GRPCAction instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPort(instance.getPort()); this.withService(instance.getService()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1GRPCActionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1GRPCAction build() { V1GRPCAction buildable = new V1GRPCAction(); buildable.setPort(fluent.getPort()); buildable.setService(fluent.getService()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1GRPCActionBuilder that = (V1GRPCActionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GRPCActionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GRPCActionFluent.java index 64a3cc192c..328958d271 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GRPCActionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GRPCActionFluent.java @@ -1,27 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1GRPCActionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1GRPCActionFluent< + A extends io.kubernetes.client.openapi.models.V1GRPCActionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getPort(); + public A withPort(java.lang.Integer port); + public java.lang.Boolean hasPort(); + public java.lang.String getService(); + public A withService(java.lang.String service); + public java.lang.Boolean hasService(); - - /** - * Method is deprecated. use withService instead. - */ + + /** Method is deprecated. use withService instead. */ @java.lang.Deprecated public A withNewService(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GRPCActionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GRPCActionFluentImpl.java index a267df3a5b..5b51ed2522 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GRPCActionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GRPCActionFluentImpl.java @@ -1,62 +1,75 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1GRPCActionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1GRPCActionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1GRPCActionFluent { + public V1GRPCActionFluentImpl() {} - /** - * Generated - */ -public class V1GRPCActionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1GRPCActionFluent{ - public V1GRPCActionFluentImpl() { - } public V1GRPCActionFluentImpl(io.kubernetes.client.openapi.models.V1GRPCAction instance) { this.withPort(instance.getPort()); this.withService(instance.getService()); - } + private java.lang.Integer port; private java.lang.String service; + public java.lang.Integer getPort() { return this.port; } + public A withPort(java.lang.Integer port) { - this.port=port; return (A) this; + this.port = port; + return (A) this; } + public java.lang.Boolean hasPort() { return this.port != null; } + public java.lang.String getService() { return this.service; } + public A withService(java.lang.String service) { - this.service=service; return (A) this; + this.service = service; + return (A) this; } + public java.lang.Boolean hasService() { return this.service != null; } - - /** - * Method is deprecated. use withService instead. - */ + + /** Method is deprecated. use withService instead. */ @java.lang.Deprecated public A withNewService(java.lang.String original) { - return (A)withService(new String(original)); + return (A) withService(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1GRPCActionFluentImpl that = (V1GRPCActionFluentImpl) o; - if (port != null ? !port.equals(that.port) :that.port != null) return false; - if (service != null ? !service.equals(that.service) :that.service != null) return false; + if (port != null ? !port.equals(that.port) : that.port != null) return false; + if (service != null ? !service.equals(that.service) : that.service != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(port, service, super.hashCode()); + return java.util.Objects.hash(port, service, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GitRepoVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GitRepoVolumeSourceBuilder.java index 33b38f42b8..44b4ed175e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GitRepoVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GitRepoVolumeSourceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1GitRepoVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1GitRepoVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1GitRepoVolumeSource, + io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceBuilder> { public V1GitRepoVolumeSourceBuilder() { this(false); } + public V1GitRepoVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1GitRepoVolumeSource(), validationEnabled); } - public V1GitRepoVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent fluent) { + + public V1GitRepoVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent fluent) { this(fluent, false); } - public V1GitRepoVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1GitRepoVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1GitRepoVolumeSource(), validationEnabled); } - public V1GitRepoVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1GitRepoVolumeSource instance) { + + public V1GitRepoVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1GitRepoVolumeSource instance) { this(fluent, instance, false); } - public V1GitRepoVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1GitRepoVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1GitRepoVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1GitRepoVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDirectory(instance.getDirectory()); fluent.withRepository(instance.getRepository()); fluent.withRevision(instance.getRevision()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1GitRepoVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GitRepoVolumeSource instance) { - this(instance,false); + + public V1GitRepoVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GitRepoVolumeSource instance) { + this(instance, false); } - public V1GitRepoVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GitRepoVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1GitRepoVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GitRepoVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDirectory(instance.getDirectory()); this.withRepository(instance.getRepository()); this.withRevision(instance.getRevision()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1GitRepoVolumeSource build() { V1GitRepoVolumeSource buildable = new V1GitRepoVolumeSource(); buildable.setDirectory(fluent.getDirectory()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1GitRepoVolumeSource build() { buildable.setRevision(fluent.getRevision()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1GitRepoVolumeSourceBuilder that = (V1GitRepoVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GitRepoVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GitRepoVolumeSourceFluent.java index d572ef1d4a..8b8fc53873 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GitRepoVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GitRepoVolumeSourceFluent.java @@ -1,41 +1,48 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1GitRepoVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1GitRepoVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getDirectory(); + public A withDirectory(java.lang.String directory); + public java.lang.Boolean hasDirectory(); - - /** - * Method is deprecated. use withDirectory instead. - */ + + /** Method is deprecated. use withDirectory instead. */ @java.lang.Deprecated public A withNewDirectory(java.lang.String original); + public java.lang.String getRepository(); + public A withRepository(java.lang.String repository); + public java.lang.Boolean hasRepository(); - - /** - * Method is deprecated. use withRepository instead. - */ + + /** Method is deprecated. use withRepository instead. */ @java.lang.Deprecated public A withNewRepository(java.lang.String original); + public java.lang.String getRevision(); + public A withRevision(java.lang.String revision); + public java.lang.Boolean hasRevision(); - - /** - * Method is deprecated. use withRevision instead. - */ + + /** Method is deprecated. use withRevision instead. */ @java.lang.Deprecated public A withNewRevision(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GitRepoVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GitRepoVolumeSourceFluentImpl.java index 90021f2e7b..388af89507 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GitRepoVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GitRepoVolumeSourceFluentImpl.java @@ -1,90 +1,107 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1GitRepoVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent{ - public V1GitRepoVolumeSourceFluentImpl() { - } - public V1GitRepoVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1GitRepoVolumeSource instance) { +/** Generated */ +public class V1GitRepoVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent { + public V1GitRepoVolumeSourceFluentImpl() {} + + public V1GitRepoVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1GitRepoVolumeSource instance) { this.withDirectory(instance.getDirectory()); this.withRepository(instance.getRepository()); this.withRevision(instance.getRevision()); - } + private java.lang.String directory; private java.lang.String repository; private java.lang.String revision; + public java.lang.String getDirectory() { return this.directory; } + public A withDirectory(java.lang.String directory) { - this.directory=directory; return (A) this; + this.directory = directory; + return (A) this; } + public java.lang.Boolean hasDirectory() { return this.directory != null; } - - /** - * Method is deprecated. use withDirectory instead. - */ + + /** Method is deprecated. use withDirectory instead. */ @java.lang.Deprecated public A withNewDirectory(java.lang.String original) { - return (A)withDirectory(new String(original)); + return (A) withDirectory(new String(original)); } + public java.lang.String getRepository() { return this.repository; } + public A withRepository(java.lang.String repository) { - this.repository=repository; return (A) this; + this.repository = repository; + return (A) this; } + public java.lang.Boolean hasRepository() { return this.repository != null; } - - /** - * Method is deprecated. use withRepository instead. - */ + + /** Method is deprecated. use withRepository instead. */ @java.lang.Deprecated public A withNewRepository(java.lang.String original) { - return (A)withRepository(new String(original)); + return (A) withRepository(new String(original)); } + public java.lang.String getRevision() { return this.revision; } + public A withRevision(java.lang.String revision) { - this.revision=revision; return (A) this; + this.revision = revision; + return (A) this; } + public java.lang.Boolean hasRevision() { return this.revision != null; } - - /** - * Method is deprecated. use withRevision instead. - */ + + /** Method is deprecated. use withRevision instead. */ @java.lang.Deprecated public A withNewRevision(java.lang.String original) { - return (A)withRevision(new String(original)); + return (A) withRevision(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1GitRepoVolumeSourceFluentImpl that = (V1GitRepoVolumeSourceFluentImpl) o; - if (directory != null ? !directory.equals(that.directory) :that.directory != null) return false; - if (repository != null ? !repository.equals(that.repository) :that.repository != null) return false; - if (revision != null ? !revision.equals(that.revision) :that.revision != null) return false; + if (directory != null ? !directory.equals(that.directory) : that.directory != null) + return false; + if (repository != null ? !repository.equals(that.repository) : that.repository != null) + return false; + if (revision != null ? !revision.equals(that.revision) : that.revision != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(directory, repository, revision, super.hashCode()); + return java.util.Objects.hash(directory, repository, revision, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsPersistentVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsPersistentVolumeSourceBuilder.java index 40ffe9be3f..cd571be5b9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsPersistentVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsPersistentVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1GlusterfsPersistentVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1GlusterfsPersistentVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource, + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceBuilder> { public V1GlusterfsPersistentVolumeSourceBuilder() { this(false); } + public V1GlusterfsPersistentVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1GlusterfsPersistentVolumeSource(), validationEnabled); } - public V1GlusterfsPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent fluent) { + + public V1GlusterfsPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent fluent) { this(fluent, false); } - public V1GlusterfsPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1GlusterfsPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1GlusterfsPersistentVolumeSource(), validationEnabled); } - public V1GlusterfsPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource instance) { + + public V1GlusterfsPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource instance) { this(fluent, instance, false); } - public V1GlusterfsPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1GlusterfsPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withEndpoints(instance.getEndpoints()); fluent.withEndpointsNamespace(instance.getEndpointsNamespace()); @@ -29,13 +56,18 @@ public V1GlusterfsPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.mod fluent.withReadOnly(instance.getReadOnly()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1GlusterfsPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource instance) { - this(instance,false); + + public V1GlusterfsPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource instance) { + this(instance, false); } - public V1GlusterfsPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1GlusterfsPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withEndpoints(instance.getEndpoints()); this.withEndpointsNamespace(instance.getEndpointsNamespace()); @@ -44,10 +76,12 @@ public V1GlusterfsPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.mod this.withReadOnly(instance.getReadOnly()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource build() { V1GlusterfsPersistentVolumeSource buildable = new V1GlusterfsPersistentVolumeSource(); buildable.setEndpoints(fluent.getEndpoints()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource bui buildable.setReadOnly(fluent.getReadOnly()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1GlusterfsPersistentVolumeSourceBuilder that = (V1GlusterfsPersistentVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsPersistentVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsPersistentVolumeSourceFluent.java index 0dc1135e19..5e325af325 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsPersistentVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsPersistentVolumeSourceFluent.java @@ -1,44 +1,54 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1GlusterfsPersistentVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1GlusterfsPersistentVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getEndpoints(); + public A withEndpoints(java.lang.String endpoints); + public java.lang.Boolean hasEndpoints(); - - /** - * Method is deprecated. use withEndpoints instead. - */ + + /** Method is deprecated. use withEndpoints instead. */ @java.lang.Deprecated public A withNewEndpoints(java.lang.String original); + public java.lang.String getEndpointsNamespace(); + public A withEndpointsNamespace(java.lang.String endpointsNamespace); + public java.lang.Boolean hasEndpointsNamespace(); - - /** - * Method is deprecated. use withEndpointsNamespace instead. - */ + + /** Method is deprecated. use withEndpointsNamespace instead. */ @java.lang.Deprecated public A withNewEndpointsNamespace(java.lang.String original); + public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsPersistentVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsPersistentVolumeSourceFluentImpl.java index 47d45a49dd..432ac49ea0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsPersistentVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsPersistentVolumeSourceFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1GlusterfsPersistentVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent { + public V1GlusterfsPersistentVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1GlusterfsPersistentVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent{ - public V1GlusterfsPersistentVolumeSourceFluentImpl() { - } - public V1GlusterfsPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource instance) { + public V1GlusterfsPersistentVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource instance) { this.withEndpoints(instance.getEndpoints()); this.withEndpointsNamespace(instance.getEndpointsNamespace()); @@ -20,84 +28,99 @@ public V1GlusterfsPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi. this.withPath(instance.getPath()); this.withReadOnly(instance.getReadOnly()); - } + private java.lang.String endpoints; private java.lang.String endpointsNamespace; private java.lang.String path; private java.lang.Boolean readOnly; + public java.lang.String getEndpoints() { return this.endpoints; } + public A withEndpoints(java.lang.String endpoints) { - this.endpoints=endpoints; return (A) this; + this.endpoints = endpoints; + return (A) this; } + public java.lang.Boolean hasEndpoints() { return this.endpoints != null; } - - /** - * Method is deprecated. use withEndpoints instead. - */ + + /** Method is deprecated. use withEndpoints instead. */ @java.lang.Deprecated public A withNewEndpoints(java.lang.String original) { - return (A)withEndpoints(new String(original)); + return (A) withEndpoints(new String(original)); } + public java.lang.String getEndpointsNamespace() { return this.endpointsNamespace; } + public A withEndpointsNamespace(java.lang.String endpointsNamespace) { - this.endpointsNamespace=endpointsNamespace; return (A) this; + this.endpointsNamespace = endpointsNamespace; + return (A) this; } + public java.lang.Boolean hasEndpointsNamespace() { return this.endpointsNamespace != null; } - - /** - * Method is deprecated. use withEndpointsNamespace instead. - */ + + /** Method is deprecated. use withEndpointsNamespace instead. */ @java.lang.Deprecated public A withNewEndpointsNamespace(java.lang.String original) { - return (A)withEndpointsNamespace(new String(original)); + return (A) withEndpointsNamespace(new String(original)); } + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1GlusterfsPersistentVolumeSourceFluentImpl that = (V1GlusterfsPersistentVolumeSourceFluentImpl) o; - if (endpoints != null ? !endpoints.equals(that.endpoints) :that.endpoints != null) return false; - if (endpointsNamespace != null ? !endpointsNamespace.equals(that.endpointsNamespace) :that.endpointsNamespace != null) return false; - if (path != null ? !path.equals(that.path) :that.path != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; + V1GlusterfsPersistentVolumeSourceFluentImpl that = + (V1GlusterfsPersistentVolumeSourceFluentImpl) o; + if (endpoints != null ? !endpoints.equals(that.endpoints) : that.endpoints != null) + return false; + if (endpointsNamespace != null + ? !endpointsNamespace.equals(that.endpointsNamespace) + : that.endpointsNamespace != null) return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(endpoints, endpointsNamespace, path, readOnly, super.hashCode()); + return java.util.Objects.hash(endpoints, endpointsNamespace, path, readOnly, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsVolumeSourceBuilder.java index 2ad2f693ac..fe2bae75ec 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsVolumeSourceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1GlusterfsVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1GlusterfsVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource, + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceBuilder> { public V1GlusterfsVolumeSourceBuilder() { this(false); } + public V1GlusterfsVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1GlusterfsVolumeSource(), validationEnabled); } - public V1GlusterfsVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent fluent) { + + public V1GlusterfsVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent fluent) { this(fluent, false); } - public V1GlusterfsVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1GlusterfsVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1GlusterfsVolumeSource(), validationEnabled); } - public V1GlusterfsVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource instance) { + + public V1GlusterfsVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource instance) { this(fluent, instance, false); } - public V1GlusterfsVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1GlusterfsVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withEndpoints(instance.getEndpoints()); fluent.withPath(instance.getPath()); fluent.withReadOnly(instance.getReadOnly()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1GlusterfsVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource instance) { - this(instance,false); + + public V1GlusterfsVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource instance) { + this(instance, false); } - public V1GlusterfsVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1GlusterfsVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withEndpoints(instance.getEndpoints()); this.withPath(instance.getPath()); this.withReadOnly(instance.getReadOnly()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource build() { V1GlusterfsVolumeSource buildable = new V1GlusterfsVolumeSource(); buildable.setEndpoints(fluent.getEndpoints()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource build() { buildable.setReadOnly(fluent.getReadOnly()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1GlusterfsVolumeSourceBuilder that = (V1GlusterfsVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsVolumeSourceFluent.java index dbc59f2de4..1f6d38c2b7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsVolumeSourceFluent.java @@ -1,35 +1,44 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1GlusterfsVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1GlusterfsVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getEndpoints(); + public A withEndpoints(java.lang.String endpoints); + public java.lang.Boolean hasEndpoints(); - - /** - * Method is deprecated. use withEndpoints instead. - */ + + /** Method is deprecated. use withEndpoints instead. */ @java.lang.Deprecated public A withNewEndpoints(java.lang.String original); + public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsVolumeSourceFluentImpl.java index 3b97d74c8e..232c9c7643 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GlusterfsVolumeSourceFluentImpl.java @@ -1,82 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1GlusterfsVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent{ - public V1GlusterfsVolumeSourceFluentImpl() { - } - public V1GlusterfsVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource instance) { +/** Generated */ +public class V1GlusterfsVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent { + public V1GlusterfsVolumeSourceFluentImpl() {} + + public V1GlusterfsVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource instance) { this.withEndpoints(instance.getEndpoints()); this.withPath(instance.getPath()); this.withReadOnly(instance.getReadOnly()); - } + private java.lang.String endpoints; private java.lang.String path; private java.lang.Boolean readOnly; + public java.lang.String getEndpoints() { return this.endpoints; } + public A withEndpoints(java.lang.String endpoints) { - this.endpoints=endpoints; return (A) this; + this.endpoints = endpoints; + return (A) this; } + public java.lang.Boolean hasEndpoints() { return this.endpoints != null; } - - /** - * Method is deprecated. use withEndpoints instead. - */ + + /** Method is deprecated. use withEndpoints instead. */ @java.lang.Deprecated public A withNewEndpoints(java.lang.String original) { - return (A)withEndpoints(new String(original)); + return (A) withEndpoints(new String(original)); } + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1GlusterfsVolumeSourceFluentImpl that = (V1GlusterfsVolumeSourceFluentImpl) o; - if (endpoints != null ? !endpoints.equals(that.endpoints) :that.endpoints != null) return false; - if (path != null ? !path.equals(that.path) :that.path != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; + if (endpoints != null ? !endpoints.equals(that.endpoints) : that.endpoints != null) + return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(endpoints, path, readOnly, super.hashCode()); + return java.util.Objects.hash(endpoints, path, readOnly, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GroupVersionForDiscoveryBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GroupVersionForDiscoveryBuilder.java index 737beb51fc..bb92e3e017 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GroupVersionForDiscoveryBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GroupVersionForDiscoveryBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1GroupVersionForDiscoveryBuilder extends io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1GroupVersionForDiscoveryBuilder + extends io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluentImpl< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery, + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryBuilder> { public V1GroupVersionForDiscoveryBuilder() { this(false); } + public V1GroupVersionForDiscoveryBuilder(java.lang.Boolean validationEnabled) { this(new V1GroupVersionForDiscovery(), validationEnabled); } - public V1GroupVersionForDiscoveryBuilder(io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent fluent) { + + public V1GroupVersionForDiscoveryBuilder( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent fluent) { this(fluent, false); } - public V1GroupVersionForDiscoveryBuilder(io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent fluent,java.lang.Boolean validationEnabled) { + + public V1GroupVersionForDiscoveryBuilder( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1GroupVersionForDiscovery(), validationEnabled); } - public V1GroupVersionForDiscoveryBuilder(io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent fluent,io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery instance) { + + public V1GroupVersionForDiscoveryBuilder( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent fluent, + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery instance) { this(fluent, instance, false); } - public V1GroupVersionForDiscoveryBuilder(io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent fluent,io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1GroupVersionForDiscoveryBuilder( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent fluent, + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withGroupVersion(instance.getGroupVersion()); fluent.withVersion(instance.getVersion()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1GroupVersionForDiscoveryBuilder(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery instance) { - this(instance,false); + + public V1GroupVersionForDiscoveryBuilder( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery instance) { + this(instance, false); } - public V1GroupVersionForDiscoveryBuilder(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1GroupVersionForDiscoveryBuilder( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withGroupVersion(instance.getGroupVersion()); this.withVersion(instance.getVersion()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery build() { V1GroupVersionForDiscovery buildable = new V1GroupVersionForDiscovery(); buildable.setGroupVersion(fluent.getGroupVersion()); buildable.setVersion(fluent.getVersion()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1GroupVersionForDiscoveryBuilder that = (V1GroupVersionForDiscoveryBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GroupVersionForDiscoveryFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GroupVersionForDiscoveryFluent.java index 705ccab127..09ee8fe124 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GroupVersionForDiscoveryFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GroupVersionForDiscoveryFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1GroupVersionForDiscoveryFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1GroupVersionForDiscoveryFluent< + A extends io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getGroupVersion(); + public A withGroupVersion(java.lang.String groupVersion); + public java.lang.Boolean hasGroupVersion(); - - /** - * Method is deprecated. use withGroupVersion instead. - */ + + /** Method is deprecated. use withGroupVersion instead. */ @java.lang.Deprecated public A withNewGroupVersion(java.lang.String original); + public java.lang.String getVersion(); + public A withVersion(java.lang.String version); + public java.lang.Boolean hasVersion(); - - /** - * Method is deprecated. use withVersion instead. - */ + + /** Method is deprecated. use withVersion instead. */ @java.lang.Deprecated public A withNewVersion(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GroupVersionForDiscoveryFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GroupVersionForDiscoveryFluentImpl.java index e395743dd7..14bcdbf182 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GroupVersionForDiscoveryFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1GroupVersionForDiscoveryFluentImpl.java @@ -1,69 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1GroupVersionForDiscoveryFluentImpl< + A extends io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent { + public V1GroupVersionForDiscoveryFluentImpl() {} - /** - * Generated - */ -public class V1GroupVersionForDiscoveryFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1GroupVersionForDiscoveryFluent{ - public V1GroupVersionForDiscoveryFluentImpl() { - } - public V1GroupVersionForDiscoveryFluentImpl(io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery instance) { + public V1GroupVersionForDiscoveryFluentImpl( + io.kubernetes.client.openapi.models.V1GroupVersionForDiscovery instance) { this.withGroupVersion(instance.getGroupVersion()); this.withVersion(instance.getVersion()); - } + private java.lang.String groupVersion; private java.lang.String version; + public java.lang.String getGroupVersion() { return this.groupVersion; } + public A withGroupVersion(java.lang.String groupVersion) { - this.groupVersion=groupVersion; return (A) this; + this.groupVersion = groupVersion; + return (A) this; } + public java.lang.Boolean hasGroupVersion() { return this.groupVersion != null; } - - /** - * Method is deprecated. use withGroupVersion instead. - */ + + /** Method is deprecated. use withGroupVersion instead. */ @java.lang.Deprecated public A withNewGroupVersion(java.lang.String original) { - return (A)withGroupVersion(new String(original)); + return (A) withGroupVersion(new String(original)); } + public java.lang.String getVersion() { return this.version; } + public A withVersion(java.lang.String version) { - this.version=version; return (A) this; + this.version = version; + return (A) this; } + public java.lang.Boolean hasVersion() { return this.version != null; } - - /** - * Method is deprecated. use withVersion instead. - */ + + /** Method is deprecated. use withVersion instead. */ @java.lang.Deprecated public A withNewVersion(java.lang.String original) { - return (A)withVersion(new String(original)); + return (A) withVersion(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1GroupVersionForDiscoveryFluentImpl that = (V1GroupVersionForDiscoveryFluentImpl) o; - if (groupVersion != null ? !groupVersion.equals(that.groupVersion) :that.groupVersion != null) return false; - if (version != null ? !version.equals(that.version) :that.version != null) return false; + if (groupVersion != null ? !groupVersion.equals(that.groupVersion) : that.groupVersion != null) + return false; + if (version != null ? !version.equals(that.version) : that.version != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(groupVersion, version, super.hashCode()); + return java.util.Objects.hash(groupVersion, version, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPGetActionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPGetActionBuilder.java index ed2c48217f..af48a042da 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPGetActionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPGetActionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1HTTPGetActionBuilder extends io.kubernetes.client.openapi.models.V1HTTPGetActionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1HTTPGetActionBuilder + extends io.kubernetes.client.openapi.models.V1HTTPGetActionFluentImpl< + io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1HTTPGetAction, + io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder> { public V1HTTPGetActionBuilder() { this(false); } + public V1HTTPGetActionBuilder(java.lang.Boolean validationEnabled) { this(new V1HTTPGetAction(), validationEnabled); } - public V1HTTPGetActionBuilder(io.kubernetes.client.openapi.models.V1HTTPGetActionFluent fluent) { + + public V1HTTPGetActionBuilder( + io.kubernetes.client.openapi.models.V1HTTPGetActionFluent fluent) { this(fluent, false); } - public V1HTTPGetActionBuilder(io.kubernetes.client.openapi.models.V1HTTPGetActionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1HTTPGetActionBuilder( + io.kubernetes.client.openapi.models.V1HTTPGetActionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1HTTPGetAction(), validationEnabled); } - public V1HTTPGetActionBuilder(io.kubernetes.client.openapi.models.V1HTTPGetActionFluent fluent,io.kubernetes.client.openapi.models.V1HTTPGetAction instance) { + + public V1HTTPGetActionBuilder( + io.kubernetes.client.openapi.models.V1HTTPGetActionFluent fluent, + io.kubernetes.client.openapi.models.V1HTTPGetAction instance) { this(fluent, instance, false); } - public V1HTTPGetActionBuilder(io.kubernetes.client.openapi.models.V1HTTPGetActionFluent fluent,io.kubernetes.client.openapi.models.V1HTTPGetAction instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1HTTPGetActionBuilder( + io.kubernetes.client.openapi.models.V1HTTPGetActionFluent fluent, + io.kubernetes.client.openapi.models.V1HTTPGetAction instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withHost(instance.getHost()); fluent.withHttpHeaders(instance.getHttpHeaders()); @@ -31,13 +58,17 @@ public V1HTTPGetActionBuilder(io.kubernetes.client.openapi.models.V1HTTPGetActio fluent.withScheme(instance.getScheme()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1HTTPGetActionBuilder(io.kubernetes.client.openapi.models.V1HTTPGetAction instance) { - this(instance,false); + this(instance, false); } - public V1HTTPGetActionBuilder(io.kubernetes.client.openapi.models.V1HTTPGetAction instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1HTTPGetActionBuilder( + io.kubernetes.client.openapi.models.V1HTTPGetAction instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withHost(instance.getHost()); this.withHttpHeaders(instance.getHttpHeaders()); @@ -48,10 +79,12 @@ public V1HTTPGetActionBuilder(io.kubernetes.client.openapi.models.V1HTTPGetActio this.withScheme(instance.getScheme()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1HTTPGetActionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1HTTPGetAction build() { V1HTTPGetAction buildable = new V1HTTPGetAction(); buildable.setHost(fluent.getHost()); @@ -61,18 +94,23 @@ public io.kubernetes.client.openapi.models.V1HTTPGetAction build() { buildable.setScheme(fluent.getScheme()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1HTTPGetActionBuilder that = (V1HTTPGetActionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPGetActionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPGetActionFluent.java index 7a94f83ce7..59e39894bc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPGetActionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPGetActionFluent.java @@ -1,84 +1,138 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.custom.IntOrString; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1HTTPGetActionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1HTTPGetActionFluent< + A extends io.kubernetes.client.openapi.models.V1HTTPGetActionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getHost(); + public A withHost(java.lang.String host); + public java.lang.Boolean hasHost(); - - /** - * Method is deprecated. use withHost instead. - */ + + /** Method is deprecated. use withHost instead. */ @java.lang.Deprecated public A withNewHost(java.lang.String original); - public A addToHttpHeaders(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPHeader item); - public A setToHttpHeaders(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPHeader item); + + public A addToHttpHeaders( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPHeader item); + + public A setToHttpHeaders( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPHeader item); + public A addToHttpHeaders(io.kubernetes.client.openapi.models.V1HTTPHeader... items); - public A addAllToHttpHeaders(java.util.Collection items); + + public A addAllToHttpHeaders( + java.util.Collection items); + public A removeFromHttpHeaders(io.kubernetes.client.openapi.models.V1HTTPHeader... items); - public A removeAllFromHttpHeaders(java.util.Collection items); - public A removeMatchingFromHttpHeaders(java.util.function.Predicate predicate); - + + public A removeAllFromHttpHeaders( + java.util.Collection items); + + public A removeMatchingFromHttpHeaders( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildHttpHeaders instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getHttpHeaders(); + public java.util.List buildHttpHeaders(); + public io.kubernetes.client.openapi.models.V1HTTPHeader buildHttpHeader(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1HTTPHeader buildFirstHttpHeader(); + public io.kubernetes.client.openapi.models.V1HTTPHeader buildLastHttpHeader(); - public io.kubernetes.client.openapi.models.V1HTTPHeader buildMatchingHttpHeader(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingHttpHeader(java.util.function.Predicate predicate); - public A withHttpHeaders(java.util.List httpHeaders); + + public io.kubernetes.client.openapi.models.V1HTTPHeader buildMatchingHttpHeader( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingHttpHeader( + java.util.function.Predicate + predicate); + + public A withHttpHeaders( + java.util.List httpHeaders); + public A withHttpHeaders(io.kubernetes.client.openapi.models.V1HTTPHeader... httpHeaders); + public java.lang.Boolean hasHttpHeaders(); - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested addNewHttpHeader(); - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested addNewHttpHeaderLike(io.kubernetes.client.openapi.models.V1HTTPHeader item); - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested setNewHttpHeaderLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPHeader item); - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested editHttpHeader(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested editFirstHttpHeader(); - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested editLastHttpHeader(); - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested editMatchingHttpHeader(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + addNewHttpHeader(); + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + addNewHttpHeaderLike(io.kubernetes.client.openapi.models.V1HTTPHeader item); + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + setNewHttpHeaderLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPHeader item); + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + editHttpHeader(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + editFirstHttpHeader(); + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + editLastHttpHeader(); + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + editMatchingHttpHeader( + java.util.function.Predicate + predicate); + public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); + public io.kubernetes.client.custom.IntOrString getPort(); + public A withPort(io.kubernetes.client.custom.IntOrString port); + public java.lang.Boolean hasPort(); + public A withNewPort(int value); + public A withNewPort(java.lang.String value); + public io.kubernetes.client.openapi.models.V1HTTPGetAction.SchemeEnum getScheme(); + public A withScheme(io.kubernetes.client.openapi.models.V1HTTPGetAction.SchemeEnum scheme); + public java.lang.Boolean hasScheme(); - public interface HttpHeadersNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1HTTPHeaderFluent>{ + + public interface HttpHeadersNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1HTTPHeaderFluent< + io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested> { public N and(); + public N endHttpHeader(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPGetActionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPGetActionFluentImpl.java index 6e8b4773b4..5df554456c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPGetActionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPGetActionFluentImpl.java @@ -1,26 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; import io.kubernetes.client.custom.IntOrString; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1HTTPGetActionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1HTTPGetActionFluent{ - public V1HTTPGetActionFluentImpl() { - } +/** Generated */ +public class V1HTTPGetActionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1HTTPGetActionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1HTTPGetActionFluent { + public V1HTTPGetActionFluentImpl() {} + public V1HTTPGetActionFluentImpl(io.kubernetes.client.openapi.models.V1HTTPGetAction instance) { this.withHost(instance.getHost()); @@ -31,58 +33,129 @@ public V1HTTPGetActionFluentImpl(io.kubernetes.client.openapi.models.V1HTTPGetAc this.withPort(instance.getPort()); this.withScheme(instance.getScheme()); - } + private java.lang.String host; private java.util.ArrayList httpHeaders; private java.lang.String path; private io.kubernetes.client.custom.IntOrString port; private io.kubernetes.client.openapi.models.V1HTTPGetAction.SchemeEnum scheme; + public java.lang.String getHost() { return this.host; } + public A withHost(java.lang.String host) { - this.host=host; return (A) this; + this.host = host; + return (A) this; } + public java.lang.Boolean hasHost() { return this.host != null; } - - /** - * Method is deprecated. use withHost instead. - */ + + /** Method is deprecated. use withHost instead. */ @java.lang.Deprecated public A withNewHost(java.lang.String original) { - return (A)withHost(new String(original)); + return (A) withHost(new String(original)); } - public A addToHttpHeaders(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPHeader item) { - if (this.httpHeaders == null) {this.httpHeaders = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder = new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(item);_visitables.get("httpHeaders").add(index >= 0 ? index : _visitables.get("httpHeaders").size(), builder);this.httpHeaders.add(index >= 0 ? index : httpHeaders.size(), builder); return (A)this; + + public A addToHttpHeaders( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPHeader item) { + if (this.httpHeaders == null) { + this.httpHeaders = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder = + new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(item); + _visitables + .get("httpHeaders") + .add(index >= 0 ? index : _visitables.get("httpHeaders").size(), builder); + this.httpHeaders.add(index >= 0 ? index : httpHeaders.size(), builder); + return (A) this; } - public A setToHttpHeaders(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPHeader item) { - if (this.httpHeaders == null) {this.httpHeaders = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder = new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(item); - if (index < 0 || index >= _visitables.get("httpHeaders").size()) { _visitables.get("httpHeaders").add(builder); } else { _visitables.get("httpHeaders").set(index, builder);} - if (index < 0 || index >= httpHeaders.size()) { httpHeaders.add(builder); } else { httpHeaders.set(index, builder);} - return (A)this; + + public A setToHttpHeaders( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPHeader item) { + if (this.httpHeaders == null) { + this.httpHeaders = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder = + new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(item); + if (index < 0 || index >= _visitables.get("httpHeaders").size()) { + _visitables.get("httpHeaders").add(builder); + } else { + _visitables.get("httpHeaders").set(index, builder); + } + if (index < 0 || index >= httpHeaders.size()) { + httpHeaders.add(builder); + } else { + httpHeaders.set(index, builder); + } + return (A) this; } + public A addToHttpHeaders(io.kubernetes.client.openapi.models.V1HTTPHeader... items) { - if (this.httpHeaders == null) {this.httpHeaders = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1HTTPHeader item : items) {io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder = new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(item);_visitables.get("httpHeaders").add(builder);this.httpHeaders.add(builder);} return (A)this; + if (this.httpHeaders == null) { + this.httpHeaders = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1HTTPHeader item : items) { + io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder = + new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(item); + _visitables.get("httpHeaders").add(builder); + this.httpHeaders.add(builder); + } + return (A) this; } - public A addAllToHttpHeaders(java.util.Collection items) { - if (this.httpHeaders == null) {this.httpHeaders = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1HTTPHeader item : items) {io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder = new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(item);_visitables.get("httpHeaders").add(builder);this.httpHeaders.add(builder);} return (A)this; + + public A addAllToHttpHeaders( + java.util.Collection items) { + if (this.httpHeaders == null) { + this.httpHeaders = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1HTTPHeader item : items) { + io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder = + new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(item); + _visitables.get("httpHeaders").add(builder); + this.httpHeaders.add(builder); + } + return (A) this; } + public A removeFromHttpHeaders(io.kubernetes.client.openapi.models.V1HTTPHeader... items) { - for (io.kubernetes.client.openapi.models.V1HTTPHeader item : items) {io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder = new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(item);_visitables.get("httpHeaders").remove(builder);if (this.httpHeaders != null) {this.httpHeaders.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1HTTPHeader item : items) { + io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder = + new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(item); + _visitables.get("httpHeaders").remove(builder); + if (this.httpHeaders != null) { + this.httpHeaders.remove(builder); + } + } + return (A) this; } - public A removeAllFromHttpHeaders(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1HTTPHeader item : items) {io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder = new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(item);_visitables.get("httpHeaders").remove(builder);if (this.httpHeaders != null) {this.httpHeaders.remove(builder);}} return (A)this; + + public A removeAllFromHttpHeaders( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1HTTPHeader item : items) { + io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder = + new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(item); + _visitables.get("httpHeaders").remove(builder); + if (this.httpHeaders != null) { + this.httpHeaders.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromHttpHeaders(java.util.function.Predicate predicate) { + + public A removeMatchingFromHttpHeaders( + java.util.function.Predicate + predicate) { if (httpHeaders == null) return (A) this; - final Iterator each = httpHeaders.iterator(); + final Iterator each = + httpHeaders.iterator(); final List visitables = _visitables.get("httpHeaders"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder = each.next(); @@ -91,149 +164,239 @@ public A removeMatchingFromHttpHeaders(java.util.function.Predicate getHttpHeaders() { return httpHeaders != null ? build(httpHeaders) : null; } + public java.util.List buildHttpHeaders() { return httpHeaders != null ? build(httpHeaders) : null; } + public io.kubernetes.client.openapi.models.V1HTTPHeader buildHttpHeader(java.lang.Integer index) { return this.httpHeaders.get(index).build(); } + public io.kubernetes.client.openapi.models.V1HTTPHeader buildFirstHttpHeader() { return this.httpHeaders.get(0).build(); } + public io.kubernetes.client.openapi.models.V1HTTPHeader buildLastHttpHeader() { return this.httpHeaders.get(httpHeaders.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1HTTPHeader buildMatchingHttpHeader(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder item: httpHeaders) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1HTTPHeader buildMatchingHttpHeader( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder item : httpHeaders) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingHttpHeader(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder item: httpHeaders) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingHttpHeader( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder item : httpHeaders) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withHttpHeaders(java.util.List httpHeaders) { - if (this.httpHeaders != null) { _visitables.get("httpHeaders").removeAll(this.httpHeaders);} - if (httpHeaders != null) {this.httpHeaders = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1HTTPHeader item : httpHeaders){this.addToHttpHeaders(item);}} else { this.httpHeaders = null;} return (A) this; + + public A withHttpHeaders( + java.util.List httpHeaders) { + if (this.httpHeaders != null) { + _visitables.get("httpHeaders").removeAll(this.httpHeaders); + } + if (httpHeaders != null) { + this.httpHeaders = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1HTTPHeader item : httpHeaders) { + this.addToHttpHeaders(item); + } + } else { + this.httpHeaders = null; + } + return (A) this; } + public A withHttpHeaders(io.kubernetes.client.openapi.models.V1HTTPHeader... httpHeaders) { - if (this.httpHeaders != null) {this.httpHeaders.clear();} - if (httpHeaders != null) {for (io.kubernetes.client.openapi.models.V1HTTPHeader item :httpHeaders){ this.addToHttpHeaders(item);}} return (A) this; + if (this.httpHeaders != null) { + this.httpHeaders.clear(); + } + if (httpHeaders != null) { + for (io.kubernetes.client.openapi.models.V1HTTPHeader item : httpHeaders) { + this.addToHttpHeaders(item); + } + } + return (A) this; } + public java.lang.Boolean hasHttpHeaders() { return httpHeaders != null && !httpHeaders.isEmpty(); } - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested addNewHttpHeader() { - return new io.kubernetes.client.openapi.models.V1HTTPGetActionFluentImpl.HttpHeadersNestedImpl(); + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + addNewHttpHeader() { + return new io.kubernetes.client.openapi.models.V1HTTPGetActionFluentImpl + .HttpHeadersNestedImpl(); } - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested addNewHttpHeaderLike(io.kubernetes.client.openapi.models.V1HTTPHeader item) { - return new io.kubernetes.client.openapi.models.V1HTTPGetActionFluentImpl.HttpHeadersNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + addNewHttpHeaderLike(io.kubernetes.client.openapi.models.V1HTTPHeader item) { + return new io.kubernetes.client.openapi.models.V1HTTPGetActionFluentImpl.HttpHeadersNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested setNewHttpHeaderLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPHeader item) { - return new io.kubernetes.client.openapi.models.V1HTTPGetActionFluentImpl.HttpHeadersNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + setNewHttpHeaderLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPHeader item) { + return new io.kubernetes.client.openapi.models.V1HTTPGetActionFluentImpl.HttpHeadersNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested editHttpHeader(java.lang.Integer index) { - if (httpHeaders.size() <= index) throw new RuntimeException("Can't edit httpHeaders. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + editHttpHeader(java.lang.Integer index) { + if (httpHeaders.size() <= index) + throw new RuntimeException("Can't edit httpHeaders. Index exceeds size."); return setNewHttpHeaderLike(index, buildHttpHeader(index)); } - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested editFirstHttpHeader() { - if (httpHeaders.size() == 0) throw new RuntimeException("Can't edit first httpHeaders. The list is empty."); + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + editFirstHttpHeader() { + if (httpHeaders.size() == 0) + throw new RuntimeException("Can't edit first httpHeaders. The list is empty."); return setNewHttpHeaderLike(0, buildHttpHeader(0)); } - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested editLastHttpHeader() { + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + editLastHttpHeader() { int index = httpHeaders.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last httpHeaders. The list is empty."); return setNewHttpHeaderLike(index, buildHttpHeader(index)); } - public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested editMatchingHttpHeader(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested + editMatchingHttpHeader( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1HTTPHeaderFluentImpl> implements io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested,io.kubernetes.client.fluent.Nested{ - HttpHeadersNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPHeader item) { + + public class HttpHeadersNestedImpl + extends io.kubernetes.client.openapi.models.V1HTTPHeaderFluentImpl< + io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested> + implements io.kubernetes.client.openapi.models.V1HTTPGetActionFluent.HttpHeadersNested, + io.kubernetes.client.fluent.Nested { + HttpHeadersNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPHeader item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(this, item); } + HttpHeadersNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder(this); } + io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1HTTPGetActionFluentImpl.this.setToHttpHeaders(index,builder.build()); + return (N) V1HTTPGetActionFluentImpl.this.setToHttpHeaders(index, builder.build()); } + public N endHttpHeader() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPHeaderBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPHeaderBuilder.java index 200ccff22f..19319e3e31 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPHeaderBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPHeaderBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1HTTPHeaderBuilder extends io.kubernetes.client.openapi.models.V1HTTPHeaderFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1HTTPHeaderBuilder + extends io.kubernetes.client.openapi.models.V1HTTPHeaderFluentImpl< + io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1HTTPHeader, + io.kubernetes.client.openapi.models.V1HTTPHeaderBuilder> { public V1HTTPHeaderBuilder() { this(false); } + public V1HTTPHeaderBuilder(java.lang.Boolean validationEnabled) { this(new V1HTTPHeader(), validationEnabled); } + public V1HTTPHeaderBuilder(io.kubernetes.client.openapi.models.V1HTTPHeaderFluent fluent) { this(fluent, false); } - public V1HTTPHeaderBuilder(io.kubernetes.client.openapi.models.V1HTTPHeaderFluent fluent,java.lang.Boolean validationEnabled) { + + public V1HTTPHeaderBuilder( + io.kubernetes.client.openapi.models.V1HTTPHeaderFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1HTTPHeader(), validationEnabled); } - public V1HTTPHeaderBuilder(io.kubernetes.client.openapi.models.V1HTTPHeaderFluent fluent,io.kubernetes.client.openapi.models.V1HTTPHeader instance) { + + public V1HTTPHeaderBuilder( + io.kubernetes.client.openapi.models.V1HTTPHeaderFluent fluent, + io.kubernetes.client.openapi.models.V1HTTPHeader instance) { this(fluent, instance, false); } - public V1HTTPHeaderBuilder(io.kubernetes.client.openapi.models.V1HTTPHeaderFluent fluent,io.kubernetes.client.openapi.models.V1HTTPHeader instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1HTTPHeaderBuilder( + io.kubernetes.client.openapi.models.V1HTTPHeaderFluent fluent, + io.kubernetes.client.openapi.models.V1HTTPHeader instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1HTTPHeaderBuilder(io.kubernetes.client.openapi.models.V1HTTPHeader instance) { - this(instance,false); + this(instance, false); } - public V1HTTPHeaderBuilder(io.kubernetes.client.openapi.models.V1HTTPHeader instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1HTTPHeaderBuilder( + io.kubernetes.client.openapi.models.V1HTTPHeader instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1HTTPHeaderFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1HTTPHeader build() { V1HTTPHeader buildable = new V1HTTPHeader(); buildable.setName(fluent.getName()); buildable.setValue(fluent.getValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1HTTPHeaderBuilder that = (V1HTTPHeaderBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPHeaderFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPHeaderFluent.java index 1c64feba1b..a5e675575a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPHeaderFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPHeaderFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1HTTPHeaderFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1HTTPHeaderFluent< + A extends io.kubernetes.client.openapi.models.V1HTTPHeaderFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getValue(); + public A withValue(java.lang.String value); + public java.lang.Boolean hasValue(); - - /** - * Method is deprecated. use withValue instead. - */ + + /** Method is deprecated. use withValue instead. */ @java.lang.Deprecated public A withNewValue(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPHeaderFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPHeaderFluentImpl.java index 97bca95845..f364e07be7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPHeaderFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPHeaderFluentImpl.java @@ -1,69 +1,81 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1HTTPHeaderFluentImpl< + A extends io.kubernetes.client.openapi.models.V1HTTPHeaderFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1HTTPHeaderFluent { + public V1HTTPHeaderFluentImpl() {} - /** - * Generated - */ -public class V1HTTPHeaderFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1HTTPHeaderFluent{ - public V1HTTPHeaderFluentImpl() { - } public V1HTTPHeaderFluentImpl(io.kubernetes.client.openapi.models.V1HTTPHeader instance) { this.withName(instance.getName()); this.withValue(instance.getValue()); - } + private java.lang.String name; private java.lang.String value; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getValue() { return this.value; } + public A withValue(java.lang.String value) { - this.value=value; return (A) this; + this.value = value; + return (A) this; } + public java.lang.Boolean hasValue() { return this.value != null; } - - /** - * Method is deprecated. use withValue instead. - */ + + /** Method is deprecated. use withValue instead. */ @java.lang.Deprecated public A withNewValue(java.lang.String original) { - return (A)withValue(new String(original)); + return (A) withValue(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1HTTPHeaderFluentImpl that = (V1HTTPHeaderFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (value != null ? !value.equals(that.value) :that.value != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (value != null ? !value.equals(that.value) : that.value != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, value, super.hashCode()); + return java.util.Objects.hash(name, value, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressPathBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressPathBuilder.java index dfdbcd9911..91341e7596 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressPathBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressPathBuilder.java @@ -1,49 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1HTTPIngressPathBuilder extends io.kubernetes.client.openapi.models.V1HTTPIngressPathFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1HTTPIngressPathBuilder + extends io.kubernetes.client.openapi.models.V1HTTPIngressPathFluentImpl< + io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1HTTPIngressPath, + io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder> { public V1HTTPIngressPathBuilder() { this(false); } + public V1HTTPIngressPathBuilder(java.lang.Boolean validationEnabled) { this(new V1HTTPIngressPath(), validationEnabled); } - public V1HTTPIngressPathBuilder(io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent fluent) { + + public V1HTTPIngressPathBuilder( + io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent fluent) { this(fluent, false); } - public V1HTTPIngressPathBuilder(io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent fluent,java.lang.Boolean validationEnabled) { + + public V1HTTPIngressPathBuilder( + io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1HTTPIngressPath(), validationEnabled); } - public V1HTTPIngressPathBuilder(io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent fluent,io.kubernetes.client.openapi.models.V1HTTPIngressPath instance) { + + public V1HTTPIngressPathBuilder( + io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent fluent, + io.kubernetes.client.openapi.models.V1HTTPIngressPath instance) { this(fluent, instance, false); } - public V1HTTPIngressPathBuilder(io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent fluent,io.kubernetes.client.openapi.models.V1HTTPIngressPath instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1HTTPIngressPathBuilder( + io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent fluent, + io.kubernetes.client.openapi.models.V1HTTPIngressPath instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withBackend(instance.getBackend()); fluent.withPath(instance.getPath()); fluent.withPathType(instance.getPathType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1HTTPIngressPathBuilder(io.kubernetes.client.openapi.models.V1HTTPIngressPath instance) { - this(instance,false); + this(instance, false); } - public V1HTTPIngressPathBuilder(io.kubernetes.client.openapi.models.V1HTTPIngressPath instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1HTTPIngressPathBuilder( + io.kubernetes.client.openapi.models.V1HTTPIngressPath instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withBackend(instance.getBackend()); this.withPath(instance.getPath()); this.withPathType(instance.getPathType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1HTTPIngressPath build() { V1HTTPIngressPath buildable = new V1HTTPIngressPath(); buildable.setBackend(fluent.getBackend()); @@ -51,18 +84,23 @@ public io.kubernetes.client.openapi.models.V1HTTPIngressPath build() { buildable.setPathType(fluent.getPathType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1HTTPIngressPathBuilder that = (V1HTTPIngressPathBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressPathFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressPathFluent.java index 244bf12c55..5f53e1c6b1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressPathFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressPathFluent.java @@ -1,53 +1,76 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1HTTPIngressPathFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1HTTPIngressPathFluent< + A extends io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildBackend instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressBackend getBackend(); + public io.kubernetes.client.openapi.models.V1IngressBackend buildBackend(); + public A withBackend(io.kubernetes.client.openapi.models.V1IngressBackend backend); + public java.lang.Boolean hasBackend(); - public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested withNewBackend(); - public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested withNewBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item); + + public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested + withNewBackend(); + + public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested + withNewBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item); + public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested editBackend(); - public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested editOrNewBackend(); - public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested editOrNewBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item); + + public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested + editOrNewBackend(); + + public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested + editOrNewBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item); + public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); + public java.lang.String getPathType(); + public A withPathType(java.lang.String pathType); + public java.lang.Boolean hasPathType(); - - /** - * Method is deprecated. use withPathType instead. - */ + + /** Method is deprecated. use withPathType instead. */ @java.lang.Deprecated public A withNewPathType(java.lang.String original); - public interface BackendNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1IngressBackendFluent>{ + + public interface BackendNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1IngressBackendFluent< + io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested> { public N and(); + public N endBackend(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressPathFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressPathFluentImpl.java index 0143987da6..b35683ec49 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressPathFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressPathFluentImpl.java @@ -1,124 +1,166 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1HTTPIngressPathFluentImpl< + A extends io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent { + public V1HTTPIngressPathFluentImpl() {} - /** - * Generated - */ -public class V1HTTPIngressPathFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent{ - public V1HTTPIngressPathFluentImpl() { - } - public V1HTTPIngressPathFluentImpl(io.kubernetes.client.openapi.models.V1HTTPIngressPath instance) { + public V1HTTPIngressPathFluentImpl( + io.kubernetes.client.openapi.models.V1HTTPIngressPath instance) { this.withBackend(instance.getBackend()); this.withPath(instance.getPath()); this.withPathType(instance.getPathType()); - } + private io.kubernetes.client.openapi.models.V1IngressBackendBuilder backend; private java.lang.String path; private java.lang.String pathType; - + /** * This method has been deprecated, please use method buildBackend instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressBackend getBackend() { - return this.backend!=null ?this.backend.build():null; + return this.backend != null ? this.backend.build() : null; } + public io.kubernetes.client.openapi.models.V1IngressBackend buildBackend() { - return this.backend!=null ?this.backend.build():null; + return this.backend != null ? this.backend.build() : null; } + public A withBackend(io.kubernetes.client.openapi.models.V1IngressBackend backend) { _visitables.get("backend").remove(this.backend); - if (backend!=null){ this.backend= new io.kubernetes.client.openapi.models.V1IngressBackendBuilder(backend); _visitables.get("backend").add(this.backend);} return (A) this; + if (backend != null) { + this.backend = new io.kubernetes.client.openapi.models.V1IngressBackendBuilder(backend); + _visitables.get("backend").add(this.backend); + } + return (A) this; } + public java.lang.Boolean hasBackend() { return this.backend != null; } - public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested withNewBackend() { + + public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested + withNewBackend() { return new io.kubernetes.client.openapi.models.V1HTTPIngressPathFluentImpl.BackendNestedImpl(); } - public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested withNewBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item) { - return new io.kubernetes.client.openapi.models.V1HTTPIngressPathFluentImpl.BackendNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested + withNewBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item) { + return new io.kubernetes.client.openapi.models.V1HTTPIngressPathFluentImpl.BackendNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested editBackend() { + + public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested + editBackend() { return withNewBackendLike(getBackend()); } - public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested editOrNewBackend() { - return withNewBackendLike(getBackend() != null ? getBackend(): new io.kubernetes.client.openapi.models.V1IngressBackendBuilder().build()); + + public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested + editOrNewBackend() { + return withNewBackendLike( + getBackend() != null + ? getBackend() + : new io.kubernetes.client.openapi.models.V1IngressBackendBuilder().build()); } - public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested editOrNewBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item) { - return withNewBackendLike(getBackend() != null ? getBackend(): item); + + public io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested + editOrNewBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item) { + return withNewBackendLike(getBackend() != null ? getBackend() : item); } + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } + public java.lang.String getPathType() { return this.pathType; } + public A withPathType(java.lang.String pathType) { - this.pathType=pathType; return (A) this; + this.pathType = pathType; + return (A) this; } + public java.lang.Boolean hasPathType() { return this.pathType != null; } - - /** - * Method is deprecated. use withPathType instead. - */ + + /** Method is deprecated. use withPathType instead. */ @java.lang.Deprecated public A withNewPathType(java.lang.String original) { - return (A)withPathType(new String(original)); + return (A) withPathType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1HTTPIngressPathFluentImpl that = (V1HTTPIngressPathFluentImpl) o; - if (backend != null ? !backend.equals(that.backend) :that.backend != null) return false; - if (path != null ? !path.equals(that.path) :that.path != null) return false; - if (pathType != null ? !pathType.equals(that.pathType) :that.pathType != null) return false; + if (backend != null ? !backend.equals(that.backend) : that.backend != null) return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; + if (pathType != null ? !pathType.equals(that.pathType) : that.pathType != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(backend, path, pathType, super.hashCode()); + return java.util.Objects.hash(backend, path, pathType, super.hashCode()); } - public class BackendNestedImpl extends io.kubernetes.client.openapi.models.V1IngressBackendFluentImpl> implements io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested,io.kubernetes.client.fluent.Nested{ + + public class BackendNestedImpl + extends io.kubernetes.client.openapi.models.V1IngressBackendFluentImpl< + io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested> + implements io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent.BackendNested, + io.kubernetes.client.fluent.Nested { BackendNestedImpl(io.kubernetes.client.openapi.models.V1IngressBackend item) { this.builder = new io.kubernetes.client.openapi.models.V1IngressBackendBuilder(this, item); } + BackendNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1IngressBackendBuilder(this); } + io.kubernetes.client.openapi.models.V1IngressBackendBuilder builder; + public N and() { return (N) V1HTTPIngressPathFluentImpl.this.withBackend(builder.build()); } + public N endBackend() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressRuleValueBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressRuleValueBuilder.java index 38c7929bba..5d9c19df08 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressRuleValueBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressRuleValueBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1HTTPIngressRuleValueBuilder extends io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1HTTPIngressRuleValueBuilder + extends io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluentImpl< + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue, + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueBuilder> { public V1HTTPIngressRuleValueBuilder() { this(false); } + public V1HTTPIngressRuleValueBuilder(java.lang.Boolean validationEnabled) { this(new V1HTTPIngressRuleValue(), validationEnabled); } - public V1HTTPIngressRuleValueBuilder(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent fluent) { + + public V1HTTPIngressRuleValueBuilder( + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent fluent) { this(fluent, false); } - public V1HTTPIngressRuleValueBuilder(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent fluent,java.lang.Boolean validationEnabled) { + + public V1HTTPIngressRuleValueBuilder( + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1HTTPIngressRuleValue(), validationEnabled); } - public V1HTTPIngressRuleValueBuilder(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent fluent,io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue instance) { + + public V1HTTPIngressRuleValueBuilder( + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent fluent, + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue instance) { this(fluent, instance, false); } - public V1HTTPIngressRuleValueBuilder(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent fluent,io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1HTTPIngressRuleValueBuilder( + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent fluent, + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPaths(instance.getPaths()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1HTTPIngressRuleValueBuilder(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue instance) { - this(instance,false); + + public V1HTTPIngressRuleValueBuilder( + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue instance) { + this(instance, false); } - public V1HTTPIngressRuleValueBuilder(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1HTTPIngressRuleValueBuilder( + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPaths(instance.getPaths()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue build() { V1HTTPIngressRuleValue buildable = new V1HTTPIngressRuleValue(); buildable.setPaths(fluent.getPaths()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1HTTPIngressRuleValueBuilder that = (V1HTTPIngressRuleValueBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressRuleValueFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressRuleValueFluent.java index 6769eb2e09..cebb76023f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressRuleValueFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressRuleValueFluent.java @@ -1,57 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1HTTPIngressRuleValueFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToPaths(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPIngressPath item); - public A setToPaths(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPIngressPath item); +/** Generated */ +public interface V1HTTPIngressRuleValueFluent< + A extends io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToPaths( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPIngressPath item); + + public A setToPaths( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPIngressPath item); + public A addToPaths(io.kubernetes.client.openapi.models.V1HTTPIngressPath... items); - public A addAllToPaths(java.util.Collection items); + + public A addAllToPaths( + java.util.Collection items); + public A removeFromPaths(io.kubernetes.client.openapi.models.V1HTTPIngressPath... items); - public A removeAllFromPaths(java.util.Collection items); - public A removeMatchingFromPaths(java.util.function.Predicate predicate); - + + public A removeAllFromPaths( + java.util.Collection items); + + public A removeMatchingFromPaths( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildPaths instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getPaths(); + public java.util.List buildPaths(); + public io.kubernetes.client.openapi.models.V1HTTPIngressPath buildPath(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1HTTPIngressPath buildFirstPath(); + public io.kubernetes.client.openapi.models.V1HTTPIngressPath buildLastPath(); - public io.kubernetes.client.openapi.models.V1HTTPIngressPath buildMatchingPath(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPath(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1HTTPIngressPath buildMatchingPath( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingPath( + java.util.function.Predicate + predicate); + public A withPaths(java.util.List paths); + public A withPaths(io.kubernetes.client.openapi.models.V1HTTPIngressPath... paths); + public java.lang.Boolean hasPaths(); - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested addNewPath(); - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested addNewPathLike(io.kubernetes.client.openapi.models.V1HTTPIngressPath item); - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested setNewPathLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPIngressPath item); - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested editPath(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested editFirstPath(); - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested editLastPath(); - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested editMatchingPath(java.util.function.Predicate predicate); - public interface PathsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent>{ + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested + addNewPath(); + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested + addNewPathLike(io.kubernetes.client.openapi.models.V1HTTPIngressPath item); + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested + setNewPathLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPIngressPath item); + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested editPath( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested + editFirstPath(); + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested + editLastPath(); + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested + editMatchingPath( + java.util.function.Predicate + predicate); + + public interface PathsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1HTTPIngressPathFluent< + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested> { public N and(); + public N endPath(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressRuleValueFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressRuleValueFluentImpl.java index 6fc7160b2b..368ca79496 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressRuleValueFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HTTPIngressRuleValueFluentImpl.java @@ -1,57 +1,128 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1HTTPIngressRuleValueFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent{ - public V1HTTPIngressRuleValueFluentImpl() { - } - public V1HTTPIngressRuleValueFluentImpl(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue instance) { - this.withPaths(instance.getPaths()); +/** Generated */ +public class V1HTTPIngressRuleValueFluentImpl< + A extends io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent { + public V1HTTPIngressRuleValueFluentImpl() {} + public V1HTTPIngressRuleValueFluentImpl( + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue instance) { + this.withPaths(instance.getPaths()); } + private java.util.ArrayList paths; - public A addToPaths(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPIngressPath item) { - if (this.paths == null) {this.paths = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder = new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(item);_visitables.get("paths").add(index >= 0 ? index : _visitables.get("paths").size(), builder);this.paths.add(index >= 0 ? index : paths.size(), builder); return (A)this; + + public A addToPaths( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPIngressPath item) { + if (this.paths == null) { + this.paths = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder = + new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(item); + _visitables.get("paths").add(index >= 0 ? index : _visitables.get("paths").size(), builder); + this.paths.add(index >= 0 ? index : paths.size(), builder); + return (A) this; } - public A setToPaths(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPIngressPath item) { - if (this.paths == null) {this.paths = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder = new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(item); - if (index < 0 || index >= _visitables.get("paths").size()) { _visitables.get("paths").add(builder); } else { _visitables.get("paths").set(index, builder);} - if (index < 0 || index >= paths.size()) { paths.add(builder); } else { paths.set(index, builder);} - return (A)this; + + public A setToPaths( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPIngressPath item) { + if (this.paths == null) { + this.paths = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder = + new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(item); + if (index < 0 || index >= _visitables.get("paths").size()) { + _visitables.get("paths").add(builder); + } else { + _visitables.get("paths").set(index, builder); + } + if (index < 0 || index >= paths.size()) { + paths.add(builder); + } else { + paths.set(index, builder); + } + return (A) this; } + public A addToPaths(io.kubernetes.client.openapi.models.V1HTTPIngressPath... items) { - if (this.paths == null) {this.paths = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1HTTPIngressPath item : items) {io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder = new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(item);_visitables.get("paths").add(builder);this.paths.add(builder);} return (A)this; + if (this.paths == null) { + this.paths = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1HTTPIngressPath item : items) { + io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder = + new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(item); + _visitables.get("paths").add(builder); + this.paths.add(builder); + } + return (A) this; } - public A addAllToPaths(java.util.Collection items) { - if (this.paths == null) {this.paths = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1HTTPIngressPath item : items) {io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder = new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(item);_visitables.get("paths").add(builder);this.paths.add(builder);} return (A)this; + + public A addAllToPaths( + java.util.Collection items) { + if (this.paths == null) { + this.paths = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1HTTPIngressPath item : items) { + io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder = + new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(item); + _visitables.get("paths").add(builder); + this.paths.add(builder); + } + return (A) this; } + public A removeFromPaths(io.kubernetes.client.openapi.models.V1HTTPIngressPath... items) { - for (io.kubernetes.client.openapi.models.V1HTTPIngressPath item : items) {io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder = new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(item);_visitables.get("paths").remove(builder);if (this.paths != null) {this.paths.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1HTTPIngressPath item : items) { + io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder = + new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(item); + _visitables.get("paths").remove(builder); + if (this.paths != null) { + this.paths.remove(builder); + } + } + return (A) this; } - public A removeAllFromPaths(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1HTTPIngressPath item : items) {io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder = new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(item);_visitables.get("paths").remove(builder);if (this.paths != null) {this.paths.remove(builder);}} return (A)this; + + public A removeAllFromPaths( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1HTTPIngressPath item : items) { + io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder = + new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(item); + _visitables.get("paths").remove(builder); + if (this.paths != null) { + this.paths.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPaths(java.util.function.Predicate predicate) { + + public A removeMatchingFromPaths( + java.util.function.Predicate + predicate) { if (paths == null) return (A) this; - final Iterator each = paths.iterator(); + final Iterator each = + paths.iterator(); final List visitables = _visitables.get("paths"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder = each.next(); @@ -60,104 +131,178 @@ public A removeMatchingFromPaths(java.util.function.Predicate getPaths() { return paths != null ? build(paths) : null; } + public java.util.List buildPaths() { return paths != null ? build(paths) : null; } + public io.kubernetes.client.openapi.models.V1HTTPIngressPath buildPath(java.lang.Integer index) { return this.paths.get(index).build(); } + public io.kubernetes.client.openapi.models.V1HTTPIngressPath buildFirstPath() { return this.paths.get(0).build(); } + public io.kubernetes.client.openapi.models.V1HTTPIngressPath buildLastPath() { return this.paths.get(paths.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1HTTPIngressPath buildMatchingPath(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder item: paths) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1HTTPIngressPath buildMatchingPath( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder item : paths) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPath(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder item: paths) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPath( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder item : paths) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withPaths(java.util.List paths) { - if (this.paths != null) { _visitables.get("paths").removeAll(this.paths);} - if (paths != null) {this.paths = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1HTTPIngressPath item : paths){this.addToPaths(item);}} else { this.paths = null;} return (A) this; + if (this.paths != null) { + _visitables.get("paths").removeAll(this.paths); + } + if (paths != null) { + this.paths = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1HTTPIngressPath item : paths) { + this.addToPaths(item); + } + } else { + this.paths = null; + } + return (A) this; } + public A withPaths(io.kubernetes.client.openapi.models.V1HTTPIngressPath... paths) { - if (this.paths != null) {this.paths.clear();} - if (paths != null) {for (io.kubernetes.client.openapi.models.V1HTTPIngressPath item :paths){ this.addToPaths(item);}} return (A) this; + if (this.paths != null) { + this.paths.clear(); + } + if (paths != null) { + for (io.kubernetes.client.openapi.models.V1HTTPIngressPath item : paths) { + this.addToPaths(item); + } + } + return (A) this; } + public java.lang.Boolean hasPaths() { return paths != null && !paths.isEmpty(); } - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested addNewPath() { - return new io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluentImpl.PathsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested + addNewPath() { + return new io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluentImpl + .PathsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested addNewPathLike(io.kubernetes.client.openapi.models.V1HTTPIngressPath item) { - return new io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluentImpl.PathsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested + addNewPathLike(io.kubernetes.client.openapi.models.V1HTTPIngressPath item) { + return new io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluentImpl.PathsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested setNewPathLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPIngressPath item) { - return new io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluentImpl.PathsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested + setNewPathLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPIngressPath item) { + return new io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluentImpl.PathsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested editPath(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested editPath( + java.lang.Integer index) { if (paths.size() <= index) throw new RuntimeException("Can't edit paths. Index exceeds size."); return setNewPathLike(index, buildPath(index)); } - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested editFirstPath() { + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested + editFirstPath() { if (paths.size() == 0) throw new RuntimeException("Can't edit first paths. The list is empty."); return setNewPathLike(0, buildPath(0)); } - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested editLastPath() { + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested + editLastPath() { int index = paths.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last paths. The list is empty."); return setNewPathLike(index, buildPath(index)); } - public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested editMatchingPath(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested + editMatchingPath( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1HTTPIngressPathFluentImpl> implements io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested,io.kubernetes.client.fluent.Nested{ - PathsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HTTPIngressPath item) { + + public class PathsNestedImpl + extends io.kubernetes.client.openapi.models.V1HTTPIngressPathFluentImpl< + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested> + implements io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent.PathsNested, + io.kubernetes.client.fluent.Nested { + PathsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HTTPIngressPath item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(this, item); } + PathsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder(this); } + io.kubernetes.client.openapi.models.V1HTTPIngressPathBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1HTTPIngressRuleValueFluentImpl.this.setToPaths(index,builder.build()); + return (N) V1HTTPIngressRuleValueFluentImpl.this.setToPaths(index, builder.build()); } + public N endPath() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerBuilder.java index 1353d26c80..c17b552ce0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1HorizontalPodAutoscalerBuilder extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1HorizontalPodAutoscalerBuilder + extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder> { public V1HorizontalPodAutoscalerBuilder() { this(false); } + public V1HorizontalPodAutoscalerBuilder(java.lang.Boolean validationEnabled) { this(new V1HorizontalPodAutoscaler(), validationEnabled); } - public V1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent fluent) { + + public V1HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent fluent) { this(fluent, false); } - public V1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent fluent,java.lang.Boolean validationEnabled) { + + public V1HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1HorizontalPodAutoscaler(), validationEnabled); } - public V1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent fluent,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler instance) { + + public V1HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent fluent, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler instance) { this(fluent, instance, false); } - public V1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent fluent,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent fluent, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V1Ho fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler instance) { - this(instance,false); + + public V1HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler instance) { + this(instance, false); } - public V1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V1Ho this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler build() { V1HorizontalPodAutoscaler buildable = new V1HorizontalPodAutoscaler(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1HorizontalPodAutoscalerBuilder that = (V1HorizontalPodAutoscalerBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerFluent.java index afee587185..d5ec3ef6d2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerFluent.java @@ -1,93 +1,153 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1HorizontalPodAutoscalerFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1HorizontalPodAutoscalerFluent< + A extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec getSpec(); + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec item); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec item); - + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus getStatus(); + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus item); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerFluentImpl.java index 6724a87991..6a9570d6b8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1HorizontalPodAutoscalerFluentImpl< + A extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent { + public V1HorizontalPodAutoscalerFluentImpl() {} - /** - * Generated - */ -public class V1HorizontalPodAutoscalerFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent{ - public V1HorizontalPodAutoscalerFluentImpl() { - } - public V1HorizontalPodAutoscalerFluentImpl(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler instance) { + public V1HorizontalPodAutoscalerFluentImpl( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,321 @@ public V1HorizontalPodAutoscalerFluentImpl(io.kubernetes.client.openapi.models.V this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecBuilder spec; private io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = + new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec item) { - return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec item) { + return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus item) { - return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus item) { + return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1HorizontalPodAutoscalerFluentImpl that = (V1HorizontalPodAutoscalerFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1HorizontalPodAutoscalerFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluentImpl< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecBuilder(this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecBuilder builder; + public N and() { return (N) V1HorizontalPodAutoscalerFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluentImpl< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent.StatusNested< + N>, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusBuilder( + this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusBuilder builder; + public N and() { return (N) V1HorizontalPodAutoscalerFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerListBuilder.java index 9838c3fb6e..1cf704bebb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1HorizontalPodAutoscalerListBuilder extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1HorizontalPodAutoscalerListBuilder + extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluentImpl< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerList, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListBuilder> { public V1HorizontalPodAutoscalerListBuilder() { this(false); } + public V1HorizontalPodAutoscalerListBuilder(java.lang.Boolean validationEnabled) { this(new V1HorizontalPodAutoscalerList(), validationEnabled); } - public V1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent fluent) { + + public V1HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent fluent) { this(fluent, false); } - public V1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1HorizontalPodAutoscalerList(), validationEnabled); } - public V1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent fluent,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerList instance) { + + public V1HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent fluent, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerList instance) { this(fluent, instance, false); } - public V1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent fluent,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent fluent, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models. fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerList instance) { - this(instance,false); + + public V1HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerList instance) { + this(instance, false); } - public V1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models. this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerList build() { V1HorizontalPodAutoscalerList buildable = new V1HorizontalPodAutoscalerList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerList build() buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1HorizontalPodAutoscalerListBuilder that = (V1HorizontalPodAutoscalerListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerListFluent.java index 5daa25be60..8597f2a2a5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerListFluent.java @@ -1,95 +1,169 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1HorizontalPodAutoscalerListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1HorizontalPodAutoscalerListFluent< + A extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item); + public A addToItems(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler buildFirstItem(); + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler buildLastItem(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent>{ + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluent< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerListFluentImpl.java index c249fb7a08..ea3e6d7b74 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1HorizontalPodAutoscalerListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent{ - public V1HorizontalPodAutoscalerListFluentImpl() { - } - public V1HorizontalPodAutoscalerListFluentImpl(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerList instance) { + +/** Generated */ +public class V1HorizontalPodAutoscalerListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent { + public V1HorizontalPodAutoscalerListFluentImpl() {} + + public V1HorizontalPodAutoscalerListFluentImpl( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,132 @@ public V1HorizontalPodAutoscalerListFluentImpl(io.kubernetes.client.openapi.mode this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder>(); + } + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder>(); + } + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler... items) { - for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder = each.next(); @@ -87,174 +165,295 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } - public java.util.List buildItems() { + + public java.util.List + buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item) { - return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item) { + return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item) { - return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item) { + return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1HorizontalPodAutoscalerListFluentImpl that = (V1HorizontalPodAutoscalerListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl> implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerFluentImpl< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent + .ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscaler item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder(this); } + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1HorizontalPodAutoscalerListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1HorizontalPodAutoscalerListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1HorizontalPodAutoscalerListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerSpecBuilder.java index d19c6b3e85..9fa889ffff 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1HorizontalPodAutoscalerSpecBuilder extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1HorizontalPodAutoscalerSpecBuilder + extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluentImpl< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecBuilder> { public V1HorizontalPodAutoscalerSpecBuilder() { this(false); } + public V1HorizontalPodAutoscalerSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1HorizontalPodAutoscalerSpec(), validationEnabled); } - public V1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent fluent) { + + public V1HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent fluent) { this(fluent, false); } - public V1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1HorizontalPodAutoscalerSpec(), validationEnabled); } - public V1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent fluent,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec instance) { + + public V1HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent fluent, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec instance) { this(fluent, instance, false); } - public V1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent fluent,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent fluent, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMaxReplicas(instance.getMaxReplicas()); fluent.withMinReplicas(instance.getMinReplicas()); @@ -29,13 +56,18 @@ public V1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models. fluent.withTargetCPUUtilizationPercentage(instance.getTargetCPUUtilizationPercentage()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec instance) { - this(instance,false); + + public V1HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec instance) { + this(instance, false); } - public V1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMaxReplicas(instance.getMaxReplicas()); this.withMinReplicas(instance.getMinReplicas()); @@ -44,10 +76,12 @@ public V1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models. this.withTargetCPUUtilizationPercentage(instance.getTargetCPUUtilizationPercentage()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec build() { V1HorizontalPodAutoscalerSpec buildable = new V1HorizontalPodAutoscalerSpec(); buildable.setMaxReplicas(fluent.getMaxReplicas()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec build() buildable.setTargetCPUUtilizationPercentage(fluent.getTargetCPUUtilizationPercentage()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1HorizontalPodAutoscalerSpecBuilder that = (V1HorizontalPodAutoscalerSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerSpecFluent.java index b28ac23f59..ab3e2fae20 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerSpecFluent.java @@ -1,45 +1,89 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1HorizontalPodAutoscalerSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1HorizontalPodAutoscalerSpecFluent< + A extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getMaxReplicas(); + public A withMaxReplicas(java.lang.Integer maxReplicas); + public java.lang.Boolean hasMaxReplicas(); + public java.lang.Integer getMinReplicas(); + public A withMinReplicas(java.lang.Integer minReplicas); + public java.lang.Boolean hasMinReplicas(); - + /** * This method has been deprecated, please use method buildScaleTargetRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CrossVersionObjectReference getScaleTargetRef(); + public io.kubernetes.client.openapi.models.V1CrossVersionObjectReference buildScaleTargetRef(); - public A withScaleTargetRef(io.kubernetes.client.openapi.models.V1CrossVersionObjectReference scaleTargetRef); + + public A withScaleTargetRef( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReference scaleTargetRef); + public java.lang.Boolean hasScaleTargetRef(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested withNewScaleTargetRef(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested withNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V1CrossVersionObjectReference item); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editScaleTargetRef(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRef(); - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V1CrossVersionObjectReference item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRef(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReference item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editScaleTargetRef(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRef(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReference item); + public java.lang.Integer getTargetCPUUtilizationPercentage(); + public A withTargetCPUUtilizationPercentage(java.lang.Integer targetCPUUtilizationPercentage); + public java.lang.Boolean hasTargetCPUUtilizationPercentage(); - public interface ScaleTargetRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent>{ + + public interface ScaleTargetRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + N>> { public N and(); + public N endScaleTargetRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerSpecFluentImpl.java index ff02ae997c..d41da06ff1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerSpecFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1HorizontalPodAutoscalerSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent { + public V1HorizontalPodAutoscalerSpecFluentImpl() {} - /** - * Generated - */ -public class V1HorizontalPodAutoscalerSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent{ - public V1HorizontalPodAutoscalerSpecFluentImpl() { - } - public V1HorizontalPodAutoscalerSpecFluentImpl(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec instance) { + public V1HorizontalPodAutoscalerSpecFluentImpl( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpec instance) { this.withMaxReplicas(instance.getMaxReplicas()); this.withMinReplicas(instance.getMinReplicas()); @@ -21,101 +28,175 @@ public V1HorizontalPodAutoscalerSpecFluentImpl(io.kubernetes.client.openapi.mode this.withScaleTargetRef(instance.getScaleTargetRef()); this.withTargetCPUUtilizationPercentage(instance.getTargetCPUUtilizationPercentage()); - } + private java.lang.Integer maxReplicas; private java.lang.Integer minReplicas; private io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceBuilder scaleTargetRef; private java.lang.Integer targetCPUUtilizationPercentage; + public java.lang.Integer getMaxReplicas() { return this.maxReplicas; } + public A withMaxReplicas(java.lang.Integer maxReplicas) { - this.maxReplicas=maxReplicas; return (A) this; + this.maxReplicas = maxReplicas; + return (A) this; } + public java.lang.Boolean hasMaxReplicas() { return this.maxReplicas != null; } + public java.lang.Integer getMinReplicas() { return this.minReplicas; } + public A withMinReplicas(java.lang.Integer minReplicas) { - this.minReplicas=minReplicas; return (A) this; + this.minReplicas = minReplicas; + return (A) this; } + public java.lang.Boolean hasMinReplicas() { return this.minReplicas != null; } - + /** * This method has been deprecated, please use method buildScaleTargetRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CrossVersionObjectReference getScaleTargetRef() { - return this.scaleTargetRef!=null ?this.scaleTargetRef.build():null; + return this.scaleTargetRef != null ? this.scaleTargetRef.build() : null; } + public io.kubernetes.client.openapi.models.V1CrossVersionObjectReference buildScaleTargetRef() { - return this.scaleTargetRef!=null ?this.scaleTargetRef.build():null; + return this.scaleTargetRef != null ? this.scaleTargetRef.build() : null; } - public A withScaleTargetRef(io.kubernetes.client.openapi.models.V1CrossVersionObjectReference scaleTargetRef) { + + public A withScaleTargetRef( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReference scaleTargetRef) { _visitables.get("scaleTargetRef").remove(this.scaleTargetRef); - if (scaleTargetRef!=null){ this.scaleTargetRef= new io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceBuilder(scaleTargetRef); _visitables.get("scaleTargetRef").add(this.scaleTargetRef);} return (A) this; + if (scaleTargetRef != null) { + this.scaleTargetRef = + new io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceBuilder( + scaleTargetRef); + _visitables.get("scaleTargetRef").add(this.scaleTargetRef); + } + return (A) this; } + public java.lang.Boolean hasScaleTargetRef() { return this.scaleTargetRef != null; } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested withNewScaleTargetRef() { - return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluentImpl.ScaleTargetRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRef() { + return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluentImpl + .ScaleTargetRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested withNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V1CrossVersionObjectReference item) { - return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluentImpl.ScaleTargetRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReference item) { + return new io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluentImpl + .ScaleTargetRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editScaleTargetRef() { + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editScaleTargetRef() { return withNewScaleTargetRefLike(getScaleTargetRef()); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRef() { - return withNewScaleTargetRefLike(getScaleTargetRef() != null ? getScaleTargetRef(): new io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRef() { + return withNewScaleTargetRefLike( + getScaleTargetRef() != null + ? getScaleTargetRef() + : new io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V1CrossVersionObjectReference item) { - return withNewScaleTargetRefLike(getScaleTargetRef() != null ? getScaleTargetRef(): item); + + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReference item) { + return withNewScaleTargetRefLike(getScaleTargetRef() != null ? getScaleTargetRef() : item); } + public java.lang.Integer getTargetCPUUtilizationPercentage() { return this.targetCPUUtilizationPercentage; } + public A withTargetCPUUtilizationPercentage(java.lang.Integer targetCPUUtilizationPercentage) { - this.targetCPUUtilizationPercentage=targetCPUUtilizationPercentage; return (A) this; + this.targetCPUUtilizationPercentage = targetCPUUtilizationPercentage; + return (A) this; } + public java.lang.Boolean hasTargetCPUUtilizationPercentage() { return this.targetCPUUtilizationPercentage != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1HorizontalPodAutoscalerSpecFluentImpl that = (V1HorizontalPodAutoscalerSpecFluentImpl) o; - if (maxReplicas != null ? !maxReplicas.equals(that.maxReplicas) :that.maxReplicas != null) return false; - if (minReplicas != null ? !minReplicas.equals(that.minReplicas) :that.minReplicas != null) return false; - if (scaleTargetRef != null ? !scaleTargetRef.equals(that.scaleTargetRef) :that.scaleTargetRef != null) return false; - if (targetCPUUtilizationPercentage != null ? !targetCPUUtilizationPercentage.equals(that.targetCPUUtilizationPercentage) :that.targetCPUUtilizationPercentage != null) return false; + if (maxReplicas != null ? !maxReplicas.equals(that.maxReplicas) : that.maxReplicas != null) + return false; + if (minReplicas != null ? !minReplicas.equals(that.minReplicas) : that.minReplicas != null) + return false; + if (scaleTargetRef != null + ? !scaleTargetRef.equals(that.scaleTargetRef) + : that.scaleTargetRef != null) return false; + if (targetCPUUtilizationPercentage != null + ? !targetCPUUtilizationPercentage.equals(that.targetCPUUtilizationPercentage) + : that.targetCPUUtilizationPercentage != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(maxReplicas, minReplicas, scaleTargetRef, targetCPUUtilizationPercentage, super.hashCode()); + return java.util.Objects.hash( + maxReplicas, minReplicas, scaleTargetRef, targetCPUUtilizationPercentage, super.hashCode()); } - public class ScaleTargetRefNestedImpl extends io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested,io.kubernetes.client.fluent.Nested{ - ScaleTargetRefNestedImpl(io.kubernetes.client.openapi.models.V1CrossVersionObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceBuilder(this, item); + + public class ScaleTargetRefNestedImpl + extends io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + N>> + implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + N>, + io.kubernetes.client.fluent.Nested { + ScaleTargetRefNestedImpl( + io.kubernetes.client.openapi.models.V1CrossVersionObjectReference item) { + this.builder = + new io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceBuilder(this, item); } + ScaleTargetRefNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1CrossVersionObjectReferenceBuilder builder; + public N and() { return (N) V1HorizontalPodAutoscalerSpecFluentImpl.this.withScaleTargetRef(builder.build()); } + public N endScaleTargetRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerStatusBuilder.java index 25ce480f8b..03682cc41b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1HorizontalPodAutoscalerStatusBuilder extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1HorizontalPodAutoscalerStatusBuilder + extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluentImpl< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusBuilder> { public V1HorizontalPodAutoscalerStatusBuilder() { this(false); } + public V1HorizontalPodAutoscalerStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1HorizontalPodAutoscalerStatus(), validationEnabled); } - public V1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent fluent) { + + public V1HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent fluent) { this(fluent, false); } - public V1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1HorizontalPodAutoscalerStatus(), validationEnabled); } - public V1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent fluent,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus instance) { + + public V1HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent fluent, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus instance) { this(fluent, instance, false); } - public V1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent fluent,io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent fluent, + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCurrentCPUUtilizationPercentage(instance.getCurrentCPUUtilizationPercentage()); fluent.withCurrentReplicas(instance.getCurrentReplicas()); @@ -31,13 +58,18 @@ public V1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.model fluent.withObservedGeneration(instance.getObservedGeneration()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus instance) { - this(instance,false); + + public V1HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus instance) { + this(instance, false); } - public V1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCurrentCPUUtilizationPercentage(instance.getCurrentCPUUtilizationPercentage()); this.withCurrentReplicas(instance.getCurrentReplicas()); @@ -48,10 +80,12 @@ public V1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.model this.withObservedGeneration(instance.getObservedGeneration()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus build() { V1HorizontalPodAutoscalerStatus buildable = new V1HorizontalPodAutoscalerStatus(); buildable.setCurrentCPUUtilizationPercentage(fluent.getCurrentCPUUtilizationPercentage()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus build buildable.setObservedGeneration(fluent.getObservedGeneration()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1HorizontalPodAutoscalerStatusBuilder that = (V1HorizontalPodAutoscalerStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerStatusFluent.java index ca9958eeb3..b1639d0f72 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerStatusFluent.java @@ -1,31 +1,48 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Long; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1HorizontalPodAutoscalerStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1HorizontalPodAutoscalerStatusFluent< + A extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getCurrentCPUUtilizationPercentage(); + public A withCurrentCPUUtilizationPercentage(java.lang.Integer currentCPUUtilizationPercentage); + public java.lang.Boolean hasCurrentCPUUtilizationPercentage(); + public java.lang.Integer getCurrentReplicas(); + public A withCurrentReplicas(java.lang.Integer currentReplicas); + public java.lang.Boolean hasCurrentReplicas(); + public java.lang.Integer getDesiredReplicas(); + public A withDesiredReplicas(java.lang.Integer desiredReplicas); + public java.lang.Boolean hasDesiredReplicas(); + public java.time.OffsetDateTime getLastScaleTime(); + public A withLastScaleTime(java.time.OffsetDateTime lastScaleTime); + public java.lang.Boolean hasLastScaleTime(); + public java.lang.Long getObservedGeneration(); + public A withObservedGeneration(java.lang.Long observedGeneration); + public java.lang.Boolean hasObservedGeneration(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerStatusFluentImpl.java index b77d5b3787..ab56d66be5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HorizontalPodAutoscalerStatusFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1HorizontalPodAutoscalerStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent { + public V1HorizontalPodAutoscalerStatusFluentImpl() {} - /** - * Generated - */ -public class V1HorizontalPodAutoscalerStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatusFluent{ - public V1HorizontalPodAutoscalerStatusFluentImpl() { - } - public V1HorizontalPodAutoscalerStatusFluentImpl(io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus instance) { + public V1HorizontalPodAutoscalerStatusFluentImpl( + io.kubernetes.client.openapi.models.V1HorizontalPodAutoscalerStatus instance) { this.withCurrentCPUUtilizationPercentage(instance.getCurrentCPUUtilizationPercentage()); this.withCurrentReplicas(instance.getCurrentReplicas()); @@ -23,71 +30,108 @@ public V1HorizontalPodAutoscalerStatusFluentImpl(io.kubernetes.client.openapi.mo this.withLastScaleTime(instance.getLastScaleTime()); this.withObservedGeneration(instance.getObservedGeneration()); - } + private java.lang.Integer currentCPUUtilizationPercentage; private java.lang.Integer currentReplicas; private java.lang.Integer desiredReplicas; private java.time.OffsetDateTime lastScaleTime; private java.lang.Long observedGeneration; + public java.lang.Integer getCurrentCPUUtilizationPercentage() { return this.currentCPUUtilizationPercentage; } + public A withCurrentCPUUtilizationPercentage(java.lang.Integer currentCPUUtilizationPercentage) { - this.currentCPUUtilizationPercentage=currentCPUUtilizationPercentage; return (A) this; + this.currentCPUUtilizationPercentage = currentCPUUtilizationPercentage; + return (A) this; } + public java.lang.Boolean hasCurrentCPUUtilizationPercentage() { return this.currentCPUUtilizationPercentage != null; } + public java.lang.Integer getCurrentReplicas() { return this.currentReplicas; } + public A withCurrentReplicas(java.lang.Integer currentReplicas) { - this.currentReplicas=currentReplicas; return (A) this; + this.currentReplicas = currentReplicas; + return (A) this; } + public java.lang.Boolean hasCurrentReplicas() { return this.currentReplicas != null; } + public java.lang.Integer getDesiredReplicas() { return this.desiredReplicas; } + public A withDesiredReplicas(java.lang.Integer desiredReplicas) { - this.desiredReplicas=desiredReplicas; return (A) this; + this.desiredReplicas = desiredReplicas; + return (A) this; } + public java.lang.Boolean hasDesiredReplicas() { return this.desiredReplicas != null; } + public java.time.OffsetDateTime getLastScaleTime() { return this.lastScaleTime; } + public A withLastScaleTime(java.time.OffsetDateTime lastScaleTime) { - this.lastScaleTime=lastScaleTime; return (A) this; + this.lastScaleTime = lastScaleTime; + return (A) this; } + public java.lang.Boolean hasLastScaleTime() { return this.lastScaleTime != null; } + public java.lang.Long getObservedGeneration() { return this.observedGeneration; } + public A withObservedGeneration(java.lang.Long observedGeneration) { - this.observedGeneration=observedGeneration; return (A) this; + this.observedGeneration = observedGeneration; + return (A) this; } + public java.lang.Boolean hasObservedGeneration() { return this.observedGeneration != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1HorizontalPodAutoscalerStatusFluentImpl that = (V1HorizontalPodAutoscalerStatusFluentImpl) o; - if (currentCPUUtilizationPercentage != null ? !currentCPUUtilizationPercentage.equals(that.currentCPUUtilizationPercentage) :that.currentCPUUtilizationPercentage != null) return false; - if (currentReplicas != null ? !currentReplicas.equals(that.currentReplicas) :that.currentReplicas != null) return false; - if (desiredReplicas != null ? !desiredReplicas.equals(that.desiredReplicas) :that.desiredReplicas != null) return false; - if (lastScaleTime != null ? !lastScaleTime.equals(that.lastScaleTime) :that.lastScaleTime != null) return false; - if (observedGeneration != null ? !observedGeneration.equals(that.observedGeneration) :that.observedGeneration != null) return false; + if (currentCPUUtilizationPercentage != null + ? !currentCPUUtilizationPercentage.equals(that.currentCPUUtilizationPercentage) + : that.currentCPUUtilizationPercentage != null) return false; + if (currentReplicas != null + ? !currentReplicas.equals(that.currentReplicas) + : that.currentReplicas != null) return false; + if (desiredReplicas != null + ? !desiredReplicas.equals(that.desiredReplicas) + : that.desiredReplicas != null) return false; + if (lastScaleTime != null + ? !lastScaleTime.equals(that.lastScaleTime) + : that.lastScaleTime != null) return false; + if (observedGeneration != null + ? !observedGeneration.equals(that.observedGeneration) + : that.observedGeneration != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(currentCPUUtilizationPercentage, currentReplicas, desiredReplicas, lastScaleTime, observedGeneration, super.hashCode()); - } - -} \ No newline at end of file + return java.util.Objects.hash( + currentCPUUtilizationPercentage, + currentReplicas, + desiredReplicas, + lastScaleTime, + observedGeneration, + super.hashCode()); + } +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostAliasBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostAliasBuilder.java index af69c08837..e196ddf65a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostAliasBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostAliasBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1HostAliasBuilder extends io.kubernetes.client.openapi.models.V1HostAliasFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1HostAliasBuilder + extends io.kubernetes.client.openapi.models.V1HostAliasFluentImpl< + io.kubernetes.client.openapi.models.V1HostAliasBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1HostAlias, + io.kubernetes.client.openapi.models.V1HostAliasBuilder> { public V1HostAliasBuilder() { this(false); } + public V1HostAliasBuilder(java.lang.Boolean validationEnabled) { this(new V1HostAlias(), validationEnabled); } + public V1HostAliasBuilder(io.kubernetes.client.openapi.models.V1HostAliasFluent fluent) { this(fluent, false); } - public V1HostAliasBuilder(io.kubernetes.client.openapi.models.V1HostAliasFluent fluent,java.lang.Boolean validationEnabled) { + + public V1HostAliasBuilder( + io.kubernetes.client.openapi.models.V1HostAliasFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1HostAlias(), validationEnabled); } - public V1HostAliasBuilder(io.kubernetes.client.openapi.models.V1HostAliasFluent fluent,io.kubernetes.client.openapi.models.V1HostAlias instance) { + + public V1HostAliasBuilder( + io.kubernetes.client.openapi.models.V1HostAliasFluent fluent, + io.kubernetes.client.openapi.models.V1HostAlias instance) { this(fluent, instance, false); } - public V1HostAliasBuilder(io.kubernetes.client.openapi.models.V1HostAliasFluent fluent,io.kubernetes.client.openapi.models.V1HostAlias instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1HostAliasBuilder( + io.kubernetes.client.openapi.models.V1HostAliasFluent fluent, + io.kubernetes.client.openapi.models.V1HostAlias instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withHostnames(instance.getHostnames()); fluent.withIp(instance.getIp()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1HostAliasBuilder(io.kubernetes.client.openapi.models.V1HostAlias instance) { - this(instance,false); + this(instance, false); } - public V1HostAliasBuilder(io.kubernetes.client.openapi.models.V1HostAlias instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1HostAliasBuilder( + io.kubernetes.client.openapi.models.V1HostAlias instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withHostnames(instance.getHostnames()); this.withIp(instance.getIp()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1HostAliasFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1HostAlias build() { V1HostAlias buildable = new V1HostAlias(); buildable.setHostnames(fluent.getHostnames()); buildable.setIp(fluent.getIp()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1HostAliasBuilder that = (V1HostAliasBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostAliasFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostAliasFluent.java index 42642179ea..4d71f434e7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostAliasFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostAliasFluent.java @@ -1,44 +1,62 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1HostAliasFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToHostnames(java.lang.Integer index,java.lang.String item); - public A setToHostnames(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1HostAliasFluent< + A extends io.kubernetes.client.openapi.models.V1HostAliasFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToHostnames(java.lang.Integer index, java.lang.String item); + + public A setToHostnames(java.lang.Integer index, java.lang.String item); + public A addToHostnames(java.lang.String... items); + public A addAllToHostnames(java.util.Collection items); + public A removeFromHostnames(java.lang.String... items); + public A removeAllFromHostnames(java.util.Collection items); + public java.util.List getHostnames(); + public java.lang.String getHostname(java.lang.Integer index); + public java.lang.String getFirstHostname(); + public java.lang.String getLastHostname(); - public java.lang.String getMatchingHostname(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingHostname(java.util.function.Predicate predicate); + + public java.lang.String getMatchingHostname( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingHostname( + java.util.function.Predicate predicate); + public A withHostnames(java.util.List hostnames); + public A withHostnames(java.lang.String... hostnames); + public java.lang.Boolean hasHostnames(); + public A addNewHostname(java.lang.String original); + public java.lang.String getIp(); + public A withIp(java.lang.String ip); + public java.lang.Boolean hasIp(); - - /** - * Method is deprecated. use withIp instead. - */ + + /** Method is deprecated. use withIp instead. */ @java.lang.Deprecated public A withNewIp(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostAliasFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostAliasFluentImpl.java index c9a5addc75..00d670165e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostAliasFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostAliasFluentImpl.java @@ -1,111 +1,185 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1HostAliasFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1HostAliasFluent{ - public V1HostAliasFluentImpl() { - } +/** Generated */ +public class V1HostAliasFluentImpl< + A extends io.kubernetes.client.openapi.models.V1HostAliasFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1HostAliasFluent { + public V1HostAliasFluentImpl() {} + public V1HostAliasFluentImpl(io.kubernetes.client.openapi.models.V1HostAlias instance) { this.withHostnames(instance.getHostnames()); this.withIp(instance.getIp()); - } + private java.util.List hostnames; private java.lang.String ip; - public A addToHostnames(java.lang.Integer index,java.lang.String item) { - if (this.hostnames == null) {this.hostnames = new java.util.ArrayList();} + + public A addToHostnames(java.lang.Integer index, java.lang.String item) { + if (this.hostnames == null) { + this.hostnames = new java.util.ArrayList(); + } this.hostnames.add(index, item); - return (A)this; + return (A) this; } - public A setToHostnames(java.lang.Integer index,java.lang.String item) { - if (this.hostnames == null) {this.hostnames = new java.util.ArrayList();} - this.hostnames.set(index, item); return (A)this; + + public A setToHostnames(java.lang.Integer index, java.lang.String item) { + if (this.hostnames == null) { + this.hostnames = new java.util.ArrayList(); + } + this.hostnames.set(index, item); + return (A) this; } + public A addToHostnames(java.lang.String... items) { - if (this.hostnames == null) {this.hostnames = new java.util.ArrayList();} - for (java.lang.String item : items) {this.hostnames.add(item);} return (A)this; + if (this.hostnames == null) { + this.hostnames = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.hostnames.add(item); + } + return (A) this; } + public A addAllToHostnames(java.util.Collection items) { - if (this.hostnames == null) {this.hostnames = new java.util.ArrayList();} - for (java.lang.String item : items) {this.hostnames.add(item);} return (A)this; + if (this.hostnames == null) { + this.hostnames = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.hostnames.add(item); + } + return (A) this; } + public A removeFromHostnames(java.lang.String... items) { - for (java.lang.String item : items) {if (this.hostnames!= null){ this.hostnames.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.hostnames != null) { + this.hostnames.remove(item); + } + } + return (A) this; } + public A removeAllFromHostnames(java.util.Collection items) { - for (java.lang.String item : items) {if (this.hostnames!= null){ this.hostnames.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.hostnames != null) { + this.hostnames.remove(item); + } + } + return (A) this; } + public java.util.List getHostnames() { return this.hostnames; } + public java.lang.String getHostname(java.lang.Integer index) { return this.hostnames.get(index); } + public java.lang.String getFirstHostname() { return this.hostnames.get(0); } + public java.lang.String getLastHostname() { return this.hostnames.get(hostnames.size() - 1); } - public java.lang.String getMatchingHostname(java.util.function.Predicate predicate) { - for (java.lang.String item: hostnames) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingHostname( + java.util.function.Predicate predicate) { + for (java.lang.String item : hostnames) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingHostname(java.util.function.Predicate predicate) { - for (java.lang.String item: hostnames) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingHostname( + java.util.function.Predicate predicate) { + for (java.lang.String item : hostnames) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withHostnames(java.util.List hostnames) { - if (hostnames != null) {this.hostnames = new java.util.ArrayList(); for (java.lang.String item : hostnames){this.addToHostnames(item);}} else { this.hostnames = null;} return (A) this; + if (hostnames != null) { + this.hostnames = new java.util.ArrayList(); + for (java.lang.String item : hostnames) { + this.addToHostnames(item); + } + } else { + this.hostnames = null; + } + return (A) this; } + public A withHostnames(java.lang.String... hostnames) { - if (this.hostnames != null) {this.hostnames.clear();} - if (hostnames != null) {for (java.lang.String item :hostnames){ this.addToHostnames(item);}} return (A) this; + if (this.hostnames != null) { + this.hostnames.clear(); + } + if (hostnames != null) { + for (java.lang.String item : hostnames) { + this.addToHostnames(item); + } + } + return (A) this; } + public java.lang.Boolean hasHostnames() { return hostnames != null && !hostnames.isEmpty(); } + public A addNewHostname(java.lang.String original) { - return (A)addToHostnames(new String(original)); + return (A) addToHostnames(new String(original)); } + public java.lang.String getIp() { return this.ip; } + public A withIp(java.lang.String ip) { - this.ip=ip; return (A) this; + this.ip = ip; + return (A) this; } + public java.lang.Boolean hasIp() { return this.ip != null; } - - /** - * Method is deprecated. use withIp instead. - */ + + /** Method is deprecated. use withIp instead. */ @java.lang.Deprecated public A withNewIp(java.lang.String original) { - return (A)withIp(new String(original)); + return (A) withIp(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1HostAliasFluentImpl that = (V1HostAliasFluentImpl) o; - if (hostnames != null ? !hostnames.equals(that.hostnames) :that.hostnames != null) return false; - if (ip != null ? !ip.equals(that.ip) :that.ip != null) return false; + if (hostnames != null ? !hostnames.equals(that.hostnames) : that.hostnames != null) + return false; + if (ip != null ? !ip.equals(that.ip) : that.ip != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(hostnames, ip, super.hashCode()); + return java.util.Objects.hash(hostnames, ip, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostPathVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostPathVolumeSourceBuilder.java index a7d2b86df5..d46a872442 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostPathVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostPathVolumeSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1HostPathVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1HostPathVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1HostPathVolumeSource, + io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder> { public V1HostPathVolumeSourceBuilder() { this(false); } + public V1HostPathVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1HostPathVolumeSource(), validationEnabled); } - public V1HostPathVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent fluent) { + + public V1HostPathVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent fluent) { this(fluent, false); } - public V1HostPathVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1HostPathVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1HostPathVolumeSource(), validationEnabled); } - public V1HostPathVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1HostPathVolumeSource instance) { + + public V1HostPathVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1HostPathVolumeSource instance) { this(fluent, instance, false); } - public V1HostPathVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1HostPathVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1HostPathVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1HostPathVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPath(instance.getPath()); fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1HostPathVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1HostPathVolumeSource instance) { - this(instance,false); + + public V1HostPathVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1HostPathVolumeSource instance) { + this(instance, false); } - public V1HostPathVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1HostPathVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1HostPathVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1HostPathVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPath(instance.getPath()); this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1HostPathVolumeSource build() { V1HostPathVolumeSource buildable = new V1HostPathVolumeSource(); buildable.setPath(fluent.getPath()); buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1HostPathVolumeSourceBuilder that = (V1HostPathVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostPathVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostPathVolumeSourceFluent.java index c8efe9e6bd..250f6d74ff 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostPathVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostPathVolumeSourceFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1HostPathVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1HostPathVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostPathVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostPathVolumeSourceFluentImpl.java index b1948c7b00..a49b8c6f84 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostPathVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1HostPathVolumeSourceFluentImpl.java @@ -1,69 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1HostPathVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent { + public V1HostPathVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1HostPathVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent{ - public V1HostPathVolumeSourceFluentImpl() { - } - public V1HostPathVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1HostPathVolumeSource instance) { + public V1HostPathVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1HostPathVolumeSource instance) { this.withPath(instance.getPath()); this.withType(instance.getType()); - } + private java.lang.String path; private java.lang.String type; + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1HostPathVolumeSourceFluentImpl that = (V1HostPathVolumeSourceFluentImpl) o; - if (path != null ? !path.equals(that.path) :that.path != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(path, type, super.hashCode()); + return java.util.Objects.hash(path, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IPBlockBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IPBlockBuilder.java index 70678b899b..331152381a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IPBlockBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IPBlockBuilder.java @@ -1,63 +1,99 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1IPBlockBuilder extends io.kubernetes.client.openapi.models.V1IPBlockFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1IPBlockBuilder + extends io.kubernetes.client.openapi.models.V1IPBlockFluentImpl< + io.kubernetes.client.openapi.models.V1IPBlockBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1IPBlock, + io.kubernetes.client.openapi.models.V1IPBlockBuilder> { public V1IPBlockBuilder() { this(false); } + public V1IPBlockBuilder(java.lang.Boolean validationEnabled) { this(new V1IPBlock(), validationEnabled); } + public V1IPBlockBuilder(io.kubernetes.client.openapi.models.V1IPBlockFluent fluent) { this(fluent, false); } - public V1IPBlockBuilder(io.kubernetes.client.openapi.models.V1IPBlockFluent fluent,java.lang.Boolean validationEnabled) { + + public V1IPBlockBuilder( + io.kubernetes.client.openapi.models.V1IPBlockFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1IPBlock(), validationEnabled); } - public V1IPBlockBuilder(io.kubernetes.client.openapi.models.V1IPBlockFluent fluent,io.kubernetes.client.openapi.models.V1IPBlock instance) { + + public V1IPBlockBuilder( + io.kubernetes.client.openapi.models.V1IPBlockFluent fluent, + io.kubernetes.client.openapi.models.V1IPBlock instance) { this(fluent, instance, false); } - public V1IPBlockBuilder(io.kubernetes.client.openapi.models.V1IPBlockFluent fluent,io.kubernetes.client.openapi.models.V1IPBlock instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1IPBlockBuilder( + io.kubernetes.client.openapi.models.V1IPBlockFluent fluent, + io.kubernetes.client.openapi.models.V1IPBlock instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCidr(instance.getCidr()); fluent.withExcept(instance.getExcept()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1IPBlockBuilder(io.kubernetes.client.openapi.models.V1IPBlock instance) { - this(instance,false); + this(instance, false); } - public V1IPBlockBuilder(io.kubernetes.client.openapi.models.V1IPBlock instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1IPBlockBuilder( + io.kubernetes.client.openapi.models.V1IPBlock instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCidr(instance.getCidr()); this.withExcept(instance.getExcept()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1IPBlockFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1IPBlock build() { V1IPBlock buildable = new V1IPBlock(); buildable.setCidr(fluent.getCidr()); buildable.setExcept(fluent.getExcept()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1IPBlockBuilder that = (V1IPBlockBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IPBlockFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IPBlockFluent.java index aee8ab5a8f..f4a4cbfde7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IPBlockFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IPBlockFluent.java @@ -1,44 +1,61 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1IPBlockFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1IPBlockFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getCidr(); + public A withCidr(java.lang.String cidr); + public java.lang.Boolean hasCidr(); - - /** - * Method is deprecated. use withCidr instead. - */ + + /** Method is deprecated. use withCidr instead. */ @java.lang.Deprecated public A withNewCidr(java.lang.String original); - public A addToExcept(java.lang.Integer index,java.lang.String item); - public A setToExcept(java.lang.Integer index,java.lang.String item); + + public A addToExcept(java.lang.Integer index, java.lang.String item); + + public A setToExcept(java.lang.Integer index, java.lang.String item); + public A addToExcept(java.lang.String... items); + public A addAllToExcept(java.util.Collection items); + public A removeFromExcept(java.lang.String... items); + public A removeAllFromExcept(java.util.Collection items); + public java.util.List getExcept(); + public java.lang.String getExcept(java.lang.Integer index); + public java.lang.String getFirstExcept(); + public java.lang.String getLastExcept(); - public java.lang.String getMatchingExcept(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingExcept(java.util.function.Predicate predicate); + + public java.lang.String getMatchingExcept( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingExcept( + java.util.function.Predicate predicate); + public A withExcept(java.util.List except); + public A withExcept(java.lang.String... except); + public java.lang.Boolean hasExcept(); + public A addNewExcept(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IPBlockFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IPBlockFluentImpl.java index 38ae25895e..4c62634cbe 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IPBlockFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IPBlockFluentImpl.java @@ -1,111 +1,183 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1IPBlockFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1IPBlockFluent{ - public V1IPBlockFluentImpl() { - } +/** Generated */ +public class V1IPBlockFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1IPBlockFluent { + public V1IPBlockFluentImpl() {} + public V1IPBlockFluentImpl(io.kubernetes.client.openapi.models.V1IPBlock instance) { this.withCidr(instance.getCidr()); this.withExcept(instance.getExcept()); - } + private java.lang.String cidr; private java.util.List except; + public java.lang.String getCidr() { return this.cidr; } + public A withCidr(java.lang.String cidr) { - this.cidr=cidr; return (A) this; + this.cidr = cidr; + return (A) this; } + public java.lang.Boolean hasCidr() { return this.cidr != null; } - - /** - * Method is deprecated. use withCidr instead. - */ + + /** Method is deprecated. use withCidr instead. */ @java.lang.Deprecated public A withNewCidr(java.lang.String original) { - return (A)withCidr(new String(original)); + return (A) withCidr(new String(original)); } - public A addToExcept(java.lang.Integer index,java.lang.String item) { - if (this.except == null) {this.except = new java.util.ArrayList();} + + public A addToExcept(java.lang.Integer index, java.lang.String item) { + if (this.except == null) { + this.except = new java.util.ArrayList(); + } this.except.add(index, item); - return (A)this; + return (A) this; } - public A setToExcept(java.lang.Integer index,java.lang.String item) { - if (this.except == null) {this.except = new java.util.ArrayList();} - this.except.set(index, item); return (A)this; + + public A setToExcept(java.lang.Integer index, java.lang.String item) { + if (this.except == null) { + this.except = new java.util.ArrayList(); + } + this.except.set(index, item); + return (A) this; } + public A addToExcept(java.lang.String... items) { - if (this.except == null) {this.except = new java.util.ArrayList();} - for (java.lang.String item : items) {this.except.add(item);} return (A)this; + if (this.except == null) { + this.except = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.except.add(item); + } + return (A) this; } + public A addAllToExcept(java.util.Collection items) { - if (this.except == null) {this.except = new java.util.ArrayList();} - for (java.lang.String item : items) {this.except.add(item);} return (A)this; + if (this.except == null) { + this.except = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.except.add(item); + } + return (A) this; } + public A removeFromExcept(java.lang.String... items) { - for (java.lang.String item : items) {if (this.except!= null){ this.except.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.except != null) { + this.except.remove(item); + } + } + return (A) this; } + public A removeAllFromExcept(java.util.Collection items) { - for (java.lang.String item : items) {if (this.except!= null){ this.except.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.except != null) { + this.except.remove(item); + } + } + return (A) this; } + public java.util.List getExcept() { return this.except; } + public java.lang.String getExcept(java.lang.Integer index) { return this.except.get(index); } + public java.lang.String getFirstExcept() { return this.except.get(0); } + public java.lang.String getLastExcept() { return this.except.get(except.size() - 1); } - public java.lang.String getMatchingExcept(java.util.function.Predicate predicate) { - for (java.lang.String item: except) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingExcept( + java.util.function.Predicate predicate) { + for (java.lang.String item : except) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingExcept(java.util.function.Predicate predicate) { - for (java.lang.String item: except) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingExcept( + java.util.function.Predicate predicate) { + for (java.lang.String item : except) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withExcept(java.util.List except) { - if (except != null) {this.except = new java.util.ArrayList(); for (java.lang.String item : except){this.addToExcept(item);}} else { this.except = null;} return (A) this; + if (except != null) { + this.except = new java.util.ArrayList(); + for (java.lang.String item : except) { + this.addToExcept(item); + } + } else { + this.except = null; + } + return (A) this; } + public A withExcept(java.lang.String... except) { - if (this.except != null) {this.except.clear();} - if (except != null) {for (java.lang.String item :except){ this.addToExcept(item);}} return (A) this; + if (this.except != null) { + this.except.clear(); + } + if (except != null) { + for (java.lang.String item : except) { + this.addToExcept(item); + } + } + return (A) this; } + public java.lang.Boolean hasExcept() { return except != null && !except.isEmpty(); } + public A addNewExcept(java.lang.String original) { - return (A)addToExcept(new String(original)); + return (A) addToExcept(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1IPBlockFluentImpl that = (V1IPBlockFluentImpl) o; - if (cidr != null ? !cidr.equals(that.cidr) :that.cidr != null) return false; - if (except != null ? !except.equals(that.except) :that.except != null) return false; + if (cidr != null ? !cidr.equals(that.cidr) : that.cidr != null) return false; + if (except != null ? !except.equals(that.except) : that.except != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(cidr, except, super.hashCode()); + return java.util.Objects.hash(cidr, except, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIPersistentVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIPersistentVolumeSourceBuilder.java index 7b5a4fd7ae..3f0207f20e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIPersistentVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIPersistentVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ISCSIPersistentVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ISCSIPersistentVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource, + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceBuilder> { public V1ISCSIPersistentVolumeSourceBuilder() { this(false); } + public V1ISCSIPersistentVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1ISCSIPersistentVolumeSource(), validationEnabled); } - public V1ISCSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent fluent) { + + public V1ISCSIPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent fluent) { this(fluent, false); } - public V1ISCSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ISCSIPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ISCSIPersistentVolumeSource(), validationEnabled); } - public V1ISCSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource instance) { + + public V1ISCSIPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource instance) { this(fluent, instance, false); } - public V1ISCSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ISCSIPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withChapAuthDiscovery(instance.getChapAuthDiscovery()); fluent.withChapAuthSession(instance.getChapAuthSession()); @@ -43,13 +70,18 @@ public V1ISCSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models. fluent.withTargetPortal(instance.getTargetPortal()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ISCSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource instance) { - this(instance,false); + + public V1ISCSIPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource instance) { + this(instance, false); } - public V1ISCSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ISCSIPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withChapAuthDiscovery(instance.getChapAuthDiscovery()); this.withChapAuthSession(instance.getChapAuthSession()); @@ -72,10 +104,12 @@ public V1ISCSIPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models. this.withTargetPortal(instance.getTargetPortal()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource build() { V1ISCSIPersistentVolumeSource buildable = new V1ISCSIPersistentVolumeSource(); buildable.setChapAuthDiscovery(fluent.getChapAuthDiscovery()); @@ -91,18 +125,23 @@ public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource build() buildable.setTargetPortal(fluent.getTargetPortal()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ISCSIPersistentVolumeSourceBuilder that = (V1ISCSIPersistentVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIPersistentVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIPersistentVolumeSourceFluent.java index 481e25ae45..965768b0bf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIPersistentVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIPersistentVolumeSourceFluent.java @@ -1,113 +1,166 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ISCSIPersistentVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ISCSIPersistentVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Boolean getChapAuthDiscovery(); + public A withChapAuthDiscovery(java.lang.Boolean chapAuthDiscovery); + public java.lang.Boolean hasChapAuthDiscovery(); + public java.lang.Boolean getChapAuthSession(); + public A withChapAuthSession(java.lang.Boolean chapAuthSession); + public java.lang.Boolean hasChapAuthSession(); + public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.String getInitiatorName(); + public A withInitiatorName(java.lang.String initiatorName); + public java.lang.Boolean hasInitiatorName(); - - /** - * Method is deprecated. use withInitiatorName instead. - */ + + /** Method is deprecated. use withInitiatorName instead. */ @java.lang.Deprecated public A withNewInitiatorName(java.lang.String original); + public java.lang.String getIqn(); + public A withIqn(java.lang.String iqn); + public java.lang.Boolean hasIqn(); - - /** - * Method is deprecated. use withIqn instead. - */ + + /** Method is deprecated. use withIqn instead. */ @java.lang.Deprecated public A withNewIqn(java.lang.String original); + public java.lang.String getIscsiInterface(); + public A withIscsiInterface(java.lang.String iscsiInterface); + public java.lang.Boolean hasIscsiInterface(); - - /** - * Method is deprecated. use withIscsiInterface instead. - */ + + /** Method is deprecated. use withIscsiInterface instead. */ @java.lang.Deprecated public A withNewIscsiInterface(java.lang.String original); + public java.lang.Integer getLun(); + public A withLun(java.lang.Integer lun); + public java.lang.Boolean hasLun(); - public A addToPortals(java.lang.Integer index,java.lang.String item); - public A setToPortals(java.lang.Integer index,java.lang.String item); + + public A addToPortals(java.lang.Integer index, java.lang.String item); + + public A setToPortals(java.lang.Integer index, java.lang.String item); + public A addToPortals(java.lang.String... items); + public A addAllToPortals(java.util.Collection items); + public A removeFromPortals(java.lang.String... items); + public A removeAllFromPortals(java.util.Collection items); + public java.util.List getPortals(); + public java.lang.String getPortal(java.lang.Integer index); + public java.lang.String getFirstPortal(); + public java.lang.String getLastPortal(); - public java.lang.String getMatchingPortal(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPortal(java.util.function.Predicate predicate); + + public java.lang.String getMatchingPortal( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingPortal( + java.util.function.Predicate predicate); + public A withPortals(java.util.List portals); + public A withPortals(java.lang.String... portals); + public java.lang.Boolean hasPortals(); + public A addNewPortal(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1SecretReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); - public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + public java.lang.String getTargetPortal(); + public A withTargetPortal(java.lang.String targetPortal); + public java.lang.Boolean hasTargetPortal(); - - /** - * Method is deprecated. use withTargetPortal instead. - */ + + /** Method is deprecated. use withTargetPortal instead. */ @java.lang.Deprecated public A withNewTargetPortal(java.lang.String original); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretReferenceFluent>{ + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretReferenceFluent< + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent + .SecretRefNested< + N>> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIPersistentVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIPersistentVolumeSourceFluentImpl.java index 55fb03833b..75da8c3717 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIPersistentVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIPersistentVolumeSourceFluentImpl.java @@ -1,24 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1ISCSIPersistentVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent{ - public V1ISCSIPersistentVolumeSourceFluentImpl() { - } - public V1ISCSIPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource instance) { +/** Generated */ +public class V1ISCSIPersistentVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent { + public V1ISCSIPersistentVolumeSourceFluentImpl() {} + + public V1ISCSIPersistentVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource instance) { this.withChapAuthDiscovery(instance.getChapAuthDiscovery()); this.withChapAuthSession(instance.getChapAuthSession()); @@ -40,8 +42,8 @@ public V1ISCSIPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.mode this.withSecretRef(instance.getSecretRef()); this.withTargetPortal(instance.getTargetPortal()); - } + private java.lang.Boolean chapAuthDiscovery; private java.lang.Boolean chapAuthSession; private java.lang.String fsType; @@ -53,250 +55,401 @@ public V1ISCSIPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.mode private java.lang.Boolean readOnly; private io.kubernetes.client.openapi.models.V1SecretReferenceBuilder secretRef; private java.lang.String targetPortal; + public java.lang.Boolean getChapAuthDiscovery() { return this.chapAuthDiscovery; } + public A withChapAuthDiscovery(java.lang.Boolean chapAuthDiscovery) { - this.chapAuthDiscovery=chapAuthDiscovery; return (A) this; + this.chapAuthDiscovery = chapAuthDiscovery; + return (A) this; } + public java.lang.Boolean hasChapAuthDiscovery() { return this.chapAuthDiscovery != null; } + public java.lang.Boolean getChapAuthSession() { return this.chapAuthSession; } + public A withChapAuthSession(java.lang.Boolean chapAuthSession) { - this.chapAuthSession=chapAuthSession; return (A) this; + this.chapAuthSession = chapAuthSession; + return (A) this; } + public java.lang.Boolean hasChapAuthSession() { return this.chapAuthSession != null; } + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.String getInitiatorName() { return this.initiatorName; } + public A withInitiatorName(java.lang.String initiatorName) { - this.initiatorName=initiatorName; return (A) this; + this.initiatorName = initiatorName; + return (A) this; } + public java.lang.Boolean hasInitiatorName() { return this.initiatorName != null; } - - /** - * Method is deprecated. use withInitiatorName instead. - */ + + /** Method is deprecated. use withInitiatorName instead. */ @java.lang.Deprecated public A withNewInitiatorName(java.lang.String original) { - return (A)withInitiatorName(new String(original)); + return (A) withInitiatorName(new String(original)); } + public java.lang.String getIqn() { return this.iqn; } + public A withIqn(java.lang.String iqn) { - this.iqn=iqn; return (A) this; + this.iqn = iqn; + return (A) this; } + public java.lang.Boolean hasIqn() { return this.iqn != null; } - - /** - * Method is deprecated. use withIqn instead. - */ + + /** Method is deprecated. use withIqn instead. */ @java.lang.Deprecated public A withNewIqn(java.lang.String original) { - return (A)withIqn(new String(original)); + return (A) withIqn(new String(original)); } + public java.lang.String getIscsiInterface() { return this.iscsiInterface; } + public A withIscsiInterface(java.lang.String iscsiInterface) { - this.iscsiInterface=iscsiInterface; return (A) this; + this.iscsiInterface = iscsiInterface; + return (A) this; } + public java.lang.Boolean hasIscsiInterface() { return this.iscsiInterface != null; } - - /** - * Method is deprecated. use withIscsiInterface instead. - */ + + /** Method is deprecated. use withIscsiInterface instead. */ @java.lang.Deprecated public A withNewIscsiInterface(java.lang.String original) { - return (A)withIscsiInterface(new String(original)); + return (A) withIscsiInterface(new String(original)); } + public java.lang.Integer getLun() { return this.lun; } + public A withLun(java.lang.Integer lun) { - this.lun=lun; return (A) this; + this.lun = lun; + return (A) this; } + public java.lang.Boolean hasLun() { return this.lun != null; } - public A addToPortals(java.lang.Integer index,java.lang.String item) { - if (this.portals == null) {this.portals = new java.util.ArrayList();} + + public A addToPortals(java.lang.Integer index, java.lang.String item) { + if (this.portals == null) { + this.portals = new java.util.ArrayList(); + } this.portals.add(index, item); - return (A)this; + return (A) this; } - public A setToPortals(java.lang.Integer index,java.lang.String item) { - if (this.portals == null) {this.portals = new java.util.ArrayList();} - this.portals.set(index, item); return (A)this; + + public A setToPortals(java.lang.Integer index, java.lang.String item) { + if (this.portals == null) { + this.portals = new java.util.ArrayList(); + } + this.portals.set(index, item); + return (A) this; } + public A addToPortals(java.lang.String... items) { - if (this.portals == null) {this.portals = new java.util.ArrayList();} - for (java.lang.String item : items) {this.portals.add(item);} return (A)this; + if (this.portals == null) { + this.portals = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.portals.add(item); + } + return (A) this; } + public A addAllToPortals(java.util.Collection items) { - if (this.portals == null) {this.portals = new java.util.ArrayList();} - for (java.lang.String item : items) {this.portals.add(item);} return (A)this; + if (this.portals == null) { + this.portals = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.portals.add(item); + } + return (A) this; } + public A removeFromPortals(java.lang.String... items) { - for (java.lang.String item : items) {if (this.portals!= null){ this.portals.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.portals != null) { + this.portals.remove(item); + } + } + return (A) this; } + public A removeAllFromPortals(java.util.Collection items) { - for (java.lang.String item : items) {if (this.portals!= null){ this.portals.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.portals != null) { + this.portals.remove(item); + } + } + return (A) this; } + public java.util.List getPortals() { return this.portals; } + public java.lang.String getPortal(java.lang.Integer index) { return this.portals.get(index); } + public java.lang.String getFirstPortal() { return this.portals.get(0); } + public java.lang.String getLastPortal() { return this.portals.get(portals.size() - 1); } - public java.lang.String getMatchingPortal(java.util.function.Predicate predicate) { - for (java.lang.String item: portals) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingPortal( + java.util.function.Predicate predicate) { + for (java.lang.String item : portals) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingPortal(java.util.function.Predicate predicate) { - for (java.lang.String item: portals) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPortal( + java.util.function.Predicate predicate) { + for (java.lang.String item : portals) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withPortals(java.util.List portals) { - if (portals != null) {this.portals = new java.util.ArrayList(); for (java.lang.String item : portals){this.addToPortals(item);}} else { this.portals = null;} return (A) this; + if (portals != null) { + this.portals = new java.util.ArrayList(); + for (java.lang.String item : portals) { + this.addToPortals(item); + } + } else { + this.portals = null; + } + return (A) this; } + public A withPortals(java.lang.String... portals) { - if (this.portals != null) {this.portals.clear();} - if (portals != null) {for (java.lang.String item :portals){ this.addToPortals(item);}} return (A) this; + if (this.portals != null) { + this.portals.clear(); + } + if (portals != null) { + for (java.lang.String item : portals) { + this.addToPortals(item); + } + } + return (A) this; } + public java.lang.Boolean hasPortals() { return portals != null && !portals.isEmpty(); } + public A addNewPortal(java.lang.String original) { - return (A)addToPortals(new String(original)); + return (A) addToPortals(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return new io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return new io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public java.lang.String getTargetPortal() { return this.targetPortal; } + public A withTargetPortal(java.lang.String targetPortal) { - this.targetPortal=targetPortal; return (A) this; + this.targetPortal = targetPortal; + return (A) this; } + public java.lang.Boolean hasTargetPortal() { return this.targetPortal != null; } - - /** - * Method is deprecated. use withTargetPortal instead. - */ + + /** Method is deprecated. use withTargetPortal instead. */ @java.lang.Deprecated public A withNewTargetPortal(java.lang.String original) { - return (A)withTargetPortal(new String(original)); + return (A) withTargetPortal(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ISCSIPersistentVolumeSourceFluentImpl that = (V1ISCSIPersistentVolumeSourceFluentImpl) o; - if (chapAuthDiscovery != null ? !chapAuthDiscovery.equals(that.chapAuthDiscovery) :that.chapAuthDiscovery != null) return false; - if (chapAuthSession != null ? !chapAuthSession.equals(that.chapAuthSession) :that.chapAuthSession != null) return false; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (initiatorName != null ? !initiatorName.equals(that.initiatorName) :that.initiatorName != null) return false; - if (iqn != null ? !iqn.equals(that.iqn) :that.iqn != null) return false; - if (iscsiInterface != null ? !iscsiInterface.equals(that.iscsiInterface) :that.iscsiInterface != null) return false; - if (lun != null ? !lun.equals(that.lun) :that.lun != null) return false; - if (portals != null ? !portals.equals(that.portals) :that.portals != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; - if (targetPortal != null ? !targetPortal.equals(that.targetPortal) :that.targetPortal != null) return false; + if (chapAuthDiscovery != null + ? !chapAuthDiscovery.equals(that.chapAuthDiscovery) + : that.chapAuthDiscovery != null) return false; + if (chapAuthSession != null + ? !chapAuthSession.equals(that.chapAuthSession) + : that.chapAuthSession != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (initiatorName != null + ? !initiatorName.equals(that.initiatorName) + : that.initiatorName != null) return false; + if (iqn != null ? !iqn.equals(that.iqn) : that.iqn != null) return false; + if (iscsiInterface != null + ? !iscsiInterface.equals(that.iscsiInterface) + : that.iscsiInterface != null) return false; + if (lun != null ? !lun.equals(that.lun) : that.lun != null) return false; + if (portals != null ? !portals.equals(that.portals) : that.portals != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; + if (targetPortal != null ? !targetPortal.equals(that.targetPortal) : that.targetPortal != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(chapAuthDiscovery, chapAuthSession, fsType, initiatorName, iqn, iscsiInterface, lun, portals, readOnly, secretRef, targetPortal, super.hashCode()); + return java.util.Objects.hash( + chapAuthDiscovery, + chapAuthSession, + fsType, + initiatorName, + iqn, + iscsiInterface, + lun, + portals, + readOnly, + secretRef, + targetPortal, + super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent.SecretRefNested< + N>> + implements io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent + .SecretRefNested< + N>, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1SecretReference item) { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretReferenceBuilder builder; + public N and() { return (N) V1ISCSIPersistentVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIVolumeSourceBuilder.java index e99c15c8d7..316ae6e3b5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ISCSIVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ISCSIVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ISCSIVolumeSource, + io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceBuilder> { public V1ISCSIVolumeSourceBuilder() { this(false); } + public V1ISCSIVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1ISCSIVolumeSource(), validationEnabled); } - public V1ISCSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent fluent) { + + public V1ISCSIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent fluent) { this(fluent, false); } - public V1ISCSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ISCSIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ISCSIVolumeSource(), validationEnabled); } - public V1ISCSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1ISCSIVolumeSource instance) { + + public V1ISCSIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ISCSIVolumeSource instance) { this(fluent, instance, false); } - public V1ISCSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1ISCSIVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ISCSIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ISCSIVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withChapAuthDiscovery(instance.getChapAuthDiscovery()); fluent.withChapAuthSession(instance.getChapAuthSession()); @@ -43,13 +70,18 @@ public V1ISCSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIVol fluent.withTargetPortal(instance.getTargetPortal()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ISCSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIVolumeSource instance) { - this(instance,false); + + public V1ISCSIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ISCSIVolumeSource instance) { + this(instance, false); } - public V1ISCSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ISCSIVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ISCSIVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withChapAuthDiscovery(instance.getChapAuthDiscovery()); this.withChapAuthSession(instance.getChapAuthSession()); @@ -72,10 +104,12 @@ public V1ISCSIVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ISCSIVol this.withTargetPortal(instance.getTargetPortal()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ISCSIVolumeSource build() { V1ISCSIVolumeSource buildable = new V1ISCSIVolumeSource(); buildable.setChapAuthDiscovery(fluent.getChapAuthDiscovery()); @@ -91,18 +125,23 @@ public io.kubernetes.client.openapi.models.V1ISCSIVolumeSource build() { buildable.setTargetPortal(fluent.getTargetPortal()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ISCSIVolumeSourceBuilder that = (V1ISCSIVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIVolumeSourceFluent.java index 35df6dbaa8..9056371e27 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIVolumeSourceFluent.java @@ -1,113 +1,164 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ISCSIVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ISCSIVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Boolean getChapAuthDiscovery(); + public A withChapAuthDiscovery(java.lang.Boolean chapAuthDiscovery); + public java.lang.Boolean hasChapAuthDiscovery(); + public java.lang.Boolean getChapAuthSession(); + public A withChapAuthSession(java.lang.Boolean chapAuthSession); + public java.lang.Boolean hasChapAuthSession(); + public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.String getInitiatorName(); + public A withInitiatorName(java.lang.String initiatorName); + public java.lang.Boolean hasInitiatorName(); - - /** - * Method is deprecated. use withInitiatorName instead. - */ + + /** Method is deprecated. use withInitiatorName instead. */ @java.lang.Deprecated public A withNewInitiatorName(java.lang.String original); + public java.lang.String getIqn(); + public A withIqn(java.lang.String iqn); + public java.lang.Boolean hasIqn(); - - /** - * Method is deprecated. use withIqn instead. - */ + + /** Method is deprecated. use withIqn instead. */ @java.lang.Deprecated public A withNewIqn(java.lang.String original); + public java.lang.String getIscsiInterface(); + public A withIscsiInterface(java.lang.String iscsiInterface); + public java.lang.Boolean hasIscsiInterface(); - - /** - * Method is deprecated. use withIscsiInterface instead. - */ + + /** Method is deprecated. use withIscsiInterface instead. */ @java.lang.Deprecated public A withNewIscsiInterface(java.lang.String original); + public java.lang.Integer getLun(); + public A withLun(java.lang.Integer lun); + public java.lang.Boolean hasLun(); - public A addToPortals(java.lang.Integer index,java.lang.String item); - public A setToPortals(java.lang.Integer index,java.lang.String item); + + public A addToPortals(java.lang.Integer index, java.lang.String item); + + public A setToPortals(java.lang.Integer index, java.lang.String item); + public A addToPortals(java.lang.String... items); + public A addAllToPortals(java.util.Collection items); + public A removeFromPortals(java.lang.String... items); + public A removeAllFromPortals(java.util.Collection items); + public java.util.List getPortals(); + public java.lang.String getPortal(java.lang.Integer index); + public java.lang.String getFirstPortal(); + public java.lang.String getLastPortal(); - public java.lang.String getMatchingPortal(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPortal(java.util.function.Predicate predicate); + + public java.lang.String getMatchingPortal( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingPortal( + java.util.function.Predicate predicate); + public A withPortals(java.util.List portals); + public A withPortals(java.lang.String... portals); + public java.lang.Boolean hasPortals(); + public A addNewPortal(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + public java.lang.String getTargetPortal(); + public A withTargetPortal(java.lang.String targetPortal); + public java.lang.Boolean hasTargetPortal(); - - /** - * Method is deprecated. use withTargetPortal instead. - */ + + /** Method is deprecated. use withTargetPortal instead. */ @java.lang.Deprecated public A withNewTargetPortal(java.lang.String original); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent>{ + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIVolumeSourceFluentImpl.java index 2d4d1326a5..65426850c9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ISCSIVolumeSourceFluentImpl.java @@ -1,24 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1ISCSIVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent{ - public V1ISCSIVolumeSourceFluentImpl() { - } - public V1ISCSIVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1ISCSIVolumeSource instance) { +/** Generated */ +public class V1ISCSIVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent { + public V1ISCSIVolumeSourceFluentImpl() {} + + public V1ISCSIVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1ISCSIVolumeSource instance) { this.withChapAuthDiscovery(instance.getChapAuthDiscovery()); this.withChapAuthSession(instance.getChapAuthSession()); @@ -40,8 +42,8 @@ public V1ISCSIVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1ISCSI this.withSecretRef(instance.getSecretRef()); this.withTargetPortal(instance.getTargetPortal()); - } + private java.lang.Boolean chapAuthDiscovery; private java.lang.Boolean chapAuthSession; private java.lang.String fsType; @@ -53,250 +55,400 @@ public V1ISCSIVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1ISCSI private java.lang.Boolean readOnly; private io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder secretRef; private java.lang.String targetPortal; + public java.lang.Boolean getChapAuthDiscovery() { return this.chapAuthDiscovery; } + public A withChapAuthDiscovery(java.lang.Boolean chapAuthDiscovery) { - this.chapAuthDiscovery=chapAuthDiscovery; return (A) this; + this.chapAuthDiscovery = chapAuthDiscovery; + return (A) this; } + public java.lang.Boolean hasChapAuthDiscovery() { return this.chapAuthDiscovery != null; } + public java.lang.Boolean getChapAuthSession() { return this.chapAuthSession; } + public A withChapAuthSession(java.lang.Boolean chapAuthSession) { - this.chapAuthSession=chapAuthSession; return (A) this; + this.chapAuthSession = chapAuthSession; + return (A) this; } + public java.lang.Boolean hasChapAuthSession() { return this.chapAuthSession != null; } + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.String getInitiatorName() { return this.initiatorName; } + public A withInitiatorName(java.lang.String initiatorName) { - this.initiatorName=initiatorName; return (A) this; + this.initiatorName = initiatorName; + return (A) this; } + public java.lang.Boolean hasInitiatorName() { return this.initiatorName != null; } - - /** - * Method is deprecated. use withInitiatorName instead. - */ + + /** Method is deprecated. use withInitiatorName instead. */ @java.lang.Deprecated public A withNewInitiatorName(java.lang.String original) { - return (A)withInitiatorName(new String(original)); + return (A) withInitiatorName(new String(original)); } + public java.lang.String getIqn() { return this.iqn; } + public A withIqn(java.lang.String iqn) { - this.iqn=iqn; return (A) this; + this.iqn = iqn; + return (A) this; } + public java.lang.Boolean hasIqn() { return this.iqn != null; } - - /** - * Method is deprecated. use withIqn instead. - */ + + /** Method is deprecated. use withIqn instead. */ @java.lang.Deprecated public A withNewIqn(java.lang.String original) { - return (A)withIqn(new String(original)); + return (A) withIqn(new String(original)); } + public java.lang.String getIscsiInterface() { return this.iscsiInterface; } + public A withIscsiInterface(java.lang.String iscsiInterface) { - this.iscsiInterface=iscsiInterface; return (A) this; + this.iscsiInterface = iscsiInterface; + return (A) this; } + public java.lang.Boolean hasIscsiInterface() { return this.iscsiInterface != null; } - - /** - * Method is deprecated. use withIscsiInterface instead. - */ + + /** Method is deprecated. use withIscsiInterface instead. */ @java.lang.Deprecated public A withNewIscsiInterface(java.lang.String original) { - return (A)withIscsiInterface(new String(original)); + return (A) withIscsiInterface(new String(original)); } + public java.lang.Integer getLun() { return this.lun; } + public A withLun(java.lang.Integer lun) { - this.lun=lun; return (A) this; + this.lun = lun; + return (A) this; } + public java.lang.Boolean hasLun() { return this.lun != null; } - public A addToPortals(java.lang.Integer index,java.lang.String item) { - if (this.portals == null) {this.portals = new java.util.ArrayList();} + + public A addToPortals(java.lang.Integer index, java.lang.String item) { + if (this.portals == null) { + this.portals = new java.util.ArrayList(); + } this.portals.add(index, item); - return (A)this; + return (A) this; } - public A setToPortals(java.lang.Integer index,java.lang.String item) { - if (this.portals == null) {this.portals = new java.util.ArrayList();} - this.portals.set(index, item); return (A)this; + + public A setToPortals(java.lang.Integer index, java.lang.String item) { + if (this.portals == null) { + this.portals = new java.util.ArrayList(); + } + this.portals.set(index, item); + return (A) this; } + public A addToPortals(java.lang.String... items) { - if (this.portals == null) {this.portals = new java.util.ArrayList();} - for (java.lang.String item : items) {this.portals.add(item);} return (A)this; + if (this.portals == null) { + this.portals = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.portals.add(item); + } + return (A) this; } + public A addAllToPortals(java.util.Collection items) { - if (this.portals == null) {this.portals = new java.util.ArrayList();} - for (java.lang.String item : items) {this.portals.add(item);} return (A)this; + if (this.portals == null) { + this.portals = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.portals.add(item); + } + return (A) this; } + public A removeFromPortals(java.lang.String... items) { - for (java.lang.String item : items) {if (this.portals!= null){ this.portals.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.portals != null) { + this.portals.remove(item); + } + } + return (A) this; } + public A removeAllFromPortals(java.util.Collection items) { - for (java.lang.String item : items) {if (this.portals!= null){ this.portals.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.portals != null) { + this.portals.remove(item); + } + } + return (A) this; } + public java.util.List getPortals() { return this.portals; } + public java.lang.String getPortal(java.lang.Integer index) { return this.portals.get(index); } + public java.lang.String getFirstPortal() { return this.portals.get(0); } + public java.lang.String getLastPortal() { return this.portals.get(portals.size() - 1); } - public java.lang.String getMatchingPortal(java.util.function.Predicate predicate) { - for (java.lang.String item: portals) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingPortal( + java.util.function.Predicate predicate) { + for (java.lang.String item : portals) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingPortal(java.util.function.Predicate predicate) { - for (java.lang.String item: portals) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPortal( + java.util.function.Predicate predicate) { + for (java.lang.String item : portals) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withPortals(java.util.List portals) { - if (portals != null) {this.portals = new java.util.ArrayList(); for (java.lang.String item : portals){this.addToPortals(item);}} else { this.portals = null;} return (A) this; + if (portals != null) { + this.portals = new java.util.ArrayList(); + for (java.lang.String item : portals) { + this.addToPortals(item); + } + } else { + this.portals = null; + } + return (A) this; } + public A withPortals(java.lang.String... portals) { - if (this.portals != null) {this.portals.clear();} - if (portals != null) {for (java.lang.String item :portals){ this.addToPortals(item);}} return (A) this; + if (this.portals != null) { + this.portals.clear(); + } + if (portals != null) { + for (java.lang.String item : portals) { + this.addToPortals(item); + } + } + return (A) this; } + public java.lang.Boolean hasPortals() { return portals != null && !portals.isEmpty(); } + public A addNewPortal(java.lang.String original) { - return (A)addToPortals(new String(original)); + return (A) addToPortals(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluentImpl + .SecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public java.lang.String getTargetPortal() { return this.targetPortal; } + public A withTargetPortal(java.lang.String targetPortal) { - this.targetPortal=targetPortal; return (A) this; + this.targetPortal = targetPortal; + return (A) this; } + public java.lang.Boolean hasTargetPortal() { return this.targetPortal != null; } - - /** - * Method is deprecated. use withTargetPortal instead. - */ + + /** Method is deprecated. use withTargetPortal instead. */ @java.lang.Deprecated public A withNewTargetPortal(java.lang.String original) { - return (A)withTargetPortal(new String(original)); + return (A) withTargetPortal(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ISCSIVolumeSourceFluentImpl that = (V1ISCSIVolumeSourceFluentImpl) o; - if (chapAuthDiscovery != null ? !chapAuthDiscovery.equals(that.chapAuthDiscovery) :that.chapAuthDiscovery != null) return false; - if (chapAuthSession != null ? !chapAuthSession.equals(that.chapAuthSession) :that.chapAuthSession != null) return false; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (initiatorName != null ? !initiatorName.equals(that.initiatorName) :that.initiatorName != null) return false; - if (iqn != null ? !iqn.equals(that.iqn) :that.iqn != null) return false; - if (iscsiInterface != null ? !iscsiInterface.equals(that.iscsiInterface) :that.iscsiInterface != null) return false; - if (lun != null ? !lun.equals(that.lun) :that.lun != null) return false; - if (portals != null ? !portals.equals(that.portals) :that.portals != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; - if (targetPortal != null ? !targetPortal.equals(that.targetPortal) :that.targetPortal != null) return false; + if (chapAuthDiscovery != null + ? !chapAuthDiscovery.equals(that.chapAuthDiscovery) + : that.chapAuthDiscovery != null) return false; + if (chapAuthSession != null + ? !chapAuthSession.equals(that.chapAuthSession) + : that.chapAuthSession != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (initiatorName != null + ? !initiatorName.equals(that.initiatorName) + : that.initiatorName != null) return false; + if (iqn != null ? !iqn.equals(that.iqn) : that.iqn != null) return false; + if (iscsiInterface != null + ? !iscsiInterface.equals(that.iscsiInterface) + : that.iscsiInterface != null) return false; + if (lun != null ? !lun.equals(that.lun) : that.lun != null) return false; + if (portals != null ? !portals.equals(that.portals) : that.portals != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; + if (targetPortal != null ? !targetPortal.equals(that.targetPortal) : that.targetPortal != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(chapAuthDiscovery, chapAuthSession, fsType, initiatorName, iqn, iscsiInterface, lun, portals, readOnly, secretRef, targetPortal, super.hashCode()); + return java.util.Objects.hash( + chapAuthDiscovery, + chapAuthSession, + fsType, + initiatorName, + iqn, + iscsiInterface, + lun, + portals, + readOnly, + secretRef, + targetPortal, + super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested> + implements io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent.SecretRefNested, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder; + public N and() { return (N) V1ISCSIVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBackendBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBackendBuilder.java index 2e95206d74..79c7df55a7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBackendBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBackendBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1IngressBackendBuilder extends io.kubernetes.client.openapi.models.V1IngressBackendFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1IngressBackendBuilder + extends io.kubernetes.client.openapi.models.V1IngressBackendFluentImpl< + io.kubernetes.client.openapi.models.V1IngressBackendBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1IngressBackend, + io.kubernetes.client.openapi.models.V1IngressBackendBuilder> { public V1IngressBackendBuilder() { this(false); } + public V1IngressBackendBuilder(java.lang.Boolean validationEnabled) { this(new V1IngressBackend(), validationEnabled); } - public V1IngressBackendBuilder(io.kubernetes.client.openapi.models.V1IngressBackendFluent fluent) { + + public V1IngressBackendBuilder( + io.kubernetes.client.openapi.models.V1IngressBackendFluent fluent) { this(fluent, false); } - public V1IngressBackendBuilder(io.kubernetes.client.openapi.models.V1IngressBackendFluent fluent,java.lang.Boolean validationEnabled) { + + public V1IngressBackendBuilder( + io.kubernetes.client.openapi.models.V1IngressBackendFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1IngressBackend(), validationEnabled); } - public V1IngressBackendBuilder(io.kubernetes.client.openapi.models.V1IngressBackendFluent fluent,io.kubernetes.client.openapi.models.V1IngressBackend instance) { + + public V1IngressBackendBuilder( + io.kubernetes.client.openapi.models.V1IngressBackendFluent fluent, + io.kubernetes.client.openapi.models.V1IngressBackend instance) { this(fluent, instance, false); } - public V1IngressBackendBuilder(io.kubernetes.client.openapi.models.V1IngressBackendFluent fluent,io.kubernetes.client.openapi.models.V1IngressBackend instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1IngressBackendBuilder( + io.kubernetes.client.openapi.models.V1IngressBackendFluent fluent, + io.kubernetes.client.openapi.models.V1IngressBackend instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withResource(instance.getResource()); fluent.withService(instance.getService()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1IngressBackendBuilder(io.kubernetes.client.openapi.models.V1IngressBackend instance) { - this(instance,false); + this(instance, false); } - public V1IngressBackendBuilder(io.kubernetes.client.openapi.models.V1IngressBackend instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1IngressBackendBuilder( + io.kubernetes.client.openapi.models.V1IngressBackend instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withResource(instance.getResource()); this.withService(instance.getService()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1IngressBackendFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1IngressBackend build() { V1IngressBackend buildable = new V1IngressBackend(); buildable.setResource(fluent.getResource()); buildable.setService(fluent.getService()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1IngressBackendBuilder that = (V1IngressBackendBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBackendFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBackendFluent.java index c1d49eca05..ca0b41cc47 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBackendFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBackendFluent.java @@ -1,55 +1,94 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1IngressBackendFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1IngressBackendFluent< + A extends io.kubernetes.client.openapi.models.V1IngressBackendFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference getResource(); + public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference buildResource(); + public A withResource(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference resource); + public java.lang.Boolean hasResource(); - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested withNewResource(); - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item); - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested editResource(); - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested editOrNewResource(); - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item); - + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested + withNewResource(); + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested + editResource(); + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested + editOrNewResource(); + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item); + /** * This method has been deprecated, please use method buildService instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressServiceBackend getService(); + public io.kubernetes.client.openapi.models.V1IngressServiceBackend buildService(); + public A withService(io.kubernetes.client.openapi.models.V1IngressServiceBackend service); + public java.lang.Boolean hasService(); - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested withNewService(); - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested withNewServiceLike(io.kubernetes.client.openapi.models.V1IngressServiceBackend item); + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested + withNewService(); + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested + withNewServiceLike(io.kubernetes.client.openapi.models.V1IngressServiceBackend item); + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested editService(); - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested editOrNewService(); - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested editOrNewServiceLike(io.kubernetes.client.openapi.models.V1IngressServiceBackend item); - public interface ResourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent>{ + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested + editOrNewService(); + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested + editOrNewServiceLike(io.kubernetes.client.openapi.models.V1IngressServiceBackend item); + + public interface ResourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested> { public N and(); + public N endResource(); - } - public interface ServiceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent>{ + + public interface ServiceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent< + io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested> { public N and(); + public N endService(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBackendFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBackendFluentImpl.java index 093801a498..7a6f9e98f2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBackendFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBackendFluentImpl.java @@ -1,135 +1,207 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1IngressBackendFluentImpl< + A extends io.kubernetes.client.openapi.models.V1IngressBackendFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1IngressBackendFluent { + public V1IngressBackendFluentImpl() {} - /** - * Generated - */ -public class V1IngressBackendFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1IngressBackendFluent{ - public V1IngressBackendFluentImpl() { - } public V1IngressBackendFluentImpl(io.kubernetes.client.openapi.models.V1IngressBackend instance) { this.withResource(instance.getResource()); this.withService(instance.getService()); - } + private io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder resource; private io.kubernetes.client.openapi.models.V1IngressServiceBackendBuilder service; - + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference getResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference buildResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public A withResource(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference resource) { _visitables.get("resource").remove(this.resource); - if (resource!=null){ this.resource= new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(resource); _visitables.get("resource").add(this.resource);} return (A) this; + if (resource != null) { + this.resource = + new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(resource); + _visitables.get("resource").add(this.resource); + } + return (A) this; } + public java.lang.Boolean hasResource() { return this.resource != null; } - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested withNewResource() { + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested + withNewResource() { return new io.kubernetes.client.openapi.models.V1IngressBackendFluentImpl.ResourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1IngressBackendFluentImpl.ResourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1IngressBackendFluentImpl.ResourceNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested editResource() { + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested + editResource() { return withNewResourceLike(getResource()); } - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested editOrNewResource() { - return withNewResourceLike(getResource() != null ? getResource(): new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested + editOrNewResource() { + return withNewResourceLike( + getResource() != null + ? getResource() + : new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { - return withNewResourceLike(getResource() != null ? getResource(): item); + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { + return withNewResourceLike(getResource() != null ? getResource() : item); } - + /** * This method has been deprecated, please use method buildService instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressServiceBackend getService() { - return this.service!=null ?this.service.build():null; + return this.service != null ? this.service.build() : null; } + public io.kubernetes.client.openapi.models.V1IngressServiceBackend buildService() { - return this.service!=null ?this.service.build():null; + return this.service != null ? this.service.build() : null; } + public A withService(io.kubernetes.client.openapi.models.V1IngressServiceBackend service) { _visitables.get("service").remove(this.service); - if (service!=null){ this.service= new io.kubernetes.client.openapi.models.V1IngressServiceBackendBuilder(service); _visitables.get("service").add(this.service);} return (A) this; + if (service != null) { + this.service = + new io.kubernetes.client.openapi.models.V1IngressServiceBackendBuilder(service); + _visitables.get("service").add(this.service); + } + return (A) this; } + public java.lang.Boolean hasService() { return this.service != null; } - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested withNewService() { + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested + withNewService() { return new io.kubernetes.client.openapi.models.V1IngressBackendFluentImpl.ServiceNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested withNewServiceLike(io.kubernetes.client.openapi.models.V1IngressServiceBackend item) { - return new io.kubernetes.client.openapi.models.V1IngressBackendFluentImpl.ServiceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested + withNewServiceLike(io.kubernetes.client.openapi.models.V1IngressServiceBackend item) { + return new io.kubernetes.client.openapi.models.V1IngressBackendFluentImpl.ServiceNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested editService() { return withNewServiceLike(getService()); } - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested editOrNewService() { - return withNewServiceLike(getService() != null ? getService(): new io.kubernetes.client.openapi.models.V1IngressServiceBackendBuilder().build()); + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested + editOrNewService() { + return withNewServiceLike( + getService() != null + ? getService() + : new io.kubernetes.client.openapi.models.V1IngressServiceBackendBuilder().build()); } - public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested editOrNewServiceLike(io.kubernetes.client.openapi.models.V1IngressServiceBackend item) { - return withNewServiceLike(getService() != null ? getService(): item); + + public io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested + editOrNewServiceLike(io.kubernetes.client.openapi.models.V1IngressServiceBackend item) { + return withNewServiceLike(getService() != null ? getService() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1IngressBackendFluentImpl that = (V1IngressBackendFluentImpl) o; - if (resource != null ? !resource.equals(that.resource) :that.resource != null) return false; - if (service != null ? !service.equals(that.service) :that.service != null) return false; + if (resource != null ? !resource.equals(that.resource) : that.resource != null) return false; + if (service != null ? !service.equals(that.service) : that.service != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(resource, service, super.hashCode()); + return java.util.Objects.hash(resource, service, super.hashCode()); } - public class ResourceNestedImpl extends io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested,io.kubernetes.client.fluent.Nested{ + + public class ResourceNestedImpl + extends io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested> + implements io.kubernetes.client.openapi.models.V1IngressBackendFluent.ResourceNested, + io.kubernetes.client.fluent.Nested { ResourceNestedImpl(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(this, item); } + ResourceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder builder; + public N and() { return (N) V1IngressBackendFluentImpl.this.withResource(builder.build()); } + public N endResource() { return and(); } - } - public class ServiceNestedImpl extends io.kubernetes.client.openapi.models.V1IngressServiceBackendFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested,io.kubernetes.client.fluent.Nested{ + + public class ServiceNestedImpl + extends io.kubernetes.client.openapi.models.V1IngressServiceBackendFluentImpl< + io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested> + implements io.kubernetes.client.openapi.models.V1IngressBackendFluent.ServiceNested, + io.kubernetes.client.fluent.Nested { ServiceNestedImpl(io.kubernetes.client.openapi.models.V1IngressServiceBackend item) { - this.builder = new io.kubernetes.client.openapi.models.V1IngressServiceBackendBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1IngressServiceBackendBuilder(this, item); } + ServiceNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1IngressServiceBackendBuilder(this); } + io.kubernetes.client.openapi.models.V1IngressServiceBackendBuilder builder; + public N and() { return (N) V1IngressBackendFluentImpl.this.withService(builder.build()); } + public N endService() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBuilder.java index a8e5412818..ac19c259f6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1IngressBuilder extends io.kubernetes.client.openapi.models.V1IngressFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1IngressBuilder + extends io.kubernetes.client.openapi.models.V1IngressFluentImpl< + io.kubernetes.client.openapi.models.V1IngressBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Ingress, + io.kubernetes.client.openapi.models.V1IngressBuilder> { public V1IngressBuilder() { this(false); } + public V1IngressBuilder(java.lang.Boolean validationEnabled) { this(new V1Ingress(), validationEnabled); } + public V1IngressBuilder(io.kubernetes.client.openapi.models.V1IngressFluent fluent) { this(fluent, false); } - public V1IngressBuilder(io.kubernetes.client.openapi.models.V1IngressFluent fluent,java.lang.Boolean validationEnabled) { + + public V1IngressBuilder( + io.kubernetes.client.openapi.models.V1IngressFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Ingress(), validationEnabled); } - public V1IngressBuilder(io.kubernetes.client.openapi.models.V1IngressFluent fluent,io.kubernetes.client.openapi.models.V1Ingress instance) { + + public V1IngressBuilder( + io.kubernetes.client.openapi.models.V1IngressFluent fluent, + io.kubernetes.client.openapi.models.V1Ingress instance) { this(fluent, instance, false); } - public V1IngressBuilder(io.kubernetes.client.openapi.models.V1IngressFluent fluent,io.kubernetes.client.openapi.models.V1Ingress instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1IngressBuilder( + io.kubernetes.client.openapi.models.V1IngressFluent fluent, + io.kubernetes.client.openapi.models.V1Ingress instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,16 @@ public V1IngressBuilder(io.kubernetes.client.openapi.models.V1IngressFluent f fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1IngressBuilder(io.kubernetes.client.openapi.models.V1Ingress instance) { - this(instance,false); + this(instance, false); } - public V1IngressBuilder(io.kubernetes.client.openapi.models.V1Ingress instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1IngressBuilder( + io.kubernetes.client.openapi.models.V1Ingress instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +77,12 @@ public V1IngressBuilder(io.kubernetes.client.openapi.models.V1Ingress instance,j this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1IngressFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Ingress build() { V1Ingress buildable = new V1Ingress(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +92,23 @@ public io.kubernetes.client.openapi.models.V1Ingress build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1IngressBuilder that = (V1IngressBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassBuilder.java index 86c60771f8..4394d818e9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1IngressClassBuilder extends io.kubernetes.client.openapi.models.V1IngressClassFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1IngressClassBuilder + extends io.kubernetes.client.openapi.models.V1IngressClassFluentImpl< + io.kubernetes.client.openapi.models.V1IngressClassBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1IngressClass, + io.kubernetes.client.openapi.models.V1IngressClassBuilder> { public V1IngressClassBuilder() { this(false); } + public V1IngressClassBuilder(java.lang.Boolean validationEnabled) { this(new V1IngressClass(), validationEnabled); } + public V1IngressClassBuilder(io.kubernetes.client.openapi.models.V1IngressClassFluent fluent) { this(fluent, false); } - public V1IngressClassBuilder(io.kubernetes.client.openapi.models.V1IngressClassFluent fluent,java.lang.Boolean validationEnabled) { + + public V1IngressClassBuilder( + io.kubernetes.client.openapi.models.V1IngressClassFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1IngressClass(), validationEnabled); } - public V1IngressClassBuilder(io.kubernetes.client.openapi.models.V1IngressClassFluent fluent,io.kubernetes.client.openapi.models.V1IngressClass instance) { + + public V1IngressClassBuilder( + io.kubernetes.client.openapi.models.V1IngressClassFluent fluent, + io.kubernetes.client.openapi.models.V1IngressClass instance) { this(fluent, instance, false); } - public V1IngressClassBuilder(io.kubernetes.client.openapi.models.V1IngressClassFluent fluent,io.kubernetes.client.openapi.models.V1IngressClass instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1IngressClassBuilder( + io.kubernetes.client.openapi.models.V1IngressClassFluent fluent, + io.kubernetes.client.openapi.models.V1IngressClass instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +55,17 @@ public V1IngressClassBuilder(io.kubernetes.client.openapi.models.V1IngressClassF fluent.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1IngressClassBuilder(io.kubernetes.client.openapi.models.V1IngressClass instance) { - this(instance,false); + this(instance, false); } - public V1IngressClassBuilder(io.kubernetes.client.openapi.models.V1IngressClass instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1IngressClassBuilder( + io.kubernetes.client.openapi.models.V1IngressClass instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +74,12 @@ public V1IngressClassBuilder(io.kubernetes.client.openapi.models.V1IngressClass this.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1IngressClassFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1IngressClass build() { V1IngressClass buildable = new V1IngressClass(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1IngressClass build() { buildable.setSpec(fluent.getSpec()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1IngressClassBuilder that = (V1IngressClassBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassFluent.java index 90057489f6..48b919bbb9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassFluent.java @@ -1,73 +1,110 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1IngressClassFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1IngressClassFluent< + A extends io.kubernetes.client.openapi.models.V1IngressClassFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressClassSpec getSpec(); + public io.kubernetes.client.openapi.models.V1IngressClassSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1IngressClassSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1IngressClassSpec item); + + public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1IngressClassSpec item); + public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1IngressClassSpec item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1IngressClassSpec item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1IngressClassSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1IngressClassSpecFluent< + io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested> { public N and(); + public N endSpec(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassFluentImpl.java index ed0872db4f..156909f472 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1IngressClassFluentImpl< + A extends io.kubernetes.client.openapi.models.V1IngressClassFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1IngressClassFluent { + public V1IngressClassFluentImpl() {} - /** - * Generated - */ -public class V1IngressClassFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1IngressClassFluent{ - public V1IngressClassFluentImpl() { - } public V1IngressClassFluentImpl(io.kubernetes.client.openapi.models.V1IngressClass instance) { this.withApiVersion(instance.getApiVersion()); @@ -21,158 +27,219 @@ public V1IngressClassFluentImpl(io.kubernetes.client.openapi.models.V1IngressCla this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1IngressClassSpecBuilder spec; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1IngressClassFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1IngressClassFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1IngressClassFluentImpl.MetadataNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressClassSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1IngressClassSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1IngressClassSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1IngressClassSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1IngressClassSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1IngressClassFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1IngressClassSpec item) { + + public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1IngressClassSpec item) { return new io.kubernetes.client.openapi.models.V1IngressClassFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1IngressClassSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1IngressClassSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1IngressClassSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1IngressClassSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1IngressClassFluentImpl that = (V1IngressClassFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1IngressClassFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1IngressClassFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1IngressClassSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1IngressClassSpecFluentImpl< + io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1IngressClassFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1IngressClassSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1IngressClassSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1IngressClassSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1IngressClassSpecBuilder builder; + public N and() { return (N) V1IngressClassFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassListBuilder.java index 99a74b6b20..108b8fa97a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1IngressClassListBuilder extends io.kubernetes.client.openapi.models.V1IngressClassListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1IngressClassListBuilder + extends io.kubernetes.client.openapi.models.V1IngressClassListFluentImpl< + io.kubernetes.client.openapi.models.V1IngressClassListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1IngressClassList, + io.kubernetes.client.openapi.models.V1IngressClassListBuilder> { public V1IngressClassListBuilder() { this(false); } + public V1IngressClassListBuilder(java.lang.Boolean validationEnabled) { this(new V1IngressClassList(), validationEnabled); } - public V1IngressClassListBuilder(io.kubernetes.client.openapi.models.V1IngressClassListFluent fluent) { + + public V1IngressClassListBuilder( + io.kubernetes.client.openapi.models.V1IngressClassListFluent fluent) { this(fluent, false); } - public V1IngressClassListBuilder(io.kubernetes.client.openapi.models.V1IngressClassListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1IngressClassListBuilder( + io.kubernetes.client.openapi.models.V1IngressClassListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1IngressClassList(), validationEnabled); } - public V1IngressClassListBuilder(io.kubernetes.client.openapi.models.V1IngressClassListFluent fluent,io.kubernetes.client.openapi.models.V1IngressClassList instance) { + + public V1IngressClassListBuilder( + io.kubernetes.client.openapi.models.V1IngressClassListFluent fluent, + io.kubernetes.client.openapi.models.V1IngressClassList instance) { this(fluent, instance, false); } - public V1IngressClassListBuilder(io.kubernetes.client.openapi.models.V1IngressClassListFluent fluent,io.kubernetes.client.openapi.models.V1IngressClassList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1IngressClassListBuilder( + io.kubernetes.client.openapi.models.V1IngressClassListFluent fluent, + io.kubernetes.client.openapi.models.V1IngressClassList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1IngressClassListBuilder(io.kubernetes.client.openapi.models.V1IngressCl fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1IngressClassListBuilder(io.kubernetes.client.openapi.models.V1IngressClassList instance) { - this(instance,false); + + public V1IngressClassListBuilder( + io.kubernetes.client.openapi.models.V1IngressClassList instance) { + this(instance, false); } - public V1IngressClassListBuilder(io.kubernetes.client.openapi.models.V1IngressClassList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1IngressClassListBuilder( + io.kubernetes.client.openapi.models.V1IngressClassList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1IngressClassListBuilder(io.kubernetes.client.openapi.models.V1IngressCl this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1IngressClassListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1IngressClassList build() { V1IngressClassList buildable = new V1IngressClassList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1IngressClassList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1IngressClassListBuilder that = (V1IngressClassListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassListFluent.java index fa24c1d6a0..73456e473f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassListFluent.java @@ -1,95 +1,156 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1IngressClassListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1IngressClassListFluent< + A extends io.kubernetes.client.openapi.models.V1IngressClassListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressClass item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressClass item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressClass item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressClass item); + public A addToItems(io.kubernetes.client.openapi.models.V1IngressClass... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1IngressClass... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1IngressClass buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1IngressClass buildFirstItem(); + public io.kubernetes.client.openapi.models.V1IngressClass buildLastItem(); - public io.kubernetes.client.openapi.models.V1IngressClass buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1IngressClass buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1IngressClass... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1IngressClass item); - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressClass item); - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested editFirstItem(); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1IngressClass item); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressClass item); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested + editFirstItem(); + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1IngressClassFluent>{ + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1IngressClassFluent< + io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassListFluentImpl.java index bfb7bc4d84..b5f6d3c529 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1IngressClassListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1IngressClassListFluent{ - public V1IngressClassListFluentImpl() { - } - public V1IngressClassListFluentImpl(io.kubernetes.client.openapi.models.V1IngressClassList instance) { + +/** Generated */ +public class V1IngressClassListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1IngressClassListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1IngressClassListFluent { + public V1IngressClassListFluentImpl() {} + + public V1IngressClassListFluentImpl( + io.kubernetes.client.openapi.models.V1IngressClassList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1IngressClassListFluentImpl(io.kubernetes.client.openapi.models.V1Ingres this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressClass item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1IngressClassBuilder builder = new io.kubernetes.client.openapi.models.V1IngressClassBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressClass item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1IngressClassBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressClassBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressClass item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1IngressClassBuilder builder = new io.kubernetes.client.openapi.models.V1IngressClassBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressClass item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1IngressClassBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressClassBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1IngressClass... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1IngressClass item : items) {io.kubernetes.client.openapi.models.V1IngressClassBuilder builder = new io.kubernetes.client.openapi.models.V1IngressClassBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1IngressClass item : items) { + io.kubernetes.client.openapi.models.V1IngressClassBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressClassBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1IngressClass item : items) {io.kubernetes.client.openapi.models.V1IngressClassBuilder builder = new io.kubernetes.client.openapi.models.V1IngressClassBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1IngressClass item : items) { + io.kubernetes.client.openapi.models.V1IngressClassBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressClassBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1IngressClass... items) { - for (io.kubernetes.client.openapi.models.V1IngressClass item : items) {io.kubernetes.client.openapi.models.V1IngressClassBuilder builder = new io.kubernetes.client.openapi.models.V1IngressClassBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1IngressClass item : items) { + io.kubernetes.client.openapi.models.V1IngressClassBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressClassBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1IngressClass item : items) {io.kubernetes.client.openapi.models.V1IngressClassBuilder builder = new io.kubernetes.client.openapi.models.V1IngressClassBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1IngressClass item : items) { + io.kubernetes.client.openapi.models.V1IngressClassBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressClassBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1IngressClassBuilder builder = each.next(); @@ -87,174 +159,279 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1IngressClass buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1IngressClass buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1IngressClass buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1IngressClass buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1IngressClassBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1IngressClass buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1IngressClassBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1IngressClassBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1IngressClassBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1IngressClass item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1IngressClass item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1IngressClass... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1IngressClass item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1IngressClass item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1IngressClassListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1IngressClass item) { - return new io.kubernetes.client.openapi.models.V1IngressClassListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1IngressClass item) { + return new io.kubernetes.client.openapi.models.V1IngressClassListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressClass item) { - return new io.kubernetes.client.openapi.models.V1IngressClassListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressClass item) { + return new io.kubernetes.client.openapi.models.V1IngressClassListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1IngressClassListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1IngressClassListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1IngressClassListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1IngressClassListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1IngressClassListFluentImpl that = (V1IngressClassListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1IngressClassFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressClass item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1IngressClassFluentImpl< + io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1IngressClassListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressClass item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1IngressClassBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1IngressClassBuilder(this); } + io.kubernetes.client.openapi.models.V1IngressClassBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1IngressClassListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1IngressClassListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1IngressClassListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1IngressClassListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassParametersReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassParametersReferenceBuilder.java index 88dcae669a..b6469e4516 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassParametersReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassParametersReferenceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1IngressClassParametersReferenceBuilder extends io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1IngressClassParametersReferenceBuilder + extends io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1IngressClassParametersReference, + io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceBuilder> { public V1IngressClassParametersReferenceBuilder() { this(false); } + public V1IngressClassParametersReferenceBuilder(java.lang.Boolean validationEnabled) { this(new V1IngressClassParametersReference(), validationEnabled); } - public V1IngressClassParametersReferenceBuilder(io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent fluent) { + + public V1IngressClassParametersReferenceBuilder( + io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent fluent) { this(fluent, false); } - public V1IngressClassParametersReferenceBuilder(io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1IngressClassParametersReferenceBuilder( + io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1IngressClassParametersReference(), validationEnabled); } - public V1IngressClassParametersReferenceBuilder(io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent fluent,io.kubernetes.client.openapi.models.V1IngressClassParametersReference instance) { + + public V1IngressClassParametersReferenceBuilder( + io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1IngressClassParametersReference instance) { this(fluent, instance, false); } - public V1IngressClassParametersReferenceBuilder(io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent fluent,io.kubernetes.client.openapi.models.V1IngressClassParametersReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1IngressClassParametersReferenceBuilder( + io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1IngressClassParametersReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiGroup(instance.getApiGroup()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1IngressClassParametersReferenceBuilder(io.kubernetes.client.openapi.mod fluent.withScope(instance.getScope()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1IngressClassParametersReferenceBuilder(io.kubernetes.client.openapi.models.V1IngressClassParametersReference instance) { - this(instance,false); + + public V1IngressClassParametersReferenceBuilder( + io.kubernetes.client.openapi.models.V1IngressClassParametersReference instance) { + this(instance, false); } - public V1IngressClassParametersReferenceBuilder(io.kubernetes.client.openapi.models.V1IngressClassParametersReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1IngressClassParametersReferenceBuilder( + io.kubernetes.client.openapi.models.V1IngressClassParametersReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiGroup(instance.getApiGroup()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1IngressClassParametersReferenceBuilder(io.kubernetes.client.openapi.mod this.withScope(instance.getScope()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1IngressClassParametersReference build() { V1IngressClassParametersReference buildable = new V1IngressClassParametersReference(); buildable.setApiGroup(fluent.getApiGroup()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1IngressClassParametersReference bui buildable.setScope(fluent.getScope()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1IngressClassParametersReferenceBuilder that = (V1IngressClassParametersReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassParametersReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassParametersReferenceFluent.java index cb3334a426..033450252c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassParametersReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassParametersReferenceFluent.java @@ -1,59 +1,68 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1IngressClassParametersReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1IngressClassParametersReferenceFluent< + A extends io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiGroup(); + public A withApiGroup(java.lang.String apiGroup); + public java.lang.Boolean hasApiGroup(); - - /** - * Method is deprecated. use withApiGroup instead. - */ + + /** Method is deprecated. use withApiGroup instead. */ @java.lang.Deprecated public A withNewApiGroup(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getNamespace(); + public A withNamespace(java.lang.String namespace); + public java.lang.Boolean hasNamespace(); - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original); + public java.lang.String getScope(); + public A withScope(java.lang.String scope); + public java.lang.Boolean hasScope(); - - /** - * Method is deprecated. use withScope instead. - */ + + /** Method is deprecated. use withScope instead. */ @java.lang.Deprecated public A withNewScope(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassParametersReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassParametersReferenceFluentImpl.java index e648627122..cbeaec50e0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassParametersReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassParametersReferenceFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1IngressClassParametersReferenceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent { + public V1IngressClassParametersReferenceFluentImpl() {} - /** - * Generated - */ -public class V1IngressClassParametersReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent{ - public V1IngressClassParametersReferenceFluentImpl() { - } - public V1IngressClassParametersReferenceFluentImpl(io.kubernetes.client.openapi.models.V1IngressClassParametersReference instance) { + public V1IngressClassParametersReferenceFluentImpl( + io.kubernetes.client.openapi.models.V1IngressClassParametersReference instance) { this.withApiGroup(instance.getApiGroup()); this.withKind(instance.getKind()); @@ -22,111 +30,124 @@ public V1IngressClassParametersReferenceFluentImpl(io.kubernetes.client.openapi. this.withNamespace(instance.getNamespace()); this.withScope(instance.getScope()); - } + private java.lang.String apiGroup; private java.lang.String kind; private java.lang.String name; private java.lang.String namespace; private java.lang.String scope; + public java.lang.String getApiGroup() { return this.apiGroup; } + public A withApiGroup(java.lang.String apiGroup) { - this.apiGroup=apiGroup; return (A) this; + this.apiGroup = apiGroup; + return (A) this; } + public java.lang.Boolean hasApiGroup() { return this.apiGroup != null; } - - /** - * Method is deprecated. use withApiGroup instead. - */ + + /** Method is deprecated. use withApiGroup instead. */ @java.lang.Deprecated public A withNewApiGroup(java.lang.String original) { - return (A)withApiGroup(new String(original)); + return (A) withApiGroup(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getNamespace() { return this.namespace; } + public A withNamespace(java.lang.String namespace) { - this.namespace=namespace; return (A) this; + this.namespace = namespace; + return (A) this; } + public java.lang.Boolean hasNamespace() { return this.namespace != null; } - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original) { - return (A)withNamespace(new String(original)); + return (A) withNamespace(new String(original)); } + public java.lang.String getScope() { return this.scope; } + public A withScope(java.lang.String scope) { - this.scope=scope; return (A) this; + this.scope = scope; + return (A) this; } + public java.lang.Boolean hasScope() { return this.scope != null; } - - /** - * Method is deprecated. use withScope instead. - */ + + /** Method is deprecated. use withScope instead. */ @java.lang.Deprecated public A withNewScope(java.lang.String original) { - return (A)withScope(new String(original)); + return (A) withScope(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1IngressClassParametersReferenceFluentImpl that = (V1IngressClassParametersReferenceFluentImpl) o; - if (apiGroup != null ? !apiGroup.equals(that.apiGroup) :that.apiGroup != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (namespace != null ? !namespace.equals(that.namespace) :that.namespace != null) return false; - if (scope != null ? !scope.equals(that.scope) :that.scope != null) return false; + V1IngressClassParametersReferenceFluentImpl that = + (V1IngressClassParametersReferenceFluentImpl) o; + if (apiGroup != null ? !apiGroup.equals(that.apiGroup) : that.apiGroup != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (namespace != null ? !namespace.equals(that.namespace) : that.namespace != null) + return false; + if (scope != null ? !scope.equals(that.scope) : that.scope != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiGroup, kind, name, namespace, scope, super.hashCode()); + return java.util.Objects.hash(apiGroup, kind, name, namespace, scope, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassSpecBuilder.java index 45ad2cd039..1c691c7787 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassSpecBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1IngressClassSpecBuilder extends io.kubernetes.client.openapi.models.V1IngressClassSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1IngressClassSpecBuilder + extends io.kubernetes.client.openapi.models.V1IngressClassSpecFluentImpl< + io.kubernetes.client.openapi.models.V1IngressClassSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1IngressClassSpec, + io.kubernetes.client.openapi.models.V1IngressClassSpecBuilder> { public V1IngressClassSpecBuilder() { this(false); } + public V1IngressClassSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1IngressClassSpec(), validationEnabled); } - public V1IngressClassSpecBuilder(io.kubernetes.client.openapi.models.V1IngressClassSpecFluent fluent) { + + public V1IngressClassSpecBuilder( + io.kubernetes.client.openapi.models.V1IngressClassSpecFluent fluent) { this(fluent, false); } - public V1IngressClassSpecBuilder(io.kubernetes.client.openapi.models.V1IngressClassSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1IngressClassSpecBuilder( + io.kubernetes.client.openapi.models.V1IngressClassSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1IngressClassSpec(), validationEnabled); } - public V1IngressClassSpecBuilder(io.kubernetes.client.openapi.models.V1IngressClassSpecFluent fluent,io.kubernetes.client.openapi.models.V1IngressClassSpec instance) { + + public V1IngressClassSpecBuilder( + io.kubernetes.client.openapi.models.V1IngressClassSpecFluent fluent, + io.kubernetes.client.openapi.models.V1IngressClassSpec instance) { this(fluent, instance, false); } - public V1IngressClassSpecBuilder(io.kubernetes.client.openapi.models.V1IngressClassSpecFluent fluent,io.kubernetes.client.openapi.models.V1IngressClassSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1IngressClassSpecBuilder( + io.kubernetes.client.openapi.models.V1IngressClassSpecFluent fluent, + io.kubernetes.client.openapi.models.V1IngressClassSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withController(instance.getController()); fluent.withParameters(instance.getParameters()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1IngressClassSpecBuilder(io.kubernetes.client.openapi.models.V1IngressClassSpec instance) { - this(instance,false); + + public V1IngressClassSpecBuilder( + io.kubernetes.client.openapi.models.V1IngressClassSpec instance) { + this(instance, false); } - public V1IngressClassSpecBuilder(io.kubernetes.client.openapi.models.V1IngressClassSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1IngressClassSpecBuilder( + io.kubernetes.client.openapi.models.V1IngressClassSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withController(instance.getController()); this.withParameters(instance.getParameters()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1IngressClassSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1IngressClassSpec build() { V1IngressClassSpec buildable = new V1IngressClassSpec(); buildable.setController(fluent.getController()); buildable.setParameters(fluent.getParameters()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1IngressClassSpecBuilder that = (V1IngressClassSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassSpecFluent.java index 2f8b9a8651..88a4470316 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassSpecFluent.java @@ -1,44 +1,69 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1IngressClassSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1IngressClassSpecFluent< + A extends io.kubernetes.client.openapi.models.V1IngressClassSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getController(); + public A withController(java.lang.String controller); + public java.lang.Boolean hasController(); - - /** - * Method is deprecated. use withController instead. - */ + + /** Method is deprecated. use withController instead. */ @java.lang.Deprecated public A withNewController(java.lang.String original); - + /** * This method has been deprecated, please use method buildParameters instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressClassParametersReference getParameters(); + public io.kubernetes.client.openapi.models.V1IngressClassParametersReference buildParameters(); - public A withParameters(io.kubernetes.client.openapi.models.V1IngressClassParametersReference parameters); + + public A withParameters( + io.kubernetes.client.openapi.models.V1IngressClassParametersReference parameters); + public java.lang.Boolean hasParameters(); - public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested withNewParameters(); - public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested withNewParametersLike(io.kubernetes.client.openapi.models.V1IngressClassParametersReference item); - public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested editParameters(); - public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested editOrNewParameters(); - public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested editOrNewParametersLike(io.kubernetes.client.openapi.models.V1IngressClassParametersReference item); - public interface ParametersNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent>{ + + public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested + withNewParameters(); + + public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested + withNewParametersLike( + io.kubernetes.client.openapi.models.V1IngressClassParametersReference item); + + public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested + editParameters(); + + public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested + editOrNewParameters(); + + public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested + editOrNewParametersLike( + io.kubernetes.client.openapi.models.V1IngressClassParametersReference item); + + public interface ParametersNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluent< + io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested> { public N and(); + public N endParameters(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassSpecFluentImpl.java index e5bb271474..84c5b51a1f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressClassSpecFluentImpl.java @@ -1,103 +1,156 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1IngressClassSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1IngressClassSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1IngressClassSpecFluent { + public V1IngressClassSpecFluentImpl() {} - /** - * Generated - */ -public class V1IngressClassSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1IngressClassSpecFluent{ - public V1IngressClassSpecFluentImpl() { - } - public V1IngressClassSpecFluentImpl(io.kubernetes.client.openapi.models.V1IngressClassSpec instance) { + public V1IngressClassSpecFluentImpl( + io.kubernetes.client.openapi.models.V1IngressClassSpec instance) { this.withController(instance.getController()); this.withParameters(instance.getParameters()); - } + private java.lang.String controller; private io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceBuilder parameters; + public java.lang.String getController() { return this.controller; } + public A withController(java.lang.String controller) { - this.controller=controller; return (A) this; + this.controller = controller; + return (A) this; } + public java.lang.Boolean hasController() { return this.controller != null; } - - /** - * Method is deprecated. use withController instead. - */ + + /** Method is deprecated. use withController instead. */ @java.lang.Deprecated public A withNewController(java.lang.String original) { - return (A)withController(new String(original)); + return (A) withController(new String(original)); } - + /** * This method has been deprecated, please use method buildParameters instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressClassParametersReference getParameters() { - return this.parameters!=null ?this.parameters.build():null; + return this.parameters != null ? this.parameters.build() : null; } + public io.kubernetes.client.openapi.models.V1IngressClassParametersReference buildParameters() { - return this.parameters!=null ?this.parameters.build():null; + return this.parameters != null ? this.parameters.build() : null; } - public A withParameters(io.kubernetes.client.openapi.models.V1IngressClassParametersReference parameters) { + + public A withParameters( + io.kubernetes.client.openapi.models.V1IngressClassParametersReference parameters) { _visitables.get("parameters").remove(this.parameters); - if (parameters!=null){ this.parameters= new io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceBuilder(parameters); _visitables.get("parameters").add(this.parameters);} return (A) this; + if (parameters != null) { + this.parameters = + new io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceBuilder( + parameters); + _visitables.get("parameters").add(this.parameters); + } + return (A) this; } + public java.lang.Boolean hasParameters() { return this.parameters != null; } - public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested withNewParameters() { - return new io.kubernetes.client.openapi.models.V1IngressClassSpecFluentImpl.ParametersNestedImpl(); + + public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested + withNewParameters() { + return new io.kubernetes.client.openapi.models.V1IngressClassSpecFluentImpl + .ParametersNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested withNewParametersLike(io.kubernetes.client.openapi.models.V1IngressClassParametersReference item) { - return new io.kubernetes.client.openapi.models.V1IngressClassSpecFluentImpl.ParametersNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested + withNewParametersLike( + io.kubernetes.client.openapi.models.V1IngressClassParametersReference item) { + return new io.kubernetes.client.openapi.models.V1IngressClassSpecFluentImpl + .ParametersNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested editParameters() { + + public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested + editParameters() { return withNewParametersLike(getParameters()); } - public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested editOrNewParameters() { - return withNewParametersLike(getParameters() != null ? getParameters(): new io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested + editOrNewParameters() { + return withNewParametersLike( + getParameters() != null + ? getParameters() + : new io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested editOrNewParametersLike(io.kubernetes.client.openapi.models.V1IngressClassParametersReference item) { - return withNewParametersLike(getParameters() != null ? getParameters(): item); + + public io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested + editOrNewParametersLike( + io.kubernetes.client.openapi.models.V1IngressClassParametersReference item) { + return withNewParametersLike(getParameters() != null ? getParameters() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1IngressClassSpecFluentImpl that = (V1IngressClassSpecFluentImpl) o; - if (controller != null ? !controller.equals(that.controller) :that.controller != null) return false; - if (parameters != null ? !parameters.equals(that.parameters) :that.parameters != null) return false; + if (controller != null ? !controller.equals(that.controller) : that.controller != null) + return false; + if (parameters != null ? !parameters.equals(that.parameters) : that.parameters != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(controller, parameters, super.hashCode()); + return java.util.Objects.hash(controller, parameters, super.hashCode()); } - public class ParametersNestedImpl extends io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested,io.kubernetes.client.fluent.Nested{ - ParametersNestedImpl(io.kubernetes.client.openapi.models.V1IngressClassParametersReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceBuilder(this, item); + + public class ParametersNestedImpl + extends io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested> + implements io.kubernetes.client.openapi.models.V1IngressClassSpecFluent.ParametersNested, + io.kubernetes.client.fluent.Nested { + ParametersNestedImpl( + io.kubernetes.client.openapi.models.V1IngressClassParametersReference item) { + this.builder = + new io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceBuilder( + this, item); } + ParametersNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1IngressClassParametersReferenceBuilder builder; + public N and() { return (N) V1IngressClassSpecFluentImpl.this.withParameters(builder.build()); } + public N endParameters() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressFluent.java index 67a11ad373..8c0e85748c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressFluent.java @@ -1,93 +1,142 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1IngressFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1IngressFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressSpec getSpec(); + public io.kubernetes.client.openapi.models.V1IngressSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1IngressSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1IngressSpec item); + + public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1IngressSpec item); + public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1IngressSpec item); - + + public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1IngressSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressStatus getStatus(); + public io.kubernetes.client.openapi.models.V1IngressStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1IngressStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1IngressStatus item); + + public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1IngressStatus item); + public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1IngressStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1IngressStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1IngressSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1IngressSpecFluent< + io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1IngressStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1IngressStatusFluent< + io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressFluentImpl.java index a5576b2072..bb23e77c3b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1IngressFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1IngressFluent { + public V1IngressFluentImpl() {} - /** - * Generated - */ -public class V1IngressFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1IngressFluent{ - public V1IngressFluentImpl() { - } public V1IngressFluentImpl(io.kubernetes.client.openapi.models.V1Ingress instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +28,294 @@ public V1IngressFluentImpl(io.kubernetes.client.openapi.models.V1Ingress instanc this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1IngressSpecBuilder spec; private io.kubernetes.client.openapi.models.V1IngressStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1IngressFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1IngressFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1IngressSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1IngressSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1IngressSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1IngressSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1IngressFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1IngressSpec item) { + + public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1IngressSpec item) { return new io.kubernetes.client.openapi.models.V1IngressFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1IngressSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1IngressSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1IngressSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1IngressSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1IngressStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1IngressStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1IngressStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1IngressStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1IngressFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1IngressStatus item) { + + public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1IngressStatus item) { return new io.kubernetes.client.openapi.models.V1IngressFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1IngressStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1IngressStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1IngressStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1IngressStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1IngressFluentImpl that = (V1IngressFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1IngressFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1IngressFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl< + io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1IngressFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1IngressSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1IngressSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1IngressSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1IngressSpecBuilder builder; + public N and() { return (N) V1IngressFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1IngressStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1IngressStatusFluentImpl< + io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1IngressFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1IngressStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1IngressStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1IngressStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1IngressStatusBuilder builder; + public N and() { return (N) V1IngressFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressListBuilder.java index f8c181609a..afb76421cc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressListBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1IngressListBuilder extends io.kubernetes.client.openapi.models.V1IngressListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1IngressListBuilder + extends io.kubernetes.client.openapi.models.V1IngressListFluentImpl< + io.kubernetes.client.openapi.models.V1IngressListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1IngressList, + io.kubernetes.client.openapi.models.V1IngressListBuilder> { public V1IngressListBuilder() { this(false); } + public V1IngressListBuilder(java.lang.Boolean validationEnabled) { this(new V1IngressList(), validationEnabled); } + public V1IngressListBuilder(io.kubernetes.client.openapi.models.V1IngressListFluent fluent) { this(fluent, false); } - public V1IngressListBuilder(io.kubernetes.client.openapi.models.V1IngressListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1IngressListBuilder( + io.kubernetes.client.openapi.models.V1IngressListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1IngressList(), validationEnabled); } - public V1IngressListBuilder(io.kubernetes.client.openapi.models.V1IngressListFluent fluent,io.kubernetes.client.openapi.models.V1IngressList instance) { + + public V1IngressListBuilder( + io.kubernetes.client.openapi.models.V1IngressListFluent fluent, + io.kubernetes.client.openapi.models.V1IngressList instance) { this(fluent, instance, false); } - public V1IngressListBuilder(io.kubernetes.client.openapi.models.V1IngressListFluent fluent,io.kubernetes.client.openapi.models.V1IngressList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1IngressListBuilder( + io.kubernetes.client.openapi.models.V1IngressListFluent fluent, + io.kubernetes.client.openapi.models.V1IngressList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +55,17 @@ public V1IngressListBuilder(io.kubernetes.client.openapi.models.V1IngressListFlu fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1IngressListBuilder(io.kubernetes.client.openapi.models.V1IngressList instance) { - this(instance,false); + this(instance, false); } - public V1IngressListBuilder(io.kubernetes.client.openapi.models.V1IngressList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1IngressListBuilder( + io.kubernetes.client.openapi.models.V1IngressList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +74,12 @@ public V1IngressListBuilder(io.kubernetes.client.openapi.models.V1IngressList in this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1IngressListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1IngressList build() { V1IngressList buildable = new V1IngressList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1IngressList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1IngressListBuilder that = (V1IngressListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressListFluent.java index 7932899623..33fdc4b368 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressListFluent.java @@ -1,95 +1,146 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1IngressListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1IngressListFluent< + A extends io.kubernetes.client.openapi.models.V1IngressListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Ingress item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Ingress item); + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Ingress item); + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Ingress item); + public A addToItems(io.kubernetes.client.openapi.models.V1Ingress... items); + public A addAllToItems(java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1Ingress... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1Ingress buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Ingress buildFirstItem(); + public io.kubernetes.client.openapi.models.V1Ingress buildLastItem(); - public io.kubernetes.client.openapi.models.V1Ingress buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Ingress buildMatchingItem( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1Ingress... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Ingress item); - public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Ingress item); - public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Ingress item); + + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Ingress item); + + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1IngressFluent>{ + + public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1IngressFluent< + io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressListFluentImpl.java index db1898cc37..072bc58afa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1IngressListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1IngressListFluent{ - public V1IngressListFluentImpl() { - } +/** Generated */ +public class V1IngressListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1IngressListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1IngressListFluent { + public V1IngressListFluentImpl() {} + public V1IngressListFluentImpl(io.kubernetes.client.openapi.models.V1IngressList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,117 @@ public V1IngressListFluentImpl(io.kubernetes.client.openapi.models.V1IngressList this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Ingress item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1IngressBuilder builder = new io.kubernetes.client.openapi.models.V1IngressBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Ingress item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1IngressBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Ingress item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1IngressBuilder builder = new io.kubernetes.client.openapi.models.V1IngressBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Ingress item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1IngressBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1Ingress... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Ingress item : items) {io.kubernetes.client.openapi.models.V1IngressBuilder builder = new io.kubernetes.client.openapi.models.V1IngressBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Ingress item : items) { + io.kubernetes.client.openapi.models.V1IngressBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Ingress item : items) {io.kubernetes.client.openapi.models.V1IngressBuilder builder = new io.kubernetes.client.openapi.models.V1IngressBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Ingress item : items) { + io.kubernetes.client.openapi.models.V1IngressBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1Ingress... items) { - for (io.kubernetes.client.openapi.models.V1Ingress item : items) {io.kubernetes.client.openapi.models.V1IngressBuilder builder = new io.kubernetes.client.openapi.models.V1IngressBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Ingress item : items) { + io.kubernetes.client.openapi.models.V1IngressBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Ingress item : items) {io.kubernetes.client.openapi.models.V1IngressBuilder builder = new io.kubernetes.client.openapi.models.V1IngressBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Ingress item : items) { + io.kubernetes.client.openapi.models.V1IngressBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +151,272 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1Ingress buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Ingress buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Ingress buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Ingress buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1IngressBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Ingress buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1IngressBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1IngressBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1IngressBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Ingress item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Ingress item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1Ingress... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1Ingress item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1Ingress item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1IngressListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Ingress item) { - return new io.kubernetes.client.openapi.models.V1IngressListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Ingress item) { + return new io.kubernetes.client.openapi.models.V1IngressListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Ingress item) { - return new io.kubernetes.client.openapi.models.V1IngressListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Ingress item) { + return new io.kubernetes.client.openapi.models.V1IngressListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1IngressListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + + public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { return new io.kubernetes.client.openapi.models.V1IngressListFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1IngressListFluentImpl that = (V1IngressListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1IngressFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Ingress item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1IngressFluentImpl< + io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1IngressListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Ingress item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1IngressBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1IngressBuilder(this); } + io.kubernetes.client.openapi.models.V1IngressBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1IngressListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1IngressListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1IngressListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1IngressListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressRuleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressRuleBuilder.java index eb5c51235d..f1dfa1533d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressRuleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressRuleBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1IngressRuleBuilder extends io.kubernetes.client.openapi.models.V1IngressRuleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1IngressRuleBuilder + extends io.kubernetes.client.openapi.models.V1IngressRuleFluentImpl< + io.kubernetes.client.openapi.models.V1IngressRuleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1IngressRule, + io.kubernetes.client.openapi.models.V1IngressRuleBuilder> { public V1IngressRuleBuilder() { this(false); } + public V1IngressRuleBuilder(java.lang.Boolean validationEnabled) { this(new V1IngressRule(), validationEnabled); } + public V1IngressRuleBuilder(io.kubernetes.client.openapi.models.V1IngressRuleFluent fluent) { this(fluent, false); } - public V1IngressRuleBuilder(io.kubernetes.client.openapi.models.V1IngressRuleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1IngressRuleBuilder( + io.kubernetes.client.openapi.models.V1IngressRuleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1IngressRule(), validationEnabled); } - public V1IngressRuleBuilder(io.kubernetes.client.openapi.models.V1IngressRuleFluent fluent,io.kubernetes.client.openapi.models.V1IngressRule instance) { + + public V1IngressRuleBuilder( + io.kubernetes.client.openapi.models.V1IngressRuleFluent fluent, + io.kubernetes.client.openapi.models.V1IngressRule instance) { this(fluent, instance, false); } - public V1IngressRuleBuilder(io.kubernetes.client.openapi.models.V1IngressRuleFluent fluent,io.kubernetes.client.openapi.models.V1IngressRule instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1IngressRuleBuilder( + io.kubernetes.client.openapi.models.V1IngressRuleFluent fluent, + io.kubernetes.client.openapi.models.V1IngressRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withHost(instance.getHost()); fluent.withHttp(instance.getHttp()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1IngressRuleBuilder(io.kubernetes.client.openapi.models.V1IngressRule instance) { - this(instance,false); + this(instance, false); } - public V1IngressRuleBuilder(io.kubernetes.client.openapi.models.V1IngressRule instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1IngressRuleBuilder( + io.kubernetes.client.openapi.models.V1IngressRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withHost(instance.getHost()); this.withHttp(instance.getHttp()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1IngressRuleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1IngressRule build() { V1IngressRule buildable = new V1IngressRule(); buildable.setHost(fluent.getHost()); buildable.setHttp(fluent.getHttp()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1IngressRuleBuilder that = (V1IngressRuleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressRuleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressRuleFluent.java index de19343487..8db6234f99 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressRuleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressRuleFluent.java @@ -1,44 +1,63 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1IngressRuleFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1IngressRuleFluent< + A extends io.kubernetes.client.openapi.models.V1IngressRuleFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getHost(); + public A withHost(java.lang.String host); + public java.lang.Boolean hasHost(); - - /** - * Method is deprecated. use withHost instead. - */ + + /** Method is deprecated. use withHost instead. */ @java.lang.Deprecated public A withNewHost(java.lang.String original); - + /** * This method has been deprecated, please use method buildHttp instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue getHttp(); + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue buildHttp(); + public A withHttp(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue http); + public java.lang.Boolean hasHttp(); + public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested withNewHttp(); - public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested withNewHttpLike(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue item); + + public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested withNewHttpLike( + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue item); + public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested editHttp(); + public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested editOrNewHttp(); - public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested editOrNewHttpLike(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue item); - public interface HttpNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent>{ + + public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested editOrNewHttpLike( + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue item); + + public interface HttpNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluent< + io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested> { public N and(); + public N endHttp(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressRuleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressRuleFluentImpl.java index 973fee635f..b2a94648e8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressRuleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressRuleFluentImpl.java @@ -1,103 +1,139 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1IngressRuleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1IngressRuleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1IngressRuleFluent { + public V1IngressRuleFluentImpl() {} - /** - * Generated - */ -public class V1IngressRuleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1IngressRuleFluent{ - public V1IngressRuleFluentImpl() { - } public V1IngressRuleFluentImpl(io.kubernetes.client.openapi.models.V1IngressRule instance) { this.withHost(instance.getHost()); this.withHttp(instance.getHttp()); - } + private java.lang.String host; private io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueBuilder http; + public java.lang.String getHost() { return this.host; } + public A withHost(java.lang.String host) { - this.host=host; return (A) this; + this.host = host; + return (A) this; } + public java.lang.Boolean hasHost() { return this.host != null; } - - /** - * Method is deprecated. use withHost instead. - */ + + /** Method is deprecated. use withHost instead. */ @java.lang.Deprecated public A withNewHost(java.lang.String original) { - return (A)withHost(new String(original)); + return (A) withHost(new String(original)); } - + /** * This method has been deprecated, please use method buildHttp instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue getHttp() { - return this.http!=null ?this.http.build():null; + return this.http != null ? this.http.build() : null; } + public io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue buildHttp() { - return this.http!=null ?this.http.build():null; + return this.http != null ? this.http.build() : null; } + public A withHttp(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue http) { _visitables.get("http").remove(this.http); - if (http!=null){ this.http= new io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueBuilder(http); _visitables.get("http").add(this.http);} return (A) this; + if (http != null) { + this.http = new io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueBuilder(http); + _visitables.get("http").add(this.http); + } + return (A) this; } + public java.lang.Boolean hasHttp() { return this.http != null; } + public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested withNewHttp() { return new io.kubernetes.client.openapi.models.V1IngressRuleFluentImpl.HttpNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested withNewHttpLike(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue item) { + + public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested withNewHttpLike( + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue item) { return new io.kubernetes.client.openapi.models.V1IngressRuleFluentImpl.HttpNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested editHttp() { return withNewHttpLike(getHttp()); } + public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested editOrNewHttp() { - return withNewHttpLike(getHttp() != null ? getHttp(): new io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueBuilder().build()); + return withNewHttpLike( + getHttp() != null + ? getHttp() + : new io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueBuilder().build()); } - public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested editOrNewHttpLike(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue item) { - return withNewHttpLike(getHttp() != null ? getHttp(): item); + + public io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested editOrNewHttpLike( + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue item) { + return withNewHttpLike(getHttp() != null ? getHttp() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1IngressRuleFluentImpl that = (V1IngressRuleFluentImpl) o; - if (host != null ? !host.equals(that.host) :that.host != null) return false; - if (http != null ? !http.equals(that.http) :that.http != null) return false; + if (host != null ? !host.equals(that.host) : that.host != null) return false; + if (http != null ? !http.equals(that.http) : that.http != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(host, http, super.hashCode()); + return java.util.Objects.hash(host, http, super.hashCode()); } - public class HttpNestedImpl extends io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested,io.kubernetes.client.fluent.Nested{ + + public class HttpNestedImpl + extends io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueFluentImpl< + io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested> + implements io.kubernetes.client.openapi.models.V1IngressRuleFluent.HttpNested, + io.kubernetes.client.fluent.Nested { HttpNestedImpl(io.kubernetes.client.openapi.models.V1HTTPIngressRuleValue item) { - this.builder = new io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueBuilder(this, item); } + HttpNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueBuilder(this); } + io.kubernetes.client.openapi.models.V1HTTPIngressRuleValueBuilder builder; + public N and() { return (N) V1IngressRuleFluentImpl.this.withHttp(builder.build()); } + public N endHttp() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressServiceBackendBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressServiceBackendBuilder.java index 2c114fff1f..b2b3128c5f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressServiceBackendBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressServiceBackendBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1IngressServiceBackendBuilder extends io.kubernetes.client.openapi.models.V1IngressServiceBackendFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1IngressServiceBackendBuilder + extends io.kubernetes.client.openapi.models.V1IngressServiceBackendFluentImpl< + io.kubernetes.client.openapi.models.V1IngressServiceBackendBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1IngressServiceBackend, + io.kubernetes.client.openapi.models.V1IngressServiceBackendBuilder> { public V1IngressServiceBackendBuilder() { this(false); } + public V1IngressServiceBackendBuilder(java.lang.Boolean validationEnabled) { this(new V1IngressServiceBackend(), validationEnabled); } - public V1IngressServiceBackendBuilder(io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent fluent) { + + public V1IngressServiceBackendBuilder( + io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent fluent) { this(fluent, false); } - public V1IngressServiceBackendBuilder(io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent fluent,java.lang.Boolean validationEnabled) { + + public V1IngressServiceBackendBuilder( + io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1IngressServiceBackend(), validationEnabled); } - public V1IngressServiceBackendBuilder(io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent fluent,io.kubernetes.client.openapi.models.V1IngressServiceBackend instance) { + + public V1IngressServiceBackendBuilder( + io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent fluent, + io.kubernetes.client.openapi.models.V1IngressServiceBackend instance) { this(fluent, instance, false); } - public V1IngressServiceBackendBuilder(io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent fluent,io.kubernetes.client.openapi.models.V1IngressServiceBackend instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1IngressServiceBackendBuilder( + io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent fluent, + io.kubernetes.client.openapi.models.V1IngressServiceBackend instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withPort(instance.getPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1IngressServiceBackendBuilder(io.kubernetes.client.openapi.models.V1IngressServiceBackend instance) { - this(instance,false); + + public V1IngressServiceBackendBuilder( + io.kubernetes.client.openapi.models.V1IngressServiceBackend instance) { + this(instance, false); } - public V1IngressServiceBackendBuilder(io.kubernetes.client.openapi.models.V1IngressServiceBackend instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1IngressServiceBackendBuilder( + io.kubernetes.client.openapi.models.V1IngressServiceBackend instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withPort(instance.getPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1IngressServiceBackend build() { V1IngressServiceBackend buildable = new V1IngressServiceBackend(); buildable.setName(fluent.getName()); buildable.setPort(fluent.getPort()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1IngressServiceBackendBuilder that = (V1IngressServiceBackendBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressServiceBackendFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressServiceBackendFluent.java index 493d1885bf..fe3ee0ed0b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressServiceBackendFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressServiceBackendFluent.java @@ -1,44 +1,65 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1IngressServiceBackendFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1IngressServiceBackendFluent< + A extends io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - + /** * This method has been deprecated, please use method buildPort instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ServiceBackendPort getPort(); + public io.kubernetes.client.openapi.models.V1ServiceBackendPort buildPort(); + public A withPort(io.kubernetes.client.openapi.models.V1ServiceBackendPort port); + public java.lang.Boolean hasPort(); - public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested withNewPort(); - public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested withNewPortLike(io.kubernetes.client.openapi.models.V1ServiceBackendPort item); + + public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested + withNewPort(); + + public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested + withNewPortLike(io.kubernetes.client.openapi.models.V1ServiceBackendPort item); + public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested editPort(); - public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested editOrNewPort(); - public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested editOrNewPortLike(io.kubernetes.client.openapi.models.V1ServiceBackendPort item); - public interface PortNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent>{ + + public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested + editOrNewPort(); + + public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested + editOrNewPortLike(io.kubernetes.client.openapi.models.V1ServiceBackendPort item); + + public interface PortNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent< + io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested> { public N and(); + public N endPort(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressServiceBackendFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressServiceBackendFluentImpl.java index ce0737a392..9ddd808a34 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressServiceBackendFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressServiceBackendFluentImpl.java @@ -1,103 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1IngressServiceBackendFluentImpl< + A extends io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent { + public V1IngressServiceBackendFluentImpl() {} - /** - * Generated - */ -public class V1IngressServiceBackendFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent{ - public V1IngressServiceBackendFluentImpl() { - } - public V1IngressServiceBackendFluentImpl(io.kubernetes.client.openapi.models.V1IngressServiceBackend instance) { + public V1IngressServiceBackendFluentImpl( + io.kubernetes.client.openapi.models.V1IngressServiceBackend instance) { this.withName(instance.getName()); this.withPort(instance.getPort()); - } + private java.lang.String name; private io.kubernetes.client.openapi.models.V1ServiceBackendPortBuilder port; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } - + /** * This method has been deprecated, please use method buildPort instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ServiceBackendPort getPort() { - return this.port!=null ?this.port.build():null; + return this.port != null ? this.port.build() : null; } + public io.kubernetes.client.openapi.models.V1ServiceBackendPort buildPort() { - return this.port!=null ?this.port.build():null; + return this.port != null ? this.port.build() : null; } + public A withPort(io.kubernetes.client.openapi.models.V1ServiceBackendPort port) { _visitables.get("port").remove(this.port); - if (port!=null){ this.port= new io.kubernetes.client.openapi.models.V1ServiceBackendPortBuilder(port); _visitables.get("port").add(this.port);} return (A) this; + if (port != null) { + this.port = new io.kubernetes.client.openapi.models.V1ServiceBackendPortBuilder(port); + _visitables.get("port").add(this.port); + } + return (A) this; } + public java.lang.Boolean hasPort() { return this.port != null; } - public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested withNewPort() { - return new io.kubernetes.client.openapi.models.V1IngressServiceBackendFluentImpl.PortNestedImpl(); + + public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested + withNewPort() { + return new io.kubernetes.client.openapi.models.V1IngressServiceBackendFluentImpl + .PortNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested withNewPortLike(io.kubernetes.client.openapi.models.V1ServiceBackendPort item) { - return new io.kubernetes.client.openapi.models.V1IngressServiceBackendFluentImpl.PortNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested + withNewPortLike(io.kubernetes.client.openapi.models.V1ServiceBackendPort item) { + return new io.kubernetes.client.openapi.models.V1IngressServiceBackendFluentImpl.PortNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested editPort() { + + public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested + editPort() { return withNewPortLike(getPort()); } - public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested editOrNewPort() { - return withNewPortLike(getPort() != null ? getPort(): new io.kubernetes.client.openapi.models.V1ServiceBackendPortBuilder().build()); + + public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested + editOrNewPort() { + return withNewPortLike( + getPort() != null + ? getPort() + : new io.kubernetes.client.openapi.models.V1ServiceBackendPortBuilder().build()); } - public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested editOrNewPortLike(io.kubernetes.client.openapi.models.V1ServiceBackendPort item) { - return withNewPortLike(getPort() != null ? getPort(): item); + + public io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested + editOrNewPortLike(io.kubernetes.client.openapi.models.V1ServiceBackendPort item) { + return withNewPortLike(getPort() != null ? getPort() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1IngressServiceBackendFluentImpl that = (V1IngressServiceBackendFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (port != null ? !port.equals(that.port) :that.port != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (port != null ? !port.equals(that.port) : that.port != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, port, super.hashCode()); + return java.util.Objects.hash(name, port, super.hashCode()); } - public class PortNestedImpl extends io.kubernetes.client.openapi.models.V1ServiceBackendPortFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested,io.kubernetes.client.fluent.Nested{ + + public class PortNestedImpl + extends io.kubernetes.client.openapi.models.V1ServiceBackendPortFluentImpl< + io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested> + implements io.kubernetes.client.openapi.models.V1IngressServiceBackendFluent.PortNested, + io.kubernetes.client.fluent.Nested { PortNestedImpl(io.kubernetes.client.openapi.models.V1ServiceBackendPort item) { - this.builder = new io.kubernetes.client.openapi.models.V1ServiceBackendPortBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ServiceBackendPortBuilder(this, item); } + PortNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ServiceBackendPortBuilder(this); } + io.kubernetes.client.openapi.models.V1ServiceBackendPortBuilder builder; + public N and() { return (N) V1IngressServiceBackendFluentImpl.this.withPort(builder.build()); } + public N endPort() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressSpecBuilder.java index 4d31e6a229..5348dd63e4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressSpecBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1IngressSpecBuilder extends io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1IngressSpecBuilder + extends io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl< + io.kubernetes.client.openapi.models.V1IngressSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1IngressSpec, + io.kubernetes.client.openapi.models.V1IngressSpecBuilder> { public V1IngressSpecBuilder() { this(false); } + public V1IngressSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1IngressSpec(), validationEnabled); } + public V1IngressSpecBuilder(io.kubernetes.client.openapi.models.V1IngressSpecFluent fluent) { this(fluent, false); } - public V1IngressSpecBuilder(io.kubernetes.client.openapi.models.V1IngressSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1IngressSpecBuilder( + io.kubernetes.client.openapi.models.V1IngressSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1IngressSpec(), validationEnabled); } - public V1IngressSpecBuilder(io.kubernetes.client.openapi.models.V1IngressSpecFluent fluent,io.kubernetes.client.openapi.models.V1IngressSpec instance) { + + public V1IngressSpecBuilder( + io.kubernetes.client.openapi.models.V1IngressSpecFluent fluent, + io.kubernetes.client.openapi.models.V1IngressSpec instance) { this(fluent, instance, false); } - public V1IngressSpecBuilder(io.kubernetes.client.openapi.models.V1IngressSpecFluent fluent,io.kubernetes.client.openapi.models.V1IngressSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1IngressSpecBuilder( + io.kubernetes.client.openapi.models.V1IngressSpecFluent fluent, + io.kubernetes.client.openapi.models.V1IngressSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDefaultBackend(instance.getDefaultBackend()); fluent.withIngressClassName(instance.getIngressClassName()); @@ -29,13 +55,17 @@ public V1IngressSpecBuilder(io.kubernetes.client.openapi.models.V1IngressSpecFlu fluent.withTls(instance.getTls()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1IngressSpecBuilder(io.kubernetes.client.openapi.models.V1IngressSpec instance) { - this(instance,false); + this(instance, false); } - public V1IngressSpecBuilder(io.kubernetes.client.openapi.models.V1IngressSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1IngressSpecBuilder( + io.kubernetes.client.openapi.models.V1IngressSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDefaultBackend(instance.getDefaultBackend()); this.withIngressClassName(instance.getIngressClassName()); @@ -44,10 +74,12 @@ public V1IngressSpecBuilder(io.kubernetes.client.openapi.models.V1IngressSpec in this.withTls(instance.getTls()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1IngressSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1IngressSpec build() { V1IngressSpec buildable = new V1IngressSpec(); buildable.setDefaultBackend(fluent.getDefaultBackend()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1IngressSpec build() { buildable.setTls(fluent.getTls()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1IngressSpecBuilder that = (V1IngressSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressSpecFluent.java index 0424460ad2..f70930a7bf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressSpecFluent.java @@ -1,121 +1,221 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1IngressSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1IngressSpecFluent< + A extends io.kubernetes.client.openapi.models.V1IngressSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildDefaultBackend instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressBackend getDefaultBackend(); + public io.kubernetes.client.openapi.models.V1IngressBackend buildDefaultBackend(); + public A withDefaultBackend(io.kubernetes.client.openapi.models.V1IngressBackend defaultBackend); + public java.lang.Boolean hasDefaultBackend(); - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested withNewDefaultBackend(); - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested withNewDefaultBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item); - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested editDefaultBackend(); - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested editOrNewDefaultBackend(); - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested editOrNewDefaultBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested + withNewDefaultBackend(); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested + withNewDefaultBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested + editDefaultBackend(); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested + editOrNewDefaultBackend(); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested + editOrNewDefaultBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item); + public java.lang.String getIngressClassName(); + public A withIngressClassName(java.lang.String ingressClassName); + public java.lang.Boolean hasIngressClassName(); - - /** - * Method is deprecated. use withIngressClassName instead. - */ + + /** Method is deprecated. use withIngressClassName instead. */ @java.lang.Deprecated public A withNewIngressClassName(java.lang.String original); - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressRule item); - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressRule item); + + public A addToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressRule item); + + public A setToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressRule item); + public A addToRules(io.kubernetes.client.openapi.models.V1IngressRule... items); - public A addAllToRules(java.util.Collection items); + + public A addAllToRules( + java.util.Collection items); + public A removeFromRules(io.kubernetes.client.openapi.models.V1IngressRule... items); - public A removeAllFromRules(java.util.Collection items); - public A removeMatchingFromRules(java.util.function.Predicate predicate); - + + public A removeAllFromRules( + java.util.Collection items); + + public A removeMatchingFromRules( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildRules instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getRules(); + public java.util.List buildRules(); + public io.kubernetes.client.openapi.models.V1IngressRule buildRule(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1IngressRule buildFirstRule(); + public io.kubernetes.client.openapi.models.V1IngressRule buildLastRule(); - public io.kubernetes.client.openapi.models.V1IngressRule buildMatchingRule(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1IngressRule buildMatchingRule( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate + predicate); + public A withRules(java.util.List rules); + public A withRules(io.kubernetes.client.openapi.models.V1IngressRule... rules); + public java.lang.Boolean hasRules(); + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested addNewRule(); - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1IngressRule item); - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressRule item); - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested editRule(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested addNewRuleLike( + io.kubernetes.client.openapi.models.V1IngressRule item); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested setNewRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressRule item); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested editRule( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested editFirstRule(); + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested editLastRule(); - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate); - public A addToTls(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressTLS item); - public A setToTls(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressTLS item); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested editMatchingRule( + java.util.function.Predicate + predicate); + + public A addToTls(java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressTLS item); + + public A setToTls(java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressTLS item); + public A addToTls(io.kubernetes.client.openapi.models.V1IngressTLS... items); - public A addAllToTls(java.util.Collection items); + + public A addAllToTls( + java.util.Collection items); + public A removeFromTls(io.kubernetes.client.openapi.models.V1IngressTLS... items); - public A removeAllFromTls(java.util.Collection items); - public A removeMatchingFromTls(java.util.function.Predicate predicate); - + + public A removeAllFromTls( + java.util.Collection items); + + public A removeMatchingFromTls( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildTls instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getTls(); + public java.util.List buildTls(); + public io.kubernetes.client.openapi.models.V1IngressTLS buildTl(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1IngressTLS buildFirstTl(); + public io.kubernetes.client.openapi.models.V1IngressTLS buildLastTl(); - public io.kubernetes.client.openapi.models.V1IngressTLS buildMatchingTl(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingTl(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1IngressTLS buildMatchingTl( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingTl( + java.util.function.Predicate + predicate); + public A withTls(java.util.List tls); + public A withTls(io.kubernetes.client.openapi.models.V1IngressTLS... tls); + public java.lang.Boolean hasTls(); + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested addNewTl(); - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested addNewTlLike(io.kubernetes.client.openapi.models.V1IngressTLS item); - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested setNewTlLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressTLS item); - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested editTl(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested addNewTlLike( + io.kubernetes.client.openapi.models.V1IngressTLS item); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested setNewTlLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressTLS item); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested editTl( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested editFirstTl(); + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested editLastTl(); - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested editMatchingTl(java.util.function.Predicate predicate); - public interface DefaultBackendNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1IngressBackendFluent>{ + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested editMatchingTl( + java.util.function.Predicate + predicate); + + public interface DefaultBackendNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1IngressBackendFluent< + io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested> { public N and(); + public N endDefaultBackend(); - } - public interface RulesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1IngressRuleFluent>{ + + public interface RulesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1IngressRuleFluent< + io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested> { public N and(); + public N endRule(); - } - public interface TlsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1IngressTLSFluent>{ + + public interface TlsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1IngressTLSFluent< + io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested> { public N and(); + public N endTl(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressSpecFluentImpl.java index ff5e1f5614..652e49e6a9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressSpecFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1IngressSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1IngressSpecFluent{ - public V1IngressSpecFluentImpl() { - } +/** Generated */ +public class V1IngressSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1IngressSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1IngressSpecFluent { + public V1IngressSpecFluentImpl() {} + public V1IngressSpecFluentImpl(io.kubernetes.client.openapi.models.V1IngressSpec instance) { this.withDefaultBackend(instance.getDefaultBackend()); @@ -28,91 +30,184 @@ public V1IngressSpecFluentImpl(io.kubernetes.client.openapi.models.V1IngressSpec this.withRules(instance.getRules()); this.withTls(instance.getTls()); - } + private io.kubernetes.client.openapi.models.V1IngressBackendBuilder defaultBackend; private java.lang.String ingressClassName; private java.util.ArrayList rules; private java.util.ArrayList tls; - + /** * This method has been deprecated, please use method buildDefaultBackend instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IngressBackend getDefaultBackend() { - return this.defaultBackend!=null ?this.defaultBackend.build():null; + return this.defaultBackend != null ? this.defaultBackend.build() : null; } + public io.kubernetes.client.openapi.models.V1IngressBackend buildDefaultBackend() { - return this.defaultBackend!=null ?this.defaultBackend.build():null; + return this.defaultBackend != null ? this.defaultBackend.build() : null; } + public A withDefaultBackend(io.kubernetes.client.openapi.models.V1IngressBackend defaultBackend) { _visitables.get("defaultBackend").remove(this.defaultBackend); - if (defaultBackend!=null){ this.defaultBackend= new io.kubernetes.client.openapi.models.V1IngressBackendBuilder(defaultBackend); _visitables.get("defaultBackend").add(this.defaultBackend);} return (A) this; + if (defaultBackend != null) { + this.defaultBackend = + new io.kubernetes.client.openapi.models.V1IngressBackendBuilder(defaultBackend); + _visitables.get("defaultBackend").add(this.defaultBackend); + } + return (A) this; } + public java.lang.Boolean hasDefaultBackend() { return this.defaultBackend != null; } - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested withNewDefaultBackend() { - return new io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl.DefaultBackendNestedImpl(); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested + withNewDefaultBackend() { + return new io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl + .DefaultBackendNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested withNewDefaultBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item) { - return new io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl.DefaultBackendNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested + withNewDefaultBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item) { + return new io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl.DefaultBackendNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested editDefaultBackend() { + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested + editDefaultBackend() { return withNewDefaultBackendLike(getDefaultBackend()); } - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested editOrNewDefaultBackend() { - return withNewDefaultBackendLike(getDefaultBackend() != null ? getDefaultBackend(): new io.kubernetes.client.openapi.models.V1IngressBackendBuilder().build()); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested + editOrNewDefaultBackend() { + return withNewDefaultBackendLike( + getDefaultBackend() != null + ? getDefaultBackend() + : new io.kubernetes.client.openapi.models.V1IngressBackendBuilder().build()); } - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested editOrNewDefaultBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item) { - return withNewDefaultBackendLike(getDefaultBackend() != null ? getDefaultBackend(): item); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested + editOrNewDefaultBackendLike(io.kubernetes.client.openapi.models.V1IngressBackend item) { + return withNewDefaultBackendLike(getDefaultBackend() != null ? getDefaultBackend() : item); } + public java.lang.String getIngressClassName() { return this.ingressClassName; } + public A withIngressClassName(java.lang.String ingressClassName) { - this.ingressClassName=ingressClassName; return (A) this; + this.ingressClassName = ingressClassName; + return (A) this; } + public java.lang.Boolean hasIngressClassName() { return this.ingressClassName != null; } - - /** - * Method is deprecated. use withIngressClassName instead. - */ + + /** Method is deprecated. use withIngressClassName instead. */ @java.lang.Deprecated public A withNewIngressClassName(java.lang.String original) { - return (A)withIngressClassName(new String(original)); + return (A) withIngressClassName(new String(original)); } - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressRule item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(item);_visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder);this.rules.add(index >= 0 ? index : rules.size(), builder); return (A)this; + + public A addToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressRule item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(item); + _visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder); + this.rules.add(index >= 0 ? index : rules.size(), builder); + return (A) this; } - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressRule item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(item); - if (index < 0 || index >= _visitables.get("rules").size()) { _visitables.get("rules").add(builder); } else { _visitables.get("rules").set(index, builder);} - if (index < 0 || index >= rules.size()) { rules.add(builder); } else { rules.set(index, builder);} - return (A)this; + + public A setToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressRule item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(item); + if (index < 0 || index >= _visitables.get("rules").size()) { + _visitables.get("rules").add(builder); + } else { + _visitables.get("rules").set(index, builder); + } + if (index < 0 || index >= rules.size()) { + rules.add(builder); + } else { + rules.set(index, builder); + } + return (A) this; } + public A addToRules(io.kubernetes.client.openapi.models.V1IngressRule... items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1IngressRule item : items) {io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + if (this.rules == null) { + this.rules = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1IngressRule item : items) { + io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } - public A addAllToRules(java.util.Collection items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1IngressRule item : items) {io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + + public A addAllToRules( + java.util.Collection items) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1IngressRule item : items) { + io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } + public A removeFromRules(io.kubernetes.client.openapi.models.V1IngressRule... items) { - for (io.kubernetes.client.openapi.models.V1IngressRule item : items) {io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1IngressRule item : items) { + io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeAllFromRules(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1IngressRule item : items) {io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + + public A removeAllFromRules( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1IngressRule item : items) { + io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromRules(java.util.function.Predicate predicate) { + + public A removeMatchingFromRules( + java.util.function.Predicate + predicate) { if (rules == null) return (A) this; - final Iterator each = rules.iterator(); + final Iterator each = + rules.iterator(); final List visitables = _visitables.get("rules"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder = each.next(); @@ -121,102 +216,222 @@ public A removeMatchingFromRules(java.util.function.Predicate getRules() { return rules != null ? build(rules) : null; } + public java.util.List buildRules() { return rules != null ? build(rules) : null; } + public io.kubernetes.client.openapi.models.V1IngressRule buildRule(java.lang.Integer index) { return this.rules.get(index).build(); } + public io.kubernetes.client.openapi.models.V1IngressRule buildFirstRule() { return this.rules.get(0).build(); } + public io.kubernetes.client.openapi.models.V1IngressRule buildLastRule() { return this.rules.get(rules.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1IngressRule buildMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1IngressRuleBuilder item: rules) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1IngressRule buildMatchingRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1IngressRuleBuilder item : rules) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1IngressRuleBuilder item: rules) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1IngressRuleBuilder item : rules) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withRules(java.util.List rules) { - if (this.rules != null) { _visitables.get("rules").removeAll(this.rules);} - if (rules != null) {this.rules = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1IngressRule item : rules){this.addToRules(item);}} else { this.rules = null;} return (A) this; + if (this.rules != null) { + _visitables.get("rules").removeAll(this.rules); + } + if (rules != null) { + this.rules = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1IngressRule item : rules) { + this.addToRules(item); + } + } else { + this.rules = null; + } + return (A) this; } + public A withRules(io.kubernetes.client.openapi.models.V1IngressRule... rules) { - if (this.rules != null) {this.rules.clear();} - if (rules != null) {for (io.kubernetes.client.openapi.models.V1IngressRule item :rules){ this.addToRules(item);}} return (A) this; + if (this.rules != null) { + this.rules.clear(); + } + if (rules != null) { + for (io.kubernetes.client.openapi.models.V1IngressRule item : rules) { + this.addToRules(item); + } + } + return (A) this; } + public java.lang.Boolean hasRules() { return rules != null && !rules.isEmpty(); } + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested addNewRule() { return new io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl.RulesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1IngressRule item) { - return new io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl.RulesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested addNewRuleLike( + io.kubernetes.client.openapi.models.V1IngressRule item) { + return new io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl.RulesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressRule item) { - return new io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl.RulesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested setNewRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressRule item) { + return new io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl.RulesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested editRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested editRule( + java.lang.Integer index) { if (rules.size() <= index) throw new RuntimeException("Can't edit rules. Index exceeds size."); return setNewRuleLike(index, buildRule(index)); } + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested editFirstRule() { if (rules.size() == 0) throw new RuntimeException("Can't edit first rules. The list is empty."); return setNewRuleLike(0, buildRule(0)); } + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested editLastRule() { int index = rules.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last rules. The list is empty."); return setNewRuleLike(index, buildRule(index)); } - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested editMatchingRule( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1IngressTLSBuilder builder = new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(item);_visitables.get("tls").add(index >= 0 ? index : _visitables.get("tls").size(), builder);this.tls.add(index >= 0 ? index : tls.size(), builder); return (A)this; + + public A addToTls( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressTLS item) { + if (this.tls == null) { + this.tls = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1IngressTLSBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(item); + _visitables.get("tls").add(index >= 0 ? index : _visitables.get("tls").size(), builder); + this.tls.add(index >= 0 ? index : tls.size(), builder); + return (A) this; } - public A setToTls(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressTLS item) { - if (this.tls == null) {this.tls = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1IngressTLSBuilder builder = new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(item); - if (index < 0 || index >= _visitables.get("tls").size()) { _visitables.get("tls").add(builder); } else { _visitables.get("tls").set(index, builder);} - if (index < 0 || index >= tls.size()) { tls.add(builder); } else { tls.set(index, builder);} - return (A)this; + + public A setToTls( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressTLS item) { + if (this.tls == null) { + this.tls = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1IngressTLSBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(item); + if (index < 0 || index >= _visitables.get("tls").size()) { + _visitables.get("tls").add(builder); + } else { + _visitables.get("tls").set(index, builder); + } + if (index < 0 || index >= tls.size()) { + tls.add(builder); + } else { + tls.set(index, builder); + } + return (A) this; } + public A addToTls(io.kubernetes.client.openapi.models.V1IngressTLS... items) { - if (this.tls == null) {this.tls = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1IngressTLS item : items) {io.kubernetes.client.openapi.models.V1IngressTLSBuilder builder = new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(item);_visitables.get("tls").add(builder);this.tls.add(builder);} return (A)this; + if (this.tls == null) { + this.tls = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1IngressTLS item : items) { + io.kubernetes.client.openapi.models.V1IngressTLSBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(item); + _visitables.get("tls").add(builder); + this.tls.add(builder); + } + return (A) this; } - public A addAllToTls(java.util.Collection items) { - if (this.tls == null) {this.tls = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1IngressTLS item : items) {io.kubernetes.client.openapi.models.V1IngressTLSBuilder builder = new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(item);_visitables.get("tls").add(builder);this.tls.add(builder);} return (A)this; + + public A addAllToTls( + java.util.Collection items) { + if (this.tls == null) { + this.tls = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1IngressTLS item : items) { + io.kubernetes.client.openapi.models.V1IngressTLSBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(item); + _visitables.get("tls").add(builder); + this.tls.add(builder); + } + return (A) this; } + public A removeFromTls(io.kubernetes.client.openapi.models.V1IngressTLS... items) { - for (io.kubernetes.client.openapi.models.V1IngressTLS item : items) {io.kubernetes.client.openapi.models.V1IngressTLSBuilder builder = new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(item);_visitables.get("tls").remove(builder);if (this.tls != null) {this.tls.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1IngressTLS item : items) { + io.kubernetes.client.openapi.models.V1IngressTLSBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(item); + _visitables.get("tls").remove(builder); + if (this.tls != null) { + this.tls.remove(builder); + } + } + return (A) this; } - public A removeAllFromTls(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1IngressTLS item : items) {io.kubernetes.client.openapi.models.V1IngressTLSBuilder builder = new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(item);_visitables.get("tls").remove(builder);if (this.tls != null) {this.tls.remove(builder);}} return (A)this; + + public A removeAllFromTls( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1IngressTLS item : items) { + io.kubernetes.client.openapi.models.V1IngressTLSBuilder builder = + new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(item); + _visitables.get("tls").remove(builder); + if (this.tls != null) { + this.tls.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromTls(java.util.function.Predicate predicate) { + + public A removeMatchingFromTls( + java.util.function.Predicate + predicate) { if (tls == null) return (A) this; final Iterator each = tls.iterator(); final List visitables = _visitables.get("tls"); @@ -227,142 +442,229 @@ public A removeMatchingFromTls(java.util.function.Predicate getTls() { return tls != null ? build(tls) : null; } + public java.util.List buildTls() { return tls != null ? build(tls) : null; } + public io.kubernetes.client.openapi.models.V1IngressTLS buildTl(java.lang.Integer index) { return this.tls.get(index).build(); } + public io.kubernetes.client.openapi.models.V1IngressTLS buildFirstTl() { return this.tls.get(0).build(); } + public io.kubernetes.client.openapi.models.V1IngressTLS buildLastTl() { return this.tls.get(tls.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1IngressTLS buildMatchingTl(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1IngressTLSBuilder item: tls) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1IngressTLS buildMatchingTl( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1IngressTLSBuilder item : tls) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingTl(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1IngressTLSBuilder item: tls) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingTl( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1IngressTLSBuilder item : tls) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withTls(java.util.List tls) { - if (this.tls != null) { _visitables.get("tls").removeAll(this.tls);} - if (tls != null) {this.tls = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1IngressTLS item : tls){this.addToTls(item);}} else { this.tls = null;} return (A) this; + if (this.tls != null) { + _visitables.get("tls").removeAll(this.tls); + } + if (tls != null) { + this.tls = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1IngressTLS item : tls) { + this.addToTls(item); + } + } else { + this.tls = null; + } + return (A) this; } + public A withTls(io.kubernetes.client.openapi.models.V1IngressTLS... tls) { - if (this.tls != null) {this.tls.clear();} - if (tls != null) {for (io.kubernetes.client.openapi.models.V1IngressTLS item :tls){ this.addToTls(item);}} return (A) this; + if (this.tls != null) { + this.tls.clear(); + } + if (tls != null) { + for (io.kubernetes.client.openapi.models.V1IngressTLS item : tls) { + this.addToTls(item); + } + } + return (A) this; } + public java.lang.Boolean hasTls() { return tls != null && !tls.isEmpty(); } + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested addNewTl() { return new io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl.TlsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested addNewTlLike(io.kubernetes.client.openapi.models.V1IngressTLS item) { + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested addNewTlLike( + io.kubernetes.client.openapi.models.V1IngressTLS item) { return new io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl.TlsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested setNewTlLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressTLS item) { - return new io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl.TlsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested setNewTlLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressTLS item) { + return new io.kubernetes.client.openapi.models.V1IngressSpecFluentImpl.TlsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested editTl(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested editTl( + java.lang.Integer index) { if (tls.size() <= index) throw new RuntimeException("Can't edit tls. Index exceeds size."); return setNewTlLike(index, buildTl(index)); } + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested editFirstTl() { if (tls.size() == 0) throw new RuntimeException("Can't edit first tls. The list is empty."); return setNewTlLike(0, buildTl(0)); } + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested editLastTl() { int index = tls.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last tls. The list is empty."); return setNewTlLike(index, buildTl(index)); } - public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested editMatchingTl(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested editMatchingTl( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1IngressBackendFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested,io.kubernetes.client.fluent.Nested{ + + public class DefaultBackendNestedImpl + extends io.kubernetes.client.openapi.models.V1IngressBackendFluentImpl< + io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested> + implements io.kubernetes.client.openapi.models.V1IngressSpecFluent.DefaultBackendNested, + io.kubernetes.client.fluent.Nested { DefaultBackendNestedImpl(io.kubernetes.client.openapi.models.V1IngressBackend item) { this.builder = new io.kubernetes.client.openapi.models.V1IngressBackendBuilder(this, item); } + DefaultBackendNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1IngressBackendBuilder(this); } + io.kubernetes.client.openapi.models.V1IngressBackendBuilder builder; + public N and() { return (N) V1IngressSpecFluentImpl.this.withDefaultBackend(builder.build()); } + public N endDefaultBackend() { return and(); } - } - public class RulesNestedImpl extends io.kubernetes.client.openapi.models.V1IngressRuleFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested,io.kubernetes.client.fluent.Nested{ - RulesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressRule item) { + + public class RulesNestedImpl + extends io.kubernetes.client.openapi.models.V1IngressRuleFluentImpl< + io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested> + implements io.kubernetes.client.openapi.models.V1IngressSpecFluent.RulesNested, + io.kubernetes.client.fluent.Nested { + RulesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressRule item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(this, item); } + RulesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1IngressRuleBuilder(this); } + io.kubernetes.client.openapi.models.V1IngressRuleBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1IngressSpecFluentImpl.this.setToRules(index,builder.build()); + return (N) V1IngressSpecFluentImpl.this.setToRules(index, builder.build()); } + public N endRule() { return and(); } - } - public class TlsNestedImpl extends io.kubernetes.client.openapi.models.V1IngressTLSFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested,io.kubernetes.client.fluent.Nested{ - TlsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1IngressTLS item) { + + public class TlsNestedImpl + extends io.kubernetes.client.openapi.models.V1IngressTLSFluentImpl< + io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested> + implements io.kubernetes.client.openapi.models.V1IngressSpecFluent.TlsNested, + io.kubernetes.client.fluent.Nested { + TlsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1IngressTLS item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(this, item); } + TlsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1IngressTLSBuilder(this); } + io.kubernetes.client.openapi.models.V1IngressTLSBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1IngressSpecFluentImpl.this.setToTls(index,builder.build()); + return (N) V1IngressSpecFluentImpl.this.setToTls(index, builder.build()); } + public N endTl() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressStatusBuilder.java index 956ad422f2..0e7f61bc0a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressStatusBuilder.java @@ -1,58 +1,96 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1IngressStatusBuilder extends io.kubernetes.client.openapi.models.V1IngressStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1IngressStatusBuilder + extends io.kubernetes.client.openapi.models.V1IngressStatusFluentImpl< + io.kubernetes.client.openapi.models.V1IngressStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1IngressStatus, + io.kubernetes.client.openapi.models.V1IngressStatusBuilder> { public V1IngressStatusBuilder() { this(false); } + public V1IngressStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1IngressStatus(), validationEnabled); } - public V1IngressStatusBuilder(io.kubernetes.client.openapi.models.V1IngressStatusFluent fluent) { + + public V1IngressStatusBuilder( + io.kubernetes.client.openapi.models.V1IngressStatusFluent fluent) { this(fluent, false); } - public V1IngressStatusBuilder(io.kubernetes.client.openapi.models.V1IngressStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1IngressStatusBuilder( + io.kubernetes.client.openapi.models.V1IngressStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1IngressStatus(), validationEnabled); } - public V1IngressStatusBuilder(io.kubernetes.client.openapi.models.V1IngressStatusFluent fluent,io.kubernetes.client.openapi.models.V1IngressStatus instance) { + + public V1IngressStatusBuilder( + io.kubernetes.client.openapi.models.V1IngressStatusFluent fluent, + io.kubernetes.client.openapi.models.V1IngressStatus instance) { this(fluent, instance, false); } - public V1IngressStatusBuilder(io.kubernetes.client.openapi.models.V1IngressStatusFluent fluent,io.kubernetes.client.openapi.models.V1IngressStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1IngressStatusBuilder( + io.kubernetes.client.openapi.models.V1IngressStatusFluent fluent, + io.kubernetes.client.openapi.models.V1IngressStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLoadBalancer(instance.getLoadBalancer()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1IngressStatusBuilder(io.kubernetes.client.openapi.models.V1IngressStatus instance) { - this(instance,false); + this(instance, false); } - public V1IngressStatusBuilder(io.kubernetes.client.openapi.models.V1IngressStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1IngressStatusBuilder( + io.kubernetes.client.openapi.models.V1IngressStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLoadBalancer(instance.getLoadBalancer()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1IngressStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1IngressStatus build() { V1IngressStatus buildable = new V1IngressStatus(); buildable.setLoadBalancer(fluent.getLoadBalancer()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1IngressStatusBuilder that = (V1IngressStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressStatusFluent.java index 4aad8fdb5f..018e2207f3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressStatusFluent.java @@ -1,35 +1,57 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1IngressStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1IngressStatusFluent< + A extends io.kubernetes.client.openapi.models.V1IngressStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildLoadBalancer instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LoadBalancerStatus getLoadBalancer(); + public io.kubernetes.client.openapi.models.V1LoadBalancerStatus buildLoadBalancer(); + public A withLoadBalancer(io.kubernetes.client.openapi.models.V1LoadBalancerStatus loadBalancer); + public java.lang.Boolean hasLoadBalancer(); - public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested withNewLoadBalancer(); - public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested withNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item); - public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested editLoadBalancer(); - public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested editOrNewLoadBalancer(); - public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested editOrNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item); - public interface LoadBalancerNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent>{ + + public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested + withNewLoadBalancer(); + + public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested + withNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item); + + public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested + editLoadBalancer(); + + public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested + editOrNewLoadBalancer(); + + public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested + editOrNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item); + + public interface LoadBalancerNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent< + io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested> { public N and(); + public N endLoadBalancer(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressStatusFluentImpl.java index 2a068eef8f..6ad06dfea9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressStatusFluentImpl.java @@ -1,81 +1,123 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1IngressStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1IngressStatusFluent{ - public V1IngressStatusFluentImpl() { - } +/** Generated */ +public class V1IngressStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1IngressStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1IngressStatusFluent { + public V1IngressStatusFluentImpl() {} + public V1IngressStatusFluentImpl(io.kubernetes.client.openapi.models.V1IngressStatus instance) { this.withLoadBalancer(instance.getLoadBalancer()); - } + private io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder loadBalancer; - + /** * This method has been deprecated, please use method buildLoadBalancer instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LoadBalancerStatus getLoadBalancer() { - return this.loadBalancer!=null ?this.loadBalancer.build():null; + return this.loadBalancer != null ? this.loadBalancer.build() : null; } + public io.kubernetes.client.openapi.models.V1LoadBalancerStatus buildLoadBalancer() { - return this.loadBalancer!=null ?this.loadBalancer.build():null; + return this.loadBalancer != null ? this.loadBalancer.build() : null; } + public A withLoadBalancer(io.kubernetes.client.openapi.models.V1LoadBalancerStatus loadBalancer) { _visitables.get("loadBalancer").remove(this.loadBalancer); - if (loadBalancer!=null){ this.loadBalancer= new io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder(loadBalancer); _visitables.get("loadBalancer").add(this.loadBalancer);} return (A) this; + if (loadBalancer != null) { + this.loadBalancer = + new io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder(loadBalancer); + _visitables.get("loadBalancer").add(this.loadBalancer); + } + return (A) this; } + public java.lang.Boolean hasLoadBalancer() { return this.loadBalancer != null; } - public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested withNewLoadBalancer() { - return new io.kubernetes.client.openapi.models.V1IngressStatusFluentImpl.LoadBalancerNestedImpl(); + + public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested + withNewLoadBalancer() { + return new io.kubernetes.client.openapi.models.V1IngressStatusFluentImpl + .LoadBalancerNestedImpl(); } - public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested withNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item) { - return new io.kubernetes.client.openapi.models.V1IngressStatusFluentImpl.LoadBalancerNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested + withNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item) { + return new io.kubernetes.client.openapi.models.V1IngressStatusFluentImpl.LoadBalancerNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested editLoadBalancer() { + + public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested + editLoadBalancer() { return withNewLoadBalancerLike(getLoadBalancer()); } - public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested editOrNewLoadBalancer() { - return withNewLoadBalancerLike(getLoadBalancer() != null ? getLoadBalancer(): new io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested + editOrNewLoadBalancer() { + return withNewLoadBalancerLike( + getLoadBalancer() != null + ? getLoadBalancer() + : new io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested editOrNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item) { - return withNewLoadBalancerLike(getLoadBalancer() != null ? getLoadBalancer(): item); + + public io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested + editOrNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item) { + return withNewLoadBalancerLike(getLoadBalancer() != null ? getLoadBalancer() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1IngressStatusFluentImpl that = (V1IngressStatusFluentImpl) o; - if (loadBalancer != null ? !loadBalancer.equals(that.loadBalancer) :that.loadBalancer != null) return false; + if (loadBalancer != null ? !loadBalancer.equals(that.loadBalancer) : that.loadBalancer != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(loadBalancer, super.hashCode()); + return java.util.Objects.hash(loadBalancer, super.hashCode()); } - public class LoadBalancerNestedImpl extends io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested,io.kubernetes.client.fluent.Nested{ + + public class LoadBalancerNestedImpl + extends io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluentImpl< + io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested> + implements io.kubernetes.client.openapi.models.V1IngressStatusFluent.LoadBalancerNested, + io.kubernetes.client.fluent.Nested { LoadBalancerNestedImpl(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder(this, item); } + LoadBalancerNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder builder; + public N and() { return (N) V1IngressStatusFluentImpl.this.withLoadBalancer(builder.build()); } + public N endLoadBalancer() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressTLSBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressTLSBuilder.java index 62012d5174..dd2dba9276 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressTLSBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressTLSBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1IngressTLSBuilder extends io.kubernetes.client.openapi.models.V1IngressTLSFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1IngressTLSBuilder + extends io.kubernetes.client.openapi.models.V1IngressTLSFluentImpl< + io.kubernetes.client.openapi.models.V1IngressTLSBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1IngressTLS, + io.kubernetes.client.openapi.models.V1IngressTLSBuilder> { public V1IngressTLSBuilder() { this(false); } + public V1IngressTLSBuilder(java.lang.Boolean validationEnabled) { this(new V1IngressTLS(), validationEnabled); } + public V1IngressTLSBuilder(io.kubernetes.client.openapi.models.V1IngressTLSFluent fluent) { this(fluent, false); } - public V1IngressTLSBuilder(io.kubernetes.client.openapi.models.V1IngressTLSFluent fluent,java.lang.Boolean validationEnabled) { + + public V1IngressTLSBuilder( + io.kubernetes.client.openapi.models.V1IngressTLSFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1IngressTLS(), validationEnabled); } - public V1IngressTLSBuilder(io.kubernetes.client.openapi.models.V1IngressTLSFluent fluent,io.kubernetes.client.openapi.models.V1IngressTLS instance) { + + public V1IngressTLSBuilder( + io.kubernetes.client.openapi.models.V1IngressTLSFluent fluent, + io.kubernetes.client.openapi.models.V1IngressTLS instance) { this(fluent, instance, false); } - public V1IngressTLSBuilder(io.kubernetes.client.openapi.models.V1IngressTLSFluent fluent,io.kubernetes.client.openapi.models.V1IngressTLS instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1IngressTLSBuilder( + io.kubernetes.client.openapi.models.V1IngressTLSFluent fluent, + io.kubernetes.client.openapi.models.V1IngressTLS instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withHosts(instance.getHosts()); fluent.withSecretName(instance.getSecretName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1IngressTLSBuilder(io.kubernetes.client.openapi.models.V1IngressTLS instance) { - this(instance,false); + this(instance, false); } - public V1IngressTLSBuilder(io.kubernetes.client.openapi.models.V1IngressTLS instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1IngressTLSBuilder( + io.kubernetes.client.openapi.models.V1IngressTLS instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withHosts(instance.getHosts()); this.withSecretName(instance.getSecretName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1IngressTLSFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1IngressTLS build() { V1IngressTLS buildable = new V1IngressTLS(); buildable.setHosts(fluent.getHosts()); buildable.setSecretName(fluent.getSecretName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1IngressTLSBuilder that = (V1IngressTLSBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressTLSFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressTLSFluent.java index f4e9ceb251..23694d3ba3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressTLSFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressTLSFluent.java @@ -1,44 +1,61 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1IngressTLSFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToHosts(java.lang.Integer index,java.lang.String item); - public A setToHosts(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1IngressTLSFluent< + A extends io.kubernetes.client.openapi.models.V1IngressTLSFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToHosts(java.lang.Integer index, java.lang.String item); + + public A setToHosts(java.lang.Integer index, java.lang.String item); + public A addToHosts(java.lang.String... items); + public A addAllToHosts(java.util.Collection items); + public A removeFromHosts(java.lang.String... items); + public A removeAllFromHosts(java.util.Collection items); + public java.util.List getHosts(); + public java.lang.String getHost(java.lang.Integer index); + public java.lang.String getFirstHost(); + public java.lang.String getLastHost(); + public java.lang.String getMatchingHost(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingHost(java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingHost( + java.util.function.Predicate predicate); + public A withHosts(java.util.List hosts); + public A withHosts(java.lang.String... hosts); + public java.lang.Boolean hasHosts(); + public A addNewHost(java.lang.String original); + public java.lang.String getSecretName(); + public A withSecretName(java.lang.String secretName); + public java.lang.Boolean hasSecretName(); - - /** - * Method is deprecated. use withSecretName instead. - */ + + /** Method is deprecated. use withSecretName instead. */ @java.lang.Deprecated public A withNewSecretName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressTLSFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressTLSFluentImpl.java index a38d07e7e8..78278b1e38 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressTLSFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1IngressTLSFluentImpl.java @@ -1,111 +1,185 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1IngressTLSFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1IngressTLSFluent{ - public V1IngressTLSFluentImpl() { - } +/** Generated */ +public class V1IngressTLSFluentImpl< + A extends io.kubernetes.client.openapi.models.V1IngressTLSFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1IngressTLSFluent { + public V1IngressTLSFluentImpl() {} + public V1IngressTLSFluentImpl(io.kubernetes.client.openapi.models.V1IngressTLS instance) { this.withHosts(instance.getHosts()); this.withSecretName(instance.getSecretName()); - } + private java.util.List hosts; private java.lang.String secretName; - public A addToHosts(java.lang.Integer index,java.lang.String item) { - if (this.hosts == null) {this.hosts = new java.util.ArrayList();} + + public A addToHosts(java.lang.Integer index, java.lang.String item) { + if (this.hosts == null) { + this.hosts = new java.util.ArrayList(); + } this.hosts.add(index, item); - return (A)this; + return (A) this; } - public A setToHosts(java.lang.Integer index,java.lang.String item) { - if (this.hosts == null) {this.hosts = new java.util.ArrayList();} - this.hosts.set(index, item); return (A)this; + + public A setToHosts(java.lang.Integer index, java.lang.String item) { + if (this.hosts == null) { + this.hosts = new java.util.ArrayList(); + } + this.hosts.set(index, item); + return (A) this; } + public A addToHosts(java.lang.String... items) { - if (this.hosts == null) {this.hosts = new java.util.ArrayList();} - for (java.lang.String item : items) {this.hosts.add(item);} return (A)this; + if (this.hosts == null) { + this.hosts = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.hosts.add(item); + } + return (A) this; } + public A addAllToHosts(java.util.Collection items) { - if (this.hosts == null) {this.hosts = new java.util.ArrayList();} - for (java.lang.String item : items) {this.hosts.add(item);} return (A)this; + if (this.hosts == null) { + this.hosts = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.hosts.add(item); + } + return (A) this; } + public A removeFromHosts(java.lang.String... items) { - for (java.lang.String item : items) {if (this.hosts!= null){ this.hosts.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.hosts != null) { + this.hosts.remove(item); + } + } + return (A) this; } + public A removeAllFromHosts(java.util.Collection items) { - for (java.lang.String item : items) {if (this.hosts!= null){ this.hosts.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.hosts != null) { + this.hosts.remove(item); + } + } + return (A) this; } + public java.util.List getHosts() { return this.hosts; } + public java.lang.String getHost(java.lang.Integer index) { return this.hosts.get(index); } + public java.lang.String getFirstHost() { return this.hosts.get(0); } + public java.lang.String getLastHost() { return this.hosts.get(hosts.size() - 1); } - public java.lang.String getMatchingHost(java.util.function.Predicate predicate) { - for (java.lang.String item: hosts) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingHost( + java.util.function.Predicate predicate) { + for (java.lang.String item : hosts) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingHost(java.util.function.Predicate predicate) { - for (java.lang.String item: hosts) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingHost( + java.util.function.Predicate predicate) { + for (java.lang.String item : hosts) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withHosts(java.util.List hosts) { - if (hosts != null) {this.hosts = new java.util.ArrayList(); for (java.lang.String item : hosts){this.addToHosts(item);}} else { this.hosts = null;} return (A) this; + if (hosts != null) { + this.hosts = new java.util.ArrayList(); + for (java.lang.String item : hosts) { + this.addToHosts(item); + } + } else { + this.hosts = null; + } + return (A) this; } + public A withHosts(java.lang.String... hosts) { - if (this.hosts != null) {this.hosts.clear();} - if (hosts != null) {for (java.lang.String item :hosts){ this.addToHosts(item);}} return (A) this; + if (this.hosts != null) { + this.hosts.clear(); + } + if (hosts != null) { + for (java.lang.String item : hosts) { + this.addToHosts(item); + } + } + return (A) this; } + public java.lang.Boolean hasHosts() { return hosts != null && !hosts.isEmpty(); } + public A addNewHost(java.lang.String original) { - return (A)addToHosts(new String(original)); + return (A) addToHosts(new String(original)); } + public java.lang.String getSecretName() { return this.secretName; } + public A withSecretName(java.lang.String secretName) { - this.secretName=secretName; return (A) this; + this.secretName = secretName; + return (A) this; } + public java.lang.Boolean hasSecretName() { return this.secretName != null; } - - /** - * Method is deprecated. use withSecretName instead. - */ + + /** Method is deprecated. use withSecretName instead. */ @java.lang.Deprecated public A withNewSecretName(java.lang.String original) { - return (A)withSecretName(new String(original)); + return (A) withSecretName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1IngressTLSFluentImpl that = (V1IngressTLSFluentImpl) o; - if (hosts != null ? !hosts.equals(that.hosts) :that.hosts != null) return false; - if (secretName != null ? !secretName.equals(that.secretName) :that.secretName != null) return false; + if (hosts != null ? !hosts.equals(that.hosts) : that.hosts != null) return false; + if (secretName != null ? !secretName.equals(that.secretName) : that.secretName != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(hosts, secretName, super.hashCode()); + return java.util.Objects.hash(hosts, secretName, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JSONSchemaPropsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JSONSchemaPropsBuilder.java index 63abef2879..91ff8891f7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JSONSchemaPropsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JSONSchemaPropsBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1JSONSchemaPropsBuilder extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1JSONSchemaPropsBuilder + extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl< + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1JSONSchemaProps, + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder> { public V1JSONSchemaPropsBuilder() { this(false); } + public V1JSONSchemaPropsBuilder(java.lang.Boolean validationEnabled) { this(new V1JSONSchemaProps(), validationEnabled); } - public V1JSONSchemaPropsBuilder(io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent fluent) { + + public V1JSONSchemaPropsBuilder( + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent fluent) { this(fluent, false); } - public V1JSONSchemaPropsBuilder(io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1JSONSchemaPropsBuilder( + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1JSONSchemaProps(), validationEnabled); } - public V1JSONSchemaPropsBuilder(io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent fluent,io.kubernetes.client.openapi.models.V1JSONSchemaProps instance) { + + public V1JSONSchemaPropsBuilder( + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent fluent, + io.kubernetes.client.openapi.models.V1JSONSchemaProps instance) { this(fluent, instance, false); } - public V1JSONSchemaPropsBuilder(io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent fluent,io.kubernetes.client.openapi.models.V1JSONSchemaProps instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1JSONSchemaPropsBuilder( + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent fluent, + io.kubernetes.client.openapi.models.V1JSONSchemaProps instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withRef(instance.get$Ref()); fluent.withSchema(instance.get$Schema()); @@ -95,13 +122,17 @@ public V1JSONSchemaPropsBuilder(io.kubernetes.client.openapi.models.V1JSONSchema fluent.withUniqueItems(instance.getUniqueItems()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1JSONSchemaPropsBuilder(io.kubernetes.client.openapi.models.V1JSONSchemaProps instance) { - this(instance,false); + this(instance, false); } - public V1JSONSchemaPropsBuilder(io.kubernetes.client.openapi.models.V1JSONSchemaProps instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1JSONSchemaPropsBuilder( + io.kubernetes.client.openapi.models.V1JSONSchemaProps instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withRef(instance.get$Ref()); this.withSchema(instance.get$Schema()); @@ -176,10 +207,12 @@ public V1JSONSchemaPropsBuilder(io.kubernetes.client.openapi.models.V1JSONSchema this.withUniqueItems(instance.getUniqueItems()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1JSONSchemaProps build() { V1JSONSchemaProps buildable = new V1JSONSchemaProps(); buildable.set$Ref(fluent.getRef()); @@ -221,18 +254,23 @@ public io.kubernetes.client.openapi.models.V1JSONSchemaProps build() { buildable.setUniqueItems(fluent.getUniqueItems()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1JSONSchemaPropsBuilder that = (V1JSONSchemaPropsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JSONSchemaPropsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JSONSchemaPropsFluent.java index 72c7052508..5c6e7acb67 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JSONSchemaPropsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JSONSchemaPropsFluent.java @@ -1,357 +1,659 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Double; -import java.lang.Integer; -import java.lang.Long; -import java.util.Collection; -import java.lang.Object; -import java.util.Map; - - /** - * Generated - */ -public interface V1JSONSchemaPropsFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1JSONSchemaPropsFluent< + A extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getRef(); + public A withRef(java.lang.String $ref); + public java.lang.Boolean hasRef(); - - /** - * Method is deprecated. use withRef instead. - */ + + /** Method is deprecated. use withRef instead. */ @java.lang.Deprecated public A withNewRef(java.lang.String original); + public java.lang.String getSchema(); + public A withSchema(java.lang.String $schema); + public java.lang.Boolean hasSchema(); - - /** - * Method is deprecated. use withSchema instead. - */ + + /** Method is deprecated. use withSchema instead. */ @java.lang.Deprecated public A withNewSchema(java.lang.String original); + public java.lang.Object getAdditionalItems(); + public A withAdditionalItems(java.lang.Object additionalItems); + public java.lang.Boolean hasAdditionalItems(); + public java.lang.Object getAdditionalProperties(); + public A withAdditionalProperties(java.lang.Object additionalProperties); + public java.lang.Boolean hasAdditionalProperties(); - public A addToAllOf(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item); - public A setToAllOf(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public A addToAllOf( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public A setToAllOf( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + public A addToAllOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... items); - public A addAllToAllOf(java.util.Collection items); + + public A addAllToAllOf( + java.util.Collection items); + public A removeFromAllOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... items); - public A removeAllFromAllOf(java.util.Collection items); - public A removeMatchingFromAllOf(java.util.function.Predicate predicate); - + + public A removeAllFromAllOf( + java.util.Collection items); + + public A removeMatchingFromAllOf( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildAllOf instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getAllOf(); + public java.util.List buildAllOf(); + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildAllOf(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildFirstAllOf(); + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildLastAllOf(); - public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildMatchingAllOf(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAllOf(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildMatchingAllOf( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingAllOf( + java.util.function.Predicate + predicate); + public A withAllOf(java.util.List allOf); + public A withAllOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... allOf); + public java.lang.Boolean hasAllOf(); + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested addNewAllOf(); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested addNewAllOfLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested setNewAllOfLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested editAllOf(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested editFirstAllOf(); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested addNewAllOfLike( + io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested setNewAllOfLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested editAllOf( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested + editFirstAllOf(); + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested editLastAllOf(); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested editMatchingAllOf(java.util.function.Predicate predicate); - public A addToAnyOf(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item); - public A setToAnyOf(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested + editMatchingAllOf( + java.util.function.Predicate + predicate); + + public A addToAnyOf( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public A setToAnyOf( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + public A addToAnyOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... items); - public A addAllToAnyOf(java.util.Collection items); + + public A addAllToAnyOf( + java.util.Collection items); + public A removeFromAnyOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... items); - public A removeAllFromAnyOf(java.util.Collection items); - public A removeMatchingFromAnyOf(java.util.function.Predicate predicate); - + + public A removeAllFromAnyOf( + java.util.Collection items); + + public A removeMatchingFromAnyOf( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildAnyOf instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getAnyOf(); + public java.util.List buildAnyOf(); + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildAnyOf(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildFirstAnyOf(); + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildLastAnyOf(); - public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildMatchingAnyOf(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAnyOf(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildMatchingAnyOf( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingAnyOf( + java.util.function.Predicate + predicate); + public A withAnyOf(java.util.List anyOf); + public A withAnyOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... anyOf); + public java.lang.Boolean hasAnyOf(); + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested addNewAnyOf(); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested addNewAnyOfLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested setNewAnyOfLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested editAnyOf(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested editFirstAnyOf(); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested addNewAnyOfLike( + io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested setNewAnyOfLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested editAnyOf( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested + editFirstAnyOf(); + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested editLastAnyOf(); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested editMatchingAnyOf(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested + editMatchingAnyOf( + java.util.function.Predicate + predicate); + public java.lang.Object getDefault(); + public A withDefault(java.lang.Object _default); + public java.lang.Boolean hasDefault(); - public A addToDefinitions(java.lang.String key,io.kubernetes.client.openapi.models.V1JSONSchemaProps value); - public A addToDefinitions(java.util.Map map); + + public A addToDefinitions( + java.lang.String key, io.kubernetes.client.openapi.models.V1JSONSchemaProps value); + + public A addToDefinitions( + java.util.Map map); + public A removeFromDefinitions(java.lang.String key); - public A removeFromDefinitions(java.util.Map map); - public java.util.Map getDefinitions(); - public A withDefinitions(java.util.Map definitions); + + public A removeFromDefinitions( + java.util.Map map); + + public java.util.Map + getDefinitions(); + + public A withDefinitions( + java.util.Map + definitions); + public java.lang.Boolean hasDefinitions(); - public A addToDependencies(java.lang.String key,java.lang.Object value); - public A addToDependencies(java.util.Map map); + + public A addToDependencies(java.lang.String key, java.lang.Object value); + + public A addToDependencies(java.util.Map map); + public A removeFromDependencies(java.lang.String key); - public A removeFromDependencies(java.util.Map map); - public java.util.Map getDependencies(); - public A withDependencies(java.util.Map dependencies); + + public A removeFromDependencies(java.util.Map map); + + public java.util.Map getDependencies(); + + public A withDependencies(java.util.Map dependencies); + public java.lang.Boolean hasDependencies(); + public java.lang.String getDescription(); + public A withDescription(java.lang.String description); + public java.lang.Boolean hasDescription(); - - /** - * Method is deprecated. use withDescription instead. - */ + + /** Method is deprecated. use withDescription instead. */ @java.lang.Deprecated public A withNewDescription(java.lang.String original); - public A addToEnum(java.lang.Integer index,java.lang.Object item); - public A setToEnum(java.lang.Integer index,java.lang.Object item); + + public A addToEnum(java.lang.Integer index, java.lang.Object item); + + public A setToEnum(java.lang.Integer index, java.lang.Object item); + public A addToEnum(java.lang.Object... items); + public A addAllToEnum(java.util.Collection items); + public A removeFromEnum(java.lang.Object... items); + public A removeAllFromEnum(java.util.Collection items); + public java.util.List getEnum(); + public java.lang.Object getEnum(java.lang.Integer index); + public java.lang.Object getFirstEnum(); + public java.lang.Object getLastEnum(); + public java.lang.Object getMatchingEnum(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingEnum(java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingEnum( + java.util.function.Predicate predicate); + public A withEnum(java.util.List _enum); + public A withEnum(java.lang.Object... _enum); + public java.lang.Boolean hasEnum(); + public java.lang.Object getExample(); + public A withExample(java.lang.Object example); + public java.lang.Boolean hasExample(); + public java.lang.Boolean getExclusiveMaximum(); + public A withExclusiveMaximum(java.lang.Boolean exclusiveMaximum); + public java.lang.Boolean hasExclusiveMaximum(); + public java.lang.Boolean getExclusiveMinimum(); + public A withExclusiveMinimum(java.lang.Boolean exclusiveMinimum); + public java.lang.Boolean hasExclusiveMinimum(); - + /** * This method has been deprecated, please use method buildExternalDocs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ExternalDocumentation getExternalDocs(); + public io.kubernetes.client.openapi.models.V1ExternalDocumentation buildExternalDocs(); - public A withExternalDocs(io.kubernetes.client.openapi.models.V1ExternalDocumentation externalDocs); + + public A withExternalDocs( + io.kubernetes.client.openapi.models.V1ExternalDocumentation externalDocs); + public java.lang.Boolean hasExternalDocs(); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested withNewExternalDocs(); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested withNewExternalDocsLike(io.kubernetes.client.openapi.models.V1ExternalDocumentation item); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested editExternalDocs(); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested editOrNewExternalDocs(); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested editOrNewExternalDocsLike(io.kubernetes.client.openapi.models.V1ExternalDocumentation item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested + withNewExternalDocs(); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested + withNewExternalDocsLike(io.kubernetes.client.openapi.models.V1ExternalDocumentation item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested + editExternalDocs(); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested + editOrNewExternalDocs(); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested + editOrNewExternalDocsLike(io.kubernetes.client.openapi.models.V1ExternalDocumentation item); + public java.lang.String getFormat(); + public A withFormat(java.lang.String format); + public java.lang.Boolean hasFormat(); - - /** - * Method is deprecated. use withFormat instead. - */ + + /** Method is deprecated. use withFormat instead. */ @java.lang.Deprecated public A withNewFormat(java.lang.String original); + public java.lang.String getId(); + public A withId(java.lang.String id); + public java.lang.Boolean hasId(); - - /** - * Method is deprecated. use withId instead. - */ + + /** Method is deprecated. use withId instead. */ @java.lang.Deprecated public A withNewId(java.lang.String original); + public java.lang.Object getItems(); + public A withItems(java.lang.Object items); + public java.lang.Boolean hasItems(); + public java.lang.Long getMaxItems(); + public A withMaxItems(java.lang.Long maxItems); + public java.lang.Boolean hasMaxItems(); + public java.lang.Long getMaxLength(); + public A withMaxLength(java.lang.Long maxLength); + public java.lang.Boolean hasMaxLength(); + public java.lang.Long getMaxProperties(); + public A withMaxProperties(java.lang.Long maxProperties); + public java.lang.Boolean hasMaxProperties(); + public java.lang.Double getMaximum(); + public A withMaximum(java.lang.Double maximum); + public java.lang.Boolean hasMaximum(); + public java.lang.Long getMinItems(); + public A withMinItems(java.lang.Long minItems); + public java.lang.Boolean hasMinItems(); + public java.lang.Long getMinLength(); + public A withMinLength(java.lang.Long minLength); + public java.lang.Boolean hasMinLength(); + public java.lang.Long getMinProperties(); + public A withMinProperties(java.lang.Long minProperties); + public java.lang.Boolean hasMinProperties(); + public java.lang.Double getMinimum(); + public A withMinimum(java.lang.Double minimum); + public java.lang.Boolean hasMinimum(); + public java.lang.Double getMultipleOf(); + public A withMultipleOf(java.lang.Double multipleOf); + public java.lang.Boolean hasMultipleOf(); - + /** * This method has been deprecated, please use method buildNot instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JSONSchemaProps getNot(); + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildNot(); + public A withNot(io.kubernetes.client.openapi.models.V1JSONSchemaProps not); + public java.lang.Boolean hasNot(); + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested withNewNot(); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested withNewNotLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested withNewNotLike( + io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested editNot(); + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested editOrNewNot(); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested editOrNewNotLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested editOrNewNotLike( + io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + public java.lang.Boolean getNullable(); + public A withNullable(java.lang.Boolean nullable); + public java.lang.Boolean hasNullable(); - public A addToOneOf(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item); - public A setToOneOf(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public A addToOneOf( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public A setToOneOf( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + public A addToOneOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... items); - public A addAllToOneOf(java.util.Collection items); + + public A addAllToOneOf( + java.util.Collection items); + public A removeFromOneOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... items); - public A removeAllFromOneOf(java.util.Collection items); - public A removeMatchingFromOneOf(java.util.function.Predicate predicate); - + + public A removeAllFromOneOf( + java.util.Collection items); + + public A removeMatchingFromOneOf( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildOneOf instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getOneOf(); + public java.util.List buildOneOf(); + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildOneOf(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildFirstOneOf(); + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildLastOneOf(); - public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildMatchingOneOf(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingOneOf(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildMatchingOneOf( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingOneOf( + java.util.function.Predicate + predicate); + public A withOneOf(java.util.List oneOf); + public A withOneOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... oneOf); + public java.lang.Boolean hasOneOf(); + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested addNewOneOf(); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested addNewOneOfLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested setNewOneOfLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested editOneOf(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested editFirstOneOf(); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested addNewOneOfLike( + io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested setNewOneOfLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested editOneOf( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested + editFirstOneOf(); + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested editLastOneOf(); - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested editMatchingOneOf(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested + editMatchingOneOf( + java.util.function.Predicate + predicate); + public java.lang.String getPattern(); + public A withPattern(java.lang.String pattern); + public java.lang.Boolean hasPattern(); - - /** - * Method is deprecated. use withPattern instead. - */ + + /** Method is deprecated. use withPattern instead. */ @java.lang.Deprecated public A withNewPattern(java.lang.String original); - public A addToPatternProperties(java.lang.String key,io.kubernetes.client.openapi.models.V1JSONSchemaProps value); - public A addToPatternProperties(java.util.Map map); + + public A addToPatternProperties( + java.lang.String key, io.kubernetes.client.openapi.models.V1JSONSchemaProps value); + + public A addToPatternProperties( + java.util.Map map); + public A removeFromPatternProperties(java.lang.String key); - public A removeFromPatternProperties(java.util.Map map); - public java.util.Map getPatternProperties(); - public A withPatternProperties(java.util.Map patternProperties); + + public A removeFromPatternProperties( + java.util.Map map); + + public java.util.Map + getPatternProperties(); + + public A withPatternProperties( + java.util.Map + patternProperties); + public java.lang.Boolean hasPatternProperties(); - public A addToProperties(java.lang.String key,io.kubernetes.client.openapi.models.V1JSONSchemaProps value); - public A addToProperties(java.util.Map map); + + public A addToProperties( + java.lang.String key, io.kubernetes.client.openapi.models.V1JSONSchemaProps value); + + public A addToProperties( + java.util.Map map); + public A removeFromProperties(java.lang.String key); - public A removeFromProperties(java.util.Map map); - public java.util.Map getProperties(); - public A withProperties(java.util.Map properties); + + public A removeFromProperties( + java.util.Map map); + + public java.util.Map + getProperties(); + + public A withProperties( + java.util.Map + properties); + public java.lang.Boolean hasProperties(); - public A addToRequired(java.lang.Integer index,java.lang.String item); - public A setToRequired(java.lang.Integer index,java.lang.String item); + + public A addToRequired(java.lang.Integer index, java.lang.String item); + + public A setToRequired(java.lang.Integer index, java.lang.String item); + public A addToRequired(java.lang.String... items); + public A addAllToRequired(java.util.Collection items); + public A removeFromRequired(java.lang.String... items); + public A removeAllFromRequired(java.util.Collection items); + public java.util.List getRequired(); + public java.lang.String getRequired(java.lang.Integer index); + public java.lang.String getFirstRequired(); + public java.lang.String getLastRequired(); - public java.lang.String getMatchingRequired(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRequired(java.util.function.Predicate predicate); + + public java.lang.String getMatchingRequired( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingRequired( + java.util.function.Predicate predicate); + public A withRequired(java.util.List required); + public A withRequired(java.lang.String... required); + public java.lang.Boolean hasRequired(); + public A addNewRequired(java.lang.String original); + public java.lang.String getTitle(); + public A withTitle(java.lang.String title); + public java.lang.Boolean hasTitle(); - - /** - * Method is deprecated. use withTitle instead. - */ + + /** Method is deprecated. use withTitle instead. */ @java.lang.Deprecated public A withNewTitle(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); + public java.lang.Boolean getUniqueItems(); + public A withUniqueItems(java.lang.Boolean uniqueItems); + public java.lang.Boolean hasUniqueItems(); - public interface AllOfNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent>{ + + public interface AllOfNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent< + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested> { public N and(); + public N endAllOf(); - } - public interface AnyOfNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent>{ + + public interface AnyOfNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent< + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested> { public N and(); + public N endAnyOf(); - } - public interface ExternalDocsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent>{ + + public interface ExternalDocsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ExternalDocumentationFluent< + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested> { public N and(); + public N endExternalDocs(); - } - public interface NotNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent>{ + + public interface NotNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent< + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested> { public N and(); + public N endNot(); - } - public interface OneOfNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent>{ + + public interface OneOfNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent< + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested> { public N and(); + public N endOneOf(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JSONSchemaPropsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JSONSchemaPropsFluentImpl.java index ad497cf19d..f24866a43e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JSONSchemaPropsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JSONSchemaPropsFluentImpl.java @@ -1,30 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Double; -import java.lang.Integer; -import java.lang.Long; -import java.util.Collection; -import java.lang.Object; -import java.util.Map; - - /** - * Generated - */ -public class V1JSONSchemaPropsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent{ - public V1JSONSchemaPropsFluentImpl() { - } - public V1JSONSchemaPropsFluentImpl(io.kubernetes.client.openapi.models.V1JSONSchemaProps instance) { + +/** Generated */ +public class V1JSONSchemaPropsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent { + public V1JSONSchemaPropsFluentImpl() {} + + public V1JSONSchemaPropsFluentImpl( + io.kubernetes.client.openapi.models.V1JSONSchemaProps instance) { this.withRef(instance.get$Ref()); this.withSchema(instance.get$Schema()); @@ -98,8 +97,8 @@ public V1JSONSchemaPropsFluentImpl(io.kubernetes.client.openapi.models.V1JSONSch this.withType(instance.getType()); this.withUniqueItems(instance.getUniqueItems()); - } + private java.lang.String $ref; private java.lang.String $schema; private java.lang.Object additionalItems; @@ -107,8 +106,9 @@ public V1JSONSchemaPropsFluentImpl(io.kubernetes.client.openapi.models.V1JSONSch private java.util.ArrayList allOf; private java.util.ArrayList anyOf; private java.lang.Object _default; - private java.util.Map definitions; - private java.util.Map dependencies; + private java.util.Map + definitions; + private java.util.Map dependencies; private java.lang.String description; private java.util.List _enum; private java.lang.Object example; @@ -131,92 +131,173 @@ public V1JSONSchemaPropsFluentImpl(io.kubernetes.client.openapi.models.V1JSONSch private java.lang.Boolean nullable; private java.util.ArrayList oneOf; private java.lang.String pattern; - private java.util.Map patternProperties; - private java.util.Map properties; + private java.util.Map + patternProperties; + private java.util.Map + properties; private java.util.List required; private java.lang.String title; private java.lang.String type; private java.lang.Boolean uniqueItems; + public java.lang.String getRef() { return this.$ref; } + public A withRef(java.lang.String $ref) { - this.$ref=$ref; return (A) this; + this.$ref = $ref; + return (A) this; } + public java.lang.Boolean hasRef() { return this.$ref != null; } - - /** - * Method is deprecated. use withRef instead. - */ + + /** Method is deprecated. use withRef instead. */ @java.lang.Deprecated public A withNewRef(java.lang.String original) { - return (A)withRef(new String(original)); + return (A) withRef(new String(original)); } + public java.lang.String getSchema() { return this.$schema; } + public A withSchema(java.lang.String $schema) { - this.$schema=$schema; return (A) this; + this.$schema = $schema; + return (A) this; } + public java.lang.Boolean hasSchema() { return this.$schema != null; } - - /** - * Method is deprecated. use withSchema instead. - */ + + /** Method is deprecated. use withSchema instead. */ @java.lang.Deprecated public A withNewSchema(java.lang.String original) { - return (A)withSchema(new String(original)); + return (A) withSchema(new String(original)); } + public java.lang.Object getAdditionalItems() { return this.additionalItems; } + public A withAdditionalItems(java.lang.Object additionalItems) { - this.additionalItems=additionalItems; return (A) this; + this.additionalItems = additionalItems; + return (A) this; } + public java.lang.Boolean hasAdditionalItems() { return this.additionalItems != null; } + public java.lang.Object getAdditionalProperties() { return this.additionalProperties; } + public A withAdditionalProperties(java.lang.Object additionalProperties) { - this.additionalProperties=additionalProperties; return (A) this; + this.additionalProperties = additionalProperties; + return (A) this; } + public java.lang.Boolean hasAdditionalProperties() { return this.additionalProperties != null; } - public A addToAllOf(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - if (this.allOf == null) {this.allOf = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("allOf").add(index >= 0 ? index : _visitables.get("allOf").size(), builder);this.allOf.add(index >= 0 ? index : allOf.size(), builder); return (A)this; + + public A addToAllOf( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + if (this.allOf == null) { + this.allOf = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("allOf").add(index >= 0 ? index : _visitables.get("allOf").size(), builder); + this.allOf.add(index >= 0 ? index : allOf.size(), builder); + return (A) this; } - public A setToAllOf(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - if (this.allOf == null) {this.allOf = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); - if (index < 0 || index >= _visitables.get("allOf").size()) { _visitables.get("allOf").add(builder); } else { _visitables.get("allOf").set(index, builder);} - if (index < 0 || index >= allOf.size()) { allOf.add(builder); } else { allOf.set(index, builder);} - return (A)this; + + public A setToAllOf( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + if (this.allOf == null) { + this.allOf = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + if (index < 0 || index >= _visitables.get("allOf").size()) { + _visitables.get("allOf").add(builder); + } else { + _visitables.get("allOf").set(index, builder); + } + if (index < 0 || index >= allOf.size()) { + allOf.add(builder); + } else { + allOf.set(index, builder); + } + return (A) this; } + public A addToAllOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... items) { - if (this.allOf == null) {this.allOf = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) {io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("allOf").add(builder);this.allOf.add(builder);} return (A)this; + if (this.allOf == null) { + this.allOf = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) { + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("allOf").add(builder); + this.allOf.add(builder); + } + return (A) this; } - public A addAllToAllOf(java.util.Collection items) { - if (this.allOf == null) {this.allOf = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) {io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("allOf").add(builder);this.allOf.add(builder);} return (A)this; + + public A addAllToAllOf( + java.util.Collection items) { + if (this.allOf == null) { + this.allOf = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) { + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("allOf").add(builder); + this.allOf.add(builder); + } + return (A) this; } + public A removeFromAllOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... items) { - for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) {io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("allOf").remove(builder);if (this.allOf != null) {this.allOf.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) { + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("allOf").remove(builder); + if (this.allOf != null) { + this.allOf.remove(builder); + } + } + return (A) this; } - public A removeAllFromAllOf(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) {io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("allOf").remove(builder);if (this.allOf != null) {this.allOf.remove(builder);}} return (A)this; + + public A removeAllFromAllOf( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) { + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("allOf").remove(builder); + if (this.allOf != null) { + this.allOf.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromAllOf(java.util.function.Predicate predicate) { + + public A removeMatchingFromAllOf( + java.util.function.Predicate + predicate) { if (allOf == null) return (A) this; - final Iterator each = allOf.iterator(); + final Iterator each = + allOf.iterator(); final List visitables = _visitables.get("allOf"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = each.next(); @@ -225,104 +306,232 @@ public A removeMatchingFromAllOf(java.util.function.Predicate getAllOf() { return allOf != null ? build(allOf) : null; } + public java.util.List buildAllOf() { return allOf != null ? build(allOf) : null; } + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildAllOf(java.lang.Integer index) { return this.allOf.get(index).build(); } + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildFirstAllOf() { return this.allOf.get(0).build(); } + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildLastAllOf() { return this.allOf.get(allOf.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildMatchingAllOf(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder item: allOf) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildMatchingAllOf( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder item : allOf) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingAllOf(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder item: allOf) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAllOf( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder item : allOf) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAllOf(java.util.List allOf) { - if (this.allOf != null) { _visitables.get("allOf").removeAll(this.allOf);} - if (allOf != null) {this.allOf = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : allOf){this.addToAllOf(item);}} else { this.allOf = null;} return (A) this; + if (this.allOf != null) { + _visitables.get("allOf").removeAll(this.allOf); + } + if (allOf != null) { + this.allOf = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : allOf) { + this.addToAllOf(item); + } + } else { + this.allOf = null; + } + return (A) this; } + public A withAllOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... allOf) { - if (this.allOf != null) {this.allOf.clear();} - if (allOf != null) {for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item :allOf){ this.addToAllOf(item);}} return (A) this; + if (this.allOf != null) { + this.allOf.clear(); + } + if (allOf != null) { + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : allOf) { + this.addToAllOf(item); + } + } + return (A) this; } + public java.lang.Boolean hasAllOf() { return allOf != null && !allOf.isEmpty(); } + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested addNewAllOf() { return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.AllOfNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested addNewAllOfLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.AllOfNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested addNewAllOfLike( + io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.AllOfNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested setNewAllOfLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.AllOfNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested setNewAllOfLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.AllOfNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested editAllOf(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested editAllOf( + java.lang.Integer index) { if (allOf.size() <= index) throw new RuntimeException("Can't edit allOf. Index exceeds size."); return setNewAllOfLike(index, buildAllOf(index)); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested editFirstAllOf() { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested + editFirstAllOf() { if (allOf.size() == 0) throw new RuntimeException("Can't edit first allOf. The list is empty."); return setNewAllOfLike(0, buildAllOf(0)); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested editLastAllOf() { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested + editLastAllOf() { int index = allOf.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last allOf. The list is empty."); return setNewAllOfLike(index, buildAllOf(index)); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested editMatchingAllOf(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested + editMatchingAllOf( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("anyOf").add(index >= 0 ? index : _visitables.get("anyOf").size(), builder);this.anyOf.add(index >= 0 ? index : anyOf.size(), builder); return (A)this; + + public A addToAnyOf( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + if (this.anyOf == null) { + this.anyOf = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("anyOf").add(index >= 0 ? index : _visitables.get("anyOf").size(), builder); + this.anyOf.add(index >= 0 ? index : anyOf.size(), builder); + return (A) this; } - public A setToAnyOf(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - if (this.anyOf == null) {this.anyOf = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); - if (index < 0 || index >= _visitables.get("anyOf").size()) { _visitables.get("anyOf").add(builder); } else { _visitables.get("anyOf").set(index, builder);} - if (index < 0 || index >= anyOf.size()) { anyOf.add(builder); } else { anyOf.set(index, builder);} - return (A)this; + + public A setToAnyOf( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + if (this.anyOf == null) { + this.anyOf = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + if (index < 0 || index >= _visitables.get("anyOf").size()) { + _visitables.get("anyOf").add(builder); + } else { + _visitables.get("anyOf").set(index, builder); + } + if (index < 0 || index >= anyOf.size()) { + anyOf.add(builder); + } else { + anyOf.set(index, builder); + } + return (A) this; } + public A addToAnyOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... items) { - if (this.anyOf == null) {this.anyOf = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) {io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("anyOf").add(builder);this.anyOf.add(builder);} return (A)this; + if (this.anyOf == null) { + this.anyOf = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) { + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("anyOf").add(builder); + this.anyOf.add(builder); + } + return (A) this; } - public A addAllToAnyOf(java.util.Collection items) { - if (this.anyOf == null) {this.anyOf = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) {io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("anyOf").add(builder);this.anyOf.add(builder);} return (A)this; + + public A addAllToAnyOf( + java.util.Collection items) { + if (this.anyOf == null) { + this.anyOf = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) { + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("anyOf").add(builder); + this.anyOf.add(builder); + } + return (A) this; } + public A removeFromAnyOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... items) { - for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) {io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("anyOf").remove(builder);if (this.anyOf != null) {this.anyOf.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) { + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("anyOf").remove(builder); + if (this.anyOf != null) { + this.anyOf.remove(builder); + } + } + return (A) this; } - public A removeAllFromAnyOf(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) {io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("anyOf").remove(builder);if (this.anyOf != null) {this.anyOf.remove(builder);}} return (A)this; + + public A removeAllFromAnyOf( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) { + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("anyOf").remove(builder); + if (this.anyOf != null) { + this.anyOf.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromAnyOf(java.util.function.Predicate predicate) { + + public A removeMatchingFromAnyOf( + java.util.function.Predicate + predicate) { if (anyOf == null) return (A) this; - final Iterator each = anyOf.iterator(); + final Iterator each = + anyOf.iterator(); final List visitables = _visitables.get("anyOf"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = each.next(); @@ -331,459 +540,841 @@ public A removeMatchingFromAnyOf(java.util.function.Predicate getAnyOf() { return anyOf != null ? build(anyOf) : null; } + public java.util.List buildAnyOf() { return anyOf != null ? build(anyOf) : null; } + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildAnyOf(java.lang.Integer index) { return this.anyOf.get(index).build(); } + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildFirstAnyOf() { return this.anyOf.get(0).build(); } + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildLastAnyOf() { return this.anyOf.get(anyOf.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildMatchingAnyOf(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder item: anyOf) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildMatchingAnyOf( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder item : anyOf) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingAnyOf(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder item: anyOf) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAnyOf( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder item : anyOf) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAnyOf(java.util.List anyOf) { - if (this.anyOf != null) { _visitables.get("anyOf").removeAll(this.anyOf);} - if (anyOf != null) {this.anyOf = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : anyOf){this.addToAnyOf(item);}} else { this.anyOf = null;} return (A) this; + if (this.anyOf != null) { + _visitables.get("anyOf").removeAll(this.anyOf); + } + if (anyOf != null) { + this.anyOf = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : anyOf) { + this.addToAnyOf(item); + } + } else { + this.anyOf = null; + } + return (A) this; } + public A withAnyOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... anyOf) { - if (this.anyOf != null) {this.anyOf.clear();} - if (anyOf != null) {for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item :anyOf){ this.addToAnyOf(item);}} return (A) this; + if (this.anyOf != null) { + this.anyOf.clear(); + } + if (anyOf != null) { + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : anyOf) { + this.addToAnyOf(item); + } + } + return (A) this; } + public java.lang.Boolean hasAnyOf() { return anyOf != null && !anyOf.isEmpty(); } + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested addNewAnyOf() { return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.AnyOfNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested addNewAnyOfLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.AnyOfNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested addNewAnyOfLike( + io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.AnyOfNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested setNewAnyOfLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.AnyOfNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested setNewAnyOfLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.AnyOfNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested editAnyOf(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested editAnyOf( + java.lang.Integer index) { if (anyOf.size() <= index) throw new RuntimeException("Can't edit anyOf. Index exceeds size."); return setNewAnyOfLike(index, buildAnyOf(index)); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested editFirstAnyOf() { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested + editFirstAnyOf() { if (anyOf.size() == 0) throw new RuntimeException("Can't edit first anyOf. The list is empty."); return setNewAnyOfLike(0, buildAnyOf(0)); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested editLastAnyOf() { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested + editLastAnyOf() { int index = anyOf.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last anyOf. The list is empty."); return setNewAnyOfLike(index, buildAnyOf(index)); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested editMatchingAnyOf(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested + editMatchingAnyOf( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i map) { - if(this.definitions == null && map != null) { this.definitions = new java.util.LinkedHashMap(); } - if(map != null) { this.definitions.putAll(map);} return (A)this; + + public A addToDefinitions( + java.util.Map map) { + if (this.definitions == null && map != null) { + this.definitions = new java.util.LinkedHashMap(); + } + if (map != null) { + this.definitions.putAll(map); + } + return (A) this; } + public A removeFromDefinitions(java.lang.String key) { - if(this.definitions == null) { return (A) this; } - if(key != null && this.definitions != null) {this.definitions.remove(key);} return (A)this; + if (this.definitions == null) { + return (A) this; + } + if (key != null && this.definitions != null) { + this.definitions.remove(key); + } + return (A) this; } - public A removeFromDefinitions(java.util.Map map) { - if(this.definitions == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.definitions != null){this.definitions.remove(key);}}} return (A)this; + + public A removeFromDefinitions( + java.util.Map map) { + if (this.definitions == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.definitions != null) { + this.definitions.remove(key); + } + } + } + return (A) this; } - public java.util.Map getDefinitions() { + + public java.util.Map + getDefinitions() { return this.definitions; } - public A withDefinitions(java.util.Map definitions) { - if (definitions == null) { this.definitions = null;} else {this.definitions = new java.util.LinkedHashMap(definitions);} return (A) this; + + public A withDefinitions( + java.util.Map + definitions) { + if (definitions == null) { + this.definitions = null; + } else { + this.definitions = new java.util.LinkedHashMap(definitions); + } + return (A) this; } + public java.lang.Boolean hasDefinitions() { return this.definitions != null; } - public A addToDependencies(java.lang.String key,java.lang.Object value) { - if(this.dependencies == null && key != null && value != null) { this.dependencies = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.dependencies.put(key, value);} return (A)this; + + public A addToDependencies(java.lang.String key, java.lang.Object value) { + if (this.dependencies == null && key != null && value != null) { + this.dependencies = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.dependencies.put(key, value); + } + return (A) this; } - public A addToDependencies(java.util.Map map) { - if(this.dependencies == null && map != null) { this.dependencies = new java.util.LinkedHashMap(); } - if(map != null) { this.dependencies.putAll(map);} return (A)this; + + public A addToDependencies(java.util.Map map) { + if (this.dependencies == null && map != null) { + this.dependencies = new java.util.LinkedHashMap(); + } + if (map != null) { + this.dependencies.putAll(map); + } + return (A) this; } + public A removeFromDependencies(java.lang.String key) { - if(this.dependencies == null) { return (A) this; } - if(key != null && this.dependencies != null) {this.dependencies.remove(key);} return (A)this; + if (this.dependencies == null) { + return (A) this; + } + if (key != null && this.dependencies != null) { + this.dependencies.remove(key); + } + return (A) this; } - public A removeFromDependencies(java.util.Map map) { - if(this.dependencies == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.dependencies != null){this.dependencies.remove(key);}}} return (A)this; + + public A removeFromDependencies(java.util.Map map) { + if (this.dependencies == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.dependencies != null) { + this.dependencies.remove(key); + } + } + } + return (A) this; } - public java.util.Map getDependencies() { + + public java.util.Map getDependencies() { return this.dependencies; } - public A withDependencies(java.util.Map dependencies) { - if (dependencies == null) { this.dependencies = null;} else {this.dependencies = new java.util.LinkedHashMap(dependencies);} return (A) this; + + public A withDependencies(java.util.Map dependencies) { + if (dependencies == null) { + this.dependencies = null; + } else { + this.dependencies = new java.util.LinkedHashMap(dependencies); + } + return (A) this; } + public java.lang.Boolean hasDependencies() { return this.dependencies != null; } + public java.lang.String getDescription() { return this.description; } + public A withDescription(java.lang.String description) { - this.description=description; return (A) this; + this.description = description; + return (A) this; } + public java.lang.Boolean hasDescription() { return this.description != null; } - - /** - * Method is deprecated. use withDescription instead. - */ + + /** Method is deprecated. use withDescription instead. */ @java.lang.Deprecated public A withNewDescription(java.lang.String original) { - return (A)withDescription(new String(original)); + return (A) withDescription(new String(original)); } - public A addToEnum(java.lang.Integer index,java.lang.Object item) { - if (this._enum == null) {this._enum = new java.util.ArrayList();} + + public A addToEnum(java.lang.Integer index, java.lang.Object item) { + if (this._enum == null) { + this._enum = new java.util.ArrayList(); + } this._enum.add(index, item); - return (A)this; + return (A) this; } - public A setToEnum(java.lang.Integer index,java.lang.Object item) { - if (this._enum == null) {this._enum = new java.util.ArrayList();} - this._enum.set(index, item); return (A)this; + + public A setToEnum(java.lang.Integer index, java.lang.Object item) { + if (this._enum == null) { + this._enum = new java.util.ArrayList(); + } + this._enum.set(index, item); + return (A) this; } + public A addToEnum(java.lang.Object... items) { - if (this._enum == null) {this._enum = new java.util.ArrayList();} - for (java.lang.Object item : items) {this._enum.add(item);} return (A)this; + if (this._enum == null) { + this._enum = new java.util.ArrayList(); + } + for (java.lang.Object item : items) { + this._enum.add(item); + } + return (A) this; } + public A addAllToEnum(java.util.Collection items) { - if (this._enum == null) {this._enum = new java.util.ArrayList();} - for (java.lang.Object item : items) {this._enum.add(item);} return (A)this; + if (this._enum == null) { + this._enum = new java.util.ArrayList(); + } + for (java.lang.Object item : items) { + this._enum.add(item); + } + return (A) this; } + public A removeFromEnum(java.lang.Object... items) { - for (java.lang.Object item : items) {if (this._enum!= null){ this._enum.remove(item);}} return (A)this; + for (java.lang.Object item : items) { + if (this._enum != null) { + this._enum.remove(item); + } + } + return (A) this; } + public A removeAllFromEnum(java.util.Collection items) { - for (java.lang.Object item : items) {if (this._enum!= null){ this._enum.remove(item);}} return (A)this; + for (java.lang.Object item : items) { + if (this._enum != null) { + this._enum.remove(item); + } + } + return (A) this; } + public java.util.List getEnum() { return this._enum; } + public java.lang.Object getEnum(java.lang.Integer index) { return this._enum.get(index); } + public java.lang.Object getFirstEnum() { return this._enum.get(0); } + public java.lang.Object getLastEnum() { return this._enum.get(_enum.size() - 1); } - public java.lang.Object getMatchingEnum(java.util.function.Predicate predicate) { - for (java.lang.Object item: _enum) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.Object getMatchingEnum( + java.util.function.Predicate predicate) { + for (java.lang.Object item : _enum) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingEnum(java.util.function.Predicate predicate) { - for (java.lang.Object item: _enum) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingEnum( + java.util.function.Predicate predicate) { + for (java.lang.Object item : _enum) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withEnum(java.util.List _enum) { - if (_enum != null) {this._enum = new java.util.ArrayList(); for (java.lang.Object item : _enum){this.addToEnum(item);}} else { this._enum = null;} return (A) this; + if (_enum != null) { + this._enum = new java.util.ArrayList(); + for (java.lang.Object item : _enum) { + this.addToEnum(item); + } + } else { + this._enum = null; + } + return (A) this; } + public A withEnum(java.lang.Object... _enum) { - if (this._enum != null) {this._enum.clear();} - if (_enum != null) {for (java.lang.Object item :_enum){ this.addToEnum(item);}} return (A) this; + if (this._enum != null) { + this._enum.clear(); + } + if (_enum != null) { + for (java.lang.Object item : _enum) { + this.addToEnum(item); + } + } + return (A) this; } + public java.lang.Boolean hasEnum() { return _enum != null && !_enum.isEmpty(); } + public java.lang.Object getExample() { return this.example; } + public A withExample(java.lang.Object example) { - this.example=example; return (A) this; + this.example = example; + return (A) this; } + public java.lang.Boolean hasExample() { return this.example != null; } + public java.lang.Boolean getExclusiveMaximum() { return this.exclusiveMaximum; } + public A withExclusiveMaximum(java.lang.Boolean exclusiveMaximum) { - this.exclusiveMaximum=exclusiveMaximum; return (A) this; + this.exclusiveMaximum = exclusiveMaximum; + return (A) this; } + public java.lang.Boolean hasExclusiveMaximum() { return this.exclusiveMaximum != null; } + public java.lang.Boolean getExclusiveMinimum() { return this.exclusiveMinimum; } + public A withExclusiveMinimum(java.lang.Boolean exclusiveMinimum) { - this.exclusiveMinimum=exclusiveMinimum; return (A) this; + this.exclusiveMinimum = exclusiveMinimum; + return (A) this; } + public java.lang.Boolean hasExclusiveMinimum() { return this.exclusiveMinimum != null; } - + /** * This method has been deprecated, please use method buildExternalDocs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ExternalDocumentation getExternalDocs() { - return this.externalDocs!=null ?this.externalDocs.build():null; + return this.externalDocs != null ? this.externalDocs.build() : null; } + public io.kubernetes.client.openapi.models.V1ExternalDocumentation buildExternalDocs() { - return this.externalDocs!=null ?this.externalDocs.build():null; + return this.externalDocs != null ? this.externalDocs.build() : null; } - public A withExternalDocs(io.kubernetes.client.openapi.models.V1ExternalDocumentation externalDocs) { + + public A withExternalDocs( + io.kubernetes.client.openapi.models.V1ExternalDocumentation externalDocs) { _visitables.get("externalDocs").remove(this.externalDocs); - if (externalDocs!=null){ this.externalDocs= new io.kubernetes.client.openapi.models.V1ExternalDocumentationBuilder(externalDocs); _visitables.get("externalDocs").add(this.externalDocs);} return (A) this; + if (externalDocs != null) { + this.externalDocs = + new io.kubernetes.client.openapi.models.V1ExternalDocumentationBuilder(externalDocs); + _visitables.get("externalDocs").add(this.externalDocs); + } + return (A) this; } + public java.lang.Boolean hasExternalDocs() { return this.externalDocs != null; } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested withNewExternalDocs() { - return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.ExternalDocsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested + withNewExternalDocs() { + return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl + .ExternalDocsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested withNewExternalDocsLike(io.kubernetes.client.openapi.models.V1ExternalDocumentation item) { - return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.ExternalDocsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested + withNewExternalDocsLike(io.kubernetes.client.openapi.models.V1ExternalDocumentation item) { + return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl + .ExternalDocsNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested editExternalDocs() { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested + editExternalDocs() { return withNewExternalDocsLike(getExternalDocs()); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested editOrNewExternalDocs() { - return withNewExternalDocsLike(getExternalDocs() != null ? getExternalDocs(): new io.kubernetes.client.openapi.models.V1ExternalDocumentationBuilder().build()); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested + editOrNewExternalDocs() { + return withNewExternalDocsLike( + getExternalDocs() != null + ? getExternalDocs() + : new io.kubernetes.client.openapi.models.V1ExternalDocumentationBuilder().build()); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested editOrNewExternalDocsLike(io.kubernetes.client.openapi.models.V1ExternalDocumentation item) { - return withNewExternalDocsLike(getExternalDocs() != null ? getExternalDocs(): item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested + editOrNewExternalDocsLike(io.kubernetes.client.openapi.models.V1ExternalDocumentation item) { + return withNewExternalDocsLike(getExternalDocs() != null ? getExternalDocs() : item); } + public java.lang.String getFormat() { return this.format; } + public A withFormat(java.lang.String format) { - this.format=format; return (A) this; + this.format = format; + return (A) this; } + public java.lang.Boolean hasFormat() { return this.format != null; } - - /** - * Method is deprecated. use withFormat instead. - */ + + /** Method is deprecated. use withFormat instead. */ @java.lang.Deprecated public A withNewFormat(java.lang.String original) { - return (A)withFormat(new String(original)); + return (A) withFormat(new String(original)); } + public java.lang.String getId() { return this.id; } + public A withId(java.lang.String id) { - this.id=id; return (A) this; + this.id = id; + return (A) this; } + public java.lang.Boolean hasId() { return this.id != null; } - - /** - * Method is deprecated. use withId instead. - */ + + /** Method is deprecated. use withId instead. */ @java.lang.Deprecated public A withNewId(java.lang.String original) { - return (A)withId(new String(original)); + return (A) withId(new String(original)); } + public java.lang.Object getItems() { return this.items; } + public A withItems(java.lang.Object items) { - this.items=items; return (A) this; + this.items = items; + return (A) this; } + public java.lang.Boolean hasItems() { return this.items != null; } + public java.lang.Long getMaxItems() { return this.maxItems; } + public A withMaxItems(java.lang.Long maxItems) { - this.maxItems=maxItems; return (A) this; + this.maxItems = maxItems; + return (A) this; } + public java.lang.Boolean hasMaxItems() { return this.maxItems != null; } + public java.lang.Long getMaxLength() { return this.maxLength; } + public A withMaxLength(java.lang.Long maxLength) { - this.maxLength=maxLength; return (A) this; + this.maxLength = maxLength; + return (A) this; } + public java.lang.Boolean hasMaxLength() { return this.maxLength != null; } + public java.lang.Long getMaxProperties() { return this.maxProperties; } + public A withMaxProperties(java.lang.Long maxProperties) { - this.maxProperties=maxProperties; return (A) this; + this.maxProperties = maxProperties; + return (A) this; } + public java.lang.Boolean hasMaxProperties() { return this.maxProperties != null; } + public java.lang.Double getMaximum() { return this.maximum; } + public A withMaximum(java.lang.Double maximum) { - this.maximum=maximum; return (A) this; + this.maximum = maximum; + return (A) this; } + public java.lang.Boolean hasMaximum() { return this.maximum != null; } + public java.lang.Long getMinItems() { return this.minItems; } + public A withMinItems(java.lang.Long minItems) { - this.minItems=minItems; return (A) this; + this.minItems = minItems; + return (A) this; } + public java.lang.Boolean hasMinItems() { return this.minItems != null; } + public java.lang.Long getMinLength() { return this.minLength; } + public A withMinLength(java.lang.Long minLength) { - this.minLength=minLength; return (A) this; + this.minLength = minLength; + return (A) this; } + public java.lang.Boolean hasMinLength() { return this.minLength != null; } + public java.lang.Long getMinProperties() { return this.minProperties; } + public A withMinProperties(java.lang.Long minProperties) { - this.minProperties=minProperties; return (A) this; + this.minProperties = minProperties; + return (A) this; } + public java.lang.Boolean hasMinProperties() { return this.minProperties != null; } + public java.lang.Double getMinimum() { return this.minimum; } + public A withMinimum(java.lang.Double minimum) { - this.minimum=minimum; return (A) this; + this.minimum = minimum; + return (A) this; } + public java.lang.Boolean hasMinimum() { return this.minimum != null; } + public java.lang.Double getMultipleOf() { return this.multipleOf; } + public A withMultipleOf(java.lang.Double multipleOf) { - this.multipleOf=multipleOf; return (A) this; + this.multipleOf = multipleOf; + return (A) this; } + public java.lang.Boolean hasMultipleOf() { return this.multipleOf != null; } - + /** * This method has been deprecated, please use method buildNot instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JSONSchemaProps getNot() { - return this.not!=null ?this.not.build():null; + return this.not != null ? this.not.build() : null; } + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildNot() { - return this.not!=null ?this.not.build():null; + return this.not != null ? this.not.build() : null; } + public A withNot(io.kubernetes.client.openapi.models.V1JSONSchemaProps not) { _visitables.get("not").remove(this.not); - if (not!=null){ this.not= new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(not); _visitables.get("not").add(this.not);} return (A) this; + if (not != null) { + this.not = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(not); + _visitables.get("not").add(this.not); + } + return (A) this; } + public java.lang.Boolean hasNot() { return this.not != null; } + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested withNewNot() { return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.NotNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested withNewNotLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested withNewNotLike( + io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.NotNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested editNot() { return withNewNotLike(getNot()); } + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested editOrNewNot() { - return withNewNotLike(getNot() != null ? getNot(): new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder().build()); + return withNewNotLike( + getNot() != null + ? getNot() + : new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested editOrNewNotLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - return withNewNotLike(getNot() != null ? getNot(): item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested editOrNewNotLike( + io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + return withNewNotLike(getNot() != null ? getNot() : item); } + public java.lang.Boolean getNullable() { return this.nullable; } + public A withNullable(java.lang.Boolean nullable) { - this.nullable=nullable; return (A) this; + this.nullable = nullable; + return (A) this; } + public java.lang.Boolean hasNullable() { return this.nullable != null; } - public A addToOneOf(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - if (this.oneOf == null) {this.oneOf = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("oneOf").add(index >= 0 ? index : _visitables.get("oneOf").size(), builder);this.oneOf.add(index >= 0 ? index : oneOf.size(), builder); return (A)this; + + public A addToOneOf( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + if (this.oneOf == null) { + this.oneOf = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("oneOf").add(index >= 0 ? index : _visitables.get("oneOf").size(), builder); + this.oneOf.add(index >= 0 ? index : oneOf.size(), builder); + return (A) this; } - public A setToOneOf(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - if (this.oneOf == null) {this.oneOf = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); - if (index < 0 || index >= _visitables.get("oneOf").size()) { _visitables.get("oneOf").add(builder); } else { _visitables.get("oneOf").set(index, builder);} - if (index < 0 || index >= oneOf.size()) { oneOf.add(builder); } else { oneOf.set(index, builder);} - return (A)this; + + public A setToOneOf( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + if (this.oneOf == null) { + this.oneOf = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + if (index < 0 || index >= _visitables.get("oneOf").size()) { + _visitables.get("oneOf").add(builder); + } else { + _visitables.get("oneOf").set(index, builder); + } + if (index < 0 || index >= oneOf.size()) { + oneOf.add(builder); + } else { + oneOf.set(index, builder); + } + return (A) this; } + public A addToOneOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... items) { - if (this.oneOf == null) {this.oneOf = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) {io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("oneOf").add(builder);this.oneOf.add(builder);} return (A)this; + if (this.oneOf == null) { + this.oneOf = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) { + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("oneOf").add(builder); + this.oneOf.add(builder); + } + return (A) this; } - public A addAllToOneOf(java.util.Collection items) { - if (this.oneOf == null) {this.oneOf = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) {io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("oneOf").add(builder);this.oneOf.add(builder);} return (A)this; + + public A addAllToOneOf( + java.util.Collection items) { + if (this.oneOf == null) { + this.oneOf = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) { + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("oneOf").add(builder); + this.oneOf.add(builder); + } + return (A) this; } + public A removeFromOneOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... items) { - for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) {io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("oneOf").remove(builder);if (this.oneOf != null) {this.oneOf.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) { + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("oneOf").remove(builder); + if (this.oneOf != null) { + this.oneOf.remove(builder); + } + } + return (A) this; } - public A removeAllFromOneOf(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) {io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item);_visitables.get("oneOf").remove(builder);if (this.oneOf != null) {this.oneOf.remove(builder);}} return (A)this; + + public A removeAllFromOneOf( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : items) { + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = + new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(item); + _visitables.get("oneOf").remove(builder); + if (this.oneOf != null) { + this.oneOf.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromOneOf(java.util.function.Predicate predicate) { + + public A removeMatchingFromOneOf( + java.util.function.Predicate + predicate) { if (oneOf == null) return (A) this; - final Iterator each = oneOf.iterator(); + final Iterator each = + oneOf.iterator(); final List visitables = _visitables.get("oneOf"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder = each.next(); @@ -792,374 +1383,703 @@ public A removeMatchingFromOneOf(java.util.function.Predicate getOneOf() { return oneOf != null ? build(oneOf) : null; } + public java.util.List buildOneOf() { return oneOf != null ? build(oneOf) : null; } + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildOneOf(java.lang.Integer index) { return this.oneOf.get(index).build(); } + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildFirstOneOf() { return this.oneOf.get(0).build(); } + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildLastOneOf() { return this.oneOf.get(oneOf.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildMatchingOneOf(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder item: oneOf) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1JSONSchemaProps buildMatchingOneOf( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder item : oneOf) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingOneOf(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder item: oneOf) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingOneOf( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder item : oneOf) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withOneOf(java.util.List oneOf) { - if (this.oneOf != null) { _visitables.get("oneOf").removeAll(this.oneOf);} - if (oneOf != null) {this.oneOf = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : oneOf){this.addToOneOf(item);}} else { this.oneOf = null;} return (A) this; + if (this.oneOf != null) { + _visitables.get("oneOf").removeAll(this.oneOf); + } + if (oneOf != null) { + this.oneOf = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : oneOf) { + this.addToOneOf(item); + } + } else { + this.oneOf = null; + } + return (A) this; } + public A withOneOf(io.kubernetes.client.openapi.models.V1JSONSchemaProps... oneOf) { - if (this.oneOf != null) {this.oneOf.clear();} - if (oneOf != null) {for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item :oneOf){ this.addToOneOf(item);}} return (A) this; + if (this.oneOf != null) { + this.oneOf.clear(); + } + if (oneOf != null) { + for (io.kubernetes.client.openapi.models.V1JSONSchemaProps item : oneOf) { + this.addToOneOf(item); + } + } + return (A) this; } + public java.lang.Boolean hasOneOf() { return oneOf != null && !oneOf.isEmpty(); } + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested addNewOneOf() { return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.OneOfNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested addNewOneOfLike(io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.OneOfNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested addNewOneOfLike( + io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.OneOfNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested setNewOneOfLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { - return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.OneOfNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested setNewOneOfLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + return new io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl.OneOfNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested editOneOf(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested editOneOf( + java.lang.Integer index) { if (oneOf.size() <= index) throw new RuntimeException("Can't edit oneOf. Index exceeds size."); return setNewOneOfLike(index, buildOneOf(index)); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested editFirstOneOf() { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested + editFirstOneOf() { if (oneOf.size() == 0) throw new RuntimeException("Can't edit first oneOf. The list is empty."); return setNewOneOfLike(0, buildOneOf(0)); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested editLastOneOf() { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested + editLastOneOf() { int index = oneOf.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last oneOf. The list is empty."); return setNewOneOfLike(index, buildOneOf(index)); } - public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested editMatchingOneOf(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested + editMatchingOneOf( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i map) { - if(this.patternProperties == null && map != null) { this.patternProperties = new java.util.LinkedHashMap(); } - if(map != null) { this.patternProperties.putAll(map);} return (A)this; + + public A addToPatternProperties( + java.util.Map map) { + if (this.patternProperties == null && map != null) { + this.patternProperties = new java.util.LinkedHashMap(); + } + if (map != null) { + this.patternProperties.putAll(map); + } + return (A) this; } + public A removeFromPatternProperties(java.lang.String key) { - if(this.patternProperties == null) { return (A) this; } - if(key != null && this.patternProperties != null) {this.patternProperties.remove(key);} return (A)this; + if (this.patternProperties == null) { + return (A) this; + } + if (key != null && this.patternProperties != null) { + this.patternProperties.remove(key); + } + return (A) this; } - public A removeFromPatternProperties(java.util.Map map) { - if(this.patternProperties == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.patternProperties != null){this.patternProperties.remove(key);}}} return (A)this; + + public A removeFromPatternProperties( + java.util.Map map) { + if (this.patternProperties == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.patternProperties != null) { + this.patternProperties.remove(key); + } + } + } + return (A) this; } - public java.util.Map getPatternProperties() { + + public java.util.Map + getPatternProperties() { return this.patternProperties; } - public A withPatternProperties(java.util.Map patternProperties) { - if (patternProperties == null) { this.patternProperties = null;} else {this.patternProperties = new java.util.LinkedHashMap(patternProperties);} return (A) this; + + public A withPatternProperties( + java.util.Map + patternProperties) { + if (patternProperties == null) { + this.patternProperties = null; + } else { + this.patternProperties = new java.util.LinkedHashMap(patternProperties); + } + return (A) this; } + public java.lang.Boolean hasPatternProperties() { return this.patternProperties != null; } - public A addToProperties(java.lang.String key,io.kubernetes.client.openapi.models.V1JSONSchemaProps value) { - if(this.properties == null && key != null && value != null) { this.properties = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.properties.put(key, value);} return (A)this; + + public A addToProperties( + java.lang.String key, io.kubernetes.client.openapi.models.V1JSONSchemaProps value) { + if (this.properties == null && key != null && value != null) { + this.properties = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.properties.put(key, value); + } + return (A) this; } - public A addToProperties(java.util.Map map) { - if(this.properties == null && map != null) { this.properties = new java.util.LinkedHashMap(); } - if(map != null) { this.properties.putAll(map);} return (A)this; + + public A addToProperties( + java.util.Map map) { + if (this.properties == null && map != null) { + this.properties = new java.util.LinkedHashMap(); + } + if (map != null) { + this.properties.putAll(map); + } + return (A) this; } + public A removeFromProperties(java.lang.String key) { - if(this.properties == null) { return (A) this; } - if(key != null && this.properties != null) {this.properties.remove(key);} return (A)this; + if (this.properties == null) { + return (A) this; + } + if (key != null && this.properties != null) { + this.properties.remove(key); + } + return (A) this; } - public A removeFromProperties(java.util.Map map) { - if(this.properties == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.properties != null){this.properties.remove(key);}}} return (A)this; + + public A removeFromProperties( + java.util.Map map) { + if (this.properties == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.properties != null) { + this.properties.remove(key); + } + } + } + return (A) this; } - public java.util.Map getProperties() { + + public java.util.Map + getProperties() { return this.properties; } - public A withProperties(java.util.Map properties) { - if (properties == null) { this.properties = null;} else {this.properties = new java.util.LinkedHashMap(properties);} return (A) this; + + public A withProperties( + java.util.Map + properties) { + if (properties == null) { + this.properties = null; + } else { + this.properties = new java.util.LinkedHashMap(properties); + } + return (A) this; } + public java.lang.Boolean hasProperties() { return this.properties != null; } - public A addToRequired(java.lang.Integer index,java.lang.String item) { - if (this.required == null) {this.required = new java.util.ArrayList();} + + public A addToRequired(java.lang.Integer index, java.lang.String item) { + if (this.required == null) { + this.required = new java.util.ArrayList(); + } this.required.add(index, item); - return (A)this; + return (A) this; } - public A setToRequired(java.lang.Integer index,java.lang.String item) { - if (this.required == null) {this.required = new java.util.ArrayList();} - this.required.set(index, item); return (A)this; + + public A setToRequired(java.lang.Integer index, java.lang.String item) { + if (this.required == null) { + this.required = new java.util.ArrayList(); + } + this.required.set(index, item); + return (A) this; } + public A addToRequired(java.lang.String... items) { - if (this.required == null) {this.required = new java.util.ArrayList();} - for (java.lang.String item : items) {this.required.add(item);} return (A)this; + if (this.required == null) { + this.required = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.required.add(item); + } + return (A) this; } + public A addAllToRequired(java.util.Collection items) { - if (this.required == null) {this.required = new java.util.ArrayList();} - for (java.lang.String item : items) {this.required.add(item);} return (A)this; + if (this.required == null) { + this.required = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.required.add(item); + } + return (A) this; } + public A removeFromRequired(java.lang.String... items) { - for (java.lang.String item : items) {if (this.required!= null){ this.required.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.required != null) { + this.required.remove(item); + } + } + return (A) this; } + public A removeAllFromRequired(java.util.Collection items) { - for (java.lang.String item : items) {if (this.required!= null){ this.required.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.required != null) { + this.required.remove(item); + } + } + return (A) this; } + public java.util.List getRequired() { return this.required; } + public java.lang.String getRequired(java.lang.Integer index) { return this.required.get(index); } + public java.lang.String getFirstRequired() { return this.required.get(0); } + public java.lang.String getLastRequired() { return this.required.get(required.size() - 1); } - public java.lang.String getMatchingRequired(java.util.function.Predicate predicate) { - for (java.lang.String item: required) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingRequired( + java.util.function.Predicate predicate) { + for (java.lang.String item : required) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingRequired(java.util.function.Predicate predicate) { - for (java.lang.String item: required) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRequired( + java.util.function.Predicate predicate) { + for (java.lang.String item : required) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withRequired(java.util.List required) { - if (required != null) {this.required = new java.util.ArrayList(); for (java.lang.String item : required){this.addToRequired(item);}} else { this.required = null;} return (A) this; + if (required != null) { + this.required = new java.util.ArrayList(); + for (java.lang.String item : required) { + this.addToRequired(item); + } + } else { + this.required = null; + } + return (A) this; } + public A withRequired(java.lang.String... required) { - if (this.required != null) {this.required.clear();} - if (required != null) {for (java.lang.String item :required){ this.addToRequired(item);}} return (A) this; + if (this.required != null) { + this.required.clear(); + } + if (required != null) { + for (java.lang.String item : required) { + this.addToRequired(item); + } + } + return (A) this; } + public java.lang.Boolean hasRequired() { return required != null && !required.isEmpty(); } + public A addNewRequired(java.lang.String original) { - return (A)addToRequired(new String(original)); + return (A) addToRequired(new String(original)); } + public java.lang.String getTitle() { return this.title; } + public A withTitle(java.lang.String title) { - this.title=title; return (A) this; + this.title = title; + return (A) this; } + public java.lang.Boolean hasTitle() { return this.title != null; } - - /** - * Method is deprecated. use withTitle instead. - */ + + /** Method is deprecated. use withTitle instead. */ @java.lang.Deprecated public A withNewTitle(java.lang.String original) { - return (A)withTitle(new String(original)); + return (A) withTitle(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public java.lang.Boolean getUniqueItems() { return this.uniqueItems; } + public A withUniqueItems(java.lang.Boolean uniqueItems) { - this.uniqueItems=uniqueItems; return (A) this; + this.uniqueItems = uniqueItems; + return (A) this; } + public java.lang.Boolean hasUniqueItems() { return this.uniqueItems != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1JSONSchemaPropsFluentImpl that = (V1JSONSchemaPropsFluentImpl) o; - if ($ref != null ? !$ref.equals(that.$ref) :that.$ref != null) return false; - if ($schema != null ? !$schema.equals(that.$schema) :that.$schema != null) return false; - if (additionalItems != null ? !additionalItems.equals(that.additionalItems) :that.additionalItems != null) return false; - if (additionalProperties != null ? !additionalProperties.equals(that.additionalProperties) :that.additionalProperties != null) return false; - if (allOf != null ? !allOf.equals(that.allOf) :that.allOf != null) return false; - if (anyOf != null ? !anyOf.equals(that.anyOf) :that.anyOf != null) return false; - if (_default != null ? !_default.equals(that._default) :that._default != null) return false; - if (definitions != null ? !definitions.equals(that.definitions) :that.definitions != null) return false; - if (dependencies != null ? !dependencies.equals(that.dependencies) :that.dependencies != null) return false; - if (description != null ? !description.equals(that.description) :that.description != null) return false; - if (_enum != null ? !_enum.equals(that._enum) :that._enum != null) return false; - if (example != null ? !example.equals(that.example) :that.example != null) return false; - if (exclusiveMaximum != null ? !exclusiveMaximum.equals(that.exclusiveMaximum) :that.exclusiveMaximum != null) return false; - if (exclusiveMinimum != null ? !exclusiveMinimum.equals(that.exclusiveMinimum) :that.exclusiveMinimum != null) return false; - if (externalDocs != null ? !externalDocs.equals(that.externalDocs) :that.externalDocs != null) return false; - if (format != null ? !format.equals(that.format) :that.format != null) return false; - if (id != null ? !id.equals(that.id) :that.id != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (maxItems != null ? !maxItems.equals(that.maxItems) :that.maxItems != null) return false; - if (maxLength != null ? !maxLength.equals(that.maxLength) :that.maxLength != null) return false; - if (maxProperties != null ? !maxProperties.equals(that.maxProperties) :that.maxProperties != null) return false; - if (maximum != null ? !maximum.equals(that.maximum) :that.maximum != null) return false; - if (minItems != null ? !minItems.equals(that.minItems) :that.minItems != null) return false; - if (minLength != null ? !minLength.equals(that.minLength) :that.minLength != null) return false; - if (minProperties != null ? !minProperties.equals(that.minProperties) :that.minProperties != null) return false; - if (minimum != null ? !minimum.equals(that.minimum) :that.minimum != null) return false; - if (multipleOf != null ? !multipleOf.equals(that.multipleOf) :that.multipleOf != null) return false; - if (not != null ? !not.equals(that.not) :that.not != null) return false; - if (nullable != null ? !nullable.equals(that.nullable) :that.nullable != null) return false; - if (oneOf != null ? !oneOf.equals(that.oneOf) :that.oneOf != null) return false; - if (pattern != null ? !pattern.equals(that.pattern) :that.pattern != null) return false; - if (patternProperties != null ? !patternProperties.equals(that.patternProperties) :that.patternProperties != null) return false; - if (properties != null ? !properties.equals(that.properties) :that.properties != null) return false; - if (required != null ? !required.equals(that.required) :that.required != null) return false; - if (title != null ? !title.equals(that.title) :that.title != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; - if (uniqueItems != null ? !uniqueItems.equals(that.uniqueItems) :that.uniqueItems != null) return false; + if ($ref != null ? !$ref.equals(that.$ref) : that.$ref != null) return false; + if ($schema != null ? !$schema.equals(that.$schema) : that.$schema != null) return false; + if (additionalItems != null + ? !additionalItems.equals(that.additionalItems) + : that.additionalItems != null) return false; + if (additionalProperties != null + ? !additionalProperties.equals(that.additionalProperties) + : that.additionalProperties != null) return false; + if (allOf != null ? !allOf.equals(that.allOf) : that.allOf != null) return false; + if (anyOf != null ? !anyOf.equals(that.anyOf) : that.anyOf != null) return false; + if (_default != null ? !_default.equals(that._default) : that._default != null) return false; + if (definitions != null ? !definitions.equals(that.definitions) : that.definitions != null) + return false; + if (dependencies != null ? !dependencies.equals(that.dependencies) : that.dependencies != null) + return false; + if (description != null ? !description.equals(that.description) : that.description != null) + return false; + if (_enum != null ? !_enum.equals(that._enum) : that._enum != null) return false; + if (example != null ? !example.equals(that.example) : that.example != null) return false; + if (exclusiveMaximum != null + ? !exclusiveMaximum.equals(that.exclusiveMaximum) + : that.exclusiveMaximum != null) return false; + if (exclusiveMinimum != null + ? !exclusiveMinimum.equals(that.exclusiveMinimum) + : that.exclusiveMinimum != null) return false; + if (externalDocs != null ? !externalDocs.equals(that.externalDocs) : that.externalDocs != null) + return false; + if (format != null ? !format.equals(that.format) : that.format != null) return false; + if (id != null ? !id.equals(that.id) : that.id != null) return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (maxItems != null ? !maxItems.equals(that.maxItems) : that.maxItems != null) return false; + if (maxLength != null ? !maxLength.equals(that.maxLength) : that.maxLength != null) + return false; + if (maxProperties != null + ? !maxProperties.equals(that.maxProperties) + : that.maxProperties != null) return false; + if (maximum != null ? !maximum.equals(that.maximum) : that.maximum != null) return false; + if (minItems != null ? !minItems.equals(that.minItems) : that.minItems != null) return false; + if (minLength != null ? !minLength.equals(that.minLength) : that.minLength != null) + return false; + if (minProperties != null + ? !minProperties.equals(that.minProperties) + : that.minProperties != null) return false; + if (minimum != null ? !minimum.equals(that.minimum) : that.minimum != null) return false; + if (multipleOf != null ? !multipleOf.equals(that.multipleOf) : that.multipleOf != null) + return false; + if (not != null ? !not.equals(that.not) : that.not != null) return false; + if (nullable != null ? !nullable.equals(that.nullable) : that.nullable != null) return false; + if (oneOf != null ? !oneOf.equals(that.oneOf) : that.oneOf != null) return false; + if (pattern != null ? !pattern.equals(that.pattern) : that.pattern != null) return false; + if (patternProperties != null + ? !patternProperties.equals(that.patternProperties) + : that.patternProperties != null) return false; + if (properties != null ? !properties.equals(that.properties) : that.properties != null) + return false; + if (required != null ? !required.equals(that.required) : that.required != null) return false; + if (title != null ? !title.equals(that.title) : that.title != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; + if (uniqueItems != null ? !uniqueItems.equals(that.uniqueItems) : that.uniqueItems != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash($ref, $schema, additionalItems, additionalProperties, allOf, anyOf, _default, definitions, dependencies, description, _enum, example, exclusiveMaximum, exclusiveMinimum, externalDocs, format, id, items, maxItems, maxLength, maxProperties, maximum, minItems, minLength, minProperties, minimum, multipleOf, not, nullable, oneOf, pattern, patternProperties, properties, required, title, type, uniqueItems, super.hashCode()); + return java.util.Objects.hash( + $ref, + $schema, + additionalItems, + additionalProperties, + allOf, + anyOf, + _default, + definitions, + dependencies, + description, + _enum, + example, + exclusiveMaximum, + exclusiveMinimum, + externalDocs, + format, + id, + items, + maxItems, + maxLength, + maxProperties, + maximum, + minItems, + minLength, + minProperties, + minimum, + multipleOf, + not, + nullable, + oneOf, + pattern, + patternProperties, + properties, + required, + title, + type, + uniqueItems, + super.hashCode()); } - public class AllOfNestedImpl extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl> implements io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested,io.kubernetes.client.fluent.Nested{ - AllOfNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + + public class AllOfNestedImpl + extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl< + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested> + implements io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AllOfNested, + io.kubernetes.client.fluent.Nested { + AllOfNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(this, item); } + AllOfNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(this); } + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1JSONSchemaPropsFluentImpl.this.setToAllOf(index,builder.build()); + return (N) V1JSONSchemaPropsFluentImpl.this.setToAllOf(index, builder.build()); } + public N endAllOf() { return and(); } - } - public class AnyOfNestedImpl extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl> implements io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested,io.kubernetes.client.fluent.Nested{ - AnyOfNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + + public class AnyOfNestedImpl + extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl< + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested> + implements io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.AnyOfNested, + io.kubernetes.client.fluent.Nested { + AnyOfNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(this, item); } + AnyOfNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(this); } + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1JSONSchemaPropsFluentImpl.this.setToAnyOf(index,builder.build()); + return (N) V1JSONSchemaPropsFluentImpl.this.setToAnyOf(index, builder.build()); } + public N endAnyOf() { return and(); } - } - public class ExternalDocsNestedImpl extends io.kubernetes.client.openapi.models.V1ExternalDocumentationFluentImpl> implements io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested,io.kubernetes.client.fluent.Nested{ + + public class ExternalDocsNestedImpl + extends io.kubernetes.client.openapi.models.V1ExternalDocumentationFluentImpl< + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested> + implements io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.ExternalDocsNested, + io.kubernetes.client.fluent.Nested { ExternalDocsNestedImpl(io.kubernetes.client.openapi.models.V1ExternalDocumentation item) { - this.builder = new io.kubernetes.client.openapi.models.V1ExternalDocumentationBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ExternalDocumentationBuilder(this, item); } + ExternalDocsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ExternalDocumentationBuilder(this); } + io.kubernetes.client.openapi.models.V1ExternalDocumentationBuilder builder; + public N and() { return (N) V1JSONSchemaPropsFluentImpl.this.withExternalDocs(builder.build()); } + public N endExternalDocs() { return and(); } - } - public class NotNestedImpl extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl> implements io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested,io.kubernetes.client.fluent.Nested{ + + public class NotNestedImpl + extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl< + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested> + implements io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.NotNested, + io.kubernetes.client.fluent.Nested { NotNestedImpl(io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { this.builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(this, item); } + NotNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(this); } + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder; + public N and() { return (N) V1JSONSchemaPropsFluentImpl.this.withNot(builder.build()); } + public N endNot() { return and(); } - } - public class OneOfNestedImpl extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl> implements io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested,io.kubernetes.client.fluent.Nested{ - OneOfNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { + + public class OneOfNestedImpl + extends io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluentImpl< + io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested> + implements io.kubernetes.client.openapi.models.V1JSONSchemaPropsFluent.OneOfNested, + io.kubernetes.client.fluent.Nested { + OneOfNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JSONSchemaProps item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(this, item); } + OneOfNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder(this); } + io.kubernetes.client.openapi.models.V1JSONSchemaPropsBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1JSONSchemaPropsFluentImpl.this.setToOneOf(index,builder.build()); + return (N) V1JSONSchemaPropsFluentImpl.this.setToOneOf(index, builder.build()); } + public N endOneOf() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobBuilder.java index 3d8b7af02e..2698509b48 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1JobBuilder extends io.kubernetes.client.openapi.models.V1JobFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1JobBuilder + extends io.kubernetes.client.openapi.models.V1JobFluentImpl< + io.kubernetes.client.openapi.models.V1JobBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Job, + io.kubernetes.client.openapi.models.V1JobBuilder> { public V1JobBuilder() { this(false); } + public V1JobBuilder(java.lang.Boolean validationEnabled) { this(new V1Job(), validationEnabled); } + public V1JobBuilder(io.kubernetes.client.openapi.models.V1JobFluent fluent) { this(fluent, false); } - public V1JobBuilder(io.kubernetes.client.openapi.models.V1JobFluent fluent,java.lang.Boolean validationEnabled) { + + public V1JobBuilder( + io.kubernetes.client.openapi.models.V1JobFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Job(), validationEnabled); } - public V1JobBuilder(io.kubernetes.client.openapi.models.V1JobFluent fluent,io.kubernetes.client.openapi.models.V1Job instance) { + + public V1JobBuilder( + io.kubernetes.client.openapi.models.V1JobFluent fluent, + io.kubernetes.client.openapi.models.V1Job instance) { this(fluent, instance, false); } - public V1JobBuilder(io.kubernetes.client.openapi.models.V1JobFluent fluent,io.kubernetes.client.openapi.models.V1Job instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1JobBuilder( + io.kubernetes.client.openapi.models.V1JobFluent fluent, + io.kubernetes.client.openapi.models.V1Job instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,16 @@ public V1JobBuilder(io.kubernetes.client.openapi.models.V1JobFluent fluent,io fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1JobBuilder(io.kubernetes.client.openapi.models.V1Job instance) { - this(instance,false); + this(instance, false); } - public V1JobBuilder(io.kubernetes.client.openapi.models.V1Job instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1JobBuilder( + io.kubernetes.client.openapi.models.V1Job instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +77,12 @@ public V1JobBuilder(io.kubernetes.client.openapi.models.V1Job instance,java.lang this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1JobFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Job build() { V1Job buildable = new V1Job(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +92,23 @@ public io.kubernetes.client.openapi.models.V1Job build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1JobBuilder that = (V1JobBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobConditionBuilder.java index 95efa2f16c..aba39ff56a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobConditionBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1JobConditionBuilder extends io.kubernetes.client.openapi.models.V1JobConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1JobConditionBuilder + extends io.kubernetes.client.openapi.models.V1JobConditionFluentImpl< + io.kubernetes.client.openapi.models.V1JobConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1JobCondition, + io.kubernetes.client.openapi.models.V1JobConditionBuilder> { public V1JobConditionBuilder() { this(false); } + public V1JobConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1JobCondition(), validationEnabled); } + public V1JobConditionBuilder(io.kubernetes.client.openapi.models.V1JobConditionFluent fluent) { this(fluent, false); } - public V1JobConditionBuilder(io.kubernetes.client.openapi.models.V1JobConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1JobConditionBuilder( + io.kubernetes.client.openapi.models.V1JobConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1JobCondition(), validationEnabled); } - public V1JobConditionBuilder(io.kubernetes.client.openapi.models.V1JobConditionFluent fluent,io.kubernetes.client.openapi.models.V1JobCondition instance) { + + public V1JobConditionBuilder( + io.kubernetes.client.openapi.models.V1JobConditionFluent fluent, + io.kubernetes.client.openapi.models.V1JobCondition instance) { this(fluent, instance, false); } - public V1JobConditionBuilder(io.kubernetes.client.openapi.models.V1JobConditionFluent fluent,io.kubernetes.client.openapi.models.V1JobCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1JobConditionBuilder( + io.kubernetes.client.openapi.models.V1JobConditionFluent fluent, + io.kubernetes.client.openapi.models.V1JobCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastProbeTime(instance.getLastProbeTime()); fluent.withLastTransitionTime(instance.getLastTransitionTime()); @@ -33,13 +59,17 @@ public V1JobConditionBuilder(io.kubernetes.client.openapi.models.V1JobConditionF fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1JobConditionBuilder(io.kubernetes.client.openapi.models.V1JobCondition instance) { - this(instance,false); + this(instance, false); } - public V1JobConditionBuilder(io.kubernetes.client.openapi.models.V1JobCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1JobConditionBuilder( + io.kubernetes.client.openapi.models.V1JobCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastProbeTime(instance.getLastProbeTime()); this.withLastTransitionTime(instance.getLastTransitionTime()); @@ -52,10 +82,12 @@ public V1JobConditionBuilder(io.kubernetes.client.openapi.models.V1JobCondition this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1JobConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1JobCondition build() { V1JobCondition buildable = new V1JobCondition(); buildable.setLastProbeTime(fluent.getLastProbeTime()); @@ -66,18 +98,23 @@ public io.kubernetes.client.openapi.models.V1JobCondition build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1JobConditionBuilder that = (V1JobConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobConditionFluent.java index 4dd79d4284..d3a6bfdd73 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobConditionFluent.java @@ -1,51 +1,66 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1JobConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1JobConditionFluent< + A extends io.kubernetes.client.openapi.models.V1JobConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastProbeTime(); + public A withLastProbeTime(java.time.OffsetDateTime lastProbeTime); + public java.lang.Boolean hasLastProbeTime(); + public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public io.kubernetes.client.openapi.models.V1JobCondition.TypeEnum getType(); + public A withType(io.kubernetes.client.openapi.models.V1JobCondition.TypeEnum type); + public java.lang.Boolean hasType(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobConditionFluentImpl.java index 817d3e7056..78dd704b1e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobConditionFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1JobConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1JobConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1JobConditionFluent { + public V1JobConditionFluentImpl() {} - /** - * Generated - */ -public class V1JobConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1JobConditionFluent{ - public V1JobConditionFluentImpl() { - } public V1JobConditionFluentImpl(io.kubernetes.client.openapi.models.V1JobCondition instance) { this.withLastProbeTime(instance.getLastProbeTime()); @@ -25,106 +31,130 @@ public V1JobConditionFluentImpl(io.kubernetes.client.openapi.models.V1JobConditi this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastProbeTime; private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private io.kubernetes.client.openapi.models.V1JobCondition.TypeEnum type; + public java.time.OffsetDateTime getLastProbeTime() { return this.lastProbeTime; } + public A withLastProbeTime(java.time.OffsetDateTime lastProbeTime) { - this.lastProbeTime=lastProbeTime; return (A) this; + this.lastProbeTime = lastProbeTime; + return (A) this; } + public java.lang.Boolean hasLastProbeTime() { return this.lastProbeTime != null; } + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public io.kubernetes.client.openapi.models.V1JobCondition.TypeEnum getType() { return this.type; } + public A withType(io.kubernetes.client.openapi.models.V1JobCondition.TypeEnum type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1JobConditionFluentImpl that = (V1JobConditionFluentImpl) o; - if (lastProbeTime != null ? !lastProbeTime.equals(that.lastProbeTime) :that.lastProbeTime != null) return false; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (lastProbeTime != null + ? !lastProbeTime.equals(that.lastProbeTime) + : that.lastProbeTime != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastProbeTime, lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastProbeTime, lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobFluent.java index 3e6adc8785..258c4cb477 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobFluent.java @@ -1,93 +1,142 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1JobFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1JobFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JobSpec getSpec(); + public io.kubernetes.client.openapi.models.V1JobSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1JobSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item); + + public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1JobSpec item); + public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item); - + + public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1JobSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JobStatus getStatus(); + public io.kubernetes.client.openapi.models.V1JobStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1JobStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1JobStatus item); + + public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1JobStatus item); + public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1JobStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1JobStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1JobSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1JobSpecFluent< + io.kubernetes.client.openapi.models.V1JobFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1JobStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1JobStatusFluent< + io.kubernetes.client.openapi.models.V1JobFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobFluentImpl.java index abe2d431af..2e21e91609 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1JobFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1JobFluent { + public V1JobFluentImpl() {} - /** - * Generated - */ -public class V1JobFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1JobFluent{ - public V1JobFluentImpl() { - } public V1JobFluentImpl(io.kubernetes.client.openapi.models.V1Job instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +28,294 @@ public V1JobFluentImpl(io.kubernetes.client.openapi.models.V1Job instance) { this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1JobSpecBuilder spec; private io.kubernetes.client.openapi.models.V1JobStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1JobFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1JobFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JobSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1JobSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1JobSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1JobSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1JobSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1JobFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item) { + + public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1JobSpec item) { return new io.kubernetes.client.openapi.models.V1JobFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1JobSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1JobSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1JobFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1JobSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JobStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1JobStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1JobStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1JobStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1JobStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1JobFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1JobStatus item) { + + public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1JobStatus item) { return new io.kubernetes.client.openapi.models.V1JobFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1JobStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1JobStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1JobStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1JobFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1JobStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1JobFluentImpl that = (V1JobFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1JobFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1JobFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1JobSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1JobFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1JobSpecFluentImpl< + io.kubernetes.client.openapi.models.V1JobFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1JobFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1JobSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1JobSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1JobSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1JobSpecBuilder builder; + public N and() { return (N) V1JobFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1JobStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1JobFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1JobStatusFluentImpl< + io.kubernetes.client.openapi.models.V1JobFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1JobFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1JobStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1JobStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1JobStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1JobStatusBuilder builder; + public N and() { return (N) V1JobFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobListBuilder.java index b9f8acf742..3b349f3121 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobListBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1JobListBuilder extends io.kubernetes.client.openapi.models.V1JobListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1JobListBuilder + extends io.kubernetes.client.openapi.models.V1JobListFluentImpl< + io.kubernetes.client.openapi.models.V1JobListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1JobList, + io.kubernetes.client.openapi.models.V1JobListBuilder> { public V1JobListBuilder() { this(false); } + public V1JobListBuilder(java.lang.Boolean validationEnabled) { this(new V1JobList(), validationEnabled); } + public V1JobListBuilder(io.kubernetes.client.openapi.models.V1JobListFluent fluent) { this(fluent, false); } - public V1JobListBuilder(io.kubernetes.client.openapi.models.V1JobListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1JobListBuilder( + io.kubernetes.client.openapi.models.V1JobListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1JobList(), validationEnabled); } - public V1JobListBuilder(io.kubernetes.client.openapi.models.V1JobListFluent fluent,io.kubernetes.client.openapi.models.V1JobList instance) { + + public V1JobListBuilder( + io.kubernetes.client.openapi.models.V1JobListFluent fluent, + io.kubernetes.client.openapi.models.V1JobList instance) { this(fluent, instance, false); } - public V1JobListBuilder(io.kubernetes.client.openapi.models.V1JobListFluent fluent,io.kubernetes.client.openapi.models.V1JobList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1JobListBuilder( + io.kubernetes.client.openapi.models.V1JobListFluent fluent, + io.kubernetes.client.openapi.models.V1JobList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +55,16 @@ public V1JobListBuilder(io.kubernetes.client.openapi.models.V1JobListFluent f fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1JobListBuilder(io.kubernetes.client.openapi.models.V1JobList instance) { - this(instance,false); + this(instance, false); } - public V1JobListBuilder(io.kubernetes.client.openapi.models.V1JobList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1JobListBuilder( + io.kubernetes.client.openapi.models.V1JobList instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +73,12 @@ public V1JobListBuilder(io.kubernetes.client.openapi.models.V1JobList instance,j this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1JobListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1JobList build() { V1JobList buildable = new V1JobList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +87,23 @@ public io.kubernetes.client.openapi.models.V1JobList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1JobListBuilder that = (V1JobListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobListFluent.java index 5a091c0453..ca1ef2cbba 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobListFluent.java @@ -1,95 +1,143 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1JobListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1JobListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Job item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Job item); + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Job item); + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Job item); + public A addToItems(io.kubernetes.client.openapi.models.V1Job... items); + public A addAllToItems(java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1Job... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1Job buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Job buildFirstItem(); + public io.kubernetes.client.openapi.models.V1Job buildLastItem(); - public io.kubernetes.client.openapi.models.V1Job buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Job buildMatchingItem( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1Job... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Job item); - public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Job item); - public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Job item); + + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Job item); + + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1JobFluent>{ + + public io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1JobFluent< + io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobListFluentImpl.java index d3a4a27fe5..1dd9015176 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobListFluentImpl.java @@ -1,25 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1JobListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1JobListFluent{ - public V1JobListFluentImpl() { - } +/** Generated */ +public class V1JobListFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1JobListFluent { + public V1JobListFluentImpl() {} + public V1JobListFluentImpl(io.kubernetes.client.openapi.models.V1JobList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +29,115 @@ public V1JobListFluentImpl(io.kubernetes.client.openapi.models.V1JobList instanc this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Job item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1JobBuilder builder = new io.kubernetes.client.openapi.models.V1JobBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Job item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1JobBuilder builder = + new io.kubernetes.client.openapi.models.V1JobBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Job item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1JobBuilder builder = new io.kubernetes.client.openapi.models.V1JobBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Job item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1JobBuilder builder = + new io.kubernetes.client.openapi.models.V1JobBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1Job... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Job item : items) {io.kubernetes.client.openapi.models.V1JobBuilder builder = new io.kubernetes.client.openapi.models.V1JobBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Job item : items) { + io.kubernetes.client.openapi.models.V1JobBuilder builder = + new io.kubernetes.client.openapi.models.V1JobBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Job item : items) {io.kubernetes.client.openapi.models.V1JobBuilder builder = new io.kubernetes.client.openapi.models.V1JobBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Job item : items) { + io.kubernetes.client.openapi.models.V1JobBuilder builder = + new io.kubernetes.client.openapi.models.V1JobBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1Job... items) { - for (io.kubernetes.client.openapi.models.V1Job item : items) {io.kubernetes.client.openapi.models.V1JobBuilder builder = new io.kubernetes.client.openapi.models.V1JobBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Job item : items) { + io.kubernetes.client.openapi.models.V1JobBuilder builder = + new io.kubernetes.client.openapi.models.V1JobBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Job item : items) {io.kubernetes.client.openapi.models.V1JobBuilder builder = new io.kubernetes.client.openapi.models.V1JobBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Job item : items) { + io.kubernetes.client.openapi.models.V1JobBuilder builder = + new io.kubernetes.client.openapi.models.V1JobBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +148,265 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1Job buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Job buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Job buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Job buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1JobBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Job buildMatchingItem( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1JobBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1JobBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1JobBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Job item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Job item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1Job... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1Job item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1Job item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1JobListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Job item) { + + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Job item) { return new io.kubernetes.client.openapi.models.V1JobListFluentImpl.ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Job item) { + + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Job item) { return new io.kubernetes.client.openapi.models.V1JobListFluentImpl.ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate) { int index = -1; - for (int i=0;i withNewMetadata() { return new io.kubernetes.client.openapi.models.V1JobListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + + public io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ListMeta item) { return new io.kubernetes.client.openapi.models.V1JobListFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1JobListFluentImpl that = (V1JobListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1JobFluentImpl> implements io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Job item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1JobFluentImpl< + io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1JobListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Job item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1JobBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1JobBuilder(this); } + io.kubernetes.client.openapi.models.V1JobBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1JobListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1JobListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1JobListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1JobListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobSpecBuilder.java index 65bbde729f..fa129398d1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobSpecBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1JobSpecBuilder extends io.kubernetes.client.openapi.models.V1JobSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1JobSpecBuilder + extends io.kubernetes.client.openapi.models.V1JobSpecFluentImpl< + io.kubernetes.client.openapi.models.V1JobSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1JobSpec, + io.kubernetes.client.openapi.models.V1JobSpecBuilder> { public V1JobSpecBuilder() { this(false); } + public V1JobSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1JobSpec(), validationEnabled); } + public V1JobSpecBuilder(io.kubernetes.client.openapi.models.V1JobSpecFluent fluent) { this(fluent, false); } - public V1JobSpecBuilder(io.kubernetes.client.openapi.models.V1JobSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1JobSpecBuilder( + io.kubernetes.client.openapi.models.V1JobSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1JobSpec(), validationEnabled); } - public V1JobSpecBuilder(io.kubernetes.client.openapi.models.V1JobSpecFluent fluent,io.kubernetes.client.openapi.models.V1JobSpec instance) { + + public V1JobSpecBuilder( + io.kubernetes.client.openapi.models.V1JobSpecFluent fluent, + io.kubernetes.client.openapi.models.V1JobSpec instance) { this(fluent, instance, false); } - public V1JobSpecBuilder(io.kubernetes.client.openapi.models.V1JobSpecFluent fluent,io.kubernetes.client.openapi.models.V1JobSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1JobSpecBuilder( + io.kubernetes.client.openapi.models.V1JobSpecFluent fluent, + io.kubernetes.client.openapi.models.V1JobSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withActiveDeadlineSeconds(instance.getActiveDeadlineSeconds()); fluent.withBackoffLimit(instance.getBackoffLimit()); @@ -41,13 +67,16 @@ public V1JobSpecBuilder(io.kubernetes.client.openapi.models.V1JobSpecFluent f fluent.withTtlSecondsAfterFinished(instance.getTtlSecondsAfterFinished()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1JobSpecBuilder(io.kubernetes.client.openapi.models.V1JobSpec instance) { - this(instance,false); + this(instance, false); } - public V1JobSpecBuilder(io.kubernetes.client.openapi.models.V1JobSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1JobSpecBuilder( + io.kubernetes.client.openapi.models.V1JobSpec instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withActiveDeadlineSeconds(instance.getActiveDeadlineSeconds()); this.withBackoffLimit(instance.getBackoffLimit()); @@ -68,10 +97,12 @@ public V1JobSpecBuilder(io.kubernetes.client.openapi.models.V1JobSpec instance,j this.withTtlSecondsAfterFinished(instance.getTtlSecondsAfterFinished()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1JobSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1JobSpec build() { V1JobSpec buildable = new V1JobSpec(); buildable.setActiveDeadlineSeconds(fluent.getActiveDeadlineSeconds()); @@ -86,18 +117,23 @@ public io.kubernetes.client.openapi.models.V1JobSpec build() { buildable.setTtlSecondsAfterFinished(fluent.getTtlSecondsAfterFinished()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1JobSpecBuilder that = (V1JobSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobSpecFluent.java index 494f5b75ce..5b83e657fa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobSpecFluent.java @@ -1,87 +1,139 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Long; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1JobSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1JobSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Long getActiveDeadlineSeconds(); + public A withActiveDeadlineSeconds(java.lang.Long activeDeadlineSeconds); + public java.lang.Boolean hasActiveDeadlineSeconds(); + public java.lang.Integer getBackoffLimit(); + public A withBackoffLimit(java.lang.Integer backoffLimit); + public java.lang.Boolean hasBackoffLimit(); + public java.lang.String getCompletionMode(); + public A withCompletionMode(java.lang.String completionMode); + public java.lang.Boolean hasCompletionMode(); - - /** - * Method is deprecated. use withCompletionMode instead. - */ + + /** Method is deprecated. use withCompletionMode instead. */ @java.lang.Deprecated public A withNewCompletionMode(java.lang.String original); + public java.lang.Integer getCompletions(); + public A withCompletions(java.lang.Integer completions); + public java.lang.Boolean hasCompletions(); + public java.lang.Boolean getManualSelector(); + public A withManualSelector(java.lang.Boolean manualSelector); + public java.lang.Boolean hasManualSelector(); + public java.lang.Integer getParallelism(); + public A withParallelism(java.lang.Integer parallelism); + public java.lang.Boolean hasParallelism(); - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); + public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested withNewSelectorLike( + io.kubernetes.client.openapi.models.V1LabelSelector item); + public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested editSelector(); + public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + public java.lang.Boolean getSuspend(); + public A withSuspend(java.lang.Boolean suspend); + public java.lang.Boolean hasSuspend(); - + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate(); + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate(); + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template); + public java.lang.Boolean hasTemplate(); + public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested withNewTemplate(); - public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + + public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested withNewTemplateLike( + io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested editTemplate(); + public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested editOrNewTemplate(); - public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + + public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + public java.lang.Integer getTtlSecondsAfterFinished(); + public A withTtlSecondsAfterFinished(java.lang.Integer ttlSecondsAfterFinished); + public java.lang.Boolean hasTtlSecondsAfterFinished(); - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested> { public N and(); + public N endSelector(); - } - public interface TemplateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent>{ + + public interface TemplateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent< + io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested> { public N and(); + public N endTemplate(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobSpecFluentImpl.java index 7604d508f4..a2ec4bd050 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobSpecFluentImpl.java @@ -1,20 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1JobSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1JobSpecFluent{ - public V1JobSpecFluentImpl() { - } +/** Generated */ +public class V1JobSpecFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1JobSpecFluent { + public V1JobSpecFluentImpl() {} + public V1JobSpecFluentImpl(io.kubernetes.client.openapi.models.V1JobSpec instance) { this.withActiveDeadlineSeconds(instance.getActiveDeadlineSeconds()); @@ -35,8 +38,8 @@ public V1JobSpecFluentImpl(io.kubernetes.client.openapi.models.V1JobSpec instanc this.withTemplate(instance.getTemplate()); this.withTtlSecondsAfterFinished(instance.getTtlSecondsAfterFinished()); - } + private java.lang.Long activeDeadlineSeconds; private java.lang.Integer backoffLimit; private java.lang.String completionMode; @@ -47,204 +50,309 @@ public V1JobSpecFluentImpl(io.kubernetes.client.openapi.models.V1JobSpec instanc private java.lang.Boolean suspend; private io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder template; private java.lang.Integer ttlSecondsAfterFinished; + public java.lang.Long getActiveDeadlineSeconds() { return this.activeDeadlineSeconds; } + public A withActiveDeadlineSeconds(java.lang.Long activeDeadlineSeconds) { - this.activeDeadlineSeconds=activeDeadlineSeconds; return (A) this; + this.activeDeadlineSeconds = activeDeadlineSeconds; + return (A) this; } + public java.lang.Boolean hasActiveDeadlineSeconds() { return this.activeDeadlineSeconds != null; } + public java.lang.Integer getBackoffLimit() { return this.backoffLimit; } + public A withBackoffLimit(java.lang.Integer backoffLimit) { - this.backoffLimit=backoffLimit; return (A) this; + this.backoffLimit = backoffLimit; + return (A) this; } + public java.lang.Boolean hasBackoffLimit() { return this.backoffLimit != null; } + public java.lang.String getCompletionMode() { return this.completionMode; } + public A withCompletionMode(java.lang.String completionMode) { - this.completionMode=completionMode; return (A) this; + this.completionMode = completionMode; + return (A) this; } + public java.lang.Boolean hasCompletionMode() { return this.completionMode != null; } - - /** - * Method is deprecated. use withCompletionMode instead. - */ + + /** Method is deprecated. use withCompletionMode instead. */ @java.lang.Deprecated public A withNewCompletionMode(java.lang.String original) { - return (A)withCompletionMode(new String(original)); + return (A) withCompletionMode(new String(original)); } + public java.lang.Integer getCompletions() { return this.completions; } + public A withCompletions(java.lang.Integer completions) { - this.completions=completions; return (A) this; + this.completions = completions; + return (A) this; } + public java.lang.Boolean hasCompletions() { return this.completions != null; } + public java.lang.Boolean getManualSelector() { return this.manualSelector; } + public A withManualSelector(java.lang.Boolean manualSelector) { - this.manualSelector=manualSelector; return (A) this; + this.manualSelector = manualSelector; + return (A) this; } + public java.lang.Boolean hasManualSelector() { return this.manualSelector != null; } + public java.lang.Integer getParallelism() { return this.parallelism; } + public A withParallelism(java.lang.Integer parallelism) { - this.parallelism=parallelism; return (A) this; + this.parallelism = parallelism; + return (A) this; } + public java.lang.Boolean hasParallelism() { return this.parallelism != null; } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } + public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested withNewSelector() { return new io.kubernetes.client.openapi.models.V1JobSpecFluentImpl.SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + + public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested withNewSelectorLike( + io.kubernetes.client.openapi.models.V1LabelSelector item) { return new io.kubernetes.client.openapi.models.V1JobSpecFluentImpl.SelectorNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested editSelector() { return withNewSelectorLike(getSelector()); } + public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } + public java.lang.Boolean getSuspend() { return this.suspend; } + public A withSuspend(java.lang.Boolean suspend) { - this.suspend=suspend; return (A) this; + this.suspend = suspend; + return (A) this; } + public java.lang.Boolean hasSuspend() { return this.suspend != null; } - + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template) { _visitables.get("template").remove(this.template); - if (template!=null){ this.template= new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); _visitables.get("template").add(this.template);} return (A) this; + if (template != null) { + this.template = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); + _visitables.get("template").add(this.template); + } + return (A) this; } + public java.lang.Boolean hasTemplate() { return this.template != null; } + public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested withNewTemplate() { return new io.kubernetes.client.openapi.models.V1JobSpecFluentImpl.TemplateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + + public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested withNewTemplateLike( + io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { return new io.kubernetes.client.openapi.models.V1JobSpecFluentImpl.TemplateNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested editTemplate() { return withNewTemplateLike(getTemplate()); } + public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested editOrNewTemplate() { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); + return withNewTemplateLike( + getTemplate() != null + ? getTemplate() + : new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): item); + + public io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + return withNewTemplateLike(getTemplate() != null ? getTemplate() : item); } + public java.lang.Integer getTtlSecondsAfterFinished() { return this.ttlSecondsAfterFinished; } + public A withTtlSecondsAfterFinished(java.lang.Integer ttlSecondsAfterFinished) { - this.ttlSecondsAfterFinished=ttlSecondsAfterFinished; return (A) this; + this.ttlSecondsAfterFinished = ttlSecondsAfterFinished; + return (A) this; } + public java.lang.Boolean hasTtlSecondsAfterFinished() { return this.ttlSecondsAfterFinished != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1JobSpecFluentImpl that = (V1JobSpecFluentImpl) o; - if (activeDeadlineSeconds != null ? !activeDeadlineSeconds.equals(that.activeDeadlineSeconds) :that.activeDeadlineSeconds != null) return false; - if (backoffLimit != null ? !backoffLimit.equals(that.backoffLimit) :that.backoffLimit != null) return false; - if (completionMode != null ? !completionMode.equals(that.completionMode) :that.completionMode != null) return false; - if (completions != null ? !completions.equals(that.completions) :that.completions != null) return false; - if (manualSelector != null ? !manualSelector.equals(that.manualSelector) :that.manualSelector != null) return false; - if (parallelism != null ? !parallelism.equals(that.parallelism) :that.parallelism != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; - if (suspend != null ? !suspend.equals(that.suspend) :that.suspend != null) return false; - if (template != null ? !template.equals(that.template) :that.template != null) return false; - if (ttlSecondsAfterFinished != null ? !ttlSecondsAfterFinished.equals(that.ttlSecondsAfterFinished) :that.ttlSecondsAfterFinished != null) return false; + if (activeDeadlineSeconds != null + ? !activeDeadlineSeconds.equals(that.activeDeadlineSeconds) + : that.activeDeadlineSeconds != null) return false; + if (backoffLimit != null ? !backoffLimit.equals(that.backoffLimit) : that.backoffLimit != null) + return false; + if (completionMode != null + ? !completionMode.equals(that.completionMode) + : that.completionMode != null) return false; + if (completions != null ? !completions.equals(that.completions) : that.completions != null) + return false; + if (manualSelector != null + ? !manualSelector.equals(that.manualSelector) + : that.manualSelector != null) return false; + if (parallelism != null ? !parallelism.equals(that.parallelism) : that.parallelism != null) + return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; + if (suspend != null ? !suspend.equals(that.suspend) : that.suspend != null) return false; + if (template != null ? !template.equals(that.template) : that.template != null) return false; + if (ttlSecondsAfterFinished != null + ? !ttlSecondsAfterFinished.equals(that.ttlSecondsAfterFinished) + : that.ttlSecondsAfterFinished != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(activeDeadlineSeconds, backoffLimit, completionMode, completions, manualSelector, parallelism, selector, suspend, template, ttlSecondsAfterFinished, super.hashCode()); + return java.util.Objects.hash( + activeDeadlineSeconds, + backoffLimit, + completionMode, + completions, + manualSelector, + parallelism, + selector, + suspend, + template, + ttlSecondsAfterFinished, + super.hashCode()); } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested> + implements io.kubernetes.client.openapi.models.V1JobSpecFluent.SelectorNested, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1JobSpecFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - public class TemplateNestedImpl extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested,io.kubernetes.client.fluent.Nested{ + + public class TemplateNestedImpl + extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl< + io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested> + implements io.kubernetes.client.openapi.models.V1JobSpecFluent.TemplateNested, + io.kubernetes.client.fluent.Nested { TemplateNestedImpl(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this, item); } + TemplateNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder builder; + public N and() { return (N) V1JobSpecFluentImpl.this.withTemplate(builder.build()); } + public N endTemplate() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobStatusBuilder.java index 12bc1436fa..f7e16f8fd5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobStatusBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1JobStatusBuilder extends io.kubernetes.client.openapi.models.V1JobStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1JobStatusBuilder + extends io.kubernetes.client.openapi.models.V1JobStatusFluentImpl< + io.kubernetes.client.openapi.models.V1JobStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1JobStatus, + io.kubernetes.client.openapi.models.V1JobStatusBuilder> { public V1JobStatusBuilder() { this(false); } + public V1JobStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1JobStatus(), validationEnabled); } + public V1JobStatusBuilder(io.kubernetes.client.openapi.models.V1JobStatusFluent fluent) { this(fluent, false); } - public V1JobStatusBuilder(io.kubernetes.client.openapi.models.V1JobStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1JobStatusBuilder( + io.kubernetes.client.openapi.models.V1JobStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1JobStatus(), validationEnabled); } - public V1JobStatusBuilder(io.kubernetes.client.openapi.models.V1JobStatusFluent fluent,io.kubernetes.client.openapi.models.V1JobStatus instance) { + + public V1JobStatusBuilder( + io.kubernetes.client.openapi.models.V1JobStatusFluent fluent, + io.kubernetes.client.openapi.models.V1JobStatus instance) { this(fluent, instance, false); } - public V1JobStatusBuilder(io.kubernetes.client.openapi.models.V1JobStatusFluent fluent,io.kubernetes.client.openapi.models.V1JobStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1JobStatusBuilder( + io.kubernetes.client.openapi.models.V1JobStatusFluent fluent, + io.kubernetes.client.openapi.models.V1JobStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withActive(instance.getActive()); fluent.withCompletedIndexes(instance.getCompletedIndexes()); @@ -39,13 +65,17 @@ public V1JobStatusBuilder(io.kubernetes.client.openapi.models.V1JobStatusFluent< fluent.withUncountedTerminatedPods(instance.getUncountedTerminatedPods()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1JobStatusBuilder(io.kubernetes.client.openapi.models.V1JobStatus instance) { - this(instance,false); + this(instance, false); } - public V1JobStatusBuilder(io.kubernetes.client.openapi.models.V1JobStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1JobStatusBuilder( + io.kubernetes.client.openapi.models.V1JobStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withActive(instance.getActive()); this.withCompletedIndexes(instance.getCompletedIndexes()); @@ -64,10 +94,12 @@ public V1JobStatusBuilder(io.kubernetes.client.openapi.models.V1JobStatus instan this.withUncountedTerminatedPods(instance.getUncountedTerminatedPods()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1JobStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1JobStatus build() { V1JobStatus buildable = new V1JobStatus(); buildable.setActive(fluent.getActive()); @@ -81,18 +113,23 @@ public io.kubernetes.client.openapi.models.V1JobStatus build() { buildable.setUncountedTerminatedPods(fluent.getUncountedTerminatedPods()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1JobStatusBuilder that = (V1JobStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobStatusFluent.java index aefc359c38..e748bb7726 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobStatusFluent.java @@ -1,105 +1,191 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.util.Collection; - - /** - * Generated - */ -public interface V1JobStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1JobStatusFluent< + A extends io.kubernetes.client.openapi.models.V1JobStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getActive(); + public A withActive(java.lang.Integer active); + public java.lang.Boolean hasActive(); + public java.lang.String getCompletedIndexes(); + public A withCompletedIndexes(java.lang.String completedIndexes); + public java.lang.Boolean hasCompletedIndexes(); - - /** - * Method is deprecated. use withCompletedIndexes instead. - */ + + /** Method is deprecated. use withCompletedIndexes instead. */ @java.lang.Deprecated public A withNewCompletedIndexes(java.lang.String original); + public java.time.OffsetDateTime getCompletionTime(); + public A withCompletionTime(java.time.OffsetDateTime completionTime); + public java.lang.Boolean hasCompletionTime(); - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JobCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JobCondition item); + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JobCondition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JobCondition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1JobCondition... items); - public A addAllToConditions(java.util.Collection items); + + public A addAllToConditions( + java.util.Collection items); + public A removeFromConditions(io.kubernetes.client.openapi.models.V1JobCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getConditions(); + public java.util.List buildConditions(); + public io.kubernetes.client.openapi.models.V1JobCondition buildCondition(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1JobCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1JobCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1JobCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); + + public io.kubernetes.client.openapi.models.V1JobCondition buildMatchingCondition( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate); + + public A withConditions( + java.util.List conditions); + public A withConditions(io.kubernetes.client.openapi.models.V1JobCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1JobCondition item); - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JobCondition item); - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1JobCondition item); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JobCondition item); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested editCondition( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate + predicate); + public java.lang.Integer getFailed(); + public A withFailed(java.lang.Integer failed); + public java.lang.Boolean hasFailed(); + public java.lang.Integer getReady(); + public A withReady(java.lang.Integer ready); + public java.lang.Boolean hasReady(); + public java.time.OffsetDateTime getStartTime(); + public A withStartTime(java.time.OffsetDateTime startTime); + public java.lang.Boolean hasStartTime(); + public java.lang.Integer getSucceeded(); + public A withSucceeded(java.lang.Integer succeeded); + public java.lang.Boolean hasSucceeded(); - + /** * This method has been deprecated, please use method buildUncountedTerminatedPods instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1UncountedTerminatedPods getUncountedTerminatedPods(); - public io.kubernetes.client.openapi.models.V1UncountedTerminatedPods buildUncountedTerminatedPods(); - public A withUncountedTerminatedPods(io.kubernetes.client.openapi.models.V1UncountedTerminatedPods uncountedTerminatedPods); + + public io.kubernetes.client.openapi.models.V1UncountedTerminatedPods + buildUncountedTerminatedPods(); + + public A withUncountedTerminatedPods( + io.kubernetes.client.openapi.models.V1UncountedTerminatedPods uncountedTerminatedPods); + public java.lang.Boolean hasUncountedTerminatedPods(); - public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested withNewUncountedTerminatedPods(); - public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested withNewUncountedTerminatedPodsLike(io.kubernetes.client.openapi.models.V1UncountedTerminatedPods item); - public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested editUncountedTerminatedPods(); - public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested editOrNewUncountedTerminatedPods(); - public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested editOrNewUncountedTerminatedPodsLike(io.kubernetes.client.openapi.models.V1UncountedTerminatedPods item); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1JobConditionFluent>{ + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested + withNewUncountedTerminatedPods(); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested + withNewUncountedTerminatedPodsLike( + io.kubernetes.client.openapi.models.V1UncountedTerminatedPods item); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested + editUncountedTerminatedPods(); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested + editOrNewUncountedTerminatedPods(); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested + editOrNewUncountedTerminatedPodsLike( + io.kubernetes.client.openapi.models.V1UncountedTerminatedPods item); + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1JobConditionFluent< + io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested> { public N and(); + public N endCondition(); - } - public interface UncountedTerminatedPodsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent>{ + + public interface UncountedTerminatedPodsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent< + io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested< + N>> { public N and(); + public N endUncountedTerminatedPods(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobStatusFluentImpl.java index 5e6d3c8999..97cf5adc72 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobStatusFluentImpl.java @@ -1,26 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1JobStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1JobStatusFluent{ - public V1JobStatusFluentImpl() { - } + +/** Generated */ +public class V1JobStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1JobStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1JobStatusFluent { + public V1JobStatusFluentImpl() {} + public V1JobStatusFluentImpl(io.kubernetes.client.openapi.models.V1JobStatus instance) { this.withActive(instance.getActive()); @@ -39,8 +40,8 @@ public V1JobStatusFluentImpl(io.kubernetes.client.openapi.models.V1JobStatus ins this.withSucceeded(instance.getSucceeded()); this.withUncountedTerminatedPods(instance.getUncountedTerminatedPods()); - } + private java.lang.Integer active; private java.lang.String completedIndexes; private java.time.OffsetDateTime completionTime; @@ -49,70 +50,150 @@ public V1JobStatusFluentImpl(io.kubernetes.client.openapi.models.V1JobStatus ins private java.lang.Integer ready; private java.time.OffsetDateTime startTime; private java.lang.Integer succeeded; - private io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsBuilder uncountedTerminatedPods; + private io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsBuilder + uncountedTerminatedPods; + public java.lang.Integer getActive() { return this.active; } + public A withActive(java.lang.Integer active) { - this.active=active; return (A) this; + this.active = active; + return (A) this; } + public java.lang.Boolean hasActive() { return this.active != null; } + public java.lang.String getCompletedIndexes() { return this.completedIndexes; } + public A withCompletedIndexes(java.lang.String completedIndexes) { - this.completedIndexes=completedIndexes; return (A) this; + this.completedIndexes = completedIndexes; + return (A) this; } + public java.lang.Boolean hasCompletedIndexes() { return this.completedIndexes != null; } - - /** - * Method is deprecated. use withCompletedIndexes instead. - */ + + /** Method is deprecated. use withCompletedIndexes instead. */ @java.lang.Deprecated public A withNewCompletedIndexes(java.lang.String original) { - return (A)withCompletedIndexes(new String(original)); + return (A) withCompletedIndexes(new String(original)); } + public java.time.OffsetDateTime getCompletionTime() { return this.completionTime; } + public A withCompletionTime(java.time.OffsetDateTime completionTime) { - this.completionTime=completionTime; return (A) this; + this.completionTime = completionTime; + return (A) this; } + public java.lang.Boolean hasCompletionTime() { return this.completionTime != null; } - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JobCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1JobConditionBuilder builder = new io.kubernetes.client.openapi.models.V1JobConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JobCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1JobConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1JobConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JobCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1JobConditionBuilder builder = new io.kubernetes.client.openapi.models.V1JobConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JobCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1JobConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1JobConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } + public A addToConditions(io.kubernetes.client.openapi.models.V1JobCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1JobCondition item : items) {io.kubernetes.client.openapi.models.V1JobConditionBuilder builder = new io.kubernetes.client.openapi.models.V1JobConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1JobCondition item : items) { + io.kubernetes.client.openapi.models.V1JobConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1JobConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1JobCondition item : items) {io.kubernetes.client.openapi.models.V1JobConditionBuilder builder = new io.kubernetes.client.openapi.models.V1JobConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1JobCondition item : items) { + io.kubernetes.client.openapi.models.V1JobConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1JobConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } + public A removeFromConditions(io.kubernetes.client.openapi.models.V1JobCondition... items) { - for (io.kubernetes.client.openapi.models.V1JobCondition item : items) {io.kubernetes.client.openapi.models.V1JobConditionBuilder builder = new io.kubernetes.client.openapi.models.V1JobConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1JobCondition item : items) { + io.kubernetes.client.openapi.models.V1JobConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1JobConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1JobCondition item : items) {io.kubernetes.client.openapi.models.V1JobConditionBuilder builder = new io.kubernetes.client.openapi.models.V1JobConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1JobCondition item : items) { + io.kubernetes.client.openapi.models.V1JobConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1JobConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1JobConditionBuilder builder = each.next(); @@ -121,198 +202,353 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { return conditions != null ? build(conditions) : null; } + public java.util.List buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1JobCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1JobCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1JobCondition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1JobCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1JobCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1JobConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1JobCondition buildMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1JobConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1JobConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1JobConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1JobCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1JobCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } + public A withConditions(io.kubernetes.client.openapi.models.V1JobCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1JobCondition item :conditions){ this.addToConditions(item);}} return (A) this; + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1JobCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested addNewCondition() { + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested + addNewCondition() { return new io.kubernetes.client.openapi.models.V1JobStatusFluentImpl.ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1JobCondition item) { - return new io.kubernetes.client.openapi.models.V1JobStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1JobCondition item) { + return new io.kubernetes.client.openapi.models.V1JobStatusFluentImpl.ConditionsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JobCondition item) { - return new io.kubernetes.client.openapi.models.V1JobStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JobCondition item) { + return new io.kubernetes.client.openapi.models.V1JobStatusFluentImpl.ConditionsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested editCondition( + java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewUncountedTerminatedPods() { - return new io.kubernetes.client.openapi.models.V1JobStatusFluentImpl.UncountedTerminatedPodsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested + withNewUncountedTerminatedPods() { + return new io.kubernetes.client.openapi.models.V1JobStatusFluentImpl + .UncountedTerminatedPodsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested withNewUncountedTerminatedPodsLike(io.kubernetes.client.openapi.models.V1UncountedTerminatedPods item) { - return new io.kubernetes.client.openapi.models.V1JobStatusFluentImpl.UncountedTerminatedPodsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested + withNewUncountedTerminatedPodsLike( + io.kubernetes.client.openapi.models.V1UncountedTerminatedPods item) { + return new io.kubernetes.client.openapi.models.V1JobStatusFluentImpl + .UncountedTerminatedPodsNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested editUncountedTerminatedPods() { + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested + editUncountedTerminatedPods() { return withNewUncountedTerminatedPodsLike(getUncountedTerminatedPods()); } - public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested editOrNewUncountedTerminatedPods() { - return withNewUncountedTerminatedPodsLike(getUncountedTerminatedPods() != null ? getUncountedTerminatedPods(): new io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested + editOrNewUncountedTerminatedPods() { + return withNewUncountedTerminatedPodsLike( + getUncountedTerminatedPods() != null + ? getUncountedTerminatedPods() + : new io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested editOrNewUncountedTerminatedPodsLike(io.kubernetes.client.openapi.models.V1UncountedTerminatedPods item) { - return withNewUncountedTerminatedPodsLike(getUncountedTerminatedPods() != null ? getUncountedTerminatedPods(): item); + + public io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested + editOrNewUncountedTerminatedPodsLike( + io.kubernetes.client.openapi.models.V1UncountedTerminatedPods item) { + return withNewUncountedTerminatedPodsLike( + getUncountedTerminatedPods() != null ? getUncountedTerminatedPods() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1JobStatusFluentImpl that = (V1JobStatusFluentImpl) o; - if (active != null ? !active.equals(that.active) :that.active != null) return false; - if (completedIndexes != null ? !completedIndexes.equals(that.completedIndexes) :that.completedIndexes != null) return false; - if (completionTime != null ? !completionTime.equals(that.completionTime) :that.completionTime != null) return false; - if (conditions != null ? !conditions.equals(that.conditions) :that.conditions != null) return false; - if (failed != null ? !failed.equals(that.failed) :that.failed != null) return false; - if (ready != null ? !ready.equals(that.ready) :that.ready != null) return false; - if (startTime != null ? !startTime.equals(that.startTime) :that.startTime != null) return false; - if (succeeded != null ? !succeeded.equals(that.succeeded) :that.succeeded != null) return false; - if (uncountedTerminatedPods != null ? !uncountedTerminatedPods.equals(that.uncountedTerminatedPods) :that.uncountedTerminatedPods != null) return false; + if (active != null ? !active.equals(that.active) : that.active != null) return false; + if (completedIndexes != null + ? !completedIndexes.equals(that.completedIndexes) + : that.completedIndexes != null) return false; + if (completionTime != null + ? !completionTime.equals(that.completionTime) + : that.completionTime != null) return false; + if (conditions != null ? !conditions.equals(that.conditions) : that.conditions != null) + return false; + if (failed != null ? !failed.equals(that.failed) : that.failed != null) return false; + if (ready != null ? !ready.equals(that.ready) : that.ready != null) return false; + if (startTime != null ? !startTime.equals(that.startTime) : that.startTime != null) + return false; + if (succeeded != null ? !succeeded.equals(that.succeeded) : that.succeeded != null) + return false; + if (uncountedTerminatedPods != null + ? !uncountedTerminatedPods.equals(that.uncountedTerminatedPods) + : that.uncountedTerminatedPods != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(active, completedIndexes, completionTime, conditions, failed, ready, startTime, succeeded, uncountedTerminatedPods, super.hashCode()); + return java.util.Objects.hash( + active, + completedIndexes, + completionTime, + conditions, + failed, + ready, + startTime, + succeeded, + uncountedTerminatedPods, + super.hashCode()); } - public class ConditionsNestedImpl extends io.kubernetes.client.openapi.models.V1JobConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1JobCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1JobConditionFluentImpl< + io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1JobStatusFluent.ConditionsNested, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1JobCondition item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1JobConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1JobConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1JobConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1JobStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1JobStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - public class UncountedTerminatedPodsNestedImpl extends io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluentImpl> implements io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested,io.kubernetes.client.fluent.Nested{ - UncountedTerminatedPodsNestedImpl(io.kubernetes.client.openapi.models.V1UncountedTerminatedPods item) { - this.builder = new io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsBuilder(this, item); + + public class UncountedTerminatedPodsNestedImpl + extends io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluentImpl< + io.kubernetes.client.openapi.models.V1JobStatusFluent.UncountedTerminatedPodsNested> + implements io.kubernetes.client.openapi.models.V1JobStatusFluent + .UncountedTerminatedPodsNested< + N>, + io.kubernetes.client.fluent.Nested { + UncountedTerminatedPodsNestedImpl( + io.kubernetes.client.openapi.models.V1UncountedTerminatedPods item) { + this.builder = + new io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsBuilder(this, item); } + UncountedTerminatedPodsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsBuilder(this); } + io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsBuilder builder; + public N and() { return (N) V1JobStatusFluentImpl.this.withUncountedTerminatedPods(builder.build()); } + public N endUncountedTerminatedPods() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobTemplateSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobTemplateSpecBuilder.java index 5523db66f7..6cd63102fa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobTemplateSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobTemplateSpecBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1JobTemplateSpecBuilder extends io.kubernetes.client.openapi.models.V1JobTemplateSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1JobTemplateSpecBuilder + extends io.kubernetes.client.openapi.models.V1JobTemplateSpecFluentImpl< + io.kubernetes.client.openapi.models.V1JobTemplateSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1JobTemplateSpec, + io.kubernetes.client.openapi.models.V1JobTemplateSpecBuilder> { public V1JobTemplateSpecBuilder() { this(false); } + public V1JobTemplateSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1JobTemplateSpec(), validationEnabled); } - public V1JobTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent fluent) { + + public V1JobTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent fluent) { this(fluent, false); } - public V1JobTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1JobTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1JobTemplateSpec(), validationEnabled); } - public V1JobTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent fluent,io.kubernetes.client.openapi.models.V1JobTemplateSpec instance) { + + public V1JobTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent fluent, + io.kubernetes.client.openapi.models.V1JobTemplateSpec instance) { this(fluent, instance, false); } - public V1JobTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent fluent,io.kubernetes.client.openapi.models.V1JobTemplateSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1JobTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent fluent, + io.kubernetes.client.openapi.models.V1JobTemplateSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMetadata(instance.getMetadata()); fluent.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1JobTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1JobTemplateSpec instance) { - this(instance,false); + this(instance, false); } - public V1JobTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1JobTemplateSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1JobTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1JobTemplateSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1JobTemplateSpec build() { V1JobTemplateSpec buildable = new V1JobTemplateSpec(); buildable.setMetadata(fluent.getMetadata()); buildable.setSpec(fluent.getSpec()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1JobTemplateSpecBuilder that = (V1JobTemplateSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobTemplateSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobTemplateSpecFluent.java index b673abbbbf..3c2f576b1f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobTemplateSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobTemplateSpecFluent.java @@ -1,55 +1,92 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1JobTemplateSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1JobTemplateSpecFluent< + A extends io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JobSpec getSpec(); + public io.kubernetes.client.openapi.models.V1JobSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1JobSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item); + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1JobSpec item); + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1JobSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1JobSpecFluent< + io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested> { public N and(); + public N endSpec(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobTemplateSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobTemplateSpecFluentImpl.java index 35a97e8608..c877e353a8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobTemplateSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1JobTemplateSpecFluentImpl.java @@ -1,135 +1,200 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1JobTemplateSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent { + public V1JobTemplateSpecFluentImpl() {} - /** - * Generated - */ -public class V1JobTemplateSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent{ - public V1JobTemplateSpecFluentImpl() { - } - public V1JobTemplateSpecFluentImpl(io.kubernetes.client.openapi.models.V1JobTemplateSpec instance) { + public V1JobTemplateSpecFluentImpl( + io.kubernetes.client.openapi.models.V1JobTemplateSpec instance) { this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - } + private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1JobSpecBuilder spec; - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1JobTemplateSpecFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1JobTemplateSpecFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1JobTemplateSpecFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JobSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1JobSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1JobSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1JobSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1JobSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1JobTemplateSpecFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item) { + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1JobSpec item) { return new io.kubernetes.client.openapi.models.V1JobTemplateSpecFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1JobSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1JobSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1JobTemplateSpecFluentImpl that = (V1JobTemplateSpecFluentImpl) o; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(metadata, spec, super.hashCode()); + return java.util.Objects.hash(metadata, spec, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1JobTemplateSpecFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1JobSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1JobSpecFluentImpl< + io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1JobTemplateSpecFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1JobSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1JobSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1JobSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1JobSpecBuilder builder; + public N and() { return (N) V1JobTemplateSpecFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1KeyToPathBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1KeyToPathBuilder.java index ae1649b327..6ce0a69618 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1KeyToPathBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1KeyToPathBuilder.java @@ -1,49 +1,81 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1KeyToPathBuilder extends io.kubernetes.client.openapi.models.V1KeyToPathFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1KeyToPathBuilder + extends io.kubernetes.client.openapi.models.V1KeyToPathFluentImpl< + io.kubernetes.client.openapi.models.V1KeyToPathBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1KeyToPath, + io.kubernetes.client.openapi.models.V1KeyToPathBuilder> { public V1KeyToPathBuilder() { this(false); } + public V1KeyToPathBuilder(java.lang.Boolean validationEnabled) { this(new V1KeyToPath(), validationEnabled); } + public V1KeyToPathBuilder(io.kubernetes.client.openapi.models.V1KeyToPathFluent fluent) { this(fluent, false); } - public V1KeyToPathBuilder(io.kubernetes.client.openapi.models.V1KeyToPathFluent fluent,java.lang.Boolean validationEnabled) { + + public V1KeyToPathBuilder( + io.kubernetes.client.openapi.models.V1KeyToPathFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1KeyToPath(), validationEnabled); } - public V1KeyToPathBuilder(io.kubernetes.client.openapi.models.V1KeyToPathFluent fluent,io.kubernetes.client.openapi.models.V1KeyToPath instance) { + + public V1KeyToPathBuilder( + io.kubernetes.client.openapi.models.V1KeyToPathFluent fluent, + io.kubernetes.client.openapi.models.V1KeyToPath instance) { this(fluent, instance, false); } - public V1KeyToPathBuilder(io.kubernetes.client.openapi.models.V1KeyToPathFluent fluent,io.kubernetes.client.openapi.models.V1KeyToPath instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1KeyToPathBuilder( + io.kubernetes.client.openapi.models.V1KeyToPathFluent fluent, + io.kubernetes.client.openapi.models.V1KeyToPath instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withKey(instance.getKey()); fluent.withMode(instance.getMode()); fluent.withPath(instance.getPath()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1KeyToPathBuilder(io.kubernetes.client.openapi.models.V1KeyToPath instance) { - this(instance,false); + this(instance, false); } - public V1KeyToPathBuilder(io.kubernetes.client.openapi.models.V1KeyToPath instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1KeyToPathBuilder( + io.kubernetes.client.openapi.models.V1KeyToPath instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withKey(instance.getKey()); this.withMode(instance.getMode()); this.withPath(instance.getPath()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1KeyToPathFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1KeyToPath build() { V1KeyToPath buildable = new V1KeyToPath(); buildable.setKey(fluent.getKey()); @@ -51,18 +83,23 @@ public io.kubernetes.client.openapi.models.V1KeyToPath build() { buildable.setPath(fluent.getPath()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1KeyToPathBuilder that = (V1KeyToPathBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1KeyToPathFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1KeyToPathFluent.java index 0b52be7bd6..9ed4d8d91e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1KeyToPathFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1KeyToPathFluent.java @@ -1,36 +1,44 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1KeyToPathFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1KeyToPathFluent< + A extends io.kubernetes.client.openapi.models.V1KeyToPathFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getKey(); + public A withKey(java.lang.String key); + public java.lang.Boolean hasKey(); - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original); + public java.lang.Integer getMode(); + public A withMode(java.lang.Integer mode); + public java.lang.Boolean hasMode(); + public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1KeyToPathFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1KeyToPathFluentImpl.java index 6e6399892d..621161a3dd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1KeyToPathFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1KeyToPathFluentImpl.java @@ -1,83 +1,98 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1KeyToPathFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1KeyToPathFluent{ - public V1KeyToPathFluentImpl() { - } +/** Generated */ +public class V1KeyToPathFluentImpl< + A extends io.kubernetes.client.openapi.models.V1KeyToPathFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1KeyToPathFluent { + public V1KeyToPathFluentImpl() {} + public V1KeyToPathFluentImpl(io.kubernetes.client.openapi.models.V1KeyToPath instance) { this.withKey(instance.getKey()); this.withMode(instance.getMode()); this.withPath(instance.getPath()); - } + private java.lang.String key; private java.lang.Integer mode; private java.lang.String path; + public java.lang.String getKey() { return this.key; } + public A withKey(java.lang.String key) { - this.key=key; return (A) this; + this.key = key; + return (A) this; } + public java.lang.Boolean hasKey() { return this.key != null; } - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original) { - return (A)withKey(new String(original)); + return (A) withKey(new String(original)); } + public java.lang.Integer getMode() { return this.mode; } + public A withMode(java.lang.Integer mode) { - this.mode=mode; return (A) this; + this.mode = mode; + return (A) this; } + public java.lang.Boolean hasMode() { return this.mode != null; } + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1KeyToPathFluentImpl that = (V1KeyToPathFluentImpl) o; - if (key != null ? !key.equals(that.key) :that.key != null) return false; - if (mode != null ? !mode.equals(that.mode) :that.mode != null) return false; - if (path != null ? !path.equals(that.path) :that.path != null) return false; + if (key != null ? !key.equals(that.key) : that.key != null) return false; + if (mode != null ? !mode.equals(that.mode) : that.mode != null) return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(key, mode, path, super.hashCode()); + return java.util.Objects.hash(key, mode, path, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorBuilder.java index 6570b92179..d4836116be 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LabelSelectorBuilder extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LabelSelectorBuilder + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LabelSelector, + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder> { public V1LabelSelectorBuilder() { this(false); } + public V1LabelSelectorBuilder(java.lang.Boolean validationEnabled) { this(new V1LabelSelector(), validationEnabled); } - public V1LabelSelectorBuilder(io.kubernetes.client.openapi.models.V1LabelSelectorFluent fluent) { + + public V1LabelSelectorBuilder( + io.kubernetes.client.openapi.models.V1LabelSelectorFluent fluent) { this(fluent, false); } - public V1LabelSelectorBuilder(io.kubernetes.client.openapi.models.V1LabelSelectorFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LabelSelectorBuilder( + io.kubernetes.client.openapi.models.V1LabelSelectorFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LabelSelector(), validationEnabled); } - public V1LabelSelectorBuilder(io.kubernetes.client.openapi.models.V1LabelSelectorFluent fluent,io.kubernetes.client.openapi.models.V1LabelSelector instance) { + + public V1LabelSelectorBuilder( + io.kubernetes.client.openapi.models.V1LabelSelectorFluent fluent, + io.kubernetes.client.openapi.models.V1LabelSelector instance) { this(fluent, instance, false); } - public V1LabelSelectorBuilder(io.kubernetes.client.openapi.models.V1LabelSelectorFluent fluent,io.kubernetes.client.openapi.models.V1LabelSelector instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LabelSelectorBuilder( + io.kubernetes.client.openapi.models.V1LabelSelectorFluent fluent, + io.kubernetes.client.openapi.models.V1LabelSelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMatchExpressions(instance.getMatchExpressions()); fluent.withMatchLabels(instance.getMatchLabels()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1LabelSelectorBuilder(io.kubernetes.client.openapi.models.V1LabelSelector instance) { - this(instance,false); + this(instance, false); } - public V1LabelSelectorBuilder(io.kubernetes.client.openapi.models.V1LabelSelector instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LabelSelectorBuilder( + io.kubernetes.client.openapi.models.V1LabelSelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMatchExpressions(instance.getMatchExpressions()); this.withMatchLabels(instance.getMatchLabels()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LabelSelectorFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LabelSelector build() { V1LabelSelector buildable = new V1LabelSelector(); buildable.setMatchExpressions(fluent.getMatchExpressions()); buildable.setMatchLabels(fluent.getMatchLabels()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LabelSelectorBuilder that = (V1LabelSelectorBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorFluent.java index 8d87cf5e67..f710a8efd5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorFluent.java @@ -1,66 +1,130 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1LabelSelectorFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToMatchExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item); - public A setToMatchExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item); - public A addToMatchExpressions(io.kubernetes.client.openapi.models.V1LabelSelectorRequirement... items); - public A addAllToMatchExpressions(java.util.Collection items); - public A removeFromMatchExpressions(io.kubernetes.client.openapi.models.V1LabelSelectorRequirement... items); - public A removeAllFromMatchExpressions(java.util.Collection items); - public A removeMatchingFromMatchExpressions(java.util.function.Predicate predicate); - +/** Generated */ +public interface V1LabelSelectorFluent< + A extends io.kubernetes.client.openapi.models.V1LabelSelectorFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToMatchExpressions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item); + + public A setToMatchExpressions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item); + + public A addToMatchExpressions( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement... items); + + public A addAllToMatchExpressions( + java.util.Collection items); + + public A removeFromMatchExpressions( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement... items); + + public A removeAllFromMatchExpressions( + java.util.Collection items); + + public A removeMatchingFromMatchExpressions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder> + predicate); + /** * This method has been deprecated, please use method buildMatchExpressions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getMatchExpressions(); - public java.util.List buildMatchExpressions(); - public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement buildMatchExpression(java.lang.Integer index); + public java.util.List + getMatchExpressions(); + + public java.util.List + buildMatchExpressions(); + + public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement buildMatchExpression( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement buildFirstMatchExpression(); + public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement buildLastMatchExpression(); - public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement buildMatchingMatchExpression(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMatchExpression(java.util.function.Predicate predicate); - public A withMatchExpressions(java.util.List matchExpressions); - public A withMatchExpressions(io.kubernetes.client.openapi.models.V1LabelSelectorRequirement... matchExpressions); + + public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement + buildMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder> + predicate); + + public java.lang.Boolean hasMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder> + predicate); + + public A withMatchExpressions( + java.util.List + matchExpressions); + + public A withMatchExpressions( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement... matchExpressions); + public java.lang.Boolean hasMatchExpressions(); - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested addNewMatchExpression(); - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested addNewMatchExpressionLike(io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item); - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested setNewMatchExpressionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item); - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested editMatchExpression(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested editFirstMatchExpression(); - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested editLastMatchExpression(); - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested editMatchingMatchExpression(java.util.function.Predicate predicate); - public A addToMatchLabels(java.lang.String key,java.lang.String value); - public A addToMatchLabels(java.util.Map map); + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + addNewMatchExpression(); + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + addNewMatchExpressionLike( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item); + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + setNewMatchExpressionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item); + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + editMatchExpression(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + editFirstMatchExpression(); + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + editLastMatchExpression(); + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + editMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder> + predicate); + + public A addToMatchLabels(java.lang.String key, java.lang.String value); + + public A addToMatchLabels(java.util.Map map); + public A removeFromMatchLabels(java.lang.String key); - public A removeFromMatchLabels(java.util.Map map); - public java.util.Map getMatchLabels(); - public A withMatchLabels(java.util.Map matchLabels); + + public A removeFromMatchLabels(java.util.Map map); + + public java.util.Map getMatchLabels(); + + public A withMatchLabels(java.util.Map matchLabels); + public java.lang.Boolean hasMatchLabels(); - public interface MatchExpressionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent>{ + + public interface MatchExpressionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent< + io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested> { public N and(); + public N endMatchExpression(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorFluentImpl.java index 770e8bd64a..ff63926c45 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorFluentImpl.java @@ -1,63 +1,142 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; -import java.util.Map; - /** - * Generated - */ -public class V1LabelSelectorFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LabelSelectorFluent{ - public V1LabelSelectorFluentImpl() { - } +/** Generated */ +public class V1LabelSelectorFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LabelSelectorFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LabelSelectorFluent { + public V1LabelSelectorFluentImpl() {} + public V1LabelSelectorFluentImpl(io.kubernetes.client.openapi.models.V1LabelSelector instance) { this.withMatchExpressions(instance.getMatchExpressions()); this.withMatchLabels(instance.getMatchLabels()); - } - private java.util.ArrayList matchExpressions; - private java.util.Map matchLabels; - public A addToMatchExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item) { - if (this.matchExpressions == null) {this.matchExpressions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(item);_visitables.get("matchExpressions").add(index >= 0 ? index : _visitables.get("matchExpressions").size(), builder);this.matchExpressions.add(index >= 0 ? index : matchExpressions.size(), builder); return (A)this; + + private java.util.ArrayList + matchExpressions; + private java.util.Map matchLabels; + + public A addToMatchExpressions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item) { + if (this.matchExpressions == null) { + this.matchExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder>(); + } + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(item); + _visitables + .get("matchExpressions") + .add(index >= 0 ? index : _visitables.get("matchExpressions").size(), builder); + this.matchExpressions.add(index >= 0 ? index : matchExpressions.size(), builder); + return (A) this; } - public A setToMatchExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item) { - if (this.matchExpressions == null) {this.matchExpressions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(item); - if (index < 0 || index >= _visitables.get("matchExpressions").size()) { _visitables.get("matchExpressions").add(builder); } else { _visitables.get("matchExpressions").set(index, builder);} - if (index < 0 || index >= matchExpressions.size()) { matchExpressions.add(builder); } else { matchExpressions.set(index, builder);} - return (A)this; + + public A setToMatchExpressions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item) { + if (this.matchExpressions == null) { + this.matchExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder>(); + } + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(item); + if (index < 0 || index >= _visitables.get("matchExpressions").size()) { + _visitables.get("matchExpressions").add(builder); + } else { + _visitables.get("matchExpressions").set(index, builder); + } + if (index < 0 || index >= matchExpressions.size()) { + matchExpressions.add(builder); + } else { + matchExpressions.set(index, builder); + } + return (A) this; } - public A addToMatchExpressions(io.kubernetes.client.openapi.models.V1LabelSelectorRequirement... items) { - if (this.matchExpressions == null) {this.matchExpressions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(item);_visitables.get("matchExpressions").add(builder);this.matchExpressions.add(builder);} return (A)this; + + public A addToMatchExpressions( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement... items) { + if (this.matchExpressions == null) { + this.matchExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(item); + _visitables.get("matchExpressions").add(builder); + this.matchExpressions.add(builder); + } + return (A) this; } - public A addAllToMatchExpressions(java.util.Collection items) { - if (this.matchExpressions == null) {this.matchExpressions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(item);_visitables.get("matchExpressions").add(builder);this.matchExpressions.add(builder);} return (A)this; + + public A addAllToMatchExpressions( + java.util.Collection items) { + if (this.matchExpressions == null) { + this.matchExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(item); + _visitables.get("matchExpressions").add(builder); + this.matchExpressions.add(builder); + } + return (A) this; } - public A removeFromMatchExpressions(io.kubernetes.client.openapi.models.V1LabelSelectorRequirement... items) { - for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(item);_visitables.get("matchExpressions").remove(builder);if (this.matchExpressions != null) {this.matchExpressions.remove(builder);}} return (A)this; + + public A removeFromMatchExpressions( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement... items) { + for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(item); + _visitables.get("matchExpressions").remove(builder); + if (this.matchExpressions != null) { + this.matchExpressions.remove(builder); + } + } + return (A) this; } - public A removeAllFromMatchExpressions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(item);_visitables.get("matchExpressions").remove(builder);if (this.matchExpressions != null) {this.matchExpressions.remove(builder);}} return (A)this; + + public A removeAllFromMatchExpressions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(item); + _visitables.get("matchExpressions").remove(builder); + if (this.matchExpressions != null) { + this.matchExpressions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromMatchExpressions(java.util.function.Predicate predicate) { + + public A removeMatchingFromMatchExpressions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder> + predicate) { if (matchExpressions == null) return (A) this; - final Iterator each = matchExpressions.iterator(); + final Iterator each = + matchExpressions.iterator(); final List visitables = _visitables.get("matchExpressions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder = each.next(); @@ -66,130 +145,266 @@ public A removeMatchingFromMatchExpressions(java.util.function.Predicate getMatchExpressions() { + public java.util.List + getMatchExpressions() { return matchExpressions != null ? build(matchExpressions) : null; } - public java.util.List buildMatchExpressions() { + + public java.util.List + buildMatchExpressions() { return matchExpressions != null ? build(matchExpressions) : null; } - public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement buildMatchExpression(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement buildMatchExpression( + java.lang.Integer index) { return this.matchExpressions.get(index).build(); } - public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement buildFirstMatchExpression() { + + public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement + buildFirstMatchExpression() { return this.matchExpressions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement buildLastMatchExpression() { return this.matchExpressions.get(matchExpressions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement buildMatchingMatchExpression(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder item: matchExpressions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement + buildMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder item : + matchExpressions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingMatchExpression(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder item: matchExpressions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder item : + matchExpressions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withMatchExpressions(java.util.List matchExpressions) { - if (this.matchExpressions != null) { _visitables.get("matchExpressions").removeAll(this.matchExpressions);} - if (matchExpressions != null) {this.matchExpressions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item : matchExpressions){this.addToMatchExpressions(item);}} else { this.matchExpressions = null;} return (A) this; + + public A withMatchExpressions( + java.util.List + matchExpressions) { + if (this.matchExpressions != null) { + _visitables.get("matchExpressions").removeAll(this.matchExpressions); + } + if (matchExpressions != null) { + this.matchExpressions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item : matchExpressions) { + this.addToMatchExpressions(item); + } + } else { + this.matchExpressions = null; + } + return (A) this; } - public A withMatchExpressions(io.kubernetes.client.openapi.models.V1LabelSelectorRequirement... matchExpressions) { - if (this.matchExpressions != null) {this.matchExpressions.clear();} - if (matchExpressions != null) {for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item :matchExpressions){ this.addToMatchExpressions(item);}} return (A) this; + + public A withMatchExpressions( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement... matchExpressions) { + if (this.matchExpressions != null) { + this.matchExpressions.clear(); + } + if (matchExpressions != null) { + for (io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item : matchExpressions) { + this.addToMatchExpressions(item); + } + } + return (A) this; } + public java.lang.Boolean hasMatchExpressions() { return matchExpressions != null && !matchExpressions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested addNewMatchExpression() { - return new io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl.MatchExpressionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + addNewMatchExpression() { + return new io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl + .MatchExpressionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested addNewMatchExpressionLike(io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item) { - return new io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl.MatchExpressionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + addNewMatchExpressionLike( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item) { + return new io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl + .MatchExpressionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested setNewMatchExpressionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item) { - return new io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl.MatchExpressionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + setNewMatchExpressionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item) { + return new io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl + .MatchExpressionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested editMatchExpression(java.lang.Integer index) { - if (matchExpressions.size() <= index) throw new RuntimeException("Can't edit matchExpressions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + editMatchExpression(java.lang.Integer index) { + if (matchExpressions.size() <= index) + throw new RuntimeException("Can't edit matchExpressions. Index exceeds size."); return setNewMatchExpressionLike(index, buildMatchExpression(index)); } - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested editFirstMatchExpression() { - if (matchExpressions.size() == 0) throw new RuntimeException("Can't edit first matchExpressions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + editFirstMatchExpression() { + if (matchExpressions.size() == 0) + throw new RuntimeException("Can't edit first matchExpressions. The list is empty."); return setNewMatchExpressionLike(0, buildMatchExpression(0)); } - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested editLastMatchExpression() { + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + editLastMatchExpression() { int index = matchExpressions.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last matchExpressions. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last matchExpressions. The list is empty."); return setNewMatchExpressionLike(index, buildMatchExpression(index)); } - public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested editMatchingMatchExpression(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested + editMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder> + predicate) { int index = -1; - for (int i=0;i map) { - if(this.matchLabels == null && map != null) { this.matchLabels = new java.util.LinkedHashMap(); } - if(map != null) { this.matchLabels.putAll(map);} return (A)this; + + public A addToMatchLabels(java.util.Map map) { + if (this.matchLabels == null && map != null) { + this.matchLabels = new java.util.LinkedHashMap(); + } + if (map != null) { + this.matchLabels.putAll(map); + } + return (A) this; } + public A removeFromMatchLabels(java.lang.String key) { - if(this.matchLabels == null) { return (A) this; } - if(key != null && this.matchLabels != null) {this.matchLabels.remove(key);} return (A)this; + if (this.matchLabels == null) { + return (A) this; + } + if (key != null && this.matchLabels != null) { + this.matchLabels.remove(key); + } + return (A) this; } - public A removeFromMatchLabels(java.util.Map map) { - if(this.matchLabels == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.matchLabels != null){this.matchLabels.remove(key);}}} return (A)this; + + public A removeFromMatchLabels(java.util.Map map) { + if (this.matchLabels == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.matchLabels != null) { + this.matchLabels.remove(key); + } + } + } + return (A) this; } - public java.util.Map getMatchLabels() { + + public java.util.Map getMatchLabels() { return this.matchLabels; } - public A withMatchLabels(java.util.Map matchLabels) { - if (matchLabels == null) { this.matchLabels = null;} else {this.matchLabels = new java.util.LinkedHashMap(matchLabels);} return (A) this; + + public A withMatchLabels(java.util.Map matchLabels) { + if (matchLabels == null) { + this.matchLabels = null; + } else { + this.matchLabels = new java.util.LinkedHashMap(matchLabels); + } + return (A) this; } + public java.lang.Boolean hasMatchLabels() { return this.matchLabels != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1LabelSelectorFluentImpl that = (V1LabelSelectorFluentImpl) o; - if (matchExpressions != null ? !matchExpressions.equals(that.matchExpressions) :that.matchExpressions != null) return false; - if (matchLabels != null ? !matchLabels.equals(that.matchLabels) :that.matchLabels != null) return false; + if (matchExpressions != null + ? !matchExpressions.equals(that.matchExpressions) + : that.matchExpressions != null) return false; + if (matchLabels != null ? !matchLabels.equals(that.matchLabels) : that.matchLabels != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(matchExpressions, matchLabels, super.hashCode()); + return java.util.Objects.hash(matchExpressions, matchLabels, super.hashCode()); } - public class MatchExpressionsNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluentImpl> implements io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested,io.kubernetes.client.fluent.Nested{ - MatchExpressionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item) { + + public class MatchExpressionsNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluentImpl< + io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested> + implements io.kubernetes.client.openapi.models.V1LabelSelectorFluent.MatchExpressionsNested< + N>, + io.kubernetes.client.fluent.Nested { + MatchExpressionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(this, item); } + MatchExpressionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1LabelSelectorFluentImpl.this.setToMatchExpressions(index,builder.build()); + return (N) V1LabelSelectorFluentImpl.this.setToMatchExpressions(index, builder.build()); } + public N endMatchExpression() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorRequirementBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorRequirementBuilder.java index 0a9238766d..1acb0ccb8b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorRequirementBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorRequirementBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LabelSelectorRequirementBuilder extends io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LabelSelectorRequirementBuilder + extends io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluentImpl< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement, + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementBuilder> { public V1LabelSelectorRequirementBuilder() { this(false); } + public V1LabelSelectorRequirementBuilder(java.lang.Boolean validationEnabled) { this(new V1LabelSelectorRequirement(), validationEnabled); } - public V1LabelSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent fluent) { + + public V1LabelSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent fluent) { this(fluent, false); } - public V1LabelSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LabelSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LabelSelectorRequirement(), validationEnabled); } - public V1LabelSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent fluent,io.kubernetes.client.openapi.models.V1LabelSelectorRequirement instance) { + + public V1LabelSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent fluent, + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement instance) { this(fluent, instance, false); } - public V1LabelSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent fluent,io.kubernetes.client.openapi.models.V1LabelSelectorRequirement instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LabelSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent fluent, + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withKey(instance.getKey()); fluent.withOperator(instance.getOperator()); fluent.withValues(instance.getValues()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1LabelSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1LabelSelectorRequirement instance) { - this(instance,false); + + public V1LabelSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement instance) { + this(instance, false); } - public V1LabelSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1LabelSelectorRequirement instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LabelSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withKey(instance.getKey()); this.withOperator(instance.getOperator()); this.withValues(instance.getValues()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement build() { V1LabelSelectorRequirement buildable = new V1LabelSelectorRequirement(); buildable.setKey(fluent.getKey()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1LabelSelectorRequirement build() { buildable.setValues(fluent.getValues()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LabelSelectorRequirementBuilder that = (V1LabelSelectorRequirementBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorRequirementFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorRequirementFluent.java index cf506cea6b..1cf59f619b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorRequirementFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorRequirementFluent.java @@ -1,53 +1,72 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1LabelSelectorRequirementFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1LabelSelectorRequirementFluent< + A extends io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getKey(); + public A withKey(java.lang.String key); + public java.lang.Boolean hasKey(); - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original); + public java.lang.String getOperator(); + public A withOperator(java.lang.String operator); + public java.lang.Boolean hasOperator(); - - /** - * Method is deprecated. use withOperator instead. - */ + + /** Method is deprecated. use withOperator instead. */ @java.lang.Deprecated public A withNewOperator(java.lang.String original); - public A addToValues(java.lang.Integer index,java.lang.String item); - public A setToValues(java.lang.Integer index,java.lang.String item); + + public A addToValues(java.lang.Integer index, java.lang.String item); + + public A setToValues(java.lang.Integer index, java.lang.String item); + public A addToValues(java.lang.String... items); + public A addAllToValues(java.util.Collection items); + public A removeFromValues(java.lang.String... items); + public A removeAllFromValues(java.util.Collection items); + public java.util.List getValues(); + public java.lang.String getValue(java.lang.Integer index); + public java.lang.String getFirstValue(); + public java.lang.String getLastValue(); - public java.lang.String getMatchingValue(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingValue(java.util.function.Predicate predicate); + + public java.lang.String getMatchingValue( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingValue( + java.util.function.Predicate predicate); + public A withValues(java.util.List values); + public A withValues(java.lang.String... values); + public java.lang.Boolean hasValues(); + public A addNewValue(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorRequirementFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorRequirementFluentImpl.java index 52face2a5e..6a700a5be4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorRequirementFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LabelSelectorRequirementFluentImpl.java @@ -1,132 +1,208 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1LabelSelectorRequirementFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent{ - public V1LabelSelectorRequirementFluentImpl() { - } - public V1LabelSelectorRequirementFluentImpl(io.kubernetes.client.openapi.models.V1LabelSelectorRequirement instance) { +/** Generated */ +public class V1LabelSelectorRequirementFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LabelSelectorRequirementFluent { + public V1LabelSelectorRequirementFluentImpl() {} + + public V1LabelSelectorRequirementFluentImpl( + io.kubernetes.client.openapi.models.V1LabelSelectorRequirement instance) { this.withKey(instance.getKey()); this.withOperator(instance.getOperator()); this.withValues(instance.getValues()); - } + private java.lang.String key; private java.lang.String operator; private java.util.List values; + public java.lang.String getKey() { return this.key; } + public A withKey(java.lang.String key) { - this.key=key; return (A) this; + this.key = key; + return (A) this; } + public java.lang.Boolean hasKey() { return this.key != null; } - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original) { - return (A)withKey(new String(original)); + return (A) withKey(new String(original)); } + public java.lang.String getOperator() { return this.operator; } + public A withOperator(java.lang.String operator) { - this.operator=operator; return (A) this; + this.operator = operator; + return (A) this; } + public java.lang.Boolean hasOperator() { return this.operator != null; } - - /** - * Method is deprecated. use withOperator instead. - */ + + /** Method is deprecated. use withOperator instead. */ @java.lang.Deprecated public A withNewOperator(java.lang.String original) { - return (A)withOperator(new String(original)); + return (A) withOperator(new String(original)); } - public A addToValues(java.lang.Integer index,java.lang.String item) { - if (this.values == null) {this.values = new java.util.ArrayList();} + + public A addToValues(java.lang.Integer index, java.lang.String item) { + if (this.values == null) { + this.values = new java.util.ArrayList(); + } this.values.add(index, item); - return (A)this; + return (A) this; } - public A setToValues(java.lang.Integer index,java.lang.String item) { - if (this.values == null) {this.values = new java.util.ArrayList();} - this.values.set(index, item); return (A)this; + + public A setToValues(java.lang.Integer index, java.lang.String item) { + if (this.values == null) { + this.values = new java.util.ArrayList(); + } + this.values.set(index, item); + return (A) this; } + public A addToValues(java.lang.String... items) { - if (this.values == null) {this.values = new java.util.ArrayList();} - for (java.lang.String item : items) {this.values.add(item);} return (A)this; + if (this.values == null) { + this.values = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.values.add(item); + } + return (A) this; } + public A addAllToValues(java.util.Collection items) { - if (this.values == null) {this.values = new java.util.ArrayList();} - for (java.lang.String item : items) {this.values.add(item);} return (A)this; + if (this.values == null) { + this.values = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.values.add(item); + } + return (A) this; } + public A removeFromValues(java.lang.String... items) { - for (java.lang.String item : items) {if (this.values!= null){ this.values.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.values != null) { + this.values.remove(item); + } + } + return (A) this; } + public A removeAllFromValues(java.util.Collection items) { - for (java.lang.String item : items) {if (this.values!= null){ this.values.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.values != null) { + this.values.remove(item); + } + } + return (A) this; } + public java.util.List getValues() { return this.values; } + public java.lang.String getValue(java.lang.Integer index) { return this.values.get(index); } + public java.lang.String getFirstValue() { return this.values.get(0); } + public java.lang.String getLastValue() { return this.values.get(values.size() - 1); } - public java.lang.String getMatchingValue(java.util.function.Predicate predicate) { - for (java.lang.String item: values) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingValue( + java.util.function.Predicate predicate) { + for (java.lang.String item : values) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingValue(java.util.function.Predicate predicate) { - for (java.lang.String item: values) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingValue( + java.util.function.Predicate predicate) { + for (java.lang.String item : values) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withValues(java.util.List values) { - if (values != null) {this.values = new java.util.ArrayList(); for (java.lang.String item : values){this.addToValues(item);}} else { this.values = null;} return (A) this; + if (values != null) { + this.values = new java.util.ArrayList(); + for (java.lang.String item : values) { + this.addToValues(item); + } + } else { + this.values = null; + } + return (A) this; } + public A withValues(java.lang.String... values) { - if (this.values != null) {this.values.clear();} - if (values != null) {for (java.lang.String item :values){ this.addToValues(item);}} return (A) this; + if (this.values != null) { + this.values.clear(); + } + if (values != null) { + for (java.lang.String item : values) { + this.addToValues(item); + } + } + return (A) this; } + public java.lang.Boolean hasValues() { return values != null && !values.isEmpty(); } + public A addNewValue(java.lang.String original) { - return (A)addToValues(new String(original)); + return (A) addToValues(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1LabelSelectorRequirementFluentImpl that = (V1LabelSelectorRequirementFluentImpl) o; - if (key != null ? !key.equals(that.key) :that.key != null) return false; - if (operator != null ? !operator.equals(that.operator) :that.operator != null) return false; - if (values != null ? !values.equals(that.values) :that.values != null) return false; + if (key != null ? !key.equals(that.key) : that.key != null) return false; + if (operator != null ? !operator.equals(that.operator) : that.operator != null) return false; + if (values != null ? !values.equals(that.values) : that.values != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(key, operator, values, super.hashCode()); + return java.util.Objects.hash(key, operator, values, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseBuilder.java index 1d85e4fb3a..8a8539d938 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LeaseBuilder extends io.kubernetes.client.openapi.models.V1LeaseFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LeaseBuilder + extends io.kubernetes.client.openapi.models.V1LeaseFluentImpl< + io.kubernetes.client.openapi.models.V1LeaseBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Lease, + io.kubernetes.client.openapi.models.V1LeaseBuilder> { public V1LeaseBuilder() { this(false); } + public V1LeaseBuilder(java.lang.Boolean validationEnabled) { this(new V1Lease(), validationEnabled); } + public V1LeaseBuilder(io.kubernetes.client.openapi.models.V1LeaseFluent fluent) { this(fluent, false); } - public V1LeaseBuilder(io.kubernetes.client.openapi.models.V1LeaseFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LeaseBuilder( + io.kubernetes.client.openapi.models.V1LeaseFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Lease(), validationEnabled); } - public V1LeaseBuilder(io.kubernetes.client.openapi.models.V1LeaseFluent fluent,io.kubernetes.client.openapi.models.V1Lease instance) { + + public V1LeaseBuilder( + io.kubernetes.client.openapi.models.V1LeaseFluent fluent, + io.kubernetes.client.openapi.models.V1Lease instance) { this(fluent, instance, false); } - public V1LeaseBuilder(io.kubernetes.client.openapi.models.V1LeaseFluent fluent,io.kubernetes.client.openapi.models.V1Lease instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LeaseBuilder( + io.kubernetes.client.openapi.models.V1LeaseFluent fluent, + io.kubernetes.client.openapi.models.V1Lease instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +55,16 @@ public V1LeaseBuilder(io.kubernetes.client.openapi.models.V1LeaseFluent fluen fluent.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1LeaseBuilder(io.kubernetes.client.openapi.models.V1Lease instance) { - this(instance,false); + this(instance, false); } - public V1LeaseBuilder(io.kubernetes.client.openapi.models.V1Lease instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LeaseBuilder( + io.kubernetes.client.openapi.models.V1Lease instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +73,12 @@ public V1LeaseBuilder(io.kubernetes.client.openapi.models.V1Lease instance,java. this.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LeaseFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Lease build() { V1Lease buildable = new V1Lease(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +87,23 @@ public io.kubernetes.client.openapi.models.V1Lease build() { buildable.setSpec(fluent.getSpec()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LeaseBuilder that = (V1LeaseBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseFluent.java index 6ca768c263..b4d2b6244e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseFluent.java @@ -1,73 +1,107 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1LeaseFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1LeaseFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LeaseSpec getSpec(); + public io.kubernetes.client.openapi.models.V1LeaseSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1LeaseSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1LeaseSpec item); + + public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1LeaseSpec item); + public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1LeaseSpec item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1LeaseSpec item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LeaseSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LeaseSpecFluent< + io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested> { public N and(); + public N endSpec(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseFluentImpl.java index 45aefd0a6f..8b761e23b4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1LeaseFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LeaseFluent { + public V1LeaseFluentImpl() {} - /** - * Generated - */ -public class V1LeaseFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LeaseFluent{ - public V1LeaseFluentImpl() { - } public V1LeaseFluentImpl(io.kubernetes.client.openapi.models.V1Lease instance) { this.withApiVersion(instance.getApiVersion()); @@ -21,158 +26,216 @@ public V1LeaseFluentImpl(io.kubernetes.client.openapi.models.V1Lease instance) { this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1LeaseSpecBuilder spec; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1LeaseFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1LeaseFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LeaseSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1LeaseSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1LeaseSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1LeaseSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1LeaseSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1LeaseFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1LeaseSpec item) { + + public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1LeaseSpec item) { return new io.kubernetes.client.openapi.models.V1LeaseFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1LeaseSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1LeaseSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1LeaseSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1LeaseSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1LeaseFluentImpl that = (V1LeaseFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1LeaseFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1LeaseFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1LeaseSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1LeaseSpecFluentImpl< + io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1LeaseFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1LeaseSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1LeaseSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LeaseSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1LeaseSpecBuilder builder; + public N and() { return (N) V1LeaseFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseListBuilder.java index 48efb6c387..546a03c55e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseListBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LeaseListBuilder extends io.kubernetes.client.openapi.models.V1LeaseListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LeaseListBuilder + extends io.kubernetes.client.openapi.models.V1LeaseListFluentImpl< + io.kubernetes.client.openapi.models.V1LeaseListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LeaseList, + io.kubernetes.client.openapi.models.V1LeaseListBuilder> { public V1LeaseListBuilder() { this(false); } + public V1LeaseListBuilder(java.lang.Boolean validationEnabled) { this(new V1LeaseList(), validationEnabled); } + public V1LeaseListBuilder(io.kubernetes.client.openapi.models.V1LeaseListFluent fluent) { this(fluent, false); } - public V1LeaseListBuilder(io.kubernetes.client.openapi.models.V1LeaseListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LeaseListBuilder( + io.kubernetes.client.openapi.models.V1LeaseListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LeaseList(), validationEnabled); } - public V1LeaseListBuilder(io.kubernetes.client.openapi.models.V1LeaseListFluent fluent,io.kubernetes.client.openapi.models.V1LeaseList instance) { + + public V1LeaseListBuilder( + io.kubernetes.client.openapi.models.V1LeaseListFluent fluent, + io.kubernetes.client.openapi.models.V1LeaseList instance) { this(fluent, instance, false); } - public V1LeaseListBuilder(io.kubernetes.client.openapi.models.V1LeaseListFluent fluent,io.kubernetes.client.openapi.models.V1LeaseList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LeaseListBuilder( + io.kubernetes.client.openapi.models.V1LeaseListFluent fluent, + io.kubernetes.client.openapi.models.V1LeaseList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +55,17 @@ public V1LeaseListBuilder(io.kubernetes.client.openapi.models.V1LeaseListFluent< fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1LeaseListBuilder(io.kubernetes.client.openapi.models.V1LeaseList instance) { - this(instance,false); + this(instance, false); } - public V1LeaseListBuilder(io.kubernetes.client.openapi.models.V1LeaseList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LeaseListBuilder( + io.kubernetes.client.openapi.models.V1LeaseList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +74,12 @@ public V1LeaseListBuilder(io.kubernetes.client.openapi.models.V1LeaseList instan this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LeaseListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LeaseList build() { V1LeaseList buildable = new V1LeaseList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1LeaseList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LeaseListBuilder that = (V1LeaseListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseListFluent.java index e58949c8c4..c23f4b4e7a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseListFluent.java @@ -1,95 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1LeaseListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1LeaseListFluent< + A extends io.kubernetes.client.openapi.models.V1LeaseListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Lease item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Lease item); + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Lease item); + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Lease item); + public A addToItems(io.kubernetes.client.openapi.models.V1Lease... items); + public A addAllToItems(java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1Lease... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1Lease buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Lease buildFirstItem(); + public io.kubernetes.client.openapi.models.V1Lease buildLastItem(); - public io.kubernetes.client.openapi.models.V1Lease buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Lease buildMatchingItem( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1Lease... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Lease item); - public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Lease item); - public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Lease item); + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Lease item); + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LeaseFluent>{ + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LeaseFluent< + io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseListFluentImpl.java index 658a9c6e7b..b8c4dc8903 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1LeaseListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LeaseListFluent{ - public V1LeaseListFluentImpl() { - } +/** Generated */ +public class V1LeaseListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LeaseListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LeaseListFluent { + public V1LeaseListFluentImpl() {} + public V1LeaseListFluentImpl(io.kubernetes.client.openapi.models.V1LeaseList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,115 @@ public V1LeaseListFluentImpl(io.kubernetes.client.openapi.models.V1LeaseList ins this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Lease item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LeaseBuilder builder = new io.kubernetes.client.openapi.models.V1LeaseBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Lease item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1LeaseBuilder builder = + new io.kubernetes.client.openapi.models.V1LeaseBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Lease item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LeaseBuilder builder = new io.kubernetes.client.openapi.models.V1LeaseBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Lease item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1LeaseBuilder builder = + new io.kubernetes.client.openapi.models.V1LeaseBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1Lease... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Lease item : items) {io.kubernetes.client.openapi.models.V1LeaseBuilder builder = new io.kubernetes.client.openapi.models.V1LeaseBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Lease item : items) { + io.kubernetes.client.openapi.models.V1LeaseBuilder builder = + new io.kubernetes.client.openapi.models.V1LeaseBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Lease item : items) {io.kubernetes.client.openapi.models.V1LeaseBuilder builder = new io.kubernetes.client.openapi.models.V1LeaseBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Lease item : items) { + io.kubernetes.client.openapi.models.V1LeaseBuilder builder = + new io.kubernetes.client.openapi.models.V1LeaseBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1Lease... items) { - for (io.kubernetes.client.openapi.models.V1Lease item : items) {io.kubernetes.client.openapi.models.V1LeaseBuilder builder = new io.kubernetes.client.openapi.models.V1LeaseBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Lease item : items) { + io.kubernetes.client.openapi.models.V1LeaseBuilder builder = + new io.kubernetes.client.openapi.models.V1LeaseBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Lease item : items) {io.kubernetes.client.openapi.models.V1LeaseBuilder builder = new io.kubernetes.client.openapi.models.V1LeaseBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Lease item : items) { + io.kubernetes.client.openapi.models.V1LeaseBuilder builder = + new io.kubernetes.client.openapi.models.V1LeaseBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +149,267 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1Lease buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Lease buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Lease buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Lease buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LeaseBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Lease buildMatchingItem( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1LeaseBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LeaseBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1LeaseBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Lease item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Lease item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1Lease... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1Lease item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1Lease item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1LeaseListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Lease item) { + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Lease item) { return new io.kubernetes.client.openapi.models.V1LeaseListFluentImpl.ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Lease item) { - return new io.kubernetes.client.openapi.models.V1LeaseListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Lease item) { + return new io.kubernetes.client.openapi.models.V1LeaseListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate) { int index = -1; - for (int i=0;i withNewMetadata() { return new io.kubernetes.client.openapi.models.V1LeaseListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { return new io.kubernetes.client.openapi.models.V1LeaseListFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1LeaseListFluentImpl that = (V1LeaseListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1LeaseFluentImpl> implements io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Lease item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1LeaseFluentImpl< + io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1LeaseListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Lease item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1LeaseBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1LeaseBuilder(this); } + io.kubernetes.client.openapi.models.V1LeaseBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1LeaseListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1LeaseListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1LeaseListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1LeaseListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseSpecBuilder.java index ac07dd6100..a428eeeb94 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseSpecBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LeaseSpecBuilder extends io.kubernetes.client.openapi.models.V1LeaseSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LeaseSpecBuilder + extends io.kubernetes.client.openapi.models.V1LeaseSpecFluentImpl< + io.kubernetes.client.openapi.models.V1LeaseSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LeaseSpec, + io.kubernetes.client.openapi.models.V1LeaseSpecBuilder> { public V1LeaseSpecBuilder() { this(false); } + public V1LeaseSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1LeaseSpec(), validationEnabled); } + public V1LeaseSpecBuilder(io.kubernetes.client.openapi.models.V1LeaseSpecFluent fluent) { this(fluent, false); } - public V1LeaseSpecBuilder(io.kubernetes.client.openapi.models.V1LeaseSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LeaseSpecBuilder( + io.kubernetes.client.openapi.models.V1LeaseSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LeaseSpec(), validationEnabled); } - public V1LeaseSpecBuilder(io.kubernetes.client.openapi.models.V1LeaseSpecFluent fluent,io.kubernetes.client.openapi.models.V1LeaseSpec instance) { + + public V1LeaseSpecBuilder( + io.kubernetes.client.openapi.models.V1LeaseSpecFluent fluent, + io.kubernetes.client.openapi.models.V1LeaseSpec instance) { this(fluent, instance, false); } - public V1LeaseSpecBuilder(io.kubernetes.client.openapi.models.V1LeaseSpecFluent fluent,io.kubernetes.client.openapi.models.V1LeaseSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LeaseSpecBuilder( + io.kubernetes.client.openapi.models.V1LeaseSpecFluent fluent, + io.kubernetes.client.openapi.models.V1LeaseSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAcquireTime(instance.getAcquireTime()); fluent.withHolderIdentity(instance.getHolderIdentity()); @@ -31,13 +57,17 @@ public V1LeaseSpecBuilder(io.kubernetes.client.openapi.models.V1LeaseSpecFluent< fluent.withRenewTime(instance.getRenewTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1LeaseSpecBuilder(io.kubernetes.client.openapi.models.V1LeaseSpec instance) { - this(instance,false); + this(instance, false); } - public V1LeaseSpecBuilder(io.kubernetes.client.openapi.models.V1LeaseSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LeaseSpecBuilder( + io.kubernetes.client.openapi.models.V1LeaseSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAcquireTime(instance.getAcquireTime()); this.withHolderIdentity(instance.getHolderIdentity()); @@ -48,10 +78,12 @@ public V1LeaseSpecBuilder(io.kubernetes.client.openapi.models.V1LeaseSpec instan this.withRenewTime(instance.getRenewTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LeaseSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LeaseSpec build() { V1LeaseSpec buildable = new V1LeaseSpec(); buildable.setAcquireTime(fluent.getAcquireTime()); @@ -61,18 +93,23 @@ public io.kubernetes.client.openapi.models.V1LeaseSpec build() { buildable.setRenewTime(fluent.getRenewTime()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LeaseSpecBuilder that = (V1LeaseSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseSpecFluent.java index 5e56421ad1..8ee4455662 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseSpecFluent.java @@ -1,37 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1LeaseSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1LeaseSpecFluent< + A extends io.kubernetes.client.openapi.models.V1LeaseSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getAcquireTime(); + public A withAcquireTime(java.time.OffsetDateTime acquireTime); + public java.lang.Boolean hasAcquireTime(); + public java.lang.String getHolderIdentity(); + public A withHolderIdentity(java.lang.String holderIdentity); + public java.lang.Boolean hasHolderIdentity(); - - /** - * Method is deprecated. use withHolderIdentity instead. - */ + + /** Method is deprecated. use withHolderIdentity instead. */ @java.lang.Deprecated public A withNewHolderIdentity(java.lang.String original); + public java.lang.Integer getLeaseDurationSeconds(); + public A withLeaseDurationSeconds(java.lang.Integer leaseDurationSeconds); + public java.lang.Boolean hasLeaseDurationSeconds(); + public java.lang.Integer getLeaseTransitions(); + public A withLeaseTransitions(java.lang.Integer leaseTransitions); + public java.lang.Boolean hasLeaseTransitions(); + public java.time.OffsetDateTime getRenewTime(); + public A withRenewTime(java.time.OffsetDateTime renewTime); + public java.lang.Boolean hasRenewTime(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseSpecFluentImpl.java index 508113d76e..f45d0188c4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LeaseSpecFluentImpl.java @@ -1,19 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1LeaseSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LeaseSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LeaseSpecFluent { + public V1LeaseSpecFluentImpl() {} - /** - * Generated - */ -public class V1LeaseSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LeaseSpecFluent{ - public V1LeaseSpecFluentImpl() { - } public V1LeaseSpecFluentImpl(io.kubernetes.client.openapi.models.V1LeaseSpec instance) { this.withAcquireTime(instance.getAcquireTime()); @@ -24,79 +29,112 @@ public V1LeaseSpecFluentImpl(io.kubernetes.client.openapi.models.V1LeaseSpec ins this.withLeaseTransitions(instance.getLeaseTransitions()); this.withRenewTime(instance.getRenewTime()); - } + private java.time.OffsetDateTime acquireTime; private java.lang.String holderIdentity; private java.lang.Integer leaseDurationSeconds; private java.lang.Integer leaseTransitions; private java.time.OffsetDateTime renewTime; + public java.time.OffsetDateTime getAcquireTime() { return this.acquireTime; } + public A withAcquireTime(java.time.OffsetDateTime acquireTime) { - this.acquireTime=acquireTime; return (A) this; + this.acquireTime = acquireTime; + return (A) this; } + public java.lang.Boolean hasAcquireTime() { return this.acquireTime != null; } + public java.lang.String getHolderIdentity() { return this.holderIdentity; } + public A withHolderIdentity(java.lang.String holderIdentity) { - this.holderIdentity=holderIdentity; return (A) this; + this.holderIdentity = holderIdentity; + return (A) this; } + public java.lang.Boolean hasHolderIdentity() { return this.holderIdentity != null; } - - /** - * Method is deprecated. use withHolderIdentity instead. - */ + + /** Method is deprecated. use withHolderIdentity instead. */ @java.lang.Deprecated public A withNewHolderIdentity(java.lang.String original) { - return (A)withHolderIdentity(new String(original)); + return (A) withHolderIdentity(new String(original)); } + public java.lang.Integer getLeaseDurationSeconds() { return this.leaseDurationSeconds; } + public A withLeaseDurationSeconds(java.lang.Integer leaseDurationSeconds) { - this.leaseDurationSeconds=leaseDurationSeconds; return (A) this; + this.leaseDurationSeconds = leaseDurationSeconds; + return (A) this; } + public java.lang.Boolean hasLeaseDurationSeconds() { return this.leaseDurationSeconds != null; } + public java.lang.Integer getLeaseTransitions() { return this.leaseTransitions; } + public A withLeaseTransitions(java.lang.Integer leaseTransitions) { - this.leaseTransitions=leaseTransitions; return (A) this; + this.leaseTransitions = leaseTransitions; + return (A) this; } + public java.lang.Boolean hasLeaseTransitions() { return this.leaseTransitions != null; } + public java.time.OffsetDateTime getRenewTime() { return this.renewTime; } + public A withRenewTime(java.time.OffsetDateTime renewTime) { - this.renewTime=renewTime; return (A) this; + this.renewTime = renewTime; + return (A) this; } + public java.lang.Boolean hasRenewTime() { return this.renewTime != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1LeaseSpecFluentImpl that = (V1LeaseSpecFluentImpl) o; - if (acquireTime != null ? !acquireTime.equals(that.acquireTime) :that.acquireTime != null) return false; - if (holderIdentity != null ? !holderIdentity.equals(that.holderIdentity) :that.holderIdentity != null) return false; - if (leaseDurationSeconds != null ? !leaseDurationSeconds.equals(that.leaseDurationSeconds) :that.leaseDurationSeconds != null) return false; - if (leaseTransitions != null ? !leaseTransitions.equals(that.leaseTransitions) :that.leaseTransitions != null) return false; - if (renewTime != null ? !renewTime.equals(that.renewTime) :that.renewTime != null) return false; + if (acquireTime != null ? !acquireTime.equals(that.acquireTime) : that.acquireTime != null) + return false; + if (holderIdentity != null + ? !holderIdentity.equals(that.holderIdentity) + : that.holderIdentity != null) return false; + if (leaseDurationSeconds != null + ? !leaseDurationSeconds.equals(that.leaseDurationSeconds) + : that.leaseDurationSeconds != null) return false; + if (leaseTransitions != null + ? !leaseTransitions.equals(that.leaseTransitions) + : that.leaseTransitions != null) return false; + if (renewTime != null ? !renewTime.equals(that.renewTime) : that.renewTime != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(acquireTime, holderIdentity, leaseDurationSeconds, leaseTransitions, renewTime, super.hashCode()); - } - -} \ No newline at end of file + return java.util.Objects.hash( + acquireTime, + holderIdentity, + leaseDurationSeconds, + leaseTransitions, + renewTime, + super.hashCode()); + } +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleBuilder.java index 3bbe94d0e4..775525dd48 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LifecycleBuilder extends io.kubernetes.client.openapi.models.V1LifecycleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LifecycleBuilder + extends io.kubernetes.client.openapi.models.V1LifecycleFluentImpl< + io.kubernetes.client.openapi.models.V1LifecycleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Lifecycle, + io.kubernetes.client.openapi.models.V1LifecycleBuilder> { public V1LifecycleBuilder() { this(false); } + public V1LifecycleBuilder(java.lang.Boolean validationEnabled) { this(new V1Lifecycle(), validationEnabled); } + public V1LifecycleBuilder(io.kubernetes.client.openapi.models.V1LifecycleFluent fluent) { this(fluent, false); } - public V1LifecycleBuilder(io.kubernetes.client.openapi.models.V1LifecycleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LifecycleBuilder( + io.kubernetes.client.openapi.models.V1LifecycleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Lifecycle(), validationEnabled); } - public V1LifecycleBuilder(io.kubernetes.client.openapi.models.V1LifecycleFluent fluent,io.kubernetes.client.openapi.models.V1Lifecycle instance) { + + public V1LifecycleBuilder( + io.kubernetes.client.openapi.models.V1LifecycleFluent fluent, + io.kubernetes.client.openapi.models.V1Lifecycle instance) { this(fluent, instance, false); } - public V1LifecycleBuilder(io.kubernetes.client.openapi.models.V1LifecycleFluent fluent,io.kubernetes.client.openapi.models.V1Lifecycle instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LifecycleBuilder( + io.kubernetes.client.openapi.models.V1LifecycleFluent fluent, + io.kubernetes.client.openapi.models.V1Lifecycle instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPostStart(instance.getPostStart()); fluent.withPreStop(instance.getPreStop()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1LifecycleBuilder(io.kubernetes.client.openapi.models.V1Lifecycle instance) { - this(instance,false); + this(instance, false); } - public V1LifecycleBuilder(io.kubernetes.client.openapi.models.V1Lifecycle instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LifecycleBuilder( + io.kubernetes.client.openapi.models.V1Lifecycle instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPostStart(instance.getPostStart()); this.withPreStop(instance.getPreStop()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LifecycleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Lifecycle build() { V1Lifecycle buildable = new V1Lifecycle(); buildable.setPostStart(fluent.getPostStart()); buildable.setPreStop(fluent.getPreStop()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LifecycleBuilder that = (V1LifecycleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleFluent.java index bfae6383b6..6e62f54987 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleFluent.java @@ -1,55 +1,91 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1LifecycleFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1LifecycleFluent< + A extends io.kubernetes.client.openapi.models.V1LifecycleFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildPostStart instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LifecycleHandler getPostStart(); + public io.kubernetes.client.openapi.models.V1LifecycleHandler buildPostStart(); + public A withPostStart(io.kubernetes.client.openapi.models.V1LifecycleHandler postStart); + public java.lang.Boolean hasPostStart(); - public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested withNewPostStart(); - public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested withNewPostStartLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item); + + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested + withNewPostStart(); + + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested + withNewPostStartLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item); + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested editPostStart(); - public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested editOrNewPostStart(); - public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested editOrNewPostStartLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item); - + + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested + editOrNewPostStart(); + + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested + editOrNewPostStartLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item); + /** * This method has been deprecated, please use method buildPreStop instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LifecycleHandler getPreStop(); + public io.kubernetes.client.openapi.models.V1LifecycleHandler buildPreStop(); + public A withPreStop(io.kubernetes.client.openapi.models.V1LifecycleHandler preStop); + public java.lang.Boolean hasPreStop(); + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested withNewPreStop(); - public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested withNewPreStopLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item); + + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested withNewPreStopLike( + io.kubernetes.client.openapi.models.V1LifecycleHandler item); + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested editPreStop(); + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested editOrNewPreStop(); - public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested editOrNewPreStopLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item); - public interface PostStartNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent>{ + + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested + editOrNewPreStopLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item); + + public interface PostStartNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent< + io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested> { public N and(); + public N endPostStart(); - } - public interface PreStopNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent>{ + + public interface PreStopNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent< + io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested> { public N and(); + public N endPreStop(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleFluentImpl.java index 9179884399..ba886d9531 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleFluentImpl.java @@ -1,135 +1,198 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1LifecycleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LifecycleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LifecycleFluent { + public V1LifecycleFluentImpl() {} - /** - * Generated - */ -public class V1LifecycleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LifecycleFluent{ - public V1LifecycleFluentImpl() { - } public V1LifecycleFluentImpl(io.kubernetes.client.openapi.models.V1Lifecycle instance) { this.withPostStart(instance.getPostStart()); this.withPreStop(instance.getPreStop()); - } + private io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder postStart; private io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder preStop; - + /** * This method has been deprecated, please use method buildPostStart instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LifecycleHandler getPostStart() { - return this.postStart!=null ?this.postStart.build():null; + return this.postStart != null ? this.postStart.build() : null; } + public io.kubernetes.client.openapi.models.V1LifecycleHandler buildPostStart() { - return this.postStart!=null ?this.postStart.build():null; + return this.postStart != null ? this.postStart.build() : null; } + public A withPostStart(io.kubernetes.client.openapi.models.V1LifecycleHandler postStart) { _visitables.get("postStart").remove(this.postStart); - if (postStart!=null){ this.postStart= new io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder(postStart); _visitables.get("postStart").add(this.postStart);} return (A) this; + if (postStart != null) { + this.postStart = new io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder(postStart); + _visitables.get("postStart").add(this.postStart); + } + return (A) this; } + public java.lang.Boolean hasPostStart() { return this.postStart != null; } - public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested withNewPostStart() { + + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested + withNewPostStart() { return new io.kubernetes.client.openapi.models.V1LifecycleFluentImpl.PostStartNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested withNewPostStartLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item) { + + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested + withNewPostStartLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item) { return new io.kubernetes.client.openapi.models.V1LifecycleFluentImpl.PostStartNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested editPostStart() { return withNewPostStartLike(getPostStart()); } - public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested editOrNewPostStart() { - return withNewPostStartLike(getPostStart() != null ? getPostStart(): new io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder().build()); + + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested + editOrNewPostStart() { + return withNewPostStartLike( + getPostStart() != null + ? getPostStart() + : new io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested editOrNewPostStartLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item) { - return withNewPostStartLike(getPostStart() != null ? getPostStart(): item); + + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested + editOrNewPostStartLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item) { + return withNewPostStartLike(getPostStart() != null ? getPostStart() : item); } - + /** * This method has been deprecated, please use method buildPreStop instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LifecycleHandler getPreStop() { - return this.preStop!=null ?this.preStop.build():null; + return this.preStop != null ? this.preStop.build() : null; } + public io.kubernetes.client.openapi.models.V1LifecycleHandler buildPreStop() { - return this.preStop!=null ?this.preStop.build():null; + return this.preStop != null ? this.preStop.build() : null; } + public A withPreStop(io.kubernetes.client.openapi.models.V1LifecycleHandler preStop) { _visitables.get("preStop").remove(this.preStop); - if (preStop!=null){ this.preStop= new io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder(preStop); _visitables.get("preStop").add(this.preStop);} return (A) this; + if (preStop != null) { + this.preStop = new io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder(preStop); + _visitables.get("preStop").add(this.preStop); + } + return (A) this; } + public java.lang.Boolean hasPreStop() { return this.preStop != null; } + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested withNewPreStop() { return new io.kubernetes.client.openapi.models.V1LifecycleFluentImpl.PreStopNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested withNewPreStopLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item) { + + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested withNewPreStopLike( + io.kubernetes.client.openapi.models.V1LifecycleHandler item) { return new io.kubernetes.client.openapi.models.V1LifecycleFluentImpl.PreStopNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested editPreStop() { return withNewPreStopLike(getPreStop()); } + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested editOrNewPreStop() { - return withNewPreStopLike(getPreStop() != null ? getPreStop(): new io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder().build()); + return withNewPreStopLike( + getPreStop() != null + ? getPreStop() + : new io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested editOrNewPreStopLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item) { - return withNewPreStopLike(getPreStop() != null ? getPreStop(): item); + + public io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested + editOrNewPreStopLike(io.kubernetes.client.openapi.models.V1LifecycleHandler item) { + return withNewPreStopLike(getPreStop() != null ? getPreStop() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1LifecycleFluentImpl that = (V1LifecycleFluentImpl) o; - if (postStart != null ? !postStart.equals(that.postStart) :that.postStart != null) return false; - if (preStop != null ? !preStop.equals(that.preStop) :that.preStop != null) return false; + if (postStart != null ? !postStart.equals(that.postStart) : that.postStart != null) + return false; + if (preStop != null ? !preStop.equals(that.preStop) : that.preStop != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(postStart, preStop, super.hashCode()); + return java.util.Objects.hash(postStart, preStop, super.hashCode()); } - public class PostStartNestedImpl extends io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl> implements io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested,io.kubernetes.client.fluent.Nested{ + + public class PostStartNestedImpl + extends io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl< + io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested> + implements io.kubernetes.client.openapi.models.V1LifecycleFluent.PostStartNested, + io.kubernetes.client.fluent.Nested { PostStartNestedImpl(io.kubernetes.client.openapi.models.V1LifecycleHandler item) { this.builder = new io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder(this, item); } + PostStartNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder(this); } + io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder builder; + public N and() { return (N) V1LifecycleFluentImpl.this.withPostStart(builder.build()); } + public N endPostStart() { return and(); } - } - public class PreStopNestedImpl extends io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl> implements io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested,io.kubernetes.client.fluent.Nested{ + + public class PreStopNestedImpl + extends io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl< + io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested> + implements io.kubernetes.client.openapi.models.V1LifecycleFluent.PreStopNested, + io.kubernetes.client.fluent.Nested { PreStopNestedImpl(io.kubernetes.client.openapi.models.V1LifecycleHandler item) { this.builder = new io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder(this, item); } + PreStopNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder(this); } + io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder builder; + public N and() { return (N) V1LifecycleFluentImpl.this.withPreStop(builder.build()); } + public N endPreStop() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleHandlerBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleHandlerBuilder.java index 841b795453..4ecc31faf0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleHandlerBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleHandlerBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LifecycleHandlerBuilder extends io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LifecycleHandlerBuilder + extends io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl< + io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LifecycleHandler, + io.kubernetes.client.openapi.models.V1LifecycleHandlerBuilder> { public V1LifecycleHandlerBuilder() { this(false); } + public V1LifecycleHandlerBuilder(java.lang.Boolean validationEnabled) { this(new V1LifecycleHandler(), validationEnabled); } - public V1LifecycleHandlerBuilder(io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent fluent) { + + public V1LifecycleHandlerBuilder( + io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent fluent) { this(fluent, false); } - public V1LifecycleHandlerBuilder(io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LifecycleHandlerBuilder( + io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LifecycleHandler(), validationEnabled); } - public V1LifecycleHandlerBuilder(io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent fluent,io.kubernetes.client.openapi.models.V1LifecycleHandler instance) { + + public V1LifecycleHandlerBuilder( + io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent fluent, + io.kubernetes.client.openapi.models.V1LifecycleHandler instance) { this(fluent, instance, false); } - public V1LifecycleHandlerBuilder(io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent fluent,io.kubernetes.client.openapi.models.V1LifecycleHandler instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LifecycleHandlerBuilder( + io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent fluent, + io.kubernetes.client.openapi.models.V1LifecycleHandler instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withExec(instance.getExec()); fluent.withHttpGet(instance.getHttpGet()); fluent.withTcpSocket(instance.getTcpSocket()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1LifecycleHandlerBuilder(io.kubernetes.client.openapi.models.V1LifecycleHandler instance) { - this(instance,false); + + public V1LifecycleHandlerBuilder( + io.kubernetes.client.openapi.models.V1LifecycleHandler instance) { + this(instance, false); } - public V1LifecycleHandlerBuilder(io.kubernetes.client.openapi.models.V1LifecycleHandler instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LifecycleHandlerBuilder( + io.kubernetes.client.openapi.models.V1LifecycleHandler instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withExec(instance.getExec()); this.withHttpGet(instance.getHttpGet()); this.withTcpSocket(instance.getTcpSocket()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LifecycleHandler build() { V1LifecycleHandler buildable = new V1LifecycleHandler(); buildable.setExec(fluent.getExec()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1LifecycleHandler build() { buildable.setTcpSocket(fluent.getTcpSocket()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LifecycleHandlerBuilder that = (V1LifecycleHandlerBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleHandlerFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleHandlerFluent.java index d83c546932..33286f4e90 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleHandlerFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleHandlerFluent.java @@ -1,75 +1,130 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1LifecycleHandlerFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1LifecycleHandlerFluent< + A extends io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildExec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ExecAction getExec(); + public io.kubernetes.client.openapi.models.V1ExecAction buildExec(); + public A withExec(io.kubernetes.client.openapi.models.V1ExecAction exec); + public java.lang.Boolean hasExec(); + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested withNewExec(); - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested withNewExecLike(io.kubernetes.client.openapi.models.V1ExecAction item); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested withNewExecLike( + io.kubernetes.client.openapi.models.V1ExecAction item); + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested editExec(); + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested editOrNewExec(); - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested editOrNewExecLike(io.kubernetes.client.openapi.models.V1ExecAction item); - + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested + editOrNewExecLike(io.kubernetes.client.openapi.models.V1ExecAction item); + /** * This method has been deprecated, please use method buildHttpGet instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HTTPGetAction getHttpGet(); + public io.kubernetes.client.openapi.models.V1HTTPGetAction buildHttpGet(); + public A withHttpGet(io.kubernetes.client.openapi.models.V1HTTPGetAction httpGet); + public java.lang.Boolean hasHttpGet(); - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested withNewHttpGet(); - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested withNewHttpGetLike(io.kubernetes.client.openapi.models.V1HTTPGetAction item); - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested editHttpGet(); - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested editOrNewHttpGet(); - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested editOrNewHttpGetLike(io.kubernetes.client.openapi.models.V1HTTPGetAction item); - + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested + withNewHttpGet(); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested + withNewHttpGetLike(io.kubernetes.client.openapi.models.V1HTTPGetAction item); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested + editHttpGet(); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested + editOrNewHttpGet(); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested + editOrNewHttpGetLike(io.kubernetes.client.openapi.models.V1HTTPGetAction item); + /** * This method has been deprecated, please use method buildTcpSocket instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TCPSocketAction getTcpSocket(); + public io.kubernetes.client.openapi.models.V1TCPSocketAction buildTcpSocket(); + public A withTcpSocket(io.kubernetes.client.openapi.models.V1TCPSocketAction tcpSocket); + public java.lang.Boolean hasTcpSocket(); - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested withNewTcpSocket(); - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested withNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item); - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested editTcpSocket(); - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested editOrNewTcpSocket(); - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested editOrNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item); - public interface ExecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ExecActionFluent>{ + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested + withNewTcpSocket(); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested + withNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested + editTcpSocket(); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested + editOrNewTcpSocket(); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested + editOrNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item); + + public interface ExecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ExecActionFluent< + io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested> { public N and(); + public N endExec(); - } - public interface HttpGetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1HTTPGetActionFluent>{ + + public interface HttpGetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1HTTPGetActionFluent< + io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested> { public N and(); + public N endHttpGet(); - } - public interface TcpSocketNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TCPSocketActionFluent>{ + + public interface TcpSocketNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TCPSocketActionFluent< + io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested> { public N and(); + public N endTcpSocket(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleHandlerFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleHandlerFluentImpl.java index ad72bb81b5..ea041954a0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleHandlerFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LifecycleHandlerFluentImpl.java @@ -1,189 +1,288 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1LifecycleHandlerFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent { + public V1LifecycleHandlerFluentImpl() {} - /** - * Generated - */ -public class V1LifecycleHandlerFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent{ - public V1LifecycleHandlerFluentImpl() { - } - public V1LifecycleHandlerFluentImpl(io.kubernetes.client.openapi.models.V1LifecycleHandler instance) { + public V1LifecycleHandlerFluentImpl( + io.kubernetes.client.openapi.models.V1LifecycleHandler instance) { this.withExec(instance.getExec()); this.withHttpGet(instance.getHttpGet()); this.withTcpSocket(instance.getTcpSocket()); - } + private io.kubernetes.client.openapi.models.V1ExecActionBuilder exec; private io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder httpGet; private io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder tcpSocket; - + /** * This method has been deprecated, please use method buildExec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ExecAction getExec() { - return this.exec!=null ?this.exec.build():null; + return this.exec != null ? this.exec.build() : null; } + public io.kubernetes.client.openapi.models.V1ExecAction buildExec() { - return this.exec!=null ?this.exec.build():null; + return this.exec != null ? this.exec.build() : null; } + public A withExec(io.kubernetes.client.openapi.models.V1ExecAction exec) { _visitables.get("exec").remove(this.exec); - if (exec!=null){ this.exec= new io.kubernetes.client.openapi.models.V1ExecActionBuilder(exec); _visitables.get("exec").add(this.exec);} return (A) this; + if (exec != null) { + this.exec = new io.kubernetes.client.openapi.models.V1ExecActionBuilder(exec); + _visitables.get("exec").add(this.exec); + } + return (A) this; } + public java.lang.Boolean hasExec() { return this.exec != null; } + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested withNewExec() { return new io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl.ExecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested withNewExecLike(io.kubernetes.client.openapi.models.V1ExecAction item) { - return new io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl.ExecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested withNewExecLike( + io.kubernetes.client.openapi.models.V1ExecAction item) { + return new io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl.ExecNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested editExec() { return withNewExecLike(getExec()); } - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested editOrNewExec() { - return withNewExecLike(getExec() != null ? getExec(): new io.kubernetes.client.openapi.models.V1ExecActionBuilder().build()); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested + editOrNewExec() { + return withNewExecLike( + getExec() != null + ? getExec() + : new io.kubernetes.client.openapi.models.V1ExecActionBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested editOrNewExecLike(io.kubernetes.client.openapi.models.V1ExecAction item) { - return withNewExecLike(getExec() != null ? getExec(): item); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested + editOrNewExecLike(io.kubernetes.client.openapi.models.V1ExecAction item) { + return withNewExecLike(getExec() != null ? getExec() : item); } - + /** * This method has been deprecated, please use method buildHttpGet instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HTTPGetAction getHttpGet() { - return this.httpGet!=null ?this.httpGet.build():null; + return this.httpGet != null ? this.httpGet.build() : null; } + public io.kubernetes.client.openapi.models.V1HTTPGetAction buildHttpGet() { - return this.httpGet!=null ?this.httpGet.build():null; + return this.httpGet != null ? this.httpGet.build() : null; } + public A withHttpGet(io.kubernetes.client.openapi.models.V1HTTPGetAction httpGet) { _visitables.get("httpGet").remove(this.httpGet); - if (httpGet!=null){ this.httpGet= new io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder(httpGet); _visitables.get("httpGet").add(this.httpGet);} return (A) this; + if (httpGet != null) { + this.httpGet = new io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder(httpGet); + _visitables.get("httpGet").add(this.httpGet); + } + return (A) this; } + public java.lang.Boolean hasHttpGet() { return this.httpGet != null; } - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested withNewHttpGet() { + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested + withNewHttpGet() { return new io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl.HttpGetNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested withNewHttpGetLike(io.kubernetes.client.openapi.models.V1HTTPGetAction item) { - return new io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl.HttpGetNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested + withNewHttpGetLike(io.kubernetes.client.openapi.models.V1HTTPGetAction item) { + return new io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl.HttpGetNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested editHttpGet() { + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested + editHttpGet() { return withNewHttpGetLike(getHttpGet()); } - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested editOrNewHttpGet() { - return withNewHttpGetLike(getHttpGet() != null ? getHttpGet(): new io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder().build()); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested + editOrNewHttpGet() { + return withNewHttpGetLike( + getHttpGet() != null + ? getHttpGet() + : new io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested editOrNewHttpGetLike(io.kubernetes.client.openapi.models.V1HTTPGetAction item) { - return withNewHttpGetLike(getHttpGet() != null ? getHttpGet(): item); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested + editOrNewHttpGetLike(io.kubernetes.client.openapi.models.V1HTTPGetAction item) { + return withNewHttpGetLike(getHttpGet() != null ? getHttpGet() : item); } - + /** * This method has been deprecated, please use method buildTcpSocket instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TCPSocketAction getTcpSocket() { - return this.tcpSocket!=null ?this.tcpSocket.build():null; + return this.tcpSocket != null ? this.tcpSocket.build() : null; } + public io.kubernetes.client.openapi.models.V1TCPSocketAction buildTcpSocket() { - return this.tcpSocket!=null ?this.tcpSocket.build():null; + return this.tcpSocket != null ? this.tcpSocket.build() : null; } + public A withTcpSocket(io.kubernetes.client.openapi.models.V1TCPSocketAction tcpSocket) { _visitables.get("tcpSocket").remove(this.tcpSocket); - if (tcpSocket!=null){ this.tcpSocket= new io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder(tcpSocket); _visitables.get("tcpSocket").add(this.tcpSocket);} return (A) this; + if (tcpSocket != null) { + this.tcpSocket = new io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder(tcpSocket); + _visitables.get("tcpSocket").add(this.tcpSocket); + } + return (A) this; } + public java.lang.Boolean hasTcpSocket() { return this.tcpSocket != null; } - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested withNewTcpSocket() { - return new io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl.TcpSocketNestedImpl(); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested + withNewTcpSocket() { + return new io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl + .TcpSocketNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested withNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item) { - return new io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl.TcpSocketNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested + withNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item) { + return new io.kubernetes.client.openapi.models.V1LifecycleHandlerFluentImpl.TcpSocketNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested editTcpSocket() { + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested + editTcpSocket() { return withNewTcpSocketLike(getTcpSocket()); } - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested editOrNewTcpSocket() { - return withNewTcpSocketLike(getTcpSocket() != null ? getTcpSocket(): new io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder().build()); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested + editOrNewTcpSocket() { + return withNewTcpSocketLike( + getTcpSocket() != null + ? getTcpSocket() + : new io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested editOrNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item) { - return withNewTcpSocketLike(getTcpSocket() != null ? getTcpSocket(): item); + + public io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested + editOrNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item) { + return withNewTcpSocketLike(getTcpSocket() != null ? getTcpSocket() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1LifecycleHandlerFluentImpl that = (V1LifecycleHandlerFluentImpl) o; - if (exec != null ? !exec.equals(that.exec) :that.exec != null) return false; - if (httpGet != null ? !httpGet.equals(that.httpGet) :that.httpGet != null) return false; - if (tcpSocket != null ? !tcpSocket.equals(that.tcpSocket) :that.tcpSocket != null) return false; + if (exec != null ? !exec.equals(that.exec) : that.exec != null) return false; + if (httpGet != null ? !httpGet.equals(that.httpGet) : that.httpGet != null) return false; + if (tcpSocket != null ? !tcpSocket.equals(that.tcpSocket) : that.tcpSocket != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(exec, httpGet, tcpSocket, super.hashCode()); + return java.util.Objects.hash(exec, httpGet, tcpSocket, super.hashCode()); } - public class ExecNestedImpl extends io.kubernetes.client.openapi.models.V1ExecActionFluentImpl> implements io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested,io.kubernetes.client.fluent.Nested{ + + public class ExecNestedImpl + extends io.kubernetes.client.openapi.models.V1ExecActionFluentImpl< + io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested> + implements io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.ExecNested, + io.kubernetes.client.fluent.Nested { ExecNestedImpl(io.kubernetes.client.openapi.models.V1ExecAction item) { this.builder = new io.kubernetes.client.openapi.models.V1ExecActionBuilder(this, item); } + ExecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ExecActionBuilder(this); } + io.kubernetes.client.openapi.models.V1ExecActionBuilder builder; + public N and() { return (N) V1LifecycleHandlerFluentImpl.this.withExec(builder.build()); } + public N endExec() { return and(); } - } - public class HttpGetNestedImpl extends io.kubernetes.client.openapi.models.V1HTTPGetActionFluentImpl> implements io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested,io.kubernetes.client.fluent.Nested{ + + public class HttpGetNestedImpl + extends io.kubernetes.client.openapi.models.V1HTTPGetActionFluentImpl< + io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested> + implements io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.HttpGetNested, + io.kubernetes.client.fluent.Nested { HttpGetNestedImpl(io.kubernetes.client.openapi.models.V1HTTPGetAction item) { this.builder = new io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder(this, item); } + HttpGetNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder(this); } + io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder builder; + public N and() { return (N) V1LifecycleHandlerFluentImpl.this.withHttpGet(builder.build()); } + public N endHttpGet() { return and(); } - } - public class TcpSocketNestedImpl extends io.kubernetes.client.openapi.models.V1TCPSocketActionFluentImpl> implements io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested,io.kubernetes.client.fluent.Nested{ + + public class TcpSocketNestedImpl + extends io.kubernetes.client.openapi.models.V1TCPSocketActionFluentImpl< + io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested> + implements io.kubernetes.client.openapi.models.V1LifecycleHandlerFluent.TcpSocketNested, + io.kubernetes.client.fluent.Nested { TcpSocketNestedImpl(io.kubernetes.client.openapi.models.V1TCPSocketAction item) { this.builder = new io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder(this, item); } + TcpSocketNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder(this); } + io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder builder; + public N and() { return (N) V1LifecycleHandlerFluentImpl.this.withTcpSocket(builder.build()); } + public N endTcpSocket() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeBuilder.java index 9029f26b4a..dc9f98fda7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LimitRangeBuilder extends io.kubernetes.client.openapi.models.V1LimitRangeFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LimitRangeBuilder + extends io.kubernetes.client.openapi.models.V1LimitRangeFluentImpl< + io.kubernetes.client.openapi.models.V1LimitRangeBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LimitRange, + io.kubernetes.client.openapi.models.V1LimitRangeBuilder> { public V1LimitRangeBuilder() { this(false); } + public V1LimitRangeBuilder(java.lang.Boolean validationEnabled) { this(new V1LimitRange(), validationEnabled); } + public V1LimitRangeBuilder(io.kubernetes.client.openapi.models.V1LimitRangeFluent fluent) { this(fluent, false); } - public V1LimitRangeBuilder(io.kubernetes.client.openapi.models.V1LimitRangeFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LimitRangeBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LimitRange(), validationEnabled); } - public V1LimitRangeBuilder(io.kubernetes.client.openapi.models.V1LimitRangeFluent fluent,io.kubernetes.client.openapi.models.V1LimitRange instance) { + + public V1LimitRangeBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeFluent fluent, + io.kubernetes.client.openapi.models.V1LimitRange instance) { this(fluent, instance, false); } - public V1LimitRangeBuilder(io.kubernetes.client.openapi.models.V1LimitRangeFluent fluent,io.kubernetes.client.openapi.models.V1LimitRange instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LimitRangeBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeFluent fluent, + io.kubernetes.client.openapi.models.V1LimitRange instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +55,17 @@ public V1LimitRangeBuilder(io.kubernetes.client.openapi.models.V1LimitRangeFluen fluent.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1LimitRangeBuilder(io.kubernetes.client.openapi.models.V1LimitRange instance) { - this(instance,false); + this(instance, false); } - public V1LimitRangeBuilder(io.kubernetes.client.openapi.models.V1LimitRange instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LimitRangeBuilder( + io.kubernetes.client.openapi.models.V1LimitRange instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +74,12 @@ public V1LimitRangeBuilder(io.kubernetes.client.openapi.models.V1LimitRange inst this.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LimitRangeFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LimitRange build() { V1LimitRange buildable = new V1LimitRange(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1LimitRange build() { buildable.setSpec(fluent.getSpec()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LimitRangeBuilder that = (V1LimitRangeBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeFluent.java index 09cf99c297..d6bcc2bb6e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeFluent.java @@ -1,73 +1,109 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1LimitRangeFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1LimitRangeFluent< + A extends io.kubernetes.client.openapi.models.V1LimitRangeFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LimitRangeSpec getSpec(); + public io.kubernetes.client.openapi.models.V1LimitRangeSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1LimitRangeSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1LimitRangeSpec item); + + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1LimitRangeSpec item); + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1LimitRangeSpec item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1LimitRangeSpec item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent< + io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested> { public N and(); + public N endSpec(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeFluentImpl.java index 62f9dfbff2..af1f474656 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1LimitRangeFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LimitRangeFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LimitRangeFluent { + public V1LimitRangeFluentImpl() {} - /** - * Generated - */ -public class V1LimitRangeFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LimitRangeFluent{ - public V1LimitRangeFluentImpl() { - } public V1LimitRangeFluentImpl(io.kubernetes.client.openapi.models.V1LimitRange instance) { this.withApiVersion(instance.getApiVersion()); @@ -21,158 +27,218 @@ public V1LimitRangeFluentImpl(io.kubernetes.client.openapi.models.V1LimitRange i this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1LimitRangeSpecBuilder spec; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1LimitRangeFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1LimitRangeFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LimitRangeSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1LimitRangeSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1LimitRangeSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1LimitRangeSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1LimitRangeSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1LimitRangeFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1LimitRangeSpec item) { + + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1LimitRangeSpec item) { return new io.kubernetes.client.openapi.models.V1LimitRangeFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1LimitRangeSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1LimitRangeSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1LimitRangeSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1LimitRangeSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1LimitRangeFluentImpl that = (V1LimitRangeFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1LimitRangeFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1LimitRangeFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1LimitRangeSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1LimitRangeSpecFluentImpl< + io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1LimitRangeFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1LimitRangeSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1LimitRangeSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LimitRangeSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1LimitRangeSpecBuilder builder; + public N and() { return (N) V1LimitRangeFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeItemBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeItemBuilder.java index 92482ee9fc..42d9264fcd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeItemBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeItemBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LimitRangeItemBuilder extends io.kubernetes.client.openapi.models.V1LimitRangeItemFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LimitRangeItemBuilder + extends io.kubernetes.client.openapi.models.V1LimitRangeItemFluentImpl< + io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LimitRangeItem, + io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder> { public V1LimitRangeItemBuilder() { this(false); } + public V1LimitRangeItemBuilder(java.lang.Boolean validationEnabled) { this(new V1LimitRangeItem(), validationEnabled); } - public V1LimitRangeItemBuilder(io.kubernetes.client.openapi.models.V1LimitRangeItemFluent fluent) { + + public V1LimitRangeItemBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeItemFluent fluent) { this(fluent, false); } - public V1LimitRangeItemBuilder(io.kubernetes.client.openapi.models.V1LimitRangeItemFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LimitRangeItemBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeItemFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LimitRangeItem(), validationEnabled); } - public V1LimitRangeItemBuilder(io.kubernetes.client.openapi.models.V1LimitRangeItemFluent fluent,io.kubernetes.client.openapi.models.V1LimitRangeItem instance) { + + public V1LimitRangeItemBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeItemFluent fluent, + io.kubernetes.client.openapi.models.V1LimitRangeItem instance) { this(fluent, instance, false); } - public V1LimitRangeItemBuilder(io.kubernetes.client.openapi.models.V1LimitRangeItemFluent fluent,io.kubernetes.client.openapi.models.V1LimitRangeItem instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LimitRangeItemBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeItemFluent fluent, + io.kubernetes.client.openapi.models.V1LimitRangeItem instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDefault(instance.getDefault()); fluent.withDefaultRequest(instance.getDefaultRequest()); @@ -33,13 +60,17 @@ public V1LimitRangeItemBuilder(io.kubernetes.client.openapi.models.V1LimitRangeI fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1LimitRangeItemBuilder(io.kubernetes.client.openapi.models.V1LimitRangeItem instance) { - this(instance,false); + this(instance, false); } - public V1LimitRangeItemBuilder(io.kubernetes.client.openapi.models.V1LimitRangeItem instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LimitRangeItemBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeItem instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDefault(instance.getDefault()); this.withDefaultRequest(instance.getDefaultRequest()); @@ -52,10 +83,12 @@ public V1LimitRangeItemBuilder(io.kubernetes.client.openapi.models.V1LimitRangeI this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LimitRangeItemFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LimitRangeItem build() { V1LimitRangeItem buildable = new V1LimitRangeItem(); buildable.setDefault(fluent.getDefault()); @@ -66,18 +99,23 @@ public io.kubernetes.client.openapi.models.V1LimitRangeItem build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LimitRangeItemBuilder that = (V1LimitRangeItemBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeItemFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeItemFluent.java index 1b979f23bb..3891305074 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeItemFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeItemFluent.java @@ -1,54 +1,106 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; -import java.util.Map; -import java.util.LinkedHashMap; - - /** - * Generated - */ -public interface V1LimitRangeItemFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToDefault(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToDefault(java.util.Map map); +/** Generated */ +public interface V1LimitRangeItemFluent< + A extends io.kubernetes.client.openapi.models.V1LimitRangeItemFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToDefault(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToDefault(java.util.Map map); + public A removeFromDefault(java.lang.String key); - public A removeFromDefault(java.util.Map map); - public java.util.Map getDefault(); - public A withDefault(java.util.Map _default); + + public A removeFromDefault( + java.util.Map map); + + public java.util.Map getDefault(); + + public A withDefault( + java.util.Map _default); + public java.lang.Boolean hasDefault(); - public A addToDefaultRequest(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToDefaultRequest(java.util.Map map); + + public A addToDefaultRequest(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToDefaultRequest( + java.util.Map map); + public A removeFromDefaultRequest(java.lang.String key); - public A removeFromDefaultRequest(java.util.Map map); - public java.util.Map getDefaultRequest(); - public A withDefaultRequest(java.util.Map defaultRequest); + + public A removeFromDefaultRequest( + java.util.Map map); + + public java.util.Map getDefaultRequest(); + + public A withDefaultRequest( + java.util.Map defaultRequest); + public java.lang.Boolean hasDefaultRequest(); - public A addToMax(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToMax(java.util.Map map); + + public A addToMax(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToMax(java.util.Map map); + public A removeFromMax(java.lang.String key); - public A removeFromMax(java.util.Map map); - public java.util.Map getMax(); - public A withMax(java.util.Map max); + + public A removeFromMax(java.util.Map map); + + public java.util.Map getMax(); + + public A withMax( + java.util.Map max); + public java.lang.Boolean hasMax(); - public A addToMaxLimitRequestRatio(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToMaxLimitRequestRatio(java.util.Map map); + + public A addToMaxLimitRequestRatio( + java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToMaxLimitRequestRatio( + java.util.Map map); + public A removeFromMaxLimitRequestRatio(java.lang.String key); - public A removeFromMaxLimitRequestRatio(java.util.Map map); - public java.util.Map getMaxLimitRequestRatio(); - public A withMaxLimitRequestRatio(java.util.Map maxLimitRequestRatio); + + public A removeFromMaxLimitRequestRatio( + java.util.Map map); + + public java.util.Map + getMaxLimitRequestRatio(); + + public A withMaxLimitRequestRatio( + java.util.Map maxLimitRequestRatio); + public java.lang.Boolean hasMaxLimitRequestRatio(); - public A addToMin(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToMin(java.util.Map map); + + public A addToMin(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToMin(java.util.Map map); + public A removeFromMin(java.lang.String key); - public A removeFromMin(java.util.Map map); - public java.util.Map getMin(); - public A withMin(java.util.Map min); + + public A removeFromMin(java.util.Map map); + + public java.util.Map getMin(); + + public A withMin( + java.util.Map min); + public java.lang.Boolean hasMin(); + public io.kubernetes.client.openapi.models.V1LimitRangeItem.TypeEnum getType(); + public A withType(io.kubernetes.client.openapi.models.V1LimitRangeItem.TypeEnum type); + public java.lang.Boolean hasType(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeItemFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeItemFluentImpl.java index 7fe3491d2a..229521c981 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeItemFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeItemFluentImpl.java @@ -1,19 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.BaseFluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; -import java.util.Map; -import java.util.LinkedHashMap; +/** Generated */ +public class V1LimitRangeItemFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LimitRangeItemFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LimitRangeItemFluent { + public V1LimitRangeItemFluentImpl() {} - /** - * Generated - */ -public class V1LimitRangeItemFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LimitRangeItemFluent{ - public V1LimitRangeItemFluentImpl() { - } public V1LimitRangeItemFluentImpl(io.kubernetes.client.openapi.models.V1LimitRangeItem instance) { this.withDefault(instance.getDefault()); @@ -26,162 +31,367 @@ public V1LimitRangeItemFluentImpl(io.kubernetes.client.openapi.models.V1LimitRan this.withMin(instance.getMin()); this.withType(instance.getType()); - } - private java.util.Map _default; - private java.util.Map defaultRequest; - private java.util.Map max; - private java.util.Map maxLimitRequestRatio; - private java.util.Map min; + + private java.util.Map _default; + private java.util.Map defaultRequest; + private java.util.Map max; + private java.util.Map + maxLimitRequestRatio; + private java.util.Map min; private io.kubernetes.client.openapi.models.V1LimitRangeItem.TypeEnum type; - public A addToDefault(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this._default == null && key != null && value != null) { this._default = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this._default.put(key, value);} return (A)this; + + public A addToDefault(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this._default == null && key != null && value != null) { + this._default = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this._default.put(key, value); + } + return (A) this; } - public A addToDefault(java.util.Map map) { - if(this._default == null && map != null) { this._default = new java.util.LinkedHashMap(); } - if(map != null) { this._default.putAll(map);} return (A)this; + + public A addToDefault(java.util.Map map) { + if (this._default == null && map != null) { + this._default = new java.util.LinkedHashMap(); + } + if (map != null) { + this._default.putAll(map); + } + return (A) this; } + public A removeFromDefault(java.lang.String key) { - if(this._default == null) { return (A) this; } - if(key != null && this._default != null) {this._default.remove(key);} return (A)this; + if (this._default == null) { + return (A) this; + } + if (key != null && this._default != null) { + this._default.remove(key); + } + return (A) this; } - public A removeFromDefault(java.util.Map map) { - if(this._default == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this._default != null){this._default.remove(key);}}} return (A)this; + + public A removeFromDefault( + java.util.Map map) { + if (this._default == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this._default != null) { + this._default.remove(key); + } + } + } + return (A) this; } - public java.util.Map getDefault() { + + public java.util.Map getDefault() { return this._default; } - public A withDefault(java.util.Map _default) { - if (_default == null) { this._default = null;} else {this._default = new java.util.LinkedHashMap(_default);} return (A) this; + + public A withDefault( + java.util.Map _default) { + if (_default == null) { + this._default = null; + } else { + this._default = new java.util.LinkedHashMap(_default); + } + return (A) this; } + public java.lang.Boolean hasDefault() { return this._default != null; } - public A addToDefaultRequest(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.defaultRequest == null && key != null && value != null) { this.defaultRequest = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.defaultRequest.put(key, value);} return (A)this; + + public A addToDefaultRequest(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.defaultRequest == null && key != null && value != null) { + this.defaultRequest = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.defaultRequest.put(key, value); + } + return (A) this; } - public A addToDefaultRequest(java.util.Map map) { - if(this.defaultRequest == null && map != null) { this.defaultRequest = new java.util.LinkedHashMap(); } - if(map != null) { this.defaultRequest.putAll(map);} return (A)this; + + public A addToDefaultRequest( + java.util.Map map) { + if (this.defaultRequest == null && map != null) { + this.defaultRequest = new java.util.LinkedHashMap(); + } + if (map != null) { + this.defaultRequest.putAll(map); + } + return (A) this; } + public A removeFromDefaultRequest(java.lang.String key) { - if(this.defaultRequest == null) { return (A) this; } - if(key != null && this.defaultRequest != null) {this.defaultRequest.remove(key);} return (A)this; + if (this.defaultRequest == null) { + return (A) this; + } + if (key != null && this.defaultRequest != null) { + this.defaultRequest.remove(key); + } + return (A) this; } - public A removeFromDefaultRequest(java.util.Map map) { - if(this.defaultRequest == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.defaultRequest != null){this.defaultRequest.remove(key);}}} return (A)this; + + public A removeFromDefaultRequest( + java.util.Map map) { + if (this.defaultRequest == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.defaultRequest != null) { + this.defaultRequest.remove(key); + } + } + } + return (A) this; } - public java.util.Map getDefaultRequest() { + + public java.util.Map getDefaultRequest() { return this.defaultRequest; } - public A withDefaultRequest(java.util.Map defaultRequest) { - if (defaultRequest == null) { this.defaultRequest = null;} else {this.defaultRequest = new java.util.LinkedHashMap(defaultRequest);} return (A) this; + + public A withDefaultRequest( + java.util.Map defaultRequest) { + if (defaultRequest == null) { + this.defaultRequest = null; + } else { + this.defaultRequest = new java.util.LinkedHashMap(defaultRequest); + } + return (A) this; } + public java.lang.Boolean hasDefaultRequest() { return this.defaultRequest != null; } - public A addToMax(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.max == null && key != null && value != null) { this.max = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.max.put(key, value);} return (A)this; + + public A addToMax(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.max == null && key != null && value != null) { + this.max = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.max.put(key, value); + } + return (A) this; } - public A addToMax(java.util.Map map) { - if(this.max == null && map != null) { this.max = new java.util.LinkedHashMap(); } - if(map != null) { this.max.putAll(map);} return (A)this; + + public A addToMax(java.util.Map map) { + if (this.max == null && map != null) { + this.max = new java.util.LinkedHashMap(); + } + if (map != null) { + this.max.putAll(map); + } + return (A) this; } + public A removeFromMax(java.lang.String key) { - if(this.max == null) { return (A) this; } - if(key != null && this.max != null) {this.max.remove(key);} return (A)this; + if (this.max == null) { + return (A) this; + } + if (key != null && this.max != null) { + this.max.remove(key); + } + return (A) this; } - public A removeFromMax(java.util.Map map) { - if(this.max == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.max != null){this.max.remove(key);}}} return (A)this; + + public A removeFromMax( + java.util.Map map) { + if (this.max == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.max != null) { + this.max.remove(key); + } + } + } + return (A) this; } - public java.util.Map getMax() { + + public java.util.Map getMax() { return this.max; } - public A withMax(java.util.Map max) { - if (max == null) { this.max = null;} else {this.max = new java.util.LinkedHashMap(max);} return (A) this; + + public A withMax( + java.util.Map max) { + if (max == null) { + this.max = null; + } else { + this.max = new java.util.LinkedHashMap(max); + } + return (A) this; } + public java.lang.Boolean hasMax() { return this.max != null; } - public A addToMaxLimitRequestRatio(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.maxLimitRequestRatio == null && key != null && value != null) { this.maxLimitRequestRatio = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.maxLimitRequestRatio.put(key, value);} return (A)this; + + public A addToMaxLimitRequestRatio( + java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.maxLimitRequestRatio == null && key != null && value != null) { + this.maxLimitRequestRatio = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.maxLimitRequestRatio.put(key, value); + } + return (A) this; } - public A addToMaxLimitRequestRatio(java.util.Map map) { - if(this.maxLimitRequestRatio == null && map != null) { this.maxLimitRequestRatio = new java.util.LinkedHashMap(); } - if(map != null) { this.maxLimitRequestRatio.putAll(map);} return (A)this; + + public A addToMaxLimitRequestRatio( + java.util.Map map) { + if (this.maxLimitRequestRatio == null && map != null) { + this.maxLimitRequestRatio = new java.util.LinkedHashMap(); + } + if (map != null) { + this.maxLimitRequestRatio.putAll(map); + } + return (A) this; } + public A removeFromMaxLimitRequestRatio(java.lang.String key) { - if(this.maxLimitRequestRatio == null) { return (A) this; } - if(key != null && this.maxLimitRequestRatio != null) {this.maxLimitRequestRatio.remove(key);} return (A)this; + if (this.maxLimitRequestRatio == null) { + return (A) this; + } + if (key != null && this.maxLimitRequestRatio != null) { + this.maxLimitRequestRatio.remove(key); + } + return (A) this; } - public A removeFromMaxLimitRequestRatio(java.util.Map map) { - if(this.maxLimitRequestRatio == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.maxLimitRequestRatio != null){this.maxLimitRequestRatio.remove(key);}}} return (A)this; + + public A removeFromMaxLimitRequestRatio( + java.util.Map map) { + if (this.maxLimitRequestRatio == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.maxLimitRequestRatio != null) { + this.maxLimitRequestRatio.remove(key); + } + } + } + return (A) this; } - public java.util.Map getMaxLimitRequestRatio() { + + public java.util.Map + getMaxLimitRequestRatio() { return this.maxLimitRequestRatio; } - public A withMaxLimitRequestRatio(java.util.Map maxLimitRequestRatio) { - if (maxLimitRequestRatio == null) { this.maxLimitRequestRatio = null;} else {this.maxLimitRequestRatio = new java.util.LinkedHashMap(maxLimitRequestRatio);} return (A) this; + + public A withMaxLimitRequestRatio( + java.util.Map maxLimitRequestRatio) { + if (maxLimitRequestRatio == null) { + this.maxLimitRequestRatio = null; + } else { + this.maxLimitRequestRatio = new java.util.LinkedHashMap(maxLimitRequestRatio); + } + return (A) this; } + public java.lang.Boolean hasMaxLimitRequestRatio() { return this.maxLimitRequestRatio != null; } - public A addToMin(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.min == null && key != null && value != null) { this.min = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.min.put(key, value);} return (A)this; + + public A addToMin(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.min == null && key != null && value != null) { + this.min = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.min.put(key, value); + } + return (A) this; } - public A addToMin(java.util.Map map) { - if(this.min == null && map != null) { this.min = new java.util.LinkedHashMap(); } - if(map != null) { this.min.putAll(map);} return (A)this; + + public A addToMin(java.util.Map map) { + if (this.min == null && map != null) { + this.min = new java.util.LinkedHashMap(); + } + if (map != null) { + this.min.putAll(map); + } + return (A) this; } + public A removeFromMin(java.lang.String key) { - if(this.min == null) { return (A) this; } - if(key != null && this.min != null) {this.min.remove(key);} return (A)this; + if (this.min == null) { + return (A) this; + } + if (key != null && this.min != null) { + this.min.remove(key); + } + return (A) this; } - public A removeFromMin(java.util.Map map) { - if(this.min == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.min != null){this.min.remove(key);}}} return (A)this; + + public A removeFromMin( + java.util.Map map) { + if (this.min == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.min != null) { + this.min.remove(key); + } + } + } + return (A) this; } - public java.util.Map getMin() { + + public java.util.Map getMin() { return this.min; } - public A withMin(java.util.Map min) { - if (min == null) { this.min = null;} else {this.min = new java.util.LinkedHashMap(min);} return (A) this; + + public A withMin( + java.util.Map min) { + if (min == null) { + this.min = null; + } else { + this.min = new java.util.LinkedHashMap(min); + } + return (A) this; } + public java.lang.Boolean hasMin() { return this.min != null; } + public io.kubernetes.client.openapi.models.V1LimitRangeItem.TypeEnum getType() { return this.type; } + public A withType(io.kubernetes.client.openapi.models.V1LimitRangeItem.TypeEnum type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1LimitRangeItemFluentImpl that = (V1LimitRangeItemFluentImpl) o; - if (_default != null ? !_default.equals(that._default) :that._default != null) return false; - if (defaultRequest != null ? !defaultRequest.equals(that.defaultRequest) :that.defaultRequest != null) return false; - if (max != null ? !max.equals(that.max) :that.max != null) return false; - if (maxLimitRequestRatio != null ? !maxLimitRequestRatio.equals(that.maxLimitRequestRatio) :that.maxLimitRequestRatio != null) return false; - if (min != null ? !min.equals(that.min) :that.min != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (_default != null ? !_default.equals(that._default) : that._default != null) return false; + if (defaultRequest != null + ? !defaultRequest.equals(that.defaultRequest) + : that.defaultRequest != null) return false; + if (max != null ? !max.equals(that.max) : that.max != null) return false; + if (maxLimitRequestRatio != null + ? !maxLimitRequestRatio.equals(that.maxLimitRequestRatio) + : that.maxLimitRequestRatio != null) return false; + if (min != null ? !min.equals(that.min) : that.min != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(_default, defaultRequest, max, maxLimitRequestRatio, min, type, super.hashCode()); + return java.util.Objects.hash( + _default, defaultRequest, max, maxLimitRequestRatio, min, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeListBuilder.java index b0401813ab..a8cc93768e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LimitRangeListBuilder extends io.kubernetes.client.openapi.models.V1LimitRangeListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LimitRangeListBuilder + extends io.kubernetes.client.openapi.models.V1LimitRangeListFluentImpl< + io.kubernetes.client.openapi.models.V1LimitRangeListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LimitRangeList, + io.kubernetes.client.openapi.models.V1LimitRangeListBuilder> { public V1LimitRangeListBuilder() { this(false); } + public V1LimitRangeListBuilder(java.lang.Boolean validationEnabled) { this(new V1LimitRangeList(), validationEnabled); } - public V1LimitRangeListBuilder(io.kubernetes.client.openapi.models.V1LimitRangeListFluent fluent) { + + public V1LimitRangeListBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeListFluent fluent) { this(fluent, false); } - public V1LimitRangeListBuilder(io.kubernetes.client.openapi.models.V1LimitRangeListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LimitRangeListBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LimitRangeList(), validationEnabled); } - public V1LimitRangeListBuilder(io.kubernetes.client.openapi.models.V1LimitRangeListFluent fluent,io.kubernetes.client.openapi.models.V1LimitRangeList instance) { + + public V1LimitRangeListBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeListFluent fluent, + io.kubernetes.client.openapi.models.V1LimitRangeList instance) { this(fluent, instance, false); } - public V1LimitRangeListBuilder(io.kubernetes.client.openapi.models.V1LimitRangeListFluent fluent,io.kubernetes.client.openapi.models.V1LimitRangeList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LimitRangeListBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeListFluent fluent, + io.kubernetes.client.openapi.models.V1LimitRangeList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1LimitRangeListBuilder(io.kubernetes.client.openapi.models.V1LimitRangeL fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1LimitRangeListBuilder(io.kubernetes.client.openapi.models.V1LimitRangeList instance) { - this(instance,false); + this(instance, false); } - public V1LimitRangeListBuilder(io.kubernetes.client.openapi.models.V1LimitRangeList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LimitRangeListBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1LimitRangeListBuilder(io.kubernetes.client.openapi.models.V1LimitRangeL this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LimitRangeListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LimitRangeList build() { V1LimitRangeList buildable = new V1LimitRangeList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1LimitRangeList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LimitRangeListBuilder that = (V1LimitRangeListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeListFluent.java index a056e4c479..72334de5c4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeListFluent.java @@ -1,95 +1,154 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1LimitRangeListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1LimitRangeListFluent< + A extends io.kubernetes.client.openapi.models.V1LimitRangeListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRange item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRange item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRange item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRange item); + public A addToItems(io.kubernetes.client.openapi.models.V1LimitRange... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1LimitRange... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1LimitRange buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1LimitRange buildFirstItem(); + public io.kubernetes.client.openapi.models.V1LimitRange buildLastItem(); - public io.kubernetes.client.openapi.models.V1LimitRange buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1LimitRange buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1LimitRange... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1LimitRange item); - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRange item); - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1LimitRange item); + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRange item); + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LimitRangeFluent>{ + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LimitRangeFluent< + io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeListFluentImpl.java index cf81f1c364..6944be02d3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1LimitRangeListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LimitRangeListFluent{ - public V1LimitRangeListFluentImpl() { - } +/** Generated */ +public class V1LimitRangeListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LimitRangeListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LimitRangeListFluent { + public V1LimitRangeListFluentImpl() {} + public V1LimitRangeListFluentImpl(io.kubernetes.client.openapi.models.V1LimitRangeList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,123 @@ public V1LimitRangeListFluentImpl(io.kubernetes.client.openapi.models.V1LimitRan this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRange item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LimitRangeBuilder builder = new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRange item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1LimitRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRange item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LimitRangeBuilder builder = new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRange item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1LimitRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1LimitRange... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LimitRange item : items) {io.kubernetes.client.openapi.models.V1LimitRangeBuilder builder = new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1LimitRange item : items) { + io.kubernetes.client.openapi.models.V1LimitRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LimitRange item : items) {io.kubernetes.client.openapi.models.V1LimitRangeBuilder builder = new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1LimitRange item : items) { + io.kubernetes.client.openapi.models.V1LimitRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1LimitRange... items) { - for (io.kubernetes.client.openapi.models.V1LimitRange item : items) {io.kubernetes.client.openapi.models.V1LimitRangeBuilder builder = new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1LimitRange item : items) { + io.kubernetes.client.openapi.models.V1LimitRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1LimitRange item : items) {io.kubernetes.client.openapi.models.V1LimitRangeBuilder builder = new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1LimitRange item : items) { + io.kubernetes.client.openapi.models.V1LimitRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +157,275 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1LimitRange buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1LimitRange buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1LimitRange buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1LimitRange buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LimitRangeBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1LimitRange buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1LimitRangeBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LimitRangeBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1LimitRangeBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1LimitRange item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1LimitRange item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1LimitRange... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1LimitRange item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1LimitRange item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1LimitRangeListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1LimitRange item) { - return new io.kubernetes.client.openapi.models.V1LimitRangeListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1LimitRange item) { + return new io.kubernetes.client.openapi.models.V1LimitRangeListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRange item) { - return new io.kubernetes.client.openapi.models.V1LimitRangeListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRange item) { + return new io.kubernetes.client.openapi.models.V1LimitRangeListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1LimitRangeListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1LimitRangeListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1LimitRangeListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1LimitRangeListFluentImpl that = (V1LimitRangeListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1LimitRangeFluentImpl> implements io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRange item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1LimitRangeFluentImpl< + io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1LimitRangeListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRange item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1LimitRangeBuilder(this); } + io.kubernetes.client.openapi.models.V1LimitRangeBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1LimitRangeListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1LimitRangeListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1LimitRangeListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1LimitRangeListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeSpecBuilder.java index 86fa10f1f4..c77ddc1807 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeSpecBuilder.java @@ -1,58 +1,96 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LimitRangeSpecBuilder extends io.kubernetes.client.openapi.models.V1LimitRangeSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LimitRangeSpecBuilder + extends io.kubernetes.client.openapi.models.V1LimitRangeSpecFluentImpl< + io.kubernetes.client.openapi.models.V1LimitRangeSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LimitRangeSpec, + io.kubernetes.client.openapi.models.V1LimitRangeSpecBuilder> { public V1LimitRangeSpecBuilder() { this(false); } + public V1LimitRangeSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1LimitRangeSpec(), validationEnabled); } - public V1LimitRangeSpecBuilder(io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent fluent) { + + public V1LimitRangeSpecBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent fluent) { this(fluent, false); } - public V1LimitRangeSpecBuilder(io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LimitRangeSpecBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LimitRangeSpec(), validationEnabled); } - public V1LimitRangeSpecBuilder(io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent fluent,io.kubernetes.client.openapi.models.V1LimitRangeSpec instance) { + + public V1LimitRangeSpecBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent fluent, + io.kubernetes.client.openapi.models.V1LimitRangeSpec instance) { this(fluent, instance, false); } - public V1LimitRangeSpecBuilder(io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent fluent,io.kubernetes.client.openapi.models.V1LimitRangeSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LimitRangeSpecBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent fluent, + io.kubernetes.client.openapi.models.V1LimitRangeSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLimits(instance.getLimits()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1LimitRangeSpecBuilder(io.kubernetes.client.openapi.models.V1LimitRangeSpec instance) { - this(instance,false); + this(instance, false); } - public V1LimitRangeSpecBuilder(io.kubernetes.client.openapi.models.V1LimitRangeSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LimitRangeSpecBuilder( + io.kubernetes.client.openapi.models.V1LimitRangeSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLimits(instance.getLimits()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LimitRangeSpec build() { V1LimitRangeSpec buildable = new V1LimitRangeSpec(); buildable.setLimits(fluent.getLimits()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LimitRangeSpecBuilder that = (V1LimitRangeSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeSpecFluent.java index c850ba7e2e..b7e5fbab97 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeSpecFluent.java @@ -1,57 +1,98 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1LimitRangeSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToLimits(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRangeItem item); - public A setToLimits(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRangeItem item); +/** Generated */ +public interface V1LimitRangeSpecFluent< + A extends io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToLimits( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRangeItem item); + + public A setToLimits( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRangeItem item); + public A addToLimits(io.kubernetes.client.openapi.models.V1LimitRangeItem... items); - public A addAllToLimits(java.util.Collection items); + + public A addAllToLimits( + java.util.Collection items); + public A removeFromLimits(io.kubernetes.client.openapi.models.V1LimitRangeItem... items); - public A removeAllFromLimits(java.util.Collection items); - public A removeMatchingFromLimits(java.util.function.Predicate predicate); - + + public A removeAllFromLimits( + java.util.Collection items); + + public A removeMatchingFromLimits( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildLimits instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getLimits(); + public java.util.List buildLimits(); + public io.kubernetes.client.openapi.models.V1LimitRangeItem buildLimit(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1LimitRangeItem buildFirstLimit(); + public io.kubernetes.client.openapi.models.V1LimitRangeItem buildLastLimit(); - public io.kubernetes.client.openapi.models.V1LimitRangeItem buildMatchingLimit(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingLimit(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1LimitRangeItem buildMatchingLimit( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingLimit( + java.util.function.Predicate + predicate); + public A withLimits(java.util.List limits); + public A withLimits(io.kubernetes.client.openapi.models.V1LimitRangeItem... limits); + public java.lang.Boolean hasLimits(); + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested addNewLimit(); - public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested addNewLimitLike(io.kubernetes.client.openapi.models.V1LimitRangeItem item); - public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested setNewLimitLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRangeItem item); - public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested editLimit(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested editFirstLimit(); + + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested addNewLimitLike( + io.kubernetes.client.openapi.models.V1LimitRangeItem item); + + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested setNewLimitLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRangeItem item); + + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested editLimit( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested + editFirstLimit(); + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested editLastLimit(); - public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested editMatchingLimit(java.util.function.Predicate predicate); - public interface LimitsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LimitRangeItemFluent>{ + + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested + editMatchingLimit( + java.util.function.Predicate + predicate); + + public interface LimitsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LimitRangeItemFluent< + io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested> { public N and(); + public N endLimit(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeSpecFluentImpl.java index 43eb699f8f..ccf0a835ce 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LimitRangeSpecFluentImpl.java @@ -1,57 +1,127 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1LimitRangeSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent{ - public V1LimitRangeSpecFluentImpl() { - } +/** Generated */ +public class V1LimitRangeSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent { + public V1LimitRangeSpecFluentImpl() {} + public V1LimitRangeSpecFluentImpl(io.kubernetes.client.openapi.models.V1LimitRangeSpec instance) { this.withLimits(instance.getLimits()); - } + private java.util.ArrayList limits; - public A addToLimits(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRangeItem item) { - if (this.limits == null) {this.limits = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder = new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(item);_visitables.get("limits").add(index >= 0 ? index : _visitables.get("limits").size(), builder);this.limits.add(index >= 0 ? index : limits.size(), builder); return (A)this; + + public A addToLimits( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRangeItem item) { + if (this.limits == null) { + this.limits = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder = + new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(item); + _visitables.get("limits").add(index >= 0 ? index : _visitables.get("limits").size(), builder); + this.limits.add(index >= 0 ? index : limits.size(), builder); + return (A) this; } - public A setToLimits(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRangeItem item) { - if (this.limits == null) {this.limits = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder = new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(item); - if (index < 0 || index >= _visitables.get("limits").size()) { _visitables.get("limits").add(builder); } else { _visitables.get("limits").set(index, builder);} - if (index < 0 || index >= limits.size()) { limits.add(builder); } else { limits.set(index, builder);} - return (A)this; + + public A setToLimits( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRangeItem item) { + if (this.limits == null) { + this.limits = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder = + new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(item); + if (index < 0 || index >= _visitables.get("limits").size()) { + _visitables.get("limits").add(builder); + } else { + _visitables.get("limits").set(index, builder); + } + if (index < 0 || index >= limits.size()) { + limits.add(builder); + } else { + limits.set(index, builder); + } + return (A) this; } + public A addToLimits(io.kubernetes.client.openapi.models.V1LimitRangeItem... items) { - if (this.limits == null) {this.limits = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LimitRangeItem item : items) {io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder = new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(item);_visitables.get("limits").add(builder);this.limits.add(builder);} return (A)this; + if (this.limits == null) { + this.limits = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1LimitRangeItem item : items) { + io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder = + new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(item); + _visitables.get("limits").add(builder); + this.limits.add(builder); + } + return (A) this; } - public A addAllToLimits(java.util.Collection items) { - if (this.limits == null) {this.limits = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LimitRangeItem item : items) {io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder = new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(item);_visitables.get("limits").add(builder);this.limits.add(builder);} return (A)this; + + public A addAllToLimits( + java.util.Collection items) { + if (this.limits == null) { + this.limits = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1LimitRangeItem item : items) { + io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder = + new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(item); + _visitables.get("limits").add(builder); + this.limits.add(builder); + } + return (A) this; } + public A removeFromLimits(io.kubernetes.client.openapi.models.V1LimitRangeItem... items) { - for (io.kubernetes.client.openapi.models.V1LimitRangeItem item : items) {io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder = new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(item);_visitables.get("limits").remove(builder);if (this.limits != null) {this.limits.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1LimitRangeItem item : items) { + io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder = + new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(item); + _visitables.get("limits").remove(builder); + if (this.limits != null) { + this.limits.remove(builder); + } + } + return (A) this; } - public A removeAllFromLimits(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1LimitRangeItem item : items) {io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder = new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(item);_visitables.get("limits").remove(builder);if (this.limits != null) {this.limits.remove(builder);}} return (A)this; + + public A removeAllFromLimits( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1LimitRangeItem item : items) { + io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder = + new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(item); + _visitables.get("limits").remove(builder); + if (this.limits != null) { + this.limits.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromLimits(java.util.function.Predicate predicate) { + + public A removeMatchingFromLimits( + java.util.function.Predicate + predicate) { if (limits == null) return (A) this; - final Iterator each = limits.iterator(); + final Iterator each = + limits.iterator(); final List visitables = _visitables.get("limits"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder = each.next(); @@ -60,104 +130,177 @@ public A removeMatchingFromLimits(java.util.function.Predicate getLimits() { return limits != null ? build(limits) : null; } + public java.util.List buildLimits() { return limits != null ? build(limits) : null; } + public io.kubernetes.client.openapi.models.V1LimitRangeItem buildLimit(java.lang.Integer index) { return this.limits.get(index).build(); } + public io.kubernetes.client.openapi.models.V1LimitRangeItem buildFirstLimit() { return this.limits.get(0).build(); } + public io.kubernetes.client.openapi.models.V1LimitRangeItem buildLastLimit() { return this.limits.get(limits.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1LimitRangeItem buildMatchingLimit(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder item: limits) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1LimitRangeItem buildMatchingLimit( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder item : limits) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingLimit(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder item: limits) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingLimit( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder item : limits) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withLimits(java.util.List limits) { - if (this.limits != null) { _visitables.get("limits").removeAll(this.limits);} - if (limits != null) {this.limits = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1LimitRangeItem item : limits){this.addToLimits(item);}} else { this.limits = null;} return (A) this; + if (this.limits != null) { + _visitables.get("limits").removeAll(this.limits); + } + if (limits != null) { + this.limits = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1LimitRangeItem item : limits) { + this.addToLimits(item); + } + } else { + this.limits = null; + } + return (A) this; } + public A withLimits(io.kubernetes.client.openapi.models.V1LimitRangeItem... limits) { - if (this.limits != null) {this.limits.clear();} - if (limits != null) {for (io.kubernetes.client.openapi.models.V1LimitRangeItem item :limits){ this.addToLimits(item);}} return (A) this; + if (this.limits != null) { + this.limits.clear(); + } + if (limits != null) { + for (io.kubernetes.client.openapi.models.V1LimitRangeItem item : limits) { + this.addToLimits(item); + } + } + return (A) this; } + public java.lang.Boolean hasLimits() { return limits != null && !limits.isEmpty(); } + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested addNewLimit() { return new io.kubernetes.client.openapi.models.V1LimitRangeSpecFluentImpl.LimitsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested addNewLimitLike(io.kubernetes.client.openapi.models.V1LimitRangeItem item) { - return new io.kubernetes.client.openapi.models.V1LimitRangeSpecFluentImpl.LimitsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested addNewLimitLike( + io.kubernetes.client.openapi.models.V1LimitRangeItem item) { + return new io.kubernetes.client.openapi.models.V1LimitRangeSpecFluentImpl.LimitsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested setNewLimitLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRangeItem item) { - return new io.kubernetes.client.openapi.models.V1LimitRangeSpecFluentImpl.LimitsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested setNewLimitLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRangeItem item) { + return new io.kubernetes.client.openapi.models.V1LimitRangeSpecFluentImpl.LimitsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested editLimit(java.lang.Integer index) { - if (limits.size() <= index) throw new RuntimeException("Can't edit limits. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested editLimit( + java.lang.Integer index) { + if (limits.size() <= index) + throw new RuntimeException("Can't edit limits. Index exceeds size."); return setNewLimitLike(index, buildLimit(index)); } - public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested editFirstLimit() { - if (limits.size() == 0) throw new RuntimeException("Can't edit first limits. The list is empty."); + + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested + editFirstLimit() { + if (limits.size() == 0) + throw new RuntimeException("Can't edit first limits. The list is empty."); return setNewLimitLike(0, buildLimit(0)); } - public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested editLastLimit() { + + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested + editLastLimit() { int index = limits.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last limits. The list is empty."); return setNewLimitLike(index, buildLimit(index)); } - public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested editMatchingLimit(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested + editMatchingLimit( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1LimitRangeItemFluentImpl> implements io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested,io.kubernetes.client.fluent.Nested{ - LimitsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LimitRangeItem item) { + + public class LimitsNestedImpl + extends io.kubernetes.client.openapi.models.V1LimitRangeItemFluentImpl< + io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested> + implements io.kubernetes.client.openapi.models.V1LimitRangeSpecFluent.LimitsNested, + io.kubernetes.client.fluent.Nested { + LimitsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LimitRangeItem item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(this, item); } + LimitsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder(this); } + io.kubernetes.client.openapi.models.V1LimitRangeItemBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1LimitRangeSpecFluentImpl.this.setToLimits(index,builder.build()); + return (N) V1LimitRangeSpecFluentImpl.this.setToLimits(index, builder.build()); } + public N endLimit() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ListMetaBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ListMetaBuilder.java index 7e11727015..8d4345a3a5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ListMetaBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ListMetaBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ListMetaBuilder extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ListMetaBuilder + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ListMetaBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ListMeta, + io.kubernetes.client.openapi.models.V1ListMetaBuilder> { public V1ListMetaBuilder() { this(false); } + public V1ListMetaBuilder(java.lang.Boolean validationEnabled) { this(new V1ListMeta(), validationEnabled); } + public V1ListMetaBuilder(io.kubernetes.client.openapi.models.V1ListMetaFluent fluent) { this(fluent, false); } - public V1ListMetaBuilder(io.kubernetes.client.openapi.models.V1ListMetaFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ListMetaBuilder( + io.kubernetes.client.openapi.models.V1ListMetaFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ListMeta(), validationEnabled); } - public V1ListMetaBuilder(io.kubernetes.client.openapi.models.V1ListMetaFluent fluent,io.kubernetes.client.openapi.models.V1ListMeta instance) { + + public V1ListMetaBuilder( + io.kubernetes.client.openapi.models.V1ListMetaFluent fluent, + io.kubernetes.client.openapi.models.V1ListMeta instance) { this(fluent, instance, false); } - public V1ListMetaBuilder(io.kubernetes.client.openapi.models.V1ListMetaFluent fluent,io.kubernetes.client.openapi.models.V1ListMeta instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ListMetaBuilder( + io.kubernetes.client.openapi.models.V1ListMetaFluent fluent, + io.kubernetes.client.openapi.models.V1ListMeta instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContinue(instance.getContinue()); fluent.withRemainingItemCount(instance.getRemainingItemCount()); @@ -29,13 +55,17 @@ public V1ListMetaBuilder(io.kubernetes.client.openapi.models.V1ListMetaFluent fluent.withSelfLink(instance.getSelfLink()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ListMetaBuilder(io.kubernetes.client.openapi.models.V1ListMeta instance) { - this(instance,false); + this(instance, false); } - public V1ListMetaBuilder(io.kubernetes.client.openapi.models.V1ListMeta instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ListMetaBuilder( + io.kubernetes.client.openapi.models.V1ListMeta instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContinue(instance.getContinue()); this.withRemainingItemCount(instance.getRemainingItemCount()); @@ -44,10 +74,12 @@ public V1ListMetaBuilder(io.kubernetes.client.openapi.models.V1ListMeta instance this.withSelfLink(instance.getSelfLink()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ListMetaFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ListMeta build() { V1ListMeta buildable = new V1ListMeta(); buildable.setContinue(fluent.getContinue()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1ListMeta build() { buildable.setSelfLink(fluent.getSelfLink()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ListMetaBuilder that = (V1ListMetaBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ListMetaFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ListMetaFluent.java index 5b0eb49597..9fef6367db 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ListMetaFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ListMetaFluent.java @@ -1,45 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Long; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ListMetaFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ListMetaFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getContinue(); + public A withContinue(java.lang.String _continue); + public java.lang.Boolean hasContinue(); - - /** - * Method is deprecated. use withContinue instead. - */ + + /** Method is deprecated. use withContinue instead. */ @java.lang.Deprecated public A withNewContinue(java.lang.String original); + public java.lang.Long getRemainingItemCount(); + public A withRemainingItemCount(java.lang.Long remainingItemCount); + public java.lang.Boolean hasRemainingItemCount(); + public java.lang.String getResourceVersion(); + public A withResourceVersion(java.lang.String resourceVersion); + public java.lang.Boolean hasResourceVersion(); - - /** - * Method is deprecated. use withResourceVersion instead. - */ + + /** Method is deprecated. use withResourceVersion instead. */ @java.lang.Deprecated public A withNewResourceVersion(java.lang.String original); + public java.lang.String getSelfLink(); + public A withSelfLink(java.lang.String selfLink); + public java.lang.Boolean hasSelfLink(); - - /** - * Method is deprecated. use withSelfLink instead. - */ + + /** Method is deprecated. use withSelfLink instead. */ @java.lang.Deprecated public A withNewSelfLink(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ListMetaFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ListMetaFluentImpl.java index 3355364855..c3e2037a4b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ListMetaFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ListMetaFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ListMetaFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ListMetaFluent { + public V1ListMetaFluentImpl() {} - /** - * Generated - */ -public class V1ListMetaFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ListMetaFluent{ - public V1ListMetaFluentImpl() { - } public V1ListMetaFluentImpl(io.kubernetes.client.openapi.models.V1ListMeta instance) { this.withContinue(instance.getContinue()); @@ -21,84 +26,101 @@ public V1ListMetaFluentImpl(io.kubernetes.client.openapi.models.V1ListMeta insta this.withResourceVersion(instance.getResourceVersion()); this.withSelfLink(instance.getSelfLink()); - } + private java.lang.String _continue; private java.lang.Long remainingItemCount; private java.lang.String resourceVersion; private java.lang.String selfLink; + public java.lang.String getContinue() { return this._continue; } + public A withContinue(java.lang.String _continue) { - this._continue=_continue; return (A) this; + this._continue = _continue; + return (A) this; } + public java.lang.Boolean hasContinue() { return this._continue != null; } - - /** - * Method is deprecated. use withContinue instead. - */ + + /** Method is deprecated. use withContinue instead. */ @java.lang.Deprecated public A withNewContinue(java.lang.String original) { - return (A)withContinue(new String(original)); + return (A) withContinue(new String(original)); } + public java.lang.Long getRemainingItemCount() { return this.remainingItemCount; } + public A withRemainingItemCount(java.lang.Long remainingItemCount) { - this.remainingItemCount=remainingItemCount; return (A) this; + this.remainingItemCount = remainingItemCount; + return (A) this; } + public java.lang.Boolean hasRemainingItemCount() { return this.remainingItemCount != null; } + public java.lang.String getResourceVersion() { return this.resourceVersion; } + public A withResourceVersion(java.lang.String resourceVersion) { - this.resourceVersion=resourceVersion; return (A) this; + this.resourceVersion = resourceVersion; + return (A) this; } + public java.lang.Boolean hasResourceVersion() { return this.resourceVersion != null; } - - /** - * Method is deprecated. use withResourceVersion instead. - */ + + /** Method is deprecated. use withResourceVersion instead. */ @java.lang.Deprecated public A withNewResourceVersion(java.lang.String original) { - return (A)withResourceVersion(new String(original)); + return (A) withResourceVersion(new String(original)); } + public java.lang.String getSelfLink() { return this.selfLink; } + public A withSelfLink(java.lang.String selfLink) { - this.selfLink=selfLink; return (A) this; + this.selfLink = selfLink; + return (A) this; } + public java.lang.Boolean hasSelfLink() { return this.selfLink != null; } - - /** - * Method is deprecated. use withSelfLink instead. - */ + + /** Method is deprecated. use withSelfLink instead. */ @java.lang.Deprecated public A withNewSelfLink(java.lang.String original) { - return (A)withSelfLink(new String(original)); + return (A) withSelfLink(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ListMetaFluentImpl that = (V1ListMetaFluentImpl) o; - if (_continue != null ? !_continue.equals(that._continue) :that._continue != null) return false; - if (remainingItemCount != null ? !remainingItemCount.equals(that.remainingItemCount) :that.remainingItemCount != null) return false; - if (resourceVersion != null ? !resourceVersion.equals(that.resourceVersion) :that.resourceVersion != null) return false; - if (selfLink != null ? !selfLink.equals(that.selfLink) :that.selfLink != null) return false; + if (_continue != null ? !_continue.equals(that._continue) : that._continue != null) + return false; + if (remainingItemCount != null + ? !remainingItemCount.equals(that.remainingItemCount) + : that.remainingItemCount != null) return false; + if (resourceVersion != null + ? !resourceVersion.equals(that.resourceVersion) + : that.resourceVersion != null) return false; + if (selfLink != null ? !selfLink.equals(that.selfLink) : that.selfLink != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(_continue, remainingItemCount, resourceVersion, selfLink, super.hashCode()); + return java.util.Objects.hash( + _continue, remainingItemCount, resourceVersion, selfLink, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerIngressBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerIngressBuilder.java index 2c3bc7fd9a..da2516afaf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerIngressBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerIngressBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LoadBalancerIngressBuilder extends io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LoadBalancerIngressBuilder + extends io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluentImpl< + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LoadBalancerIngress, + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder> { public V1LoadBalancerIngressBuilder() { this(false); } + public V1LoadBalancerIngressBuilder(java.lang.Boolean validationEnabled) { this(new V1LoadBalancerIngress(), validationEnabled); } - public V1LoadBalancerIngressBuilder(io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent fluent) { + + public V1LoadBalancerIngressBuilder( + io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent fluent) { this(fluent, false); } - public V1LoadBalancerIngressBuilder(io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LoadBalancerIngressBuilder( + io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LoadBalancerIngress(), validationEnabled); } - public V1LoadBalancerIngressBuilder(io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent fluent,io.kubernetes.client.openapi.models.V1LoadBalancerIngress instance) { + + public V1LoadBalancerIngressBuilder( + io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent fluent, + io.kubernetes.client.openapi.models.V1LoadBalancerIngress instance) { this(fluent, instance, false); } - public V1LoadBalancerIngressBuilder(io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent fluent,io.kubernetes.client.openapi.models.V1LoadBalancerIngress instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LoadBalancerIngressBuilder( + io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent fluent, + io.kubernetes.client.openapi.models.V1LoadBalancerIngress instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withHostname(instance.getHostname()); fluent.withIp(instance.getIp()); fluent.withPorts(instance.getPorts()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1LoadBalancerIngressBuilder(io.kubernetes.client.openapi.models.V1LoadBalancerIngress instance) { - this(instance,false); + + public V1LoadBalancerIngressBuilder( + io.kubernetes.client.openapi.models.V1LoadBalancerIngress instance) { + this(instance, false); } - public V1LoadBalancerIngressBuilder(io.kubernetes.client.openapi.models.V1LoadBalancerIngress instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LoadBalancerIngressBuilder( + io.kubernetes.client.openapi.models.V1LoadBalancerIngress instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withHostname(instance.getHostname()); this.withIp(instance.getIp()); this.withPorts(instance.getPorts()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LoadBalancerIngress build() { V1LoadBalancerIngress buildable = new V1LoadBalancerIngress(); buildable.setHostname(fluent.getHostname()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1LoadBalancerIngress build() { buildable.setPorts(fluent.getPorts()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LoadBalancerIngressBuilder that = (V1LoadBalancerIngressBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerIngressFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerIngressFluent.java index 636b403572..186c2ad834 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerIngressFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerIngressFluent.java @@ -1,75 +1,121 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1LoadBalancerIngressFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1LoadBalancerIngressFluent< + A extends io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getHostname(); + public A withHostname(java.lang.String hostname); + public java.lang.Boolean hasHostname(); - - /** - * Method is deprecated. use withHostname instead. - */ + + /** Method is deprecated. use withHostname instead. */ @java.lang.Deprecated public A withNewHostname(java.lang.String original); + public java.lang.String getIp(); + public A withIp(java.lang.String ip); + public java.lang.Boolean hasIp(); - - /** - * Method is deprecated. use withIp instead. - */ + + /** Method is deprecated. use withIp instead. */ @java.lang.Deprecated public A withNewIp(java.lang.String original); - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PortStatus item); - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PortStatus item); + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PortStatus item); + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PortStatus item); + public A addToPorts(io.kubernetes.client.openapi.models.V1PortStatus... items); - public A addAllToPorts(java.util.Collection items); + + public A addAllToPorts( + java.util.Collection items); + public A removeFromPorts(io.kubernetes.client.openapi.models.V1PortStatus... items); - public A removeAllFromPorts(java.util.Collection items); - public A removeMatchingFromPorts(java.util.function.Predicate predicate); - + + public A removeAllFromPorts( + java.util.Collection items); + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildPorts instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getPorts(); + public java.util.List buildPorts(); + public io.kubernetes.client.openapi.models.V1PortStatus buildPort(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PortStatus buildFirstPort(); + public io.kubernetes.client.openapi.models.V1PortStatus buildLastPort(); - public io.kubernetes.client.openapi.models.V1PortStatus buildMatchingPort(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PortStatus buildMatchingPort( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate); + public A withPorts(java.util.List ports); + public A withPorts(io.kubernetes.client.openapi.models.V1PortStatus... ports); + public java.lang.Boolean hasPorts(); - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested addNewPort(); - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1PortStatus item); - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PortStatus item); - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested editPort(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested editFirstPort(); - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested editLastPort(); - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate); - public interface PortsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PortStatusFluent>{ + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested + addNewPort(); + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested + addNewPortLike(io.kubernetes.client.openapi.models.V1PortStatus item); + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested + setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PortStatus item); + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested editPort( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested + editFirstPort(); + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested + editLastPort(); + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested + editMatchingPort( + java.util.function.Predicate + predicate); + + public interface PortsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PortStatusFluent< + io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested> { public N and(); + public N endPort(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerIngressFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerIngressFluentImpl.java index f39398cee0..75086eedb7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerIngressFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerIngressFluentImpl.java @@ -1,96 +1,169 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1LoadBalancerIngressFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent{ - public V1LoadBalancerIngressFluentImpl() { - } - public V1LoadBalancerIngressFluentImpl(io.kubernetes.client.openapi.models.V1LoadBalancerIngress instance) { +/** Generated */ +public class V1LoadBalancerIngressFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent { + public V1LoadBalancerIngressFluentImpl() {} + + public V1LoadBalancerIngressFluentImpl( + io.kubernetes.client.openapi.models.V1LoadBalancerIngress instance) { this.withHostname(instance.getHostname()); this.withIp(instance.getIp()); this.withPorts(instance.getPorts()); - } + private java.lang.String hostname; private java.lang.String ip; private java.util.ArrayList ports; + public java.lang.String getHostname() { return this.hostname; } + public A withHostname(java.lang.String hostname) { - this.hostname=hostname; return (A) this; + this.hostname = hostname; + return (A) this; } + public java.lang.Boolean hasHostname() { return this.hostname != null; } - - /** - * Method is deprecated. use withHostname instead. - */ + + /** Method is deprecated. use withHostname instead. */ @java.lang.Deprecated public A withNewHostname(java.lang.String original) { - return (A)withHostname(new String(original)); + return (A) withHostname(new String(original)); } + public java.lang.String getIp() { return this.ip; } + public A withIp(java.lang.String ip) { - this.ip=ip; return (A) this; + this.ip = ip; + return (A) this; } + public java.lang.Boolean hasIp() { return this.ip != null; } - - /** - * Method is deprecated. use withIp instead. - */ + + /** Method is deprecated. use withIp instead. */ @java.lang.Deprecated public A withNewIp(java.lang.String original) { - return (A)withIp(new String(original)); + return (A) withIp(new String(original)); } - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PortStatus item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PortStatusBuilder builder = new io.kubernetes.client.openapi.models.V1PortStatusBuilder(item);_visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder);this.ports.add(index >= 0 ? index : ports.size(), builder); return (A)this; + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PortStatus item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PortStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1PortStatusBuilder(item); + _visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder); + this.ports.add(index >= 0 ? index : ports.size(), builder); + return (A) this; } - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PortStatus item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PortStatusBuilder builder = new io.kubernetes.client.openapi.models.V1PortStatusBuilder(item); - if (index < 0 || index >= _visitables.get("ports").size()) { _visitables.get("ports").add(builder); } else { _visitables.get("ports").set(index, builder);} - if (index < 0 || index >= ports.size()) { ports.add(builder); } else { ports.set(index, builder);} - return (A)this; + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PortStatus item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PortStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1PortStatusBuilder(item); + if (index < 0 || index >= _visitables.get("ports").size()) { + _visitables.get("ports").add(builder); + } else { + _visitables.get("ports").set(index, builder); + } + if (index < 0 || index >= ports.size()) { + ports.add(builder); + } else { + ports.set(index, builder); + } + return (A) this; } + public A addToPorts(io.kubernetes.client.openapi.models.V1PortStatus... items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PortStatus item : items) {io.kubernetes.client.openapi.models.V1PortStatusBuilder builder = new io.kubernetes.client.openapi.models.V1PortStatusBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PortStatus item : items) { + io.kubernetes.client.openapi.models.V1PortStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1PortStatusBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } - public A addAllToPorts(java.util.Collection items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PortStatus item : items) {io.kubernetes.client.openapi.models.V1PortStatusBuilder builder = new io.kubernetes.client.openapi.models.V1PortStatusBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + + public A addAllToPorts( + java.util.Collection items) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PortStatus item : items) { + io.kubernetes.client.openapi.models.V1PortStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1PortStatusBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } + public A removeFromPorts(io.kubernetes.client.openapi.models.V1PortStatus... items) { - for (io.kubernetes.client.openapi.models.V1PortStatus item : items) {io.kubernetes.client.openapi.models.V1PortStatusBuilder builder = new io.kubernetes.client.openapi.models.V1PortStatusBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1PortStatus item : items) { + io.kubernetes.client.openapi.models.V1PortStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1PortStatusBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeAllFromPorts(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PortStatus item : items) {io.kubernetes.client.openapi.models.V1PortStatusBuilder builder = new io.kubernetes.client.openapi.models.V1PortStatusBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + + public A removeAllFromPorts( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PortStatus item : items) { + io.kubernetes.client.openapi.models.V1PortStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1PortStatusBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPorts(java.util.function.Predicate predicate) { + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate) { if (ports == null) return (A) this; final Iterator each = ports.iterator(); final List visitables = _visitables.get("ports"); @@ -101,106 +174,180 @@ public A removeMatchingFromPorts(java.util.function.Predicate getPorts() { return ports != null ? build(ports) : null; } + public java.util.List buildPorts() { return ports != null ? build(ports) : null; } + public io.kubernetes.client.openapi.models.V1PortStatus buildPort(java.lang.Integer index) { return this.ports.get(index).build(); } + public io.kubernetes.client.openapi.models.V1PortStatus buildFirstPort() { return this.ports.get(0).build(); } + public io.kubernetes.client.openapi.models.V1PortStatus buildLastPort() { return this.ports.get(ports.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PortStatus buildMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PortStatusBuilder item: ports) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PortStatus buildMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PortStatusBuilder item : ports) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PortStatusBuilder item: ports) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PortStatusBuilder item : ports) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withPorts(java.util.List ports) { - if (this.ports != null) { _visitables.get("ports").removeAll(this.ports);} - if (ports != null) {this.ports = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PortStatus item : ports){this.addToPorts(item);}} else { this.ports = null;} return (A) this; + if (this.ports != null) { + _visitables.get("ports").removeAll(this.ports); + } + if (ports != null) { + this.ports = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PortStatus item : ports) { + this.addToPorts(item); + } + } else { + this.ports = null; + } + return (A) this; } + public A withPorts(io.kubernetes.client.openapi.models.V1PortStatus... ports) { - if (this.ports != null) {this.ports.clear();} - if (ports != null) {for (io.kubernetes.client.openapi.models.V1PortStatus item :ports){ this.addToPorts(item);}} return (A) this; + if (this.ports != null) { + this.ports.clear(); + } + if (ports != null) { + for (io.kubernetes.client.openapi.models.V1PortStatus item : ports) { + this.addToPorts(item); + } + } + return (A) this; } + public java.lang.Boolean hasPorts() { return ports != null && !ports.isEmpty(); } - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested addNewPort() { - return new io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluentImpl.PortsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested + addNewPort() { + return new io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluentImpl + .PortsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1PortStatus item) { - return new io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluentImpl.PortsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested + addNewPortLike(io.kubernetes.client.openapi.models.V1PortStatus item) { + return new io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluentImpl.PortsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PortStatus item) { - return new io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluentImpl.PortsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested + setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PortStatus item) { + return new io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluentImpl.PortsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested editPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested editPort( + java.lang.Integer index) { if (ports.size() <= index) throw new RuntimeException("Can't edit ports. Index exceeds size."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested editFirstPort() { + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested + editFirstPort() { if (ports.size() == 0) throw new RuntimeException("Can't edit first ports. The list is empty."); return setNewPortLike(0, buildPort(0)); } - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested editLastPort() { + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested + editLastPort() { int index = ports.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ports. The list is empty."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested + editMatchingPort( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1PortStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested,io.kubernetes.client.fluent.Nested{ - PortsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PortStatus item) { + + public class PortsNestedImpl + extends io.kubernetes.client.openapi.models.V1PortStatusFluentImpl< + io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested> + implements io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent.PortsNested, + io.kubernetes.client.fluent.Nested { + PortsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PortStatus item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1PortStatusBuilder(this, item); } + PortsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PortStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1PortStatusBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1LoadBalancerIngressFluentImpl.this.setToPorts(index,builder.build()); + return (N) V1LoadBalancerIngressFluentImpl.this.setToPorts(index, builder.build()); } + public N endPort() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerStatusBuilder.java index 83ff837b45..94f46203ee 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerStatusBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LoadBalancerStatusBuilder extends io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LoadBalancerStatusBuilder + extends io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluentImpl< + io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LoadBalancerStatus, + io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder> { public V1LoadBalancerStatusBuilder() { this(false); } + public V1LoadBalancerStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1LoadBalancerStatus(), validationEnabled); } - public V1LoadBalancerStatusBuilder(io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent fluent) { + + public V1LoadBalancerStatusBuilder( + io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent fluent) { this(fluent, false); } - public V1LoadBalancerStatusBuilder(io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LoadBalancerStatusBuilder( + io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LoadBalancerStatus(), validationEnabled); } - public V1LoadBalancerStatusBuilder(io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent fluent,io.kubernetes.client.openapi.models.V1LoadBalancerStatus instance) { + + public V1LoadBalancerStatusBuilder( + io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent fluent, + io.kubernetes.client.openapi.models.V1LoadBalancerStatus instance) { this(fluent, instance, false); } - public V1LoadBalancerStatusBuilder(io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent fluent,io.kubernetes.client.openapi.models.V1LoadBalancerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LoadBalancerStatusBuilder( + io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent fluent, + io.kubernetes.client.openapi.models.V1LoadBalancerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withIngress(instance.getIngress()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1LoadBalancerStatusBuilder(io.kubernetes.client.openapi.models.V1LoadBalancerStatus instance) { - this(instance,false); + + public V1LoadBalancerStatusBuilder( + io.kubernetes.client.openapi.models.V1LoadBalancerStatus instance) { + this(instance, false); } - public V1LoadBalancerStatusBuilder(io.kubernetes.client.openapi.models.V1LoadBalancerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LoadBalancerStatusBuilder( + io.kubernetes.client.openapi.models.V1LoadBalancerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withIngress(instance.getIngress()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LoadBalancerStatus build() { V1LoadBalancerStatus buildable = new V1LoadBalancerStatus(); buildable.setIngress(fluent.getIngress()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LoadBalancerStatusBuilder that = (V1LoadBalancerStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerStatusFluent.java index 922e71d8fa..41e59e9906 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerStatusFluent.java @@ -1,57 +1,104 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1LoadBalancerStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToIngress(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LoadBalancerIngress item); - public A setToIngress(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LoadBalancerIngress item); +/** Generated */ +public interface V1LoadBalancerStatusFluent< + A extends io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToIngress( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LoadBalancerIngress item); + + public A setToIngress( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LoadBalancerIngress item); + public A addToIngress(io.kubernetes.client.openapi.models.V1LoadBalancerIngress... items); - public A addAllToIngress(java.util.Collection items); + + public A addAllToIngress( + java.util.Collection items); + public A removeFromIngress(io.kubernetes.client.openapi.models.V1LoadBalancerIngress... items); - public A removeAllFromIngress(java.util.Collection items); - public A removeMatchingFromIngress(java.util.function.Predicate predicate); - + + public A removeAllFromIngress( + java.util.Collection items); + + public A removeMatchingFromIngress( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildIngress instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getIngress(); + public java.util.List buildIngress(); - public io.kubernetes.client.openapi.models.V1LoadBalancerIngress buildIngress(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngress buildIngress( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1LoadBalancerIngress buildFirstIngress(); + public io.kubernetes.client.openapi.models.V1LoadBalancerIngress buildLastIngress(); - public io.kubernetes.client.openapi.models.V1LoadBalancerIngress buildMatchingIngress(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingIngress(java.util.function.Predicate predicate); - public A withIngress(java.util.List ingress); + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngress buildMatchingIngress( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingIngress( + java.util.function.Predicate + predicate); + + public A withIngress( + java.util.List ingress); + public A withIngress(io.kubernetes.client.openapi.models.V1LoadBalancerIngress... ingress); + public java.lang.Boolean hasIngress(); - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested addNewIngress(); - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested addNewIngressLike(io.kubernetes.client.openapi.models.V1LoadBalancerIngress item); - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested setNewIngressLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LoadBalancerIngress item); - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested editIngress(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested editFirstIngress(); - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested editLastIngress(); - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested editMatchingIngress(java.util.function.Predicate predicate); - public interface IngressNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent>{ + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + addNewIngress(); + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + addNewIngressLike(io.kubernetes.client.openapi.models.V1LoadBalancerIngress item); + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + setNewIngressLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LoadBalancerIngress item); + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + editIngress(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + editFirstIngress(); + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + editLastIngress(); + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + editMatchingIngress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder> + predicate); + + public interface IngressNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluent< + io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested> { public N and(); + public N endIngress(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerStatusFluentImpl.java index 3a74d16d6d..21c7468374 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LoadBalancerStatusFluentImpl.java @@ -1,57 +1,133 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1LoadBalancerStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent{ - public V1LoadBalancerStatusFluentImpl() { - } - public V1LoadBalancerStatusFluentImpl(io.kubernetes.client.openapi.models.V1LoadBalancerStatus instance) { - this.withIngress(instance.getIngress()); +/** Generated */ +public class V1LoadBalancerStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent { + public V1LoadBalancerStatusFluentImpl() {} + public V1LoadBalancerStatusFluentImpl( + io.kubernetes.client.openapi.models.V1LoadBalancerStatus instance) { + this.withIngress(instance.getIngress()); } - private java.util.ArrayList ingress; - public A addToIngress(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LoadBalancerIngress item) { - if (this.ingress == null) {this.ingress = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder = new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(item);_visitables.get("ingress").add(index >= 0 ? index : _visitables.get("ingress").size(), builder);this.ingress.add(index >= 0 ? index : ingress.size(), builder); return (A)this; + + private java.util.ArrayList + ingress; + + public A addToIngress( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LoadBalancerIngress item) { + if (this.ingress == null) { + this.ingress = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder>(); + } + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder = + new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(item); + _visitables.get("ingress").add(index >= 0 ? index : _visitables.get("ingress").size(), builder); + this.ingress.add(index >= 0 ? index : ingress.size(), builder); + return (A) this; } - public A setToIngress(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LoadBalancerIngress item) { - if (this.ingress == null) {this.ingress = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder = new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(item); - if (index < 0 || index >= _visitables.get("ingress").size()) { _visitables.get("ingress").add(builder); } else { _visitables.get("ingress").set(index, builder);} - if (index < 0 || index >= ingress.size()) { ingress.add(builder); } else { ingress.set(index, builder);} - return (A)this; + + public A setToIngress( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LoadBalancerIngress item) { + if (this.ingress == null) { + this.ingress = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder>(); + } + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder = + new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(item); + if (index < 0 || index >= _visitables.get("ingress").size()) { + _visitables.get("ingress").add(builder); + } else { + _visitables.get("ingress").set(index, builder); + } + if (index < 0 || index >= ingress.size()) { + ingress.add(builder); + } else { + ingress.set(index, builder); + } + return (A) this; } + public A addToIngress(io.kubernetes.client.openapi.models.V1LoadBalancerIngress... items) { - if (this.ingress == null) {this.ingress = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LoadBalancerIngress item : items) {io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder = new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(item);_visitables.get("ingress").add(builder);this.ingress.add(builder);} return (A)this; + if (this.ingress == null) { + this.ingress = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1LoadBalancerIngress item : items) { + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder = + new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(item); + _visitables.get("ingress").add(builder); + this.ingress.add(builder); + } + return (A) this; } - public A addAllToIngress(java.util.Collection items) { - if (this.ingress == null) {this.ingress = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LoadBalancerIngress item : items) {io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder = new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(item);_visitables.get("ingress").add(builder);this.ingress.add(builder);} return (A)this; + + public A addAllToIngress( + java.util.Collection items) { + if (this.ingress == null) { + this.ingress = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1LoadBalancerIngress item : items) { + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder = + new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(item); + _visitables.get("ingress").add(builder); + this.ingress.add(builder); + } + return (A) this; } + public A removeFromIngress(io.kubernetes.client.openapi.models.V1LoadBalancerIngress... items) { - for (io.kubernetes.client.openapi.models.V1LoadBalancerIngress item : items) {io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder = new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(item);_visitables.get("ingress").remove(builder);if (this.ingress != null) {this.ingress.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1LoadBalancerIngress item : items) { + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder = + new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(item); + _visitables.get("ingress").remove(builder); + if (this.ingress != null) { + this.ingress.remove(builder); + } + } + return (A) this; } - public A removeAllFromIngress(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1LoadBalancerIngress item : items) {io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder = new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(item);_visitables.get("ingress").remove(builder);if (this.ingress != null) {this.ingress.remove(builder);}} return (A)this; + + public A removeAllFromIngress( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1LoadBalancerIngress item : items) { + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder = + new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(item); + _visitables.get("ingress").remove(builder); + if (this.ingress != null) { + this.ingress.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromIngress(java.util.function.Predicate predicate) { + + public A removeMatchingFromIngress( + java.util.function.Predicate + predicate) { if (ingress == null) return (A) this; - final Iterator each = ingress.iterator(); + final Iterator each = + ingress.iterator(); final List visitables = _visitables.get("ingress"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder = each.next(); @@ -60,104 +136,184 @@ public A removeMatchingFromIngress(java.util.function.Predicate getIngress() { return ingress != null ? build(ingress) : null; } + public java.util.List buildIngress() { return ingress != null ? build(ingress) : null; } - public io.kubernetes.client.openapi.models.V1LoadBalancerIngress buildIngress(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngress buildIngress( + java.lang.Integer index) { return this.ingress.get(index).build(); } + public io.kubernetes.client.openapi.models.V1LoadBalancerIngress buildFirstIngress() { return this.ingress.get(0).build(); } + public io.kubernetes.client.openapi.models.V1LoadBalancerIngress buildLastIngress() { return this.ingress.get(ingress.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1LoadBalancerIngress buildMatchingIngress(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder item: ingress) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1LoadBalancerIngress buildMatchingIngress( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder item : ingress) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingIngress(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder item: ingress) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingIngress( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder item : ingress) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withIngress(java.util.List ingress) { - if (this.ingress != null) { _visitables.get("ingress").removeAll(this.ingress);} - if (ingress != null) {this.ingress = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1LoadBalancerIngress item : ingress){this.addToIngress(item);}} else { this.ingress = null;} return (A) this; + + public A withIngress( + java.util.List ingress) { + if (this.ingress != null) { + _visitables.get("ingress").removeAll(this.ingress); + } + if (ingress != null) { + this.ingress = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1LoadBalancerIngress item : ingress) { + this.addToIngress(item); + } + } else { + this.ingress = null; + } + return (A) this; } + public A withIngress(io.kubernetes.client.openapi.models.V1LoadBalancerIngress... ingress) { - if (this.ingress != null) {this.ingress.clear();} - if (ingress != null) {for (io.kubernetes.client.openapi.models.V1LoadBalancerIngress item :ingress){ this.addToIngress(item);}} return (A) this; + if (this.ingress != null) { + this.ingress.clear(); + } + if (ingress != null) { + for (io.kubernetes.client.openapi.models.V1LoadBalancerIngress item : ingress) { + this.addToIngress(item); + } + } + return (A) this; } + public java.lang.Boolean hasIngress() { return ingress != null && !ingress.isEmpty(); } - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested addNewIngress() { - return new io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluentImpl.IngressNestedImpl(); + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + addNewIngress() { + return new io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluentImpl + .IngressNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested addNewIngressLike(io.kubernetes.client.openapi.models.V1LoadBalancerIngress item) { - return new io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluentImpl.IngressNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + addNewIngressLike(io.kubernetes.client.openapi.models.V1LoadBalancerIngress item) { + return new io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluentImpl.IngressNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested setNewIngressLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LoadBalancerIngress item) { - return new io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluentImpl.IngressNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + setNewIngressLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LoadBalancerIngress item) { + return new io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluentImpl.IngressNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested editIngress(java.lang.Integer index) { - if (ingress.size() <= index) throw new RuntimeException("Can't edit ingress. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + editIngress(java.lang.Integer index) { + if (ingress.size() <= index) + throw new RuntimeException("Can't edit ingress. Index exceeds size."); return setNewIngressLike(index, buildIngress(index)); } - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested editFirstIngress() { - if (ingress.size() == 0) throw new RuntimeException("Can't edit first ingress. The list is empty."); + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + editFirstIngress() { + if (ingress.size() == 0) + throw new RuntimeException("Can't edit first ingress. The list is empty."); return setNewIngressLike(0, buildIngress(0)); } - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested editLastIngress() { + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + editLastIngress() { int index = ingress.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ingress. The list is empty."); return setNewIngressLike(index, buildIngress(index)); } - public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested editMatchingIngress(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested + editMatchingIngress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluentImpl> implements io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested,io.kubernetes.client.fluent.Nested{ - IngressNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LoadBalancerIngress item) { + + public class IngressNestedImpl + extends io.kubernetes.client.openapi.models.V1LoadBalancerIngressFluentImpl< + io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested> + implements io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent.IngressNested, + io.kubernetes.client.fluent.Nested { + IngressNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LoadBalancerIngress item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(this, item); } + IngressNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder(this); } + io.kubernetes.client.openapi.models.V1LoadBalancerIngressBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1LoadBalancerStatusFluentImpl.this.setToIngress(index,builder.build()); + return (N) V1LoadBalancerStatusFluentImpl.this.setToIngress(index, builder.build()); } + public N endIngress() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalObjectReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalObjectReferenceBuilder.java index 42f7331d57..0764fea8af 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalObjectReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalObjectReferenceBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LocalObjectReferenceBuilder extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LocalObjectReferenceBuilder + extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LocalObjectReference, + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> { public V1LocalObjectReferenceBuilder() { this(false); } + public V1LocalObjectReferenceBuilder(java.lang.Boolean validationEnabled) { this(new V1LocalObjectReference(), validationEnabled); } - public V1LocalObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent fluent) { + + public V1LocalObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent fluent) { this(fluent, false); } - public V1LocalObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LocalObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LocalObjectReference(), validationEnabled); } - public V1LocalObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V1LocalObjectReference instance) { + + public V1LocalObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1LocalObjectReference instance) { this(fluent, instance, false); } - public V1LocalObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V1LocalObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LocalObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1LocalObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1LocalObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1LocalObjectReference instance) { - this(instance,false); + + public V1LocalObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1LocalObjectReference instance) { + this(instance, false); } - public V1LocalObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1LocalObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LocalObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1LocalObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LocalObjectReference build() { V1LocalObjectReference buildable = new V1LocalObjectReference(); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LocalObjectReferenceBuilder that = (V1LocalObjectReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalObjectReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalObjectReferenceFluent.java index 7b362b06ec..d065476830 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalObjectReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalObjectReferenceFluent.java @@ -1,23 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1LocalObjectReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1LocalObjectReferenceFluent< + A extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalObjectReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalObjectReferenceFluentImpl.java index f88dfcee2b..1232c7e910 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalObjectReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalObjectReferenceFluentImpl.java @@ -1,48 +1,59 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1LocalObjectReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent{ - public V1LocalObjectReferenceFluentImpl() { - } - public V1LocalObjectReferenceFluentImpl(io.kubernetes.client.openapi.models.V1LocalObjectReference instance) { - this.withName(instance.getName()); +/** Generated */ +public class V1LocalObjectReferenceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent { + public V1LocalObjectReferenceFluentImpl() {} + public V1LocalObjectReferenceFluentImpl( + io.kubernetes.client.openapi.models.V1LocalObjectReference instance) { + this.withName(instance.getName()); } + private java.lang.String name; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1LocalObjectReferenceFluentImpl that = (V1LocalObjectReferenceFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, super.hashCode()); + return java.util.Objects.hash(name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalSubjectAccessReviewBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalSubjectAccessReviewBuilder.java index 0263d82b45..71dc40d9f5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalSubjectAccessReviewBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalSubjectAccessReviewBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LocalSubjectAccessReviewBuilder extends io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LocalSubjectAccessReviewBuilder + extends io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl< + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReview, + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewBuilder> { public V1LocalSubjectAccessReviewBuilder() { this(false); } + public V1LocalSubjectAccessReviewBuilder(java.lang.Boolean validationEnabled) { this(new V1LocalSubjectAccessReview(), validationEnabled); } - public V1LocalSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent fluent) { + + public V1LocalSubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent fluent) { this(fluent, false); } - public V1LocalSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LocalSubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LocalSubjectAccessReview(), validationEnabled); } - public V1LocalSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent fluent,io.kubernetes.client.openapi.models.V1LocalSubjectAccessReview instance) { + + public V1LocalSubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent fluent, + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReview instance) { this(fluent, instance, false); } - public V1LocalSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent fluent,io.kubernetes.client.openapi.models.V1LocalSubjectAccessReview instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LocalSubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent fluent, + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReview instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1LocalSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1L fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1LocalSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1LocalSubjectAccessReview instance) { - this(instance,false); + + public V1LocalSubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReview instance) { + this(instance, false); } - public V1LocalSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1LocalSubjectAccessReview instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LocalSubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReview instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1LocalSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1L this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReview build() { V1LocalSubjectAccessReview buildable = new V1LocalSubjectAccessReview(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReview build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LocalSubjectAccessReviewBuilder that = (V1LocalSubjectAccessReviewBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalSubjectAccessReviewFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalSubjectAccessReviewFluent.java index 062348c540..286de7bcc7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalSubjectAccessReviewFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalSubjectAccessReviewFluent.java @@ -1,93 +1,154 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1LocalSubjectAccessReviewFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1LocalSubjectAccessReviewFluent< + A extends io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec getSpec(); + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item); - + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus getStatus(); + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent< + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent< + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested< + N>> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalSubjectAccessReviewFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalSubjectAccessReviewFluentImpl.java index 3083c29ab2..81240add77 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalSubjectAccessReviewFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalSubjectAccessReviewFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1LocalSubjectAccessReviewFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent { + public V1LocalSubjectAccessReviewFluentImpl() {} - /** - * Generated - */ -public class V1LocalSubjectAccessReviewFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent{ - public V1LocalSubjectAccessReviewFluentImpl() { - } - public V1LocalSubjectAccessReviewFluentImpl(io.kubernetes.client.openapi.models.V1LocalSubjectAccessReview instance) { + public V1LocalSubjectAccessReviewFluentImpl( + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReview instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,316 @@ public V1LocalSubjectAccessReviewFluentImpl(io.kubernetes.client.openapi.models. this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder spec; private io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item) { - return new io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item) { + return new io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { - return new io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { + return new io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1LocalSubjectAccessReviewFluentImpl that = (V1LocalSubjectAccessReviewFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1LocalSubjectAccessReviewFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl< + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder builder; + public N and() { return (N) V1LocalSubjectAccessReviewFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluentImpl< + io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1LocalSubjectAccessReviewFluent.StatusNested< + N>, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder builder; + public N and() { return (N) V1LocalSubjectAccessReviewFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalVolumeSourceBuilder.java index d1bc55455d..78f15fe93d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalVolumeSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1LocalVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1LocalVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1LocalVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1LocalVolumeSource, + io.kubernetes.client.openapi.models.V1LocalVolumeSourceBuilder> { public V1LocalVolumeSourceBuilder() { this(false); } + public V1LocalVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1LocalVolumeSource(), validationEnabled); } - public V1LocalVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent fluent) { + + public V1LocalVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent fluent) { this(fluent, false); } - public V1LocalVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1LocalVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1LocalVolumeSource(), validationEnabled); } - public V1LocalVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1LocalVolumeSource instance) { + + public V1LocalVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1LocalVolumeSource instance) { this(fluent, instance, false); } - public V1LocalVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1LocalVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1LocalVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1LocalVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withPath(instance.getPath()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1LocalVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1LocalVolumeSource instance) { - this(instance,false); + + public V1LocalVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1LocalVolumeSource instance) { + this(instance, false); } - public V1LocalVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1LocalVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1LocalVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1LocalVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withPath(instance.getPath()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1LocalVolumeSource build() { V1LocalVolumeSource buildable = new V1LocalVolumeSource(); buildable.setFsType(fluent.getFsType()); buildable.setPath(fluent.getPath()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1LocalVolumeSourceBuilder that = (V1LocalVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalVolumeSourceFluent.java index a5b57ced4b..ece888d193 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalVolumeSourceFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1LocalVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1LocalVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalVolumeSourceFluentImpl.java index 550fc574ba..94c6568c5a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1LocalVolumeSourceFluentImpl.java @@ -1,69 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1LocalVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent { + public V1LocalVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1LocalVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent{ - public V1LocalVolumeSourceFluentImpl() { - } - public V1LocalVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1LocalVolumeSource instance) { + public V1LocalVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1LocalVolumeSource instance) { this.withFsType(instance.getFsType()); this.withPath(instance.getPath()); - } + private java.lang.String fsType; private java.lang.String path; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1LocalVolumeSourceFluentImpl that = (V1LocalVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (path != null ? !path.equals(that.path) :that.path != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, path, super.hashCode()); + return java.util.Objects.hash(fsType, path, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ManagedFieldsEntryBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ManagedFieldsEntryBuilder.java index c19d476591..8f5e6f7a46 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ManagedFieldsEntryBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ManagedFieldsEntryBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ManagedFieldsEntryBuilder extends io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ManagedFieldsEntryBuilder + extends io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluentImpl< + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ManagedFieldsEntry, + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder> { public V1ManagedFieldsEntryBuilder() { this(false); } + public V1ManagedFieldsEntryBuilder(java.lang.Boolean validationEnabled) { this(new V1ManagedFieldsEntry(), validationEnabled); } - public V1ManagedFieldsEntryBuilder(io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent fluent) { + + public V1ManagedFieldsEntryBuilder( + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent fluent) { this(fluent, false); } - public V1ManagedFieldsEntryBuilder(io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ManagedFieldsEntryBuilder( + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ManagedFieldsEntry(), validationEnabled); } - public V1ManagedFieldsEntryBuilder(io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent fluent,io.kubernetes.client.openapi.models.V1ManagedFieldsEntry instance) { + + public V1ManagedFieldsEntryBuilder( + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent fluent, + io.kubernetes.client.openapi.models.V1ManagedFieldsEntry instance) { this(fluent, instance, false); } - public V1ManagedFieldsEntryBuilder(io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent fluent,io.kubernetes.client.openapi.models.V1ManagedFieldsEntry instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ManagedFieldsEntryBuilder( + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent fluent, + io.kubernetes.client.openapi.models.V1ManagedFieldsEntry instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withFieldsType(instance.getFieldsType()); @@ -35,13 +62,18 @@ public V1ManagedFieldsEntryBuilder(io.kubernetes.client.openapi.models.V1Managed fluent.withTime(instance.getTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ManagedFieldsEntryBuilder(io.kubernetes.client.openapi.models.V1ManagedFieldsEntry instance) { - this(instance,false); + + public V1ManagedFieldsEntryBuilder( + io.kubernetes.client.openapi.models.V1ManagedFieldsEntry instance) { + this(instance, false); } - public V1ManagedFieldsEntryBuilder(io.kubernetes.client.openapi.models.V1ManagedFieldsEntry instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ManagedFieldsEntryBuilder( + io.kubernetes.client.openapi.models.V1ManagedFieldsEntry instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withFieldsType(instance.getFieldsType()); @@ -56,10 +88,12 @@ public V1ManagedFieldsEntryBuilder(io.kubernetes.client.openapi.models.V1Managed this.withTime(instance.getTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry build() { V1ManagedFieldsEntry buildable = new V1ManagedFieldsEntry(); buildable.setApiVersion(fluent.getApiVersion()); @@ -71,18 +105,23 @@ public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry build() { buildable.setTime(fluent.getTime()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ManagedFieldsEntryBuilder that = (V1ManagedFieldsEntryBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ManagedFieldsEntryFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ManagedFieldsEntryFluent.java index 36130de337..8e94c4ee1c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ManagedFieldsEntryFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ManagedFieldsEntryFluent.java @@ -1,67 +1,80 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ManagedFieldsEntryFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ManagedFieldsEntryFluent< + A extends io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getFieldsType(); + public A withFieldsType(java.lang.String fieldsType); + public java.lang.Boolean hasFieldsType(); - - /** - * Method is deprecated. use withFieldsType instead. - */ + + /** Method is deprecated. use withFieldsType instead. */ @java.lang.Deprecated public A withNewFieldsType(java.lang.String original); + public java.lang.Object getFieldsV1(); + public A withFieldsV1(java.lang.Object fieldsV1); + public java.lang.Boolean hasFieldsV1(); + public java.lang.String getManager(); + public A withManager(java.lang.String manager); + public java.lang.Boolean hasManager(); - - /** - * Method is deprecated. use withManager instead. - */ + + /** Method is deprecated. use withManager instead. */ @java.lang.Deprecated public A withNewManager(java.lang.String original); + public java.lang.String getOperation(); + public A withOperation(java.lang.String operation); + public java.lang.Boolean hasOperation(); - - /** - * Method is deprecated. use withOperation instead. - */ + + /** Method is deprecated. use withOperation instead. */ @java.lang.Deprecated public A withNewOperation(java.lang.String original); + public java.lang.String getSubresource(); + public A withSubresource(java.lang.String subresource); + public java.lang.Boolean hasSubresource(); - - /** - * Method is deprecated. use withSubresource instead. - */ + + /** Method is deprecated. use withSubresource instead. */ @java.lang.Deprecated public A withNewSubresource(java.lang.String original); + public java.time.OffsetDateTime getTime(); + public A withTime(java.time.OffsetDateTime time); + public java.lang.Boolean hasTime(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ManagedFieldsEntryFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ManagedFieldsEntryFluentImpl.java index 6f18ccba97..d88224d8ca 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ManagedFieldsEntryFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ManagedFieldsEntryFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ManagedFieldsEntryFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent { + public V1ManagedFieldsEntryFluentImpl() {} - /** - * Generated - */ -public class V1ManagedFieldsEntryFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent{ - public V1ManagedFieldsEntryFluentImpl() { - } - public V1ManagedFieldsEntryFluentImpl(io.kubernetes.client.openapi.models.V1ManagedFieldsEntry instance) { + public V1ManagedFieldsEntryFluentImpl( + io.kubernetes.client.openapi.models.V1ManagedFieldsEntry instance) { this.withApiVersion(instance.getApiVersion()); this.withFieldsType(instance.getFieldsType()); @@ -27,8 +34,8 @@ public V1ManagedFieldsEntryFluentImpl(io.kubernetes.client.openapi.models.V1Mana this.withSubresource(instance.getSubresource()); this.withTime(instance.getTime()); - } + private java.lang.String apiVersion; private java.lang.String fieldsType; private java.lang.Object fieldsV1; @@ -36,124 +43,148 @@ public V1ManagedFieldsEntryFluentImpl(io.kubernetes.client.openapi.models.V1Mana private java.lang.String operation; private java.lang.String subresource; private java.time.OffsetDateTime time; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getFieldsType() { return this.fieldsType; } + public A withFieldsType(java.lang.String fieldsType) { - this.fieldsType=fieldsType; return (A) this; + this.fieldsType = fieldsType; + return (A) this; } + public java.lang.Boolean hasFieldsType() { return this.fieldsType != null; } - - /** - * Method is deprecated. use withFieldsType instead. - */ + + /** Method is deprecated. use withFieldsType instead. */ @java.lang.Deprecated public A withNewFieldsType(java.lang.String original) { - return (A)withFieldsType(new String(original)); + return (A) withFieldsType(new String(original)); } + public java.lang.Object getFieldsV1() { return this.fieldsV1; } + public A withFieldsV1(java.lang.Object fieldsV1) { - this.fieldsV1=fieldsV1; return (A) this; + this.fieldsV1 = fieldsV1; + return (A) this; } + public java.lang.Boolean hasFieldsV1() { return this.fieldsV1 != null; } + public java.lang.String getManager() { return this.manager; } + public A withManager(java.lang.String manager) { - this.manager=manager; return (A) this; + this.manager = manager; + return (A) this; } + public java.lang.Boolean hasManager() { return this.manager != null; } - - /** - * Method is deprecated. use withManager instead. - */ + + /** Method is deprecated. use withManager instead. */ @java.lang.Deprecated public A withNewManager(java.lang.String original) { - return (A)withManager(new String(original)); + return (A) withManager(new String(original)); } + public java.lang.String getOperation() { return this.operation; } + public A withOperation(java.lang.String operation) { - this.operation=operation; return (A) this; + this.operation = operation; + return (A) this; } + public java.lang.Boolean hasOperation() { return this.operation != null; } - - /** - * Method is deprecated. use withOperation instead. - */ + + /** Method is deprecated. use withOperation instead. */ @java.lang.Deprecated public A withNewOperation(java.lang.String original) { - return (A)withOperation(new String(original)); + return (A) withOperation(new String(original)); } + public java.lang.String getSubresource() { return this.subresource; } + public A withSubresource(java.lang.String subresource) { - this.subresource=subresource; return (A) this; + this.subresource = subresource; + return (A) this; } + public java.lang.Boolean hasSubresource() { return this.subresource != null; } - - /** - * Method is deprecated. use withSubresource instead. - */ + + /** Method is deprecated. use withSubresource instead. */ @java.lang.Deprecated public A withNewSubresource(java.lang.String original) { - return (A)withSubresource(new String(original)); + return (A) withSubresource(new String(original)); } + public java.time.OffsetDateTime getTime() { return this.time; } + public A withTime(java.time.OffsetDateTime time) { - this.time=time; return (A) this; + this.time = time; + return (A) this; } + public java.lang.Boolean hasTime() { return this.time != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ManagedFieldsEntryFluentImpl that = (V1ManagedFieldsEntryFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (fieldsType != null ? !fieldsType.equals(that.fieldsType) :that.fieldsType != null) return false; - if (fieldsV1 != null ? !fieldsV1.equals(that.fieldsV1) :that.fieldsV1 != null) return false; - if (manager != null ? !manager.equals(that.manager) :that.manager != null) return false; - if (operation != null ? !operation.equals(that.operation) :that.operation != null) return false; - if (subresource != null ? !subresource.equals(that.subresource) :that.subresource != null) return false; - if (time != null ? !time.equals(that.time) :that.time != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (fieldsType != null ? !fieldsType.equals(that.fieldsType) : that.fieldsType != null) + return false; + if (fieldsV1 != null ? !fieldsV1.equals(that.fieldsV1) : that.fieldsV1 != null) return false; + if (manager != null ? !manager.equals(that.manager) : that.manager != null) return false; + if (operation != null ? !operation.equals(that.operation) : that.operation != null) + return false; + if (subresource != null ? !subresource.equals(that.subresource) : that.subresource != null) + return false; + if (time != null ? !time.equals(that.time) : that.time != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, fieldsType, fieldsV1, manager, operation, subresource, time, super.hashCode()); + return java.util.Objects.hash( + apiVersion, fieldsType, fieldsV1, manager, operation, subresource, time, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookBuilder.java index 2387ee58d3..1616cf820f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1MutatingWebhookBuilder extends io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1MutatingWebhookBuilder + extends io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl< + io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1MutatingWebhook, + io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder> { public V1MutatingWebhookBuilder() { this(false); } + public V1MutatingWebhookBuilder(java.lang.Boolean validationEnabled) { this(new V1MutatingWebhook(), validationEnabled); } - public V1MutatingWebhookBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookFluent fluent) { + + public V1MutatingWebhookBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent fluent) { this(fluent, false); } - public V1MutatingWebhookBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookFluent fluent,java.lang.Boolean validationEnabled) { + + public V1MutatingWebhookBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1MutatingWebhook(), validationEnabled); } - public V1MutatingWebhookBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookFluent fluent,io.kubernetes.client.openapi.models.V1MutatingWebhook instance) { + + public V1MutatingWebhookBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent fluent, + io.kubernetes.client.openapi.models.V1MutatingWebhook instance) { this(fluent, instance, false); } - public V1MutatingWebhookBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookFluent fluent,io.kubernetes.client.openapi.models.V1MutatingWebhook instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1MutatingWebhookBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent fluent, + io.kubernetes.client.openapi.models.V1MutatingWebhook instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAdmissionReviewVersions(instance.getAdmissionReviewVersions()); fluent.withClientConfig(instance.getClientConfig()); @@ -43,13 +70,17 @@ public V1MutatingWebhookBuilder(io.kubernetes.client.openapi.models.V1MutatingWe fluent.withTimeoutSeconds(instance.getTimeoutSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1MutatingWebhookBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhook instance) { - this(instance,false); + this(instance, false); } - public V1MutatingWebhookBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhook instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1MutatingWebhookBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhook instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAdmissionReviewVersions(instance.getAdmissionReviewVersions()); this.withClientConfig(instance.getClientConfig()); @@ -72,10 +103,12 @@ public V1MutatingWebhookBuilder(io.kubernetes.client.openapi.models.V1MutatingWe this.withTimeoutSeconds(instance.getTimeoutSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1MutatingWebhook build() { V1MutatingWebhook buildable = new V1MutatingWebhook(); buildable.setAdmissionReviewVersions(fluent.getAdmissionReviewVersions()); @@ -91,18 +124,23 @@ public io.kubernetes.client.openapi.models.V1MutatingWebhook build() { buildable.setTimeoutSeconds(fluent.getTimeoutSeconds()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1MutatingWebhookBuilder that = (V1MutatingWebhookBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationBuilder.java index 7b8f7ec6ce..fe1a72e9c5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1MutatingWebhookConfigurationBuilder extends io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1MutatingWebhookConfigurationBuilder + extends io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder> { public V1MutatingWebhookConfigurationBuilder() { this(false); } + public V1MutatingWebhookConfigurationBuilder(java.lang.Boolean validationEnabled) { this(new V1MutatingWebhookConfiguration(), validationEnabled); } - public V1MutatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent fluent) { + + public V1MutatingWebhookConfigurationBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent fluent) { this(fluent, false); } - public V1MutatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent fluent,java.lang.Boolean validationEnabled) { + + public V1MutatingWebhookConfigurationBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1MutatingWebhookConfiguration(), validationEnabled); } - public V1MutatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration instance) { + + public V1MutatingWebhookConfigurationBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration instance) { this(fluent, instance, false); } - public V1MutatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1MutatingWebhookConfigurationBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +56,18 @@ public V1MutatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models fluent.withWebhooks(instance.getWebhooks()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1MutatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration instance) { - this(instance,false); + + public V1MutatingWebhookConfigurationBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration instance) { + this(instance, false); } - public V1MutatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1MutatingWebhookConfigurationBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +76,12 @@ public V1MutatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models this.withWebhooks(instance.getWebhooks()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration build() { V1MutatingWebhookConfiguration buildable = new V1MutatingWebhookConfiguration(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration build( buildable.setWebhooks(fluent.getWebhooks()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1MutatingWebhookConfigurationBuilder that = (V1MutatingWebhookConfigurationBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationFluent.java index 89967e2d52..4b66ac4dd6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationFluent.java @@ -1,95 +1,165 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1MutatingWebhookConfigurationFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1MutatingWebhookConfigurationFluent< + A extends io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public A addToWebhooks(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhook item); - public A setToWebhooks(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhook item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public A addToWebhooks( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1MutatingWebhook item); + + public A setToWebhooks( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1MutatingWebhook item); + public A addToWebhooks(io.kubernetes.client.openapi.models.V1MutatingWebhook... items); - public A addAllToWebhooks(java.util.Collection items); + + public A addAllToWebhooks( + java.util.Collection items); + public A removeFromWebhooks(io.kubernetes.client.openapi.models.V1MutatingWebhook... items); - public A removeAllFromWebhooks(java.util.Collection items); - public A removeMatchingFromWebhooks(java.util.function.Predicate predicate); - + + public A removeAllFromWebhooks( + java.util.Collection items); + + public A removeMatchingFromWebhooks( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildWebhooks instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getWebhooks(); + public java.util.List buildWebhooks(); - public io.kubernetes.client.openapi.models.V1MutatingWebhook buildWebhook(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1MutatingWebhook buildWebhook( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1MutatingWebhook buildFirstWebhook(); + public io.kubernetes.client.openapi.models.V1MutatingWebhook buildLastWebhook(); - public io.kubernetes.client.openapi.models.V1MutatingWebhook buildMatchingWebhook(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingWebhook(java.util.function.Predicate predicate); - public A withWebhooks(java.util.List webhooks); + + public io.kubernetes.client.openapi.models.V1MutatingWebhook buildMatchingWebhook( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingWebhook( + java.util.function.Predicate + predicate); + + public A withWebhooks( + java.util.List webhooks); + public A withWebhooks(io.kubernetes.client.openapi.models.V1MutatingWebhook... webhooks); + public java.lang.Boolean hasWebhooks(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested addNewWebhook(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested addNewWebhookLike(io.kubernetes.client.openapi.models.V1MutatingWebhook item); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested setNewWebhookLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhook item); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested editWebhook(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested editFirstWebhook(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested editLastWebhook(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested editMatchingWebhook(java.util.function.Predicate predicate); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + addNewWebhook(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + addNewWebhookLike(io.kubernetes.client.openapi.models.V1MutatingWebhook item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + setNewWebhookLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1MutatingWebhook item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + editWebhook(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + editFirstWebhook(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + editLastWebhook(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + editMatchingWebhook( + java.util.function.Predicate + predicate); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface WebhooksNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1MutatingWebhookFluent>{ + + public interface WebhooksNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent + .WebhooksNested< + N>> { public N and(); + public N endWebhook(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationFluentImpl.java index 731cc529cc..f7a70e4634 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1MutatingWebhookConfigurationFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent{ - public V1MutatingWebhookConfigurationFluentImpl() { - } - public V1MutatingWebhookConfigurationFluentImpl(io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration instance) { + +/** Generated */ +public class V1MutatingWebhookConfigurationFluentImpl< + A extends io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent { + public V1MutatingWebhookConfigurationFluentImpl() {} + + public V1MutatingWebhookConfigurationFluentImpl( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -28,108 +31,205 @@ public V1MutatingWebhookConfigurationFluentImpl(io.kubernetes.client.openapi.mod this.withMetadata(instance.getMetadata()); this.withWebhooks(instance.getWebhooks()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; - private java.util.ArrayList webhooks; + private java.util.ArrayList + webhooks; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - public A addToWebhooks(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhook item) { - if (this.webhooks == null) {this.webhooks = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(item);_visitables.get("webhooks").add(index >= 0 ? index : _visitables.get("webhooks").size(), builder);this.webhooks.add(index >= 0 ? index : webhooks.size(), builder); return (A)this; + + public A addToWebhooks( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1MutatingWebhook item) { + if (this.webhooks == null) { + this.webhooks = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(item); + _visitables + .get("webhooks") + .add(index >= 0 ? index : _visitables.get("webhooks").size(), builder); + this.webhooks.add(index >= 0 ? index : webhooks.size(), builder); + return (A) this; } - public A setToWebhooks(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhook item) { - if (this.webhooks == null) {this.webhooks = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(item); - if (index < 0 || index >= _visitables.get("webhooks").size()) { _visitables.get("webhooks").add(builder); } else { _visitables.get("webhooks").set(index, builder);} - if (index < 0 || index >= webhooks.size()) { webhooks.add(builder); } else { webhooks.set(index, builder);} - return (A)this; + + public A setToWebhooks( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1MutatingWebhook item) { + if (this.webhooks == null) { + this.webhooks = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(item); + if (index < 0 || index >= _visitables.get("webhooks").size()) { + _visitables.get("webhooks").add(builder); + } else { + _visitables.get("webhooks").set(index, builder); + } + if (index < 0 || index >= webhooks.size()) { + webhooks.add(builder); + } else { + webhooks.set(index, builder); + } + return (A) this; } + public A addToWebhooks(io.kubernetes.client.openapi.models.V1MutatingWebhook... items) { - if (this.webhooks == null) {this.webhooks = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1MutatingWebhook item : items) {io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(item);_visitables.get("webhooks").add(builder);this.webhooks.add(builder);} return (A)this; + if (this.webhooks == null) { + this.webhooks = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1MutatingWebhook item : items) { + io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(item); + _visitables.get("webhooks").add(builder); + this.webhooks.add(builder); + } + return (A) this; } - public A addAllToWebhooks(java.util.Collection items) { - if (this.webhooks == null) {this.webhooks = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1MutatingWebhook item : items) {io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(item);_visitables.get("webhooks").add(builder);this.webhooks.add(builder);} return (A)this; + + public A addAllToWebhooks( + java.util.Collection items) { + if (this.webhooks == null) { + this.webhooks = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1MutatingWebhook item : items) { + io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(item); + _visitables.get("webhooks").add(builder); + this.webhooks.add(builder); + } + return (A) this; } + public A removeFromWebhooks(io.kubernetes.client.openapi.models.V1MutatingWebhook... items) { - for (io.kubernetes.client.openapi.models.V1MutatingWebhook item : items) {io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(item);_visitables.get("webhooks").remove(builder);if (this.webhooks != null) {this.webhooks.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1MutatingWebhook item : items) { + io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(item); + _visitables.get("webhooks").remove(builder); + if (this.webhooks != null) { + this.webhooks.remove(builder); + } + } + return (A) this; } - public A removeAllFromWebhooks(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1MutatingWebhook item : items) {io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(item);_visitables.get("webhooks").remove(builder);if (this.webhooks != null) {this.webhooks.remove(builder);}} return (A)this; + + public A removeAllFromWebhooks( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1MutatingWebhook item : items) { + io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(item); + _visitables.get("webhooks").remove(builder); + if (this.webhooks != null) { + this.webhooks.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromWebhooks(java.util.function.Predicate predicate) { + + public A removeMatchingFromWebhooks( + java.util.function.Predicate + predicate) { if (webhooks == null) return (A) this; - final Iterator each = webhooks.iterator(); + final Iterator each = + webhooks.iterator(); final List visitables = _visitables.get("webhooks"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder = each.next(); @@ -138,123 +238,217 @@ public A removeMatchingFromWebhooks(java.util.function.Predicate getWebhooks() { return webhooks != null ? build(webhooks) : null; } + public java.util.List buildWebhooks() { return webhooks != null ? build(webhooks) : null; } - public io.kubernetes.client.openapi.models.V1MutatingWebhook buildWebhook(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1MutatingWebhook buildWebhook( + java.lang.Integer index) { return this.webhooks.get(index).build(); } + public io.kubernetes.client.openapi.models.V1MutatingWebhook buildFirstWebhook() { return this.webhooks.get(0).build(); } + public io.kubernetes.client.openapi.models.V1MutatingWebhook buildLastWebhook() { return this.webhooks.get(webhooks.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1MutatingWebhook buildMatchingWebhook(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder item: webhooks) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1MutatingWebhook buildMatchingWebhook( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder item : webhooks) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingWebhook(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder item: webhooks) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingWebhook( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder item : webhooks) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withWebhooks(java.util.List webhooks) { - if (this.webhooks != null) { _visitables.get("webhooks").removeAll(this.webhooks);} - if (webhooks != null) {this.webhooks = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1MutatingWebhook item : webhooks){this.addToWebhooks(item);}} else { this.webhooks = null;} return (A) this; + + public A withWebhooks( + java.util.List webhooks) { + if (this.webhooks != null) { + _visitables.get("webhooks").removeAll(this.webhooks); + } + if (webhooks != null) { + this.webhooks = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1MutatingWebhook item : webhooks) { + this.addToWebhooks(item); + } + } else { + this.webhooks = null; + } + return (A) this; } + public A withWebhooks(io.kubernetes.client.openapi.models.V1MutatingWebhook... webhooks) { - if (this.webhooks != null) {this.webhooks.clear();} - if (webhooks != null) {for (io.kubernetes.client.openapi.models.V1MutatingWebhook item :webhooks){ this.addToWebhooks(item);}} return (A) this; + if (this.webhooks != null) { + this.webhooks.clear(); + } + if (webhooks != null) { + for (io.kubernetes.client.openapi.models.V1MutatingWebhook item : webhooks) { + this.addToWebhooks(item); + } + } + return (A) this; } + public java.lang.Boolean hasWebhooks() { return webhooks != null && !webhooks.isEmpty(); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested addNewWebhook() { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl.WebhooksNestedImpl(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + addNewWebhook() { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl + .WebhooksNestedImpl(); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested addNewWebhookLike(io.kubernetes.client.openapi.models.V1MutatingWebhook item) { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl.WebhooksNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + addNewWebhookLike(io.kubernetes.client.openapi.models.V1MutatingWebhook item) { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl + .WebhooksNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested setNewWebhookLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhook item) { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl.WebhooksNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + setNewWebhookLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1MutatingWebhook item) { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl + .WebhooksNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested editWebhook(java.lang.Integer index) { - if (webhooks.size() <= index) throw new RuntimeException("Can't edit webhooks. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + editWebhook(java.lang.Integer index) { + if (webhooks.size() <= index) + throw new RuntimeException("Can't edit webhooks. Index exceeds size."); return setNewWebhookLike(index, buildWebhook(index)); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested editFirstWebhook() { - if (webhooks.size() == 0) throw new RuntimeException("Can't edit first webhooks. The list is empty."); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + editFirstWebhook() { + if (webhooks.size() == 0) + throw new RuntimeException("Can't edit first webhooks. The list is empty."); return setNewWebhookLike(0, buildWebhook(0)); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested editLastWebhook() { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + editLastWebhook() { int index = webhooks.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last webhooks. The list is empty."); return setNewWebhookLike(index, buildWebhook(index)); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested editMatchingWebhook(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested + editMatchingWebhook( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1MutatingWebhookConfigurationFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class WebhooksNestedImpl extends io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl> implements io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested,io.kubernetes.client.fluent.Nested{ - WebhooksNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhook item) { + + public class WebhooksNestedImpl + extends io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent.WebhooksNested< + N>> + implements io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent + .WebhooksNested< + N>, + io.kubernetes.client.fluent.Nested { + WebhooksNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1MutatingWebhook item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(this, item); } + WebhooksNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder(this); } + io.kubernetes.client.openapi.models.V1MutatingWebhookBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1MutatingWebhookConfigurationFluentImpl.this.setToWebhooks(index,builder.build()); + return (N) + V1MutatingWebhookConfigurationFluentImpl.this.setToWebhooks(index, builder.build()); } + public N endWebhook() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationListBuilder.java index 17bd093e0e..f3605d15a7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1MutatingWebhookConfigurationListBuilder extends io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1MutatingWebhookConfigurationListBuilder + extends io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluentImpl< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationList, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListBuilder> { public V1MutatingWebhookConfigurationListBuilder() { this(false); } + public V1MutatingWebhookConfigurationListBuilder(java.lang.Boolean validationEnabled) { this(new V1MutatingWebhookConfigurationList(), validationEnabled); } - public V1MutatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent fluent) { + + public V1MutatingWebhookConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent fluent) { this(fluent, false); } - public V1MutatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1MutatingWebhookConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1MutatingWebhookConfigurationList(), validationEnabled); } - public V1MutatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent fluent,io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationList instance) { + + public V1MutatingWebhookConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent fluent, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationList instance) { this(fluent, instance, false); } - public V1MutatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent fluent,io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1MutatingWebhookConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent fluent, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1MutatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.mo fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1MutatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationList instance) { - this(instance,false); + + public V1MutatingWebhookConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationList instance) { + this(instance, false); } - public V1MutatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1MutatingWebhookConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1MutatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.mo this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationList build() { V1MutatingWebhookConfigurationList buildable = new V1MutatingWebhookConfigurationList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationList bu buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1MutatingWebhookConfigurationListBuilder that = (V1MutatingWebhookConfigurationListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationListFluent.java index 82d144535b..3de679ebd6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationListFluent.java @@ -1,95 +1,187 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1MutatingWebhookConfigurationListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1MutatingWebhookConfigurationListFluent< + A extends io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item); + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item); + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item); + public A addToItems(io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration... items); - public A addAllToItems(java.util.Collection items); - public A removeFromItems(io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A addAllToItems( + java.util.Collection + items); + + public A removeFromItems( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration... items); + + public A removeAllFromItems( + java.util.Collection + items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getItems(); - public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration buildItem(java.lang.Integer index); + public java.util.List + getItems(); + + public java.util.List + buildItems(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration buildFirstItem(); + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration buildLastItem(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent>{ + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .MetadataNested< + A> + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .MetadataNested< + A> + editMetadata(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluent< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationListFluentImpl.java index af9fd1bf43..4edb9d8e06 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookConfigurationListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1MutatingWebhookConfigurationListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent{ - public V1MutatingWebhookConfigurationListFluentImpl() { - } - public V1MutatingWebhookConfigurationListFluentImpl(io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationList instance) { + +/** Generated */ +public class V1MutatingWebhookConfigurationListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent { + public V1MutatingWebhookConfigurationListFluentImpl() {} + + public V1MutatingWebhookConfigurationListFluentImpl( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,233 +31,453 @@ public V1MutatingWebhookConfigurationListFluentImpl(io.kubernetes.client.openapi this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder> + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder>(); + } + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder>(); + } + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item : items) {io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item : items) { + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item : items) {io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection + items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item : items) { + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A removeFromItems(io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration... items) { - for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item : items) {io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeFromItems( + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration... items) { + for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item : items) { + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item : items) {io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item : items) { + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getItems() { + public java.util.List + getItems() { return items != null ? build(items) : null; } - public java.util.List buildItems() { + + public java.util.List + buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item) { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item) { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item) { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item) { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .MetadataNested< + A> + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .MetadataNested< + A> + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1MutatingWebhookConfigurationListFluentImpl that = (V1MutatingWebhookConfigurationListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + V1MutatingWebhookConfigurationListFluentImpl that = + (V1MutatingWebhookConfigurationListFluentImpl) o; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl> implements io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.ItemsNested< + N>> + implements io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1MutatingWebhookConfiguration item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder(this); } + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1MutatingWebhookConfigurationListFluentImpl.this.setToItems(index,builder.build()); + return (N) + V1MutatingWebhookConfigurationListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V1MutatingWebhookConfigurationListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1MutatingWebhookConfigurationListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookFluent.java index 64d3c06eb1..c8b1a42774 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookFluent.java @@ -1,181 +1,311 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1MutatingWebhookFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAdmissionReviewVersions(java.lang.Integer index,java.lang.String item); - public A setToAdmissionReviewVersions(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1MutatingWebhookFluent< + A extends io.kubernetes.client.openapi.models.V1MutatingWebhookFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAdmissionReviewVersions(java.lang.Integer index, java.lang.String item); + + public A setToAdmissionReviewVersions(java.lang.Integer index, java.lang.String item); + public A addToAdmissionReviewVersions(java.lang.String... items); + public A addAllToAdmissionReviewVersions(java.util.Collection items); + public A removeFromAdmissionReviewVersions(java.lang.String... items); + public A removeAllFromAdmissionReviewVersions(java.util.Collection items); + public java.util.List getAdmissionReviewVersions(); + public java.lang.String getAdmissionReviewVersion(java.lang.Integer index); + public java.lang.String getFirstAdmissionReviewVersion(); + public java.lang.String getLastAdmissionReviewVersion(); - public java.lang.String getMatchingAdmissionReviewVersion(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAdmissionReviewVersion(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAdmissionReviewVersion( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAdmissionReviewVersion( + java.util.function.Predicate predicate); + public A withAdmissionReviewVersions(java.util.List admissionReviewVersions); + public A withAdmissionReviewVersions(java.lang.String... admissionReviewVersions); + public java.lang.Boolean hasAdmissionReviewVersions(); + public A addNewAdmissionReviewVersion(java.lang.String original); - + /** * This method has been deprecated, please use method buildClientConfig instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig getClientConfig(); - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig buildClientConfig(); - public A withClientConfig(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig clientConfig); + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig + getClientConfig(); + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig + buildClientConfig(); + + public A withClientConfig( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig clientConfig); + public java.lang.Boolean hasClientConfig(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested withNewClientConfig(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested withNewClientConfigLike(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested editClientConfig(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested editOrNewClientConfig(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested editOrNewClientConfigLike(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested + withNewClientConfig(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested + withNewClientConfigLike( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested + editClientConfig(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested + editOrNewClientConfig(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested + editOrNewClientConfigLike( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item); + public java.lang.String getFailurePolicy(); + public A withFailurePolicy(java.lang.String failurePolicy); + public java.lang.Boolean hasFailurePolicy(); - - /** - * Method is deprecated. use withFailurePolicy instead. - */ + + /** Method is deprecated. use withFailurePolicy instead. */ @java.lang.Deprecated public A withNewFailurePolicy(java.lang.String original); + public java.lang.String getMatchPolicy(); + public A withMatchPolicy(java.lang.String matchPolicy); + public java.lang.Boolean hasMatchPolicy(); - - /** - * Method is deprecated. use withMatchPolicy instead. - */ + + /** Method is deprecated. use withMatchPolicy instead. */ @java.lang.Deprecated public A withNewMatchPolicy(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - + /** * This method has been deprecated, please use method buildNamespaceSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getNamespaceSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildNamespaceSelector(); - public A withNamespaceSelector(io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector); + + public A withNamespaceSelector( + io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector); + public java.lang.Boolean hasNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested withNewNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested editNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested editOrNewNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested + withNewNamespaceSelector(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested + withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested + editNamespaceSelector(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested + editOrNewNamespaceSelector(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested + editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + /** * This method has been deprecated, please use method buildObjectSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getObjectSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildObjectSelector(); + public A withObjectSelector(io.kubernetes.client.openapi.models.V1LabelSelector objectSelector); + public java.lang.Boolean hasObjectSelector(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested withNewObjectSelector(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested withNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested editObjectSelector(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested editOrNewObjectSelector(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested editOrNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested + withNewObjectSelector(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested + withNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested + editObjectSelector(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested + editOrNewObjectSelector(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested + editOrNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + public java.lang.String getReinvocationPolicy(); + public A withReinvocationPolicy(java.lang.String reinvocationPolicy); + public java.lang.Boolean hasReinvocationPolicy(); - - /** - * Method is deprecated. use withReinvocationPolicy instead. - */ + + /** Method is deprecated. use withReinvocationPolicy instead. */ @java.lang.Deprecated public A withNewReinvocationPolicy(java.lang.String original); - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item); - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item); + + public A addToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item); + + public A setToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item); + public A addToRules(io.kubernetes.client.openapi.models.V1RuleWithOperations... items); - public A addAllToRules(java.util.Collection items); + + public A addAllToRules( + java.util.Collection items); + public A removeFromRules(io.kubernetes.client.openapi.models.V1RuleWithOperations... items); - public A removeAllFromRules(java.util.Collection items); - public A removeMatchingFromRules(java.util.function.Predicate predicate); - + + public A removeAllFromRules( + java.util.Collection items); + + public A removeMatchingFromRules( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildRules instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getRules(); + public java.util.List buildRules(); - public io.kubernetes.client.openapi.models.V1RuleWithOperations buildRule(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildRule( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildFirstRule(); + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildLastRule(); - public io.kubernetes.client.openapi.models.V1RuleWithOperations buildMatchingRule(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate); - public A withRules(java.util.List rules); + + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildMatchingRule( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate + predicate); + + public A withRules( + java.util.List rules); + public A withRules(io.kubernetes.client.openapi.models.V1RuleWithOperations... rules); + public java.lang.Boolean hasRules(); + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested addNewRule(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1RuleWithOperations item); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested editRule(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested addNewRuleLike( + io.kubernetes.client.openapi.models.V1RuleWithOperations item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested setNewRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested editRule( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested editFirstRule(); + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested editLastRule(); - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested + editMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder> + predicate); + public java.lang.String getSideEffects(); + public A withSideEffects(java.lang.String sideEffects); + public java.lang.Boolean hasSideEffects(); - - /** - * Method is deprecated. use withSideEffects instead. - */ + + /** Method is deprecated. use withSideEffects instead. */ @java.lang.Deprecated public A withNewSideEffects(java.lang.String original); + public java.lang.Integer getTimeoutSeconds(); + public A withTimeoutSeconds(java.lang.Integer timeoutSeconds); + public java.lang.Boolean hasTimeoutSeconds(); - public interface ClientConfigNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent>{ + + public interface ClientConfigNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent< + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested> { public N and(); + public N endClientConfig(); - } - public interface NamespaceSelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface NamespaceSelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested< + N>> { public N and(); + public N endNamespaceSelector(); - } - public interface ObjectSelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface ObjectSelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested> { public N and(); + public N endObjectSelector(); - } - public interface RulesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent>{ + + public interface RulesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent< + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested> { public N and(); + public N endRule(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookFluentImpl.java index c79ccd20b9..b4ea9de665 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1MutatingWebhookFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1MutatingWebhookFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1MutatingWebhookFluent{ - public V1MutatingWebhookFluentImpl() { - } - public V1MutatingWebhookFluentImpl(io.kubernetes.client.openapi.models.V1MutatingWebhook instance) { + +/** Generated */ +public class V1MutatingWebhookFluentImpl< + A extends io.kubernetes.client.openapi.models.V1MutatingWebhookFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1MutatingWebhookFluent { + public V1MutatingWebhookFluentImpl() {} + + public V1MutatingWebhookFluentImpl( + io.kubernetes.client.openapi.models.V1MutatingWebhook instance) { this.withAdmissionReviewVersions(instance.getAdmissionReviewVersions()); this.withClientConfig(instance.getClientConfig()); @@ -42,271 +45,502 @@ public V1MutatingWebhookFluentImpl(io.kubernetes.client.openapi.models.V1Mutatin this.withSideEffects(instance.getSideEffects()); this.withTimeoutSeconds(instance.getTimeoutSeconds()); - } + private java.util.List admissionReviewVersions; - private io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder clientConfig; + private io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder + clientConfig; private java.lang.String failurePolicy; private java.lang.String matchPolicy; private java.lang.String name; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder namespaceSelector; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder objectSelector; private java.lang.String reinvocationPolicy; - private java.util.ArrayList rules; + private java.util.ArrayList + rules; private java.lang.String sideEffects; private java.lang.Integer timeoutSeconds; - public A addToAdmissionReviewVersions(java.lang.Integer index,java.lang.String item) { - if (this.admissionReviewVersions == null) {this.admissionReviewVersions = new java.util.ArrayList();} + + public A addToAdmissionReviewVersions(java.lang.Integer index, java.lang.String item) { + if (this.admissionReviewVersions == null) { + this.admissionReviewVersions = new java.util.ArrayList(); + } this.admissionReviewVersions.add(index, item); - return (A)this; + return (A) this; } - public A setToAdmissionReviewVersions(java.lang.Integer index,java.lang.String item) { - if (this.admissionReviewVersions == null) {this.admissionReviewVersions = new java.util.ArrayList();} - this.admissionReviewVersions.set(index, item); return (A)this; + + public A setToAdmissionReviewVersions(java.lang.Integer index, java.lang.String item) { + if (this.admissionReviewVersions == null) { + this.admissionReviewVersions = new java.util.ArrayList(); + } + this.admissionReviewVersions.set(index, item); + return (A) this; } + public A addToAdmissionReviewVersions(java.lang.String... items) { - if (this.admissionReviewVersions == null) {this.admissionReviewVersions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.admissionReviewVersions.add(item);} return (A)this; + if (this.admissionReviewVersions == null) { + this.admissionReviewVersions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.admissionReviewVersions.add(item); + } + return (A) this; } + public A addAllToAdmissionReviewVersions(java.util.Collection items) { - if (this.admissionReviewVersions == null) {this.admissionReviewVersions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.admissionReviewVersions.add(item);} return (A)this; + if (this.admissionReviewVersions == null) { + this.admissionReviewVersions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.admissionReviewVersions.add(item); + } + return (A) this; } + public A removeFromAdmissionReviewVersions(java.lang.String... items) { - for (java.lang.String item : items) {if (this.admissionReviewVersions!= null){ this.admissionReviewVersions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.admissionReviewVersions != null) { + this.admissionReviewVersions.remove(item); + } + } + return (A) this; } + public A removeAllFromAdmissionReviewVersions(java.util.Collection items) { - for (java.lang.String item : items) {if (this.admissionReviewVersions!= null){ this.admissionReviewVersions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.admissionReviewVersions != null) { + this.admissionReviewVersions.remove(item); + } + } + return (A) this; } + public java.util.List getAdmissionReviewVersions() { return this.admissionReviewVersions; } + public java.lang.String getAdmissionReviewVersion(java.lang.Integer index) { return this.admissionReviewVersions.get(index); } + public java.lang.String getFirstAdmissionReviewVersion() { return this.admissionReviewVersions.get(0); } + public java.lang.String getLastAdmissionReviewVersion() { return this.admissionReviewVersions.get(admissionReviewVersions.size() - 1); } - public java.lang.String getMatchingAdmissionReviewVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: admissionReviewVersions) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAdmissionReviewVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : admissionReviewVersions) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAdmissionReviewVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: admissionReviewVersions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAdmissionReviewVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : admissionReviewVersions) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAdmissionReviewVersions(java.util.List admissionReviewVersions) { - if (admissionReviewVersions != null) {this.admissionReviewVersions = new java.util.ArrayList(); for (java.lang.String item : admissionReviewVersions){this.addToAdmissionReviewVersions(item);}} else { this.admissionReviewVersions = null;} return (A) this; + if (admissionReviewVersions != null) { + this.admissionReviewVersions = new java.util.ArrayList(); + for (java.lang.String item : admissionReviewVersions) { + this.addToAdmissionReviewVersions(item); + } + } else { + this.admissionReviewVersions = null; + } + return (A) this; } + public A withAdmissionReviewVersions(java.lang.String... admissionReviewVersions) { - if (this.admissionReviewVersions != null) {this.admissionReviewVersions.clear();} - if (admissionReviewVersions != null) {for (java.lang.String item :admissionReviewVersions){ this.addToAdmissionReviewVersions(item);}} return (A) this; + if (this.admissionReviewVersions != null) { + this.admissionReviewVersions.clear(); + } + if (admissionReviewVersions != null) { + for (java.lang.String item : admissionReviewVersions) { + this.addToAdmissionReviewVersions(item); + } + } + return (A) this; } + public java.lang.Boolean hasAdmissionReviewVersions() { return admissionReviewVersions != null && !admissionReviewVersions.isEmpty(); } + public A addNewAdmissionReviewVersion(java.lang.String original) { - return (A)addToAdmissionReviewVersions(new String(original)); + return (A) addToAdmissionReviewVersions(new String(original)); } - + /** * This method has been deprecated, please use method buildClientConfig instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig getClientConfig() { - return this.clientConfig!=null ?this.clientConfig.build():null; + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig + getClientConfig() { + return this.clientConfig != null ? this.clientConfig.build() : null; } - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig buildClientConfig() { - return this.clientConfig!=null ?this.clientConfig.build():null; + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig + buildClientConfig() { + return this.clientConfig != null ? this.clientConfig.build() : null; } - public A withClientConfig(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig clientConfig) { + + public A withClientConfig( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig clientConfig) { _visitables.get("clientConfig").remove(this.clientConfig); - if (clientConfig!=null){ this.clientConfig= new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder(clientConfig); _visitables.get("clientConfig").add(this.clientConfig);} return (A) this; + if (clientConfig != null) { + this.clientConfig = + new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder( + clientConfig); + _visitables.get("clientConfig").add(this.clientConfig); + } + return (A) this; } + public java.lang.Boolean hasClientConfig() { return this.clientConfig != null; } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested withNewClientConfig() { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl.ClientConfigNestedImpl(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested + withNewClientConfig() { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl + .ClientConfigNestedImpl(); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested withNewClientConfigLike(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item) { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl.ClientConfigNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested + withNewClientConfigLike( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item) { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl + .ClientConfigNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested editClientConfig() { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested + editClientConfig() { return withNewClientConfigLike(getClientConfig()); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested editOrNewClientConfig() { - return withNewClientConfigLike(getClientConfig() != null ? getClientConfig(): new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder().build()); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested + editOrNewClientConfig() { + return withNewClientConfigLike( + getClientConfig() != null + ? getClientConfig() + : new io.kubernetes.client.openapi.models + .AdmissionregistrationV1WebhookClientConfigBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested editOrNewClientConfigLike(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item) { - return withNewClientConfigLike(getClientConfig() != null ? getClientConfig(): item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested + editOrNewClientConfigLike( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item) { + return withNewClientConfigLike(getClientConfig() != null ? getClientConfig() : item); } + public java.lang.String getFailurePolicy() { return this.failurePolicy; } + public A withFailurePolicy(java.lang.String failurePolicy) { - this.failurePolicy=failurePolicy; return (A) this; + this.failurePolicy = failurePolicy; + return (A) this; } + public java.lang.Boolean hasFailurePolicy() { return this.failurePolicy != null; } - - /** - * Method is deprecated. use withFailurePolicy instead. - */ + + /** Method is deprecated. use withFailurePolicy instead. */ @java.lang.Deprecated public A withNewFailurePolicy(java.lang.String original) { - return (A)withFailurePolicy(new String(original)); + return (A) withFailurePolicy(new String(original)); } + public java.lang.String getMatchPolicy() { return this.matchPolicy; } + public A withMatchPolicy(java.lang.String matchPolicy) { - this.matchPolicy=matchPolicy; return (A) this; + this.matchPolicy = matchPolicy; + return (A) this; } + public java.lang.Boolean hasMatchPolicy() { return this.matchPolicy != null; } - - /** - * Method is deprecated. use withMatchPolicy instead. - */ + + /** Method is deprecated. use withMatchPolicy instead. */ @java.lang.Deprecated public A withNewMatchPolicy(java.lang.String original) { - return (A)withMatchPolicy(new String(original)); + return (A) withMatchPolicy(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } - + /** * This method has been deprecated, please use method buildNamespaceSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getNamespaceSelector() { - return this.namespaceSelector!=null ?this.namespaceSelector.build():null; + return this.namespaceSelector != null ? this.namespaceSelector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildNamespaceSelector() { - return this.namespaceSelector!=null ?this.namespaceSelector.build():null; + return this.namespaceSelector != null ? this.namespaceSelector.build() : null; } - public A withNamespaceSelector(io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector) { + + public A withNamespaceSelector( + io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector) { _visitables.get("namespaceSelector").remove(this.namespaceSelector); - if (namespaceSelector!=null){ this.namespaceSelector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(namespaceSelector); _visitables.get("namespaceSelector").add(this.namespaceSelector);} return (A) this; + if (namespaceSelector != null) { + this.namespaceSelector = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(namespaceSelector); + _visitables.get("namespaceSelector").add(this.namespaceSelector); + } + return (A) this; } + public java.lang.Boolean hasNamespaceSelector() { return this.namespaceSelector != null; } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested withNewNamespaceSelector() { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl.NamespaceSelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested + withNewNamespaceSelector() { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl + .NamespaceSelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl.NamespaceSelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested + withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl + .NamespaceSelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested editNamespaceSelector() { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested + editNamespaceSelector() { return withNewNamespaceSelectorLike(getNamespaceSelector()); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested editOrNewNamespaceSelector() { - return withNewNamespaceSelectorLike(getNamespaceSelector() != null ? getNamespaceSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested + editOrNewNamespaceSelector() { + return withNewNamespaceSelectorLike( + getNamespaceSelector() != null + ? getNamespaceSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewNamespaceSelectorLike(getNamespaceSelector() != null ? getNamespaceSelector(): item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested + editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewNamespaceSelectorLike( + getNamespaceSelector() != null ? getNamespaceSelector() : item); } - + /** * This method has been deprecated, please use method buildObjectSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getObjectSelector() { - return this.objectSelector!=null ?this.objectSelector.build():null; + return this.objectSelector != null ? this.objectSelector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildObjectSelector() { - return this.objectSelector!=null ?this.objectSelector.build():null; + return this.objectSelector != null ? this.objectSelector.build() : null; } + public A withObjectSelector(io.kubernetes.client.openapi.models.V1LabelSelector objectSelector) { _visitables.get("objectSelector").remove(this.objectSelector); - if (objectSelector!=null){ this.objectSelector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(objectSelector); _visitables.get("objectSelector").add(this.objectSelector);} return (A) this; + if (objectSelector != null) { + this.objectSelector = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(objectSelector); + _visitables.get("objectSelector").add(this.objectSelector); + } + return (A) this; } + public java.lang.Boolean hasObjectSelector() { return this.objectSelector != null; } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested withNewObjectSelector() { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl.ObjectSelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested + withNewObjectSelector() { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl + .ObjectSelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested withNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl.ObjectSelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested + withNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl + .ObjectSelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested editObjectSelector() { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested + editObjectSelector() { return withNewObjectSelectorLike(getObjectSelector()); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested editOrNewObjectSelector() { - return withNewObjectSelectorLike(getObjectSelector() != null ? getObjectSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested + editOrNewObjectSelector() { + return withNewObjectSelectorLike( + getObjectSelector() != null + ? getObjectSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested editOrNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewObjectSelectorLike(getObjectSelector() != null ? getObjectSelector(): item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested + editOrNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewObjectSelectorLike(getObjectSelector() != null ? getObjectSelector() : item); } + public java.lang.String getReinvocationPolicy() { return this.reinvocationPolicy; } + public A withReinvocationPolicy(java.lang.String reinvocationPolicy) { - this.reinvocationPolicy=reinvocationPolicy; return (A) this; + this.reinvocationPolicy = reinvocationPolicy; + return (A) this; } + public java.lang.Boolean hasReinvocationPolicy() { return this.reinvocationPolicy != null; } - - /** - * Method is deprecated. use withReinvocationPolicy instead. - */ + + /** Method is deprecated. use withReinvocationPolicy instead. */ @java.lang.Deprecated public A withNewReinvocationPolicy(java.lang.String original) { - return (A)withReinvocationPolicy(new String(original)); + return (A) withReinvocationPolicy(new String(original)); } - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item);_visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder);this.rules.add(index >= 0 ? index : rules.size(), builder); return (A)this; + + public A addToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder>(); + } + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); + _visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder); + this.rules.add(index >= 0 ? index : rules.size(), builder); + return (A) this; } - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); - if (index < 0 || index >= _visitables.get("rules").size()) { _visitables.get("rules").add(builder); } else { _visitables.get("rules").set(index, builder);} - if (index < 0 || index >= rules.size()) { rules.add(builder); } else { rules.set(index, builder);} - return (A)this; + + public A setToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder>(); + } + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); + if (index < 0 || index >= _visitables.get("rules").size()) { + _visitables.get("rules").add(builder); + } else { + _visitables.get("rules").set(index, builder); + } + if (index < 0 || index >= rules.size()) { + rules.add(builder); + } else { + rules.set(index, builder); + } + return (A) this; } + public A addToRules(io.kubernetes.client.openapi.models.V1RuleWithOperations... items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) {io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) { + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } - public A addAllToRules(java.util.Collection items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) {io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + + public A addAllToRules( + java.util.Collection items) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) { + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } + public A removeFromRules(io.kubernetes.client.openapi.models.V1RuleWithOperations... items) { - for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) {io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) { + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeAllFromRules(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) {io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + + public A removeAllFromRules( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) { + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromRules(java.util.function.Predicate predicate) { + + public A removeMatchingFromRules( + java.util.function.Predicate + predicate) { if (rules == null) return (A) this; - final Iterator each = rules.iterator(); + final Iterator each = + rules.iterator(); final List visitables = _visitables.get("rules"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = each.next(); @@ -315,188 +549,328 @@ public A removeMatchingFromRules(java.util.function.Predicate getRules() { return rules != null ? build(rules) : null; } + public java.util.List buildRules() { return rules != null ? build(rules) : null; } - public io.kubernetes.client.openapi.models.V1RuleWithOperations buildRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildRule( + java.lang.Integer index) { return this.rules.get(index).build(); } + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildFirstRule() { return this.rules.get(0).build(); } + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildLastRule() { return this.rules.get(rules.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1RuleWithOperations buildMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder item: rules) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildMatchingRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder item : rules) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder item: rules) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder item : rules) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withRules(java.util.List rules) { - if (this.rules != null) { _visitables.get("rules").removeAll(this.rules);} - if (rules != null) {this.rules = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : rules){this.addToRules(item);}} else { this.rules = null;} return (A) this; + + public A withRules( + java.util.List rules) { + if (this.rules != null) { + _visitables.get("rules").removeAll(this.rules); + } + if (rules != null) { + this.rules = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : rules) { + this.addToRules(item); + } + } else { + this.rules = null; + } + return (A) this; } + public A withRules(io.kubernetes.client.openapi.models.V1RuleWithOperations... rules) { - if (this.rules != null) {this.rules.clear();} - if (rules != null) {for (io.kubernetes.client.openapi.models.V1RuleWithOperations item :rules){ this.addToRules(item);}} return (A) this; + if (this.rules != null) { + this.rules.clear(); + } + if (rules != null) { + for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : rules) { + this.addToRules(item); + } + } + return (A) this; } + public java.lang.Boolean hasRules() { return rules != null && !rules.isEmpty(); } + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested addNewRule() { return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl.RulesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1RuleWithOperations item) { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl.RulesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested addNewRuleLike( + io.kubernetes.client.openapi.models.V1RuleWithOperations item) { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl.RulesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item) { - return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl.RulesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested setNewRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item) { + return new io.kubernetes.client.openapi.models.V1MutatingWebhookFluentImpl.RulesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested editRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested editRule( + java.lang.Integer index) { if (rules.size() <= index) throw new RuntimeException("Can't edit rules. Index exceeds size."); return setNewRuleLike(index, buildRule(index)); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested editFirstRule() { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested + editFirstRule() { if (rules.size() == 0) throw new RuntimeException("Can't edit first rules. The list is empty."); return setNewRuleLike(0, buildRule(0)); } + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested editLastRule() { int index = rules.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last rules. The list is empty."); return setNewRuleLike(index, buildRule(index)); } - public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested + editMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluentImpl> implements io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested,io.kubernetes.client.fluent.Nested{ - ClientConfigNestedImpl(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item) { - this.builder = new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder(this, item); + + public class ClientConfigNestedImpl + extends io.kubernetes.client.openapi.models + .AdmissionregistrationV1WebhookClientConfigFluentImpl< + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested> + implements io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ClientConfigNested, + io.kubernetes.client.fluent.Nested { + ClientConfigNestedImpl( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item) { + this.builder = + new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder( + this, item); } + ClientConfigNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder( + this); } + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder builder; + public N and() { return (N) V1MutatingWebhookFluentImpl.this.withClientConfig(builder.build()); } + public N endClientConfig() { return and(); } - } - public class NamespaceSelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested,io.kubernetes.client.fluent.Nested{ + + public class NamespaceSelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.NamespaceSelectorNested> + implements io.kubernetes.client.openapi.models.V1MutatingWebhookFluent + .NamespaceSelectorNested< + N>, + io.kubernetes.client.fluent.Nested { NamespaceSelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + NamespaceSelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1MutatingWebhookFluentImpl.this.withNamespaceSelector(builder.build()); } + public N endNamespaceSelector() { return and(); } - } - public class ObjectSelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested,io.kubernetes.client.fluent.Nested{ + + public class ObjectSelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested> + implements io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.ObjectSelectorNested< + N>, + io.kubernetes.client.fluent.Nested { ObjectSelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + ObjectSelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1MutatingWebhookFluentImpl.this.withObjectSelector(builder.build()); } + public N endObjectSelector() { return and(); } - } - public class RulesNestedImpl extends io.kubernetes.client.openapi.models.V1RuleWithOperationsFluentImpl> implements io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested,io.kubernetes.client.fluent.Nested{ - RulesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item) { + + public class RulesNestedImpl + extends io.kubernetes.client.openapi.models.V1RuleWithOperationsFluentImpl< + io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested> + implements io.kubernetes.client.openapi.models.V1MutatingWebhookFluent.RulesNested, + io.kubernetes.client.fluent.Nested { + RulesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(this, item); } + RulesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(this); } + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1MutatingWebhookFluentImpl.this.setToRules(index,builder.build()); + return (N) V1MutatingWebhookFluentImpl.this.setToRules(index, builder.build()); } + public N endRule() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NFSVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NFSVolumeSourceBuilder.java index 0a76c3264e..3d582f7955 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NFSVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NFSVolumeSourceBuilder.java @@ -1,49 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NFSVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NFSVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NFSVolumeSource, + io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder> { public V1NFSVolumeSourceBuilder() { this(false); } + public V1NFSVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1NFSVolumeSource(), validationEnabled); } - public V1NFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent fluent) { + + public V1NFSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent fluent) { this(fluent, false); } - public V1NFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NFSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NFSVolumeSource(), validationEnabled); } - public V1NFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1NFSVolumeSource instance) { + + public V1NFSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1NFSVolumeSource instance) { this(fluent, instance, false); } - public V1NFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1NFSVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NFSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1NFSVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPath(instance.getPath()); fluent.withReadOnly(instance.getReadOnly()); fluent.withServer(instance.getServer()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1NFSVolumeSource instance) { - this(instance,false); + this(instance, false); } - public V1NFSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1NFSVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NFSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1NFSVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPath(instance.getPath()); this.withReadOnly(instance.getReadOnly()); this.withServer(instance.getServer()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NFSVolumeSource build() { V1NFSVolumeSource buildable = new V1NFSVolumeSource(); buildable.setPath(fluent.getPath()); @@ -51,18 +84,23 @@ public io.kubernetes.client.openapi.models.V1NFSVolumeSource build() { buildable.setServer(fluent.getServer()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NFSVolumeSourceBuilder that = (V1NFSVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NFSVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NFSVolumeSourceFluent.java index 75b8c7c217..c4e1841b48 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NFSVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NFSVolumeSourceFluent.java @@ -1,35 +1,44 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NFSVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NFSVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); + public java.lang.String getServer(); + public A withServer(java.lang.String server); + public java.lang.Boolean hasServer(); - - /** - * Method is deprecated. use withServer instead. - */ + + /** Method is deprecated. use withServer instead. */ @java.lang.Deprecated public A withNewServer(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NFSVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NFSVolumeSourceFluentImpl.java index 344c743c8f..9953e8c1e4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NFSVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NFSVolumeSourceFluentImpl.java @@ -1,82 +1,99 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1NFSVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent{ - public V1NFSVolumeSourceFluentImpl() { - } - public V1NFSVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1NFSVolumeSource instance) { +/** Generated */ +public class V1NFSVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent { + public V1NFSVolumeSourceFluentImpl() {} + + public V1NFSVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1NFSVolumeSource instance) { this.withPath(instance.getPath()); this.withReadOnly(instance.getReadOnly()); this.withServer(instance.getServer()); - } + private java.lang.String path; private java.lang.Boolean readOnly; private java.lang.String server; + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public java.lang.String getServer() { return this.server; } + public A withServer(java.lang.String server) { - this.server=server; return (A) this; + this.server = server; + return (A) this; } + public java.lang.Boolean hasServer() { return this.server != null; } - - /** - * Method is deprecated. use withServer instead. - */ + + /** Method is deprecated. use withServer instead. */ @java.lang.Deprecated public A withNewServer(java.lang.String original) { - return (A)withServer(new String(original)); + return (A) withServer(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NFSVolumeSourceFluentImpl that = (V1NFSVolumeSourceFluentImpl) o; - if (path != null ? !path.equals(that.path) :that.path != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (server != null ? !server.equals(that.server) :that.server != null) return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (server != null ? !server.equals(that.server) : that.server != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(path, readOnly, server, super.hashCode()); + return java.util.Objects.hash(path, readOnly, server, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceBuilder.java index 3725894e72..322935ead8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NamespaceBuilder extends io.kubernetes.client.openapi.models.V1NamespaceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NamespaceBuilder + extends io.kubernetes.client.openapi.models.V1NamespaceFluentImpl< + io.kubernetes.client.openapi.models.V1NamespaceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Namespace, + io.kubernetes.client.openapi.models.V1NamespaceBuilder> { public V1NamespaceBuilder() { this(false); } + public V1NamespaceBuilder(java.lang.Boolean validationEnabled) { this(new V1Namespace(), validationEnabled); } + public V1NamespaceBuilder(io.kubernetes.client.openapi.models.V1NamespaceFluent fluent) { this(fluent, false); } - public V1NamespaceBuilder(io.kubernetes.client.openapi.models.V1NamespaceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NamespaceBuilder( + io.kubernetes.client.openapi.models.V1NamespaceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Namespace(), validationEnabled); } - public V1NamespaceBuilder(io.kubernetes.client.openapi.models.V1NamespaceFluent fluent,io.kubernetes.client.openapi.models.V1Namespace instance) { + + public V1NamespaceBuilder( + io.kubernetes.client.openapi.models.V1NamespaceFluent fluent, + io.kubernetes.client.openapi.models.V1Namespace instance) { this(fluent, instance, false); } - public V1NamespaceBuilder(io.kubernetes.client.openapi.models.V1NamespaceFluent fluent,io.kubernetes.client.openapi.models.V1Namespace instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NamespaceBuilder( + io.kubernetes.client.openapi.models.V1NamespaceFluent fluent, + io.kubernetes.client.openapi.models.V1Namespace instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,17 @@ public V1NamespaceBuilder(io.kubernetes.client.openapi.models.V1NamespaceFluent< fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NamespaceBuilder(io.kubernetes.client.openapi.models.V1Namespace instance) { - this(instance,false); + this(instance, false); } - public V1NamespaceBuilder(io.kubernetes.client.openapi.models.V1Namespace instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NamespaceBuilder( + io.kubernetes.client.openapi.models.V1Namespace instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +78,12 @@ public V1NamespaceBuilder(io.kubernetes.client.openapi.models.V1Namespace instan this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NamespaceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Namespace build() { V1Namespace buildable = new V1Namespace(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +93,23 @@ public io.kubernetes.client.openapi.models.V1Namespace build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NamespaceBuilder that = (V1NamespaceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceConditionBuilder.java index 30c1279195..3081e5a5ff 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NamespaceConditionBuilder extends io.kubernetes.client.openapi.models.V1NamespaceConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NamespaceConditionBuilder + extends io.kubernetes.client.openapi.models.V1NamespaceConditionFluentImpl< + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NamespaceCondition, + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder> { public V1NamespaceConditionBuilder() { this(false); } + public V1NamespaceConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1NamespaceCondition(), validationEnabled); } - public V1NamespaceConditionBuilder(io.kubernetes.client.openapi.models.V1NamespaceConditionFluent fluent) { + + public V1NamespaceConditionBuilder( + io.kubernetes.client.openapi.models.V1NamespaceConditionFluent fluent) { this(fluent, false); } - public V1NamespaceConditionBuilder(io.kubernetes.client.openapi.models.V1NamespaceConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NamespaceConditionBuilder( + io.kubernetes.client.openapi.models.V1NamespaceConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NamespaceCondition(), validationEnabled); } - public V1NamespaceConditionBuilder(io.kubernetes.client.openapi.models.V1NamespaceConditionFluent fluent,io.kubernetes.client.openapi.models.V1NamespaceCondition instance) { + + public V1NamespaceConditionBuilder( + io.kubernetes.client.openapi.models.V1NamespaceConditionFluent fluent, + io.kubernetes.client.openapi.models.V1NamespaceCondition instance) { this(fluent, instance, false); } - public V1NamespaceConditionBuilder(io.kubernetes.client.openapi.models.V1NamespaceConditionFluent fluent,io.kubernetes.client.openapi.models.V1NamespaceCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NamespaceConditionBuilder( + io.kubernetes.client.openapi.models.V1NamespaceConditionFluent fluent, + io.kubernetes.client.openapi.models.V1NamespaceCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +58,18 @@ public V1NamespaceConditionBuilder(io.kubernetes.client.openapi.models.V1Namespa fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1NamespaceConditionBuilder(io.kubernetes.client.openapi.models.V1NamespaceCondition instance) { - this(instance,false); + + public V1NamespaceConditionBuilder( + io.kubernetes.client.openapi.models.V1NamespaceCondition instance) { + this(instance, false); } - public V1NamespaceConditionBuilder(io.kubernetes.client.openapi.models.V1NamespaceCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NamespaceConditionBuilder( + io.kubernetes.client.openapi.models.V1NamespaceCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,10 +80,12 @@ public V1NamespaceConditionBuilder(io.kubernetes.client.openapi.models.V1Namespa this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NamespaceConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NamespaceCondition build() { V1NamespaceCondition buildable = new V1NamespaceCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1NamespaceCondition build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NamespaceConditionBuilder that = (V1NamespaceConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceConditionFluent.java index f12e5d0f87..31c2c80638 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceConditionFluent.java @@ -1,48 +1,60 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NamespaceConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NamespaceConditionFluent< + A extends io.kubernetes.client.openapi.models.V1NamespaceConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public io.kubernetes.client.openapi.models.V1NamespaceCondition.TypeEnum getType(); + public A withType(io.kubernetes.client.openapi.models.V1NamespaceCondition.TypeEnum type); + public java.lang.Boolean hasType(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceConditionFluentImpl.java index 4530f43d00..30477b5dc5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceConditionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1NamespaceConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NamespaceConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NamespaceConditionFluent { + public V1NamespaceConditionFluentImpl() {} - /** - * Generated - */ -public class V1NamespaceConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NamespaceConditionFluent{ - public V1NamespaceConditionFluentImpl() { - } - public V1NamespaceConditionFluentImpl(io.kubernetes.client.openapi.models.V1NamespaceCondition instance) { + public V1NamespaceConditionFluentImpl( + io.kubernetes.client.openapi.models.V1NamespaceCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,95 +30,113 @@ public V1NamespaceConditionFluentImpl(io.kubernetes.client.openapi.models.V1Name this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private io.kubernetes.client.openapi.models.V1NamespaceCondition.TypeEnum type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public io.kubernetes.client.openapi.models.V1NamespaceCondition.TypeEnum getType() { return this.type; } + public A withType(io.kubernetes.client.openapi.models.V1NamespaceCondition.TypeEnum type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NamespaceConditionFluentImpl that = (V1NamespaceConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceFluent.java index 078383adac..607b1136e4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceFluent.java @@ -1,93 +1,144 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NamespaceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NamespaceFluent< + A extends io.kubernetes.client.openapi.models.V1NamespaceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NamespaceSpec getSpec(); + public io.kubernetes.client.openapi.models.V1NamespaceSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1NamespaceSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1NamespaceSpec item); + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1NamespaceSpec item); + public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1NamespaceSpec item); - + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1NamespaceSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NamespaceStatus getStatus(); + public io.kubernetes.client.openapi.models.V1NamespaceStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1NamespaceStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1NamespaceStatus item); + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1NamespaceStatus item); + public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1NamespaceStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1NamespaceStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NamespaceSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NamespaceSpecFluent< + io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NamespaceStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NamespaceStatusFluent< + io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceFluentImpl.java index e27b039efc..6842955b4d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1NamespaceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NamespaceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NamespaceFluent { + public V1NamespaceFluentImpl() {} - /** - * Generated - */ -public class V1NamespaceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NamespaceFluent{ - public V1NamespaceFluentImpl() { - } public V1NamespaceFluentImpl(io.kubernetes.client.openapi.models.V1Namespace instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +29,295 @@ public V1NamespaceFluentImpl(io.kubernetes.client.openapi.models.V1Namespace ins this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1NamespaceSpecBuilder spec; private io.kubernetes.client.openapi.models.V1NamespaceStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1NamespaceFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1NamespaceFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NamespaceSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1NamespaceSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1NamespaceSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1NamespaceSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1NamespaceSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1NamespaceFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1NamespaceSpec item) { + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1NamespaceSpec item) { return new io.kubernetes.client.openapi.models.V1NamespaceFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1NamespaceSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1NamespaceSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1NamespaceSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1NamespaceSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NamespaceStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1NamespaceStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1NamespaceStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1NamespaceStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1NamespaceStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1NamespaceFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1NamespaceStatus item) { + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1NamespaceStatus item) { return new io.kubernetes.client.openapi.models.V1NamespaceFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1NamespaceStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1NamespaceStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1NamespaceStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1NamespaceStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NamespaceFluentImpl that = (V1NamespaceFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1NamespaceFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1NamespaceFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1NamespaceSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1NamespaceSpecFluentImpl< + io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1NamespaceFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1NamespaceSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1NamespaceSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NamespaceSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1NamespaceSpecBuilder builder; + public N and() { return (N) V1NamespaceFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1NamespaceStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1NamespaceStatusFluentImpl< + io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1NamespaceFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1NamespaceStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1NamespaceStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NamespaceStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1NamespaceStatusBuilder builder; + public N and() { return (N) V1NamespaceFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceListBuilder.java index 0b6491179c..ce17d41168 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NamespaceListBuilder extends io.kubernetes.client.openapi.models.V1NamespaceListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NamespaceListBuilder + extends io.kubernetes.client.openapi.models.V1NamespaceListFluentImpl< + io.kubernetes.client.openapi.models.V1NamespaceListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NamespaceList, + io.kubernetes.client.openapi.models.V1NamespaceListBuilder> { public V1NamespaceListBuilder() { this(false); } + public V1NamespaceListBuilder(java.lang.Boolean validationEnabled) { this(new V1NamespaceList(), validationEnabled); } - public V1NamespaceListBuilder(io.kubernetes.client.openapi.models.V1NamespaceListFluent fluent) { + + public V1NamespaceListBuilder( + io.kubernetes.client.openapi.models.V1NamespaceListFluent fluent) { this(fluent, false); } - public V1NamespaceListBuilder(io.kubernetes.client.openapi.models.V1NamespaceListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NamespaceListBuilder( + io.kubernetes.client.openapi.models.V1NamespaceListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NamespaceList(), validationEnabled); } - public V1NamespaceListBuilder(io.kubernetes.client.openapi.models.V1NamespaceListFluent fluent,io.kubernetes.client.openapi.models.V1NamespaceList instance) { + + public V1NamespaceListBuilder( + io.kubernetes.client.openapi.models.V1NamespaceListFluent fluent, + io.kubernetes.client.openapi.models.V1NamespaceList instance) { this(fluent, instance, false); } - public V1NamespaceListBuilder(io.kubernetes.client.openapi.models.V1NamespaceListFluent fluent,io.kubernetes.client.openapi.models.V1NamespaceList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NamespaceListBuilder( + io.kubernetes.client.openapi.models.V1NamespaceListFluent fluent, + io.kubernetes.client.openapi.models.V1NamespaceList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1NamespaceListBuilder(io.kubernetes.client.openapi.models.V1NamespaceLis fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NamespaceListBuilder(io.kubernetes.client.openapi.models.V1NamespaceList instance) { - this(instance,false); + this(instance, false); } - public V1NamespaceListBuilder(io.kubernetes.client.openapi.models.V1NamespaceList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NamespaceListBuilder( + io.kubernetes.client.openapi.models.V1NamespaceList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1NamespaceListBuilder(io.kubernetes.client.openapi.models.V1NamespaceLis this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NamespaceListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NamespaceList build() { V1NamespaceList buildable = new V1NamespaceList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1NamespaceList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NamespaceListBuilder that = (V1NamespaceListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceListFluent.java index e3a6ac383d..30fc0da53d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceListFluent.java @@ -1,95 +1,153 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NamespaceListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NamespaceListFluent< + A extends io.kubernetes.client.openapi.models.V1NamespaceListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Namespace item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Namespace item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Namespace item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Namespace item); + public A addToItems(io.kubernetes.client.openapi.models.V1Namespace... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1Namespace... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1Namespace buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Namespace buildFirstItem(); + public io.kubernetes.client.openapi.models.V1Namespace buildLastItem(); - public io.kubernetes.client.openapi.models.V1Namespace buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Namespace buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1Namespace... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Namespace item); - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Namespace item); - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Namespace item); + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Namespace item); + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NamespaceFluent>{ + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NamespaceFluent< + io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceListFluentImpl.java index dbe278a959..966fa72f4e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1NamespaceListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NamespaceListFluent{ - public V1NamespaceListFluentImpl() { - } +/** Generated */ +public class V1NamespaceListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NamespaceListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NamespaceListFluent { + public V1NamespaceListFluentImpl() {} + public V1NamespaceListFluentImpl(io.kubernetes.client.openapi.models.V1NamespaceList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,123 @@ public V1NamespaceListFluentImpl(io.kubernetes.client.openapi.models.V1Namespace this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Namespace item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NamespaceBuilder builder = new io.kubernetes.client.openapi.models.V1NamespaceBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Namespace item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NamespaceBuilder builder = + new io.kubernetes.client.openapi.models.V1NamespaceBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Namespace item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NamespaceBuilder builder = new io.kubernetes.client.openapi.models.V1NamespaceBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Namespace item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NamespaceBuilder builder = + new io.kubernetes.client.openapi.models.V1NamespaceBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1Namespace... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Namespace item : items) {io.kubernetes.client.openapi.models.V1NamespaceBuilder builder = new io.kubernetes.client.openapi.models.V1NamespaceBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Namespace item : items) { + io.kubernetes.client.openapi.models.V1NamespaceBuilder builder = + new io.kubernetes.client.openapi.models.V1NamespaceBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Namespace item : items) {io.kubernetes.client.openapi.models.V1NamespaceBuilder builder = new io.kubernetes.client.openapi.models.V1NamespaceBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Namespace item : items) { + io.kubernetes.client.openapi.models.V1NamespaceBuilder builder = + new io.kubernetes.client.openapi.models.V1NamespaceBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1Namespace... items) { - for (io.kubernetes.client.openapi.models.V1Namespace item : items) {io.kubernetes.client.openapi.models.V1NamespaceBuilder builder = new io.kubernetes.client.openapi.models.V1NamespaceBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Namespace item : items) { + io.kubernetes.client.openapi.models.V1NamespaceBuilder builder = + new io.kubernetes.client.openapi.models.V1NamespaceBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Namespace item : items) {io.kubernetes.client.openapi.models.V1NamespaceBuilder builder = new io.kubernetes.client.openapi.models.V1NamespaceBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Namespace item : items) { + io.kubernetes.client.openapi.models.V1NamespaceBuilder builder = + new io.kubernetes.client.openapi.models.V1NamespaceBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +157,274 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1Namespace buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Namespace buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Namespace buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Namespace buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NamespaceBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Namespace buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NamespaceBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NamespaceBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NamespaceBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Namespace item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Namespace item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1Namespace... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1Namespace item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1Namespace item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1NamespaceListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Namespace item) { - return new io.kubernetes.client.openapi.models.V1NamespaceListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Namespace item) { + return new io.kubernetes.client.openapi.models.V1NamespaceListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Namespace item) { - return new io.kubernetes.client.openapi.models.V1NamespaceListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Namespace item) { + return new io.kubernetes.client.openapi.models.V1NamespaceListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1NamespaceListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1NamespaceListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1NamespaceListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NamespaceListFluentImpl that = (V1NamespaceListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1NamespaceFluentImpl> implements io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Namespace item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1NamespaceFluentImpl< + io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1NamespaceListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Namespace item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1NamespaceBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NamespaceBuilder(this); } + io.kubernetes.client.openapi.models.V1NamespaceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NamespaceListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1NamespaceListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1NamespaceListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1NamespaceListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceSpecBuilder.java index ad65db4f2e..39d24e6a13 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceSpecBuilder.java @@ -1,58 +1,96 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NamespaceSpecBuilder extends io.kubernetes.client.openapi.models.V1NamespaceSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NamespaceSpecBuilder + extends io.kubernetes.client.openapi.models.V1NamespaceSpecFluentImpl< + io.kubernetes.client.openapi.models.V1NamespaceSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NamespaceSpec, + io.kubernetes.client.openapi.models.V1NamespaceSpecBuilder> { public V1NamespaceSpecBuilder() { this(false); } + public V1NamespaceSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1NamespaceSpec(), validationEnabled); } - public V1NamespaceSpecBuilder(io.kubernetes.client.openapi.models.V1NamespaceSpecFluent fluent) { + + public V1NamespaceSpecBuilder( + io.kubernetes.client.openapi.models.V1NamespaceSpecFluent fluent) { this(fluent, false); } - public V1NamespaceSpecBuilder(io.kubernetes.client.openapi.models.V1NamespaceSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NamespaceSpecBuilder( + io.kubernetes.client.openapi.models.V1NamespaceSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NamespaceSpec(), validationEnabled); } - public V1NamespaceSpecBuilder(io.kubernetes.client.openapi.models.V1NamespaceSpecFluent fluent,io.kubernetes.client.openapi.models.V1NamespaceSpec instance) { + + public V1NamespaceSpecBuilder( + io.kubernetes.client.openapi.models.V1NamespaceSpecFluent fluent, + io.kubernetes.client.openapi.models.V1NamespaceSpec instance) { this(fluent, instance, false); } - public V1NamespaceSpecBuilder(io.kubernetes.client.openapi.models.V1NamespaceSpecFluent fluent,io.kubernetes.client.openapi.models.V1NamespaceSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NamespaceSpecBuilder( + io.kubernetes.client.openapi.models.V1NamespaceSpecFluent fluent, + io.kubernetes.client.openapi.models.V1NamespaceSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFinalizers(instance.getFinalizers()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NamespaceSpecBuilder(io.kubernetes.client.openapi.models.V1NamespaceSpec instance) { - this(instance,false); + this(instance, false); } - public V1NamespaceSpecBuilder(io.kubernetes.client.openapi.models.V1NamespaceSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NamespaceSpecBuilder( + io.kubernetes.client.openapi.models.V1NamespaceSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFinalizers(instance.getFinalizers()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NamespaceSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NamespaceSpec build() { V1NamespaceSpec buildable = new V1NamespaceSpec(); buildable.setFinalizers(fluent.getFinalizers()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NamespaceSpecBuilder that = (V1NamespaceSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceSpecFluent.java index 847eebaa33..dd34e93112 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceSpecFluent.java @@ -1,34 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1NamespaceSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToFinalizers(java.lang.Integer index,java.lang.String item); - public A setToFinalizers(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1NamespaceSpecFluent< + A extends io.kubernetes.client.openapi.models.V1NamespaceSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToFinalizers(java.lang.Integer index, java.lang.String item); + + public A setToFinalizers(java.lang.Integer index, java.lang.String item); + public A addToFinalizers(java.lang.String... items); + public A addAllToFinalizers(java.util.Collection items); + public A removeFromFinalizers(java.lang.String... items); + public A removeAllFromFinalizers(java.util.Collection items); + public java.util.List getFinalizers(); + public java.lang.String getFinalizer(java.lang.Integer index); + public java.lang.String getFirstFinalizer(); + public java.lang.String getLastFinalizer(); - public java.lang.String getMatchingFinalizer(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingFinalizer(java.util.function.Predicate predicate); + + public java.lang.String getMatchingFinalizer( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingFinalizer( + java.util.function.Predicate predicate); + public A withFinalizers(java.util.List finalizers); + public A withFinalizers(java.lang.String... finalizers); + public java.lang.Boolean hasFinalizers(); + public A addNewFinalizer(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceSpecFluentImpl.java index 5717e11236..1df09ffb4c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceSpecFluentImpl.java @@ -1,89 +1,162 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.ArrayList; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public class V1NamespaceSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NamespaceSpecFluent{ - public V1NamespaceSpecFluentImpl() { - } +/** Generated */ +public class V1NamespaceSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NamespaceSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NamespaceSpecFluent { + public V1NamespaceSpecFluentImpl() {} + public V1NamespaceSpecFluentImpl(io.kubernetes.client.openapi.models.V1NamespaceSpec instance) { this.withFinalizers(instance.getFinalizers()); - } + private java.util.List finalizers; - public A addToFinalizers(java.lang.Integer index,java.lang.String item) { - if (this.finalizers == null) {this.finalizers = new java.util.ArrayList();} + + public A addToFinalizers(java.lang.Integer index, java.lang.String item) { + if (this.finalizers == null) { + this.finalizers = new java.util.ArrayList(); + } this.finalizers.add(index, item); - return (A)this; + return (A) this; } - public A setToFinalizers(java.lang.Integer index,java.lang.String item) { - if (this.finalizers == null) {this.finalizers = new java.util.ArrayList();} - this.finalizers.set(index, item); return (A)this; + + public A setToFinalizers(java.lang.Integer index, java.lang.String item) { + if (this.finalizers == null) { + this.finalizers = new java.util.ArrayList(); + } + this.finalizers.set(index, item); + return (A) this; } + public A addToFinalizers(java.lang.String... items) { - if (this.finalizers == null) {this.finalizers = new java.util.ArrayList();} - for (java.lang.String item : items) {this.finalizers.add(item);} return (A)this; + if (this.finalizers == null) { + this.finalizers = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.finalizers.add(item); + } + return (A) this; } + public A addAllToFinalizers(java.util.Collection items) { - if (this.finalizers == null) {this.finalizers = new java.util.ArrayList();} - for (java.lang.String item : items) {this.finalizers.add(item);} return (A)this; + if (this.finalizers == null) { + this.finalizers = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.finalizers.add(item); + } + return (A) this; } + public A removeFromFinalizers(java.lang.String... items) { - for (java.lang.String item : items) {if (this.finalizers!= null){ this.finalizers.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.finalizers != null) { + this.finalizers.remove(item); + } + } + return (A) this; } + public A removeAllFromFinalizers(java.util.Collection items) { - for (java.lang.String item : items) {if (this.finalizers!= null){ this.finalizers.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.finalizers != null) { + this.finalizers.remove(item); + } + } + return (A) this; } + public java.util.List getFinalizers() { return this.finalizers; } + public java.lang.String getFinalizer(java.lang.Integer index) { return this.finalizers.get(index); } + public java.lang.String getFirstFinalizer() { return this.finalizers.get(0); } + public java.lang.String getLastFinalizer() { return this.finalizers.get(finalizers.size() - 1); } - public java.lang.String getMatchingFinalizer(java.util.function.Predicate predicate) { - for (java.lang.String item: finalizers) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingFinalizer( + java.util.function.Predicate predicate) { + for (java.lang.String item : finalizers) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingFinalizer(java.util.function.Predicate predicate) { - for (java.lang.String item: finalizers) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingFinalizer( + java.util.function.Predicate predicate) { + for (java.lang.String item : finalizers) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withFinalizers(java.util.List finalizers) { - if (finalizers != null) {this.finalizers = new java.util.ArrayList(); for (java.lang.String item : finalizers){this.addToFinalizers(item);}} else { this.finalizers = null;} return (A) this; + if (finalizers != null) { + this.finalizers = new java.util.ArrayList(); + for (java.lang.String item : finalizers) { + this.addToFinalizers(item); + } + } else { + this.finalizers = null; + } + return (A) this; } + public A withFinalizers(java.lang.String... finalizers) { - if (this.finalizers != null) {this.finalizers.clear();} - if (finalizers != null) {for (java.lang.String item :finalizers){ this.addToFinalizers(item);}} return (A) this; + if (this.finalizers != null) { + this.finalizers.clear(); + } + if (finalizers != null) { + for (java.lang.String item : finalizers) { + this.addToFinalizers(item); + } + } + return (A) this; } + public java.lang.Boolean hasFinalizers() { return finalizers != null && !finalizers.isEmpty(); } + public A addNewFinalizer(java.lang.String original) { - return (A)addToFinalizers(new String(original)); + return (A) addToFinalizers(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NamespaceSpecFluentImpl that = (V1NamespaceSpecFluentImpl) o; - if (finalizers != null ? !finalizers.equals(that.finalizers) :that.finalizers != null) return false; + if (finalizers != null ? !finalizers.equals(that.finalizers) : that.finalizers != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(finalizers, super.hashCode()); + return java.util.Objects.hash(finalizers, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceStatusBuilder.java index abb7f17c78..7ff7fa8f76 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceStatusBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NamespaceStatusBuilder extends io.kubernetes.client.openapi.models.V1NamespaceStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NamespaceStatusBuilder + extends io.kubernetes.client.openapi.models.V1NamespaceStatusFluentImpl< + io.kubernetes.client.openapi.models.V1NamespaceStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NamespaceStatus, + io.kubernetes.client.openapi.models.V1NamespaceStatusBuilder> { public V1NamespaceStatusBuilder() { this(false); } + public V1NamespaceStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1NamespaceStatus(), validationEnabled); } - public V1NamespaceStatusBuilder(io.kubernetes.client.openapi.models.V1NamespaceStatusFluent fluent) { + + public V1NamespaceStatusBuilder( + io.kubernetes.client.openapi.models.V1NamespaceStatusFluent fluent) { this(fluent, false); } - public V1NamespaceStatusBuilder(io.kubernetes.client.openapi.models.V1NamespaceStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NamespaceStatusBuilder( + io.kubernetes.client.openapi.models.V1NamespaceStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NamespaceStatus(), validationEnabled); } - public V1NamespaceStatusBuilder(io.kubernetes.client.openapi.models.V1NamespaceStatusFluent fluent,io.kubernetes.client.openapi.models.V1NamespaceStatus instance) { + + public V1NamespaceStatusBuilder( + io.kubernetes.client.openapi.models.V1NamespaceStatusFluent fluent, + io.kubernetes.client.openapi.models.V1NamespaceStatus instance) { this(fluent, instance, false); } - public V1NamespaceStatusBuilder(io.kubernetes.client.openapi.models.V1NamespaceStatusFluent fluent,io.kubernetes.client.openapi.models.V1NamespaceStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NamespaceStatusBuilder( + io.kubernetes.client.openapi.models.V1NamespaceStatusFluent fluent, + io.kubernetes.client.openapi.models.V1NamespaceStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditions(instance.getConditions()); fluent.withPhase(instance.getPhase()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NamespaceStatusBuilder(io.kubernetes.client.openapi.models.V1NamespaceStatus instance) { - this(instance,false); + this(instance, false); } - public V1NamespaceStatusBuilder(io.kubernetes.client.openapi.models.V1NamespaceStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NamespaceStatusBuilder( + io.kubernetes.client.openapi.models.V1NamespaceStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditions(instance.getConditions()); this.withPhase(instance.getPhase()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NamespaceStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NamespaceStatus build() { V1NamespaceStatus buildable = new V1NamespaceStatus(); buildable.setConditions(fluent.getConditions()); buildable.setPhase(fluent.getPhase()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NamespaceStatusBuilder that = (V1NamespaceStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceStatusFluent.java index 45518406a2..c5de7f6f1f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceStatusFluent.java @@ -1,60 +1,110 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NamespaceStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NamespaceCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NamespaceCondition item); +/** Generated */ +public interface V1NamespaceStatusFluent< + A extends io.kubernetes.client.openapi.models.V1NamespaceStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NamespaceCondition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NamespaceCondition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1NamespaceCondition... items); - public A addAllToConditions(java.util.Collection items); + + public A addAllToConditions( + java.util.Collection items); + public A removeFromConditions(io.kubernetes.client.openapi.models.V1NamespaceCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getConditions(); + public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1NamespaceCondition buildCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NamespaceCondition buildCondition( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NamespaceCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1NamespaceCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1NamespaceCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); + + public io.kubernetes.client.openapi.models.V1NamespaceCondition buildMatchingCondition( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate); + + public A withConditions( + java.util.List conditions); + public A withConditions(io.kubernetes.client.openapi.models.V1NamespaceCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1NamespaceCondition item); - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NamespaceCondition item); - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1NamespaceCondition item); + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NamespaceCondition item); + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder> + predicate); + public io.kubernetes.client.openapi.models.V1NamespaceStatus.PhaseEnum getPhase(); + public A withPhase(io.kubernetes.client.openapi.models.V1NamespaceStatus.PhaseEnum phase); + public java.lang.Boolean hasPhase(); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NamespaceConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NamespaceConditionFluent< + io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceStatusFluentImpl.java index d73380987f..4cb1340c0e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NamespaceStatusFluentImpl.java @@ -1,60 +1,138 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1NamespaceStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NamespaceStatusFluent{ - public V1NamespaceStatusFluentImpl() { - } - public V1NamespaceStatusFluentImpl(io.kubernetes.client.openapi.models.V1NamespaceStatus instance) { +/** Generated */ +public class V1NamespaceStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NamespaceStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NamespaceStatusFluent { + public V1NamespaceStatusFluentImpl() {} + + public V1NamespaceStatusFluentImpl( + io.kubernetes.client.openapi.models.V1NamespaceStatus instance) { this.withConditions(instance.getConditions()); this.withPhase(instance.getPhase()); - } - private java.util.ArrayList conditions; + + private java.util.ArrayList + conditions; private io.kubernetes.client.openapi.models.V1NamespaceStatus.PhaseEnum phase; - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NamespaceCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder = new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NamespaceCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NamespaceCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder = new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NamespaceCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } + public A addToConditions(io.kubernetes.client.openapi.models.V1NamespaceCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NamespaceCondition item : items) {io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder = new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1NamespaceCondition item : items) { + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NamespaceCondition item : items) {io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder = new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1NamespaceCondition item : items) { + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } + public A removeFromConditions(io.kubernetes.client.openapi.models.V1NamespaceCondition... items) { - for (io.kubernetes.client.openapi.models.V1NamespaceCondition item : items) {io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder = new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1NamespaceCondition item : items) { + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NamespaceCondition item : items) {io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder = new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NamespaceCondition item : items) { + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder = each.next(); @@ -63,114 +141,200 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1NamespaceCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NamespaceCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NamespaceCondition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NamespaceCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NamespaceCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NamespaceCondition buildMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NamespaceCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NamespaceCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } + public A withConditions(io.kubernetes.client.openapi.models.V1NamespaceCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1NamespaceCondition item :conditions){ this.addToConditions(item);}} return (A) this; + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1NamespaceCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1NamespaceStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1NamespaceStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1NamespaceCondition item) { - return new io.kubernetes.client.openapi.models.V1NamespaceStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1NamespaceCondition item) { + return new io.kubernetes.client.openapi.models.V1NamespaceStatusFluentImpl.ConditionsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NamespaceCondition item) { - return new io.kubernetes.client.openapi.models.V1NamespaceStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NamespaceCondition item) { + return new io.kubernetes.client.openapi.models.V1NamespaceStatusFluentImpl.ConditionsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1NamespaceConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NamespaceCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1NamespaceConditionFluentImpl< + io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1NamespaceStatusFluent.ConditionsNested, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NamespaceCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1NamespaceConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NamespaceStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1NamespaceStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyBuilder.java index d742709cbb..4013fabeaa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NetworkPolicyBuilder extends io.kubernetes.client.openapi.models.V1NetworkPolicyFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NetworkPolicyBuilder + extends io.kubernetes.client.openapi.models.V1NetworkPolicyFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NetworkPolicy, + io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder> { public V1NetworkPolicyBuilder() { this(false); } + public V1NetworkPolicyBuilder(java.lang.Boolean validationEnabled) { this(new V1NetworkPolicy(), validationEnabled); } - public V1NetworkPolicyBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyFluent fluent) { + + public V1NetworkPolicyBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyFluent fluent) { this(fluent, false); } - public V1NetworkPolicyBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NetworkPolicyBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NetworkPolicy(), validationEnabled); } - public V1NetworkPolicyBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicy instance) { + + public V1NetworkPolicyBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicy instance) { this(fluent, instance, false); } - public V1NetworkPolicyBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicy instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NetworkPolicyBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicy instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +56,17 @@ public V1NetworkPolicyBuilder(io.kubernetes.client.openapi.models.V1NetworkPolic fluent.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NetworkPolicyBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicy instance) { - this(instance,false); + this(instance, false); } - public V1NetworkPolicyBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicy instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NetworkPolicyBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicy instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +75,12 @@ public V1NetworkPolicyBuilder(io.kubernetes.client.openapi.models.V1NetworkPolic this.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NetworkPolicyFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NetworkPolicy build() { V1NetworkPolicy buildable = new V1NetworkPolicy(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1NetworkPolicy build() { buildable.setSpec(fluent.getSpec()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NetworkPolicyBuilder that = (V1NetworkPolicyBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyEgressRuleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyEgressRuleBuilder.java index 341fc5c062..c2f4a6de78 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyEgressRuleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyEgressRuleBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NetworkPolicyEgressRuleBuilder extends io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NetworkPolicyEgressRuleBuilder + extends io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule, + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder> { public V1NetworkPolicyEgressRuleBuilder() { this(false); } + public V1NetworkPolicyEgressRuleBuilder(java.lang.Boolean validationEnabled) { this(new V1NetworkPolicyEgressRule(), validationEnabled); } - public V1NetworkPolicyEgressRuleBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent fluent) { + + public V1NetworkPolicyEgressRuleBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent fluent) { this(fluent, false); } - public V1NetworkPolicyEgressRuleBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NetworkPolicyEgressRuleBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NetworkPolicyEgressRule(), validationEnabled); } - public V1NetworkPolicyEgressRuleBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule instance) { + + public V1NetworkPolicyEgressRuleBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule instance) { this(fluent, instance, false); } - public V1NetworkPolicyEgressRuleBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NetworkPolicyEgressRuleBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPorts(instance.getPorts()); fluent.withTo(instance.getTo()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1NetworkPolicyEgressRuleBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule instance) { - this(instance,false); + + public V1NetworkPolicyEgressRuleBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule instance) { + this(instance, false); } - public V1NetworkPolicyEgressRuleBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NetworkPolicyEgressRuleBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPorts(instance.getPorts()); this.withTo(instance.getTo()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule build() { V1NetworkPolicyEgressRule buildable = new V1NetworkPolicyEgressRule(); buildable.setPorts(fluent.getPorts()); buildable.setTo(fluent.getTo()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NetworkPolicyEgressRuleBuilder that = (V1NetworkPolicyEgressRuleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyEgressRuleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyEgressRuleFluent.java index e1a7122400..3c65d7ba35 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyEgressRuleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyEgressRuleFluent.java @@ -1,92 +1,185 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NetworkPolicyEgressRuleFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); +/** Generated */ +public interface V1NetworkPolicyEgressRuleFluent< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); + public A addToPorts(io.kubernetes.client.openapi.models.V1NetworkPolicyPort... items); - public A addAllToPorts(java.util.Collection items); + + public A addAllToPorts( + java.util.Collection items); + public A removeFromPorts(io.kubernetes.client.openapi.models.V1NetworkPolicyPort... items); - public A removeAllFromPorts(java.util.Collection items); - public A removeMatchingFromPorts(java.util.function.Predicate predicate); - + + public A removeAllFromPorts( + java.util.Collection items); + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildPorts instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getPorts(); + public java.util.List buildPorts(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildPort(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildFirstPort(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildLastPort(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildMatchingPort(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildMatchingPort( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate); + public A withPorts(java.util.List ports); + public A withPorts(io.kubernetes.client.openapi.models.V1NetworkPolicyPort... ports); + public java.lang.Boolean hasPorts(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested addNewPort(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested editPort(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested editFirstPort(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested editLastPort(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate); - public A addToTo(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); - public A setToTo(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + addNewPort(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + addNewPortLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + editPort(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + editFirstPort(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + editLastPort(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + editMatchingPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder> + predicate); + + public A addToTo( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); + + public A setToTo( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); + public A addToTo(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer... items); - public A addAllToTo(java.util.Collection items); + + public A addAllToTo( + java.util.Collection items); + public A removeFromTo(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer... items); - public A removeAllFromTo(java.util.Collection items); - public A removeMatchingFromTo(java.util.function.Predicate predicate); - + + public A removeAllFromTo( + java.util.Collection items); + + public A removeMatchingFromTo( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildTo instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getTo(); + public java.util.List buildTo(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildTo(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildFirstTo(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildLastTo(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildMatchingTo(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingTo(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildMatchingTo( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingTo( + java.util.function.Predicate + predicate); + public A withTo(java.util.List to); + public A withTo(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer... to); + public java.lang.Boolean hasTo(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested addNewTo(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested addNewToLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested setNewToLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested editTo(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested editFirstTo(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested editLastTo(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested editMatchingTo(java.util.function.Predicate predicate); - public interface PortsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent>{ + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested + addNewToLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested + setNewToLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested editTo( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested + editFirstTo(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested + editLastTo(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested + editMatchingTo( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder> + predicate); + + public interface PortsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested> { public N and(); + public N endPort(); - } - public interface ToNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent>{ + + public interface ToNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested> { public N and(); + public N endTo(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyEgressRuleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyEgressRuleFluentImpl.java index 5c120f3185..e10fb05f82 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyEgressRuleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyEgressRuleFluentImpl.java @@ -1,60 +1,131 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1NetworkPolicyEgressRuleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent{ - public V1NetworkPolicyEgressRuleFluentImpl() { - } - public V1NetworkPolicyEgressRuleFluentImpl(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule instance) { + +/** Generated */ +public class V1NetworkPolicyEgressRuleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent { + public V1NetworkPolicyEgressRuleFluentImpl() {} + + public V1NetworkPolicyEgressRuleFluentImpl( + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule instance) { this.withPorts(instance.getPorts()); this.withTo(instance.getTo()); - } + private java.util.ArrayList ports; private java.util.ArrayList to; - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item);_visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder);this.ports.add(index >= 0 ? index : ports.size(), builder); return (A)this; + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); + _visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder); + this.ports.add(index >= 0 ? index : ports.size(), builder); + return (A) this; } - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); - if (index < 0 || index >= _visitables.get("ports").size()) { _visitables.get("ports").add(builder); } else { _visitables.get("ports").set(index, builder);} - if (index < 0 || index >= ports.size()) { ports.add(builder); } else { ports.set(index, builder);} - return (A)this; + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); + if (index < 0 || index >= _visitables.get("ports").size()) { + _visitables.get("ports").add(builder); + } else { + _visitables.get("ports").set(index, builder); + } + if (index < 0 || index >= ports.size()) { + ports.add(builder); + } else { + ports.set(index, builder); + } + return (A) this; } + public A addToPorts(io.kubernetes.client.openapi.models.V1NetworkPolicyPort... items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } - public A addAllToPorts(java.util.Collection items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + + public A addAllToPorts( + java.util.Collection items) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } + public A removeFromPorts(io.kubernetes.client.openapi.models.V1NetworkPolicyPort... items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeAllFromPorts(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + + public A removeAllFromPorts( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPorts(java.util.function.Predicate predicate) { + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate) { if (ports == null) return (A) this; - final Iterator each = ports.iterator(); + final Iterator each = + ports.iterator(); final List visitables = _visitables.get("ports"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = each.next(); @@ -63,104 +134,238 @@ public A removeMatchingFromPorts(java.util.function.Predicate getPorts() { return ports != null ? build(ports) : null; } + public java.util.List buildPorts() { return ports != null ? build(ports) : null; } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildPort( + java.lang.Integer index) { return this.ports.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildFirstPort() { return this.ports.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildLastPort() { return this.ports.get(ports.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder item: ports) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder item : ports) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder item: ports) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder item : ports) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withPorts(java.util.List ports) { - if (this.ports != null) { _visitables.get("ports").removeAll(this.ports);} - if (ports != null) {this.ports = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : ports){this.addToPorts(item);}} else { this.ports = null;} return (A) this; + + public A withPorts( + java.util.List ports) { + if (this.ports != null) { + _visitables.get("ports").removeAll(this.ports); + } + if (ports != null) { + this.ports = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : ports) { + this.addToPorts(item); + } + } else { + this.ports = null; + } + return (A) this; } + public A withPorts(io.kubernetes.client.openapi.models.V1NetworkPolicyPort... ports) { - if (this.ports != null) {this.ports.clear();} - if (ports != null) {for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item :ports){ this.addToPorts(item);}} return (A) this; + if (this.ports != null) { + this.ports.clear(); + } + if (ports != null) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : ports) { + this.addToPorts(item); + } + } + return (A) this; } + public java.lang.Boolean hasPorts() { return ports != null && !ports.isEmpty(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested addNewPort() { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl.PortsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + addNewPort() { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl + .PortsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl.PortsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + addNewPortLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl + .PortsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl.PortsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl + .PortsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested editPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + editPort(java.lang.Integer index) { if (ports.size() <= index) throw new RuntimeException("Can't edit ports. Index exceeds size."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested editFirstPort() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + editFirstPort() { if (ports.size() == 0) throw new RuntimeException("Can't edit first ports. The list is empty."); return setNewPortLike(0, buildPort(0)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested editLastPort() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + editLastPort() { int index = ports.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ports. The list is empty."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested + editMatchingPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item);_visitables.get("to").add(index >= 0 ? index : _visitables.get("to").size(), builder);this.to.add(index >= 0 ? index : to.size(), builder); return (A)this; + + public A addToTo( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { + if (this.to == null) { + this.to = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); + _visitables.get("to").add(index >= 0 ? index : _visitables.get("to").size(), builder); + this.to.add(index >= 0 ? index : to.size(), builder); + return (A) this; } - public A setToTo(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { - if (this.to == null) {this.to = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); - if (index < 0 || index >= _visitables.get("to").size()) { _visitables.get("to").add(builder); } else { _visitables.get("to").set(index, builder);} - if (index < 0 || index >= to.size()) { to.add(builder); } else { to.set(index, builder);} - return (A)this; + + public A setToTo( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { + if (this.to == null) { + this.to = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); + if (index < 0 || index >= _visitables.get("to").size()) { + _visitables.get("to").add(builder); + } else { + _visitables.get("to").set(index, builder); + } + if (index < 0 || index >= to.size()) { + to.add(builder); + } else { + to.set(index, builder); + } + return (A) this; } + public A addToTo(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer... items) { - if (this.to == null) {this.to = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item);_visitables.get("to").add(builder);this.to.add(builder);} return (A)this; + if (this.to == null) { + this.to = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); + _visitables.get("to").add(builder); + this.to.add(builder); + } + return (A) this; } - public A addAllToTo(java.util.Collection items) { - if (this.to == null) {this.to = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item);_visitables.get("to").add(builder);this.to.add(builder);} return (A)this; + + public A addAllToTo( + java.util.Collection items) { + if (this.to == null) { + this.to = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); + _visitables.get("to").add(builder); + this.to.add(builder); + } + return (A) this; } + public A removeFromTo(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer... items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item);_visitables.get("to").remove(builder);if (this.to != null) {this.to.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); + _visitables.get("to").remove(builder); + if (this.to != null) { + this.to.remove(builder); + } + } + return (A) this; } - public A removeAllFromTo(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item);_visitables.get("to").remove(builder);if (this.to != null) {this.to.remove(builder);}} return (A)this; + + public A removeAllFromTo( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); + _visitables.get("to").remove(builder); + if (this.to != null) { + this.to.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromTo(java.util.function.Predicate predicate) { + + public A removeMatchingFromTo( + java.util.function.Predicate + predicate) { if (to == null) return (A) this; - final Iterator each = to.iterator(); + final Iterator each = + to.iterator(); final List visitables = _visitables.get("to"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = each.next(); @@ -169,124 +374,208 @@ public A removeMatchingFromTo(java.util.function.Predicate getTo() { return to != null ? build(to) : null; } + public java.util.List buildTo() { return to != null ? build(to) : null; } + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildTo(java.lang.Integer index) { return this.to.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildFirstTo() { return this.to.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildLastTo() { return this.to.get(to.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildMatchingTo(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder item: to) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildMatchingTo( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder item : to) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingTo(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder item: to) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingTo( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder item : to) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withTo(java.util.List to) { - if (this.to != null) { _visitables.get("to").removeAll(this.to);} - if (to != null) {this.to = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : to){this.addToTo(item);}} else { this.to = null;} return (A) this; + if (this.to != null) { + _visitables.get("to").removeAll(this.to); + } + if (to != null) { + this.to = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : to) { + this.addToTo(item); + } + } else { + this.to = null; + } + return (A) this; } + public A withTo(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer... to) { - if (this.to != null) {this.to.clear();} - if (to != null) {for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item :to){ this.addToTo(item);}} return (A) this; + if (this.to != null) { + this.to.clear(); + } + if (to != null) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : to) { + this.addToTo(item); + } + } + return (A) this; } + public java.lang.Boolean hasTo() { return to != null && !to.isEmpty(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested addNewTo() { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl.ToNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested + addNewTo() { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl + .ToNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested addNewToLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl.ToNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested + addNewToLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl.ToNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested setNewToLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl.ToNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested + setNewToLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl.ToNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested editTo(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested editTo( + java.lang.Integer index) { if (to.size() <= index) throw new RuntimeException("Can't edit to. Index exceeds size."); return setNewToLike(index, buildTo(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested editFirstTo() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested + editFirstTo() { if (to.size() == 0) throw new RuntimeException("Can't edit first to. The list is empty."); return setNewToLike(0, buildTo(0)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested editLastTo() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested + editLastTo() { int index = to.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last to. The list is empty."); return setNewToLike(index, buildTo(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested editMatchingTo(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested + editMatchingTo( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested,io.kubernetes.client.fluent.Nested{ - PortsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { + + public class PortsNestedImpl + extends io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.PortsNested, + io.kubernetes.client.fluent.Nested { + PortsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(this, item); } + PortsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(this); } + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NetworkPolicyEgressRuleFluentImpl.this.setToPorts(index,builder.build()); + return (N) V1NetworkPolicyEgressRuleFluentImpl.this.setToPorts(index, builder.build()); } + public N endPort() { return and(); } - } - public class ToNestedImpl extends io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested,io.kubernetes.client.fluent.Nested{ - ToNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { + + public class ToNestedImpl + extends io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent.ToNested, + io.kubernetes.client.fluent.Nested { + ToNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(this, item); } + ToNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(this); } + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NetworkPolicyEgressRuleFluentImpl.this.setToTo(index,builder.build()); + return (N) V1NetworkPolicyEgressRuleFluentImpl.this.setToTo(index, builder.build()); } + public N endTo() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyFluent.java index af09119a95..3a76b354a7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyFluent.java @@ -1,73 +1,110 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NetworkPolicyFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NetworkPolicyFluent< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicyFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NetworkPolicySpec getSpec(); + public io.kubernetes.client.openapi.models.V1NetworkPolicySpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1NetworkPolicySpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1NetworkPolicySpec item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1NetworkPolicySpec item); + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1NetworkPolicySpec item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1NetworkPolicySpec item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested> { public N and(); + public N endSpec(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyFluentImpl.java index 25ef589930..35dec1fbe1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1NetworkPolicyFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicyFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NetworkPolicyFluent { + public V1NetworkPolicyFluentImpl() {} - /** - * Generated - */ -public class V1NetworkPolicyFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NetworkPolicyFluent{ - public V1NetworkPolicyFluentImpl() { - } public V1NetworkPolicyFluentImpl(io.kubernetes.client.openapi.models.V1NetworkPolicy instance) { this.withApiVersion(instance.getApiVersion()); @@ -21,158 +27,220 @@ public V1NetworkPolicyFluentImpl(io.kubernetes.client.openapi.models.V1NetworkPo this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1NetworkPolicySpecBuilder spec; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1NetworkPolicyFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NetworkPolicySpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1NetworkPolicySpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1NetworkPolicySpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1NetworkPolicySpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1NetworkPolicySpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1NetworkPolicyFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1NetworkPolicySpec item) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1NetworkPolicySpec item) { return new io.kubernetes.client.openapi.models.V1NetworkPolicyFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1NetworkPolicySpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1NetworkPolicySpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1NetworkPolicySpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1NetworkPolicySpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NetworkPolicyFluentImpl that = (V1NetworkPolicyFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1NetworkPolicyFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicyFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1NetworkPolicySpec item) { this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicySpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicySpecBuilder(this); } + io.kubernetes.client.openapi.models.V1NetworkPolicySpecBuilder builder; + public N and() { return (N) V1NetworkPolicyFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyIngressRuleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyIngressRuleBuilder.java index 9aac9f0cbd..6377b49cf8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyIngressRuleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyIngressRuleBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NetworkPolicyIngressRuleBuilder extends io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NetworkPolicyIngressRuleBuilder + extends io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule, + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder> { public V1NetworkPolicyIngressRuleBuilder() { this(false); } + public V1NetworkPolicyIngressRuleBuilder(java.lang.Boolean validationEnabled) { this(new V1NetworkPolicyIngressRule(), validationEnabled); } - public V1NetworkPolicyIngressRuleBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent fluent) { + + public V1NetworkPolicyIngressRuleBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent fluent) { this(fluent, false); } - public V1NetworkPolicyIngressRuleBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NetworkPolicyIngressRuleBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NetworkPolicyIngressRule(), validationEnabled); } - public V1NetworkPolicyIngressRuleBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule instance) { + + public V1NetworkPolicyIngressRuleBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule instance) { this(fluent, instance, false); } - public V1NetworkPolicyIngressRuleBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NetworkPolicyIngressRuleBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFrom(instance.getFrom()); fluent.withPorts(instance.getPorts()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1NetworkPolicyIngressRuleBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule instance) { - this(instance,false); + + public V1NetworkPolicyIngressRuleBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule instance) { + this(instance, false); } - public V1NetworkPolicyIngressRuleBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NetworkPolicyIngressRuleBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFrom(instance.getFrom()); this.withPorts(instance.getPorts()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule build() { V1NetworkPolicyIngressRule buildable = new V1NetworkPolicyIngressRule(); buildable.setFrom(fluent.getFrom()); buildable.setPorts(fluent.getPorts()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NetworkPolicyIngressRuleBuilder that = (V1NetworkPolicyIngressRuleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyIngressRuleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyIngressRuleFluent.java index 21080be972..3113e4f5a5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyIngressRuleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyIngressRuleFluent.java @@ -1,92 +1,186 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NetworkPolicyIngressRuleFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToFrom(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); - public A setToFrom(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); +/** Generated */ +public interface V1NetworkPolicyIngressRuleFluent< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToFrom( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); + + public A setToFrom( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); + public A addToFrom(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer... items); - public A addAllToFrom(java.util.Collection items); + + public A addAllToFrom( + java.util.Collection items); + public A removeFromFrom(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer... items); - public A removeAllFromFrom(java.util.Collection items); - public A removeMatchingFromFrom(java.util.function.Predicate predicate); - + + public A removeAllFromFrom( + java.util.Collection items); + + public A removeMatchingFromFrom( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildFrom instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getFrom(); + public java.util.List buildFrom(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildFrom(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildFirstFrom(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildLastFrom(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildMatchingFrom(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingFrom(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildMatchingFrom( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingFrom( + java.util.function.Predicate + predicate); + public A withFrom(java.util.List from); + public A withFrom(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer... from); + public java.lang.Boolean hasFrom(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested addNewFrom(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested addNewFromLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested setNewFromLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested editFrom(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested editFirstFrom(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested editLastFrom(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested editMatchingFrom(java.util.function.Predicate predicate); - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + addNewFrom(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + addNewFromLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + setNewFromLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + editFrom(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + editFirstFrom(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + editLastFrom(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + editMatchingFrom( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder> + predicate); + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); + public A addToPorts(io.kubernetes.client.openapi.models.V1NetworkPolicyPort... items); - public A addAllToPorts(java.util.Collection items); + + public A addAllToPorts( + java.util.Collection items); + public A removeFromPorts(io.kubernetes.client.openapi.models.V1NetworkPolicyPort... items); - public A removeAllFromPorts(java.util.Collection items); - public A removeMatchingFromPorts(java.util.function.Predicate predicate); - + + public A removeAllFromPorts( + java.util.Collection items); + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildPorts instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getPorts(); + public java.util.List buildPorts(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildPort(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildFirstPort(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildLastPort(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildMatchingPort(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildMatchingPort( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate); + public A withPorts(java.util.List ports); + public A withPorts(io.kubernetes.client.openapi.models.V1NetworkPolicyPort... ports); + public java.lang.Boolean hasPorts(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested addNewPort(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested editPort(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested editFirstPort(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested editLastPort(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate); - public interface FromNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent>{ + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + addNewPort(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + addNewPortLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + editPort(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + editFirstPort(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + editLastPort(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + editMatchingPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder> + predicate); + + public interface FromNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested> { public N and(); + public N endFrom(); - } - public interface PortsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent>{ + + public interface PortsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested> { public N and(); + public N endPort(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyIngressRuleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyIngressRuleFluentImpl.java index b32b08e304..5edd248ff5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyIngressRuleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyIngressRuleFluentImpl.java @@ -1,60 +1,131 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1NetworkPolicyIngressRuleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent{ - public V1NetworkPolicyIngressRuleFluentImpl() { - } - public V1NetworkPolicyIngressRuleFluentImpl(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule instance) { + +/** Generated */ +public class V1NetworkPolicyIngressRuleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent { + public V1NetworkPolicyIngressRuleFluentImpl() {} + + public V1NetworkPolicyIngressRuleFluentImpl( + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule instance) { this.withFrom(instance.getFrom()); this.withPorts(instance.getPorts()); - } + private java.util.ArrayList from; private java.util.ArrayList ports; - public A addToFrom(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { - if (this.from == null) {this.from = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item);_visitables.get("from").add(index >= 0 ? index : _visitables.get("from").size(), builder);this.from.add(index >= 0 ? index : from.size(), builder); return (A)this; + + public A addToFrom( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { + if (this.from == null) { + this.from = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); + _visitables.get("from").add(index >= 0 ? index : _visitables.get("from").size(), builder); + this.from.add(index >= 0 ? index : from.size(), builder); + return (A) this; } - public A setToFrom(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { - if (this.from == null) {this.from = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); - if (index < 0 || index >= _visitables.get("from").size()) { _visitables.get("from").add(builder); } else { _visitables.get("from").set(index, builder);} - if (index < 0 || index >= from.size()) { from.add(builder); } else { from.set(index, builder);} - return (A)this; + + public A setToFrom( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { + if (this.from == null) { + this.from = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); + if (index < 0 || index >= _visitables.get("from").size()) { + _visitables.get("from").add(builder); + } else { + _visitables.get("from").set(index, builder); + } + if (index < 0 || index >= from.size()) { + from.add(builder); + } else { + from.set(index, builder); + } + return (A) this; } + public A addToFrom(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer... items) { - if (this.from == null) {this.from = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item);_visitables.get("from").add(builder);this.from.add(builder);} return (A)this; + if (this.from == null) { + this.from = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); + _visitables.get("from").add(builder); + this.from.add(builder); + } + return (A) this; } - public A addAllToFrom(java.util.Collection items) { - if (this.from == null) {this.from = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item);_visitables.get("from").add(builder);this.from.add(builder);} return (A)this; + + public A addAllToFrom( + java.util.Collection items) { + if (this.from == null) { + this.from = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); + _visitables.get("from").add(builder); + this.from.add(builder); + } + return (A) this; } + public A removeFromFrom(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer... items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item);_visitables.get("from").remove(builder);if (this.from != null) {this.from.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); + _visitables.get("from").remove(builder); + if (this.from != null) { + this.from.remove(builder); + } + } + return (A) this; } - public A removeAllFromFrom(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item);_visitables.get("from").remove(builder);if (this.from != null) {this.from.remove(builder);}} return (A)this; + + public A removeAllFromFrom( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(item); + _visitables.get("from").remove(builder); + if (this.from != null) { + this.from.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromFrom(java.util.function.Predicate predicate) { + + public A removeMatchingFromFrom( + java.util.function.Predicate + predicate) { if (from == null) return (A) this; - final Iterator each = from.iterator(); + final Iterator each = + from.iterator(); final List visitables = _visitables.get("from"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder = each.next(); @@ -63,104 +134,237 @@ public A removeMatchingFromFrom(java.util.function.Predicate getFrom() { return from != null ? build(from) : null; } + public java.util.List buildFrom() { return from != null ? build(from) : null; } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildFrom(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildFrom( + java.lang.Integer index) { return this.from.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildFirstFrom() { return this.from.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildLastFrom() { return this.from.get(from.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildMatchingFrom(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder item: from) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer buildMatchingFrom( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder item : from) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingFrom(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder item: from) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingFrom( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder item : from) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withFrom(java.util.List from) { - if (this.from != null) { _visitables.get("from").removeAll(this.from);} - if (from != null) {this.from = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : from){this.addToFrom(item);}} else { this.from = null;} return (A) this; + if (this.from != null) { + _visitables.get("from").removeAll(this.from); + } + if (from != null) { + this.from = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : from) { + this.addToFrom(item); + } + } else { + this.from = null; + } + return (A) this; } + public A withFrom(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer... from) { - if (this.from != null) {this.from.clear();} - if (from != null) {for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item :from){ this.addToFrom(item);}} return (A) this; + if (this.from != null) { + this.from.clear(); + } + if (from != null) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item : from) { + this.addToFrom(item); + } + } + return (A) this; } + public java.lang.Boolean hasFrom() { return from != null && !from.isEmpty(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested addNewFrom() { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl.FromNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + addNewFrom() { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl + .FromNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested addNewFromLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl.FromNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + addNewFromLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl + .FromNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested setNewFromLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl.FromNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + setNewFromLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl + .FromNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested editFrom(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + editFrom(java.lang.Integer index) { if (from.size() <= index) throw new RuntimeException("Can't edit from. Index exceeds size."); return setNewFromLike(index, buildFrom(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested editFirstFrom() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + editFirstFrom() { if (from.size() == 0) throw new RuntimeException("Can't edit first from. The list is empty."); return setNewFromLike(0, buildFrom(0)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested editLastFrom() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + editLastFrom() { int index = from.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last from. The list is empty."); return setNewFromLike(index, buildFrom(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested editMatchingFrom(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested + editMatchingFrom( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item);_visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder);this.ports.add(index >= 0 ? index : ports.size(), builder); return (A)this; + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); + _visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder); + this.ports.add(index >= 0 ? index : ports.size(), builder); + return (A) this; } - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); - if (index < 0 || index >= _visitables.get("ports").size()) { _visitables.get("ports").add(builder); } else { _visitables.get("ports").set(index, builder);} - if (index < 0 || index >= ports.size()) { ports.add(builder); } else { ports.set(index, builder);} - return (A)this; + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); + if (index < 0 || index >= _visitables.get("ports").size()) { + _visitables.get("ports").add(builder); + } else { + _visitables.get("ports").set(index, builder); + } + if (index < 0 || index >= ports.size()) { + ports.add(builder); + } else { + ports.set(index, builder); + } + return (A) this; } + public A addToPorts(io.kubernetes.client.openapi.models.V1NetworkPolicyPort... items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } - public A addAllToPorts(java.util.Collection items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + + public A addAllToPorts( + java.util.Collection items) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } + public A removeFromPorts(io.kubernetes.client.openapi.models.V1NetworkPolicyPort... items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeAllFromPorts(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + + public A removeAllFromPorts( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPorts(java.util.function.Predicate predicate) { + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate) { if (ports == null) return (A) this; - final Iterator each = ports.iterator(); + final Iterator each = + ports.iterator(); final List visitables = _visitables.get("ports"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder = each.next(); @@ -169,124 +373,211 @@ public A removeMatchingFromPorts(java.util.function.Predicate getPorts() { return ports != null ? build(ports) : null; } + public java.util.List buildPorts() { return ports != null ? build(ports) : null; } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildPort( + java.lang.Integer index) { return this.ports.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildFirstPort() { return this.ports.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildLastPort() { return this.ports.get(ports.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder item: ports) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort buildMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder item : ports) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder item: ports) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder item : ports) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withPorts(java.util.List ports) { - if (this.ports != null) { _visitables.get("ports").removeAll(this.ports);} - if (ports != null) {this.ports = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : ports){this.addToPorts(item);}} else { this.ports = null;} return (A) this; + + public A withPorts( + java.util.List ports) { + if (this.ports != null) { + _visitables.get("ports").removeAll(this.ports); + } + if (ports != null) { + this.ports = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : ports) { + this.addToPorts(item); + } + } else { + this.ports = null; + } + return (A) this; } + public A withPorts(io.kubernetes.client.openapi.models.V1NetworkPolicyPort... ports) { - if (this.ports != null) {this.ports.clear();} - if (ports != null) {for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item :ports){ this.addToPorts(item);}} return (A) this; + if (this.ports != null) { + this.ports.clear(); + } + if (ports != null) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyPort item : ports) { + this.addToPorts(item); + } + } + return (A) this; } + public java.lang.Boolean hasPorts() { return ports != null && !ports.isEmpty(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested addNewPort() { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl.PortsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + addNewPort() { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl + .PortsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl.PortsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + addNewPortLike(io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl + .PortsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl.PortsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl + .PortsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested editPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + editPort(java.lang.Integer index) { if (ports.size() <= index) throw new RuntimeException("Can't edit ports. Index exceeds size."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested editFirstPort() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + editFirstPort() { if (ports.size() == 0) throw new RuntimeException("Can't edit first ports. The list is empty."); return setNewPortLike(0, buildPort(0)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested editLastPort() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + editLastPort() { int index = ports.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ports. The list is empty."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested + editMatchingPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested,io.kubernetes.client.fluent.Nested{ - FromNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { + + public class FromNestedImpl + extends io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.FromNested, + io.kubernetes.client.fluent.Nested { + FromNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPeer item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(this, item); } + FromNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder(this); } + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NetworkPolicyIngressRuleFluentImpl.this.setToFrom(index,builder.build()); + return (N) V1NetworkPolicyIngressRuleFluentImpl.this.setToFrom(index, builder.build()); } + public N endFrom() { return and(); } - } - public class PortsNestedImpl extends io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested,io.kubernetes.client.fluent.Nested{ - PortsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { + + public class PortsNestedImpl + extends io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent.PortsNested< + N>, + io.kubernetes.client.fluent.Nested { + PortsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyPort item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(this, item); } + PortsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder(this); } + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NetworkPolicyIngressRuleFluentImpl.this.setToPorts(index,builder.build()); + return (N) V1NetworkPolicyIngressRuleFluentImpl.this.setToPorts(index, builder.build()); } + public N endPort() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyListBuilder.java index aaebf4c92a..95b42a8862 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NetworkPolicyListBuilder extends io.kubernetes.client.openapi.models.V1NetworkPolicyListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NetworkPolicyListBuilder + extends io.kubernetes.client.openapi.models.V1NetworkPolicyListFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NetworkPolicyList, + io.kubernetes.client.openapi.models.V1NetworkPolicyListBuilder> { public V1NetworkPolicyListBuilder() { this(false); } + public V1NetworkPolicyListBuilder(java.lang.Boolean validationEnabled) { this(new V1NetworkPolicyList(), validationEnabled); } - public V1NetworkPolicyListBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent fluent) { + + public V1NetworkPolicyListBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent fluent) { this(fluent, false); } - public V1NetworkPolicyListBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NetworkPolicyListBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NetworkPolicyList(), validationEnabled); } - public V1NetworkPolicyListBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicyList instance) { + + public V1NetworkPolicyListBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicyList instance) { this(fluent, instance, false); } - public V1NetworkPolicyListBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicyList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NetworkPolicyListBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicyList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1NetworkPolicyListBuilder(io.kubernetes.client.openapi.models.V1NetworkP fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1NetworkPolicyListBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyList instance) { - this(instance,false); + + public V1NetworkPolicyListBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyList instance) { + this(instance, false); } - public V1NetworkPolicyListBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NetworkPolicyListBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1NetworkPolicyListBuilder(io.kubernetes.client.openapi.models.V1NetworkP this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NetworkPolicyList build() { V1NetworkPolicyList buildable = new V1NetworkPolicyList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1NetworkPolicyList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NetworkPolicyListBuilder that = (V1NetworkPolicyListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyListFluent.java index 56a12783aa..aa8983f3b3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyListFluent.java @@ -1,95 +1,158 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NetworkPolicyListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NetworkPolicyListFluent< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicy item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicy item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicy item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicy item); + public A addToItems(io.kubernetes.client.openapi.models.V1NetworkPolicy... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1NetworkPolicy... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1NetworkPolicy buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NetworkPolicy buildFirstItem(); + public io.kubernetes.client.openapi.models.V1NetworkPolicy buildLastItem(); - public io.kubernetes.client.openapi.models.V1NetworkPolicy buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1NetworkPolicy buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1NetworkPolicy... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1NetworkPolicy item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicy item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1NetworkPolicy item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicy item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NetworkPolicyFluent>{ + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NetworkPolicyFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyListFluentImpl.java index 50a3e87330..d567f472ef 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1NetworkPolicyListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent{ - public V1NetworkPolicyListFluentImpl() { - } - public V1NetworkPolicyListFluentImpl(io.kubernetes.client.openapi.models.V1NetworkPolicyList instance) { + +/** Generated */ +public class V1NetworkPolicyListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent { + public V1NetworkPolicyListFluentImpl() {} + + public V1NetworkPolicyListFluentImpl( + io.kubernetes.client.openapi.models.V1NetworkPolicyList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1NetworkPolicyListFluentImpl(io.kubernetes.client.openapi.models.V1Netwo this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicy item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicy item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicy item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicy item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1NetworkPolicy... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicy item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicy item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicy item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicy item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1NetworkPolicy... items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicy item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1NetworkPolicy item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicy item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicy item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder = each.next(); @@ -87,174 +159,280 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1NetworkPolicy buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicy buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicy buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicy buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NetworkPolicy buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NetworkPolicy item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NetworkPolicy item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1NetworkPolicy... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1NetworkPolicy item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicy item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1NetworkPolicyListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1NetworkPolicy item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1NetworkPolicy item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicy item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicy item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NetworkPolicyListFluentImpl that = (V1NetworkPolicyListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1NetworkPolicyFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicy item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1NetworkPolicyFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicy item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder(this); } + io.kubernetes.client.openapi.models.V1NetworkPolicyBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NetworkPolicyListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1NetworkPolicyListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicyListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1NetworkPolicyListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPeerBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPeerBuilder.java index 5feeb3ba43..1b8ce37dee 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPeerBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPeerBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NetworkPolicyPeerBuilder extends io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NetworkPolicyPeerBuilder + extends io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NetworkPolicyPeer, + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerBuilder> { public V1NetworkPolicyPeerBuilder() { this(false); } + public V1NetworkPolicyPeerBuilder(java.lang.Boolean validationEnabled) { this(new V1NetworkPolicyPeer(), validationEnabled); } - public V1NetworkPolicyPeerBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent fluent) { + + public V1NetworkPolicyPeerBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent fluent) { this(fluent, false); } - public V1NetworkPolicyPeerBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NetworkPolicyPeerBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NetworkPolicyPeer(), validationEnabled); } - public V1NetworkPolicyPeerBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer instance) { + + public V1NetworkPolicyPeerBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicyPeer instance) { this(fluent, instance, false); } - public V1NetworkPolicyPeerBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicyPeer instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NetworkPolicyPeerBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicyPeer instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withIpBlock(instance.getIpBlock()); fluent.withNamespaceSelector(instance.getNamespaceSelector()); fluent.withPodSelector(instance.getPodSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1NetworkPolicyPeerBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer instance) { - this(instance,false); + + public V1NetworkPolicyPeerBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyPeer instance) { + this(instance, false); } - public V1NetworkPolicyPeerBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NetworkPolicyPeerBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyPeer instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withIpBlock(instance.getIpBlock()); this.withNamespaceSelector(instance.getNamespaceSelector()); this.withPodSelector(instance.getPodSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer build() { V1NetworkPolicyPeer buildable = new V1NetworkPolicyPeer(); buildable.setIpBlock(fluent.getIpBlock()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1NetworkPolicyPeer build() { buildable.setPodSelector(fluent.getPodSelector()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NetworkPolicyPeerBuilder that = (V1NetworkPolicyPeerBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPeerFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPeerFluent.java index 3c625e897a..530df6ee51 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPeerFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPeerFluent.java @@ -1,75 +1,135 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NetworkPolicyPeerFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1NetworkPolicyPeerFluent< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildIpBlock instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IPBlock getIpBlock(); + public io.kubernetes.client.openapi.models.V1IPBlock buildIpBlock(); + public A withIpBlock(io.kubernetes.client.openapi.models.V1IPBlock ipBlock); + public java.lang.Boolean hasIpBlock(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested withNewIpBlock(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested withNewIpBlockLike(io.kubernetes.client.openapi.models.V1IPBlock item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested editIpBlock(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested editOrNewIpBlock(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested editOrNewIpBlockLike(io.kubernetes.client.openapi.models.V1IPBlock item); - + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested + withNewIpBlock(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested + withNewIpBlockLike(io.kubernetes.client.openapi.models.V1IPBlock item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested + editIpBlock(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested + editOrNewIpBlock(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested + editOrNewIpBlockLike(io.kubernetes.client.openapi.models.V1IPBlock item); + /** * This method has been deprecated, please use method buildNamespaceSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getNamespaceSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildNamespaceSelector(); - public A withNamespaceSelector(io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector); + + public A withNamespaceSelector( + io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector); + public java.lang.Boolean hasNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested withNewNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested editNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested editOrNewNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested + withNewNamespaceSelector(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested + withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested + editNamespaceSelector(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested + editOrNewNamespaceSelector(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested + editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + /** * This method has been deprecated, please use method buildPodSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getPodSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildPodSelector(); + public A withPodSelector(io.kubernetes.client.openapi.models.V1LabelSelector podSelector); + public java.lang.Boolean hasPodSelector(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested withNewPodSelector(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested withNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested editPodSelector(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested editOrNewPodSelector(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested editOrNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public interface IpBlockNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1IPBlockFluent>{ + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested + withNewPodSelector(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested + withNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested + editPodSelector(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested + editOrNewPodSelector(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested + editOrNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public interface IpBlockNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1IPBlockFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested> { public N and(); + public N endIpBlock(); - } - public interface NamespaceSelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface NamespaceSelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested< + N>> { public N and(); + public N endNamespaceSelector(); - } - public interface PodSelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface PodSelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested> { public N and(); + public N endPodSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPeerFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPeerFluentImpl.java index d1eaffdb3b..a104e0e9d0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPeerFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPeerFluentImpl.java @@ -1,189 +1,300 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1NetworkPolicyPeerFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent { + public V1NetworkPolicyPeerFluentImpl() {} - /** - * Generated - */ -public class V1NetworkPolicyPeerFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent{ - public V1NetworkPolicyPeerFluentImpl() { - } - public V1NetworkPolicyPeerFluentImpl(io.kubernetes.client.openapi.models.V1NetworkPolicyPeer instance) { + public V1NetworkPolicyPeerFluentImpl( + io.kubernetes.client.openapi.models.V1NetworkPolicyPeer instance) { this.withIpBlock(instance.getIpBlock()); this.withNamespaceSelector(instance.getNamespaceSelector()); this.withPodSelector(instance.getPodSelector()); - } + private io.kubernetes.client.openapi.models.V1IPBlockBuilder ipBlock; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder namespaceSelector; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder podSelector; - + /** * This method has been deprecated, please use method buildIpBlock instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1IPBlock getIpBlock() { - return this.ipBlock!=null ?this.ipBlock.build():null; + return this.ipBlock != null ? this.ipBlock.build() : null; } + public io.kubernetes.client.openapi.models.V1IPBlock buildIpBlock() { - return this.ipBlock!=null ?this.ipBlock.build():null; + return this.ipBlock != null ? this.ipBlock.build() : null; } + public A withIpBlock(io.kubernetes.client.openapi.models.V1IPBlock ipBlock) { _visitables.get("ipBlock").remove(this.ipBlock); - if (ipBlock!=null){ this.ipBlock= new io.kubernetes.client.openapi.models.V1IPBlockBuilder(ipBlock); _visitables.get("ipBlock").add(this.ipBlock);} return (A) this; + if (ipBlock != null) { + this.ipBlock = new io.kubernetes.client.openapi.models.V1IPBlockBuilder(ipBlock); + _visitables.get("ipBlock").add(this.ipBlock); + } + return (A) this; } + public java.lang.Boolean hasIpBlock() { return this.ipBlock != null; } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested withNewIpBlock() { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl.IpBlockNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested + withNewIpBlock() { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl + .IpBlockNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested withNewIpBlockLike(io.kubernetes.client.openapi.models.V1IPBlock item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl.IpBlockNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested + withNewIpBlockLike(io.kubernetes.client.openapi.models.V1IPBlock item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl.IpBlockNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested editIpBlock() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested + editIpBlock() { return withNewIpBlockLike(getIpBlock()); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested editOrNewIpBlock() { - return withNewIpBlockLike(getIpBlock() != null ? getIpBlock(): new io.kubernetes.client.openapi.models.V1IPBlockBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested + editOrNewIpBlock() { + return withNewIpBlockLike( + getIpBlock() != null + ? getIpBlock() + : new io.kubernetes.client.openapi.models.V1IPBlockBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested editOrNewIpBlockLike(io.kubernetes.client.openapi.models.V1IPBlock item) { - return withNewIpBlockLike(getIpBlock() != null ? getIpBlock(): item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested + editOrNewIpBlockLike(io.kubernetes.client.openapi.models.V1IPBlock item) { + return withNewIpBlockLike(getIpBlock() != null ? getIpBlock() : item); } - + /** * This method has been deprecated, please use method buildNamespaceSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getNamespaceSelector() { - return this.namespaceSelector!=null ?this.namespaceSelector.build():null; + return this.namespaceSelector != null ? this.namespaceSelector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildNamespaceSelector() { - return this.namespaceSelector!=null ?this.namespaceSelector.build():null; + return this.namespaceSelector != null ? this.namespaceSelector.build() : null; } - public A withNamespaceSelector(io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector) { + + public A withNamespaceSelector( + io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector) { _visitables.get("namespaceSelector").remove(this.namespaceSelector); - if (namespaceSelector!=null){ this.namespaceSelector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(namespaceSelector); _visitables.get("namespaceSelector").add(this.namespaceSelector);} return (A) this; + if (namespaceSelector != null) { + this.namespaceSelector = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(namespaceSelector); + _visitables.get("namespaceSelector").add(this.namespaceSelector); + } + return (A) this; } + public java.lang.Boolean hasNamespaceSelector() { return this.namespaceSelector != null; } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested withNewNamespaceSelector() { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl.NamespaceSelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested + withNewNamespaceSelector() { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl + .NamespaceSelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl.NamespaceSelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested + withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl + .NamespaceSelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested editNamespaceSelector() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested + editNamespaceSelector() { return withNewNamespaceSelectorLike(getNamespaceSelector()); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested editOrNewNamespaceSelector() { - return withNewNamespaceSelectorLike(getNamespaceSelector() != null ? getNamespaceSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested + editOrNewNamespaceSelector() { + return withNewNamespaceSelectorLike( + getNamespaceSelector() != null + ? getNamespaceSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewNamespaceSelectorLike(getNamespaceSelector() != null ? getNamespaceSelector(): item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested + editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewNamespaceSelectorLike( + getNamespaceSelector() != null ? getNamespaceSelector() : item); } - + /** * This method has been deprecated, please use method buildPodSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getPodSelector() { - return this.podSelector!=null ?this.podSelector.build():null; + return this.podSelector != null ? this.podSelector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildPodSelector() { - return this.podSelector!=null ?this.podSelector.build():null; + return this.podSelector != null ? this.podSelector.build() : null; } + public A withPodSelector(io.kubernetes.client.openapi.models.V1LabelSelector podSelector) { _visitables.get("podSelector").remove(this.podSelector); - if (podSelector!=null){ this.podSelector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(podSelector); _visitables.get("podSelector").add(this.podSelector);} return (A) this; + if (podSelector != null) { + this.podSelector = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(podSelector); + _visitables.get("podSelector").add(this.podSelector); + } + return (A) this; } + public java.lang.Boolean hasPodSelector() { return this.podSelector != null; } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested withNewPodSelector() { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl.PodSelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested + withNewPodSelector() { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl + .PodSelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested withNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl.PodSelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested + withNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluentImpl + .PodSelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested editPodSelector() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested + editPodSelector() { return withNewPodSelectorLike(getPodSelector()); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested editOrNewPodSelector() { - return withNewPodSelectorLike(getPodSelector() != null ? getPodSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested + editOrNewPodSelector() { + return withNewPodSelectorLike( + getPodSelector() != null + ? getPodSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested editOrNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewPodSelectorLike(getPodSelector() != null ? getPodSelector(): item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested + editOrNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewPodSelectorLike(getPodSelector() != null ? getPodSelector() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NetworkPolicyPeerFluentImpl that = (V1NetworkPolicyPeerFluentImpl) o; - if (ipBlock != null ? !ipBlock.equals(that.ipBlock) :that.ipBlock != null) return false; - if (namespaceSelector != null ? !namespaceSelector.equals(that.namespaceSelector) :that.namespaceSelector != null) return false; - if (podSelector != null ? !podSelector.equals(that.podSelector) :that.podSelector != null) return false; + if (ipBlock != null ? !ipBlock.equals(that.ipBlock) : that.ipBlock != null) return false; + if (namespaceSelector != null + ? !namespaceSelector.equals(that.namespaceSelector) + : that.namespaceSelector != null) return false; + if (podSelector != null ? !podSelector.equals(that.podSelector) : that.podSelector != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(ipBlock, namespaceSelector, podSelector, super.hashCode()); + return java.util.Objects.hash(ipBlock, namespaceSelector, podSelector, super.hashCode()); } - public class IpBlockNestedImpl extends io.kubernetes.client.openapi.models.V1IPBlockFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested,io.kubernetes.client.fluent.Nested{ + + public class IpBlockNestedImpl + extends io.kubernetes.client.openapi.models.V1IPBlockFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.IpBlockNested, + io.kubernetes.client.fluent.Nested { IpBlockNestedImpl(io.kubernetes.client.openapi.models.V1IPBlock item) { this.builder = new io.kubernetes.client.openapi.models.V1IPBlockBuilder(this, item); } + IpBlockNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1IPBlockBuilder(this); } + io.kubernetes.client.openapi.models.V1IPBlockBuilder builder; + public N and() { return (N) V1NetworkPolicyPeerFluentImpl.this.withIpBlock(builder.build()); } + public N endIpBlock() { return and(); } - } - public class NamespaceSelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested,io.kubernetes.client.fluent.Nested{ + + public class NamespaceSelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.NamespaceSelectorNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent + .NamespaceSelectorNested< + N>, + io.kubernetes.client.fluent.Nested { NamespaceSelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + NamespaceSelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1NetworkPolicyPeerFluentImpl.this.withNamespaceSelector(builder.build()); } + public N endNamespaceSelector() { return and(); } - } - public class PodSelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested,io.kubernetes.client.fluent.Nested{ + + public class PodSelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicyPeerFluent.PodSelectorNested, + io.kubernetes.client.fluent.Nested { PodSelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + PodSelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1NetworkPolicyPeerFluentImpl.this.withPodSelector(builder.build()); } + public N endPodSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPortBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPortBuilder.java index 6caa4246f0..d1c0f7350e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPortBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPortBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NetworkPolicyPortBuilder extends io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NetworkPolicyPortBuilder + extends io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NetworkPolicyPort, + io.kubernetes.client.openapi.models.V1NetworkPolicyPortBuilder> { public V1NetworkPolicyPortBuilder() { this(false); } + public V1NetworkPolicyPortBuilder(java.lang.Boolean validationEnabled) { this(new V1NetworkPolicyPort(), validationEnabled); } - public V1NetworkPolicyPortBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent fluent) { + + public V1NetworkPolicyPortBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent fluent) { this(fluent, false); } - public V1NetworkPolicyPortBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NetworkPolicyPortBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NetworkPolicyPort(), validationEnabled); } - public V1NetworkPolicyPortBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicyPort instance) { + + public V1NetworkPolicyPortBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicyPort instance) { this(fluent, instance, false); } - public V1NetworkPolicyPortBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicyPort instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NetworkPolicyPortBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicyPort instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withEndPort(instance.getEndPort()); fluent.withPort(instance.getPort()); fluent.withProtocol(instance.getProtocol()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1NetworkPolicyPortBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyPort instance) { - this(instance,false); + + public V1NetworkPolicyPortBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyPort instance) { + this(instance, false); } - public V1NetworkPolicyPortBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicyPort instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NetworkPolicyPortBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicyPort instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withEndPort(instance.getEndPort()); this.withPort(instance.getPort()); this.withProtocol(instance.getProtocol()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NetworkPolicyPort build() { V1NetworkPolicyPort buildable = new V1NetworkPolicyPort(); buildable.setEndPort(fluent.getEndPort()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1NetworkPolicyPort build() { buildable.setProtocol(fluent.getProtocol()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NetworkPolicyPortBuilder that = (V1NetworkPolicyPortBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPortFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPortFluent.java index 401bd02861..d55ffce30b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPortFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPortFluent.java @@ -1,33 +1,44 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.custom.IntOrString; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NetworkPolicyPortFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NetworkPolicyPortFluent< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getEndPort(); + public A withEndPort(java.lang.Integer endPort); + public java.lang.Boolean hasEndPort(); + public io.kubernetes.client.custom.IntOrString getPort(); + public A withPort(io.kubernetes.client.custom.IntOrString port); + public java.lang.Boolean hasPort(); + public A withNewPort(int value); + public A withNewPort(java.lang.String value); + public java.lang.String getProtocol(); + public A withProtocol(java.lang.String protocol); + public java.lang.Boolean hasProtocol(); - - /** - * Method is deprecated. use withProtocol instead. - */ + + /** Method is deprecated. use withProtocol instead. */ @java.lang.Deprecated public A withNewProtocol(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPortFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPortFluentImpl.java index 6539012dda..ac6f23aa8e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPortFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicyPortFluentImpl.java @@ -1,82 +1,103 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; import io.kubernetes.client.custom.IntOrString; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1NetworkPolicyPortFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent{ - public V1NetworkPolicyPortFluentImpl() { - } - public V1NetworkPolicyPortFluentImpl(io.kubernetes.client.openapi.models.V1NetworkPolicyPort instance) { + +/** Generated */ +public class V1NetworkPolicyPortFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NetworkPolicyPortFluent { + public V1NetworkPolicyPortFluentImpl() {} + + public V1NetworkPolicyPortFluentImpl( + io.kubernetes.client.openapi.models.V1NetworkPolicyPort instance) { this.withEndPort(instance.getEndPort()); this.withPort(instance.getPort()); this.withProtocol(instance.getProtocol()); - } + private java.lang.Integer endPort; private io.kubernetes.client.custom.IntOrString port; private java.lang.String protocol; + public java.lang.Integer getEndPort() { return this.endPort; } + public A withEndPort(java.lang.Integer endPort) { - this.endPort=endPort; return (A) this; + this.endPort = endPort; + return (A) this; } + public java.lang.Boolean hasEndPort() { return this.endPort != null; } + public io.kubernetes.client.custom.IntOrString getPort() { return this.port; } + public A withPort(io.kubernetes.client.custom.IntOrString port) { - this.port=port; return (A) this; + this.port = port; + return (A) this; } + public java.lang.Boolean hasPort() { return this.port != null; } + public A withNewPort(int value) { - return (A)withPort(new IntOrString(value)); + return (A) withPort(new IntOrString(value)); } + public A withNewPort(java.lang.String value) { - return (A)withPort(new IntOrString(value)); + return (A) withPort(new IntOrString(value)); } + public java.lang.String getProtocol() { return this.protocol; } + public A withProtocol(java.lang.String protocol) { - this.protocol=protocol; return (A) this; + this.protocol = protocol; + return (A) this; } + public java.lang.Boolean hasProtocol() { return this.protocol != null; } - - /** - * Method is deprecated. use withProtocol instead. - */ + + /** Method is deprecated. use withProtocol instead. */ @java.lang.Deprecated public A withNewProtocol(java.lang.String original) { - return (A)withProtocol(new String(original)); + return (A) withProtocol(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NetworkPolicyPortFluentImpl that = (V1NetworkPolicyPortFluentImpl) o; - if (endPort != null ? !endPort.equals(that.endPort) :that.endPort != null) return false; - if (port != null ? !port.equals(that.port) :that.port != null) return false; - if (protocol != null ? !protocol.equals(that.protocol) :that.protocol != null) return false; + if (endPort != null ? !endPort.equals(that.endPort) : that.endPort != null) return false; + if (port != null ? !port.equals(that.port) : that.port != null) return false; + if (protocol != null ? !protocol.equals(that.protocol) : that.protocol != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(endPort, port, protocol, super.hashCode()); + return java.util.Objects.hash(endPort, port, protocol, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicySpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicySpecBuilder.java index f226665e77..0df79917e3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicySpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicySpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NetworkPolicySpecBuilder extends io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NetworkPolicySpecBuilder + extends io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicySpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NetworkPolicySpec, + io.kubernetes.client.openapi.models.V1NetworkPolicySpecBuilder> { public V1NetworkPolicySpecBuilder() { this(false); } + public V1NetworkPolicySpecBuilder(java.lang.Boolean validationEnabled) { this(new V1NetworkPolicySpec(), validationEnabled); } - public V1NetworkPolicySpecBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent fluent) { + + public V1NetworkPolicySpecBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent fluent) { this(fluent, false); } - public V1NetworkPolicySpecBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NetworkPolicySpecBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NetworkPolicySpec(), validationEnabled); } - public V1NetworkPolicySpecBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicySpec instance) { + + public V1NetworkPolicySpecBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicySpec instance) { this(fluent, instance, false); } - public V1NetworkPolicySpecBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent fluent,io.kubernetes.client.openapi.models.V1NetworkPolicySpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NetworkPolicySpecBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent fluent, + io.kubernetes.client.openapi.models.V1NetworkPolicySpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withEgress(instance.getEgress()); fluent.withIngress(instance.getIngress()); @@ -29,13 +56,18 @@ public V1NetworkPolicySpecBuilder(io.kubernetes.client.openapi.models.V1NetworkP fluent.withPolicyTypes(instance.getPolicyTypes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1NetworkPolicySpecBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicySpec instance) { - this(instance,false); + + public V1NetworkPolicySpecBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicySpec instance) { + this(instance, false); } - public V1NetworkPolicySpecBuilder(io.kubernetes.client.openapi.models.V1NetworkPolicySpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NetworkPolicySpecBuilder( + io.kubernetes.client.openapi.models.V1NetworkPolicySpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withEgress(instance.getEgress()); this.withIngress(instance.getIngress()); @@ -44,10 +76,12 @@ public V1NetworkPolicySpecBuilder(io.kubernetes.client.openapi.models.V1NetworkP this.withPolicyTypes(instance.getPolicyTypes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NetworkPolicySpec build() { V1NetworkPolicySpec buildable = new V1NetworkPolicySpec(); buildable.setEgress(fluent.getEgress()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1NetworkPolicySpec build() { buildable.setPolicyTypes(fluent.getPolicyTypes()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NetworkPolicySpecBuilder that = (V1NetworkPolicySpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicySpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicySpecFluent.java index db9e40e722..26981cb723 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicySpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicySpecFluent.java @@ -1,128 +1,274 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1NetworkPolicySpecFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToEgress(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item); - public A setToEgress(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item); +/** Generated */ +public interface V1NetworkPolicySpecFluent< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToEgress( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item); + + public A setToEgress( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item); + public A addToEgress(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule... items); - public A addAllToEgress(java.util.Collection items); + + public A addAllToEgress( + java.util.Collection items); + public A removeFromEgress(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule... items); - public A removeAllFromEgress(java.util.Collection items); - public A removeMatchingFromEgress(java.util.function.Predicate predicate); - + + public A removeAllFromEgress( + java.util.Collection items); + + public A removeMatchingFromEgress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder> + predicate); + /** * This method has been deprecated, please use method buildEgress instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getEgress(); - public java.util.List buildEgress(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule buildEgress(java.lang.Integer index); + + public java.util.List + buildEgress(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule buildEgress( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule buildFirstEgress(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule buildLastEgress(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule buildMatchingEgress(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingEgress(java.util.function.Predicate predicate); - public A withEgress(java.util.List egress); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule buildMatchingEgress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder> + predicate); + + public java.lang.Boolean hasMatchingEgress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder> + predicate); + + public A withEgress( + java.util.List egress); + public A withEgress(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule... egress); + public java.lang.Boolean hasEgress(); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested addNewEgress(); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested addNewEgressLike(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested setNewEgressLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested editEgress(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested editFirstEgress(); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested editLastEgress(); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested editMatchingEgress(java.util.function.Predicate predicate); - public A addToIngress(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item); - public A setToIngress(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested + addNewEgress(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested + addNewEgressLike(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested + setNewEgressLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested editEgress( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested + editFirstEgress(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested + editLastEgress(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested + editMatchingEgress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder> + predicate); + + public A addToIngress( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item); + + public A setToIngress( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item); + public A addToIngress(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule... items); - public A addAllToIngress(java.util.Collection items); - public A removeFromIngress(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule... items); - public A removeAllFromIngress(java.util.Collection items); - public A removeMatchingFromIngress(java.util.function.Predicate predicate); - + + public A addAllToIngress( + java.util.Collection items); + + public A removeFromIngress( + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule... items); + + public A removeAllFromIngress( + java.util.Collection items); + + public A removeMatchingFromIngress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder> + predicate); + /** * This method has been deprecated, please use method buildIngress instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getIngress(); - public java.util.List buildIngress(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule buildIngress(java.lang.Integer index); + public java.util.List + getIngress(); + + public java.util.List + buildIngress(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule buildIngress( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule buildFirstIngress(); + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule buildLastIngress(); - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule buildMatchingIngress(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingIngress(java.util.function.Predicate predicate); - public A withIngress(java.util.List ingress); + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule buildMatchingIngress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder> + predicate); + + public java.lang.Boolean hasMatchingIngress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder> + predicate); + + public A withIngress( + java.util.List ingress); + public A withIngress(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule... ingress); + public java.lang.Boolean hasIngress(); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested addNewIngress(); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested addNewIngressLike(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested setNewIngressLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested editIngress(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested editFirstIngress(); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested editLastIngress(); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested editMatchingIngress(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested + addNewIngress(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested + addNewIngressLike(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested + setNewIngressLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested editIngress( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested + editFirstIngress(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested + editLastIngress(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested + editMatchingIngress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder> + predicate); + /** * This method has been deprecated, please use method buildPodSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getPodSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildPodSelector(); + public A withPodSelector(io.kubernetes.client.openapi.models.V1LabelSelector podSelector); + public java.lang.Boolean hasPodSelector(); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested withNewPodSelector(); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested withNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested editPodSelector(); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested editOrNewPodSelector(); - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested editOrNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public A addToPolicyTypes(java.lang.Integer index,java.lang.String item); - public A setToPolicyTypes(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested + withNewPodSelector(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested + withNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested + editPodSelector(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested + editOrNewPodSelector(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested + editOrNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public A addToPolicyTypes(java.lang.Integer index, java.lang.String item); + + public A setToPolicyTypes(java.lang.Integer index, java.lang.String item); + public A addToPolicyTypes(java.lang.String... items); + public A addAllToPolicyTypes(java.util.Collection items); + public A removeFromPolicyTypes(java.lang.String... items); + public A removeAllFromPolicyTypes(java.util.Collection items); + public java.util.List getPolicyTypes(); + public java.lang.String getPolicyType(java.lang.Integer index); + public java.lang.String getFirstPolicyType(); + public java.lang.String getLastPolicyType(); - public java.lang.String getMatchingPolicyType(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPolicyType(java.util.function.Predicate predicate); + + public java.lang.String getMatchingPolicyType( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingPolicyType( + java.util.function.Predicate predicate); + public A withPolicyTypes(java.util.List policyTypes); + public A withPolicyTypes(java.lang.String... policyTypes); + public java.lang.Boolean hasPolicyTypes(); + public A addNewPolicyType(java.lang.String original); - public interface EgressNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent>{ + + public interface EgressNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested> { public N and(); + public N endEgress(); - } - public interface IngressNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent>{ + + public interface IngressNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested> { public N and(); + public N endIngress(); - } - public interface PodSelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface PodSelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested> { public N and(); + public N endPodSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicySpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicySpecFluentImpl.java index 17c8b2cff8..b040f59cf1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicySpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NetworkPolicySpecFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1NetworkPolicySpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent{ - public V1NetworkPolicySpecFluentImpl() { - } - public V1NetworkPolicySpecFluentImpl(io.kubernetes.client.openapi.models.V1NetworkPolicySpec instance) { + +/** Generated */ +public class V1NetworkPolicySpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent { + public V1NetworkPolicySpecFluentImpl() {} + + public V1NetworkPolicySpecFluentImpl( + io.kubernetes.client.openapi.models.V1NetworkPolicySpec instance) { this.withEgress(instance.getEgress()); this.withIngress(instance.getIngress()); @@ -28,40 +31,115 @@ public V1NetworkPolicySpecFluentImpl(io.kubernetes.client.openapi.models.V1Netwo this.withPodSelector(instance.getPodSelector()); this.withPolicyTypes(instance.getPolicyTypes()); - } - private java.util.ArrayList egress; - private java.util.ArrayList ingress; + + private java.util.ArrayList + egress; + private java.util.ArrayList + ingress; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder podSelector; private java.util.List policyTypes; - public A addToEgress(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item) { - if (this.egress == null) {this.egress = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(item);_visitables.get("egress").add(index >= 0 ? index : _visitables.get("egress").size(), builder);this.egress.add(index >= 0 ? index : egress.size(), builder); return (A)this; + + public A addToEgress( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item) { + if (this.egress == null) { + this.egress = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder>(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(item); + _visitables.get("egress").add(index >= 0 ? index : _visitables.get("egress").size(), builder); + this.egress.add(index >= 0 ? index : egress.size(), builder); + return (A) this; } - public A setToEgress(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item) { - if (this.egress == null) {this.egress = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(item); - if (index < 0 || index >= _visitables.get("egress").size()) { _visitables.get("egress").add(builder); } else { _visitables.get("egress").set(index, builder);} - if (index < 0 || index >= egress.size()) { egress.add(builder); } else { egress.set(index, builder);} - return (A)this; + + public A setToEgress( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item) { + if (this.egress == null) { + this.egress = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder>(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(item); + if (index < 0 || index >= _visitables.get("egress").size()) { + _visitables.get("egress").add(builder); + } else { + _visitables.get("egress").set(index, builder); + } + if (index < 0 || index >= egress.size()) { + egress.add(builder); + } else { + egress.set(index, builder); + } + return (A) this; } + public A addToEgress(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule... items) { - if (this.egress == null) {this.egress = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(item);_visitables.get("egress").add(builder);this.egress.add(builder);} return (A)this; + if (this.egress == null) { + this.egress = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(item); + _visitables.get("egress").add(builder); + this.egress.add(builder); + } + return (A) this; } - public A addAllToEgress(java.util.Collection items) { - if (this.egress == null) {this.egress = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(item);_visitables.get("egress").add(builder);this.egress.add(builder);} return (A)this; + + public A addAllToEgress( + java.util.Collection items) { + if (this.egress == null) { + this.egress = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(item); + _visitables.get("egress").add(builder); + this.egress.add(builder); + } + return (A) this; } - public A removeFromEgress(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule... items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(item);_visitables.get("egress").remove(builder);if (this.egress != null) {this.egress.remove(builder);}} return (A)this; + + public A removeFromEgress( + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule... items) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(item); + _visitables.get("egress").remove(builder); + if (this.egress != null) { + this.egress.remove(builder); + } + } + return (A) this; } - public A removeAllFromEgress(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(item);_visitables.get("egress").remove(builder);if (this.egress != null) {this.egress.remove(builder);}} return (A)this; + + public A removeAllFromEgress( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(item); + _visitables.get("egress").remove(builder); + if (this.egress != null) { + this.egress.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromEgress(java.util.function.Predicate predicate) { + + public A removeMatchingFromEgress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder> + predicate) { if (egress == null) return (A) this; - final Iterator each = egress.iterator(); + final Iterator each = + egress.iterator(); final List visitables = _visitables.get("egress"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder = each.next(); @@ -70,104 +148,251 @@ public A removeMatchingFromEgress(java.util.function.Predicate getEgress() { return egress != null ? build(egress) : null; } - public java.util.List buildEgress() { + + public java.util.List + buildEgress() { return egress != null ? build(egress) : null; } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule buildEgress(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule buildEgress( + java.lang.Integer index) { return this.egress.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule buildFirstEgress() { return this.egress.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule buildLastEgress() { return this.egress.get(egress.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule buildMatchingEgress(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder item: egress) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule buildMatchingEgress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder item : egress) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingEgress(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder item: egress) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingEgress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder item : egress) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withEgress(java.util.List egress) { - if (this.egress != null) { _visitables.get("egress").removeAll(this.egress);} - if (egress != null) {this.egress = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item : egress){this.addToEgress(item);}} else { this.egress = null;} return (A) this; + + public A withEgress( + java.util.List egress) { + if (this.egress != null) { + _visitables.get("egress").removeAll(this.egress); + } + if (egress != null) { + this.egress = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item : egress) { + this.addToEgress(item); + } + } else { + this.egress = null; + } + return (A) this; } + public A withEgress(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule... egress) { - if (this.egress != null) {this.egress.clear();} - if (egress != null) {for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item :egress){ this.addToEgress(item);}} return (A) this; + if (this.egress != null) { + this.egress.clear(); + } + if (egress != null) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item : egress) { + this.addToEgress(item); + } + } + return (A) this; } + public java.lang.Boolean hasEgress() { return egress != null && !egress.isEmpty(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested addNewEgress() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested + addNewEgress() { return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl.EgressNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested addNewEgressLike(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl.EgressNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested + addNewEgressLike(io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl.EgressNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested setNewEgressLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl.EgressNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested + setNewEgressLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl.EgressNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested editEgress(java.lang.Integer index) { - if (egress.size() <= index) throw new RuntimeException("Can't edit egress. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested editEgress( + java.lang.Integer index) { + if (egress.size() <= index) + throw new RuntimeException("Can't edit egress. Index exceeds size."); return setNewEgressLike(index, buildEgress(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested editFirstEgress() { - if (egress.size() == 0) throw new RuntimeException("Can't edit first egress. The list is empty."); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested + editFirstEgress() { + if (egress.size() == 0) + throw new RuntimeException("Can't edit first egress. The list is empty."); return setNewEgressLike(0, buildEgress(0)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested editLastEgress() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested + editLastEgress() { int index = egress.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last egress. The list is empty."); return setNewEgressLike(index, buildEgress(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested editMatchingEgress(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested + editMatchingEgress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(item);_visitables.get("ingress").add(index >= 0 ? index : _visitables.get("ingress").size(), builder);this.ingress.add(index >= 0 ? index : ingress.size(), builder); return (A)this; + + public A addToIngress( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item) { + if (this.ingress == null) { + this.ingress = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder>(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(item); + _visitables.get("ingress").add(index >= 0 ? index : _visitables.get("ingress").size(), builder); + this.ingress.add(index >= 0 ? index : ingress.size(), builder); + return (A) this; } - public A setToIngress(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item) { - if (this.ingress == null) {this.ingress = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(item); - if (index < 0 || index >= _visitables.get("ingress").size()) { _visitables.get("ingress").add(builder); } else { _visitables.get("ingress").set(index, builder);} - if (index < 0 || index >= ingress.size()) { ingress.add(builder); } else { ingress.set(index, builder);} - return (A)this; + + public A setToIngress( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item) { + if (this.ingress == null) { + this.ingress = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder>(); + } + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(item); + if (index < 0 || index >= _visitables.get("ingress").size()) { + _visitables.get("ingress").add(builder); + } else { + _visitables.get("ingress").set(index, builder); + } + if (index < 0 || index >= ingress.size()) { + ingress.add(builder); + } else { + ingress.set(index, builder); + } + return (A) this; } + public A addToIngress(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule... items) { - if (this.ingress == null) {this.ingress = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(item);_visitables.get("ingress").add(builder);this.ingress.add(builder);} return (A)this; + if (this.ingress == null) { + this.ingress = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(item); + _visitables.get("ingress").add(builder); + this.ingress.add(builder); + } + return (A) this; } - public A addAllToIngress(java.util.Collection items) { - if (this.ingress == null) {this.ingress = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(item);_visitables.get("ingress").add(builder);this.ingress.add(builder);} return (A)this; + + public A addAllToIngress( + java.util.Collection items) { + if (this.ingress == null) { + this.ingress = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(item); + _visitables.get("ingress").add(builder); + this.ingress.add(builder); + } + return (A) this; } - public A removeFromIngress(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule... items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(item);_visitables.get("ingress").remove(builder);if (this.ingress != null) {this.ingress.remove(builder);}} return (A)this; + + public A removeFromIngress( + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule... items) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(item); + _visitables.get("ingress").remove(builder); + if (this.ingress != null) { + this.ingress.remove(builder); + } + } + return (A) this; } - public A removeAllFromIngress(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item : items) {io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(item);_visitables.get("ingress").remove(builder);if (this.ingress != null) {this.ingress.remove(builder);}} return (A)this; + + public A removeAllFromIngress( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item : items) { + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(item); + _visitables.get("ingress").remove(builder); + if (this.ingress != null) { + this.ingress.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromIngress(java.util.function.Predicate predicate) { + + public A removeMatchingFromIngress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder> + predicate) { if (ingress == null) return (A) this; - final Iterator each = ingress.iterator(); + final Iterator each = + ingress.iterator(); final List visitables = _visitables.get("ingress"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder = each.next(); @@ -176,230 +401,430 @@ public A removeMatchingFromIngress(java.util.function.Predicate getIngress() { + public java.util.List + getIngress() { return ingress != null ? build(ingress) : null; } - public java.util.List buildIngress() { + + public java.util.List + buildIngress() { return ingress != null ? build(ingress) : null; } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule buildIngress(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule buildIngress( + java.lang.Integer index) { return this.ingress.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule buildFirstIngress() { return this.ingress.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule buildLastIngress() { return this.ingress.get(ingress.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule buildMatchingIngress(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder item: ingress) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule buildMatchingIngress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder item : ingress) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingIngress(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder item: ingress) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingIngress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder item : ingress) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withIngress(java.util.List ingress) { - if (this.ingress != null) { _visitables.get("ingress").removeAll(this.ingress);} - if (ingress != null) {this.ingress = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item : ingress){this.addToIngress(item);}} else { this.ingress = null;} return (A) this; + + public A withIngress( + java.util.List ingress) { + if (this.ingress != null) { + _visitables.get("ingress").removeAll(this.ingress); + } + if (ingress != null) { + this.ingress = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item : ingress) { + this.addToIngress(item); + } + } else { + this.ingress = null; + } + return (A) this; } + public A withIngress(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule... ingress) { - if (this.ingress != null) {this.ingress.clear();} - if (ingress != null) {for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item :ingress){ this.addToIngress(item);}} return (A) this; + if (this.ingress != null) { + this.ingress.clear(); + } + if (ingress != null) { + for (io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item : ingress) { + this.addToIngress(item); + } + } + return (A) this; } + public java.lang.Boolean hasIngress() { return ingress != null && !ingress.isEmpty(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested addNewIngress() { - return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl.IngressNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested + addNewIngress() { + return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl + .IngressNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested addNewIngressLike(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl.IngressNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested + addNewIngressLike(io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl.IngressNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested setNewIngressLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl.IngressNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested + setNewIngressLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl.IngressNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested editIngress(java.lang.Integer index) { - if (ingress.size() <= index) throw new RuntimeException("Can't edit ingress. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested editIngress( + java.lang.Integer index) { + if (ingress.size() <= index) + throw new RuntimeException("Can't edit ingress. Index exceeds size."); return setNewIngressLike(index, buildIngress(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested editFirstIngress() { - if (ingress.size() == 0) throw new RuntimeException("Can't edit first ingress. The list is empty."); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested + editFirstIngress() { + if (ingress.size() == 0) + throw new RuntimeException("Can't edit first ingress. The list is empty."); return setNewIngressLike(0, buildIngress(0)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested editLastIngress() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested + editLastIngress() { int index = ingress.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ingress. The list is empty."); return setNewIngressLike(index, buildIngress(index)); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested editMatchingIngress(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested + editMatchingIngress( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder> + predicate) { int index = -1; - for (int i=0;i withNewPodSelector() { - return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl.PodSelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested + withNewPodSelector() { + return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl + .PodSelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested withNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl.PodSelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested + withNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluentImpl + .PodSelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested editPodSelector() { + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested + editPodSelector() { return withNewPodSelectorLike(getPodSelector()); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested editOrNewPodSelector() { - return withNewPodSelectorLike(getPodSelector() != null ? getPodSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested + editOrNewPodSelector() { + return withNewPodSelectorLike( + getPodSelector() != null + ? getPodSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested editOrNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewPodSelectorLike(getPodSelector() != null ? getPodSelector(): item); + + public io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested + editOrNewPodSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewPodSelectorLike(getPodSelector() != null ? getPodSelector() : item); } - public A addToPolicyTypes(java.lang.Integer index,java.lang.String item) { - if (this.policyTypes == null) {this.policyTypes = new java.util.ArrayList();} + + public A addToPolicyTypes(java.lang.Integer index, java.lang.String item) { + if (this.policyTypes == null) { + this.policyTypes = new java.util.ArrayList(); + } this.policyTypes.add(index, item); - return (A)this; + return (A) this; } - public A setToPolicyTypes(java.lang.Integer index,java.lang.String item) { - if (this.policyTypes == null) {this.policyTypes = new java.util.ArrayList();} - this.policyTypes.set(index, item); return (A)this; + + public A setToPolicyTypes(java.lang.Integer index, java.lang.String item) { + if (this.policyTypes == null) { + this.policyTypes = new java.util.ArrayList(); + } + this.policyTypes.set(index, item); + return (A) this; } + public A addToPolicyTypes(java.lang.String... items) { - if (this.policyTypes == null) {this.policyTypes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.policyTypes.add(item);} return (A)this; + if (this.policyTypes == null) { + this.policyTypes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.policyTypes.add(item); + } + return (A) this; } + public A addAllToPolicyTypes(java.util.Collection items) { - if (this.policyTypes == null) {this.policyTypes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.policyTypes.add(item);} return (A)this; + if (this.policyTypes == null) { + this.policyTypes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.policyTypes.add(item); + } + return (A) this; } + public A removeFromPolicyTypes(java.lang.String... items) { - for (java.lang.String item : items) {if (this.policyTypes!= null){ this.policyTypes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.policyTypes != null) { + this.policyTypes.remove(item); + } + } + return (A) this; } + public A removeAllFromPolicyTypes(java.util.Collection items) { - for (java.lang.String item : items) {if (this.policyTypes!= null){ this.policyTypes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.policyTypes != null) { + this.policyTypes.remove(item); + } + } + return (A) this; } + public java.util.List getPolicyTypes() { return this.policyTypes; } + public java.lang.String getPolicyType(java.lang.Integer index) { return this.policyTypes.get(index); } + public java.lang.String getFirstPolicyType() { return this.policyTypes.get(0); } + public java.lang.String getLastPolicyType() { return this.policyTypes.get(policyTypes.size() - 1); } - public java.lang.String getMatchingPolicyType(java.util.function.Predicate predicate) { - for (java.lang.String item: policyTypes) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingPolicyType( + java.util.function.Predicate predicate) { + for (java.lang.String item : policyTypes) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingPolicyType(java.util.function.Predicate predicate) { - for (java.lang.String item: policyTypes) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPolicyType( + java.util.function.Predicate predicate) { + for (java.lang.String item : policyTypes) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withPolicyTypes(java.util.List policyTypes) { - if (policyTypes != null) {this.policyTypes = new java.util.ArrayList(); for (java.lang.String item : policyTypes){this.addToPolicyTypes(item);}} else { this.policyTypes = null;} return (A) this; + if (policyTypes != null) { + this.policyTypes = new java.util.ArrayList(); + for (java.lang.String item : policyTypes) { + this.addToPolicyTypes(item); + } + } else { + this.policyTypes = null; + } + return (A) this; } + public A withPolicyTypes(java.lang.String... policyTypes) { - if (this.policyTypes != null) {this.policyTypes.clear();} - if (policyTypes != null) {for (java.lang.String item :policyTypes){ this.addToPolicyTypes(item);}} return (A) this; + if (this.policyTypes != null) { + this.policyTypes.clear(); + } + if (policyTypes != null) { + for (java.lang.String item : policyTypes) { + this.addToPolicyTypes(item); + } + } + return (A) this; } + public java.lang.Boolean hasPolicyTypes() { return policyTypes != null && !policyTypes.isEmpty(); } + public A addNewPolicyType(java.lang.String original) { - return (A)addToPolicyTypes(new String(original)); + return (A) addToPolicyTypes(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NetworkPolicySpecFluentImpl that = (V1NetworkPolicySpecFluentImpl) o; - if (egress != null ? !egress.equals(that.egress) :that.egress != null) return false; - if (ingress != null ? !ingress.equals(that.ingress) :that.ingress != null) return false; - if (podSelector != null ? !podSelector.equals(that.podSelector) :that.podSelector != null) return false; - if (policyTypes != null ? !policyTypes.equals(that.policyTypes) :that.policyTypes != null) return false; + if (egress != null ? !egress.equals(that.egress) : that.egress != null) return false; + if (ingress != null ? !ingress.equals(that.ingress) : that.ingress != null) return false; + if (podSelector != null ? !podSelector.equals(that.podSelector) : that.podSelector != null) + return false; + if (policyTypes != null ? !policyTypes.equals(that.policyTypes) : that.policyTypes != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(egress, ingress, podSelector, policyTypes, super.hashCode()); + return java.util.Objects.hash(egress, ingress, podSelector, policyTypes, super.hashCode()); } - public class EgressNestedImpl extends io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested,io.kubernetes.client.fluent.Nested{ - EgressNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item) { + + public class EgressNestedImpl + extends io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.EgressNested, + io.kubernetes.client.fluent.Nested { + EgressNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRule item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(this, item); } + EgressNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder(this); } + io.kubernetes.client.openapi.models.V1NetworkPolicyEgressRuleBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NetworkPolicySpecFluentImpl.this.setToEgress(index,builder.build()); + return (N) V1NetworkPolicySpecFluentImpl.this.setToEgress(index, builder.build()); } + public N endEgress() { return and(); } - } - public class IngressNestedImpl extends io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested,io.kubernetes.client.fluent.Nested{ - IngressNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item) { + + public class IngressNestedImpl + extends io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.IngressNested, + io.kubernetes.client.fluent.Nested { + IngressNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRule item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(this, item); } + IngressNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder(this); } + io.kubernetes.client.openapi.models.V1NetworkPolicyIngressRuleBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NetworkPolicySpecFluentImpl.this.setToIngress(index,builder.build()); + return (N) V1NetworkPolicySpecFluentImpl.this.setToIngress(index, builder.build()); } + public N endIngress() { return and(); } - } - public class PodSelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested,io.kubernetes.client.fluent.Nested{ + + public class PodSelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested> + implements io.kubernetes.client.openapi.models.V1NetworkPolicySpecFluent.PodSelectorNested, + io.kubernetes.client.fluent.Nested { PodSelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + PodSelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1NetworkPolicySpecFluentImpl.this.withPodSelector(builder.build()); } + public N endPodSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAddressBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAddressBuilder.java index b98aa7569a..cd5d2f3f95 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAddressBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAddressBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeAddressBuilder extends io.kubernetes.client.openapi.models.V1NodeAddressFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeAddressBuilder + extends io.kubernetes.client.openapi.models.V1NodeAddressFluentImpl< + io.kubernetes.client.openapi.models.V1NodeAddressBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NodeAddress, + io.kubernetes.client.openapi.models.V1NodeAddressBuilder> { public V1NodeAddressBuilder() { this(false); } + public V1NodeAddressBuilder(java.lang.Boolean validationEnabled) { this(new V1NodeAddress(), validationEnabled); } + public V1NodeAddressBuilder(io.kubernetes.client.openapi.models.V1NodeAddressFluent fluent) { this(fluent, false); } - public V1NodeAddressBuilder(io.kubernetes.client.openapi.models.V1NodeAddressFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeAddressBuilder( + io.kubernetes.client.openapi.models.V1NodeAddressFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NodeAddress(), validationEnabled); } - public V1NodeAddressBuilder(io.kubernetes.client.openapi.models.V1NodeAddressFluent fluent,io.kubernetes.client.openapi.models.V1NodeAddress instance) { + + public V1NodeAddressBuilder( + io.kubernetes.client.openapi.models.V1NodeAddressFluent fluent, + io.kubernetes.client.openapi.models.V1NodeAddress instance) { this(fluent, instance, false); } - public V1NodeAddressBuilder(io.kubernetes.client.openapi.models.V1NodeAddressFluent fluent,io.kubernetes.client.openapi.models.V1NodeAddress instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NodeAddressBuilder( + io.kubernetes.client.openapi.models.V1NodeAddressFluent fluent, + io.kubernetes.client.openapi.models.V1NodeAddress instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAddress(instance.getAddress()); fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NodeAddressBuilder(io.kubernetes.client.openapi.models.V1NodeAddress instance) { - this(instance,false); + this(instance, false); } - public V1NodeAddressBuilder(io.kubernetes.client.openapi.models.V1NodeAddress instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NodeAddressBuilder( + io.kubernetes.client.openapi.models.V1NodeAddress instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAddress(instance.getAddress()); this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeAddressFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NodeAddress build() { V1NodeAddress buildable = new V1NodeAddress(); buildable.setAddress(fluent.getAddress()); buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeAddressBuilder that = (V1NodeAddressBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAddressFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAddressFluent.java index bdfcd96e8a..1065e314eb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAddressFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAddressFluent.java @@ -1,26 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NodeAddressFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NodeAddressFluent< + A extends io.kubernetes.client.openapi.models.V1NodeAddressFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getAddress(); + public A withAddress(java.lang.String address); + public java.lang.Boolean hasAddress(); - - /** - * Method is deprecated. use withAddress instead. - */ + + /** Method is deprecated. use withAddress instead. */ @java.lang.Deprecated public A withNewAddress(java.lang.String original); + public io.kubernetes.client.openapi.models.V1NodeAddress.TypeEnum getType(); + public A withType(io.kubernetes.client.openapi.models.V1NodeAddress.TypeEnum type); + public java.lang.Boolean hasType(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAddressFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAddressFluentImpl.java index 0560d5d358..8b841b4dcd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAddressFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAddressFluentImpl.java @@ -1,61 +1,75 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1NodeAddressFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NodeAddressFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeAddressFluent { + public V1NodeAddressFluentImpl() {} - /** - * Generated - */ -public class V1NodeAddressFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeAddressFluent{ - public V1NodeAddressFluentImpl() { - } public V1NodeAddressFluentImpl(io.kubernetes.client.openapi.models.V1NodeAddress instance) { this.withAddress(instance.getAddress()); this.withType(instance.getType()); - } + private java.lang.String address; private io.kubernetes.client.openapi.models.V1NodeAddress.TypeEnum type; + public java.lang.String getAddress() { return this.address; } + public A withAddress(java.lang.String address) { - this.address=address; return (A) this; + this.address = address; + return (A) this; } + public java.lang.Boolean hasAddress() { return this.address != null; } - - /** - * Method is deprecated. use withAddress instead. - */ + + /** Method is deprecated. use withAddress instead. */ @java.lang.Deprecated public A withNewAddress(java.lang.String original) { - return (A)withAddress(new String(original)); + return (A) withAddress(new String(original)); } + public io.kubernetes.client.openapi.models.V1NodeAddress.TypeEnum getType() { return this.type; } + public A withType(io.kubernetes.client.openapi.models.V1NodeAddress.TypeEnum type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NodeAddressFluentImpl that = (V1NodeAddressFluentImpl) o; - if (address != null ? !address.equals(that.address) :that.address != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (address != null ? !address.equals(that.address) : that.address != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(address, type, super.hashCode()); + return java.util.Objects.hash(address, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAffinityBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAffinityBuilder.java index 7faa0178ab..fee8de505e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAffinityBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAffinityBuilder.java @@ -1,63 +1,106 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeAffinityBuilder extends io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeAffinityBuilder + extends io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl< + io.kubernetes.client.openapi.models.V1NodeAffinityBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NodeAffinity, + io.kubernetes.client.openapi.models.V1NodeAffinityBuilder> { public V1NodeAffinityBuilder() { this(false); } + public V1NodeAffinityBuilder(java.lang.Boolean validationEnabled) { this(new V1NodeAffinity(), validationEnabled); } + public V1NodeAffinityBuilder(io.kubernetes.client.openapi.models.V1NodeAffinityFluent fluent) { this(fluent, false); } - public V1NodeAffinityBuilder(io.kubernetes.client.openapi.models.V1NodeAffinityFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeAffinityBuilder( + io.kubernetes.client.openapi.models.V1NodeAffinityFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NodeAffinity(), validationEnabled); } - public V1NodeAffinityBuilder(io.kubernetes.client.openapi.models.V1NodeAffinityFluent fluent,io.kubernetes.client.openapi.models.V1NodeAffinity instance) { + + public V1NodeAffinityBuilder( + io.kubernetes.client.openapi.models.V1NodeAffinityFluent fluent, + io.kubernetes.client.openapi.models.V1NodeAffinity instance) { this(fluent, instance, false); } - public V1NodeAffinityBuilder(io.kubernetes.client.openapi.models.V1NodeAffinityFluent fluent,io.kubernetes.client.openapi.models.V1NodeAffinity instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; - fluent.withPreferredDuringSchedulingIgnoredDuringExecution(instance.getPreferredDuringSchedulingIgnoredDuringExecution()); - fluent.withRequiredDuringSchedulingIgnoredDuringExecution(instance.getRequiredDuringSchedulingIgnoredDuringExecution()); + public V1NodeAffinityBuilder( + io.kubernetes.client.openapi.models.V1NodeAffinityFluent fluent, + io.kubernetes.client.openapi.models.V1NodeAffinity instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; + fluent.withPreferredDuringSchedulingIgnoredDuringExecution( + instance.getPreferredDuringSchedulingIgnoredDuringExecution()); + + fluent.withRequiredDuringSchedulingIgnoredDuringExecution( + instance.getRequiredDuringSchedulingIgnoredDuringExecution()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NodeAffinityBuilder(io.kubernetes.client.openapi.models.V1NodeAffinity instance) { - this(instance,false); + this(instance, false); } - public V1NodeAffinityBuilder(io.kubernetes.client.openapi.models.V1NodeAffinity instance,java.lang.Boolean validationEnabled) { - this.fluent = this; - this.withPreferredDuringSchedulingIgnoredDuringExecution(instance.getPreferredDuringSchedulingIgnoredDuringExecution()); - this.withRequiredDuringSchedulingIgnoredDuringExecution(instance.getRequiredDuringSchedulingIgnoredDuringExecution()); + public V1NodeAffinityBuilder( + io.kubernetes.client.openapi.models.V1NodeAffinity instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; + this.withPreferredDuringSchedulingIgnoredDuringExecution( + instance.getPreferredDuringSchedulingIgnoredDuringExecution()); - this.validationEnabled = validationEnabled; + this.withRequiredDuringSchedulingIgnoredDuringExecution( + instance.getRequiredDuringSchedulingIgnoredDuringExecution()); + + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeAffinityFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NodeAffinity build() { V1NodeAffinity buildable = new V1NodeAffinity(); - buildable.setPreferredDuringSchedulingIgnoredDuringExecution(fluent.getPreferredDuringSchedulingIgnoredDuringExecution()); - buildable.setRequiredDuringSchedulingIgnoredDuringExecution(fluent.getRequiredDuringSchedulingIgnoredDuringExecution()); + buildable.setPreferredDuringSchedulingIgnoredDuringExecution( + fluent.getPreferredDuringSchedulingIgnoredDuringExecution()); + buildable.setRequiredDuringSchedulingIgnoredDuringExecution( + fluent.getRequiredDuringSchedulingIgnoredDuringExecution()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeAffinityBuilder that = (V1NodeAffinityBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAffinityFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAffinityFluent.java index 9310e31116..6b64278757 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAffinityFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAffinityFluent.java @@ -1,77 +1,193 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NodeAffinityFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item); - public A setToPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item); - public A addToPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm... items); - public A addAllToPreferredDuringSchedulingIgnoredDuringExecution(java.util.Collection items); - public A removeFromPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm... items); - public A removeAllFromPreferredDuringSchedulingIgnoredDuringExecution(java.util.Collection items); - public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - +/** Generated */ +public interface V1NodeAffinityFluent< + A extends io.kubernetes.client.openapi.models.V1NodeAffinityFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToPreferredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item); + + public A setToPreferredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item); + + public A addToPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm... items); + + public A addAllToPreferredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items); + + public A removeFromPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm... items); + + public A removeAllFromPreferredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items); + + public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder> + predicate); + /** - * This method has been deprecated, please use method buildPreferredDuringSchedulingIgnoredDuringExecution instead. + * This method has been deprecated, please use method + * buildPreferredDuringSchedulingIgnoredDuringExecution instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getPreferredDuringSchedulingIgnoredDuringExecution(); - public java.util.List buildPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm buildPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm buildFirstPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm buildLastPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm buildMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public A withPreferredDuringSchedulingIgnoredDuringExecution(java.util.List preferredDuringSchedulingIgnoredDuringExecution); - public A withPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm... preferredDuringSchedulingIgnoredDuringExecution); + public java.util.List + getPreferredDuringSchedulingIgnoredDuringExecution(); + + public java.util.List + buildPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm + buildPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm + buildFirstPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm + buildLastPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm + buildMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder> + predicate); + + public java.lang.Boolean hasMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder> + predicate); + + public A withPreferredDuringSchedulingIgnoredDuringExecution( + java.util.List + preferredDuringSchedulingIgnoredDuringExecution); + + public A withPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm... + preferredDuringSchedulingIgnoredDuringExecution); + public java.lang.Boolean hasPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested addNewPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested addNewPreferredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item); - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item); - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editFirstPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editLastPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editFirstPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editLastPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder> + predicate); + /** - * This method has been deprecated, please use method buildRequiredDuringSchedulingIgnoredDuringExecution instead. + * This method has been deprecated, please use method + * buildRequiredDuringSchedulingIgnoredDuringExecution instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1NodeSelector getRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1NodeSelector buildRequiredDuringSchedulingIgnoredDuringExecution(); - public A withRequiredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1NodeSelector requiredDuringSchedulingIgnoredDuringExecution); + public io.kubernetes.client.openapi.models.V1NodeSelector + getRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1NodeSelector + buildRequiredDuringSchedulingIgnoredDuringExecution(); + + public A withRequiredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1NodeSelector + requiredDuringSchedulingIgnoredDuringExecution); + public java.lang.Boolean hasRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested withNewRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested withNewRequiredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1NodeSelector item); - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editOrNewRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editOrNewRequiredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1NodeSelector item); - public interface PreferredDuringSchedulingIgnoredDuringExecutionNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent>{ + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + withNewRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + withNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1NodeSelector item); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editOrNewRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editOrNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1NodeSelector item); + + public interface PreferredDuringSchedulingIgnoredDuringExecutionNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent< + io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + N>> { public N and(); + public N endPreferredDuringSchedulingIgnoredDuringExecution(); - } - public interface RequiredDuringSchedulingIgnoredDuringExecutionNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeSelectorFluent>{ + + public interface RequiredDuringSchedulingIgnoredDuringExecutionNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeSelectorFluent< + io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + N>> { public N and(); + public N endRequiredDuringSchedulingIgnoredDuringExecution(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAffinityFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAffinityFluentImpl.java index d6d97d1c46..ef9cdaec8e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAffinityFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeAffinityFluentImpl.java @@ -1,60 +1,149 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1NodeAffinityFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeAffinityFluent{ - public V1NodeAffinityFluentImpl() { - } - public V1NodeAffinityFluentImpl(io.kubernetes.client.openapi.models.V1NodeAffinity instance) { - this.withPreferredDuringSchedulingIgnoredDuringExecution(instance.getPreferredDuringSchedulingIgnoredDuringExecution()); +/** Generated */ +public class V1NodeAffinityFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NodeAffinityFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeAffinityFluent { + public V1NodeAffinityFluentImpl() {} - this.withRequiredDuringSchedulingIgnoredDuringExecution(instance.getRequiredDuringSchedulingIgnoredDuringExecution()); + public V1NodeAffinityFluentImpl(io.kubernetes.client.openapi.models.V1NodeAffinity instance) { + this.withPreferredDuringSchedulingIgnoredDuringExecution( + instance.getPreferredDuringSchedulingIgnoredDuringExecution()); + this.withRequiredDuringSchedulingIgnoredDuringExecution( + instance.getRequiredDuringSchedulingIgnoredDuringExecution()); } - private java.util.ArrayList preferredDuringSchedulingIgnoredDuringExecution; - private io.kubernetes.client.openapi.models.V1NodeSelectorBuilder requiredDuringSchedulingIgnoredDuringExecution; - public A addToPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item) { - if (this.preferredDuringSchedulingIgnoredDuringExecution == null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder = new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(index >= 0 ? index : _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").size(), builder);this.preferredDuringSchedulingIgnoredDuringExecution.add(index >= 0 ? index : preferredDuringSchedulingIgnoredDuringExecution.size(), builder); return (A)this; + + private java.util.ArrayList + preferredDuringSchedulingIgnoredDuringExecution; + private io.kubernetes.client.openapi.models.V1NodeSelectorBuilder + requiredDuringSchedulingIgnoredDuringExecution; + + public A addToPreferredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item) { + if (this.preferredDuringSchedulingIgnoredDuringExecution == null) { + this.preferredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder>(); + } + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(item); + _visitables + .get("preferredDuringSchedulingIgnoredDuringExecution") + .add( + index >= 0 + ? index + : _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").size(), + builder); + this.preferredDuringSchedulingIgnoredDuringExecution.add( + index >= 0 ? index : preferredDuringSchedulingIgnoredDuringExecution.size(), builder); + return (A) this; } - public A setToPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item) { - if (this.preferredDuringSchedulingIgnoredDuringExecution == null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder = new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(item); - if (index < 0 || index >= _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").size()) { _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder); } else { _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").set(index, builder);} - if (index < 0 || index >= preferredDuringSchedulingIgnoredDuringExecution.size()) { preferredDuringSchedulingIgnoredDuringExecution.add(builder); } else { preferredDuringSchedulingIgnoredDuringExecution.set(index, builder);} - return (A)this; + + public A setToPreferredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item) { + if (this.preferredDuringSchedulingIgnoredDuringExecution == null) { + this.preferredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder>(); + } + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(item); + if (index < 0 + || index >= _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").size()) { + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder); + } else { + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").set(index, builder); + } + if (index < 0 || index >= preferredDuringSchedulingIgnoredDuringExecution.size()) { + preferredDuringSchedulingIgnoredDuringExecution.add(builder); + } else { + preferredDuringSchedulingIgnoredDuringExecution.set(index, builder); + } + return (A) this; } - public A addToPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm... items) { - if (this.preferredDuringSchedulingIgnoredDuringExecution == null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item : items) {io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder = new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder);this.preferredDuringSchedulingIgnoredDuringExecution.add(builder);} return (A)this; + + public A addToPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm... items) { + if (this.preferredDuringSchedulingIgnoredDuringExecution == null) { + this.preferredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item : items) { + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(item); + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder); + this.preferredDuringSchedulingIgnoredDuringExecution.add(builder); + } + return (A) this; } - public A addAllToPreferredDuringSchedulingIgnoredDuringExecution(java.util.Collection items) { - if (this.preferredDuringSchedulingIgnoredDuringExecution == null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item : items) {io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder = new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder);this.preferredDuringSchedulingIgnoredDuringExecution.add(builder);} return (A)this; + + public A addAllToPreferredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items) { + if (this.preferredDuringSchedulingIgnoredDuringExecution == null) { + this.preferredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item : items) { + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(item); + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder); + this.preferredDuringSchedulingIgnoredDuringExecution.add(builder); + } + return (A) this; } - public A removeFromPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm... items) { - for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item : items) {io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder = new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").remove(builder);if (this.preferredDuringSchedulingIgnoredDuringExecution != null) {this.preferredDuringSchedulingIgnoredDuringExecution.remove(builder);}} return (A)this; + + public A removeFromPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm... items) { + for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item : items) { + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(item); + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").remove(builder); + if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { + this.preferredDuringSchedulingIgnoredDuringExecution.remove(builder); + } + } + return (A) this; } - public A removeAllFromPreferredDuringSchedulingIgnoredDuringExecution(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item : items) {io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder = new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").remove(builder);if (this.preferredDuringSchedulingIgnoredDuringExecution != null) {this.preferredDuringSchedulingIgnoredDuringExecution.remove(builder);}} return (A)this; + + public A removeAllFromPreferredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item : items) { + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(item); + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").remove(builder); + if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { + this.preferredDuringSchedulingIgnoredDuringExecution.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { + + public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder> + predicate) { if (preferredDuringSchedulingIgnoredDuringExecution == null) return (A) this; - final Iterator each = preferredDuringSchedulingIgnoredDuringExecution.iterator(); + final Iterator each = + preferredDuringSchedulingIgnoredDuringExecution.iterator(); final List visitables = _visitables.get("preferredDuringSchedulingIgnoredDuringExecution"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder = each.next(); @@ -63,155 +152,370 @@ public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution(java. each.remove(); } } - return (A)this; + return (A) this; } - + /** - * This method has been deprecated, please use method buildPreferredDuringSchedulingIgnoredDuringExecution instead. + * This method has been deprecated, please use method + * buildPreferredDuringSchedulingIgnoredDuringExecution instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getPreferredDuringSchedulingIgnoredDuringExecution() { - return preferredDuringSchedulingIgnoredDuringExecution != null ? build(preferredDuringSchedulingIgnoredDuringExecution) : null; + public java.util.List + getPreferredDuringSchedulingIgnoredDuringExecution() { + return preferredDuringSchedulingIgnoredDuringExecution != null + ? build(preferredDuringSchedulingIgnoredDuringExecution) + : null; } - public java.util.List buildPreferredDuringSchedulingIgnoredDuringExecution() { - return preferredDuringSchedulingIgnoredDuringExecution != null ? build(preferredDuringSchedulingIgnoredDuringExecution) : null; + + public java.util.List + buildPreferredDuringSchedulingIgnoredDuringExecution() { + return preferredDuringSchedulingIgnoredDuringExecution != null + ? build(preferredDuringSchedulingIgnoredDuringExecution) + : null; } - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm buildPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm + buildPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { return this.preferredDuringSchedulingIgnoredDuringExecution.get(index).build(); } - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm buildFirstPreferredDuringSchedulingIgnoredDuringExecution() { + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm + buildFirstPreferredDuringSchedulingIgnoredDuringExecution() { return this.preferredDuringSchedulingIgnoredDuringExecution.get(0).build(); } - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm buildLastPreferredDuringSchedulingIgnoredDuringExecution() { - return this.preferredDuringSchedulingIgnoredDuringExecution.get(preferredDuringSchedulingIgnoredDuringExecution.size() - 1).build(); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm + buildLastPreferredDuringSchedulingIgnoredDuringExecution() { + return this.preferredDuringSchedulingIgnoredDuringExecution + .get(preferredDuringSchedulingIgnoredDuringExecution.size() - 1) + .build(); } - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm buildMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder item: preferredDuringSchedulingIgnoredDuringExecution) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm + buildMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder item : + preferredDuringSchedulingIgnoredDuringExecution) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder item: preferredDuringSchedulingIgnoredDuringExecution) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder item : + preferredDuringSchedulingIgnoredDuringExecution) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withPreferredDuringSchedulingIgnoredDuringExecution(java.util.List preferredDuringSchedulingIgnoredDuringExecution) { - if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").removeAll(this.preferredDuringSchedulingIgnoredDuringExecution);} - if (preferredDuringSchedulingIgnoredDuringExecution != null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item : preferredDuringSchedulingIgnoredDuringExecution){this.addToPreferredDuringSchedulingIgnoredDuringExecution(item);}} else { this.preferredDuringSchedulingIgnoredDuringExecution = null;} return (A) this; + + public A withPreferredDuringSchedulingIgnoredDuringExecution( + java.util.List + preferredDuringSchedulingIgnoredDuringExecution) { + if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { + _visitables + .get("preferredDuringSchedulingIgnoredDuringExecution") + .removeAll(this.preferredDuringSchedulingIgnoredDuringExecution); + } + if (preferredDuringSchedulingIgnoredDuringExecution != null) { + this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item : + preferredDuringSchedulingIgnoredDuringExecution) { + this.addToPreferredDuringSchedulingIgnoredDuringExecution(item); + } + } else { + this.preferredDuringSchedulingIgnoredDuringExecution = null; + } + return (A) this; } - public A withPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm... preferredDuringSchedulingIgnoredDuringExecution) { - if (this.preferredDuringSchedulingIgnoredDuringExecution != null) {this.preferredDuringSchedulingIgnoredDuringExecution.clear();} - if (preferredDuringSchedulingIgnoredDuringExecution != null) {for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item :preferredDuringSchedulingIgnoredDuringExecution){ this.addToPreferredDuringSchedulingIgnoredDuringExecution(item);}} return (A) this; + + public A withPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm... + preferredDuringSchedulingIgnoredDuringExecution) { + if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { + this.preferredDuringSchedulingIgnoredDuringExecution.clear(); + } + if (preferredDuringSchedulingIgnoredDuringExecution != null) { + for (io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item : + preferredDuringSchedulingIgnoredDuringExecution) { + this.addToPreferredDuringSchedulingIgnoredDuringExecution(item); + } + } + return (A) this; } + public java.lang.Boolean hasPreferredDuringSchedulingIgnoredDuringExecution() { - return preferredDuringSchedulingIgnoredDuringExecution != null && !preferredDuringSchedulingIgnoredDuringExecution.isEmpty(); + return preferredDuringSchedulingIgnoredDuringExecution != null + && !preferredDuringSchedulingIgnoredDuringExecution.isEmpty(); } - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested addNewPreferredDuringSchedulingIgnoredDuringExecution() { - return new io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl.PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewPreferredDuringSchedulingIgnoredDuringExecution() { + return new io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl + .PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested addNewPreferredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item) { - return new io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl.PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item) { + return new io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl + .PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item) { - return new io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl.PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item) { + return new io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl + .PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { - if (preferredDuringSchedulingIgnoredDuringExecution.size() <= index) throw new RuntimeException("Can't edit preferredDuringSchedulingIgnoredDuringExecution. Index exceeds size."); - return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { + if (preferredDuringSchedulingIgnoredDuringExecution.size() <= index) + throw new RuntimeException( + "Can't edit preferredDuringSchedulingIgnoredDuringExecution. Index exceeds size."); + return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); } - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editFirstPreferredDuringSchedulingIgnoredDuringExecution() { - if (preferredDuringSchedulingIgnoredDuringExecution.size() == 0) throw new RuntimeException("Can't edit first preferredDuringSchedulingIgnoredDuringExecution. The list is empty."); - return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(0, buildPreferredDuringSchedulingIgnoredDuringExecution(0)); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editFirstPreferredDuringSchedulingIgnoredDuringExecution() { + if (preferredDuringSchedulingIgnoredDuringExecution.size() == 0) + throw new RuntimeException( + "Can't edit first preferredDuringSchedulingIgnoredDuringExecution. The list is empty."); + return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + 0, buildPreferredDuringSchedulingIgnoredDuringExecution(0)); } - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editLastPreferredDuringSchedulingIgnoredDuringExecution() { + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editLastPreferredDuringSchedulingIgnoredDuringExecution() { int index = preferredDuringSchedulingIgnoredDuringExecution.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last preferredDuringSchedulingIgnoredDuringExecution. The list is empty."); - return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); + if (index < 0) + throw new RuntimeException( + "Can't edit last preferredDuringSchedulingIgnoredDuringExecution. The list is empty."); + return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); } - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder> + predicate) { int index = -1; - for (int i=0;i withNewRequiredDuringSchedulingIgnoredDuringExecution() { - return new io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl.RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + withNewRequiredDuringSchedulingIgnoredDuringExecution() { + return new io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl + .RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested withNewRequiredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1NodeSelector item) { - return new io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl.RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + withNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1NodeSelector item) { + return new io.kubernetes.client.openapi.models.V1NodeAffinityFluentImpl + .RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editRequiredDuringSchedulingIgnoredDuringExecution() { - return withNewRequiredDuringSchedulingIgnoredDuringExecutionLike(getRequiredDuringSchedulingIgnoredDuringExecution()); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editRequiredDuringSchedulingIgnoredDuringExecution() { + return withNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + getRequiredDuringSchedulingIgnoredDuringExecution()); } - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editOrNewRequiredDuringSchedulingIgnoredDuringExecution() { - return withNewRequiredDuringSchedulingIgnoredDuringExecutionLike(getRequiredDuringSchedulingIgnoredDuringExecution() != null ? getRequiredDuringSchedulingIgnoredDuringExecution(): new io.kubernetes.client.openapi.models.V1NodeSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editOrNewRequiredDuringSchedulingIgnoredDuringExecution() { + return withNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + getRequiredDuringSchedulingIgnoredDuringExecution() != null + ? getRequiredDuringSchedulingIgnoredDuringExecution() + : new io.kubernetes.client.openapi.models.V1NodeSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editOrNewRequiredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1NodeSelector item) { - return withNewRequiredDuringSchedulingIgnoredDuringExecutionLike(getRequiredDuringSchedulingIgnoredDuringExecution() != null ? getRequiredDuringSchedulingIgnoredDuringExecution(): item); + + public io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editOrNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1NodeSelector item) { + return withNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + getRequiredDuringSchedulingIgnoredDuringExecution() != null + ? getRequiredDuringSchedulingIgnoredDuringExecution() + : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NodeAffinityFluentImpl that = (V1NodeAffinityFluentImpl) o; - if (preferredDuringSchedulingIgnoredDuringExecution != null ? !preferredDuringSchedulingIgnoredDuringExecution.equals(that.preferredDuringSchedulingIgnoredDuringExecution) :that.preferredDuringSchedulingIgnoredDuringExecution != null) return false; - if (requiredDuringSchedulingIgnoredDuringExecution != null ? !requiredDuringSchedulingIgnoredDuringExecution.equals(that.requiredDuringSchedulingIgnoredDuringExecution) :that.requiredDuringSchedulingIgnoredDuringExecution != null) return false; + if (preferredDuringSchedulingIgnoredDuringExecution != null + ? !preferredDuringSchedulingIgnoredDuringExecution.equals( + that.preferredDuringSchedulingIgnoredDuringExecution) + : that.preferredDuringSchedulingIgnoredDuringExecution != null) return false; + if (requiredDuringSchedulingIgnoredDuringExecution != null + ? !requiredDuringSchedulingIgnoredDuringExecution.equals( + that.requiredDuringSchedulingIgnoredDuringExecution) + : that.requiredDuringSchedulingIgnoredDuringExecution != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(preferredDuringSchedulingIgnoredDuringExecution, requiredDuringSchedulingIgnoredDuringExecution, super.hashCode()); + return java.util.Objects.hash( + preferredDuringSchedulingIgnoredDuringExecution, + requiredDuringSchedulingIgnoredDuringExecution, + super.hashCode()); } - public class PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl extends io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested,io.kubernetes.client.fluent.Nested{ - PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item) { + + public class PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl + extends io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluentImpl< + io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + N>> + implements io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + N>, + io.kubernetes.client.fluent.Nested { + PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(this, item); } + PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder(this); } + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NodeAffinityFluentImpl.this.setToPreferredDuringSchedulingIgnoredDuringExecution(index,builder.build()); + return (N) + V1NodeAffinityFluentImpl.this.setToPreferredDuringSchedulingIgnoredDuringExecution( + index, builder.build()); } + public N endPreferredDuringSchedulingIgnoredDuringExecution() { return and(); } - } - public class RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl extends io.kubernetes.client.openapi.models.V1NodeSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested,io.kubernetes.client.fluent.Nested{ - RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(io.kubernetes.client.openapi.models.V1NodeSelector item) { + + public class RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + N>> + implements io.kubernetes.client.openapi.models.V1NodeAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + N>, + io.kubernetes.client.fluent.Nested { + RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl( + io.kubernetes.client.openapi.models.V1NodeSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1NodeSelectorBuilder(this, item); } + RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NodeSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeSelectorBuilder builder; + public N and() { - return (N) V1NodeAffinityFluentImpl.this.withRequiredDuringSchedulingIgnoredDuringExecution(builder.build()); + return (N) + V1NodeAffinityFluentImpl.this.withRequiredDuringSchedulingIgnoredDuringExecution( + builder.build()); } + public N endRequiredDuringSchedulingIgnoredDuringExecution() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeBuilder.java index 828ee799f5..b4c5310736 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeBuilder extends io.kubernetes.client.openapi.models.V1NodeFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeBuilder + extends io.kubernetes.client.openapi.models.V1NodeFluentImpl< + io.kubernetes.client.openapi.models.V1NodeBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Node, + io.kubernetes.client.openapi.models.V1NodeBuilder> { public V1NodeBuilder() { this(false); } + public V1NodeBuilder(java.lang.Boolean validationEnabled) { this(new V1Node(), validationEnabled); } + public V1NodeBuilder(io.kubernetes.client.openapi.models.V1NodeFluent fluent) { this(fluent, false); } - public V1NodeBuilder(io.kubernetes.client.openapi.models.V1NodeFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeBuilder( + io.kubernetes.client.openapi.models.V1NodeFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Node(), validationEnabled); } - public V1NodeBuilder(io.kubernetes.client.openapi.models.V1NodeFluent fluent,io.kubernetes.client.openapi.models.V1Node instance) { + + public V1NodeBuilder( + io.kubernetes.client.openapi.models.V1NodeFluent fluent, + io.kubernetes.client.openapi.models.V1Node instance) { this(fluent, instance, false); } - public V1NodeBuilder(io.kubernetes.client.openapi.models.V1NodeFluent fluent,io.kubernetes.client.openapi.models.V1Node instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NodeBuilder( + io.kubernetes.client.openapi.models.V1NodeFluent fluent, + io.kubernetes.client.openapi.models.V1Node instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,16 @@ public V1NodeBuilder(io.kubernetes.client.openapi.models.V1NodeFluent fluent, fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NodeBuilder(io.kubernetes.client.openapi.models.V1Node instance) { - this(instance,false); + this(instance, false); } - public V1NodeBuilder(io.kubernetes.client.openapi.models.V1Node instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NodeBuilder( + io.kubernetes.client.openapi.models.V1Node instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +77,12 @@ public V1NodeBuilder(io.kubernetes.client.openapi.models.V1Node instance,java.la this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Node build() { V1Node buildable = new V1Node(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +92,23 @@ public io.kubernetes.client.openapi.models.V1Node build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeBuilder that = (V1NodeBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConditionBuilder.java index 6c96ef8cf0..09e819576c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeConditionBuilder extends io.kubernetes.client.openapi.models.V1NodeConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeConditionBuilder + extends io.kubernetes.client.openapi.models.V1NodeConditionFluentImpl< + io.kubernetes.client.openapi.models.V1NodeConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NodeCondition, + io.kubernetes.client.openapi.models.V1NodeConditionBuilder> { public V1NodeConditionBuilder() { this(false); } + public V1NodeConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1NodeCondition(), validationEnabled); } - public V1NodeConditionBuilder(io.kubernetes.client.openapi.models.V1NodeConditionFluent fluent) { + + public V1NodeConditionBuilder( + io.kubernetes.client.openapi.models.V1NodeConditionFluent fluent) { this(fluent, false); } - public V1NodeConditionBuilder(io.kubernetes.client.openapi.models.V1NodeConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeConditionBuilder( + io.kubernetes.client.openapi.models.V1NodeConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NodeCondition(), validationEnabled); } - public V1NodeConditionBuilder(io.kubernetes.client.openapi.models.V1NodeConditionFluent fluent,io.kubernetes.client.openapi.models.V1NodeCondition instance) { + + public V1NodeConditionBuilder( + io.kubernetes.client.openapi.models.V1NodeConditionFluent fluent, + io.kubernetes.client.openapi.models.V1NodeCondition instance) { this(fluent, instance, false); } - public V1NodeConditionBuilder(io.kubernetes.client.openapi.models.V1NodeConditionFluent fluent,io.kubernetes.client.openapi.models.V1NodeCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NodeConditionBuilder( + io.kubernetes.client.openapi.models.V1NodeConditionFluent fluent, + io.kubernetes.client.openapi.models.V1NodeCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastHeartbeatTime(instance.getLastHeartbeatTime()); fluent.withLastTransitionTime(instance.getLastTransitionTime()); @@ -33,13 +60,17 @@ public V1NodeConditionBuilder(io.kubernetes.client.openapi.models.V1NodeConditio fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NodeConditionBuilder(io.kubernetes.client.openapi.models.V1NodeCondition instance) { - this(instance,false); + this(instance, false); } - public V1NodeConditionBuilder(io.kubernetes.client.openapi.models.V1NodeCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NodeConditionBuilder( + io.kubernetes.client.openapi.models.V1NodeCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastHeartbeatTime(instance.getLastHeartbeatTime()); this.withLastTransitionTime(instance.getLastTransitionTime()); @@ -52,10 +83,12 @@ public V1NodeConditionBuilder(io.kubernetes.client.openapi.models.V1NodeConditio this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NodeCondition build() { V1NodeCondition buildable = new V1NodeCondition(); buildable.setLastHeartbeatTime(fluent.getLastHeartbeatTime()); @@ -66,18 +99,23 @@ public io.kubernetes.client.openapi.models.V1NodeCondition build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeConditionBuilder that = (V1NodeConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConditionFluent.java index d7c9070ff2..55b9e21405 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConditionFluent.java @@ -1,51 +1,66 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NodeConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NodeConditionFluent< + A extends io.kubernetes.client.openapi.models.V1NodeConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastHeartbeatTime(); + public A withLastHeartbeatTime(java.time.OffsetDateTime lastHeartbeatTime); + public java.lang.Boolean hasLastHeartbeatTime(); + public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public io.kubernetes.client.openapi.models.V1NodeCondition.TypeEnum getType(); + public A withType(io.kubernetes.client.openapi.models.V1NodeCondition.TypeEnum type); + public java.lang.Boolean hasType(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConditionFluentImpl.java index f9c8c3381c..3a9f3213f8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConditionFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1NodeConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NodeConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeConditionFluent { + public V1NodeConditionFluentImpl() {} - /** - * Generated - */ -public class V1NodeConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeConditionFluent{ - public V1NodeConditionFluentImpl() { - } public V1NodeConditionFluentImpl(io.kubernetes.client.openapi.models.V1NodeCondition instance) { this.withLastHeartbeatTime(instance.getLastHeartbeatTime()); @@ -25,106 +31,130 @@ public V1NodeConditionFluentImpl(io.kubernetes.client.openapi.models.V1NodeCondi this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastHeartbeatTime; private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private io.kubernetes.client.openapi.models.V1NodeCondition.TypeEnum type; + public java.time.OffsetDateTime getLastHeartbeatTime() { return this.lastHeartbeatTime; } + public A withLastHeartbeatTime(java.time.OffsetDateTime lastHeartbeatTime) { - this.lastHeartbeatTime=lastHeartbeatTime; return (A) this; + this.lastHeartbeatTime = lastHeartbeatTime; + return (A) this; } + public java.lang.Boolean hasLastHeartbeatTime() { return this.lastHeartbeatTime != null; } + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public io.kubernetes.client.openapi.models.V1NodeCondition.TypeEnum getType() { return this.type; } + public A withType(io.kubernetes.client.openapi.models.V1NodeCondition.TypeEnum type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NodeConditionFluentImpl that = (V1NodeConditionFluentImpl) o; - if (lastHeartbeatTime != null ? !lastHeartbeatTime.equals(that.lastHeartbeatTime) :that.lastHeartbeatTime != null) return false; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (lastHeartbeatTime != null + ? !lastHeartbeatTime.equals(that.lastHeartbeatTime) + : that.lastHeartbeatTime != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastHeartbeatTime, lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastHeartbeatTime, lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigSourceBuilder.java index 1e96a2fe54..c1b06ec9fa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigSourceBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeConfigSourceBuilder extends io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeConfigSourceBuilder + extends io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl< + io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NodeConfigSource, + io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder> { public V1NodeConfigSourceBuilder() { this(false); } + public V1NodeConfigSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1NodeConfigSource(), validationEnabled); } - public V1NodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent fluent) { + + public V1NodeConfigSourceBuilder( + io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent fluent) { this(fluent, false); } - public V1NodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeConfigSourceBuilder( + io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NodeConfigSource(), validationEnabled); } - public V1NodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent fluent,io.kubernetes.client.openapi.models.V1NodeConfigSource instance) { + + public V1NodeConfigSourceBuilder( + io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent fluent, + io.kubernetes.client.openapi.models.V1NodeConfigSource instance) { this(fluent, instance, false); } - public V1NodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent fluent,io.kubernetes.client.openapi.models.V1NodeConfigSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NodeConfigSourceBuilder( + io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent fluent, + io.kubernetes.client.openapi.models.V1NodeConfigSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConfigMap(instance.getConfigMap()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1NodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1NodeConfigSource instance) { - this(instance,false); + + public V1NodeConfigSourceBuilder( + io.kubernetes.client.openapi.models.V1NodeConfigSource instance) { + this(instance, false); } - public V1NodeConfigSourceBuilder(io.kubernetes.client.openapi.models.V1NodeConfigSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NodeConfigSourceBuilder( + io.kubernetes.client.openapi.models.V1NodeConfigSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConfigMap(instance.getConfigMap()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NodeConfigSource build() { V1NodeConfigSource buildable = new V1NodeConfigSource(); buildable.setConfigMap(fluent.getConfigMap()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeConfigSourceBuilder that = (V1NodeConfigSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigSourceFluent.java index ac96c8861d..550c1fc55d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigSourceFluent.java @@ -1,35 +1,57 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NodeConfigSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1NodeConfigSourceFluent< + A extends io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildConfigMap instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource getConfigMap(); + public io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource buildConfigMap(); + public A withConfigMap(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource configMap); + public java.lang.Boolean hasConfigMap(); - public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested withNewConfigMap(); - public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested withNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource item); - public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested editConfigMap(); - public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested editOrNewConfigMap(); - public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested editOrNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource item); - public interface ConfigMapNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent>{ + + public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested + withNewConfigMap(); + + public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested + withNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource item); + + public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested + editConfigMap(); + + public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested + editOrNewConfigMap(); + + public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested + editOrNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource item); + + public interface ConfigMapNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluent< + io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested> { public N and(); + public N endConfigMap(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigSourceFluentImpl.java index a5fafb9780..c306094a7d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigSourceFluentImpl.java @@ -1,81 +1,126 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1NodeConfigSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent{ - public V1NodeConfigSourceFluentImpl() { - } - public V1NodeConfigSourceFluentImpl(io.kubernetes.client.openapi.models.V1NodeConfigSource instance) { - this.withConfigMap(instance.getConfigMap()); +/** Generated */ +public class V1NodeConfigSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent { + public V1NodeConfigSourceFluentImpl() {} + public V1NodeConfigSourceFluentImpl( + io.kubernetes.client.openapi.models.V1NodeConfigSource instance) { + this.withConfigMap(instance.getConfigMap()); } + private io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceBuilder configMap; - + /** * This method has been deprecated, please use method buildConfigMap instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource getConfigMap() { - return this.configMap!=null ?this.configMap.build():null; + return this.configMap != null ? this.configMap.build() : null; } + public io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource buildConfigMap() { - return this.configMap!=null ?this.configMap.build():null; + return this.configMap != null ? this.configMap.build() : null; } - public A withConfigMap(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource configMap) { + + public A withConfigMap( + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource configMap) { _visitables.get("configMap").remove(this.configMap); - if (configMap!=null){ this.configMap= new io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceBuilder(configMap); _visitables.get("configMap").add(this.configMap);} return (A) this; + if (configMap != null) { + this.configMap = + new io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceBuilder(configMap); + _visitables.get("configMap").add(this.configMap); + } + return (A) this; } + public java.lang.Boolean hasConfigMap() { return this.configMap != null; } - public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested withNewConfigMap() { - return new io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl.ConfigMapNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested + withNewConfigMap() { + return new io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl + .ConfigMapNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested withNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource item) { - return new io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl.ConfigMapNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested + withNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource item) { + return new io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl.ConfigMapNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested editConfigMap() { + + public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested + editConfigMap() { return withNewConfigMapLike(getConfigMap()); } - public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested editOrNewConfigMap() { - return withNewConfigMapLike(getConfigMap() != null ? getConfigMap(): new io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested + editOrNewConfigMap() { + return withNewConfigMapLike( + getConfigMap() != null + ? getConfigMap() + : new io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested editOrNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource item) { - return withNewConfigMapLike(getConfigMap() != null ? getConfigMap(): item); + + public io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested + editOrNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource item) { + return withNewConfigMapLike(getConfigMap() != null ? getConfigMap() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NodeConfigSourceFluentImpl that = (V1NodeConfigSourceFluentImpl) o; - if (configMap != null ? !configMap.equals(that.configMap) :that.configMap != null) return false; + if (configMap != null ? !configMap.equals(that.configMap) : that.configMap != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(configMap, super.hashCode()); + return java.util.Objects.hash(configMap, super.hashCode()); } - public class ConfigMapNestedImpl extends io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested,io.kubernetes.client.fluent.Nested{ + + public class ConfigMapNestedImpl + extends io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceFluentImpl< + io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested> + implements io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent.ConfigMapNested, + io.kubernetes.client.fluent.Nested { ConfigMapNestedImpl(io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceBuilder(this, item); } + ConfigMapNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1ConfigMapNodeConfigSourceBuilder builder; + public N and() { return (N) V1NodeConfigSourceFluentImpl.this.withConfigMap(builder.build()); } + public N endConfigMap() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigStatusBuilder.java index 807c290a88..a76f852863 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeConfigStatusBuilder extends io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeConfigStatusBuilder + extends io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl< + io.kubernetes.client.openapi.models.V1NodeConfigStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NodeConfigStatus, + io.kubernetes.client.openapi.models.V1NodeConfigStatusBuilder> { public V1NodeConfigStatusBuilder() { this(false); } + public V1NodeConfigStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1NodeConfigStatus(), validationEnabled); } - public V1NodeConfigStatusBuilder(io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent fluent) { + + public V1NodeConfigStatusBuilder( + io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent fluent) { this(fluent, false); } - public V1NodeConfigStatusBuilder(io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeConfigStatusBuilder( + io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NodeConfigStatus(), validationEnabled); } - public V1NodeConfigStatusBuilder(io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent fluent,io.kubernetes.client.openapi.models.V1NodeConfigStatus instance) { + + public V1NodeConfigStatusBuilder( + io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent fluent, + io.kubernetes.client.openapi.models.V1NodeConfigStatus instance) { this(fluent, instance, false); } - public V1NodeConfigStatusBuilder(io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent fluent,io.kubernetes.client.openapi.models.V1NodeConfigStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NodeConfigStatusBuilder( + io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent fluent, + io.kubernetes.client.openapi.models.V1NodeConfigStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withActive(instance.getActive()); fluent.withAssigned(instance.getAssigned()); @@ -29,13 +56,18 @@ public V1NodeConfigStatusBuilder(io.kubernetes.client.openapi.models.V1NodeConfi fluent.withLastKnownGood(instance.getLastKnownGood()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1NodeConfigStatusBuilder(io.kubernetes.client.openapi.models.V1NodeConfigStatus instance) { - this(instance,false); + + public V1NodeConfigStatusBuilder( + io.kubernetes.client.openapi.models.V1NodeConfigStatus instance) { + this(instance, false); } - public V1NodeConfigStatusBuilder(io.kubernetes.client.openapi.models.V1NodeConfigStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NodeConfigStatusBuilder( + io.kubernetes.client.openapi.models.V1NodeConfigStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withActive(instance.getActive()); this.withAssigned(instance.getAssigned()); @@ -44,10 +76,12 @@ public V1NodeConfigStatusBuilder(io.kubernetes.client.openapi.models.V1NodeConfi this.withLastKnownGood(instance.getLastKnownGood()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NodeConfigStatus build() { V1NodeConfigStatus buildable = new V1NodeConfigStatus(); buildable.setActive(fluent.getActive()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1NodeConfigStatus build() { buildable.setLastKnownGood(fluent.getLastKnownGood()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeConfigStatusBuilder that = (V1NodeConfigStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigStatusFluent.java index 97de86b9f7..f296ce97c8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigStatusFluent.java @@ -1,84 +1,142 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NodeConfigStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1NodeConfigStatusFluent< + A extends io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildActive instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeConfigSource getActive(); + public io.kubernetes.client.openapi.models.V1NodeConfigSource buildActive(); + public A withActive(io.kubernetes.client.openapi.models.V1NodeConfigSource active); + public java.lang.Boolean hasActive(); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested withNewActive(); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested withNewActiveLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested + withNewActive(); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested + withNewActiveLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested editActive(); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested editOrNewActive(); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested editOrNewActiveLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); - + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested + editOrNewActive(); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested + editOrNewActiveLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); + /** * This method has been deprecated, please use method buildAssigned instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeConfigSource getAssigned(); + public io.kubernetes.client.openapi.models.V1NodeConfigSource buildAssigned(); + public A withAssigned(io.kubernetes.client.openapi.models.V1NodeConfigSource assigned); + public java.lang.Boolean hasAssigned(); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested withNewAssigned(); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested withNewAssignedLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested editAssigned(); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested editOrNewAssigned(); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested editOrNewAssignedLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested + withNewAssigned(); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested + withNewAssignedLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested + editAssigned(); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested + editOrNewAssigned(); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested + editOrNewAssignedLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); + public java.lang.String getError(); + public A withError(java.lang.String error); + public java.lang.Boolean hasError(); - - /** - * Method is deprecated. use withError instead. - */ + + /** Method is deprecated. use withError instead. */ @java.lang.Deprecated public A withNewError(java.lang.String original); - + /** * This method has been deprecated, please use method buildLastKnownGood instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeConfigSource getLastKnownGood(); + public io.kubernetes.client.openapi.models.V1NodeConfigSource buildLastKnownGood(); + public A withLastKnownGood(io.kubernetes.client.openapi.models.V1NodeConfigSource lastKnownGood); + public java.lang.Boolean hasLastKnownGood(); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested withNewLastKnownGood(); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested withNewLastKnownGoodLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested editLastKnownGood(); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested editOrNewLastKnownGood(); - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested editOrNewLastKnownGoodLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); - public interface ActiveNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent>{ + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested + withNewLastKnownGood(); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested + withNewLastKnownGoodLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested + editLastKnownGood(); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested + editOrNewLastKnownGood(); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested + editOrNewLastKnownGoodLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); + + public interface ActiveNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent< + io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested> { public N and(); + public N endActive(); - } - public interface AssignedNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent>{ + + public interface AssignedNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent< + io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested> { public N and(); + public N endAssigned(); - } - public interface LastKnownGoodNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent>{ + + public interface LastKnownGoodNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent< + io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested> { public N and(); + public N endLastKnownGood(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigStatusFluentImpl.java index 4b1a20843e..afddd7d277 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeConfigStatusFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1NodeConfigStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent { + public V1NodeConfigStatusFluentImpl() {} - /** - * Generated - */ -public class V1NodeConfigStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent{ - public V1NodeConfigStatusFluentImpl() { - } - public V1NodeConfigStatusFluentImpl(io.kubernetes.client.openapi.models.V1NodeConfigStatus instance) { + public V1NodeConfigStatusFluentImpl( + io.kubernetes.client.openapi.models.V1NodeConfigStatus instance) { this.withActive(instance.getActive()); this.withAssigned(instance.getAssigned()); @@ -21,191 +28,289 @@ public V1NodeConfigStatusFluentImpl(io.kubernetes.client.openapi.models.V1NodeCo this.withError(instance.getError()); this.withLastKnownGood(instance.getLastKnownGood()); - } + private io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder active; private io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder assigned; private java.lang.String error; private io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder lastKnownGood; - + /** * This method has been deprecated, please use method buildActive instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeConfigSource getActive() { - return this.active!=null ?this.active.build():null; + return this.active != null ? this.active.build() : null; } + public io.kubernetes.client.openapi.models.V1NodeConfigSource buildActive() { - return this.active!=null ?this.active.build():null; + return this.active != null ? this.active.build() : null; } + public A withActive(io.kubernetes.client.openapi.models.V1NodeConfigSource active) { _visitables.get("active").remove(this.active); - if (active!=null){ this.active= new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(active); _visitables.get("active").add(this.active);} return (A) this; + if (active != null) { + this.active = new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(active); + _visitables.get("active").add(this.active); + } + return (A) this; } + public java.lang.Boolean hasActive() { return this.active != null; } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested withNewActive() { + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested + withNewActive() { return new io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl.ActiveNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested withNewActiveLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { - return new io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl.ActiveNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested + withNewActiveLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { + return new io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl.ActiveNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested editActive() { return withNewActiveLike(getActive()); } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested editOrNewActive() { - return withNewActiveLike(getActive() != null ? getActive(): new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested + editOrNewActive() { + return withNewActiveLike( + getActive() != null + ? getActive() + : new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested editOrNewActiveLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { - return withNewActiveLike(getActive() != null ? getActive(): item); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested + editOrNewActiveLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { + return withNewActiveLike(getActive() != null ? getActive() : item); } - + /** * This method has been deprecated, please use method buildAssigned instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeConfigSource getAssigned() { - return this.assigned!=null ?this.assigned.build():null; + return this.assigned != null ? this.assigned.build() : null; } + public io.kubernetes.client.openapi.models.V1NodeConfigSource buildAssigned() { - return this.assigned!=null ?this.assigned.build():null; + return this.assigned != null ? this.assigned.build() : null; } + public A withAssigned(io.kubernetes.client.openapi.models.V1NodeConfigSource assigned) { _visitables.get("assigned").remove(this.assigned); - if (assigned!=null){ this.assigned= new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(assigned); _visitables.get("assigned").add(this.assigned);} return (A) this; + if (assigned != null) { + this.assigned = new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(assigned); + _visitables.get("assigned").add(this.assigned); + } + return (A) this; } + public java.lang.Boolean hasAssigned() { return this.assigned != null; } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested withNewAssigned() { - return new io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl.AssignedNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested + withNewAssigned() { + return new io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl + .AssignedNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested withNewAssignedLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { - return new io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl.AssignedNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested + withNewAssignedLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { + return new io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl.AssignedNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested editAssigned() { + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested + editAssigned() { return withNewAssignedLike(getAssigned()); } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested editOrNewAssigned() { - return withNewAssignedLike(getAssigned() != null ? getAssigned(): new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested + editOrNewAssigned() { + return withNewAssignedLike( + getAssigned() != null + ? getAssigned() + : new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested editOrNewAssignedLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { - return withNewAssignedLike(getAssigned() != null ? getAssigned(): item); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested + editOrNewAssignedLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { + return withNewAssignedLike(getAssigned() != null ? getAssigned() : item); } + public java.lang.String getError() { return this.error; } + public A withError(java.lang.String error) { - this.error=error; return (A) this; + this.error = error; + return (A) this; } + public java.lang.Boolean hasError() { return this.error != null; } - - /** - * Method is deprecated. use withError instead. - */ + + /** Method is deprecated. use withError instead. */ @java.lang.Deprecated public A withNewError(java.lang.String original) { - return (A)withError(new String(original)); + return (A) withError(new String(original)); } - + /** * This method has been deprecated, please use method buildLastKnownGood instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeConfigSource getLastKnownGood() { - return this.lastKnownGood!=null ?this.lastKnownGood.build():null; + return this.lastKnownGood != null ? this.lastKnownGood.build() : null; } + public io.kubernetes.client.openapi.models.V1NodeConfigSource buildLastKnownGood() { - return this.lastKnownGood!=null ?this.lastKnownGood.build():null; + return this.lastKnownGood != null ? this.lastKnownGood.build() : null; } + public A withLastKnownGood(io.kubernetes.client.openapi.models.V1NodeConfigSource lastKnownGood) { _visitables.get("lastKnownGood").remove(this.lastKnownGood); - if (lastKnownGood!=null){ this.lastKnownGood= new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(lastKnownGood); _visitables.get("lastKnownGood").add(this.lastKnownGood);} return (A) this; + if (lastKnownGood != null) { + this.lastKnownGood = + new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(lastKnownGood); + _visitables.get("lastKnownGood").add(this.lastKnownGood); + } + return (A) this; } + public java.lang.Boolean hasLastKnownGood() { return this.lastKnownGood != null; } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested withNewLastKnownGood() { - return new io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl.LastKnownGoodNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested + withNewLastKnownGood() { + return new io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl + .LastKnownGoodNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested withNewLastKnownGoodLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { - return new io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl.LastKnownGoodNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested + withNewLastKnownGoodLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { + return new io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl + .LastKnownGoodNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested editLastKnownGood() { + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested + editLastKnownGood() { return withNewLastKnownGoodLike(getLastKnownGood()); } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested editOrNewLastKnownGood() { - return withNewLastKnownGoodLike(getLastKnownGood() != null ? getLastKnownGood(): new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested + editOrNewLastKnownGood() { + return withNewLastKnownGoodLike( + getLastKnownGood() != null + ? getLastKnownGood() + : new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested editOrNewLastKnownGoodLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { - return withNewLastKnownGoodLike(getLastKnownGood() != null ? getLastKnownGood(): item); + + public io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested + editOrNewLastKnownGoodLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { + return withNewLastKnownGoodLike(getLastKnownGood() != null ? getLastKnownGood() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NodeConfigStatusFluentImpl that = (V1NodeConfigStatusFluentImpl) o; - if (active != null ? !active.equals(that.active) :that.active != null) return false; - if (assigned != null ? !assigned.equals(that.assigned) :that.assigned != null) return false; - if (error != null ? !error.equals(that.error) :that.error != null) return false; - if (lastKnownGood != null ? !lastKnownGood.equals(that.lastKnownGood) :that.lastKnownGood != null) return false; + if (active != null ? !active.equals(that.active) : that.active != null) return false; + if (assigned != null ? !assigned.equals(that.assigned) : that.assigned != null) return false; + if (error != null ? !error.equals(that.error) : that.error != null) return false; + if (lastKnownGood != null + ? !lastKnownGood.equals(that.lastKnownGood) + : that.lastKnownGood != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(active, assigned, error, lastKnownGood, super.hashCode()); + return java.util.Objects.hash(active, assigned, error, lastKnownGood, super.hashCode()); } - public class ActiveNestedImpl extends io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested,io.kubernetes.client.fluent.Nested{ + + public class ActiveNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl< + io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested> + implements io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.ActiveNested, + io.kubernetes.client.fluent.Nested { ActiveNestedImpl(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { this.builder = new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(this, item); } + ActiveNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder builder; + public N and() { return (N) V1NodeConfigStatusFluentImpl.this.withActive(builder.build()); } + public N endActive() { return and(); } - } - public class AssignedNestedImpl extends io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested,io.kubernetes.client.fluent.Nested{ + + public class AssignedNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl< + io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested> + implements io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.AssignedNested, + io.kubernetes.client.fluent.Nested { AssignedNestedImpl(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { this.builder = new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(this, item); } + AssignedNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder builder; + public N and() { return (N) V1NodeConfigStatusFluentImpl.this.withAssigned(builder.build()); } + public N endAssigned() { return and(); } - } - public class LastKnownGoodNestedImpl extends io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested,io.kubernetes.client.fluent.Nested{ + + public class LastKnownGoodNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl< + io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested> + implements io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent.LastKnownGoodNested< + N>, + io.kubernetes.client.fluent.Nested { LastKnownGoodNestedImpl(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { this.builder = new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(this, item); } + LastKnownGoodNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder builder; + public N and() { return (N) V1NodeConfigStatusFluentImpl.this.withLastKnownGood(builder.build()); } + public N endLastKnownGood() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeDaemonEndpointsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeDaemonEndpointsBuilder.java index 1c138667a6..f80f206555 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeDaemonEndpointsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeDaemonEndpointsBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeDaemonEndpointsBuilder extends io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeDaemonEndpointsBuilder + extends io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluentImpl< + io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints, + io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsBuilder> { public V1NodeDaemonEndpointsBuilder() { this(false); } + public V1NodeDaemonEndpointsBuilder(java.lang.Boolean validationEnabled) { this(new V1NodeDaemonEndpoints(), validationEnabled); } - public V1NodeDaemonEndpointsBuilder(io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent fluent) { + + public V1NodeDaemonEndpointsBuilder( + io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent fluent) { this(fluent, false); } - public V1NodeDaemonEndpointsBuilder(io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeDaemonEndpointsBuilder( + io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NodeDaemonEndpoints(), validationEnabled); } - public V1NodeDaemonEndpointsBuilder(io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent fluent,io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints instance) { + + public V1NodeDaemonEndpointsBuilder( + io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent fluent, + io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints instance) { this(fluent, instance, false); } - public V1NodeDaemonEndpointsBuilder(io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent fluent,io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NodeDaemonEndpointsBuilder( + io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent fluent, + io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withKubeletEndpoint(instance.getKubeletEndpoint()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1NodeDaemonEndpointsBuilder(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints instance) { - this(instance,false); + + public V1NodeDaemonEndpointsBuilder( + io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints instance) { + this(instance, false); } - public V1NodeDaemonEndpointsBuilder(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NodeDaemonEndpointsBuilder( + io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withKubeletEndpoint(instance.getKubeletEndpoint()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints build() { V1NodeDaemonEndpoints buildable = new V1NodeDaemonEndpoints(); buildable.setKubeletEndpoint(fluent.getKubeletEndpoint()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeDaemonEndpointsBuilder that = (V1NodeDaemonEndpointsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeDaemonEndpointsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeDaemonEndpointsFluent.java index 9b99457d22..d37e4afa5e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeDaemonEndpointsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeDaemonEndpointsFluent.java @@ -1,35 +1,59 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NodeDaemonEndpointsFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1NodeDaemonEndpointsFluent< + A extends io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildKubeletEndpoint instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DaemonEndpoint getKubeletEndpoint(); + public io.kubernetes.client.openapi.models.V1DaemonEndpoint buildKubeletEndpoint(); - public A withKubeletEndpoint(io.kubernetes.client.openapi.models.V1DaemonEndpoint kubeletEndpoint); + + public A withKubeletEndpoint( + io.kubernetes.client.openapi.models.V1DaemonEndpoint kubeletEndpoint); + public java.lang.Boolean hasKubeletEndpoint(); - public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested withNewKubeletEndpoint(); - public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested withNewKubeletEndpointLike(io.kubernetes.client.openapi.models.V1DaemonEndpoint item); - public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested editKubeletEndpoint(); - public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested editOrNewKubeletEndpoint(); - public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested editOrNewKubeletEndpointLike(io.kubernetes.client.openapi.models.V1DaemonEndpoint item); - public interface KubeletEndpointNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DaemonEndpointFluent>{ + + public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested + withNewKubeletEndpoint(); + + public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested + withNewKubeletEndpointLike(io.kubernetes.client.openapi.models.V1DaemonEndpoint item); + + public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested + editKubeletEndpoint(); + + public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested + editOrNewKubeletEndpoint(); + + public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested + editOrNewKubeletEndpointLike(io.kubernetes.client.openapi.models.V1DaemonEndpoint item); + + public interface KubeletEndpointNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DaemonEndpointFluent< + io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested< + N>> { public N and(); + public N endKubeletEndpoint(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeDaemonEndpointsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeDaemonEndpointsFluentImpl.java index 2ce1baacaf..6b7348fdb9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeDaemonEndpointsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeDaemonEndpointsFluentImpl.java @@ -1,81 +1,127 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1NodeDaemonEndpointsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent{ - public V1NodeDaemonEndpointsFluentImpl() { - } - public V1NodeDaemonEndpointsFluentImpl(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints instance) { - this.withKubeletEndpoint(instance.getKubeletEndpoint()); +/** Generated */ +public class V1NodeDaemonEndpointsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent { + public V1NodeDaemonEndpointsFluentImpl() {} + public V1NodeDaemonEndpointsFluentImpl( + io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints instance) { + this.withKubeletEndpoint(instance.getKubeletEndpoint()); } + private io.kubernetes.client.openapi.models.V1DaemonEndpointBuilder kubeletEndpoint; - + /** * This method has been deprecated, please use method buildKubeletEndpoint instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DaemonEndpoint getKubeletEndpoint() { - return this.kubeletEndpoint!=null ?this.kubeletEndpoint.build():null; + return this.kubeletEndpoint != null ? this.kubeletEndpoint.build() : null; } + public io.kubernetes.client.openapi.models.V1DaemonEndpoint buildKubeletEndpoint() { - return this.kubeletEndpoint!=null ?this.kubeletEndpoint.build():null; + return this.kubeletEndpoint != null ? this.kubeletEndpoint.build() : null; } - public A withKubeletEndpoint(io.kubernetes.client.openapi.models.V1DaemonEndpoint kubeletEndpoint) { + + public A withKubeletEndpoint( + io.kubernetes.client.openapi.models.V1DaemonEndpoint kubeletEndpoint) { _visitables.get("kubeletEndpoint").remove(this.kubeletEndpoint); - if (kubeletEndpoint!=null){ this.kubeletEndpoint= new io.kubernetes.client.openapi.models.V1DaemonEndpointBuilder(kubeletEndpoint); _visitables.get("kubeletEndpoint").add(this.kubeletEndpoint);} return (A) this; + if (kubeletEndpoint != null) { + this.kubeletEndpoint = + new io.kubernetes.client.openapi.models.V1DaemonEndpointBuilder(kubeletEndpoint); + _visitables.get("kubeletEndpoint").add(this.kubeletEndpoint); + } + return (A) this; } + public java.lang.Boolean hasKubeletEndpoint() { return this.kubeletEndpoint != null; } - public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested withNewKubeletEndpoint() { - return new io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluentImpl.KubeletEndpointNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested + withNewKubeletEndpoint() { + return new io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluentImpl + .KubeletEndpointNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested withNewKubeletEndpointLike(io.kubernetes.client.openapi.models.V1DaemonEndpoint item) { - return new io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluentImpl.KubeletEndpointNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested + withNewKubeletEndpointLike(io.kubernetes.client.openapi.models.V1DaemonEndpoint item) { + return new io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluentImpl + .KubeletEndpointNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested editKubeletEndpoint() { + + public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested + editKubeletEndpoint() { return withNewKubeletEndpointLike(getKubeletEndpoint()); } - public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested editOrNewKubeletEndpoint() { - return withNewKubeletEndpointLike(getKubeletEndpoint() != null ? getKubeletEndpoint(): new io.kubernetes.client.openapi.models.V1DaemonEndpointBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested + editOrNewKubeletEndpoint() { + return withNewKubeletEndpointLike( + getKubeletEndpoint() != null + ? getKubeletEndpoint() + : new io.kubernetes.client.openapi.models.V1DaemonEndpointBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested editOrNewKubeletEndpointLike(io.kubernetes.client.openapi.models.V1DaemonEndpoint item) { - return withNewKubeletEndpointLike(getKubeletEndpoint() != null ? getKubeletEndpoint(): item); + + public io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested + editOrNewKubeletEndpointLike(io.kubernetes.client.openapi.models.V1DaemonEndpoint item) { + return withNewKubeletEndpointLike(getKubeletEndpoint() != null ? getKubeletEndpoint() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NodeDaemonEndpointsFluentImpl that = (V1NodeDaemonEndpointsFluentImpl) o; - if (kubeletEndpoint != null ? !kubeletEndpoint.equals(that.kubeletEndpoint) :that.kubeletEndpoint != null) return false; + if (kubeletEndpoint != null + ? !kubeletEndpoint.equals(that.kubeletEndpoint) + : that.kubeletEndpoint != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(kubeletEndpoint, super.hashCode()); + return java.util.Objects.hash(kubeletEndpoint, super.hashCode()); } - public class KubeletEndpointNestedImpl extends io.kubernetes.client.openapi.models.V1DaemonEndpointFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested,io.kubernetes.client.fluent.Nested{ + + public class KubeletEndpointNestedImpl + extends io.kubernetes.client.openapi.models.V1DaemonEndpointFluentImpl< + io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent.KubeletEndpointNested> + implements io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent + .KubeletEndpointNested< + N>, + io.kubernetes.client.fluent.Nested { KubeletEndpointNestedImpl(io.kubernetes.client.openapi.models.V1DaemonEndpoint item) { this.builder = new io.kubernetes.client.openapi.models.V1DaemonEndpointBuilder(this, item); } + KubeletEndpointNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1DaemonEndpointBuilder(this); } + io.kubernetes.client.openapi.models.V1DaemonEndpointBuilder builder; + public N and() { return (N) V1NodeDaemonEndpointsFluentImpl.this.withKubeletEndpoint(builder.build()); } + public N endKubeletEndpoint() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeFluent.java index 7b387eabf6..43be08475c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeFluent.java @@ -1,93 +1,142 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NodeFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NodeFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeSpec getSpec(); + public io.kubernetes.client.openapi.models.V1NodeSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1NodeSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1NodeSpec item); + + public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1NodeSpec item); + public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1NodeSpec item); - + + public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1NodeSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeStatus getStatus(); + public io.kubernetes.client.openapi.models.V1NodeStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1NodeStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1NodeStatus item); + + public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1NodeStatus item); + public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1NodeStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1NodeStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeSpecFluent< + io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeStatusFluent< + io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeFluentImpl.java index 8928bccd5c..90125cec9f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1NodeFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeFluent { + public V1NodeFluentImpl() {} - /** - * Generated - */ -public class V1NodeFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeFluent{ - public V1NodeFluentImpl() { - } public V1NodeFluentImpl(io.kubernetes.client.openapi.models.V1Node instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +28,294 @@ public V1NodeFluentImpl(io.kubernetes.client.openapi.models.V1Node instance) { this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1NodeSpecBuilder spec; private io.kubernetes.client.openapi.models.V1NodeStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1NodeFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1NodeFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1NodeSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1NodeSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1NodeSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1NodeSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1NodeFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1NodeSpec item) { + + public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1NodeSpec item) { return new io.kubernetes.client.openapi.models.V1NodeFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1NodeSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1NodeSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1NodeSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1NodeSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1NodeStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1NodeStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1NodeStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1NodeStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1NodeFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1NodeStatus item) { + + public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1NodeStatus item) { return new io.kubernetes.client.openapi.models.V1NodeFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1NodeStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1NodeStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1NodeStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1NodeStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NodeFluentImpl that = (V1NodeFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1NodeFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1NodeFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1NodeSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeSpecFluentImpl< + io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1NodeFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1NodeSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1NodeSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NodeSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeSpecBuilder builder; + public N and() { return (N) V1NodeFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl< + io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1NodeFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1NodeStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1NodeStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NodeStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeStatusBuilder builder; + public N and() { return (N) V1NodeFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeListBuilder.java index 23825d670c..62367d3c8a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeListBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeListBuilder extends io.kubernetes.client.openapi.models.V1NodeListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeListBuilder + extends io.kubernetes.client.openapi.models.V1NodeListFluentImpl< + io.kubernetes.client.openapi.models.V1NodeListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NodeList, + io.kubernetes.client.openapi.models.V1NodeListBuilder> { public V1NodeListBuilder() { this(false); } + public V1NodeListBuilder(java.lang.Boolean validationEnabled) { this(new V1NodeList(), validationEnabled); } + public V1NodeListBuilder(io.kubernetes.client.openapi.models.V1NodeListFluent fluent) { this(fluent, false); } - public V1NodeListBuilder(io.kubernetes.client.openapi.models.V1NodeListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeListBuilder( + io.kubernetes.client.openapi.models.V1NodeListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NodeList(), validationEnabled); } - public V1NodeListBuilder(io.kubernetes.client.openapi.models.V1NodeListFluent fluent,io.kubernetes.client.openapi.models.V1NodeList instance) { + + public V1NodeListBuilder( + io.kubernetes.client.openapi.models.V1NodeListFluent fluent, + io.kubernetes.client.openapi.models.V1NodeList instance) { this(fluent, instance, false); } - public V1NodeListBuilder(io.kubernetes.client.openapi.models.V1NodeListFluent fluent,io.kubernetes.client.openapi.models.V1NodeList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NodeListBuilder( + io.kubernetes.client.openapi.models.V1NodeListFluent fluent, + io.kubernetes.client.openapi.models.V1NodeList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +55,17 @@ public V1NodeListBuilder(io.kubernetes.client.openapi.models.V1NodeListFluent fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NodeListBuilder(io.kubernetes.client.openapi.models.V1NodeList instance) { - this(instance,false); + this(instance, false); } - public V1NodeListBuilder(io.kubernetes.client.openapi.models.V1NodeList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NodeListBuilder( + io.kubernetes.client.openapi.models.V1NodeList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +74,12 @@ public V1NodeListBuilder(io.kubernetes.client.openapi.models.V1NodeList instance this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NodeList build() { V1NodeList buildable = new V1NodeList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1NodeList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeListBuilder that = (V1NodeListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeListFluent.java index 0937c12609..f606959f04 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeListFluent.java @@ -1,95 +1,143 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NodeListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NodeListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Node item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Node item); + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Node item); + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Node item); + public A addToItems(io.kubernetes.client.openapi.models.V1Node... items); + public A addAllToItems(java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1Node... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1Node buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Node buildFirstItem(); + public io.kubernetes.client.openapi.models.V1Node buildLastItem(); - public io.kubernetes.client.openapi.models.V1Node buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Node buildMatchingItem( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1Node... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Node item); - public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Node item); - public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Node item); + + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Node item); + + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeFluent>{ + + public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeFluent< + io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeListFluentImpl.java index 314881bf42..cb6c3da059 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeListFluentImpl.java @@ -1,25 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1NodeListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeListFluent{ - public V1NodeListFluentImpl() { - } +/** Generated */ +public class V1NodeListFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeListFluent { + public V1NodeListFluentImpl() {} + public V1NodeListFluentImpl(io.kubernetes.client.openapi.models.V1NodeList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +29,115 @@ public V1NodeListFluentImpl(io.kubernetes.client.openapi.models.V1NodeList insta this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Node item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NodeBuilder builder = new io.kubernetes.client.openapi.models.V1NodeBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Node item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NodeBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Node item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NodeBuilder builder = new io.kubernetes.client.openapi.models.V1NodeBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Node item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NodeBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1Node... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Node item : items) {io.kubernetes.client.openapi.models.V1NodeBuilder builder = new io.kubernetes.client.openapi.models.V1NodeBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Node item : items) { + io.kubernetes.client.openapi.models.V1NodeBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Node item : items) {io.kubernetes.client.openapi.models.V1NodeBuilder builder = new io.kubernetes.client.openapi.models.V1NodeBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Node item : items) { + io.kubernetes.client.openapi.models.V1NodeBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1Node... items) { - for (io.kubernetes.client.openapi.models.V1Node item : items) {io.kubernetes.client.openapi.models.V1NodeBuilder builder = new io.kubernetes.client.openapi.models.V1NodeBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Node item : items) { + io.kubernetes.client.openapi.models.V1NodeBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Node item : items) {io.kubernetes.client.openapi.models.V1NodeBuilder builder = new io.kubernetes.client.openapi.models.V1NodeBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Node item : items) { + io.kubernetes.client.openapi.models.V1NodeBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +148,267 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1Node buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Node buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Node buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Node buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NodeBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Node buildMatchingItem( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1NodeBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NodeBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1NodeBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Node item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Node item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1Node... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1Node item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1Node item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1NodeListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Node item) { + + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Node item) { return new io.kubernetes.client.openapi.models.V1NodeListFluentImpl.ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Node item) { - return new io.kubernetes.client.openapi.models.V1NodeListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Node item) { + return new io.kubernetes.client.openapi.models.V1NodeListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate) { int index = -1; - for (int i=0;i withNewMetadata() { return new io.kubernetes.client.openapi.models.V1NodeListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + + public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ListMeta item) { return new io.kubernetes.client.openapi.models.V1NodeListFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NodeListFluentImpl that = (V1NodeListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1NodeFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Node item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeFluentImpl< + io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1NodeListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Node item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1NodeBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NodeBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NodeListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1NodeListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1NodeListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1NodeListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorBuilder.java index f1327bf96e..d7896b0eef 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorBuilder.java @@ -1,58 +1,95 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeSelectorBuilder extends io.kubernetes.client.openapi.models.V1NodeSelectorFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeSelectorBuilder + extends io.kubernetes.client.openapi.models.V1NodeSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1NodeSelectorBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NodeSelector, + io.kubernetes.client.openapi.models.V1NodeSelectorBuilder> { public V1NodeSelectorBuilder() { this(false); } + public V1NodeSelectorBuilder(java.lang.Boolean validationEnabled) { this(new V1NodeSelector(), validationEnabled); } + public V1NodeSelectorBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorFluent fluent) { this(fluent, false); } - public V1NodeSelectorBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeSelectorBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NodeSelector(), validationEnabled); } - public V1NodeSelectorBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorFluent fluent,io.kubernetes.client.openapi.models.V1NodeSelector instance) { + + public V1NodeSelectorBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorFluent fluent, + io.kubernetes.client.openapi.models.V1NodeSelector instance) { this(fluent, instance, false); } - public V1NodeSelectorBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorFluent fluent,io.kubernetes.client.openapi.models.V1NodeSelector instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NodeSelectorBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorFluent fluent, + io.kubernetes.client.openapi.models.V1NodeSelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNodeSelectorTerms(instance.getNodeSelectorTerms()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NodeSelectorBuilder(io.kubernetes.client.openapi.models.V1NodeSelector instance) { - this(instance,false); + this(instance, false); } - public V1NodeSelectorBuilder(io.kubernetes.client.openapi.models.V1NodeSelector instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NodeSelectorBuilder( + io.kubernetes.client.openapi.models.V1NodeSelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNodeSelectorTerms(instance.getNodeSelectorTerms()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeSelectorFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NodeSelector build() { V1NodeSelector buildable = new V1NodeSelector(); buildable.setNodeSelectorTerms(fluent.getNodeSelectorTerms()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeSelectorBuilder that = (V1NodeSelectorBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorFluent.java index f0161b2480..7517135081 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorFluent.java @@ -1,57 +1,108 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NodeSelectorFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToNodeSelectorTerms(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorTerm item); - public A setToNodeSelectorTerms(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorTerm item); +/** Generated */ +public interface V1NodeSelectorFluent< + A extends io.kubernetes.client.openapi.models.V1NodeSelectorFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToNodeSelectorTerms( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorTerm item); + + public A setToNodeSelectorTerms( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorTerm item); + public A addToNodeSelectorTerms(io.kubernetes.client.openapi.models.V1NodeSelectorTerm... items); - public A addAllToNodeSelectorTerms(java.util.Collection items); - public A removeFromNodeSelectorTerms(io.kubernetes.client.openapi.models.V1NodeSelectorTerm... items); - public A removeAllFromNodeSelectorTerms(java.util.Collection items); - public A removeMatchingFromNodeSelectorTerms(java.util.function.Predicate predicate); - + + public A addAllToNodeSelectorTerms( + java.util.Collection items); + + public A removeFromNodeSelectorTerms( + io.kubernetes.client.openapi.models.V1NodeSelectorTerm... items); + + public A removeAllFromNodeSelectorTerms( + java.util.Collection items); + + public A removeMatchingFromNodeSelectorTerms( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildNodeSelectorTerms instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getNodeSelectorTerms(); - public java.util.List buildNodeSelectorTerms(); - public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildNodeSelectorTerm(java.lang.Integer index); + public java.util.List + getNodeSelectorTerms(); + + public java.util.List + buildNodeSelectorTerms(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildNodeSelectorTerm( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildFirstNodeSelectorTerm(); + public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildLastNodeSelectorTerm(); - public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildMatchingNodeSelectorTerm(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingNodeSelectorTerm(java.util.function.Predicate predicate); - public A withNodeSelectorTerms(java.util.List nodeSelectorTerms); - public A withNodeSelectorTerms(io.kubernetes.client.openapi.models.V1NodeSelectorTerm... nodeSelectorTerms); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildMatchingNodeSelectorTerm( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingNodeSelectorTerm( + java.util.function.Predicate + predicate); + + public A withNodeSelectorTerms( + java.util.List nodeSelectorTerms); + + public A withNodeSelectorTerms( + io.kubernetes.client.openapi.models.V1NodeSelectorTerm... nodeSelectorTerms); + public java.lang.Boolean hasNodeSelectorTerms(); - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested addNewNodeSelectorTerm(); - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested addNewNodeSelectorTermLike(io.kubernetes.client.openapi.models.V1NodeSelectorTerm item); - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested setNewNodeSelectorTermLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorTerm item); - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested editNodeSelectorTerm(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested editFirstNodeSelectorTerm(); - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested editLastNodeSelectorTerm(); - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested editMatchingNodeSelectorTerm(java.util.function.Predicate predicate); - public interface NodeSelectorTermsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent>{ + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + addNewNodeSelectorTerm(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + addNewNodeSelectorTermLike(io.kubernetes.client.openapi.models.V1NodeSelectorTerm item); + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + setNewNodeSelectorTermLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorTerm item); + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + editNodeSelectorTerm(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + editFirstNodeSelectorTerm(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + editLastNodeSelectorTerm(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + editMatchingNodeSelectorTerm( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder> + predicate); + + public interface NodeSelectorTermsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent< + io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested> { public N and(); + public N endNodeSelectorTerm(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorFluentImpl.java index 7675f8eedc..9beb70cf24 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorFluentImpl.java @@ -1,57 +1,131 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1NodeSelectorFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeSelectorFluent{ - public V1NodeSelectorFluentImpl() { - } +/** Generated */ +public class V1NodeSelectorFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NodeSelectorFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeSelectorFluent { + public V1NodeSelectorFluentImpl() {} + public V1NodeSelectorFluentImpl(io.kubernetes.client.openapi.models.V1NodeSelector instance) { this.withNodeSelectorTerms(instance.getNodeSelectorTerms()); - } - private java.util.ArrayList nodeSelectorTerms; - public A addToNodeSelectorTerms(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { - if (this.nodeSelectorTerms == null) {this.nodeSelectorTerms = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(item);_visitables.get("nodeSelectorTerms").add(index >= 0 ? index : _visitables.get("nodeSelectorTerms").size(), builder);this.nodeSelectorTerms.add(index >= 0 ? index : nodeSelectorTerms.size(), builder); return (A)this; + + private java.util.ArrayList + nodeSelectorTerms; + + public A addToNodeSelectorTerms( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { + if (this.nodeSelectorTerms == null) { + this.nodeSelectorTerms = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(item); + _visitables + .get("nodeSelectorTerms") + .add(index >= 0 ? index : _visitables.get("nodeSelectorTerms").size(), builder); + this.nodeSelectorTerms.add(index >= 0 ? index : nodeSelectorTerms.size(), builder); + return (A) this; } - public A setToNodeSelectorTerms(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { - if (this.nodeSelectorTerms == null) {this.nodeSelectorTerms = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(item); - if (index < 0 || index >= _visitables.get("nodeSelectorTerms").size()) { _visitables.get("nodeSelectorTerms").add(builder); } else { _visitables.get("nodeSelectorTerms").set(index, builder);} - if (index < 0 || index >= nodeSelectorTerms.size()) { nodeSelectorTerms.add(builder); } else { nodeSelectorTerms.set(index, builder);} - return (A)this; + + public A setToNodeSelectorTerms( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { + if (this.nodeSelectorTerms == null) { + this.nodeSelectorTerms = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(item); + if (index < 0 || index >= _visitables.get("nodeSelectorTerms").size()) { + _visitables.get("nodeSelectorTerms").add(builder); + } else { + _visitables.get("nodeSelectorTerms").set(index, builder); + } + if (index < 0 || index >= nodeSelectorTerms.size()) { + nodeSelectorTerms.add(builder); + } else { + nodeSelectorTerms.set(index, builder); + } + return (A) this; } + public A addToNodeSelectorTerms(io.kubernetes.client.openapi.models.V1NodeSelectorTerm... items) { - if (this.nodeSelectorTerms == null) {this.nodeSelectorTerms = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NodeSelectorTerm item : items) {io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(item);_visitables.get("nodeSelectorTerms").add(builder);this.nodeSelectorTerms.add(builder);} return (A)this; + if (this.nodeSelectorTerms == null) { + this.nodeSelectorTerms = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NodeSelectorTerm item : items) { + io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(item); + _visitables.get("nodeSelectorTerms").add(builder); + this.nodeSelectorTerms.add(builder); + } + return (A) this; } - public A addAllToNodeSelectorTerms(java.util.Collection items) { - if (this.nodeSelectorTerms == null) {this.nodeSelectorTerms = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NodeSelectorTerm item : items) {io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(item);_visitables.get("nodeSelectorTerms").add(builder);this.nodeSelectorTerms.add(builder);} return (A)this; + + public A addAllToNodeSelectorTerms( + java.util.Collection items) { + if (this.nodeSelectorTerms == null) { + this.nodeSelectorTerms = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NodeSelectorTerm item : items) { + io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(item); + _visitables.get("nodeSelectorTerms").add(builder); + this.nodeSelectorTerms.add(builder); + } + return (A) this; } - public A removeFromNodeSelectorTerms(io.kubernetes.client.openapi.models.V1NodeSelectorTerm... items) { - for (io.kubernetes.client.openapi.models.V1NodeSelectorTerm item : items) {io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(item);_visitables.get("nodeSelectorTerms").remove(builder);if (this.nodeSelectorTerms != null) {this.nodeSelectorTerms.remove(builder);}} return (A)this; + + public A removeFromNodeSelectorTerms( + io.kubernetes.client.openapi.models.V1NodeSelectorTerm... items) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorTerm item : items) { + io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(item); + _visitables.get("nodeSelectorTerms").remove(builder); + if (this.nodeSelectorTerms != null) { + this.nodeSelectorTerms.remove(builder); + } + } + return (A) this; } - public A removeAllFromNodeSelectorTerms(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NodeSelectorTerm item : items) {io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(item);_visitables.get("nodeSelectorTerms").remove(builder);if (this.nodeSelectorTerms != null) {this.nodeSelectorTerms.remove(builder);}} return (A)this; + + public A removeAllFromNodeSelectorTerms( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorTerm item : items) { + io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(item); + _visitables.get("nodeSelectorTerms").remove(builder); + if (this.nodeSelectorTerms != null) { + this.nodeSelectorTerms.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromNodeSelectorTerms(java.util.function.Predicate predicate) { + + public A removeMatchingFromNodeSelectorTerms( + java.util.function.Predicate + predicate) { if (nodeSelectorTerms == null) return (A) this; - final Iterator each = nodeSelectorTerms.iterator(); + final Iterator each = + nodeSelectorTerms.iterator(); final List visitables = _visitables.get("nodeSelectorTerms"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder = each.next(); @@ -60,104 +134,191 @@ public A removeMatchingFromNodeSelectorTerms(java.util.function.Predicate getNodeSelectorTerms() { + public java.util.List + getNodeSelectorTerms() { return nodeSelectorTerms != null ? build(nodeSelectorTerms) : null; } - public java.util.List buildNodeSelectorTerms() { + + public java.util.List + buildNodeSelectorTerms() { return nodeSelectorTerms != null ? build(nodeSelectorTerms) : null; } - public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildNodeSelectorTerm(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildNodeSelectorTerm( + java.lang.Integer index) { return this.nodeSelectorTerms.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildFirstNodeSelectorTerm() { return this.nodeSelectorTerms.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildLastNodeSelectorTerm() { return this.nodeSelectorTerms.get(nodeSelectorTerms.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildMatchingNodeSelectorTerm(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder item: nodeSelectorTerms) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildMatchingNodeSelectorTerm( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder item : nodeSelectorTerms) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingNodeSelectorTerm(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder item: nodeSelectorTerms) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingNodeSelectorTerm( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder item : nodeSelectorTerms) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withNodeSelectorTerms(java.util.List nodeSelectorTerms) { - if (this.nodeSelectorTerms != null) { _visitables.get("nodeSelectorTerms").removeAll(this.nodeSelectorTerms);} - if (nodeSelectorTerms != null) {this.nodeSelectorTerms = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NodeSelectorTerm item : nodeSelectorTerms){this.addToNodeSelectorTerms(item);}} else { this.nodeSelectorTerms = null;} return (A) this; + + public A withNodeSelectorTerms( + java.util.List nodeSelectorTerms) { + if (this.nodeSelectorTerms != null) { + _visitables.get("nodeSelectorTerms").removeAll(this.nodeSelectorTerms); + } + if (nodeSelectorTerms != null) { + this.nodeSelectorTerms = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NodeSelectorTerm item : nodeSelectorTerms) { + this.addToNodeSelectorTerms(item); + } + } else { + this.nodeSelectorTerms = null; + } + return (A) this; } - public A withNodeSelectorTerms(io.kubernetes.client.openapi.models.V1NodeSelectorTerm... nodeSelectorTerms) { - if (this.nodeSelectorTerms != null) {this.nodeSelectorTerms.clear();} - if (nodeSelectorTerms != null) {for (io.kubernetes.client.openapi.models.V1NodeSelectorTerm item :nodeSelectorTerms){ this.addToNodeSelectorTerms(item);}} return (A) this; + + public A withNodeSelectorTerms( + io.kubernetes.client.openapi.models.V1NodeSelectorTerm... nodeSelectorTerms) { + if (this.nodeSelectorTerms != null) { + this.nodeSelectorTerms.clear(); + } + if (nodeSelectorTerms != null) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorTerm item : nodeSelectorTerms) { + this.addToNodeSelectorTerms(item); + } + } + return (A) this; } + public java.lang.Boolean hasNodeSelectorTerms() { return nodeSelectorTerms != null && !nodeSelectorTerms.isEmpty(); } - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested addNewNodeSelectorTerm() { - return new io.kubernetes.client.openapi.models.V1NodeSelectorFluentImpl.NodeSelectorTermsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + addNewNodeSelectorTerm() { + return new io.kubernetes.client.openapi.models.V1NodeSelectorFluentImpl + .NodeSelectorTermsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested addNewNodeSelectorTermLike(io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { - return new io.kubernetes.client.openapi.models.V1NodeSelectorFluentImpl.NodeSelectorTermsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + addNewNodeSelectorTermLike(io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { + return new io.kubernetes.client.openapi.models.V1NodeSelectorFluentImpl + .NodeSelectorTermsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested setNewNodeSelectorTermLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { - return new io.kubernetes.client.openapi.models.V1NodeSelectorFluentImpl.NodeSelectorTermsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + setNewNodeSelectorTermLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { + return new io.kubernetes.client.openapi.models.V1NodeSelectorFluentImpl + .NodeSelectorTermsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested editNodeSelectorTerm(java.lang.Integer index) { - if (nodeSelectorTerms.size() <= index) throw new RuntimeException("Can't edit nodeSelectorTerms. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + editNodeSelectorTerm(java.lang.Integer index) { + if (nodeSelectorTerms.size() <= index) + throw new RuntimeException("Can't edit nodeSelectorTerms. Index exceeds size."); return setNewNodeSelectorTermLike(index, buildNodeSelectorTerm(index)); } - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested editFirstNodeSelectorTerm() { - if (nodeSelectorTerms.size() == 0) throw new RuntimeException("Can't edit first nodeSelectorTerms. The list is empty."); + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + editFirstNodeSelectorTerm() { + if (nodeSelectorTerms.size() == 0) + throw new RuntimeException("Can't edit first nodeSelectorTerms. The list is empty."); return setNewNodeSelectorTermLike(0, buildNodeSelectorTerm(0)); } - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested editLastNodeSelectorTerm() { + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + editLastNodeSelectorTerm() { int index = nodeSelectorTerms.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last nodeSelectorTerms. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last nodeSelectorTerms. The list is empty."); return setNewNodeSelectorTermLike(index, buildNodeSelectorTerm(index)); } - public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested editMatchingNodeSelectorTerm(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested + editMatchingNodeSelectorTerm( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested,io.kubernetes.client.fluent.Nested{ - NodeSelectorTermsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { + + public class NodeSelectorTermsNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl< + io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested> + implements io.kubernetes.client.openapi.models.V1NodeSelectorFluent.NodeSelectorTermsNested< + N>, + io.kubernetes.client.fluent.Nested { + NodeSelectorTermsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(this, item); } + NodeSelectorTermsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NodeSelectorFluentImpl.this.setToNodeSelectorTerms(index,builder.build()); + return (N) V1NodeSelectorFluentImpl.this.setToNodeSelectorTerms(index, builder.build()); } + public N endNodeSelectorTerm() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorRequirementBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorRequirementBuilder.java index 556e25b1c5..3667fe098e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorRequirementBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorRequirementBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeSelectorRequirementBuilder extends io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeSelectorRequirementBuilder + extends io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluentImpl< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement, + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> { public V1NodeSelectorRequirementBuilder() { this(false); } + public V1NodeSelectorRequirementBuilder(java.lang.Boolean validationEnabled) { this(new V1NodeSelectorRequirement(), validationEnabled); } - public V1NodeSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent fluent) { + + public V1NodeSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent fluent) { this(fluent, false); } - public V1NodeSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NodeSelectorRequirement(), validationEnabled); } - public V1NodeSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent fluent,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement instance) { + + public V1NodeSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent fluent, + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement instance) { this(fluent, instance, false); } - public V1NodeSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent fluent,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NodeSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent fluent, + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withKey(instance.getKey()); fluent.withOperator(instance.getOperator()); fluent.withValues(instance.getValues()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1NodeSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement instance) { - this(instance,false); + + public V1NodeSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement instance) { + this(instance, false); } - public V1NodeSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NodeSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withKey(instance.getKey()); this.withOperator(instance.getOperator()); this.withValues(instance.getValues()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement build() { V1NodeSelectorRequirement buildable = new V1NodeSelectorRequirement(); buildable.setKey(fluent.getKey()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement build() { buildable.setValues(fluent.getValues()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeSelectorRequirementBuilder that = (V1NodeSelectorRequirementBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorRequirementFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorRequirementFluent.java index c2fda5cc88..fc8d530171 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorRequirementFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorRequirementFluent.java @@ -1,47 +1,69 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1NodeSelectorRequirementFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NodeSelectorRequirementFluent< + A extends io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getKey(); + public A withKey(java.lang.String key); + public java.lang.Boolean hasKey(); - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original); + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement.OperatorEnum getOperator(); - public A withOperator(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement.OperatorEnum operator); + + public A withOperator( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement.OperatorEnum operator); + public java.lang.Boolean hasOperator(); - public A addToValues(java.lang.Integer index,java.lang.String item); - public A setToValues(java.lang.Integer index,java.lang.String item); + + public A addToValues(java.lang.Integer index, java.lang.String item); + + public A setToValues(java.lang.Integer index, java.lang.String item); + public A addToValues(java.lang.String... items); + public A addAllToValues(java.util.Collection items); + public A removeFromValues(java.lang.String... items); + public A removeAllFromValues(java.util.Collection items); + public java.util.List getValues(); + public java.lang.String getValue(java.lang.Integer index); + public java.lang.String getFirstValue(); + public java.lang.String getLastValue(); - public java.lang.String getMatchingValue(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingValue(java.util.function.Predicate predicate); + + public java.lang.String getMatchingValue( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingValue( + java.util.function.Predicate predicate); + public A withValues(java.util.List values); + public A withValues(java.lang.String... values); + public java.lang.Boolean hasValues(); + public A addNewValue(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorRequirementFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorRequirementFluentImpl.java index 0feaefa3e2..67c88f294b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorRequirementFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorRequirementFluentImpl.java @@ -1,124 +1,203 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1NodeSelectorRequirementFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent{ - public V1NodeSelectorRequirementFluentImpl() { - } - public V1NodeSelectorRequirementFluentImpl(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement instance) { +/** Generated */ +public class V1NodeSelectorRequirementFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent { + public V1NodeSelectorRequirementFluentImpl() {} + + public V1NodeSelectorRequirementFluentImpl( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement instance) { this.withKey(instance.getKey()); this.withOperator(instance.getOperator()); this.withValues(instance.getValues()); - } + private java.lang.String key; private io.kubernetes.client.openapi.models.V1NodeSelectorRequirement.OperatorEnum operator; private java.util.List values; + public java.lang.String getKey() { return this.key; } + public A withKey(java.lang.String key) { - this.key=key; return (A) this; + this.key = key; + return (A) this; } + public java.lang.Boolean hasKey() { return this.key != null; } - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original) { - return (A)withKey(new String(original)); + return (A) withKey(new String(original)); } + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement.OperatorEnum getOperator() { return this.operator; } - public A withOperator(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement.OperatorEnum operator) { - this.operator=operator; return (A) this; + + public A withOperator( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement.OperatorEnum operator) { + this.operator = operator; + return (A) this; } + public java.lang.Boolean hasOperator() { return this.operator != null; } - public A addToValues(java.lang.Integer index,java.lang.String item) { - if (this.values == null) {this.values = new java.util.ArrayList();} + + public A addToValues(java.lang.Integer index, java.lang.String item) { + if (this.values == null) { + this.values = new java.util.ArrayList(); + } this.values.add(index, item); - return (A)this; + return (A) this; } - public A setToValues(java.lang.Integer index,java.lang.String item) { - if (this.values == null) {this.values = new java.util.ArrayList();} - this.values.set(index, item); return (A)this; + + public A setToValues(java.lang.Integer index, java.lang.String item) { + if (this.values == null) { + this.values = new java.util.ArrayList(); + } + this.values.set(index, item); + return (A) this; } + public A addToValues(java.lang.String... items) { - if (this.values == null) {this.values = new java.util.ArrayList();} - for (java.lang.String item : items) {this.values.add(item);} return (A)this; + if (this.values == null) { + this.values = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.values.add(item); + } + return (A) this; } + public A addAllToValues(java.util.Collection items) { - if (this.values == null) {this.values = new java.util.ArrayList();} - for (java.lang.String item : items) {this.values.add(item);} return (A)this; + if (this.values == null) { + this.values = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.values.add(item); + } + return (A) this; } + public A removeFromValues(java.lang.String... items) { - for (java.lang.String item : items) {if (this.values!= null){ this.values.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.values != null) { + this.values.remove(item); + } + } + return (A) this; } + public A removeAllFromValues(java.util.Collection items) { - for (java.lang.String item : items) {if (this.values!= null){ this.values.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.values != null) { + this.values.remove(item); + } + } + return (A) this; } + public java.util.List getValues() { return this.values; } + public java.lang.String getValue(java.lang.Integer index) { return this.values.get(index); } + public java.lang.String getFirstValue() { return this.values.get(0); } + public java.lang.String getLastValue() { return this.values.get(values.size() - 1); } - public java.lang.String getMatchingValue(java.util.function.Predicate predicate) { - for (java.lang.String item: values) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingValue( + java.util.function.Predicate predicate) { + for (java.lang.String item : values) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingValue(java.util.function.Predicate predicate) { - for (java.lang.String item: values) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingValue( + java.util.function.Predicate predicate) { + for (java.lang.String item : values) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withValues(java.util.List values) { - if (values != null) {this.values = new java.util.ArrayList(); for (java.lang.String item : values){this.addToValues(item);}} else { this.values = null;} return (A) this; + if (values != null) { + this.values = new java.util.ArrayList(); + for (java.lang.String item : values) { + this.addToValues(item); + } + } else { + this.values = null; + } + return (A) this; } + public A withValues(java.lang.String... values) { - if (this.values != null) {this.values.clear();} - if (values != null) {for (java.lang.String item :values){ this.addToValues(item);}} return (A) this; + if (this.values != null) { + this.values.clear(); + } + if (values != null) { + for (java.lang.String item : values) { + this.addToValues(item); + } + } + return (A) this; } + public java.lang.Boolean hasValues() { return values != null && !values.isEmpty(); } + public A addNewValue(java.lang.String original) { - return (A)addToValues(new String(original)); + return (A) addToValues(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NodeSelectorRequirementFluentImpl that = (V1NodeSelectorRequirementFluentImpl) o; - if (key != null ? !key.equals(that.key) :that.key != null) return false; - if (operator != null ? !operator.equals(that.operator) :that.operator != null) return false; - if (values != null ? !values.equals(that.values) :that.values != null) return false; + if (key != null ? !key.equals(that.key) : that.key != null) return false; + if (operator != null ? !operator.equals(that.operator) : that.operator != null) return false; + if (values != null ? !values.equals(that.values) : that.values != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(key, operator, values, super.hashCode()); + return java.util.Objects.hash(key, operator, values, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorTermBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorTermBuilder.java index e00ac81702..cd89bbb992 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorTermBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorTermBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeSelectorTermBuilder extends io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeSelectorTermBuilder + extends io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl< + io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NodeSelectorTerm, + io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder> { public V1NodeSelectorTermBuilder() { this(false); } + public V1NodeSelectorTermBuilder(java.lang.Boolean validationEnabled) { this(new V1NodeSelectorTerm(), validationEnabled); } - public V1NodeSelectorTermBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent fluent) { + + public V1NodeSelectorTermBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent fluent) { this(fluent, false); } - public V1NodeSelectorTermBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeSelectorTermBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NodeSelectorTerm(), validationEnabled); } - public V1NodeSelectorTermBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent fluent,io.kubernetes.client.openapi.models.V1NodeSelectorTerm instance) { + + public V1NodeSelectorTermBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent fluent, + io.kubernetes.client.openapi.models.V1NodeSelectorTerm instance) { this(fluent, instance, false); } - public V1NodeSelectorTermBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent fluent,io.kubernetes.client.openapi.models.V1NodeSelectorTerm instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NodeSelectorTermBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent fluent, + io.kubernetes.client.openapi.models.V1NodeSelectorTerm instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMatchExpressions(instance.getMatchExpressions()); fluent.withMatchFields(instance.getMatchFields()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1NodeSelectorTermBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorTerm instance) { - this(instance,false); + + public V1NodeSelectorTermBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorTerm instance) { + this(instance, false); } - public V1NodeSelectorTermBuilder(io.kubernetes.client.openapi.models.V1NodeSelectorTerm instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NodeSelectorTermBuilder( + io.kubernetes.client.openapi.models.V1NodeSelectorTerm instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMatchExpressions(instance.getMatchExpressions()); this.withMatchFields(instance.getMatchFields()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NodeSelectorTerm build() { V1NodeSelectorTerm buildable = new V1NodeSelectorTerm(); buildable.setMatchExpressions(fluent.getMatchExpressions()); buildable.setMatchFields(fluent.getMatchFields()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeSelectorTermBuilder that = (V1NodeSelectorTermBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorTermFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorTermFluent.java index caf301fe7b..74ae6c8edc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorTermFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorTermFluent.java @@ -1,92 +1,209 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NodeSelectorTermFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToMatchExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); - public A setToMatchExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); - public A addToMatchExpressions(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items); - public A addAllToMatchExpressions(java.util.Collection items); - public A removeFromMatchExpressions(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items); - public A removeAllFromMatchExpressions(java.util.Collection items); - public A removeMatchingFromMatchExpressions(java.util.function.Predicate predicate); - +/** Generated */ +public interface V1NodeSelectorTermFluent< + A extends io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToMatchExpressions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); + + public A setToMatchExpressions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); + + public A addToMatchExpressions( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items); + + public A addAllToMatchExpressions( + java.util.Collection items); + + public A removeFromMatchExpressions( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items); + + public A removeAllFromMatchExpressions( + java.util.Collection items); + + public A removeMatchingFromMatchExpressions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate); + /** * This method has been deprecated, please use method buildMatchExpressions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getMatchExpressions(); - public java.util.List buildMatchExpressions(); - public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchExpression(java.lang.Integer index); + public java.util.List + getMatchExpressions(); + + public java.util.List + buildMatchExpressions(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchExpression( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildFirstMatchExpression(); + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildLastMatchExpression(); - public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchingMatchExpression(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMatchExpression(java.util.function.Predicate predicate); - public A withMatchExpressions(java.util.List matchExpressions); - public A withMatchExpressions(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... matchExpressions); + + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate); + + public java.lang.Boolean hasMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate); + + public A withMatchExpressions( + java.util.List + matchExpressions); + + public A withMatchExpressions( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... matchExpressions); + public java.lang.Boolean hasMatchExpressions(); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested addNewMatchExpression(); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested addNewMatchExpressionLike(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested setNewMatchExpressionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested editMatchExpression(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested editFirstMatchExpression(); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested editLastMatchExpression(); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested editMatchingMatchExpression(java.util.function.Predicate predicate); - public A addToMatchFields(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); - public A setToMatchFields(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + addNewMatchExpression(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + addNewMatchExpressionLike(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + setNewMatchExpressionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + editMatchExpression(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + editFirstMatchExpression(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + editLastMatchExpression(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + editMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate); + + public A addToMatchFields( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); + + public A setToMatchFields( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); + public A addToMatchFields(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items); - public A addAllToMatchFields(java.util.Collection items); - public A removeFromMatchFields(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items); - public A removeAllFromMatchFields(java.util.Collection items); - public A removeMatchingFromMatchFields(java.util.function.Predicate predicate); - + + public A addAllToMatchFields( + java.util.Collection items); + + public A removeFromMatchFields( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items); + + public A removeAllFromMatchFields( + java.util.Collection items); + + public A removeMatchingFromMatchFields( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate); + /** * This method has been deprecated, please use method buildMatchFields instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getMatchFields(); - public java.util.List buildMatchFields(); - public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchField(java.lang.Integer index); + public java.util.List + getMatchFields(); + + public java.util.List + buildMatchFields(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchField( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildFirstMatchField(); + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildLastMatchField(); - public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchingMatchField(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMatchField(java.util.function.Predicate predicate); - public A withMatchFields(java.util.List matchFields); - public A withMatchFields(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... matchFields); + + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchingMatchField( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate); + + public java.lang.Boolean hasMatchingMatchField( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate); + + public A withMatchFields( + java.util.List matchFields); + + public A withMatchFields( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... matchFields); + public java.lang.Boolean hasMatchFields(); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested addNewMatchField(); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested addNewMatchFieldLike(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested setNewMatchFieldLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested editMatchField(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested editFirstMatchField(); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested editLastMatchField(); - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested editMatchingMatchField(java.util.function.Predicate predicate); - public interface MatchExpressionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent>{ + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + addNewMatchField(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + addNewMatchFieldLike(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + setNewMatchFieldLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + editMatchField(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + editFirstMatchField(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + editLastMatchField(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + editMatchingMatchField( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate); + + public interface MatchExpressionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent< + io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested< + N>> { public N and(); + public N endMatchExpression(); - } - public interface MatchFieldsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent>{ + + public interface MatchFieldsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluent< + io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested> { public N and(); + public N endMatchField(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorTermFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorTermFluentImpl.java index 552bd68b1f..efda35fd5e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorTermFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSelectorTermFluentImpl.java @@ -1,60 +1,142 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1NodeSelectorTermFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent{ - public V1NodeSelectorTermFluentImpl() { - } - public V1NodeSelectorTermFluentImpl(io.kubernetes.client.openapi.models.V1NodeSelectorTerm instance) { +/** Generated */ +public class V1NodeSelectorTermFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent { + public V1NodeSelectorTermFluentImpl() {} + + public V1NodeSelectorTermFluentImpl( + io.kubernetes.client.openapi.models.V1NodeSelectorTerm instance) { this.withMatchExpressions(instance.getMatchExpressions()); this.withMatchFields(instance.getMatchFields()); - } - private java.util.ArrayList matchExpressions; - private java.util.ArrayList matchFields; - public A addToMatchExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { - if (this.matchExpressions == null) {this.matchExpressions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item);_visitables.get("matchExpressions").add(index >= 0 ? index : _visitables.get("matchExpressions").size(), builder);this.matchExpressions.add(index >= 0 ? index : matchExpressions.size(), builder); return (A)this; + + private java.util.ArrayList + matchExpressions; + private java.util.ArrayList + matchFields; + + public A addToMatchExpressions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { + if (this.matchExpressions == null) { + this.matchExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder>(); + } + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); + _visitables + .get("matchExpressions") + .add(index >= 0 ? index : _visitables.get("matchExpressions").size(), builder); + this.matchExpressions.add(index >= 0 ? index : matchExpressions.size(), builder); + return (A) this; } - public A setToMatchExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { - if (this.matchExpressions == null) {this.matchExpressions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); - if (index < 0 || index >= _visitables.get("matchExpressions").size()) { _visitables.get("matchExpressions").add(builder); } else { _visitables.get("matchExpressions").set(index, builder);} - if (index < 0 || index >= matchExpressions.size()) { matchExpressions.add(builder); } else { matchExpressions.set(index, builder);} - return (A)this; + + public A setToMatchExpressions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { + if (this.matchExpressions == null) { + this.matchExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder>(); + } + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); + if (index < 0 || index >= _visitables.get("matchExpressions").size()) { + _visitables.get("matchExpressions").add(builder); + } else { + _visitables.get("matchExpressions").set(index, builder); + } + if (index < 0 || index >= matchExpressions.size()) { + matchExpressions.add(builder); + } else { + matchExpressions.set(index, builder); + } + return (A) this; } - public A addToMatchExpressions(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items) { - if (this.matchExpressions == null) {this.matchExpressions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item);_visitables.get("matchExpressions").add(builder);this.matchExpressions.add(builder);} return (A)this; + + public A addToMatchExpressions( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items) { + if (this.matchExpressions == null) { + this.matchExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); + _visitables.get("matchExpressions").add(builder); + this.matchExpressions.add(builder); + } + return (A) this; } - public A addAllToMatchExpressions(java.util.Collection items) { - if (this.matchExpressions == null) {this.matchExpressions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item);_visitables.get("matchExpressions").add(builder);this.matchExpressions.add(builder);} return (A)this; + + public A addAllToMatchExpressions( + java.util.Collection items) { + if (this.matchExpressions == null) { + this.matchExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); + _visitables.get("matchExpressions").add(builder); + this.matchExpressions.add(builder); + } + return (A) this; } - public A removeFromMatchExpressions(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items) { - for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item);_visitables.get("matchExpressions").remove(builder);if (this.matchExpressions != null) {this.matchExpressions.remove(builder);}} return (A)this; + + public A removeFromMatchExpressions( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); + _visitables.get("matchExpressions").remove(builder); + if (this.matchExpressions != null) { + this.matchExpressions.remove(builder); + } + } + return (A) this; } - public A removeAllFromMatchExpressions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item);_visitables.get("matchExpressions").remove(builder);if (this.matchExpressions != null) {this.matchExpressions.remove(builder);}} return (A)this; + + public A removeAllFromMatchExpressions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); + _visitables.get("matchExpressions").remove(builder); + if (this.matchExpressions != null) { + this.matchExpressions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromMatchExpressions(java.util.function.Predicate predicate) { + + public A removeMatchingFromMatchExpressions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate) { if (matchExpressions == null) return (A) this; - final Iterator each = matchExpressions.iterator(); + final Iterator each = + matchExpressions.iterator(); final List visitables = _visitables.get("matchExpressions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = each.next(); @@ -63,104 +145,261 @@ public A removeMatchingFromMatchExpressions(java.util.function.Predicate getMatchExpressions() { + public java.util.List + getMatchExpressions() { return matchExpressions != null ? build(matchExpressions) : null; } - public java.util.List buildMatchExpressions() { + + public java.util.List + buildMatchExpressions() { return matchExpressions != null ? build(matchExpressions) : null; } - public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchExpression(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchExpression( + java.lang.Integer index) { return this.matchExpressions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildFirstMatchExpression() { return this.matchExpressions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildLastMatchExpression() { return this.matchExpressions.get(matchExpressions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchingMatchExpression(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder item: matchExpressions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder item : + matchExpressions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingMatchExpression(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder item: matchExpressions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder item : + matchExpressions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withMatchExpressions(java.util.List matchExpressions) { - if (this.matchExpressions != null) { _visitables.get("matchExpressions").removeAll(this.matchExpressions);} - if (matchExpressions != null) {this.matchExpressions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : matchExpressions){this.addToMatchExpressions(item);}} else { this.matchExpressions = null;} return (A) this; + + public A withMatchExpressions( + java.util.List + matchExpressions) { + if (this.matchExpressions != null) { + _visitables.get("matchExpressions").removeAll(this.matchExpressions); + } + if (matchExpressions != null) { + this.matchExpressions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : matchExpressions) { + this.addToMatchExpressions(item); + } + } else { + this.matchExpressions = null; + } + return (A) this; } - public A withMatchExpressions(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... matchExpressions) { - if (this.matchExpressions != null) {this.matchExpressions.clear();} - if (matchExpressions != null) {for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item :matchExpressions){ this.addToMatchExpressions(item);}} return (A) this; + + public A withMatchExpressions( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... matchExpressions) { + if (this.matchExpressions != null) { + this.matchExpressions.clear(); + } + if (matchExpressions != null) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : matchExpressions) { + this.addToMatchExpressions(item); + } + } + return (A) this; } + public java.lang.Boolean hasMatchExpressions() { return matchExpressions != null && !matchExpressions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested addNewMatchExpression() { - return new io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl.MatchExpressionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + addNewMatchExpression() { + return new io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl + .MatchExpressionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested addNewMatchExpressionLike(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { - return new io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl.MatchExpressionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + addNewMatchExpressionLike( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { + return new io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl + .MatchExpressionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested setNewMatchExpressionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { - return new io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl.MatchExpressionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + setNewMatchExpressionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { + return new io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl + .MatchExpressionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested editMatchExpression(java.lang.Integer index) { - if (matchExpressions.size() <= index) throw new RuntimeException("Can't edit matchExpressions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + editMatchExpression(java.lang.Integer index) { + if (matchExpressions.size() <= index) + throw new RuntimeException("Can't edit matchExpressions. Index exceeds size."); return setNewMatchExpressionLike(index, buildMatchExpression(index)); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested editFirstMatchExpression() { - if (matchExpressions.size() == 0) throw new RuntimeException("Can't edit first matchExpressions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + editFirstMatchExpression() { + if (matchExpressions.size() == 0) + throw new RuntimeException("Can't edit first matchExpressions. The list is empty."); return setNewMatchExpressionLike(0, buildMatchExpression(0)); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested editLastMatchExpression() { + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + editLastMatchExpression() { int index = matchExpressions.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last matchExpressions. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last matchExpressions. The list is empty."); return setNewMatchExpressionLike(index, buildMatchExpression(index)); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested editMatchingMatchExpression(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested + editMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item);_visitables.get("matchFields").add(index >= 0 ? index : _visitables.get("matchFields").size(), builder);this.matchFields.add(index >= 0 ? index : matchFields.size(), builder); return (A)this; + + public A addToMatchFields( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { + if (this.matchFields == null) { + this.matchFields = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder>(); + } + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); + _visitables + .get("matchFields") + .add(index >= 0 ? index : _visitables.get("matchFields").size(), builder); + this.matchFields.add(index >= 0 ? index : matchFields.size(), builder); + return (A) this; } - public A setToMatchFields(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { - if (this.matchFields == null) {this.matchFields = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); - if (index < 0 || index >= _visitables.get("matchFields").size()) { _visitables.get("matchFields").add(builder); } else { _visitables.get("matchFields").set(index, builder);} - if (index < 0 || index >= matchFields.size()) { matchFields.add(builder); } else { matchFields.set(index, builder);} - return (A)this; + + public A setToMatchFields( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { + if (this.matchFields == null) { + this.matchFields = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder>(); + } + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); + if (index < 0 || index >= _visitables.get("matchFields").size()) { + _visitables.get("matchFields").add(builder); + } else { + _visitables.get("matchFields").set(index, builder); + } + if (index < 0 || index >= matchFields.size()) { + matchFields.add(builder); + } else { + matchFields.set(index, builder); + } + return (A) this; } - public A addToMatchFields(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items) { - if (this.matchFields == null) {this.matchFields = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item);_visitables.get("matchFields").add(builder);this.matchFields.add(builder);} return (A)this; + + public A addToMatchFields( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items) { + if (this.matchFields == null) { + this.matchFields = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); + _visitables.get("matchFields").add(builder); + this.matchFields.add(builder); + } + return (A) this; } - public A addAllToMatchFields(java.util.Collection items) { - if (this.matchFields == null) {this.matchFields = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item);_visitables.get("matchFields").add(builder);this.matchFields.add(builder);} return (A)this; + + public A addAllToMatchFields( + java.util.Collection items) { + if (this.matchFields == null) { + this.matchFields = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); + _visitables.get("matchFields").add(builder); + this.matchFields.add(builder); + } + return (A) this; } - public A removeFromMatchFields(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items) { - for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item);_visitables.get("matchFields").remove(builder);if (this.matchFields != null) {this.matchFields.remove(builder);}} return (A)this; + + public A removeFromMatchFields( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... items) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); + _visitables.get("matchFields").remove(builder); + if (this.matchFields != null) { + this.matchFields.remove(builder); + } + } + return (A) this; } - public A removeAllFromMatchFields(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item);_visitables.get("matchFields").remove(builder);if (this.matchFields != null) {this.matchFields.remove(builder);}} return (A)this; + + public A removeAllFromMatchFields( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(item); + _visitables.get("matchFields").remove(builder); + if (this.matchFields != null) { + this.matchFields.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromMatchFields(java.util.function.Predicate predicate) { + + public A removeMatchingFromMatchFields( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate) { if (matchFields == null) return (A) this; - final Iterator each = matchFields.iterator(); + final Iterator each = + matchFields.iterator(); final List visitables = _visitables.get("matchFields"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder = each.next(); @@ -169,124 +408,227 @@ public A removeMatchingFromMatchFields(java.util.function.Predicate getMatchFields() { + public java.util.List + getMatchFields() { return matchFields != null ? build(matchFields) : null; } - public java.util.List buildMatchFields() { + + public java.util.List + buildMatchFields() { return matchFields != null ? build(matchFields) : null; } - public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchField(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchField( + java.lang.Integer index) { return this.matchFields.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildFirstMatchField() { return this.matchFields.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildLastMatchField() { return this.matchFields.get(matchFields.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchingMatchField(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder item: matchFields) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NodeSelectorRequirement buildMatchingMatchField( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder item : matchFields) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingMatchField(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder item: matchFields) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMatchField( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder item : matchFields) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withMatchFields(java.util.List matchFields) { - if (this.matchFields != null) { _visitables.get("matchFields").removeAll(this.matchFields);} - if (matchFields != null) {this.matchFields = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : matchFields){this.addToMatchFields(item);}} else { this.matchFields = null;} return (A) this; + + public A withMatchFields( + java.util.List matchFields) { + if (this.matchFields != null) { + _visitables.get("matchFields").removeAll(this.matchFields); + } + if (matchFields != null) { + this.matchFields = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : matchFields) { + this.addToMatchFields(item); + } + } else { + this.matchFields = null; + } + return (A) this; } - public A withMatchFields(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... matchFields) { - if (this.matchFields != null) {this.matchFields.clear();} - if (matchFields != null) {for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item :matchFields){ this.addToMatchFields(item);}} return (A) this; + + public A withMatchFields( + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement... matchFields) { + if (this.matchFields != null) { + this.matchFields.clear(); + } + if (matchFields != null) { + for (io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item : matchFields) { + this.addToMatchFields(item); + } + } + return (A) this; } + public java.lang.Boolean hasMatchFields() { return matchFields != null && !matchFields.isEmpty(); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested addNewMatchField() { - return new io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl.MatchFieldsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + addNewMatchField() { + return new io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl + .MatchFieldsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested addNewMatchFieldLike(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { - return new io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl.MatchFieldsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + addNewMatchFieldLike(io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { + return new io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl + .MatchFieldsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested setNewMatchFieldLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { - return new io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl.MatchFieldsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + setNewMatchFieldLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { + return new io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl + .MatchFieldsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested editMatchField(java.lang.Integer index) { - if (matchFields.size() <= index) throw new RuntimeException("Can't edit matchFields. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + editMatchField(java.lang.Integer index) { + if (matchFields.size() <= index) + throw new RuntimeException("Can't edit matchFields. Index exceeds size."); return setNewMatchFieldLike(index, buildMatchField(index)); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested editFirstMatchField() { - if (matchFields.size() == 0) throw new RuntimeException("Can't edit first matchFields. The list is empty."); + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + editFirstMatchField() { + if (matchFields.size() == 0) + throw new RuntimeException("Can't edit first matchFields. The list is empty."); return setNewMatchFieldLike(0, buildMatchField(0)); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested editLastMatchField() { + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + editLastMatchField() { int index = matchFields.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last matchFields. The list is empty."); return setNewMatchFieldLike(index, buildMatchField(index)); } - public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested editMatchingMatchField(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested + editMatchingMatchField( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested,io.kubernetes.client.fluent.Nested{ - MatchExpressionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { + + public class MatchExpressionsNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluentImpl< + io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchExpressionsNested> + implements io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent + .MatchExpressionsNested< + N>, + io.kubernetes.client.fluent.Nested { + MatchExpressionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(this, item); } + MatchExpressionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NodeSelectorTermFluentImpl.this.setToMatchExpressions(index,builder.build()); + return (N) V1NodeSelectorTermFluentImpl.this.setToMatchExpressions(index, builder.build()); } + public N endMatchExpression() { return and(); } - } - public class MatchFieldsNestedImpl extends io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested,io.kubernetes.client.fluent.Nested{ - MatchFieldsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { + + public class MatchFieldsNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeSelectorRequirementFluentImpl< + io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested> + implements io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent.MatchFieldsNested, + io.kubernetes.client.fluent.Nested { + MatchFieldsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1NodeSelectorRequirement item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(this, item); } + MatchFieldsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeSelectorRequirementBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NodeSelectorTermFluentImpl.this.setToMatchFields(index,builder.build()); + return (N) V1NodeSelectorTermFluentImpl.this.setToMatchFields(index, builder.build()); } + public N endMatchField() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSpecBuilder.java index 4cbe1c28ea..4b597068ca 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSpecBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeSpecBuilder extends io.kubernetes.client.openapi.models.V1NodeSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeSpecBuilder + extends io.kubernetes.client.openapi.models.V1NodeSpecFluentImpl< + io.kubernetes.client.openapi.models.V1NodeSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NodeSpec, + io.kubernetes.client.openapi.models.V1NodeSpecBuilder> { public V1NodeSpecBuilder() { this(false); } + public V1NodeSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1NodeSpec(), validationEnabled); } + public V1NodeSpecBuilder(io.kubernetes.client.openapi.models.V1NodeSpecFluent fluent) { this(fluent, false); } - public V1NodeSpecBuilder(io.kubernetes.client.openapi.models.V1NodeSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeSpecBuilder( + io.kubernetes.client.openapi.models.V1NodeSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NodeSpec(), validationEnabled); } - public V1NodeSpecBuilder(io.kubernetes.client.openapi.models.V1NodeSpecFluent fluent,io.kubernetes.client.openapi.models.V1NodeSpec instance) { + + public V1NodeSpecBuilder( + io.kubernetes.client.openapi.models.V1NodeSpecFluent fluent, + io.kubernetes.client.openapi.models.V1NodeSpec instance) { this(fluent, instance, false); } - public V1NodeSpecBuilder(io.kubernetes.client.openapi.models.V1NodeSpecFluent fluent,io.kubernetes.client.openapi.models.V1NodeSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NodeSpecBuilder( + io.kubernetes.client.openapi.models.V1NodeSpecFluent fluent, + io.kubernetes.client.openapi.models.V1NodeSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConfigSource(instance.getConfigSource()); fluent.withExternalID(instance.getExternalID()); @@ -35,13 +61,17 @@ public V1NodeSpecBuilder(io.kubernetes.client.openapi.models.V1NodeSpecFluent fluent.withUnschedulable(instance.getUnschedulable()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NodeSpecBuilder(io.kubernetes.client.openapi.models.V1NodeSpec instance) { - this(instance,false); + this(instance, false); } - public V1NodeSpecBuilder(io.kubernetes.client.openapi.models.V1NodeSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NodeSpecBuilder( + io.kubernetes.client.openapi.models.V1NodeSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConfigSource(instance.getConfigSource()); this.withExternalID(instance.getExternalID()); @@ -56,10 +86,12 @@ public V1NodeSpecBuilder(io.kubernetes.client.openapi.models.V1NodeSpec instance this.withUnschedulable(instance.getUnschedulable()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NodeSpec build() { V1NodeSpec buildable = new V1NodeSpec(); buildable.setConfigSource(fluent.getConfigSource()); @@ -71,18 +103,23 @@ public io.kubernetes.client.openapi.models.V1NodeSpec build() { buildable.setUnschedulable(fluent.getUnschedulable()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeSpecBuilder that = (V1NodeSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSpecFluent.java index 10ba8e882c..a900bce1e0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSpecFluent.java @@ -1,123 +1,197 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NodeSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1NodeSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildConfigSource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeConfigSource getConfigSource(); + public io.kubernetes.client.openapi.models.V1NodeConfigSource buildConfigSource(); + public A withConfigSource(io.kubernetes.client.openapi.models.V1NodeConfigSource configSource); + public java.lang.Boolean hasConfigSource(); - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested withNewConfigSource(); - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested withNewConfigSourceLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested editConfigSource(); - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested editOrNewConfigSource(); - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested editOrNewConfigSourceLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested + withNewConfigSource(); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested + withNewConfigSourceLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested + editConfigSource(); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested + editOrNewConfigSource(); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested + editOrNewConfigSourceLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item); + public java.lang.String getExternalID(); + public A withExternalID(java.lang.String externalID); + public java.lang.Boolean hasExternalID(); - - /** - * Method is deprecated. use withExternalID instead. - */ + + /** Method is deprecated. use withExternalID instead. */ @java.lang.Deprecated public A withNewExternalID(java.lang.String original); + public java.lang.String getPodCIDR(); + public A withPodCIDR(java.lang.String podCIDR); + public java.lang.Boolean hasPodCIDR(); - - /** - * Method is deprecated. use withPodCIDR instead. - */ + + /** Method is deprecated. use withPodCIDR instead. */ @java.lang.Deprecated public A withNewPodCIDR(java.lang.String original); - public A addToPodCIDRs(java.lang.Integer index,java.lang.String item); - public A setToPodCIDRs(java.lang.Integer index,java.lang.String item); + + public A addToPodCIDRs(java.lang.Integer index, java.lang.String item); + + public A setToPodCIDRs(java.lang.Integer index, java.lang.String item); + public A addToPodCIDRs(java.lang.String... items); + public A addAllToPodCIDRs(java.util.Collection items); + public A removeFromPodCIDRs(java.lang.String... items); + public A removeAllFromPodCIDRs(java.util.Collection items); + public java.util.List getPodCIDRs(); + public java.lang.String getPodCIDR(java.lang.Integer index); + public java.lang.String getFirstPodCIDR(); + public java.lang.String getLastPodCIDR(); - public java.lang.String getMatchingPodCIDR(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPodCIDR(java.util.function.Predicate predicate); + + public java.lang.String getMatchingPodCIDR( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingPodCIDR( + java.util.function.Predicate predicate); + public A withPodCIDRs(java.util.List podCIDRs); + public A withPodCIDRs(java.lang.String... podCIDRs); + public java.lang.Boolean hasPodCIDRs(); + public A addNewPodCIDR(java.lang.String original); + public java.lang.String getProviderID(); + public A withProviderID(java.lang.String providerID); + public java.lang.Boolean hasProviderID(); - - /** - * Method is deprecated. use withProviderID instead. - */ + + /** Method is deprecated. use withProviderID instead. */ @java.lang.Deprecated public A withNewProviderID(java.lang.String original); - public A addToTaints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Taint item); - public A setToTaints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Taint item); + + public A addToTaints(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Taint item); + + public A setToTaints(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Taint item); + public A addToTaints(io.kubernetes.client.openapi.models.V1Taint... items); + public A addAllToTaints(java.util.Collection items); + public A removeFromTaints(io.kubernetes.client.openapi.models.V1Taint... items); - public A removeAllFromTaints(java.util.Collection items); - public A removeMatchingFromTaints(java.util.function.Predicate predicate); - + + public A removeAllFromTaints( + java.util.Collection items); + + public A removeMatchingFromTaints( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildTaints instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getTaints(); + public java.util.List buildTaints(); + public io.kubernetes.client.openapi.models.V1Taint buildTaint(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Taint buildFirstTaint(); + public io.kubernetes.client.openapi.models.V1Taint buildLastTaint(); - public io.kubernetes.client.openapi.models.V1Taint buildMatchingTaint(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingTaint(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Taint buildMatchingTaint( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingTaint( + java.util.function.Predicate predicate); + public A withTaints(java.util.List taints); + public A withTaints(io.kubernetes.client.openapi.models.V1Taint... taints); + public java.lang.Boolean hasTaints(); + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested addNewTaint(); - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested addNewTaintLike(io.kubernetes.client.openapi.models.V1Taint item); - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested setNewTaintLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Taint item); - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested editTaint(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested addNewTaintLike( + io.kubernetes.client.openapi.models.V1Taint item); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested setNewTaintLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Taint item); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested editTaint( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested editFirstTaint(); + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested editLastTaint(); - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested editMatchingTaint(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested editMatchingTaint( + java.util.function.Predicate predicate); + public java.lang.Boolean getUnschedulable(); + public A withUnschedulable(java.lang.Boolean unschedulable); + public java.lang.Boolean hasUnschedulable(); - public interface ConfigSourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent>{ + + public interface ConfigSourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeConfigSourceFluent< + io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested> { public N and(); + public N endConfigSource(); - } - public interface TaintsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TaintFluent>{ + + public interface TaintsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TaintFluent< + io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested> { public N and(); + public N endTaint(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSpecFluentImpl.java index 67f0706c2f..1b44340072 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSpecFluentImpl.java @@ -1,25 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1NodeSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeSpecFluent{ - public V1NodeSpecFluentImpl() { - } +/** Generated */ +public class V1NodeSpecFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeSpecFluent { + public V1NodeSpecFluentImpl() {} + public V1NodeSpecFluentImpl(io.kubernetes.client.openapi.models.V1NodeSpec instance) { this.withConfigSource(instance.getConfigSource()); @@ -34,8 +35,8 @@ public V1NodeSpecFluentImpl(io.kubernetes.client.openapi.models.V1NodeSpec insta this.withTaints(instance.getTaints()); this.withUnschedulable(instance.getUnschedulable()); - } + private io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder configSource; private java.lang.String externalID; private java.lang.String podCIDR; @@ -43,171 +44,326 @@ public V1NodeSpecFluentImpl(io.kubernetes.client.openapi.models.V1NodeSpec insta private java.lang.String providerID; private java.util.ArrayList taints; private java.lang.Boolean unschedulable; - + /** * This method has been deprecated, please use method buildConfigSource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeConfigSource getConfigSource() { - return this.configSource!=null ?this.configSource.build():null; + return this.configSource != null ? this.configSource.build() : null; } + public io.kubernetes.client.openapi.models.V1NodeConfigSource buildConfigSource() { - return this.configSource!=null ?this.configSource.build():null; + return this.configSource != null ? this.configSource.build() : null; } + public A withConfigSource(io.kubernetes.client.openapi.models.V1NodeConfigSource configSource) { _visitables.get("configSource").remove(this.configSource); - if (configSource!=null){ this.configSource= new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(configSource); _visitables.get("configSource").add(this.configSource);} return (A) this; + if (configSource != null) { + this.configSource = + new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(configSource); + _visitables.get("configSource").add(this.configSource); + } + return (A) this; } + public java.lang.Boolean hasConfigSource() { return this.configSource != null; } - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested withNewConfigSource() { + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested + withNewConfigSource() { return new io.kubernetes.client.openapi.models.V1NodeSpecFluentImpl.ConfigSourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested withNewConfigSourceLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { - return new io.kubernetes.client.openapi.models.V1NodeSpecFluentImpl.ConfigSourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested + withNewConfigSourceLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { + return new io.kubernetes.client.openapi.models.V1NodeSpecFluentImpl.ConfigSourceNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested editConfigSource() { + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested + editConfigSource() { return withNewConfigSourceLike(getConfigSource()); } - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested editOrNewConfigSource() { - return withNewConfigSourceLike(getConfigSource() != null ? getConfigSource(): new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested + editOrNewConfigSource() { + return withNewConfigSourceLike( + getConfigSource() != null + ? getConfigSource() + : new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested editOrNewConfigSourceLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { - return withNewConfigSourceLike(getConfigSource() != null ? getConfigSource(): item); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested + editOrNewConfigSourceLike(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { + return withNewConfigSourceLike(getConfigSource() != null ? getConfigSource() : item); } + public java.lang.String getExternalID() { return this.externalID; } + public A withExternalID(java.lang.String externalID) { - this.externalID=externalID; return (A) this; + this.externalID = externalID; + return (A) this; } + public java.lang.Boolean hasExternalID() { return this.externalID != null; } - - /** - * Method is deprecated. use withExternalID instead. - */ + + /** Method is deprecated. use withExternalID instead. */ @java.lang.Deprecated public A withNewExternalID(java.lang.String original) { - return (A)withExternalID(new String(original)); + return (A) withExternalID(new String(original)); } + public java.lang.String getPodCIDR() { return this.podCIDR; } + public A withPodCIDR(java.lang.String podCIDR) { - this.podCIDR=podCIDR; return (A) this; + this.podCIDR = podCIDR; + return (A) this; } + public java.lang.Boolean hasPodCIDR() { return this.podCIDR != null; } - - /** - * Method is deprecated. use withPodCIDR instead. - */ + + /** Method is deprecated. use withPodCIDR instead. */ @java.lang.Deprecated public A withNewPodCIDR(java.lang.String original) { - return (A)withPodCIDR(new String(original)); + return (A) withPodCIDR(new String(original)); } - public A addToPodCIDRs(java.lang.Integer index,java.lang.String item) { - if (this.podCIDRs == null) {this.podCIDRs = new java.util.ArrayList();} + + public A addToPodCIDRs(java.lang.Integer index, java.lang.String item) { + if (this.podCIDRs == null) { + this.podCIDRs = new java.util.ArrayList(); + } this.podCIDRs.add(index, item); - return (A)this; + return (A) this; } - public A setToPodCIDRs(java.lang.Integer index,java.lang.String item) { - if (this.podCIDRs == null) {this.podCIDRs = new java.util.ArrayList();} - this.podCIDRs.set(index, item); return (A)this; + + public A setToPodCIDRs(java.lang.Integer index, java.lang.String item) { + if (this.podCIDRs == null) { + this.podCIDRs = new java.util.ArrayList(); + } + this.podCIDRs.set(index, item); + return (A) this; } + public A addToPodCIDRs(java.lang.String... items) { - if (this.podCIDRs == null) {this.podCIDRs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.podCIDRs.add(item);} return (A)this; + if (this.podCIDRs == null) { + this.podCIDRs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.podCIDRs.add(item); + } + return (A) this; } + public A addAllToPodCIDRs(java.util.Collection items) { - if (this.podCIDRs == null) {this.podCIDRs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.podCIDRs.add(item);} return (A)this; + if (this.podCIDRs == null) { + this.podCIDRs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.podCIDRs.add(item); + } + return (A) this; } + public A removeFromPodCIDRs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.podCIDRs!= null){ this.podCIDRs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.podCIDRs != null) { + this.podCIDRs.remove(item); + } + } + return (A) this; } + public A removeAllFromPodCIDRs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.podCIDRs!= null){ this.podCIDRs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.podCIDRs != null) { + this.podCIDRs.remove(item); + } + } + return (A) this; } + public java.util.List getPodCIDRs() { return this.podCIDRs; } + public java.lang.String getPodCIDR(java.lang.Integer index) { return this.podCIDRs.get(index); } + public java.lang.String getFirstPodCIDR() { return this.podCIDRs.get(0); } + public java.lang.String getLastPodCIDR() { return this.podCIDRs.get(podCIDRs.size() - 1); } - public java.lang.String getMatchingPodCIDR(java.util.function.Predicate predicate) { - for (java.lang.String item: podCIDRs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingPodCIDR( + java.util.function.Predicate predicate) { + for (java.lang.String item : podCIDRs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingPodCIDR(java.util.function.Predicate predicate) { - for (java.lang.String item: podCIDRs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPodCIDR( + java.util.function.Predicate predicate) { + for (java.lang.String item : podCIDRs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withPodCIDRs(java.util.List podCIDRs) { - if (podCIDRs != null) {this.podCIDRs = new java.util.ArrayList(); for (java.lang.String item : podCIDRs){this.addToPodCIDRs(item);}} else { this.podCIDRs = null;} return (A) this; + if (podCIDRs != null) { + this.podCIDRs = new java.util.ArrayList(); + for (java.lang.String item : podCIDRs) { + this.addToPodCIDRs(item); + } + } else { + this.podCIDRs = null; + } + return (A) this; } + public A withPodCIDRs(java.lang.String... podCIDRs) { - if (this.podCIDRs != null) {this.podCIDRs.clear();} - if (podCIDRs != null) {for (java.lang.String item :podCIDRs){ this.addToPodCIDRs(item);}} return (A) this; + if (this.podCIDRs != null) { + this.podCIDRs.clear(); + } + if (podCIDRs != null) { + for (java.lang.String item : podCIDRs) { + this.addToPodCIDRs(item); + } + } + return (A) this; } + public java.lang.Boolean hasPodCIDRs() { return podCIDRs != null && !podCIDRs.isEmpty(); } + public A addNewPodCIDR(java.lang.String original) { - return (A)addToPodCIDRs(new String(original)); + return (A) addToPodCIDRs(new String(original)); } + public java.lang.String getProviderID() { return this.providerID; } + public A withProviderID(java.lang.String providerID) { - this.providerID=providerID; return (A) this; + this.providerID = providerID; + return (A) this; } + public java.lang.Boolean hasProviderID() { return this.providerID != null; } - - /** - * Method is deprecated. use withProviderID instead. - */ + + /** Method is deprecated. use withProviderID instead. */ @java.lang.Deprecated public A withNewProviderID(java.lang.String original) { - return (A)withProviderID(new String(original)); + return (A) withProviderID(new String(original)); } - public A addToTaints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Taint item) { - if (this.taints == null) {this.taints = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TaintBuilder builder = new io.kubernetes.client.openapi.models.V1TaintBuilder(item);_visitables.get("taints").add(index >= 0 ? index : _visitables.get("taints").size(), builder);this.taints.add(index >= 0 ? index : taints.size(), builder); return (A)this; + + public A addToTaints(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Taint item) { + if (this.taints == null) { + this.taints = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1TaintBuilder builder = + new io.kubernetes.client.openapi.models.V1TaintBuilder(item); + _visitables.get("taints").add(index >= 0 ? index : _visitables.get("taints").size(), builder); + this.taints.add(index >= 0 ? index : taints.size(), builder); + return (A) this; } - public A setToTaints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Taint item) { - if (this.taints == null) {this.taints = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TaintBuilder builder = new io.kubernetes.client.openapi.models.V1TaintBuilder(item); - if (index < 0 || index >= _visitables.get("taints").size()) { _visitables.get("taints").add(builder); } else { _visitables.get("taints").set(index, builder);} - if (index < 0 || index >= taints.size()) { taints.add(builder); } else { taints.set(index, builder);} - return (A)this; + + public A setToTaints(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Taint item) { + if (this.taints == null) { + this.taints = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1TaintBuilder builder = + new io.kubernetes.client.openapi.models.V1TaintBuilder(item); + if (index < 0 || index >= _visitables.get("taints").size()) { + _visitables.get("taints").add(builder); + } else { + _visitables.get("taints").set(index, builder); + } + if (index < 0 || index >= taints.size()) { + taints.add(builder); + } else { + taints.set(index, builder); + } + return (A) this; } + public A addToTaints(io.kubernetes.client.openapi.models.V1Taint... items) { - if (this.taints == null) {this.taints = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Taint item : items) {io.kubernetes.client.openapi.models.V1TaintBuilder builder = new io.kubernetes.client.openapi.models.V1TaintBuilder(item);_visitables.get("taints").add(builder);this.taints.add(builder);} return (A)this; + if (this.taints == null) { + this.taints = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Taint item : items) { + io.kubernetes.client.openapi.models.V1TaintBuilder builder = + new io.kubernetes.client.openapi.models.V1TaintBuilder(item); + _visitables.get("taints").add(builder); + this.taints.add(builder); + } + return (A) this; } + public A addAllToTaints(java.util.Collection items) { - if (this.taints == null) {this.taints = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Taint item : items) {io.kubernetes.client.openapi.models.V1TaintBuilder builder = new io.kubernetes.client.openapi.models.V1TaintBuilder(item);_visitables.get("taints").add(builder);this.taints.add(builder);} return (A)this; + if (this.taints == null) { + this.taints = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Taint item : items) { + io.kubernetes.client.openapi.models.V1TaintBuilder builder = + new io.kubernetes.client.openapi.models.V1TaintBuilder(item); + _visitables.get("taints").add(builder); + this.taints.add(builder); + } + return (A) this; } + public A removeFromTaints(io.kubernetes.client.openapi.models.V1Taint... items) { - for (io.kubernetes.client.openapi.models.V1Taint item : items) {io.kubernetes.client.openapi.models.V1TaintBuilder builder = new io.kubernetes.client.openapi.models.V1TaintBuilder(item);_visitables.get("taints").remove(builder);if (this.taints != null) {this.taints.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Taint item : items) { + io.kubernetes.client.openapi.models.V1TaintBuilder builder = + new io.kubernetes.client.openapi.models.V1TaintBuilder(item); + _visitables.get("taints").remove(builder); + if (this.taints != null) { + this.taints.remove(builder); + } + } + return (A) this; } - public A removeAllFromTaints(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Taint item : items) {io.kubernetes.client.openapi.models.V1TaintBuilder builder = new io.kubernetes.client.openapi.models.V1TaintBuilder(item);_visitables.get("taints").remove(builder);if (this.taints != null) {this.taints.remove(builder);}} return (A)this; + + public A removeAllFromTaints( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Taint item : items) { + io.kubernetes.client.openapi.models.V1TaintBuilder builder = + new io.kubernetes.client.openapi.models.V1TaintBuilder(item); + _visitables.get("taints").remove(builder); + if (this.taints != null) { + this.taints.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromTaints(java.util.function.Predicate predicate) { + + public A removeMatchingFromTaints( + java.util.function.Predicate predicate) { if (taints == null) return (A) this; final Iterator each = taints.iterator(); final List visitables = _visitables.get("taints"); @@ -218,135 +374,225 @@ public A removeMatchingFromTaints(java.util.function.Predicate getTaints() { return taints != null ? build(taints) : null; } + public java.util.List buildTaints() { return taints != null ? build(taints) : null; } + public io.kubernetes.client.openapi.models.V1Taint buildTaint(java.lang.Integer index) { return this.taints.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Taint buildFirstTaint() { return this.taints.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Taint buildLastTaint() { return this.taints.get(taints.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Taint buildMatchingTaint(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TaintBuilder item: taints) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Taint buildMatchingTaint( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1TaintBuilder item : taints) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingTaint(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TaintBuilder item: taints) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingTaint( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1TaintBuilder item : taints) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withTaints(java.util.List taints) { - if (this.taints != null) { _visitables.get("taints").removeAll(this.taints);} - if (taints != null) {this.taints = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Taint item : taints){this.addToTaints(item);}} else { this.taints = null;} return (A) this; + if (this.taints != null) { + _visitables.get("taints").removeAll(this.taints); + } + if (taints != null) { + this.taints = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Taint item : taints) { + this.addToTaints(item); + } + } else { + this.taints = null; + } + return (A) this; } + public A withTaints(io.kubernetes.client.openapi.models.V1Taint... taints) { - if (this.taints != null) {this.taints.clear();} - if (taints != null) {for (io.kubernetes.client.openapi.models.V1Taint item :taints){ this.addToTaints(item);}} return (A) this; + if (this.taints != null) { + this.taints.clear(); + } + if (taints != null) { + for (io.kubernetes.client.openapi.models.V1Taint item : taints) { + this.addToTaints(item); + } + } + return (A) this; } + public java.lang.Boolean hasTaints() { return taints != null && !taints.isEmpty(); } + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested addNewTaint() { return new io.kubernetes.client.openapi.models.V1NodeSpecFluentImpl.TaintsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested addNewTaintLike(io.kubernetes.client.openapi.models.V1Taint item) { + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested addNewTaintLike( + io.kubernetes.client.openapi.models.V1Taint item) { return new io.kubernetes.client.openapi.models.V1NodeSpecFluentImpl.TaintsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested setNewTaintLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Taint item) { - return new io.kubernetes.client.openapi.models.V1NodeSpecFluentImpl.TaintsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested setNewTaintLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Taint item) { + return new io.kubernetes.client.openapi.models.V1NodeSpecFluentImpl.TaintsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested editTaint(java.lang.Integer index) { - if (taints.size() <= index) throw new RuntimeException("Can't edit taints. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested editTaint( + java.lang.Integer index) { + if (taints.size() <= index) + throw new RuntimeException("Can't edit taints. Index exceeds size."); return setNewTaintLike(index, buildTaint(index)); } + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested editFirstTaint() { - if (taints.size() == 0) throw new RuntimeException("Can't edit first taints. The list is empty."); + if (taints.size() == 0) + throw new RuntimeException("Can't edit first taints. The list is empty."); return setNewTaintLike(0, buildTaint(0)); } + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested editLastTaint() { int index = taints.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last taints. The list is empty."); return setNewTaintLike(index, buildTaint(index)); } - public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested editMatchingTaint(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested editMatchingTaint( + java.util.function.Predicate predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested,io.kubernetes.client.fluent.Nested{ + + public class ConfigSourceNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeConfigSourceFluentImpl< + io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested> + implements io.kubernetes.client.openapi.models.V1NodeSpecFluent.ConfigSourceNested, + io.kubernetes.client.fluent.Nested { ConfigSourceNestedImpl(io.kubernetes.client.openapi.models.V1NodeConfigSource item) { this.builder = new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(this, item); } + ConfigSourceNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeConfigSourceBuilder builder; + public N and() { return (N) V1NodeSpecFluentImpl.this.withConfigSource(builder.build()); } + public N endConfigSource() { return and(); } - } - public class TaintsNestedImpl extends io.kubernetes.client.openapi.models.V1TaintFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested,io.kubernetes.client.fluent.Nested{ - TaintsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Taint item) { + + public class TaintsNestedImpl + extends io.kubernetes.client.openapi.models.V1TaintFluentImpl< + io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested> + implements io.kubernetes.client.openapi.models.V1NodeSpecFluent.TaintsNested, + io.kubernetes.client.fluent.Nested { + TaintsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Taint item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1TaintBuilder(this, item); } + TaintsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1TaintBuilder(this); } + io.kubernetes.client.openapi.models.V1TaintBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NodeSpecFluentImpl.this.setToTaints(index,builder.build()); + return (N) V1NodeSpecFluentImpl.this.setToTaints(index, builder.build()); } + public N endTaint() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeStatusBuilder.java index 4b4348cbc3..2bd0da7d43 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeStatusBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeStatusBuilder extends io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeStatusBuilder + extends io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl< + io.kubernetes.client.openapi.models.V1NodeStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NodeStatus, + io.kubernetes.client.openapi.models.V1NodeStatusBuilder> { public V1NodeStatusBuilder() { this(false); } + public V1NodeStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1NodeStatus(), validationEnabled); } + public V1NodeStatusBuilder(io.kubernetes.client.openapi.models.V1NodeStatusFluent fluent) { this(fluent, false); } - public V1NodeStatusBuilder(io.kubernetes.client.openapi.models.V1NodeStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeStatusBuilder( + io.kubernetes.client.openapi.models.V1NodeStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NodeStatus(), validationEnabled); } - public V1NodeStatusBuilder(io.kubernetes.client.openapi.models.V1NodeStatusFluent fluent,io.kubernetes.client.openapi.models.V1NodeStatus instance) { + + public V1NodeStatusBuilder( + io.kubernetes.client.openapi.models.V1NodeStatusFluent fluent, + io.kubernetes.client.openapi.models.V1NodeStatus instance) { this(fluent, instance, false); } - public V1NodeStatusBuilder(io.kubernetes.client.openapi.models.V1NodeStatusFluent fluent,io.kubernetes.client.openapi.models.V1NodeStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NodeStatusBuilder( + io.kubernetes.client.openapi.models.V1NodeStatusFluent fluent, + io.kubernetes.client.openapi.models.V1NodeStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAddresses(instance.getAddresses()); fluent.withAllocatable(instance.getAllocatable()); @@ -43,13 +69,17 @@ public V1NodeStatusBuilder(io.kubernetes.client.openapi.models.V1NodeStatusFluen fluent.withVolumesInUse(instance.getVolumesInUse()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NodeStatusBuilder(io.kubernetes.client.openapi.models.V1NodeStatus instance) { - this(instance,false); + this(instance, false); } - public V1NodeStatusBuilder(io.kubernetes.client.openapi.models.V1NodeStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NodeStatusBuilder( + io.kubernetes.client.openapi.models.V1NodeStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAddresses(instance.getAddresses()); this.withAllocatable(instance.getAllocatable()); @@ -72,10 +102,12 @@ public V1NodeStatusBuilder(io.kubernetes.client.openapi.models.V1NodeStatus inst this.withVolumesInUse(instance.getVolumesInUse()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NodeStatus build() { V1NodeStatus buildable = new V1NodeStatus(); buildable.setAddresses(fluent.getAddresses()); @@ -91,18 +123,23 @@ public io.kubernetes.client.openapi.models.V1NodeStatus build() { buildable.setVolumesInUse(fluent.getVolumesInUse()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeStatusBuilder that = (V1NodeStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeStatusFluent.java index c0b38c6016..7e1a86bd34 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeStatusFluent.java @@ -1,258 +1,534 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.util.Collection; -import java.util.Map; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import java.util.Iterator; -import io.kubernetes.client.custom.Quantity; -import java.lang.Integer; - - /** - * Generated - */ -public interface V1NodeStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAddresses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeAddress item); - public A setToAddresses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeAddress item); +/** Generated */ +public interface V1NodeStatusFluent< + A extends io.kubernetes.client.openapi.models.V1NodeStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAddresses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeAddress item); + + public A setToAddresses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeAddress item); + public A addToAddresses(io.kubernetes.client.openapi.models.V1NodeAddress... items); - public A addAllToAddresses(java.util.Collection items); + + public A addAllToAddresses( + java.util.Collection items); + public A removeFromAddresses(io.kubernetes.client.openapi.models.V1NodeAddress... items); - public A removeAllFromAddresses(java.util.Collection items); - public A removeMatchingFromAddresses(java.util.function.Predicate predicate); - + + public A removeAllFromAddresses( + java.util.Collection items); + + public A removeMatchingFromAddresses( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildAddresses instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getAddresses(); + public java.util.List buildAddresses(); + public io.kubernetes.client.openapi.models.V1NodeAddress buildAddress(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NodeAddress buildFirstAddress(); + public io.kubernetes.client.openapi.models.V1NodeAddress buildLastAddress(); - public io.kubernetes.client.openapi.models.V1NodeAddress buildMatchingAddress(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAddress(java.util.function.Predicate predicate); - public A withAddresses(java.util.List addresses); + + public io.kubernetes.client.openapi.models.V1NodeAddress buildMatchingAddress( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingAddress( + java.util.function.Predicate + predicate); + + public A withAddresses( + java.util.List addresses); + public A withAddresses(io.kubernetes.client.openapi.models.V1NodeAddress... addresses); + public java.lang.Boolean hasAddresses(); + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested addNewAddress(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested addNewAddressLike(io.kubernetes.client.openapi.models.V1NodeAddress item); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested setNewAddressLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeAddress item); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested editAddress(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested editFirstAddress(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested editLastAddress(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested editMatchingAddress(java.util.function.Predicate predicate); - public A addToAllocatable(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToAllocatable(java.util.Map map); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested + addNewAddressLike(io.kubernetes.client.openapi.models.V1NodeAddress item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested + setNewAddressLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeAddress item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested editAddress( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested + editFirstAddress(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested + editLastAddress(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested + editMatchingAddress( + java.util.function.Predicate + predicate); + + public A addToAllocatable(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToAllocatable( + java.util.Map map); + public A removeFromAllocatable(java.lang.String key); - public A removeFromAllocatable(java.util.Map map); - public java.util.Map getAllocatable(); - public A withAllocatable(java.util.Map allocatable); + + public A removeFromAllocatable( + java.util.Map map); + + public java.util.Map getAllocatable(); + + public A withAllocatable( + java.util.Map allocatable); + public java.lang.Boolean hasAllocatable(); - public A addToCapacity(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToCapacity(java.util.Map map); + + public A addToCapacity(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToCapacity(java.util.Map map); + public A removeFromCapacity(java.lang.String key); - public A removeFromCapacity(java.util.Map map); - public java.util.Map getCapacity(); - public A withCapacity(java.util.Map capacity); + + public A removeFromCapacity( + java.util.Map map); + + public java.util.Map getCapacity(); + + public A withCapacity( + java.util.Map capacity); + public java.lang.Boolean hasCapacity(); - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeCondition item); + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeCondition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeCondition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1NodeCondition... items); - public A addAllToConditions(java.util.Collection items); + + public A addAllToConditions( + java.util.Collection items); + public A removeFromConditions(io.kubernetes.client.openapi.models.V1NodeCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getConditions(); + public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1NodeCondition buildCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NodeCondition buildCondition( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NodeCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1NodeCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1NodeCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); + + public io.kubernetes.client.openapi.models.V1NodeCondition buildMatchingCondition( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate); + + public A withConditions( + java.util.List conditions); + public A withConditions(io.kubernetes.client.openapi.models.V1NodeCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1NodeCondition item); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeCondition item); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1NodeCondition item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeCondition item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested editCondition( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildConfig instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeConfigStatus getConfig(); + public io.kubernetes.client.openapi.models.V1NodeConfigStatus buildConfig(); + public A withConfig(io.kubernetes.client.openapi.models.V1NodeConfigStatus config); + public java.lang.Boolean hasConfig(); + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested withNewConfig(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested withNewConfigLike(io.kubernetes.client.openapi.models.V1NodeConfigStatus item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested withNewConfigLike( + io.kubernetes.client.openapi.models.V1NodeConfigStatus item); + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested editConfig(); + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested editOrNewConfig(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested editOrNewConfigLike(io.kubernetes.client.openapi.models.V1NodeConfigStatus item); - + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested editOrNewConfigLike( + io.kubernetes.client.openapi.models.V1NodeConfigStatus item); + /** * This method has been deprecated, please use method buildDaemonEndpoints instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints getDaemonEndpoints(); + public io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints buildDaemonEndpoints(); - public A withDaemonEndpoints(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints daemonEndpoints); + + public A withDaemonEndpoints( + io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints daemonEndpoints); + public java.lang.Boolean hasDaemonEndpoints(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested withNewDaemonEndpoints(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested withNewDaemonEndpointsLike(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints item); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested editDaemonEndpoints(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested editOrNewDaemonEndpoints(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested editOrNewDaemonEndpointsLike(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints item); - public A addToImages(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerImage item); - public A setToImages(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerImage item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested + withNewDaemonEndpoints(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested + withNewDaemonEndpointsLike(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested + editDaemonEndpoints(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested + editOrNewDaemonEndpoints(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested + editOrNewDaemonEndpointsLike(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints item); + + public A addToImages( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerImage item); + + public A setToImages( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerImage item); + public A addToImages(io.kubernetes.client.openapi.models.V1ContainerImage... items); - public A addAllToImages(java.util.Collection items); + + public A addAllToImages( + java.util.Collection items); + public A removeFromImages(io.kubernetes.client.openapi.models.V1ContainerImage... items); - public A removeAllFromImages(java.util.Collection items); - public A removeMatchingFromImages(java.util.function.Predicate predicate); - + + public A removeAllFromImages( + java.util.Collection items); + + public A removeMatchingFromImages( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildImages instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getImages(); + public java.util.List buildImages(); + public io.kubernetes.client.openapi.models.V1ContainerImage buildImage(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ContainerImage buildFirstImage(); + public io.kubernetes.client.openapi.models.V1ContainerImage buildLastImage(); - public io.kubernetes.client.openapi.models.V1ContainerImage buildMatchingImage(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingImage(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ContainerImage buildMatchingImage( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingImage( + java.util.function.Predicate + predicate); + public A withImages(java.util.List images); + public A withImages(io.kubernetes.client.openapi.models.V1ContainerImage... images); + public java.lang.Boolean hasImages(); + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested addNewImage(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested addNewImageLike(io.kubernetes.client.openapi.models.V1ContainerImage item); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested setNewImageLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerImage item); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested editImage(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested addNewImageLike( + io.kubernetes.client.openapi.models.V1ContainerImage item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested setNewImageLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerImage item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested editImage( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested editFirstImage(); + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested editLastImage(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested editMatchingImage(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested editMatchingImage( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildNodeInfo instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeSystemInfo getNodeInfo(); + public io.kubernetes.client.openapi.models.V1NodeSystemInfo buildNodeInfo(); + public A withNodeInfo(io.kubernetes.client.openapi.models.V1NodeSystemInfo nodeInfo); + public java.lang.Boolean hasNodeInfo(); + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested withNewNodeInfo(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested withNewNodeInfoLike(io.kubernetes.client.openapi.models.V1NodeSystemInfo item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested + withNewNodeInfoLike(io.kubernetes.client.openapi.models.V1NodeSystemInfo item); + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested editNodeInfo(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested editOrNewNodeInfo(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested editOrNewNodeInfoLike(io.kubernetes.client.openapi.models.V1NodeSystemInfo item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested + editOrNewNodeInfo(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested + editOrNewNodeInfoLike(io.kubernetes.client.openapi.models.V1NodeSystemInfo item); + public io.kubernetes.client.openapi.models.V1NodeStatus.PhaseEnum getPhase(); + public A withPhase(io.kubernetes.client.openapi.models.V1NodeStatus.PhaseEnum phase); + public java.lang.Boolean hasPhase(); - public A addToVolumesAttached(java.lang.Integer index,io.kubernetes.client.openapi.models.V1AttachedVolume item); - public A setToVolumesAttached(java.lang.Integer index,io.kubernetes.client.openapi.models.V1AttachedVolume item); + + public A addToVolumesAttached( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1AttachedVolume item); + + public A setToVolumesAttached( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1AttachedVolume item); + public A addToVolumesAttached(io.kubernetes.client.openapi.models.V1AttachedVolume... items); - public A addAllToVolumesAttached(java.util.Collection items); + + public A addAllToVolumesAttached( + java.util.Collection items); + public A removeFromVolumesAttached(io.kubernetes.client.openapi.models.V1AttachedVolume... items); - public A removeAllFromVolumesAttached(java.util.Collection items); - public A removeMatchingFromVolumesAttached(java.util.function.Predicate predicate); - + + public A removeAllFromVolumesAttached( + java.util.Collection items); + + public A removeMatchingFromVolumesAttached( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildVolumesAttached instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getVolumesAttached(); - public java.util.List buildVolumesAttached(); - public io.kubernetes.client.openapi.models.V1AttachedVolume buildVolumesAttached(java.lang.Integer index); + + public java.util.List + buildVolumesAttached(); + + public io.kubernetes.client.openapi.models.V1AttachedVolume buildVolumesAttached( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1AttachedVolume buildFirstVolumesAttached(); + public io.kubernetes.client.openapi.models.V1AttachedVolume buildLastVolumesAttached(); - public io.kubernetes.client.openapi.models.V1AttachedVolume buildMatchingVolumesAttached(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVolumesAttached(java.util.function.Predicate predicate); - public A withVolumesAttached(java.util.List volumesAttached); - public A withVolumesAttached(io.kubernetes.client.openapi.models.V1AttachedVolume... volumesAttached); + + public io.kubernetes.client.openapi.models.V1AttachedVolume buildMatchingVolumesAttached( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingVolumesAttached( + java.util.function.Predicate + predicate); + + public A withVolumesAttached( + java.util.List volumesAttached); + + public A withVolumesAttached( + io.kubernetes.client.openapi.models.V1AttachedVolume... volumesAttached); + public java.lang.Boolean hasVolumesAttached(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested addNewVolumesAttached(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested addNewVolumesAttachedLike(io.kubernetes.client.openapi.models.V1AttachedVolume item); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested setNewVolumesAttachedLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1AttachedVolume item); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested editVolumesAttached(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested editFirstVolumesAttached(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested editLastVolumesAttached(); - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested editMatchingVolumesAttached(java.util.function.Predicate predicate); - public A addToVolumesInUse(java.lang.Integer index,java.lang.String item); - public A setToVolumesInUse(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + addNewVolumesAttached(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + addNewVolumesAttachedLike(io.kubernetes.client.openapi.models.V1AttachedVolume item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + setNewVolumesAttachedLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1AttachedVolume item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + editVolumesAttached(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + editFirstVolumesAttached(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + editLastVolumesAttached(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + editMatchingVolumesAttached( + java.util.function.Predicate + predicate); + + public A addToVolumesInUse(java.lang.Integer index, java.lang.String item); + + public A setToVolumesInUse(java.lang.Integer index, java.lang.String item); + public A addToVolumesInUse(java.lang.String... items); + public A addAllToVolumesInUse(java.util.Collection items); + public A removeFromVolumesInUse(java.lang.String... items); + public A removeAllFromVolumesInUse(java.util.Collection items); + public java.util.List getVolumesInUse(); + public java.lang.String getVolumesInUse(java.lang.Integer index); + public java.lang.String getFirstVolumesInUse(); + public java.lang.String getLastVolumesInUse(); - public java.lang.String getMatchingVolumesInUse(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVolumesInUse(java.util.function.Predicate predicate); + + public java.lang.String getMatchingVolumesInUse( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingVolumesInUse( + java.util.function.Predicate predicate); + public A withVolumesInUse(java.util.List volumesInUse); + public A withVolumesInUse(java.lang.String... volumesInUse); + public java.lang.Boolean hasVolumesInUse(); + public A addNewVolumesInUse(java.lang.String original); - public interface AddressesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeAddressFluent>{ + + public interface AddressesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeAddressFluent< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested> { public N and(); + public N endAddress(); - } - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeConditionFluent< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested> { public N and(); + public N endCondition(); - } - public interface ConfigNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent>{ + + public interface ConfigNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeConfigStatusFluent< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested> { public N and(); + public N endConfig(); - } - public interface DaemonEndpointsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent>{ + + public interface DaemonEndpointsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluent< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested> { public N and(); + public N endDaemonEndpoints(); - } - public interface ImagesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ContainerImageFluent>{ + + public interface ImagesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ContainerImageFluent< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested> { public N and(); + public N endImage(); - } - public interface NodeInfoNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent>{ + + public interface NodeInfoNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested> { public N and(); + public N endNodeInfo(); - } - public interface VolumesAttachedNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1AttachedVolumeFluent>{ + + public interface VolumesAttachedNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1AttachedVolumeFluent< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested> { public N and(); + public N endVolumesAttached(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeStatusFluentImpl.java index c474e3b69b..8a8bac988f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeStatusFluentImpl.java @@ -1,28 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.List; -import java.lang.Boolean; -import java.util.Collection; -import java.lang.Object; -import java.util.Map; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; import java.util.Iterator; -import io.kubernetes.client.custom.Quantity; -import java.lang.Integer; +import java.util.List; + +/** Generated */ +public class V1NodeStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NodeStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeStatusFluent { + public V1NodeStatusFluentImpl() {} - /** - * Generated - */ -public class V1NodeStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeStatusFluent{ - public V1NodeStatusFluentImpl() { - } public V1NodeStatusFluentImpl(io.kubernetes.client.openapi.models.V1NodeStatus instance) { this.withAddresses(instance.getAddresses()); @@ -45,47 +44,118 @@ public V1NodeStatusFluentImpl(io.kubernetes.client.openapi.models.V1NodeStatus i this.withVolumesAttached(instance.getVolumesAttached()); this.withVolumesInUse(instance.getVolumesInUse()); - } + private java.util.ArrayList addresses; - private java.util.Map allocatable; - private java.util.Map capacity; - private java.util.ArrayList conditions; + private java.util.Map allocatable; + private java.util.Map capacity; + private java.util.ArrayList + conditions; private io.kubernetes.client.openapi.models.V1NodeConfigStatusBuilder config; private io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsBuilder daemonEndpoints; private java.util.ArrayList images; private io.kubernetes.client.openapi.models.V1NodeSystemInfoBuilder nodeInfo; private io.kubernetes.client.openapi.models.V1NodeStatus.PhaseEnum phase; - private java.util.ArrayList volumesAttached; + private java.util.ArrayList + volumesAttached; private java.util.List volumesInUse; - public A addToAddresses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeAddress item) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder = new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(item);_visitables.get("addresses").add(index >= 0 ? index : _visitables.get("addresses").size(), builder);this.addresses.add(index >= 0 ? index : addresses.size(), builder); return (A)this; + + public A addToAddresses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeAddress item) { + if (this.addresses == null) { + this.addresses = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(item); + _visitables + .get("addresses") + .add(index >= 0 ? index : _visitables.get("addresses").size(), builder); + this.addresses.add(index >= 0 ? index : addresses.size(), builder); + return (A) this; } - public A setToAddresses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeAddress item) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder = new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(item); - if (index < 0 || index >= _visitables.get("addresses").size()) { _visitables.get("addresses").add(builder); } else { _visitables.get("addresses").set(index, builder);} - if (index < 0 || index >= addresses.size()) { addresses.add(builder); } else { addresses.set(index, builder);} - return (A)this; + + public A setToAddresses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeAddress item) { + if (this.addresses == null) { + this.addresses = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(item); + if (index < 0 || index >= _visitables.get("addresses").size()) { + _visitables.get("addresses").add(builder); + } else { + _visitables.get("addresses").set(index, builder); + } + if (index < 0 || index >= addresses.size()) { + addresses.add(builder); + } else { + addresses.set(index, builder); + } + return (A) this; } + public A addToAddresses(io.kubernetes.client.openapi.models.V1NodeAddress... items) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NodeAddress item : items) {io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder = new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(item);_visitables.get("addresses").add(builder);this.addresses.add(builder);} return (A)this; + if (this.addresses == null) { + this.addresses = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NodeAddress item : items) { + io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(item); + _visitables.get("addresses").add(builder); + this.addresses.add(builder); + } + return (A) this; } - public A addAllToAddresses(java.util.Collection items) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NodeAddress item : items) {io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder = new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(item);_visitables.get("addresses").add(builder);this.addresses.add(builder);} return (A)this; + + public A addAllToAddresses( + java.util.Collection items) { + if (this.addresses == null) { + this.addresses = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NodeAddress item : items) { + io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(item); + _visitables.get("addresses").add(builder); + this.addresses.add(builder); + } + return (A) this; } + public A removeFromAddresses(io.kubernetes.client.openapi.models.V1NodeAddress... items) { - for (io.kubernetes.client.openapi.models.V1NodeAddress item : items) {io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder = new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(item);_visitables.get("addresses").remove(builder);if (this.addresses != null) {this.addresses.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1NodeAddress item : items) { + io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(item); + _visitables.get("addresses").remove(builder); + if (this.addresses != null) { + this.addresses.remove(builder); + } + } + return (A) this; } - public A removeAllFromAddresses(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NodeAddress item : items) {io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder = new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(item);_visitables.get("addresses").remove(builder);if (this.addresses != null) {this.addresses.remove(builder);}} return (A)this; + + public A removeAllFromAddresses( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NodeAddress item : items) { + io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(item); + _visitables.get("addresses").remove(builder); + if (this.addresses != null) { + this.addresses.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromAddresses(java.util.function.Predicate predicate) { + + public A removeMatchingFromAddresses( + java.util.function.Predicate + predicate) { if (addresses == null) return (A) this; - final Iterator each = addresses.iterator(); + final Iterator each = + addresses.iterator(); final List visitables = _visitables.get("addresses"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder = each.next(); @@ -94,154 +164,366 @@ public A removeMatchingFromAddresses(java.util.function.Predicate getAddresses() { return addresses != null ? build(addresses) : null; } + public java.util.List buildAddresses() { return addresses != null ? build(addresses) : null; } + public io.kubernetes.client.openapi.models.V1NodeAddress buildAddress(java.lang.Integer index) { return this.addresses.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NodeAddress buildFirstAddress() { return this.addresses.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NodeAddress buildLastAddress() { return this.addresses.get(addresses.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NodeAddress buildMatchingAddress(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NodeAddressBuilder item: addresses) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NodeAddress buildMatchingAddress( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NodeAddressBuilder item : addresses) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingAddress(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NodeAddressBuilder item: addresses) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAddress( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NodeAddressBuilder item : addresses) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withAddresses(java.util.List addresses) { - if (this.addresses != null) { _visitables.get("addresses").removeAll(this.addresses);} - if (addresses != null) {this.addresses = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NodeAddress item : addresses){this.addToAddresses(item);}} else { this.addresses = null;} return (A) this; + + public A withAddresses( + java.util.List addresses) { + if (this.addresses != null) { + _visitables.get("addresses").removeAll(this.addresses); + } + if (addresses != null) { + this.addresses = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NodeAddress item : addresses) { + this.addToAddresses(item); + } + } else { + this.addresses = null; + } + return (A) this; } + public A withAddresses(io.kubernetes.client.openapi.models.V1NodeAddress... addresses) { - if (this.addresses != null) {this.addresses.clear();} - if (addresses != null) {for (io.kubernetes.client.openapi.models.V1NodeAddress item :addresses){ this.addToAddresses(item);}} return (A) this; + if (this.addresses != null) { + this.addresses.clear(); + } + if (addresses != null) { + for (io.kubernetes.client.openapi.models.V1NodeAddress item : addresses) { + this.addToAddresses(item); + } + } + return (A) this; } + public java.lang.Boolean hasAddresses() { return addresses != null && !addresses.isEmpty(); } + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested addNewAddress() { return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.AddressesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested addNewAddressLike(io.kubernetes.client.openapi.models.V1NodeAddress item) { - return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.AddressesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested + addNewAddressLike(io.kubernetes.client.openapi.models.V1NodeAddress item) { + return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.AddressesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested setNewAddressLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeAddress item) { - return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.AddressesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested + setNewAddressLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeAddress item) { + return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.AddressesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested editAddress(java.lang.Integer index) { - if (addresses.size() <= index) throw new RuntimeException("Can't edit addresses. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested editAddress( + java.lang.Integer index) { + if (addresses.size() <= index) + throw new RuntimeException("Can't edit addresses. Index exceeds size."); return setNewAddressLike(index, buildAddress(index)); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested editFirstAddress() { - if (addresses.size() == 0) throw new RuntimeException("Can't edit first addresses. The list is empty."); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested + editFirstAddress() { + if (addresses.size() == 0) + throw new RuntimeException("Can't edit first addresses. The list is empty."); return setNewAddressLike(0, buildAddress(0)); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested editLastAddress() { + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested + editLastAddress() { int index = addresses.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last addresses. The list is empty."); return setNewAddressLike(index, buildAddress(index)); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested editMatchingAddress(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested + editMatchingAddress( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i map) { - if(this.allocatable == null && map != null) { this.allocatable = new java.util.LinkedHashMap(); } - if(map != null) { this.allocatable.putAll(map);} return (A)this; + + public A addToAllocatable( + java.util.Map map) { + if (this.allocatable == null && map != null) { + this.allocatable = new java.util.LinkedHashMap(); + } + if (map != null) { + this.allocatable.putAll(map); + } + return (A) this; } + public A removeFromAllocatable(java.lang.String key) { - if(this.allocatable == null) { return (A) this; } - if(key != null && this.allocatable != null) {this.allocatable.remove(key);} return (A)this; + if (this.allocatable == null) { + return (A) this; + } + if (key != null && this.allocatable != null) { + this.allocatable.remove(key); + } + return (A) this; } - public A removeFromAllocatable(java.util.Map map) { - if(this.allocatable == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.allocatable != null){this.allocatable.remove(key);}}} return (A)this; + + public A removeFromAllocatable( + java.util.Map map) { + if (this.allocatable == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.allocatable != null) { + this.allocatable.remove(key); + } + } + } + return (A) this; } - public java.util.Map getAllocatable() { + + public java.util.Map getAllocatable() { return this.allocatable; } - public A withAllocatable(java.util.Map allocatable) { - if (allocatable == null) { this.allocatable = null;} else {this.allocatable = new java.util.LinkedHashMap(allocatable);} return (A) this; + + public A withAllocatable( + java.util.Map allocatable) { + if (allocatable == null) { + this.allocatable = null; + } else { + this.allocatable = new java.util.LinkedHashMap(allocatable); + } + return (A) this; } + public java.lang.Boolean hasAllocatable() { return this.allocatable != null; } - public A addToCapacity(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.capacity == null && key != null && value != null) { this.capacity = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.capacity.put(key, value);} return (A)this; + + public A addToCapacity(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.capacity == null && key != null && value != null) { + this.capacity = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.capacity.put(key, value); + } + return (A) this; } - public A addToCapacity(java.util.Map map) { - if(this.capacity == null && map != null) { this.capacity = new java.util.LinkedHashMap(); } - if(map != null) { this.capacity.putAll(map);} return (A)this; + + public A addToCapacity( + java.util.Map map) { + if (this.capacity == null && map != null) { + this.capacity = new java.util.LinkedHashMap(); + } + if (map != null) { + this.capacity.putAll(map); + } + return (A) this; } + public A removeFromCapacity(java.lang.String key) { - if(this.capacity == null) { return (A) this; } - if(key != null && this.capacity != null) {this.capacity.remove(key);} return (A)this; + if (this.capacity == null) { + return (A) this; + } + if (key != null && this.capacity != null) { + this.capacity.remove(key); + } + return (A) this; } - public A removeFromCapacity(java.util.Map map) { - if(this.capacity == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.capacity != null){this.capacity.remove(key);}}} return (A)this; + + public A removeFromCapacity( + java.util.Map map) { + if (this.capacity == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.capacity != null) { + this.capacity.remove(key); + } + } + } + return (A) this; } - public java.util.Map getCapacity() { + + public java.util.Map getCapacity() { return this.capacity; } - public A withCapacity(java.util.Map capacity) { - if (capacity == null) { this.capacity = null;} else {this.capacity = new java.util.LinkedHashMap(capacity);} return (A) this; + + public A withCapacity( + java.util.Map capacity) { + if (capacity == null) { + this.capacity = null; + } else { + this.capacity = new java.util.LinkedHashMap(capacity); + } + return (A) this; } + public java.lang.Boolean hasCapacity() { return this.capacity != null; } - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder = new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder = new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } + public A addToConditions(io.kubernetes.client.openapi.models.V1NodeCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NodeCondition item : items) {io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder = new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NodeCondition item : items) { + io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NodeCondition item : items) {io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder = new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NodeCondition item : items) { + io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } + public A removeFromConditions(io.kubernetes.client.openapi.models.V1NodeCondition... items) { - for (io.kubernetes.client.openapi.models.V1NodeCondition item : items) {io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder = new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1NodeCondition item : items) { + io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NodeCondition item : items) {io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder = new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NodeCondition item : items) { + io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder = each.next(); @@ -250,172 +532,349 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { return conditions != null ? build(conditions) : null; } + public java.util.List buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1NodeCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NodeCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NodeCondition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NodeCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NodeCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NodeConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NodeCondition buildMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NodeConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NodeConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NodeConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NodeCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NodeCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } + public A withConditions(io.kubernetes.client.openapi.models.V1NodeCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1NodeCondition item :conditions){ this.addToConditions(item);}} return (A) this; + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1NodeCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested addNewCondition() { + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested + addNewCondition() { return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1NodeCondition item) { - return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1NodeCondition item) { + return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.ConditionsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeCondition item) { - return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeCondition item) { + return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.ConditionsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested editCondition( + java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewConfig() { return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.ConfigNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested withNewConfigLike(io.kubernetes.client.openapi.models.V1NodeConfigStatus item) { + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested withNewConfigLike( + io.kubernetes.client.openapi.models.V1NodeConfigStatus item) { return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.ConfigNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested editConfig() { return withNewConfigLike(getConfig()); } + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested editOrNewConfig() { - return withNewConfigLike(getConfig() != null ? getConfig(): new io.kubernetes.client.openapi.models.V1NodeConfigStatusBuilder().build()); + return withNewConfigLike( + getConfig() != null + ? getConfig() + : new io.kubernetes.client.openapi.models.V1NodeConfigStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested editOrNewConfigLike(io.kubernetes.client.openapi.models.V1NodeConfigStatus item) { - return withNewConfigLike(getConfig() != null ? getConfig(): item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested editOrNewConfigLike( + io.kubernetes.client.openapi.models.V1NodeConfigStatus item) { + return withNewConfigLike(getConfig() != null ? getConfig() : item); } - + /** * This method has been deprecated, please use method buildDaemonEndpoints instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints getDaemonEndpoints() { - return this.daemonEndpoints!=null ?this.daemonEndpoints.build():null; + return this.daemonEndpoints != null ? this.daemonEndpoints.build() : null; } + public io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints buildDaemonEndpoints() { - return this.daemonEndpoints!=null ?this.daemonEndpoints.build():null; + return this.daemonEndpoints != null ? this.daemonEndpoints.build() : null; } - public A withDaemonEndpoints(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints daemonEndpoints) { + + public A withDaemonEndpoints( + io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints daemonEndpoints) { _visitables.get("daemonEndpoints").remove(this.daemonEndpoints); - if (daemonEndpoints!=null){ this.daemonEndpoints= new io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsBuilder(daemonEndpoints); _visitables.get("daemonEndpoints").add(this.daemonEndpoints);} return (A) this; + if (daemonEndpoints != null) { + this.daemonEndpoints = + new io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsBuilder(daemonEndpoints); + _visitables.get("daemonEndpoints").add(this.daemonEndpoints); + } + return (A) this; } + public java.lang.Boolean hasDaemonEndpoints() { return this.daemonEndpoints != null; } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested withNewDaemonEndpoints() { - return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.DaemonEndpointsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested + withNewDaemonEndpoints() { + return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl + .DaemonEndpointsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested withNewDaemonEndpointsLike(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints item) { - return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.DaemonEndpointsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested + withNewDaemonEndpointsLike(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints item) { + return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.DaemonEndpointsNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested editDaemonEndpoints() { + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested + editDaemonEndpoints() { return withNewDaemonEndpointsLike(getDaemonEndpoints()); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested editOrNewDaemonEndpoints() { - return withNewDaemonEndpointsLike(getDaemonEndpoints() != null ? getDaemonEndpoints(): new io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested + editOrNewDaemonEndpoints() { + return withNewDaemonEndpointsLike( + getDaemonEndpoints() != null + ? getDaemonEndpoints() + : new io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested editOrNewDaemonEndpointsLike(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints item) { - return withNewDaemonEndpointsLike(getDaemonEndpoints() != null ? getDaemonEndpoints(): item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested + editOrNewDaemonEndpointsLike(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints item) { + return withNewDaemonEndpointsLike(getDaemonEndpoints() != null ? getDaemonEndpoints() : item); } - public A addToImages(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerImage item) { - if (this.images == null) {this.images = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(item);_visitables.get("images").add(index >= 0 ? index : _visitables.get("images").size(), builder);this.images.add(index >= 0 ? index : images.size(), builder); return (A)this; + + public A addToImages( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerImage item) { + if (this.images == null) { + this.images = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(item); + _visitables.get("images").add(index >= 0 ? index : _visitables.get("images").size(), builder); + this.images.add(index >= 0 ? index : images.size(), builder); + return (A) this; } - public A setToImages(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerImage item) { - if (this.images == null) {this.images = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(item); - if (index < 0 || index >= _visitables.get("images").size()) { _visitables.get("images").add(builder); } else { _visitables.get("images").set(index, builder);} - if (index < 0 || index >= images.size()) { images.add(builder); } else { images.set(index, builder);} - return (A)this; + + public A setToImages( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerImage item) { + if (this.images == null) { + this.images = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(item); + if (index < 0 || index >= _visitables.get("images").size()) { + _visitables.get("images").add(builder); + } else { + _visitables.get("images").set(index, builder); + } + if (index < 0 || index >= images.size()) { + images.add(builder); + } else { + images.set(index, builder); + } + return (A) this; } + public A addToImages(io.kubernetes.client.openapi.models.V1ContainerImage... items) { - if (this.images == null) {this.images = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ContainerImage item : items) {io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(item);_visitables.get("images").add(builder);this.images.add(builder);} return (A)this; + if (this.images == null) { + this.images = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ContainerImage item : items) { + io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(item); + _visitables.get("images").add(builder); + this.images.add(builder); + } + return (A) this; } - public A addAllToImages(java.util.Collection items) { - if (this.images == null) {this.images = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ContainerImage item : items) {io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(item);_visitables.get("images").add(builder);this.images.add(builder);} return (A)this; + + public A addAllToImages( + java.util.Collection items) { + if (this.images == null) { + this.images = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ContainerImage item : items) { + io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(item); + _visitables.get("images").add(builder); + this.images.add(builder); + } + return (A) this; } + public A removeFromImages(io.kubernetes.client.openapi.models.V1ContainerImage... items) { - for (io.kubernetes.client.openapi.models.V1ContainerImage item : items) {io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(item);_visitables.get("images").remove(builder);if (this.images != null) {this.images.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ContainerImage item : items) { + io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(item); + _visitables.get("images").remove(builder); + if (this.images != null) { + this.images.remove(builder); + } + } + return (A) this; } - public A removeAllFromImages(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ContainerImage item : items) {io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(item);_visitables.get("images").remove(builder);if (this.images != null) {this.images.remove(builder);}} return (A)this; + + public A removeAllFromImages( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ContainerImage item : items) { + io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(item); + _visitables.get("images").remove(builder); + if (this.images != null) { + this.images.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromImages(java.util.function.Predicate predicate) { + + public A removeMatchingFromImages( + java.util.function.Predicate + predicate) { if (images == null) return (A) this; - final Iterator each = images.iterator(); + final Iterator each = + images.iterator(); final List visitables = _visitables.get("images"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder = each.next(); @@ -424,147 +883,301 @@ public A removeMatchingFromImages(java.util.function.Predicate getImages() { return images != null ? build(images) : null; } + public java.util.List buildImages() { return images != null ? build(images) : null; } + public io.kubernetes.client.openapi.models.V1ContainerImage buildImage(java.lang.Integer index) { return this.images.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ContainerImage buildFirstImage() { return this.images.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ContainerImage buildLastImage() { return this.images.get(images.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ContainerImage buildMatchingImage(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerImageBuilder item: images) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ContainerImage buildMatchingImage( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerImageBuilder item : images) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingImage(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerImageBuilder item: images) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingImage( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerImageBuilder item : images) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withImages(java.util.List images) { - if (this.images != null) { _visitables.get("images").removeAll(this.images);} - if (images != null) {this.images = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ContainerImage item : images){this.addToImages(item);}} else { this.images = null;} return (A) this; + if (this.images != null) { + _visitables.get("images").removeAll(this.images); + } + if (images != null) { + this.images = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ContainerImage item : images) { + this.addToImages(item); + } + } else { + this.images = null; + } + return (A) this; } + public A withImages(io.kubernetes.client.openapi.models.V1ContainerImage... images) { - if (this.images != null) {this.images.clear();} - if (images != null) {for (io.kubernetes.client.openapi.models.V1ContainerImage item :images){ this.addToImages(item);}} return (A) this; + if (this.images != null) { + this.images.clear(); + } + if (images != null) { + for (io.kubernetes.client.openapi.models.V1ContainerImage item : images) { + this.addToImages(item); + } + } + return (A) this; } + public java.lang.Boolean hasImages() { return images != null && !images.isEmpty(); } + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested addNewImage() { return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.ImagesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested addNewImageLike(io.kubernetes.client.openapi.models.V1ContainerImage item) { - return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.ImagesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested addNewImageLike( + io.kubernetes.client.openapi.models.V1ContainerImage item) { + return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.ImagesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested setNewImageLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerImage item) { - return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.ImagesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested setNewImageLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerImage item) { + return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.ImagesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested editImage(java.lang.Integer index) { - if (images.size() <= index) throw new RuntimeException("Can't edit images. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested editImage( + java.lang.Integer index) { + if (images.size() <= index) + throw new RuntimeException("Can't edit images. Index exceeds size."); return setNewImageLike(index, buildImage(index)); } + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested editFirstImage() { - if (images.size() == 0) throw new RuntimeException("Can't edit first images. The list is empty."); + if (images.size() == 0) + throw new RuntimeException("Can't edit first images. The list is empty."); return setNewImageLike(0, buildImage(0)); } + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested editLastImage() { int index = images.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last images. The list is empty."); return setNewImageLike(index, buildImage(index)); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested editMatchingImage(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested editMatchingImage( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewNodeInfo() { + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested + withNewNodeInfo() { return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.NodeInfoNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested withNewNodeInfoLike(io.kubernetes.client.openapi.models.V1NodeSystemInfo item) { + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested + withNewNodeInfoLike(io.kubernetes.client.openapi.models.V1NodeSystemInfo item) { return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.NodeInfoNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested editNodeInfo() { return withNewNodeInfoLike(getNodeInfo()); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested editOrNewNodeInfo() { - return withNewNodeInfoLike(getNodeInfo() != null ? getNodeInfo(): new io.kubernetes.client.openapi.models.V1NodeSystemInfoBuilder().build()); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested + editOrNewNodeInfo() { + return withNewNodeInfoLike( + getNodeInfo() != null + ? getNodeInfo() + : new io.kubernetes.client.openapi.models.V1NodeSystemInfoBuilder().build()); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested editOrNewNodeInfoLike(io.kubernetes.client.openapi.models.V1NodeSystemInfo item) { - return withNewNodeInfoLike(getNodeInfo() != null ? getNodeInfo(): item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested + editOrNewNodeInfoLike(io.kubernetes.client.openapi.models.V1NodeSystemInfo item) { + return withNewNodeInfoLike(getNodeInfo() != null ? getNodeInfo() : item); } + public io.kubernetes.client.openapi.models.V1NodeStatus.PhaseEnum getPhase() { return this.phase; } + public A withPhase(io.kubernetes.client.openapi.models.V1NodeStatus.PhaseEnum phase) { - this.phase=phase; return (A) this; + this.phase = phase; + return (A) this; } + public java.lang.Boolean hasPhase() { return this.phase != null; } - public A addToVolumesAttached(java.lang.Integer index,io.kubernetes.client.openapi.models.V1AttachedVolume item) { - if (this.volumesAttached == null) {this.volumesAttached = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(item);_visitables.get("volumesAttached").add(index >= 0 ? index : _visitables.get("volumesAttached").size(), builder);this.volumesAttached.add(index >= 0 ? index : volumesAttached.size(), builder); return (A)this; + + public A addToVolumesAttached( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1AttachedVolume item) { + if (this.volumesAttached == null) { + this.volumesAttached = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(item); + _visitables + .get("volumesAttached") + .add(index >= 0 ? index : _visitables.get("volumesAttached").size(), builder); + this.volumesAttached.add(index >= 0 ? index : volumesAttached.size(), builder); + return (A) this; } - public A setToVolumesAttached(java.lang.Integer index,io.kubernetes.client.openapi.models.V1AttachedVolume item) { - if (this.volumesAttached == null) {this.volumesAttached = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(item); - if (index < 0 || index >= _visitables.get("volumesAttached").size()) { _visitables.get("volumesAttached").add(builder); } else { _visitables.get("volumesAttached").set(index, builder);} - if (index < 0 || index >= volumesAttached.size()) { volumesAttached.add(builder); } else { volumesAttached.set(index, builder);} - return (A)this; + + public A setToVolumesAttached( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1AttachedVolume item) { + if (this.volumesAttached == null) { + this.volumesAttached = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(item); + if (index < 0 || index >= _visitables.get("volumesAttached").size()) { + _visitables.get("volumesAttached").add(builder); + } else { + _visitables.get("volumesAttached").set(index, builder); + } + if (index < 0 || index >= volumesAttached.size()) { + volumesAttached.add(builder); + } else { + volumesAttached.set(index, builder); + } + return (A) this; } + public A addToVolumesAttached(io.kubernetes.client.openapi.models.V1AttachedVolume... items) { - if (this.volumesAttached == null) {this.volumesAttached = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1AttachedVolume item : items) {io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(item);_visitables.get("volumesAttached").add(builder);this.volumesAttached.add(builder);} return (A)this; + if (this.volumesAttached == null) { + this.volumesAttached = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1AttachedVolume item : items) { + io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(item); + _visitables.get("volumesAttached").add(builder); + this.volumesAttached.add(builder); + } + return (A) this; } - public A addAllToVolumesAttached(java.util.Collection items) { - if (this.volumesAttached == null) {this.volumesAttached = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1AttachedVolume item : items) {io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(item);_visitables.get("volumesAttached").add(builder);this.volumesAttached.add(builder);} return (A)this; + + public A addAllToVolumesAttached( + java.util.Collection items) { + if (this.volumesAttached == null) { + this.volumesAttached = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1AttachedVolume item : items) { + io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(item); + _visitables.get("volumesAttached").add(builder); + this.volumesAttached.add(builder); + } + return (A) this; } - public A removeFromVolumesAttached(io.kubernetes.client.openapi.models.V1AttachedVolume... items) { - for (io.kubernetes.client.openapi.models.V1AttachedVolume item : items) {io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(item);_visitables.get("volumesAttached").remove(builder);if (this.volumesAttached != null) {this.volumesAttached.remove(builder);}} return (A)this; + + public A removeFromVolumesAttached( + io.kubernetes.client.openapi.models.V1AttachedVolume... items) { + for (io.kubernetes.client.openapi.models.V1AttachedVolume item : items) { + io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(item); + _visitables.get("volumesAttached").remove(builder); + if (this.volumesAttached != null) { + this.volumesAttached.remove(builder); + } + } + return (A) this; } - public A removeAllFromVolumesAttached(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1AttachedVolume item : items) {io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(item);_visitables.get("volumesAttached").remove(builder);if (this.volumesAttached != null) {this.volumesAttached.remove(builder);}} return (A)this; + + public A removeAllFromVolumesAttached( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1AttachedVolume item : items) { + io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(item); + _visitables.get("volumesAttached").remove(builder); + if (this.volumesAttached != null) { + this.volumesAttached.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromVolumesAttached(java.util.function.Predicate predicate) { + + public A removeMatchingFromVolumesAttached( + java.util.function.Predicate + predicate) { if (volumesAttached == null) return (A) this; - final Iterator each = volumesAttached.iterator(); + final Iterator each = + volumesAttached.iterator(); final List visitables = _visitables.get("volumesAttached"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder = each.next(); @@ -573,273 +1186,495 @@ public A removeMatchingFromVolumesAttached(java.util.function.Predicate getVolumesAttached() { return volumesAttached != null ? build(volumesAttached) : null; } - public java.util.List buildVolumesAttached() { + + public java.util.List + buildVolumesAttached() { return volumesAttached != null ? build(volumesAttached) : null; } - public io.kubernetes.client.openapi.models.V1AttachedVolume buildVolumesAttached(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1AttachedVolume buildVolumesAttached( + java.lang.Integer index) { return this.volumesAttached.get(index).build(); } + public io.kubernetes.client.openapi.models.V1AttachedVolume buildFirstVolumesAttached() { return this.volumesAttached.get(0).build(); } + public io.kubernetes.client.openapi.models.V1AttachedVolume buildLastVolumesAttached() { return this.volumesAttached.get(volumesAttached.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1AttachedVolume buildMatchingVolumesAttached(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder item: volumesAttached) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1AttachedVolume buildMatchingVolumesAttached( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder item : volumesAttached) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingVolumesAttached(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder item: volumesAttached) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVolumesAttached( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder item : volumesAttached) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withVolumesAttached(java.util.List volumesAttached) { - if (this.volumesAttached != null) { _visitables.get("volumesAttached").removeAll(this.volumesAttached);} - if (volumesAttached != null) {this.volumesAttached = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1AttachedVolume item : volumesAttached){this.addToVolumesAttached(item);}} else { this.volumesAttached = null;} return (A) this; + + public A withVolumesAttached( + java.util.List volumesAttached) { + if (this.volumesAttached != null) { + _visitables.get("volumesAttached").removeAll(this.volumesAttached); + } + if (volumesAttached != null) { + this.volumesAttached = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1AttachedVolume item : volumesAttached) { + this.addToVolumesAttached(item); + } + } else { + this.volumesAttached = null; + } + return (A) this; } - public A withVolumesAttached(io.kubernetes.client.openapi.models.V1AttachedVolume... volumesAttached) { - if (this.volumesAttached != null) {this.volumesAttached.clear();} - if (volumesAttached != null) {for (io.kubernetes.client.openapi.models.V1AttachedVolume item :volumesAttached){ this.addToVolumesAttached(item);}} return (A) this; + + public A withVolumesAttached( + io.kubernetes.client.openapi.models.V1AttachedVolume... volumesAttached) { + if (this.volumesAttached != null) { + this.volumesAttached.clear(); + } + if (volumesAttached != null) { + for (io.kubernetes.client.openapi.models.V1AttachedVolume item : volumesAttached) { + this.addToVolumesAttached(item); + } + } + return (A) this; } + public java.lang.Boolean hasVolumesAttached() { return volumesAttached != null && !volumesAttached.isEmpty(); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested addNewVolumesAttached() { - return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.VolumesAttachedNestedImpl(); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + addNewVolumesAttached() { + return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl + .VolumesAttachedNestedImpl(); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested addNewVolumesAttachedLike(io.kubernetes.client.openapi.models.V1AttachedVolume item) { - return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.VolumesAttachedNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + addNewVolumesAttachedLike(io.kubernetes.client.openapi.models.V1AttachedVolume item) { + return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.VolumesAttachedNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested setNewVolumesAttachedLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1AttachedVolume item) { - return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.VolumesAttachedNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + setNewVolumesAttachedLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1AttachedVolume item) { + return new io.kubernetes.client.openapi.models.V1NodeStatusFluentImpl.VolumesAttachedNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested editVolumesAttached(java.lang.Integer index) { - if (volumesAttached.size() <= index) throw new RuntimeException("Can't edit volumesAttached. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + editVolumesAttached(java.lang.Integer index) { + if (volumesAttached.size() <= index) + throw new RuntimeException("Can't edit volumesAttached. Index exceeds size."); return setNewVolumesAttachedLike(index, buildVolumesAttached(index)); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested editFirstVolumesAttached() { - if (volumesAttached.size() == 0) throw new RuntimeException("Can't edit first volumesAttached. The list is empty."); + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + editFirstVolumesAttached() { + if (volumesAttached.size() == 0) + throw new RuntimeException("Can't edit first volumesAttached. The list is empty."); return setNewVolumesAttachedLike(0, buildVolumesAttached(0)); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested editLastVolumesAttached() { + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + editLastVolumesAttached() { int index = volumesAttached.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last volumesAttached. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last volumesAttached. The list is empty."); return setNewVolumesAttachedLike(index, buildVolumesAttached(index)); } - public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested editMatchingVolumesAttached(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested + editMatchingVolumesAttached( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} + + public A addToVolumesInUse(java.lang.Integer index, java.lang.String item) { + if (this.volumesInUse == null) { + this.volumesInUse = new java.util.ArrayList(); + } this.volumesInUse.add(index, item); - return (A)this; + return (A) this; } - public A setToVolumesInUse(java.lang.Integer index,java.lang.String item) { - if (this.volumesInUse == null) {this.volumesInUse = new java.util.ArrayList();} - this.volumesInUse.set(index, item); return (A)this; + + public A setToVolumesInUse(java.lang.Integer index, java.lang.String item) { + if (this.volumesInUse == null) { + this.volumesInUse = new java.util.ArrayList(); + } + this.volumesInUse.set(index, item); + return (A) this; } + public A addToVolumesInUse(java.lang.String... items) { - if (this.volumesInUse == null) {this.volumesInUse = new java.util.ArrayList();} - for (java.lang.String item : items) {this.volumesInUse.add(item);} return (A)this; + if (this.volumesInUse == null) { + this.volumesInUse = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.volumesInUse.add(item); + } + return (A) this; } + public A addAllToVolumesInUse(java.util.Collection items) { - if (this.volumesInUse == null) {this.volumesInUse = new java.util.ArrayList();} - for (java.lang.String item : items) {this.volumesInUse.add(item);} return (A)this; + if (this.volumesInUse == null) { + this.volumesInUse = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.volumesInUse.add(item); + } + return (A) this; } + public A removeFromVolumesInUse(java.lang.String... items) { - for (java.lang.String item : items) {if (this.volumesInUse!= null){ this.volumesInUse.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.volumesInUse != null) { + this.volumesInUse.remove(item); + } + } + return (A) this; } + public A removeAllFromVolumesInUse(java.util.Collection items) { - for (java.lang.String item : items) {if (this.volumesInUse!= null){ this.volumesInUse.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.volumesInUse != null) { + this.volumesInUse.remove(item); + } + } + return (A) this; } + public java.util.List getVolumesInUse() { return this.volumesInUse; } + public java.lang.String getVolumesInUse(java.lang.Integer index) { return this.volumesInUse.get(index); } + public java.lang.String getFirstVolumesInUse() { return this.volumesInUse.get(0); } + public java.lang.String getLastVolumesInUse() { return this.volumesInUse.get(volumesInUse.size() - 1); } - public java.lang.String getMatchingVolumesInUse(java.util.function.Predicate predicate) { - for (java.lang.String item: volumesInUse) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingVolumesInUse( + java.util.function.Predicate predicate) { + for (java.lang.String item : volumesInUse) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingVolumesInUse(java.util.function.Predicate predicate) { - for (java.lang.String item: volumesInUse) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVolumesInUse( + java.util.function.Predicate predicate) { + for (java.lang.String item : volumesInUse) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withVolumesInUse(java.util.List volumesInUse) { - if (volumesInUse != null) {this.volumesInUse = new java.util.ArrayList(); for (java.lang.String item : volumesInUse){this.addToVolumesInUse(item);}} else { this.volumesInUse = null;} return (A) this; + if (volumesInUse != null) { + this.volumesInUse = new java.util.ArrayList(); + for (java.lang.String item : volumesInUse) { + this.addToVolumesInUse(item); + } + } else { + this.volumesInUse = null; + } + return (A) this; } + public A withVolumesInUse(java.lang.String... volumesInUse) { - if (this.volumesInUse != null) {this.volumesInUse.clear();} - if (volumesInUse != null) {for (java.lang.String item :volumesInUse){ this.addToVolumesInUse(item);}} return (A) this; + if (this.volumesInUse != null) { + this.volumesInUse.clear(); + } + if (volumesInUse != null) { + for (java.lang.String item : volumesInUse) { + this.addToVolumesInUse(item); + } + } + return (A) this; } + public java.lang.Boolean hasVolumesInUse() { return volumesInUse != null && !volumesInUse.isEmpty(); } + public A addNewVolumesInUse(java.lang.String original) { - return (A)addToVolumesInUse(new String(original)); + return (A) addToVolumesInUse(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NodeStatusFluentImpl that = (V1NodeStatusFluentImpl) o; - if (addresses != null ? !addresses.equals(that.addresses) :that.addresses != null) return false; - if (allocatable != null ? !allocatable.equals(that.allocatable) :that.allocatable != null) return false; - if (capacity != null ? !capacity.equals(that.capacity) :that.capacity != null) return false; - if (conditions != null ? !conditions.equals(that.conditions) :that.conditions != null) return false; - if (config != null ? !config.equals(that.config) :that.config != null) return false; - if (daemonEndpoints != null ? !daemonEndpoints.equals(that.daemonEndpoints) :that.daemonEndpoints != null) return false; - if (images != null ? !images.equals(that.images) :that.images != null) return false; - if (nodeInfo != null ? !nodeInfo.equals(that.nodeInfo) :that.nodeInfo != null) return false; - if (phase != null ? !phase.equals(that.phase) :that.phase != null) return false; - if (volumesAttached != null ? !volumesAttached.equals(that.volumesAttached) :that.volumesAttached != null) return false; - if (volumesInUse != null ? !volumesInUse.equals(that.volumesInUse) :that.volumesInUse != null) return false; + if (addresses != null ? !addresses.equals(that.addresses) : that.addresses != null) + return false; + if (allocatable != null ? !allocatable.equals(that.allocatable) : that.allocatable != null) + return false; + if (capacity != null ? !capacity.equals(that.capacity) : that.capacity != null) return false; + if (conditions != null ? !conditions.equals(that.conditions) : that.conditions != null) + return false; + if (config != null ? !config.equals(that.config) : that.config != null) return false; + if (daemonEndpoints != null + ? !daemonEndpoints.equals(that.daemonEndpoints) + : that.daemonEndpoints != null) return false; + if (images != null ? !images.equals(that.images) : that.images != null) return false; + if (nodeInfo != null ? !nodeInfo.equals(that.nodeInfo) : that.nodeInfo != null) return false; + if (phase != null ? !phase.equals(that.phase) : that.phase != null) return false; + if (volumesAttached != null + ? !volumesAttached.equals(that.volumesAttached) + : that.volumesAttached != null) return false; + if (volumesInUse != null ? !volumesInUse.equals(that.volumesInUse) : that.volumesInUse != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(addresses, allocatable, capacity, conditions, config, daemonEndpoints, images, nodeInfo, phase, volumesAttached, volumesInUse, super.hashCode()); + return java.util.Objects.hash( + addresses, + allocatable, + capacity, + conditions, + config, + daemonEndpoints, + images, + nodeInfo, + phase, + volumesAttached, + volumesInUse, + super.hashCode()); } - public class AddressesNestedImpl extends io.kubernetes.client.openapi.models.V1NodeAddressFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested,io.kubernetes.client.fluent.Nested{ - AddressesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeAddress item) { + + public class AddressesNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeAddressFluentImpl< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested> + implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.AddressesNested, + io.kubernetes.client.fluent.Nested { + AddressesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeAddress item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(this, item); } + AddressesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NodeAddressBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeAddressBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NodeStatusFluentImpl.this.setToAddresses(index,builder.build()); + return (N) V1NodeStatusFluentImpl.this.setToAddresses(index, builder.build()); } + public N endAddress() { return and(); } - } - public class ConditionsNestedImpl extends io.kubernetes.client.openapi.models.V1NodeConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NodeCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeConditionFluentImpl< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConditionsNested, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NodeCondition item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NodeConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NodeStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1NodeStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - public class ConfigNestedImpl extends io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested,io.kubernetes.client.fluent.Nested{ + + public class ConfigNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeConfigStatusFluentImpl< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested> + implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.ConfigNested, + io.kubernetes.client.fluent.Nested { ConfigNestedImpl(io.kubernetes.client.openapi.models.V1NodeConfigStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1NodeConfigStatusBuilder(this, item); } + ConfigNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NodeConfigStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeConfigStatusBuilder builder; + public N and() { return (N) V1NodeStatusFluentImpl.this.withConfig(builder.build()); } + public N endConfig() { return and(); } - } - public class DaemonEndpointsNestedImpl extends io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested,io.kubernetes.client.fluent.Nested{ + + public class DaemonEndpointsNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsFluentImpl< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested> + implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.DaemonEndpointsNested, + io.kubernetes.client.fluent.Nested { DaemonEndpointsNestedImpl(io.kubernetes.client.openapi.models.V1NodeDaemonEndpoints item) { - this.builder = new io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsBuilder(this, item); } + DaemonEndpointsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeDaemonEndpointsBuilder builder; + public N and() { return (N) V1NodeStatusFluentImpl.this.withDaemonEndpoints(builder.build()); } + public N endDaemonEndpoints() { return and(); } - } - public class ImagesNestedImpl extends io.kubernetes.client.openapi.models.V1ContainerImageFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested,io.kubernetes.client.fluent.Nested{ - ImagesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerImage item) { + + public class ImagesNestedImpl + extends io.kubernetes.client.openapi.models.V1ContainerImageFluentImpl< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested> + implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.ImagesNested, + io.kubernetes.client.fluent.Nested { + ImagesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerImage item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(this, item); } + ImagesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ContainerImageBuilder(this); } + io.kubernetes.client.openapi.models.V1ContainerImageBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NodeStatusFluentImpl.this.setToImages(index,builder.build()); + return (N) V1NodeStatusFluentImpl.this.setToImages(index, builder.build()); } + public N endImage() { return and(); } - } - public class NodeInfoNestedImpl extends io.kubernetes.client.openapi.models.V1NodeSystemInfoFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested,io.kubernetes.client.fluent.Nested{ + + public class NodeInfoNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeSystemInfoFluentImpl< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested> + implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.NodeInfoNested, + io.kubernetes.client.fluent.Nested { NodeInfoNestedImpl(io.kubernetes.client.openapi.models.V1NodeSystemInfo item) { this.builder = new io.kubernetes.client.openapi.models.V1NodeSystemInfoBuilder(this, item); } + NodeInfoNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NodeSystemInfoBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeSystemInfoBuilder builder; + public N and() { return (N) V1NodeStatusFluentImpl.this.withNodeInfo(builder.build()); } + public N endNodeInfo() { return and(); } - } - public class VolumesAttachedNestedImpl extends io.kubernetes.client.openapi.models.V1AttachedVolumeFluentImpl> implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested,io.kubernetes.client.fluent.Nested{ - VolumesAttachedNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1AttachedVolume item) { + + public class VolumesAttachedNestedImpl + extends io.kubernetes.client.openapi.models.V1AttachedVolumeFluentImpl< + io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested> + implements io.kubernetes.client.openapi.models.V1NodeStatusFluent.VolumesAttachedNested, + io.kubernetes.client.fluent.Nested { + VolumesAttachedNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1AttachedVolume item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(this, item); } + VolumesAttachedNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder(this); } + io.kubernetes.client.openapi.models.V1AttachedVolumeBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1NodeStatusFluentImpl.this.setToVolumesAttached(index,builder.build()); + return (N) V1NodeStatusFluentImpl.this.setToVolumesAttached(index, builder.build()); } + public N endVolumesAttached() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSystemInfoBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSystemInfoBuilder.java index 72d9158add..d69e7f4590 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSystemInfoBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSystemInfoBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NodeSystemInfoBuilder extends io.kubernetes.client.openapi.models.V1NodeSystemInfoFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NodeSystemInfoBuilder + extends io.kubernetes.client.openapi.models.V1NodeSystemInfoFluentImpl< + io.kubernetes.client.openapi.models.V1NodeSystemInfoBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NodeSystemInfo, + io.kubernetes.client.openapi.models.V1NodeSystemInfoBuilder> { public V1NodeSystemInfoBuilder() { this(false); } + public V1NodeSystemInfoBuilder(java.lang.Boolean validationEnabled) { this(new V1NodeSystemInfo(), validationEnabled); } - public V1NodeSystemInfoBuilder(io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent fluent) { + + public V1NodeSystemInfoBuilder( + io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent fluent) { this(fluent, false); } - public V1NodeSystemInfoBuilder(io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NodeSystemInfoBuilder( + io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NodeSystemInfo(), validationEnabled); } - public V1NodeSystemInfoBuilder(io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent fluent,io.kubernetes.client.openapi.models.V1NodeSystemInfo instance) { + + public V1NodeSystemInfoBuilder( + io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent fluent, + io.kubernetes.client.openapi.models.V1NodeSystemInfo instance) { this(fluent, instance, false); } - public V1NodeSystemInfoBuilder(io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent fluent,io.kubernetes.client.openapi.models.V1NodeSystemInfo instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NodeSystemInfoBuilder( + io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent fluent, + io.kubernetes.client.openapi.models.V1NodeSystemInfo instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withArchitecture(instance.getArchitecture()); fluent.withBootID(instance.getBootID()); @@ -41,13 +68,17 @@ public V1NodeSystemInfoBuilder(io.kubernetes.client.openapi.models.V1NodeSystemI fluent.withSystemUUID(instance.getSystemUUID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NodeSystemInfoBuilder(io.kubernetes.client.openapi.models.V1NodeSystemInfo instance) { - this(instance,false); + this(instance, false); } - public V1NodeSystemInfoBuilder(io.kubernetes.client.openapi.models.V1NodeSystemInfo instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NodeSystemInfoBuilder( + io.kubernetes.client.openapi.models.V1NodeSystemInfo instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withArchitecture(instance.getArchitecture()); this.withBootID(instance.getBootID()); @@ -68,10 +99,12 @@ public V1NodeSystemInfoBuilder(io.kubernetes.client.openapi.models.V1NodeSystemI this.withSystemUUID(instance.getSystemUUID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NodeSystemInfo build() { V1NodeSystemInfo buildable = new V1NodeSystemInfo(); buildable.setArchitecture(fluent.getArchitecture()); @@ -86,18 +119,23 @@ public io.kubernetes.client.openapi.models.V1NodeSystemInfo build() { buildable.setSystemUUID(fluent.getSystemUUID()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NodeSystemInfoBuilder that = (V1NodeSystemInfoBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSystemInfoFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSystemInfoFluent.java index db0d9556c4..6d5b5929e8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSystemInfoFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSystemInfoFluent.java @@ -1,104 +1,118 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NodeSystemInfoFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NodeSystemInfoFluent< + A extends io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getArchitecture(); + public A withArchitecture(java.lang.String architecture); + public java.lang.Boolean hasArchitecture(); - - /** - * Method is deprecated. use withArchitecture instead. - */ + + /** Method is deprecated. use withArchitecture instead. */ @java.lang.Deprecated public A withNewArchitecture(java.lang.String original); + public java.lang.String getBootID(); + public A withBootID(java.lang.String bootID); + public java.lang.Boolean hasBootID(); - - /** - * Method is deprecated. use withBootID instead. - */ + + /** Method is deprecated. use withBootID instead. */ @java.lang.Deprecated public A withNewBootID(java.lang.String original); + public java.lang.String getContainerRuntimeVersion(); + public A withContainerRuntimeVersion(java.lang.String containerRuntimeVersion); + public java.lang.Boolean hasContainerRuntimeVersion(); - - /** - * Method is deprecated. use withContainerRuntimeVersion instead. - */ + + /** Method is deprecated. use withContainerRuntimeVersion instead. */ @java.lang.Deprecated public A withNewContainerRuntimeVersion(java.lang.String original); + public java.lang.String getKernelVersion(); + public A withKernelVersion(java.lang.String kernelVersion); + public java.lang.Boolean hasKernelVersion(); - - /** - * Method is deprecated. use withKernelVersion instead. - */ + + /** Method is deprecated. use withKernelVersion instead. */ @java.lang.Deprecated public A withNewKernelVersion(java.lang.String original); + public java.lang.String getKubeProxyVersion(); + public A withKubeProxyVersion(java.lang.String kubeProxyVersion); + public java.lang.Boolean hasKubeProxyVersion(); - - /** - * Method is deprecated. use withKubeProxyVersion instead. - */ + + /** Method is deprecated. use withKubeProxyVersion instead. */ @java.lang.Deprecated public A withNewKubeProxyVersion(java.lang.String original); + public java.lang.String getKubeletVersion(); + public A withKubeletVersion(java.lang.String kubeletVersion); + public java.lang.Boolean hasKubeletVersion(); - - /** - * Method is deprecated. use withKubeletVersion instead. - */ + + /** Method is deprecated. use withKubeletVersion instead. */ @java.lang.Deprecated public A withNewKubeletVersion(java.lang.String original); + public java.lang.String getMachineID(); + public A withMachineID(java.lang.String machineID); + public java.lang.Boolean hasMachineID(); - - /** - * Method is deprecated. use withMachineID instead. - */ + + /** Method is deprecated. use withMachineID instead. */ @java.lang.Deprecated public A withNewMachineID(java.lang.String original); + public java.lang.String getOperatingSystem(); + public A withOperatingSystem(java.lang.String operatingSystem); + public java.lang.Boolean hasOperatingSystem(); - - /** - * Method is deprecated. use withOperatingSystem instead. - */ + + /** Method is deprecated. use withOperatingSystem instead. */ @java.lang.Deprecated public A withNewOperatingSystem(java.lang.String original); + public java.lang.String getOsImage(); + public A withOsImage(java.lang.String osImage); + public java.lang.Boolean hasOsImage(); - - /** - * Method is deprecated. use withOsImage instead. - */ + + /** Method is deprecated. use withOsImage instead. */ @java.lang.Deprecated public A withNewOsImage(java.lang.String original); + public java.lang.String getSystemUUID(); + public A withSystemUUID(java.lang.String systemUUID); + public java.lang.Boolean hasSystemUUID(); - - /** - * Method is deprecated. use withSystemUUID instead. - */ + + /** Method is deprecated. use withSystemUUID instead. */ @java.lang.Deprecated public A withNewSystemUUID(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSystemInfoFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSystemInfoFluentImpl.java index 41a08dc12f..e3b2fc8bfd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSystemInfoFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NodeSystemInfoFluentImpl.java @@ -1,17 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1NodeSystemInfoFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent { + public V1NodeSystemInfoFluentImpl() {} - /** - * Generated - */ -public class V1NodeSystemInfoFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NodeSystemInfoFluent{ - public V1NodeSystemInfoFluentImpl() { - } public V1NodeSystemInfoFluentImpl(io.kubernetes.client.openapi.models.V1NodeSystemInfo instance) { this.withArchitecture(instance.getArchitecture()); @@ -32,8 +39,8 @@ public V1NodeSystemInfoFluentImpl(io.kubernetes.client.openapi.models.V1NodeSyst this.withOsImage(instance.getOsImage()); this.withSystemUUID(instance.getSystemUUID()); - } + private java.lang.String architecture; private java.lang.String bootID; private java.lang.String containerRuntimeVersion; @@ -44,194 +51,239 @@ public V1NodeSystemInfoFluentImpl(io.kubernetes.client.openapi.models.V1NodeSyst private java.lang.String operatingSystem; private java.lang.String osImage; private java.lang.String systemUUID; + public java.lang.String getArchitecture() { return this.architecture; } + public A withArchitecture(java.lang.String architecture) { - this.architecture=architecture; return (A) this; + this.architecture = architecture; + return (A) this; } + public java.lang.Boolean hasArchitecture() { return this.architecture != null; } - - /** - * Method is deprecated. use withArchitecture instead. - */ + + /** Method is deprecated. use withArchitecture instead. */ @java.lang.Deprecated public A withNewArchitecture(java.lang.String original) { - return (A)withArchitecture(new String(original)); + return (A) withArchitecture(new String(original)); } + public java.lang.String getBootID() { return this.bootID; } + public A withBootID(java.lang.String bootID) { - this.bootID=bootID; return (A) this; + this.bootID = bootID; + return (A) this; } + public java.lang.Boolean hasBootID() { return this.bootID != null; } - - /** - * Method is deprecated. use withBootID instead. - */ + + /** Method is deprecated. use withBootID instead. */ @java.lang.Deprecated public A withNewBootID(java.lang.String original) { - return (A)withBootID(new String(original)); + return (A) withBootID(new String(original)); } + public java.lang.String getContainerRuntimeVersion() { return this.containerRuntimeVersion; } + public A withContainerRuntimeVersion(java.lang.String containerRuntimeVersion) { - this.containerRuntimeVersion=containerRuntimeVersion; return (A) this; + this.containerRuntimeVersion = containerRuntimeVersion; + return (A) this; } + public java.lang.Boolean hasContainerRuntimeVersion() { return this.containerRuntimeVersion != null; } - - /** - * Method is deprecated. use withContainerRuntimeVersion instead. - */ + + /** Method is deprecated. use withContainerRuntimeVersion instead. */ @java.lang.Deprecated public A withNewContainerRuntimeVersion(java.lang.String original) { - return (A)withContainerRuntimeVersion(new String(original)); + return (A) withContainerRuntimeVersion(new String(original)); } + public java.lang.String getKernelVersion() { return this.kernelVersion; } + public A withKernelVersion(java.lang.String kernelVersion) { - this.kernelVersion=kernelVersion; return (A) this; + this.kernelVersion = kernelVersion; + return (A) this; } + public java.lang.Boolean hasKernelVersion() { return this.kernelVersion != null; } - - /** - * Method is deprecated. use withKernelVersion instead. - */ + + /** Method is deprecated. use withKernelVersion instead. */ @java.lang.Deprecated public A withNewKernelVersion(java.lang.String original) { - return (A)withKernelVersion(new String(original)); + return (A) withKernelVersion(new String(original)); } + public java.lang.String getKubeProxyVersion() { return this.kubeProxyVersion; } + public A withKubeProxyVersion(java.lang.String kubeProxyVersion) { - this.kubeProxyVersion=kubeProxyVersion; return (A) this; + this.kubeProxyVersion = kubeProxyVersion; + return (A) this; } + public java.lang.Boolean hasKubeProxyVersion() { return this.kubeProxyVersion != null; } - - /** - * Method is deprecated. use withKubeProxyVersion instead. - */ + + /** Method is deprecated. use withKubeProxyVersion instead. */ @java.lang.Deprecated public A withNewKubeProxyVersion(java.lang.String original) { - return (A)withKubeProxyVersion(new String(original)); + return (A) withKubeProxyVersion(new String(original)); } + public java.lang.String getKubeletVersion() { return this.kubeletVersion; } + public A withKubeletVersion(java.lang.String kubeletVersion) { - this.kubeletVersion=kubeletVersion; return (A) this; + this.kubeletVersion = kubeletVersion; + return (A) this; } + public java.lang.Boolean hasKubeletVersion() { return this.kubeletVersion != null; } - - /** - * Method is deprecated. use withKubeletVersion instead. - */ + + /** Method is deprecated. use withKubeletVersion instead. */ @java.lang.Deprecated public A withNewKubeletVersion(java.lang.String original) { - return (A)withKubeletVersion(new String(original)); + return (A) withKubeletVersion(new String(original)); } + public java.lang.String getMachineID() { return this.machineID; } + public A withMachineID(java.lang.String machineID) { - this.machineID=machineID; return (A) this; + this.machineID = machineID; + return (A) this; } + public java.lang.Boolean hasMachineID() { return this.machineID != null; } - - /** - * Method is deprecated. use withMachineID instead. - */ + + /** Method is deprecated. use withMachineID instead. */ @java.lang.Deprecated public A withNewMachineID(java.lang.String original) { - return (A)withMachineID(new String(original)); + return (A) withMachineID(new String(original)); } + public java.lang.String getOperatingSystem() { return this.operatingSystem; } + public A withOperatingSystem(java.lang.String operatingSystem) { - this.operatingSystem=operatingSystem; return (A) this; + this.operatingSystem = operatingSystem; + return (A) this; } + public java.lang.Boolean hasOperatingSystem() { return this.operatingSystem != null; } - - /** - * Method is deprecated. use withOperatingSystem instead. - */ + + /** Method is deprecated. use withOperatingSystem instead. */ @java.lang.Deprecated public A withNewOperatingSystem(java.lang.String original) { - return (A)withOperatingSystem(new String(original)); + return (A) withOperatingSystem(new String(original)); } + public java.lang.String getOsImage() { return this.osImage; } + public A withOsImage(java.lang.String osImage) { - this.osImage=osImage; return (A) this; + this.osImage = osImage; + return (A) this; } + public java.lang.Boolean hasOsImage() { return this.osImage != null; } - - /** - * Method is deprecated. use withOsImage instead. - */ + + /** Method is deprecated. use withOsImage instead. */ @java.lang.Deprecated public A withNewOsImage(java.lang.String original) { - return (A)withOsImage(new String(original)); + return (A) withOsImage(new String(original)); } + public java.lang.String getSystemUUID() { return this.systemUUID; } + public A withSystemUUID(java.lang.String systemUUID) { - this.systemUUID=systemUUID; return (A) this; + this.systemUUID = systemUUID; + return (A) this; } + public java.lang.Boolean hasSystemUUID() { return this.systemUUID != null; } - - /** - * Method is deprecated. use withSystemUUID instead. - */ + + /** Method is deprecated. use withSystemUUID instead. */ @java.lang.Deprecated public A withNewSystemUUID(java.lang.String original) { - return (A)withSystemUUID(new String(original)); + return (A) withSystemUUID(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NodeSystemInfoFluentImpl that = (V1NodeSystemInfoFluentImpl) o; - if (architecture != null ? !architecture.equals(that.architecture) :that.architecture != null) return false; - if (bootID != null ? !bootID.equals(that.bootID) :that.bootID != null) return false; - if (containerRuntimeVersion != null ? !containerRuntimeVersion.equals(that.containerRuntimeVersion) :that.containerRuntimeVersion != null) return false; - if (kernelVersion != null ? !kernelVersion.equals(that.kernelVersion) :that.kernelVersion != null) return false; - if (kubeProxyVersion != null ? !kubeProxyVersion.equals(that.kubeProxyVersion) :that.kubeProxyVersion != null) return false; - if (kubeletVersion != null ? !kubeletVersion.equals(that.kubeletVersion) :that.kubeletVersion != null) return false; - if (machineID != null ? !machineID.equals(that.machineID) :that.machineID != null) return false; - if (operatingSystem != null ? !operatingSystem.equals(that.operatingSystem) :that.operatingSystem != null) return false; - if (osImage != null ? !osImage.equals(that.osImage) :that.osImage != null) return false; - if (systemUUID != null ? !systemUUID.equals(that.systemUUID) :that.systemUUID != null) return false; + if (architecture != null ? !architecture.equals(that.architecture) : that.architecture != null) + return false; + if (bootID != null ? !bootID.equals(that.bootID) : that.bootID != null) return false; + if (containerRuntimeVersion != null + ? !containerRuntimeVersion.equals(that.containerRuntimeVersion) + : that.containerRuntimeVersion != null) return false; + if (kernelVersion != null + ? !kernelVersion.equals(that.kernelVersion) + : that.kernelVersion != null) return false; + if (kubeProxyVersion != null + ? !kubeProxyVersion.equals(that.kubeProxyVersion) + : that.kubeProxyVersion != null) return false; + if (kubeletVersion != null + ? !kubeletVersion.equals(that.kubeletVersion) + : that.kubeletVersion != null) return false; + if (machineID != null ? !machineID.equals(that.machineID) : that.machineID != null) + return false; + if (operatingSystem != null + ? !operatingSystem.equals(that.operatingSystem) + : that.operatingSystem != null) return false; + if (osImage != null ? !osImage.equals(that.osImage) : that.osImage != null) return false; + if (systemUUID != null ? !systemUUID.equals(that.systemUUID) : that.systemUUID != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(architecture, bootID, containerRuntimeVersion, kernelVersion, kubeProxyVersion, kubeletVersion, machineID, operatingSystem, osImage, systemUUID, super.hashCode()); - } - -} \ No newline at end of file + return java.util.Objects.hash( + architecture, + bootID, + containerRuntimeVersion, + kernelVersion, + kubeProxyVersion, + kubeletVersion, + machineID, + operatingSystem, + osImage, + systemUUID, + super.hashCode()); + } +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceAttributesBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceAttributesBuilder.java index 1fa92cb836..f65d6dbda8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceAttributesBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceAttributesBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NonResourceAttributesBuilder extends io.kubernetes.client.openapi.models.V1NonResourceAttributesFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NonResourceAttributesBuilder + extends io.kubernetes.client.openapi.models.V1NonResourceAttributesFluentImpl< + io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NonResourceAttributes, + io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder> { public V1NonResourceAttributesBuilder() { this(false); } + public V1NonResourceAttributesBuilder(java.lang.Boolean validationEnabled) { this(new V1NonResourceAttributes(), validationEnabled); } - public V1NonResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent fluent) { + + public V1NonResourceAttributesBuilder( + io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent fluent) { this(fluent, false); } - public V1NonResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NonResourceAttributesBuilder( + io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NonResourceAttributes(), validationEnabled); } - public V1NonResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent fluent,io.kubernetes.client.openapi.models.V1NonResourceAttributes instance) { + + public V1NonResourceAttributesBuilder( + io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent fluent, + io.kubernetes.client.openapi.models.V1NonResourceAttributes instance) { this(fluent, instance, false); } - public V1NonResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent fluent,io.kubernetes.client.openapi.models.V1NonResourceAttributes instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NonResourceAttributesBuilder( + io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent fluent, + io.kubernetes.client.openapi.models.V1NonResourceAttributes instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPath(instance.getPath()); fluent.withVerb(instance.getVerb()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1NonResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1NonResourceAttributes instance) { - this(instance,false); + + public V1NonResourceAttributesBuilder( + io.kubernetes.client.openapi.models.V1NonResourceAttributes instance) { + this(instance, false); } - public V1NonResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1NonResourceAttributes instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NonResourceAttributesBuilder( + io.kubernetes.client.openapi.models.V1NonResourceAttributes instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPath(instance.getPath()); this.withVerb(instance.getVerb()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NonResourceAttributes build() { V1NonResourceAttributes buildable = new V1NonResourceAttributes(); buildable.setPath(fluent.getPath()); buildable.setVerb(fluent.getVerb()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NonResourceAttributesBuilder that = (V1NonResourceAttributesBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceAttributesFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceAttributesFluent.java index baeaab709c..97b3dc62c1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceAttributesFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceAttributesFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1NonResourceAttributesFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1NonResourceAttributesFluent< + A extends io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); + public java.lang.String getVerb(); + public A withVerb(java.lang.String verb); + public java.lang.Boolean hasVerb(); - - /** - * Method is deprecated. use withVerb instead. - */ + + /** Method is deprecated. use withVerb instead. */ @java.lang.Deprecated public A withNewVerb(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceAttributesFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceAttributesFluentImpl.java index dfdc1831e6..a7e4513785 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceAttributesFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceAttributesFluentImpl.java @@ -1,69 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1NonResourceAttributesFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent { + public V1NonResourceAttributesFluentImpl() {} - /** - * Generated - */ -public class V1NonResourceAttributesFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent{ - public V1NonResourceAttributesFluentImpl() { - } - public V1NonResourceAttributesFluentImpl(io.kubernetes.client.openapi.models.V1NonResourceAttributes instance) { + public V1NonResourceAttributesFluentImpl( + io.kubernetes.client.openapi.models.V1NonResourceAttributes instance) { this.withPath(instance.getPath()); this.withVerb(instance.getVerb()); - } + private java.lang.String path; private java.lang.String verb; + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } + public java.lang.String getVerb() { return this.verb; } + public A withVerb(java.lang.String verb) { - this.verb=verb; return (A) this; + this.verb = verb; + return (A) this; } + public java.lang.Boolean hasVerb() { return this.verb != null; } - - /** - * Method is deprecated. use withVerb instead. - */ + + /** Method is deprecated. use withVerb instead. */ @java.lang.Deprecated public A withNewVerb(java.lang.String original) { - return (A)withVerb(new String(original)); + return (A) withVerb(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NonResourceAttributesFluentImpl that = (V1NonResourceAttributesFluentImpl) o; - if (path != null ? !path.equals(that.path) :that.path != null) return false; - if (verb != null ? !verb.equals(that.verb) :that.verb != null) return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; + if (verb != null ? !verb.equals(that.verb) : that.verb != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(path, verb, super.hashCode()); + return java.util.Objects.hash(path, verb, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceRuleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceRuleBuilder.java index 4f072091b3..28097d2de3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceRuleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceRuleBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1NonResourceRuleBuilder extends io.kubernetes.client.openapi.models.V1NonResourceRuleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1NonResourceRuleBuilder + extends io.kubernetes.client.openapi.models.V1NonResourceRuleFluentImpl< + io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1NonResourceRule, + io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder> { public V1NonResourceRuleBuilder() { this(false); } + public V1NonResourceRuleBuilder(java.lang.Boolean validationEnabled) { this(new V1NonResourceRule(), validationEnabled); } - public V1NonResourceRuleBuilder(io.kubernetes.client.openapi.models.V1NonResourceRuleFluent fluent) { + + public V1NonResourceRuleBuilder( + io.kubernetes.client.openapi.models.V1NonResourceRuleFluent fluent) { this(fluent, false); } - public V1NonResourceRuleBuilder(io.kubernetes.client.openapi.models.V1NonResourceRuleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1NonResourceRuleBuilder( + io.kubernetes.client.openapi.models.V1NonResourceRuleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1NonResourceRule(), validationEnabled); } - public V1NonResourceRuleBuilder(io.kubernetes.client.openapi.models.V1NonResourceRuleFluent fluent,io.kubernetes.client.openapi.models.V1NonResourceRule instance) { + + public V1NonResourceRuleBuilder( + io.kubernetes.client.openapi.models.V1NonResourceRuleFluent fluent, + io.kubernetes.client.openapi.models.V1NonResourceRule instance) { this(fluent, instance, false); } - public V1NonResourceRuleBuilder(io.kubernetes.client.openapi.models.V1NonResourceRuleFluent fluent,io.kubernetes.client.openapi.models.V1NonResourceRule instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1NonResourceRuleBuilder( + io.kubernetes.client.openapi.models.V1NonResourceRuleFluent fluent, + io.kubernetes.client.openapi.models.V1NonResourceRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNonResourceURLs(instance.getNonResourceURLs()); fluent.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1NonResourceRuleBuilder(io.kubernetes.client.openapi.models.V1NonResourceRule instance) { - this(instance,false); + this(instance, false); } - public V1NonResourceRuleBuilder(io.kubernetes.client.openapi.models.V1NonResourceRule instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1NonResourceRuleBuilder( + io.kubernetes.client.openapi.models.V1NonResourceRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNonResourceURLs(instance.getNonResourceURLs()); this.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1NonResourceRuleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1NonResourceRule build() { V1NonResourceRule buildable = new V1NonResourceRule(); buildable.setNonResourceURLs(fluent.getNonResourceURLs()); buildable.setVerbs(fluent.getVerbs()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1NonResourceRuleBuilder that = (V1NonResourceRuleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceRuleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceRuleFluent.java index 103d164e2a..b35bf42f07 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceRuleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceRuleFluent.java @@ -1,50 +1,85 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1NonResourceRuleFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToNonResourceURLs(java.lang.Integer index,java.lang.String item); - public A setToNonResourceURLs(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1NonResourceRuleFluent< + A extends io.kubernetes.client.openapi.models.V1NonResourceRuleFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToNonResourceURLs(java.lang.Integer index, java.lang.String item); + + public A setToNonResourceURLs(java.lang.Integer index, java.lang.String item); + public A addToNonResourceURLs(java.lang.String... items); + public A addAllToNonResourceURLs(java.util.Collection items); + public A removeFromNonResourceURLs(java.lang.String... items); + public A removeAllFromNonResourceURLs(java.util.Collection items); + public java.util.List getNonResourceURLs(); + public java.lang.String getNonResourceURL(java.lang.Integer index); + public java.lang.String getFirstNonResourceURL(); + public java.lang.String getLastNonResourceURL(); - public java.lang.String getMatchingNonResourceURL(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingNonResourceURL(java.util.function.Predicate predicate); + + public java.lang.String getMatchingNonResourceURL( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingNonResourceURL( + java.util.function.Predicate predicate); + public A withNonResourceURLs(java.util.List nonResourceURLs); + public A withNonResourceURLs(java.lang.String... nonResourceURLs); + public java.lang.Boolean hasNonResourceURLs(); + public A addNewNonResourceURL(java.lang.String original); - public A addToVerbs(java.lang.Integer index,java.lang.String item); - public A setToVerbs(java.lang.Integer index,java.lang.String item); + + public A addToVerbs(java.lang.Integer index, java.lang.String item); + + public A setToVerbs(java.lang.Integer index, java.lang.String item); + public A addToVerbs(java.lang.String... items); + public A addAllToVerbs(java.util.Collection items); + public A removeFromVerbs(java.lang.String... items); + public A removeAllFromVerbs(java.util.Collection items); + public java.util.List getVerbs(); + public java.lang.String getVerb(java.lang.Integer index); + public java.lang.String getFirstVerb(); + public java.lang.String getLastVerb(); + public java.lang.String getMatchingVerb(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate); + public A withVerbs(java.util.List verbs); + public A withVerbs(java.lang.String... verbs); + public java.lang.Boolean hasVerbs(); + public A addNewVerb(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceRuleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceRuleFluentImpl.java index 15677b9cef..f338ccce1b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceRuleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1NonResourceRuleFluentImpl.java @@ -1,147 +1,290 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.ArrayList; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public class V1NonResourceRuleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1NonResourceRuleFluent{ - public V1NonResourceRuleFluentImpl() { - } - public V1NonResourceRuleFluentImpl(io.kubernetes.client.openapi.models.V1NonResourceRule instance) { +/** Generated */ +public class V1NonResourceRuleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1NonResourceRuleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1NonResourceRuleFluent { + public V1NonResourceRuleFluentImpl() {} + + public V1NonResourceRuleFluentImpl( + io.kubernetes.client.openapi.models.V1NonResourceRule instance) { this.withNonResourceURLs(instance.getNonResourceURLs()); this.withVerbs(instance.getVerbs()); - } + private java.util.List nonResourceURLs; private java.util.List verbs; - public A addToNonResourceURLs(java.lang.Integer index,java.lang.String item) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} + + public A addToNonResourceURLs(java.lang.Integer index, java.lang.String item) { + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } this.nonResourceURLs.add(index, item); - return (A)this; + return (A) this; } - public A setToNonResourceURLs(java.lang.Integer index,java.lang.String item) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} - this.nonResourceURLs.set(index, item); return (A)this; + + public A setToNonResourceURLs(java.lang.Integer index, java.lang.String item) { + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } + this.nonResourceURLs.set(index, item); + return (A) this; } + public A addToNonResourceURLs(java.lang.String... items) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.nonResourceURLs.add(item);} return (A)this; + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.nonResourceURLs.add(item); + } + return (A) this; } + public A addAllToNonResourceURLs(java.util.Collection items) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.nonResourceURLs.add(item);} return (A)this; + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.nonResourceURLs.add(item); + } + return (A) this; } + public A removeFromNonResourceURLs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.nonResourceURLs!= null){ this.nonResourceURLs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.nonResourceURLs != null) { + this.nonResourceURLs.remove(item); + } + } + return (A) this; } + public A removeAllFromNonResourceURLs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.nonResourceURLs!= null){ this.nonResourceURLs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.nonResourceURLs != null) { + this.nonResourceURLs.remove(item); + } + } + return (A) this; } + public java.util.List getNonResourceURLs() { return this.nonResourceURLs; } + public java.lang.String getNonResourceURL(java.lang.Integer index) { return this.nonResourceURLs.get(index); } + public java.lang.String getFirstNonResourceURL() { return this.nonResourceURLs.get(0); } + public java.lang.String getLastNonResourceURL() { return this.nonResourceURLs.get(nonResourceURLs.size() - 1); } - public java.lang.String getMatchingNonResourceURL(java.util.function.Predicate predicate) { - for (java.lang.String item: nonResourceURLs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingNonResourceURL( + java.util.function.Predicate predicate) { + for (java.lang.String item : nonResourceURLs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingNonResourceURL(java.util.function.Predicate predicate) { - for (java.lang.String item: nonResourceURLs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingNonResourceURL( + java.util.function.Predicate predicate) { + for (java.lang.String item : nonResourceURLs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withNonResourceURLs(java.util.List nonResourceURLs) { - if (nonResourceURLs != null) {this.nonResourceURLs = new java.util.ArrayList(); for (java.lang.String item : nonResourceURLs){this.addToNonResourceURLs(item);}} else { this.nonResourceURLs = null;} return (A) this; + if (nonResourceURLs != null) { + this.nonResourceURLs = new java.util.ArrayList(); + for (java.lang.String item : nonResourceURLs) { + this.addToNonResourceURLs(item); + } + } else { + this.nonResourceURLs = null; + } + return (A) this; } + public A withNonResourceURLs(java.lang.String... nonResourceURLs) { - if (this.nonResourceURLs != null) {this.nonResourceURLs.clear();} - if (nonResourceURLs != null) {for (java.lang.String item :nonResourceURLs){ this.addToNonResourceURLs(item);}} return (A) this; + if (this.nonResourceURLs != null) { + this.nonResourceURLs.clear(); + } + if (nonResourceURLs != null) { + for (java.lang.String item : nonResourceURLs) { + this.addToNonResourceURLs(item); + } + } + return (A) this; } + public java.lang.Boolean hasNonResourceURLs() { return nonResourceURLs != null && !nonResourceURLs.isEmpty(); } + public A addNewNonResourceURL(java.lang.String original) { - return (A)addToNonResourceURLs(new String(original)); + return (A) addToNonResourceURLs(new String(original)); } - public A addToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} + + public A addToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } this.verbs.add(index, item); - return (A)this; + return (A) this; } - public A setToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - this.verbs.set(index, item); return (A)this; + + public A setToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + this.verbs.set(index, item); + return (A) this; } + public A addToVerbs(java.lang.String... items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A addAllToVerbs(java.util.Collection items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A removeFromVerbs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public A removeAllFromVerbs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public java.util.List getVerbs() { return this.verbs; } + public java.lang.String getVerb(java.lang.Integer index) { return this.verbs.get(index); } + public java.lang.String getFirstVerb() { return this.verbs.get(0); } + public java.lang.String getLastVerb() { return this.verbs.get(verbs.size() - 1); } - public java.lang.String getMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withVerbs(java.util.List verbs) { - if (verbs != null) {this.verbs = new java.util.ArrayList(); for (java.lang.String item : verbs){this.addToVerbs(item);}} else { this.verbs = null;} return (A) this; + if (verbs != null) { + this.verbs = new java.util.ArrayList(); + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } else { + this.verbs = null; + } + return (A) this; } + public A withVerbs(java.lang.String... verbs) { - if (this.verbs != null) {this.verbs.clear();} - if (verbs != null) {for (java.lang.String item :verbs){ this.addToVerbs(item);}} return (A) this; + if (this.verbs != null) { + this.verbs.clear(); + } + if (verbs != null) { + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } + return (A) this; } + public java.lang.Boolean hasVerbs() { return verbs != null && !verbs.isEmpty(); } + public A addNewVerb(java.lang.String original) { - return (A)addToVerbs(new String(original)); + return (A) addToVerbs(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1NonResourceRuleFluentImpl that = (V1NonResourceRuleFluentImpl) o; - if (nonResourceURLs != null ? !nonResourceURLs.equals(that.nonResourceURLs) :that.nonResourceURLs != null) return false; - if (verbs != null ? !verbs.equals(that.verbs) :that.verbs != null) return false; + if (nonResourceURLs != null + ? !nonResourceURLs.equals(that.nonResourceURLs) + : that.nonResourceURLs != null) return false; + if (verbs != null ? !verbs.equals(that.verbs) : that.verbs != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(nonResourceURLs, verbs, super.hashCode()); + return java.util.Objects.hash(nonResourceURLs, verbs, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectFieldSelectorBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectFieldSelectorBuilder.java index 8b12747f03..6fa44176bd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectFieldSelectorBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectFieldSelectorBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ObjectFieldSelectorBuilder extends io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ObjectFieldSelectorBuilder + extends io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ObjectFieldSelector, + io.kubernetes.client.openapi.models.V1ObjectFieldSelectorBuilder> { public V1ObjectFieldSelectorBuilder() { this(false); } + public V1ObjectFieldSelectorBuilder(java.lang.Boolean validationEnabled) { this(new V1ObjectFieldSelector(), validationEnabled); } - public V1ObjectFieldSelectorBuilder(io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent fluent) { + + public V1ObjectFieldSelectorBuilder( + io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent fluent) { this(fluent, false); } - public V1ObjectFieldSelectorBuilder(io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ObjectFieldSelectorBuilder( + io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ObjectFieldSelector(), validationEnabled); } - public V1ObjectFieldSelectorBuilder(io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent fluent,io.kubernetes.client.openapi.models.V1ObjectFieldSelector instance) { + + public V1ObjectFieldSelectorBuilder( + io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent fluent, + io.kubernetes.client.openapi.models.V1ObjectFieldSelector instance) { this(fluent, instance, false); } - public V1ObjectFieldSelectorBuilder(io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent fluent,io.kubernetes.client.openapi.models.V1ObjectFieldSelector instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ObjectFieldSelectorBuilder( + io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent fluent, + io.kubernetes.client.openapi.models.V1ObjectFieldSelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withFieldPath(instance.getFieldPath()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ObjectFieldSelectorBuilder(io.kubernetes.client.openapi.models.V1ObjectFieldSelector instance) { - this(instance,false); + + public V1ObjectFieldSelectorBuilder( + io.kubernetes.client.openapi.models.V1ObjectFieldSelector instance) { + this(instance, false); } - public V1ObjectFieldSelectorBuilder(io.kubernetes.client.openapi.models.V1ObjectFieldSelector instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ObjectFieldSelectorBuilder( + io.kubernetes.client.openapi.models.V1ObjectFieldSelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withFieldPath(instance.getFieldPath()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ObjectFieldSelector build() { V1ObjectFieldSelector buildable = new V1ObjectFieldSelector(); buildable.setApiVersion(fluent.getApiVersion()); buildable.setFieldPath(fluent.getFieldPath()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ObjectFieldSelectorBuilder that = (V1ObjectFieldSelectorBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectFieldSelectorFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectFieldSelectorFluent.java index 5dcaeb6a0a..32ec309123 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectFieldSelectorFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectFieldSelectorFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ObjectFieldSelectorFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ObjectFieldSelectorFluent< + A extends io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getFieldPath(); + public A withFieldPath(java.lang.String fieldPath); + public java.lang.Boolean hasFieldPath(); - - /** - * Method is deprecated. use withFieldPath instead. - */ + + /** Method is deprecated. use withFieldPath instead. */ @java.lang.Deprecated public A withNewFieldPath(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectFieldSelectorFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectFieldSelectorFluentImpl.java index 6a163f363e..b65245453e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectFieldSelectorFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectFieldSelectorFluentImpl.java @@ -1,69 +1,84 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ObjectFieldSelectorFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent { + public V1ObjectFieldSelectorFluentImpl() {} - /** - * Generated - */ -public class V1ObjectFieldSelectorFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ObjectFieldSelectorFluent{ - public V1ObjectFieldSelectorFluentImpl() { - } - public V1ObjectFieldSelectorFluentImpl(io.kubernetes.client.openapi.models.V1ObjectFieldSelector instance) { + public V1ObjectFieldSelectorFluentImpl( + io.kubernetes.client.openapi.models.V1ObjectFieldSelector instance) { this.withApiVersion(instance.getApiVersion()); this.withFieldPath(instance.getFieldPath()); - } + private java.lang.String apiVersion; private java.lang.String fieldPath; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getFieldPath() { return this.fieldPath; } + public A withFieldPath(java.lang.String fieldPath) { - this.fieldPath=fieldPath; return (A) this; + this.fieldPath = fieldPath; + return (A) this; } + public java.lang.Boolean hasFieldPath() { return this.fieldPath != null; } - - /** - * Method is deprecated. use withFieldPath instead. - */ + + /** Method is deprecated. use withFieldPath instead. */ @java.lang.Deprecated public A withNewFieldPath(java.lang.String original) { - return (A)withFieldPath(new String(original)); + return (A) withFieldPath(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ObjectFieldSelectorFluentImpl that = (V1ObjectFieldSelectorFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (fieldPath != null ? !fieldPath.equals(that.fieldPath) :that.fieldPath != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (fieldPath != null ? !fieldPath.equals(that.fieldPath) : that.fieldPath != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, fieldPath, super.hashCode()); + return java.util.Objects.hash(apiVersion, fieldPath, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectMetaBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectMetaBuilder.java index 3c1d1f39b1..d506906e07 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectMetaBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectMetaBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ObjectMetaBuilder extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ObjectMetaBuilder + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ObjectMeta, + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder> { public V1ObjectMetaBuilder() { this(false); } + public V1ObjectMetaBuilder(java.lang.Boolean validationEnabled) { this(new V1ObjectMeta(), validationEnabled); } + public V1ObjectMetaBuilder(io.kubernetes.client.openapi.models.V1ObjectMetaFluent fluent) { this(fluent, false); } - public V1ObjectMetaBuilder(io.kubernetes.client.openapi.models.V1ObjectMetaFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ObjectMetaBuilder( + io.kubernetes.client.openapi.models.V1ObjectMetaFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ObjectMeta(), validationEnabled); } - public V1ObjectMetaBuilder(io.kubernetes.client.openapi.models.V1ObjectMetaFluent fluent,io.kubernetes.client.openapi.models.V1ObjectMeta instance) { + + public V1ObjectMetaBuilder( + io.kubernetes.client.openapi.models.V1ObjectMetaFluent fluent, + io.kubernetes.client.openapi.models.V1ObjectMeta instance) { this(fluent, instance, false); } - public V1ObjectMetaBuilder(io.kubernetes.client.openapi.models.V1ObjectMetaFluent fluent,io.kubernetes.client.openapi.models.V1ObjectMeta instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ObjectMetaBuilder( + io.kubernetes.client.openapi.models.V1ObjectMetaFluent fluent, + io.kubernetes.client.openapi.models.V1ObjectMeta instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAnnotations(instance.getAnnotations()); fluent.withClusterName(instance.getClusterName()); @@ -53,13 +79,17 @@ public V1ObjectMetaBuilder(io.kubernetes.client.openapi.models.V1ObjectMetaFluen fluent.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ObjectMetaBuilder(io.kubernetes.client.openapi.models.V1ObjectMeta instance) { - this(instance,false); + this(instance, false); } - public V1ObjectMetaBuilder(io.kubernetes.client.openapi.models.V1ObjectMeta instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ObjectMetaBuilder( + io.kubernetes.client.openapi.models.V1ObjectMeta instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAnnotations(instance.getAnnotations()); this.withClusterName(instance.getClusterName()); @@ -92,10 +122,12 @@ public V1ObjectMetaBuilder(io.kubernetes.client.openapi.models.V1ObjectMeta inst this.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ObjectMetaFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ObjectMeta build() { V1ObjectMeta buildable = new V1ObjectMeta(); buildable.setAnnotations(fluent.getAnnotations()); @@ -116,18 +148,23 @@ public io.kubernetes.client.openapi.models.V1ObjectMeta build() { buildable.setUid(fluent.getUid()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ObjectMetaBuilder that = (V1ObjectMetaBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectMetaFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectMetaFluent.java index b93c6889d9..37efd9953b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectMetaFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectMetaFluent.java @@ -1,201 +1,351 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.lang.Long; -import java.util.Collection; -import java.util.Map; - - /** - * Generated - */ -public interface V1ObjectMetaFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAnnotations(java.lang.String key,java.lang.String value); - public A addToAnnotations(java.util.Map map); +/** Generated */ +public interface V1ObjectMetaFluent< + A extends io.kubernetes.client.openapi.models.V1ObjectMetaFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAnnotations(java.lang.String key, java.lang.String value); + + public A addToAnnotations(java.util.Map map); + public A removeFromAnnotations(java.lang.String key); - public A removeFromAnnotations(java.util.Map map); - public java.util.Map getAnnotations(); - public A withAnnotations(java.util.Map annotations); + + public A removeFromAnnotations(java.util.Map map); + + public java.util.Map getAnnotations(); + + public A withAnnotations(java.util.Map annotations); + public java.lang.Boolean hasAnnotations(); + public java.lang.String getClusterName(); + public A withClusterName(java.lang.String clusterName); + public java.lang.Boolean hasClusterName(); - - /** - * Method is deprecated. use withClusterName instead. - */ + + /** Method is deprecated. use withClusterName instead. */ @java.lang.Deprecated public A withNewClusterName(java.lang.String original); + public java.time.OffsetDateTime getCreationTimestamp(); + public A withCreationTimestamp(java.time.OffsetDateTime creationTimestamp); + public java.lang.Boolean hasCreationTimestamp(); + public java.lang.Long getDeletionGracePeriodSeconds(); + public A withDeletionGracePeriodSeconds(java.lang.Long deletionGracePeriodSeconds); + public java.lang.Boolean hasDeletionGracePeriodSeconds(); + public java.time.OffsetDateTime getDeletionTimestamp(); + public A withDeletionTimestamp(java.time.OffsetDateTime deletionTimestamp); + public java.lang.Boolean hasDeletionTimestamp(); - public A addToFinalizers(java.lang.Integer index,java.lang.String item); - public A setToFinalizers(java.lang.Integer index,java.lang.String item); + + public A addToFinalizers(java.lang.Integer index, java.lang.String item); + + public A setToFinalizers(java.lang.Integer index, java.lang.String item); + public A addToFinalizers(java.lang.String... items); + public A addAllToFinalizers(java.util.Collection items); + public A removeFromFinalizers(java.lang.String... items); + public A removeAllFromFinalizers(java.util.Collection items); + public java.util.List getFinalizers(); + public java.lang.String getFinalizer(java.lang.Integer index); + public java.lang.String getFirstFinalizer(); + public java.lang.String getLastFinalizer(); - public java.lang.String getMatchingFinalizer(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingFinalizer(java.util.function.Predicate predicate); + + public java.lang.String getMatchingFinalizer( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingFinalizer( + java.util.function.Predicate predicate); + public A withFinalizers(java.util.List finalizers); + public A withFinalizers(java.lang.String... finalizers); + public java.lang.Boolean hasFinalizers(); + public A addNewFinalizer(java.lang.String original); + public java.lang.String getGenerateName(); + public A withGenerateName(java.lang.String generateName); + public java.lang.Boolean hasGenerateName(); - - /** - * Method is deprecated. use withGenerateName instead. - */ + + /** Method is deprecated. use withGenerateName instead. */ @java.lang.Deprecated public A withNewGenerateName(java.lang.String original); + public java.lang.Long getGeneration(); + public A withGeneration(java.lang.Long generation); + public java.lang.Boolean hasGeneration(); - public A addToLabels(java.lang.String key,java.lang.String value); - public A addToLabels(java.util.Map map); + + public A addToLabels(java.lang.String key, java.lang.String value); + + public A addToLabels(java.util.Map map); + public A removeFromLabels(java.lang.String key); - public A removeFromLabels(java.util.Map map); - public java.util.Map getLabels(); - public A withLabels(java.util.Map labels); + + public A removeFromLabels(java.util.Map map); + + public java.util.Map getLabels(); + + public A withLabels(java.util.Map labels); + public java.lang.Boolean hasLabels(); - public A addToManagedFields(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item); - public A setToManagedFields(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item); + + public A addToManagedFields( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item); + + public A setToManagedFields( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item); + public A addToManagedFields(io.kubernetes.client.openapi.models.V1ManagedFieldsEntry... items); - public A addAllToManagedFields(java.util.Collection items); - public A removeFromManagedFields(io.kubernetes.client.openapi.models.V1ManagedFieldsEntry... items); - public A removeAllFromManagedFields(java.util.Collection items); - public A removeMatchingFromManagedFields(java.util.function.Predicate predicate); - + + public A addAllToManagedFields( + java.util.Collection items); + + public A removeFromManagedFields( + io.kubernetes.client.openapi.models.V1ManagedFieldsEntry... items); + + public A removeAllFromManagedFields( + java.util.Collection items); + + public A removeMatchingFromManagedFields( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildManagedFields instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getManagedFields(); - public java.util.List buildManagedFields(); - public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry buildManagedField(java.lang.Integer index); + public java.util.List + getManagedFields(); + + public java.util.List + buildManagedFields(); + + public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry buildManagedField( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry buildFirstManagedField(); + public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry buildLastManagedField(); - public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry buildMatchingManagedField(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingManagedField(java.util.function.Predicate predicate); - public A withManagedFields(java.util.List managedFields); - public A withManagedFields(io.kubernetes.client.openapi.models.V1ManagedFieldsEntry... managedFields); + + public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry buildMatchingManagedField( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingManagedField( + java.util.function.Predicate + predicate); + + public A withManagedFields( + java.util.List managedFields); + + public A withManagedFields( + io.kubernetes.client.openapi.models.V1ManagedFieldsEntry... managedFields); + public java.lang.Boolean hasManagedFields(); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested addNewManagedField(); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested addNewManagedFieldLike(io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested setNewManagedFieldLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested editManagedField(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested editFirstManagedField(); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested editLastManagedField(); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested editMatchingManagedField(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + addNewManagedField(); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + addNewManagedFieldLike(io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + setNewManagedFieldLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + editManagedField(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + editFirstManagedField(); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + editLastManagedField(); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + editMatchingManagedField( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder> + predicate); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getNamespace(); + public A withNamespace(java.lang.String namespace); + public java.lang.Boolean hasNamespace(); - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original); - public A addToOwnerReferences(java.lang.Integer index,io.kubernetes.client.openapi.models.V1OwnerReference item); - public A setToOwnerReferences(java.lang.Integer index,io.kubernetes.client.openapi.models.V1OwnerReference item); + + public A addToOwnerReferences( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1OwnerReference item); + + public A setToOwnerReferences( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1OwnerReference item); + public A addToOwnerReferences(io.kubernetes.client.openapi.models.V1OwnerReference... items); - public A addAllToOwnerReferences(java.util.Collection items); + + public A addAllToOwnerReferences( + java.util.Collection items); + public A removeFromOwnerReferences(io.kubernetes.client.openapi.models.V1OwnerReference... items); - public A removeAllFromOwnerReferences(java.util.Collection items); - public A removeMatchingFromOwnerReferences(java.util.function.Predicate predicate); - + + public A removeAllFromOwnerReferences( + java.util.Collection items); + + public A removeMatchingFromOwnerReferences( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildOwnerReferences instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getOwnerReferences(); - public java.util.List buildOwnerReferences(); - public io.kubernetes.client.openapi.models.V1OwnerReference buildOwnerReference(java.lang.Integer index); + + public java.util.List + buildOwnerReferences(); + + public io.kubernetes.client.openapi.models.V1OwnerReference buildOwnerReference( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1OwnerReference buildFirstOwnerReference(); + public io.kubernetes.client.openapi.models.V1OwnerReference buildLastOwnerReference(); - public io.kubernetes.client.openapi.models.V1OwnerReference buildMatchingOwnerReference(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingOwnerReference(java.util.function.Predicate predicate); - public A withOwnerReferences(java.util.List ownerReferences); - public A withOwnerReferences(io.kubernetes.client.openapi.models.V1OwnerReference... ownerReferences); + + public io.kubernetes.client.openapi.models.V1OwnerReference buildMatchingOwnerReference( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingOwnerReference( + java.util.function.Predicate + predicate); + + public A withOwnerReferences( + java.util.List ownerReferences); + + public A withOwnerReferences( + io.kubernetes.client.openapi.models.V1OwnerReference... ownerReferences); + public java.lang.Boolean hasOwnerReferences(); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested addNewOwnerReference(); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested addNewOwnerReferenceLike(io.kubernetes.client.openapi.models.V1OwnerReference item); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested setNewOwnerReferenceLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1OwnerReference item); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested editOwnerReference(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested editFirstOwnerReference(); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested editLastOwnerReference(); - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested editMatchingOwnerReference(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + addNewOwnerReference(); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + addNewOwnerReferenceLike(io.kubernetes.client.openapi.models.V1OwnerReference item); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + setNewOwnerReferenceLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1OwnerReference item); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + editOwnerReference(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + editFirstOwnerReference(); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + editLastOwnerReference(); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + editMatchingOwnerReference( + java.util.function.Predicate + predicate); + public java.lang.String getResourceVersion(); + public A withResourceVersion(java.lang.String resourceVersion); + public java.lang.Boolean hasResourceVersion(); - - /** - * Method is deprecated. use withResourceVersion instead. - */ + + /** Method is deprecated. use withResourceVersion instead. */ @java.lang.Deprecated public A withNewResourceVersion(java.lang.String original); + public java.lang.String getSelfLink(); + public A withSelfLink(java.lang.String selfLink); + public java.lang.Boolean hasSelfLink(); - - /** - * Method is deprecated. use withSelfLink instead. - */ + + /** Method is deprecated. use withSelfLink instead. */ @java.lang.Deprecated public A withNewSelfLink(java.lang.String original); + public java.lang.String getUid(); + public A withUid(java.lang.String uid); + public java.lang.Boolean hasUid(); - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original); - public interface ManagedFieldsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent>{ + + public interface ManagedFieldsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluent< + io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested> { public N and(); + public N endManagedField(); - } - public interface OwnerReferencesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1OwnerReferenceFluent>{ + + public interface OwnerReferencesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1OwnerReferenceFluent< + io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested> { public N and(); + public N endOwnerReference(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectMetaFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectMetaFluentImpl.java index 2d8b7da6a4..9e751bcc04 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectMetaFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectMetaFluentImpl.java @@ -1,29 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.lang.Long; -import java.util.Collection; -import java.lang.Object; -import java.util.Map; - - /** - * Generated - */ -public class V1ObjectMetaFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ObjectMetaFluent{ - public V1ObjectMetaFluentImpl() { - } + +/** Generated */ +public class V1ObjectMetaFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ObjectMetaFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ObjectMetaFluent { + public V1ObjectMetaFluentImpl() {} + public V1ObjectMetaFluentImpl(io.kubernetes.client.openapi.models.V1ObjectMeta instance) { this.withAnnotations(instance.getAnnotations()); @@ -56,9 +54,9 @@ public V1ObjectMetaFluentImpl(io.kubernetes.client.openapi.models.V1ObjectMeta i this.withSelfLink(instance.getSelfLink()); this.withUid(instance.getUid()); - } - private java.util.Map annotations; + + private java.util.Map annotations; private java.lang.String clusterName; private java.time.OffsetDateTime creationTimestamp; private java.lang.Long deletionGracePeriodSeconds; @@ -66,216 +64,452 @@ public V1ObjectMetaFluentImpl(io.kubernetes.client.openapi.models.V1ObjectMeta i private java.util.List finalizers; private java.lang.String generateName; private java.lang.Long generation; - private java.util.Map labels; - private java.util.ArrayList managedFields; + private java.util.Map labels; + private java.util.ArrayList + managedFields; private java.lang.String name; private java.lang.String namespace; - private java.util.ArrayList ownerReferences; + private java.util.ArrayList + ownerReferences; private java.lang.String resourceVersion; private java.lang.String selfLink; private java.lang.String uid; - public A addToAnnotations(java.lang.String key,java.lang.String value) { - if(this.annotations == null && key != null && value != null) { this.annotations = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.annotations.put(key, value);} return (A)this; + + public A addToAnnotations(java.lang.String key, java.lang.String value) { + if (this.annotations == null && key != null && value != null) { + this.annotations = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.annotations.put(key, value); + } + return (A) this; } - public A addToAnnotations(java.util.Map map) { - if(this.annotations == null && map != null) { this.annotations = new java.util.LinkedHashMap(); } - if(map != null) { this.annotations.putAll(map);} return (A)this; + + public A addToAnnotations(java.util.Map map) { + if (this.annotations == null && map != null) { + this.annotations = new java.util.LinkedHashMap(); + } + if (map != null) { + this.annotations.putAll(map); + } + return (A) this; } + public A removeFromAnnotations(java.lang.String key) { - if(this.annotations == null) { return (A) this; } - if(key != null && this.annotations != null) {this.annotations.remove(key);} return (A)this; + if (this.annotations == null) { + return (A) this; + } + if (key != null && this.annotations != null) { + this.annotations.remove(key); + } + return (A) this; } - public A removeFromAnnotations(java.util.Map map) { - if(this.annotations == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.annotations != null){this.annotations.remove(key);}}} return (A)this; + + public A removeFromAnnotations(java.util.Map map) { + if (this.annotations == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.annotations != null) { + this.annotations.remove(key); + } + } + } + return (A) this; } - public java.util.Map getAnnotations() { + + public java.util.Map getAnnotations() { return this.annotations; } - public A withAnnotations(java.util.Map annotations) { - if (annotations == null) { this.annotations = null;} else {this.annotations = new java.util.LinkedHashMap(annotations);} return (A) this; + + public A withAnnotations(java.util.Map annotations) { + if (annotations == null) { + this.annotations = null; + } else { + this.annotations = new java.util.LinkedHashMap(annotations); + } + return (A) this; } + public java.lang.Boolean hasAnnotations() { return this.annotations != null; } + public java.lang.String getClusterName() { return this.clusterName; } + public A withClusterName(java.lang.String clusterName) { - this.clusterName=clusterName; return (A) this; + this.clusterName = clusterName; + return (A) this; } + public java.lang.Boolean hasClusterName() { return this.clusterName != null; } - - /** - * Method is deprecated. use withClusterName instead. - */ + + /** Method is deprecated. use withClusterName instead. */ @java.lang.Deprecated public A withNewClusterName(java.lang.String original) { - return (A)withClusterName(new String(original)); + return (A) withClusterName(new String(original)); } + public java.time.OffsetDateTime getCreationTimestamp() { return this.creationTimestamp; } + public A withCreationTimestamp(java.time.OffsetDateTime creationTimestamp) { - this.creationTimestamp=creationTimestamp; return (A) this; + this.creationTimestamp = creationTimestamp; + return (A) this; } + public java.lang.Boolean hasCreationTimestamp() { return this.creationTimestamp != null; } + public java.lang.Long getDeletionGracePeriodSeconds() { return this.deletionGracePeriodSeconds; } + public A withDeletionGracePeriodSeconds(java.lang.Long deletionGracePeriodSeconds) { - this.deletionGracePeriodSeconds=deletionGracePeriodSeconds; return (A) this; + this.deletionGracePeriodSeconds = deletionGracePeriodSeconds; + return (A) this; } + public java.lang.Boolean hasDeletionGracePeriodSeconds() { return this.deletionGracePeriodSeconds != null; } + public java.time.OffsetDateTime getDeletionTimestamp() { return this.deletionTimestamp; } + public A withDeletionTimestamp(java.time.OffsetDateTime deletionTimestamp) { - this.deletionTimestamp=deletionTimestamp; return (A) this; + this.deletionTimestamp = deletionTimestamp; + return (A) this; } + public java.lang.Boolean hasDeletionTimestamp() { return this.deletionTimestamp != null; } - public A addToFinalizers(java.lang.Integer index,java.lang.String item) { - if (this.finalizers == null) {this.finalizers = new java.util.ArrayList();} + + public A addToFinalizers(java.lang.Integer index, java.lang.String item) { + if (this.finalizers == null) { + this.finalizers = new java.util.ArrayList(); + } this.finalizers.add(index, item); - return (A)this; + return (A) this; } - public A setToFinalizers(java.lang.Integer index,java.lang.String item) { - if (this.finalizers == null) {this.finalizers = new java.util.ArrayList();} - this.finalizers.set(index, item); return (A)this; + + public A setToFinalizers(java.lang.Integer index, java.lang.String item) { + if (this.finalizers == null) { + this.finalizers = new java.util.ArrayList(); + } + this.finalizers.set(index, item); + return (A) this; } + public A addToFinalizers(java.lang.String... items) { - if (this.finalizers == null) {this.finalizers = new java.util.ArrayList();} - for (java.lang.String item : items) {this.finalizers.add(item);} return (A)this; + if (this.finalizers == null) { + this.finalizers = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.finalizers.add(item); + } + return (A) this; } + public A addAllToFinalizers(java.util.Collection items) { - if (this.finalizers == null) {this.finalizers = new java.util.ArrayList();} - for (java.lang.String item : items) {this.finalizers.add(item);} return (A)this; + if (this.finalizers == null) { + this.finalizers = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.finalizers.add(item); + } + return (A) this; } + public A removeFromFinalizers(java.lang.String... items) { - for (java.lang.String item : items) {if (this.finalizers!= null){ this.finalizers.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.finalizers != null) { + this.finalizers.remove(item); + } + } + return (A) this; } + public A removeAllFromFinalizers(java.util.Collection items) { - for (java.lang.String item : items) {if (this.finalizers!= null){ this.finalizers.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.finalizers != null) { + this.finalizers.remove(item); + } + } + return (A) this; } + public java.util.List getFinalizers() { return this.finalizers; } + public java.lang.String getFinalizer(java.lang.Integer index) { return this.finalizers.get(index); } + public java.lang.String getFirstFinalizer() { return this.finalizers.get(0); } + public java.lang.String getLastFinalizer() { return this.finalizers.get(finalizers.size() - 1); } - public java.lang.String getMatchingFinalizer(java.util.function.Predicate predicate) { - for (java.lang.String item: finalizers) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingFinalizer( + java.util.function.Predicate predicate) { + for (java.lang.String item : finalizers) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingFinalizer(java.util.function.Predicate predicate) { - for (java.lang.String item: finalizers) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingFinalizer( + java.util.function.Predicate predicate) { + for (java.lang.String item : finalizers) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withFinalizers(java.util.List finalizers) { - if (finalizers != null) {this.finalizers = new java.util.ArrayList(); for (java.lang.String item : finalizers){this.addToFinalizers(item);}} else { this.finalizers = null;} return (A) this; + if (finalizers != null) { + this.finalizers = new java.util.ArrayList(); + for (java.lang.String item : finalizers) { + this.addToFinalizers(item); + } + } else { + this.finalizers = null; + } + return (A) this; } + public A withFinalizers(java.lang.String... finalizers) { - if (this.finalizers != null) {this.finalizers.clear();} - if (finalizers != null) {for (java.lang.String item :finalizers){ this.addToFinalizers(item);}} return (A) this; + if (this.finalizers != null) { + this.finalizers.clear(); + } + if (finalizers != null) { + for (java.lang.String item : finalizers) { + this.addToFinalizers(item); + } + } + return (A) this; } + public java.lang.Boolean hasFinalizers() { return finalizers != null && !finalizers.isEmpty(); } + public A addNewFinalizer(java.lang.String original) { - return (A)addToFinalizers(new String(original)); + return (A) addToFinalizers(new String(original)); } + public java.lang.String getGenerateName() { return this.generateName; } + public A withGenerateName(java.lang.String generateName) { - this.generateName=generateName; return (A) this; + this.generateName = generateName; + return (A) this; } + public java.lang.Boolean hasGenerateName() { return this.generateName != null; } - - /** - * Method is deprecated. use withGenerateName instead. - */ + + /** Method is deprecated. use withGenerateName instead. */ @java.lang.Deprecated public A withNewGenerateName(java.lang.String original) { - return (A)withGenerateName(new String(original)); + return (A) withGenerateName(new String(original)); } + public java.lang.Long getGeneration() { return this.generation; } + public A withGeneration(java.lang.Long generation) { - this.generation=generation; return (A) this; + this.generation = generation; + return (A) this; } + public java.lang.Boolean hasGeneration() { return this.generation != null; } - public A addToLabels(java.lang.String key,java.lang.String value) { - if(this.labels == null && key != null && value != null) { this.labels = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.labels.put(key, value);} return (A)this; + + public A addToLabels(java.lang.String key, java.lang.String value) { + if (this.labels == null && key != null && value != null) { + this.labels = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.labels.put(key, value); + } + return (A) this; } - public A addToLabels(java.util.Map map) { - if(this.labels == null && map != null) { this.labels = new java.util.LinkedHashMap(); } - if(map != null) { this.labels.putAll(map);} return (A)this; + + public A addToLabels(java.util.Map map) { + if (this.labels == null && map != null) { + this.labels = new java.util.LinkedHashMap(); + } + if (map != null) { + this.labels.putAll(map); + } + return (A) this; } + public A removeFromLabels(java.lang.String key) { - if(this.labels == null) { return (A) this; } - if(key != null && this.labels != null) {this.labels.remove(key);} return (A)this; + if (this.labels == null) { + return (A) this; + } + if (key != null && this.labels != null) { + this.labels.remove(key); + } + return (A) this; } - public A removeFromLabels(java.util.Map map) { - if(this.labels == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.labels != null){this.labels.remove(key);}}} return (A)this; + + public A removeFromLabels(java.util.Map map) { + if (this.labels == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.labels != null) { + this.labels.remove(key); + } + } + } + return (A) this; } - public java.util.Map getLabels() { + + public java.util.Map getLabels() { return this.labels; } - public A withLabels(java.util.Map labels) { - if (labels == null) { this.labels = null;} else {this.labels = new java.util.LinkedHashMap(labels);} return (A) this; + + public A withLabels(java.util.Map labels) { + if (labels == null) { + this.labels = null; + } else { + this.labels = new java.util.LinkedHashMap(labels); + } + return (A) this; } + public java.lang.Boolean hasLabels() { return this.labels != null; } - public A addToManagedFields(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item) { - if (this.managedFields == null) {this.managedFields = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder = new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(item);_visitables.get("managedFields").add(index >= 0 ? index : _visitables.get("managedFields").size(), builder);this.managedFields.add(index >= 0 ? index : managedFields.size(), builder); return (A)this; + + public A addToManagedFields( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item) { + if (this.managedFields == null) { + this.managedFields = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder>(); + } + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder = + new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(item); + _visitables + .get("managedFields") + .add(index >= 0 ? index : _visitables.get("managedFields").size(), builder); + this.managedFields.add(index >= 0 ? index : managedFields.size(), builder); + return (A) this; } - public A setToManagedFields(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item) { - if (this.managedFields == null) {this.managedFields = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder = new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(item); - if (index < 0 || index >= _visitables.get("managedFields").size()) { _visitables.get("managedFields").add(builder); } else { _visitables.get("managedFields").set(index, builder);} - if (index < 0 || index >= managedFields.size()) { managedFields.add(builder); } else { managedFields.set(index, builder);} - return (A)this; + + public A setToManagedFields( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item) { + if (this.managedFields == null) { + this.managedFields = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder>(); + } + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder = + new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(item); + if (index < 0 || index >= _visitables.get("managedFields").size()) { + _visitables.get("managedFields").add(builder); + } else { + _visitables.get("managedFields").set(index, builder); + } + if (index < 0 || index >= managedFields.size()) { + managedFields.add(builder); + } else { + managedFields.set(index, builder); + } + return (A) this; } + public A addToManagedFields(io.kubernetes.client.openapi.models.V1ManagedFieldsEntry... items) { - if (this.managedFields == null) {this.managedFields = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item : items) {io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder = new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(item);_visitables.get("managedFields").add(builder);this.managedFields.add(builder);} return (A)this; + if (this.managedFields == null) { + this.managedFields = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item : items) { + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder = + new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(item); + _visitables.get("managedFields").add(builder); + this.managedFields.add(builder); + } + return (A) this; } - public A addAllToManagedFields(java.util.Collection items) { - if (this.managedFields == null) {this.managedFields = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item : items) {io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder = new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(item);_visitables.get("managedFields").add(builder);this.managedFields.add(builder);} return (A)this; + + public A addAllToManagedFields( + java.util.Collection items) { + if (this.managedFields == null) { + this.managedFields = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item : items) { + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder = + new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(item); + _visitables.get("managedFields").add(builder); + this.managedFields.add(builder); + } + return (A) this; } - public A removeFromManagedFields(io.kubernetes.client.openapi.models.V1ManagedFieldsEntry... items) { - for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item : items) {io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder = new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(item);_visitables.get("managedFields").remove(builder);if (this.managedFields != null) {this.managedFields.remove(builder);}} return (A)this; + + public A removeFromManagedFields( + io.kubernetes.client.openapi.models.V1ManagedFieldsEntry... items) { + for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item : items) { + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder = + new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(item); + _visitables.get("managedFields").remove(builder); + if (this.managedFields != null) { + this.managedFields.remove(builder); + } + } + return (A) this; } - public A removeAllFromManagedFields(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item : items) {io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder = new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(item);_visitables.get("managedFields").remove(builder);if (this.managedFields != null) {this.managedFields.remove(builder);}} return (A)this; + + public A removeAllFromManagedFields( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item : items) { + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder = + new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(item); + _visitables.get("managedFields").remove(builder); + if (this.managedFields != null) { + this.managedFields.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromManagedFields(java.util.function.Predicate predicate) { + + public A removeMatchingFromManagedFields( + java.util.function.Predicate + predicate) { if (managedFields == null) return (A) this; - final Iterator each = managedFields.iterator(); + final Iterator each = + managedFields.iterator(); final List visitables = _visitables.get("managedFields"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder = each.next(); @@ -284,138 +518,283 @@ public A removeMatchingFromManagedFields(java.util.function.Predicate getManagedFields() { + public java.util.List + getManagedFields() { return managedFields != null ? build(managedFields) : null; } - public java.util.List buildManagedFields() { + + public java.util.List + buildManagedFields() { return managedFields != null ? build(managedFields) : null; } - public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry buildManagedField(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry buildManagedField( + java.lang.Integer index) { return this.managedFields.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry buildFirstManagedField() { return this.managedFields.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry buildLastManagedField() { return this.managedFields.get(managedFields.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry buildMatchingManagedField(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder item: managedFields) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ManagedFieldsEntry buildMatchingManagedField( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder item : managedFields) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingManagedField(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder item: managedFields) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingManagedField( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder item : managedFields) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withManagedFields(java.util.List managedFields) { - if (this.managedFields != null) { _visitables.get("managedFields").removeAll(this.managedFields);} - if (managedFields != null) {this.managedFields = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item : managedFields){this.addToManagedFields(item);}} else { this.managedFields = null;} return (A) this; + + public A withManagedFields( + java.util.List managedFields) { + if (this.managedFields != null) { + _visitables.get("managedFields").removeAll(this.managedFields); + } + if (managedFields != null) { + this.managedFields = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item : managedFields) { + this.addToManagedFields(item); + } + } else { + this.managedFields = null; + } + return (A) this; } - public A withManagedFields(io.kubernetes.client.openapi.models.V1ManagedFieldsEntry... managedFields) { - if (this.managedFields != null) {this.managedFields.clear();} - if (managedFields != null) {for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item :managedFields){ this.addToManagedFields(item);}} return (A) this; + + public A withManagedFields( + io.kubernetes.client.openapi.models.V1ManagedFieldsEntry... managedFields) { + if (this.managedFields != null) { + this.managedFields.clear(); + } + if (managedFields != null) { + for (io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item : managedFields) { + this.addToManagedFields(item); + } + } + return (A) this; } + public java.lang.Boolean hasManagedFields() { return managedFields != null && !managedFields.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested addNewManagedField() { + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + addNewManagedField() { return new io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl.ManagedFieldsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested addNewManagedFieldLike(io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item) { - return new io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl.ManagedFieldsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + addNewManagedFieldLike(io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item) { + return new io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl.ManagedFieldsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested setNewManagedFieldLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item) { - return new io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl.ManagedFieldsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + setNewManagedFieldLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item) { + return new io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl.ManagedFieldsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested editManagedField(java.lang.Integer index) { - if (managedFields.size() <= index) throw new RuntimeException("Can't edit managedFields. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + editManagedField(java.lang.Integer index) { + if (managedFields.size() <= index) + throw new RuntimeException("Can't edit managedFields. Index exceeds size."); return setNewManagedFieldLike(index, buildManagedField(index)); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested editFirstManagedField() { - if (managedFields.size() == 0) throw new RuntimeException("Can't edit first managedFields. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + editFirstManagedField() { + if (managedFields.size() == 0) + throw new RuntimeException("Can't edit first managedFields. The list is empty."); return setNewManagedFieldLike(0, buildManagedField(0)); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested editLastManagedField() { + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + editLastManagedField() { int index = managedFields.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last managedFields. The list is empty."); return setNewManagedFieldLike(index, buildManagedField(index)); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested editMatchingManagedField(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested + editMatchingManagedField( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(item);_visitables.get("ownerReferences").add(index >= 0 ? index : _visitables.get("ownerReferences").size(), builder);this.ownerReferences.add(index >= 0 ? index : ownerReferences.size(), builder); return (A)this; + + public A addToOwnerReferences( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1OwnerReference item) { + if (this.ownerReferences == null) { + this.ownerReferences = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(item); + _visitables + .get("ownerReferences") + .add(index >= 0 ? index : _visitables.get("ownerReferences").size(), builder); + this.ownerReferences.add(index >= 0 ? index : ownerReferences.size(), builder); + return (A) this; } - public A setToOwnerReferences(java.lang.Integer index,io.kubernetes.client.openapi.models.V1OwnerReference item) { - if (this.ownerReferences == null) {this.ownerReferences = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(item); - if (index < 0 || index >= _visitables.get("ownerReferences").size()) { _visitables.get("ownerReferences").add(builder); } else { _visitables.get("ownerReferences").set(index, builder);} - if (index < 0 || index >= ownerReferences.size()) { ownerReferences.add(builder); } else { ownerReferences.set(index, builder);} - return (A)this; + + public A setToOwnerReferences( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1OwnerReference item) { + if (this.ownerReferences == null) { + this.ownerReferences = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(item); + if (index < 0 || index >= _visitables.get("ownerReferences").size()) { + _visitables.get("ownerReferences").add(builder); + } else { + _visitables.get("ownerReferences").set(index, builder); + } + if (index < 0 || index >= ownerReferences.size()) { + ownerReferences.add(builder); + } else { + ownerReferences.set(index, builder); + } + return (A) this; } + public A addToOwnerReferences(io.kubernetes.client.openapi.models.V1OwnerReference... items) { - if (this.ownerReferences == null) {this.ownerReferences = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1OwnerReference item : items) {io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(item);_visitables.get("ownerReferences").add(builder);this.ownerReferences.add(builder);} return (A)this; + if (this.ownerReferences == null) { + this.ownerReferences = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1OwnerReference item : items) { + io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(item); + _visitables.get("ownerReferences").add(builder); + this.ownerReferences.add(builder); + } + return (A) this; } - public A addAllToOwnerReferences(java.util.Collection items) { - if (this.ownerReferences == null) {this.ownerReferences = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1OwnerReference item : items) {io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(item);_visitables.get("ownerReferences").add(builder);this.ownerReferences.add(builder);} return (A)this; + + public A addAllToOwnerReferences( + java.util.Collection items) { + if (this.ownerReferences == null) { + this.ownerReferences = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1OwnerReference item : items) { + io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(item); + _visitables.get("ownerReferences").add(builder); + this.ownerReferences.add(builder); + } + return (A) this; } - public A removeFromOwnerReferences(io.kubernetes.client.openapi.models.V1OwnerReference... items) { - for (io.kubernetes.client.openapi.models.V1OwnerReference item : items) {io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(item);_visitables.get("ownerReferences").remove(builder);if (this.ownerReferences != null) {this.ownerReferences.remove(builder);}} return (A)this; + + public A removeFromOwnerReferences( + io.kubernetes.client.openapi.models.V1OwnerReference... items) { + for (io.kubernetes.client.openapi.models.V1OwnerReference item : items) { + io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(item); + _visitables.get("ownerReferences").remove(builder); + if (this.ownerReferences != null) { + this.ownerReferences.remove(builder); + } + } + return (A) this; } - public A removeAllFromOwnerReferences(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1OwnerReference item : items) {io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(item);_visitables.get("ownerReferences").remove(builder);if (this.ownerReferences != null) {this.ownerReferences.remove(builder);}} return (A)this; + + public A removeAllFromOwnerReferences( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1OwnerReference item : items) { + io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(item); + _visitables.get("ownerReferences").remove(builder); + if (this.ownerReferences != null) { + this.ownerReferences.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromOwnerReferences(java.util.function.Predicate predicate) { + + public A removeMatchingFromOwnerReferences( + java.util.function.Predicate + predicate) { if (ownerReferences == null) return (A) this; - final Iterator each = ownerReferences.iterator(); + final Iterator each = + ownerReferences.iterator(); final List visitables = _visitables.get("ownerReferences"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder = each.next(); @@ -424,189 +803,322 @@ public A removeMatchingFromOwnerReferences(java.util.function.Predicate getOwnerReferences() { return ownerReferences != null ? build(ownerReferences) : null; } - public java.util.List buildOwnerReferences() { + + public java.util.List + buildOwnerReferences() { return ownerReferences != null ? build(ownerReferences) : null; } - public io.kubernetes.client.openapi.models.V1OwnerReference buildOwnerReference(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1OwnerReference buildOwnerReference( + java.lang.Integer index) { return this.ownerReferences.get(index).build(); } + public io.kubernetes.client.openapi.models.V1OwnerReference buildFirstOwnerReference() { return this.ownerReferences.get(0).build(); } + public io.kubernetes.client.openapi.models.V1OwnerReference buildLastOwnerReference() { return this.ownerReferences.get(ownerReferences.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1OwnerReference buildMatchingOwnerReference(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder item: ownerReferences) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1OwnerReference buildMatchingOwnerReference( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder item : ownerReferences) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingOwnerReference(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder item: ownerReferences) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingOwnerReference( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder item : ownerReferences) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withOwnerReferences(java.util.List ownerReferences) { - if (this.ownerReferences != null) { _visitables.get("ownerReferences").removeAll(this.ownerReferences);} - if (ownerReferences != null) {this.ownerReferences = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1OwnerReference item : ownerReferences){this.addToOwnerReferences(item);}} else { this.ownerReferences = null;} return (A) this; + + public A withOwnerReferences( + java.util.List ownerReferences) { + if (this.ownerReferences != null) { + _visitables.get("ownerReferences").removeAll(this.ownerReferences); + } + if (ownerReferences != null) { + this.ownerReferences = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1OwnerReference item : ownerReferences) { + this.addToOwnerReferences(item); + } + } else { + this.ownerReferences = null; + } + return (A) this; } - public A withOwnerReferences(io.kubernetes.client.openapi.models.V1OwnerReference... ownerReferences) { - if (this.ownerReferences != null) {this.ownerReferences.clear();} - if (ownerReferences != null) {for (io.kubernetes.client.openapi.models.V1OwnerReference item :ownerReferences){ this.addToOwnerReferences(item);}} return (A) this; + + public A withOwnerReferences( + io.kubernetes.client.openapi.models.V1OwnerReference... ownerReferences) { + if (this.ownerReferences != null) { + this.ownerReferences.clear(); + } + if (ownerReferences != null) { + for (io.kubernetes.client.openapi.models.V1OwnerReference item : ownerReferences) { + this.addToOwnerReferences(item); + } + } + return (A) this; } + public java.lang.Boolean hasOwnerReferences() { return ownerReferences != null && !ownerReferences.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested addNewOwnerReference() { - return new io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl.OwnerReferencesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + addNewOwnerReference() { + return new io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl + .OwnerReferencesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested addNewOwnerReferenceLike(io.kubernetes.client.openapi.models.V1OwnerReference item) { - return new io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl.OwnerReferencesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + addNewOwnerReferenceLike(io.kubernetes.client.openapi.models.V1OwnerReference item) { + return new io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl.OwnerReferencesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested setNewOwnerReferenceLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1OwnerReference item) { - return new io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl.OwnerReferencesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + setNewOwnerReferenceLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1OwnerReference item) { + return new io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl.OwnerReferencesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested editOwnerReference(java.lang.Integer index) { - if (ownerReferences.size() <= index) throw new RuntimeException("Can't edit ownerReferences. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + editOwnerReference(java.lang.Integer index) { + if (ownerReferences.size() <= index) + throw new RuntimeException("Can't edit ownerReferences. Index exceeds size."); return setNewOwnerReferenceLike(index, buildOwnerReference(index)); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested editFirstOwnerReference() { - if (ownerReferences.size() == 0) throw new RuntimeException("Can't edit first ownerReferences. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + editFirstOwnerReference() { + if (ownerReferences.size() == 0) + throw new RuntimeException("Can't edit first ownerReferences. The list is empty."); return setNewOwnerReferenceLike(0, buildOwnerReference(0)); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested editLastOwnerReference() { + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + editLastOwnerReference() { int index = ownerReferences.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last ownerReferences. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last ownerReferences. The list is empty."); return setNewOwnerReferenceLike(index, buildOwnerReference(index)); } - public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested editMatchingOwnerReference(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested + editMatchingOwnerReference( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluentImpl> implements io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested,io.kubernetes.client.fluent.Nested{ - ManagedFieldsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item) { + + public class ManagedFieldsNestedImpl + extends io.kubernetes.client.openapi.models.V1ManagedFieldsEntryFluentImpl< + io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested> + implements io.kubernetes.client.openapi.models.V1ObjectMetaFluent.ManagedFieldsNested, + io.kubernetes.client.fluent.Nested { + ManagedFieldsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ManagedFieldsEntry item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(this, item); } + ManagedFieldsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder(this); } + io.kubernetes.client.openapi.models.V1ManagedFieldsEntryBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ObjectMetaFluentImpl.this.setToManagedFields(index,builder.build()); + return (N) V1ObjectMetaFluentImpl.this.setToManagedFields(index, builder.build()); } + public N endManagedField() { return and(); } - } - public class OwnerReferencesNestedImpl extends io.kubernetes.client.openapi.models.V1OwnerReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested,io.kubernetes.client.fluent.Nested{ - OwnerReferencesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1OwnerReference item) { + + public class OwnerReferencesNestedImpl + extends io.kubernetes.client.openapi.models.V1OwnerReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested> + implements io.kubernetes.client.openapi.models.V1ObjectMetaFluent.OwnerReferencesNested, + io.kubernetes.client.fluent.Nested { + OwnerReferencesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1OwnerReference item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(this, item); } + OwnerReferencesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ObjectMetaFluentImpl.this.setToOwnerReferences(index,builder.build()); + return (N) V1ObjectMetaFluentImpl.this.setToOwnerReferences(index, builder.build()); } + public N endOwnerReference() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectReferenceBuilder.java index 26ea0f8306..36919ba5a3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectReferenceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ObjectReferenceBuilder extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ObjectReferenceBuilder + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ObjectReference, + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder> { public V1ObjectReferenceBuilder() { this(false); } + public V1ObjectReferenceBuilder(java.lang.Boolean validationEnabled) { this(new V1ObjectReference(), validationEnabled); } - public V1ObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1ObjectReferenceFluent fluent) { + + public V1ObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent fluent) { this(fluent, false); } - public V1ObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1ObjectReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ObjectReference(), validationEnabled); } - public V1ObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1ObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V1ObjectReference instance) { + + public V1ObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1ObjectReference instance) { this(fluent, instance, false); } - public V1ObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1ObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V1ObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1ObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withFieldPath(instance.getFieldPath()); @@ -35,13 +62,17 @@ public V1ObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1ObjectRefe fluent.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1ObjectReference instance) { - this(instance,false); + this(instance, false); } - public V1ObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1ObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1ObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withFieldPath(instance.getFieldPath()); @@ -56,10 +87,12 @@ public V1ObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1ObjectRefe this.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ObjectReference build() { V1ObjectReference buildable = new V1ObjectReference(); buildable.setApiVersion(fluent.getApiVersion()); @@ -71,18 +104,23 @@ public io.kubernetes.client.openapi.models.V1ObjectReference build() { buildable.setUid(fluent.getUid()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ObjectReferenceBuilder that = (V1ObjectReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectReferenceFluent.java index 5ccd2b4bb6..60031ff9ad 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectReferenceFluent.java @@ -1,77 +1,88 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ObjectReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ObjectReferenceFluent< + A extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getFieldPath(); + public A withFieldPath(java.lang.String fieldPath); + public java.lang.Boolean hasFieldPath(); - - /** - * Method is deprecated. use withFieldPath instead. - */ + + /** Method is deprecated. use withFieldPath instead. */ @java.lang.Deprecated public A withNewFieldPath(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getNamespace(); + public A withNamespace(java.lang.String namespace); + public java.lang.Boolean hasNamespace(); - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original); + public java.lang.String getResourceVersion(); + public A withResourceVersion(java.lang.String resourceVersion); + public java.lang.Boolean hasResourceVersion(); - - /** - * Method is deprecated. use withResourceVersion instead. - */ + + /** Method is deprecated. use withResourceVersion instead. */ @java.lang.Deprecated public A withNewResourceVersion(java.lang.String original); + public java.lang.String getUid(); + public A withUid(java.lang.String uid); + public java.lang.Boolean hasUid(); - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectReferenceFluentImpl.java index 2abf2253aa..9150cd9910 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ObjectReferenceFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ObjectReferenceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ObjectReferenceFluent { + public V1ObjectReferenceFluentImpl() {} - /** - * Generated - */ -public class V1ObjectReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ObjectReferenceFluent{ - public V1ObjectReferenceFluentImpl() { - } - public V1ObjectReferenceFluentImpl(io.kubernetes.client.openapi.models.V1ObjectReference instance) { + public V1ObjectReferenceFluentImpl( + io.kubernetes.client.openapi.models.V1ObjectReference instance) { this.withApiVersion(instance.getApiVersion()); this.withFieldPath(instance.getFieldPath()); @@ -26,8 +34,8 @@ public V1ObjectReferenceFluentImpl(io.kubernetes.client.openapi.models.V1ObjectR this.withResourceVersion(instance.getResourceVersion()); this.withUid(instance.getUid()); - } + private java.lang.String apiVersion; private java.lang.String fieldPath; private java.lang.String kind; @@ -35,140 +43,161 @@ public V1ObjectReferenceFluentImpl(io.kubernetes.client.openapi.models.V1ObjectR private java.lang.String namespace; private java.lang.String resourceVersion; private java.lang.String uid; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getFieldPath() { return this.fieldPath; } + public A withFieldPath(java.lang.String fieldPath) { - this.fieldPath=fieldPath; return (A) this; + this.fieldPath = fieldPath; + return (A) this; } + public java.lang.Boolean hasFieldPath() { return this.fieldPath != null; } - - /** - * Method is deprecated. use withFieldPath instead. - */ + + /** Method is deprecated. use withFieldPath instead. */ @java.lang.Deprecated public A withNewFieldPath(java.lang.String original) { - return (A)withFieldPath(new String(original)); + return (A) withFieldPath(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getNamespace() { return this.namespace; } + public A withNamespace(java.lang.String namespace) { - this.namespace=namespace; return (A) this; + this.namespace = namespace; + return (A) this; } + public java.lang.Boolean hasNamespace() { return this.namespace != null; } - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original) { - return (A)withNamespace(new String(original)); + return (A) withNamespace(new String(original)); } + public java.lang.String getResourceVersion() { return this.resourceVersion; } + public A withResourceVersion(java.lang.String resourceVersion) { - this.resourceVersion=resourceVersion; return (A) this; + this.resourceVersion = resourceVersion; + return (A) this; } + public java.lang.Boolean hasResourceVersion() { return this.resourceVersion != null; } - - /** - * Method is deprecated. use withResourceVersion instead. - */ + + /** Method is deprecated. use withResourceVersion instead. */ @java.lang.Deprecated public A withNewResourceVersion(java.lang.String original) { - return (A)withResourceVersion(new String(original)); + return (A) withResourceVersion(new String(original)); } + public java.lang.String getUid() { return this.uid; } + public A withUid(java.lang.String uid) { - this.uid=uid; return (A) this; + this.uid = uid; + return (A) this; } + public java.lang.Boolean hasUid() { return this.uid != null; } - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original) { - return (A)withUid(new String(original)); + return (A) withUid(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ObjectReferenceFluentImpl that = (V1ObjectReferenceFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (fieldPath != null ? !fieldPath.equals(that.fieldPath) :that.fieldPath != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (namespace != null ? !namespace.equals(that.namespace) :that.namespace != null) return false; - if (resourceVersion != null ? !resourceVersion.equals(that.resourceVersion) :that.resourceVersion != null) return false; - if (uid != null ? !uid.equals(that.uid) :that.uid != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (fieldPath != null ? !fieldPath.equals(that.fieldPath) : that.fieldPath != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (namespace != null ? !namespace.equals(that.namespace) : that.namespace != null) + return false; + if (resourceVersion != null + ? !resourceVersion.equals(that.resourceVersion) + : that.resourceVersion != null) return false; + if (uid != null ? !uid.equals(that.uid) : that.uid != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, fieldPath, kind, name, namespace, resourceVersion, uid, super.hashCode()); + return java.util.Objects.hash( + apiVersion, fieldPath, kind, name, namespace, resourceVersion, uid, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OverheadBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OverheadBuilder.java index 3514282df1..af399fbada 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OverheadBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OverheadBuilder.java @@ -1,58 +1,95 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1OverheadBuilder extends io.kubernetes.client.openapi.models.V1OverheadFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1OverheadBuilder + extends io.kubernetes.client.openapi.models.V1OverheadFluentImpl< + io.kubernetes.client.openapi.models.V1OverheadBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Overhead, + io.kubernetes.client.openapi.models.V1OverheadBuilder> { public V1OverheadBuilder() { this(false); } + public V1OverheadBuilder(java.lang.Boolean validationEnabled) { this(new V1Overhead(), validationEnabled); } + public V1OverheadBuilder(io.kubernetes.client.openapi.models.V1OverheadFluent fluent) { this(fluent, false); } - public V1OverheadBuilder(io.kubernetes.client.openapi.models.V1OverheadFluent fluent,java.lang.Boolean validationEnabled) { + + public V1OverheadBuilder( + io.kubernetes.client.openapi.models.V1OverheadFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Overhead(), validationEnabled); } - public V1OverheadBuilder(io.kubernetes.client.openapi.models.V1OverheadFluent fluent,io.kubernetes.client.openapi.models.V1Overhead instance) { + + public V1OverheadBuilder( + io.kubernetes.client.openapi.models.V1OverheadFluent fluent, + io.kubernetes.client.openapi.models.V1Overhead instance) { this(fluent, instance, false); } - public V1OverheadBuilder(io.kubernetes.client.openapi.models.V1OverheadFluent fluent,io.kubernetes.client.openapi.models.V1Overhead instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1OverheadBuilder( + io.kubernetes.client.openapi.models.V1OverheadFluent fluent, + io.kubernetes.client.openapi.models.V1Overhead instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPodFixed(instance.getPodFixed()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1OverheadBuilder(io.kubernetes.client.openapi.models.V1Overhead instance) { - this(instance,false); + this(instance, false); } - public V1OverheadBuilder(io.kubernetes.client.openapi.models.V1Overhead instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1OverheadBuilder( + io.kubernetes.client.openapi.models.V1Overhead instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPodFixed(instance.getPodFixed()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1OverheadFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Overhead build() { V1Overhead buildable = new V1Overhead(); buildable.setPodFixed(fluent.getPodFixed()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1OverheadBuilder that = (V1OverheadBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OverheadFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OverheadFluent.java index ece4b54ce9..3760f462de 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OverheadFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OverheadFluent.java @@ -1,23 +1,33 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; -import java.util.Map; -import java.util.LinkedHashMap; +/** Generated */ +public interface V1OverheadFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToPodFixed(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToPodFixed(java.util.Map map); - /** - * Generated - */ -public interface V1OverheadFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToPodFixed(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToPodFixed(java.util.Map map); public A removeFromPodFixed(java.lang.String key); - public A removeFromPodFixed(java.util.Map map); - public java.util.Map getPodFixed(); - public A withPodFixed(java.util.Map podFixed); + + public A removeFromPodFixed( + java.util.Map map); + + public java.util.Map getPodFixed(); + + public A withPodFixed( + java.util.Map podFixed); + public java.lang.Boolean hasPodFixed(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OverheadFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OverheadFluentImpl.java index af672b5bdc..126b8bc000 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OverheadFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OverheadFluentImpl.java @@ -1,58 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.BaseFluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; -import java.util.Map; -import java.util.LinkedHashMap; +/** Generated */ +public class V1OverheadFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1OverheadFluent { + public V1OverheadFluentImpl() {} - /** - * Generated - */ -public class V1OverheadFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1OverheadFluent{ - public V1OverheadFluentImpl() { - } public V1OverheadFluentImpl(io.kubernetes.client.openapi.models.V1Overhead instance) { this.withPodFixed(instance.getPodFixed()); - } - private java.util.Map podFixed; - public A addToPodFixed(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.podFixed == null && key != null && value != null) { this.podFixed = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.podFixed.put(key, value);} return (A)this; + + private java.util.Map podFixed; + + public A addToPodFixed(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.podFixed == null && key != null && value != null) { + this.podFixed = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.podFixed.put(key, value); + } + return (A) this; } - public A addToPodFixed(java.util.Map map) { - if(this.podFixed == null && map != null) { this.podFixed = new java.util.LinkedHashMap(); } - if(map != null) { this.podFixed.putAll(map);} return (A)this; + + public A addToPodFixed( + java.util.Map map) { + if (this.podFixed == null && map != null) { + this.podFixed = new java.util.LinkedHashMap(); + } + if (map != null) { + this.podFixed.putAll(map); + } + return (A) this; } + public A removeFromPodFixed(java.lang.String key) { - if(this.podFixed == null) { return (A) this; } - if(key != null && this.podFixed != null) {this.podFixed.remove(key);} return (A)this; + if (this.podFixed == null) { + return (A) this; + } + if (key != null && this.podFixed != null) { + this.podFixed.remove(key); + } + return (A) this; } - public A removeFromPodFixed(java.util.Map map) { - if(this.podFixed == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.podFixed != null){this.podFixed.remove(key);}}} return (A)this; + + public A removeFromPodFixed( + java.util.Map map) { + if (this.podFixed == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.podFixed != null) { + this.podFixed.remove(key); + } + } + } + return (A) this; } - public java.util.Map getPodFixed() { + + public java.util.Map getPodFixed() { return this.podFixed; } - public A withPodFixed(java.util.Map podFixed) { - if (podFixed == null) { this.podFixed = null;} else {this.podFixed = new java.util.LinkedHashMap(podFixed);} return (A) this; + + public A withPodFixed( + java.util.Map podFixed) { + if (podFixed == null) { + this.podFixed = null; + } else { + this.podFixed = new java.util.LinkedHashMap(podFixed); + } + return (A) this; } + public java.lang.Boolean hasPodFixed() { return this.podFixed != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1OverheadFluentImpl that = (V1OverheadFluentImpl) o; - if (podFixed != null ? !podFixed.equals(that.podFixed) :that.podFixed != null) return false; + if (podFixed != null ? !podFixed.equals(that.podFixed) : that.podFixed != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(podFixed, super.hashCode()); + return java.util.Objects.hash(podFixed, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OwnerReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OwnerReferenceBuilder.java index 392aa1e7ce..c0877c3267 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OwnerReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OwnerReferenceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1OwnerReferenceBuilder extends io.kubernetes.client.openapi.models.V1OwnerReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1OwnerReferenceBuilder + extends io.kubernetes.client.openapi.models.V1OwnerReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1OwnerReference, + io.kubernetes.client.openapi.models.V1OwnerReferenceBuilder> { public V1OwnerReferenceBuilder() { this(false); } + public V1OwnerReferenceBuilder(java.lang.Boolean validationEnabled) { this(new V1OwnerReference(), validationEnabled); } - public V1OwnerReferenceBuilder(io.kubernetes.client.openapi.models.V1OwnerReferenceFluent fluent) { + + public V1OwnerReferenceBuilder( + io.kubernetes.client.openapi.models.V1OwnerReferenceFluent fluent) { this(fluent, false); } - public V1OwnerReferenceBuilder(io.kubernetes.client.openapi.models.V1OwnerReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1OwnerReferenceBuilder( + io.kubernetes.client.openapi.models.V1OwnerReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1OwnerReference(), validationEnabled); } - public V1OwnerReferenceBuilder(io.kubernetes.client.openapi.models.V1OwnerReferenceFluent fluent,io.kubernetes.client.openapi.models.V1OwnerReference instance) { + + public V1OwnerReferenceBuilder( + io.kubernetes.client.openapi.models.V1OwnerReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1OwnerReference instance) { this(fluent, instance, false); } - public V1OwnerReferenceBuilder(io.kubernetes.client.openapi.models.V1OwnerReferenceFluent fluent,io.kubernetes.client.openapi.models.V1OwnerReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1OwnerReferenceBuilder( + io.kubernetes.client.openapi.models.V1OwnerReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1OwnerReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withBlockOwnerDeletion(instance.getBlockOwnerDeletion()); @@ -33,13 +60,17 @@ public V1OwnerReferenceBuilder(io.kubernetes.client.openapi.models.V1OwnerRefere fluent.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1OwnerReferenceBuilder(io.kubernetes.client.openapi.models.V1OwnerReference instance) { - this(instance,false); + this(instance, false); } - public V1OwnerReferenceBuilder(io.kubernetes.client.openapi.models.V1OwnerReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1OwnerReferenceBuilder( + io.kubernetes.client.openapi.models.V1OwnerReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withBlockOwnerDeletion(instance.getBlockOwnerDeletion()); @@ -52,10 +83,12 @@ public V1OwnerReferenceBuilder(io.kubernetes.client.openapi.models.V1OwnerRefere this.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1OwnerReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1OwnerReference build() { V1OwnerReference buildable = new V1OwnerReference(); buildable.setApiVersion(fluent.getApiVersion()); @@ -66,18 +99,23 @@ public io.kubernetes.client.openapi.models.V1OwnerReference build() { buildable.setUid(fluent.getUid()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1OwnerReferenceBuilder that = (V1OwnerReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OwnerReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OwnerReferenceFluent.java index ea75a0b948..ac47acfae3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OwnerReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OwnerReferenceFluent.java @@ -1,56 +1,70 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1OwnerReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1OwnerReferenceFluent< + A extends io.kubernetes.client.openapi.models.V1OwnerReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.Boolean getBlockOwnerDeletion(); + public A withBlockOwnerDeletion(java.lang.Boolean blockOwnerDeletion); + public java.lang.Boolean hasBlockOwnerDeletion(); + public java.lang.Boolean getController(); + public A withController(java.lang.Boolean controller); + public java.lang.Boolean hasController(); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getUid(); + public A withUid(java.lang.String uid); + public java.lang.Boolean hasUid(); - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OwnerReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OwnerReferenceFluentImpl.java index ef96d54670..93aba6287c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OwnerReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1OwnerReferenceFluentImpl.java @@ -1,17 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1OwnerReferenceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1OwnerReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1OwnerReferenceFluent { + public V1OwnerReferenceFluentImpl() {} - /** - * Generated - */ -public class V1OwnerReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1OwnerReferenceFluent{ - public V1OwnerReferenceFluentImpl() { - } public V1OwnerReferenceFluentImpl(io.kubernetes.client.openapi.models.V1OwnerReference instance) { this.withApiVersion(instance.getApiVersion()); @@ -24,114 +31,136 @@ public V1OwnerReferenceFluentImpl(io.kubernetes.client.openapi.models.V1OwnerRef this.withName(instance.getName()); this.withUid(instance.getUid()); - } + private java.lang.String apiVersion; private java.lang.Boolean blockOwnerDeletion; private java.lang.Boolean controller; private java.lang.String kind; private java.lang.String name; private java.lang.String uid; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.Boolean getBlockOwnerDeletion() { return this.blockOwnerDeletion; } + public A withBlockOwnerDeletion(java.lang.Boolean blockOwnerDeletion) { - this.blockOwnerDeletion=blockOwnerDeletion; return (A) this; + this.blockOwnerDeletion = blockOwnerDeletion; + return (A) this; } + public java.lang.Boolean hasBlockOwnerDeletion() { return this.blockOwnerDeletion != null; } + public java.lang.Boolean getController() { return this.controller; } + public A withController(java.lang.Boolean controller) { - this.controller=controller; return (A) this; + this.controller = controller; + return (A) this; } + public java.lang.Boolean hasController() { return this.controller != null; } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getUid() { return this.uid; } + public A withUid(java.lang.String uid) { - this.uid=uid; return (A) this; + this.uid = uid; + return (A) this; } + public java.lang.Boolean hasUid() { return this.uid != null; } - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original) { - return (A)withUid(new String(original)); + return (A) withUid(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1OwnerReferenceFluentImpl that = (V1OwnerReferenceFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (blockOwnerDeletion != null ? !blockOwnerDeletion.equals(that.blockOwnerDeletion) :that.blockOwnerDeletion != null) return false; - if (controller != null ? !controller.equals(that.controller) :that.controller != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (uid != null ? !uid.equals(that.uid) :that.uid != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (blockOwnerDeletion != null + ? !blockOwnerDeletion.equals(that.blockOwnerDeletion) + : that.blockOwnerDeletion != null) return false; + if (controller != null ? !controller.equals(that.controller) : that.controller != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (uid != null ? !uid.equals(that.uid) : that.uid != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, blockOwnerDeletion, controller, kind, name, uid, super.hashCode()); + return java.util.Objects.hash( + apiVersion, blockOwnerDeletion, controller, kind, name, uid, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeBuilder.java index 3674fff793..c0ed27f97e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PersistentVolumeBuilder extends io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PersistentVolumeBuilder + extends io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PersistentVolume, + io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder> { public V1PersistentVolumeBuilder() { this(false); } + public V1PersistentVolumeBuilder(java.lang.Boolean validationEnabled) { this(new V1PersistentVolume(), validationEnabled); } - public V1PersistentVolumeBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeFluent fluent) { + + public V1PersistentVolumeBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeFluent fluent) { this(fluent, false); } - public V1PersistentVolumeBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PersistentVolumeBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PersistentVolume(), validationEnabled); } - public V1PersistentVolumeBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolume instance) { + + public V1PersistentVolumeBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolume instance) { this(fluent, instance, false); } - public V1PersistentVolumeBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolume instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PersistentVolumeBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolume instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1PersistentVolumeBuilder(io.kubernetes.client.openapi.models.V1Persisten fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PersistentVolumeBuilder(io.kubernetes.client.openapi.models.V1PersistentVolume instance) { - this(instance,false); + + public V1PersistentVolumeBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolume instance) { + this(instance, false); } - public V1PersistentVolumeBuilder(io.kubernetes.client.openapi.models.V1PersistentVolume instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PersistentVolumeBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolume instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1PersistentVolumeBuilder(io.kubernetes.client.openapi.models.V1Persisten this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PersistentVolumeFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PersistentVolume build() { V1PersistentVolume buildable = new V1PersistentVolume(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1PersistentVolume build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PersistentVolumeBuilder that = (V1PersistentVolumeBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimBuilder.java index d18f60147b..64a9519532 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PersistentVolumeClaimBuilder extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PersistentVolumeClaimBuilder + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> { public V1PersistentVolumeClaimBuilder() { this(false); } + public V1PersistentVolumeClaimBuilder(java.lang.Boolean validationEnabled) { this(new V1PersistentVolumeClaim(), validationEnabled); } - public V1PersistentVolumeClaimBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent fluent) { + + public V1PersistentVolumeClaimBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent fluent) { this(fluent, false); } - public V1PersistentVolumeClaimBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PersistentVolumeClaimBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PersistentVolumeClaim(), validationEnabled); } - public V1PersistentVolumeClaimBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim instance) { + + public V1PersistentVolumeClaimBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim instance) { this(fluent, instance, false); } - public V1PersistentVolumeClaimBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PersistentVolumeClaimBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1PersistentVolumeClaimBuilder(io.kubernetes.client.openapi.models.V1Pers fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PersistentVolumeClaimBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim instance) { - this(instance,false); + + public V1PersistentVolumeClaimBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim instance) { + this(instance, false); } - public V1PersistentVolumeClaimBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PersistentVolumeClaimBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1PersistentVolumeClaimBuilder(io.kubernetes.client.openapi.models.V1Pers this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim build() { V1PersistentVolumeClaim buildable = new V1PersistentVolumeClaim(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PersistentVolumeClaimBuilder that = (V1PersistentVolumeClaimBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimConditionBuilder.java index e01a6d610d..8a10cf7fe6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PersistentVolumeClaimConditionBuilder extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PersistentVolumeClaimConditionBuilder + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder> { public V1PersistentVolumeClaimConditionBuilder() { this(false); } + public V1PersistentVolumeClaimConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1PersistentVolumeClaimCondition(), validationEnabled); } - public V1PersistentVolumeClaimConditionBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent fluent) { + + public V1PersistentVolumeClaimConditionBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent fluent) { this(fluent, false); } - public V1PersistentVolumeClaimConditionBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PersistentVolumeClaimConditionBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PersistentVolumeClaimCondition(), validationEnabled); } - public V1PersistentVolumeClaimConditionBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition instance) { + + public V1PersistentVolumeClaimConditionBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition instance) { this(fluent, instance, false); } - public V1PersistentVolumeClaimConditionBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PersistentVolumeClaimConditionBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastProbeTime(instance.getLastProbeTime()); fluent.withLastTransitionTime(instance.getLastTransitionTime()); @@ -33,13 +60,18 @@ public V1PersistentVolumeClaimConditionBuilder(io.kubernetes.client.openapi.mode fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PersistentVolumeClaimConditionBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition instance) { - this(instance,false); + + public V1PersistentVolumeClaimConditionBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition instance) { + this(instance, false); } - public V1PersistentVolumeClaimConditionBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PersistentVolumeClaimConditionBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastProbeTime(instance.getLastProbeTime()); this.withLastTransitionTime(instance.getLastTransitionTime()); @@ -52,10 +84,12 @@ public V1PersistentVolumeClaimConditionBuilder(io.kubernetes.client.openapi.mode this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition build() { V1PersistentVolumeClaimCondition buildable = new V1PersistentVolumeClaimCondition(); buildable.setLastProbeTime(fluent.getLastProbeTime()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition buil buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PersistentVolumeClaimConditionBuilder that = (V1PersistentVolumeClaimConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimConditionFluent.java index 0aa781bcc4..a5919d6983 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimConditionFluent.java @@ -1,51 +1,67 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PersistentVolumeClaimConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PersistentVolumeClaimConditionFluent< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastProbeTime(); + public A withLastProbeTime(java.time.OffsetDateTime lastProbeTime); + public java.lang.Boolean hasLastProbeTime(); + public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition.TypeEnum getType(); - public A withType(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition.TypeEnum type); + + public A withType( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition.TypeEnum type); + public java.lang.Boolean hasType(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimConditionFluentImpl.java index 2acaf64966..0aa7c9d3c3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimConditionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1PersistentVolumeClaimConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent { + public V1PersistentVolumeClaimConditionFluentImpl() {} - /** - * Generated - */ -public class V1PersistentVolumeClaimConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent{ - public V1PersistentVolumeClaimConditionFluentImpl() { - } - public V1PersistentVolumeClaimConditionFluentImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition instance) { + public V1PersistentVolumeClaimConditionFluentImpl( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition instance) { this.withLastProbeTime(instance.getLastProbeTime()); this.withLastTransitionTime(instance.getLastTransitionTime()); @@ -25,106 +32,132 @@ public V1PersistentVolumeClaimConditionFluentImpl(io.kubernetes.client.openapi.m this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastProbeTime; private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition.TypeEnum type; + public java.time.OffsetDateTime getLastProbeTime() { return this.lastProbeTime; } + public A withLastProbeTime(java.time.OffsetDateTime lastProbeTime) { - this.lastProbeTime=lastProbeTime; return (A) this; + this.lastProbeTime = lastProbeTime; + return (A) this; } + public java.lang.Boolean hasLastProbeTime() { return this.lastProbeTime != null; } + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition.TypeEnum getType() { return this.type; } - public A withType(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition.TypeEnum type) { - this.type=type; return (A) this; + + public A withType( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition.TypeEnum type) { + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1PersistentVolumeClaimConditionFluentImpl that = (V1PersistentVolumeClaimConditionFluentImpl) o; - if (lastProbeTime != null ? !lastProbeTime.equals(that.lastProbeTime) :that.lastProbeTime != null) return false; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + V1PersistentVolumeClaimConditionFluentImpl that = + (V1PersistentVolumeClaimConditionFluentImpl) o; + if (lastProbeTime != null + ? !lastProbeTime.equals(that.lastProbeTime) + : that.lastProbeTime != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastProbeTime, lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastProbeTime, lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimFluent.java index 2b9b2101a2..4d739f1671 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimFluent.java @@ -1,93 +1,151 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PersistentVolumeClaimFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PersistentVolumeClaimFluent< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec getSpec(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item); + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus getStatus(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimFluentImpl.java index 343d55c112..45f441e7ec 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1PersistentVolumeClaimFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent { + public V1PersistentVolumeClaimFluentImpl() {} - /** - * Generated - */ -public class V1PersistentVolumeClaimFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent{ - public V1PersistentVolumeClaimFluentImpl() { - } - public V1PersistentVolumeClaimFluentImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim instance) { + public V1PersistentVolumeClaimFluentImpl( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,316 @@ public V1PersistentVolumeClaimFluentImpl(io.kubernetes.client.openapi.models.V1P this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder spec; private io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl.SpecNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PersistentVolumeClaimFluentImpl that = (V1PersistentVolumeClaimFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1PersistentVolumeClaimFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder(this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder builder; + public N and() { return (N) V1PersistentVolumeClaimFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusBuilder(this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusBuilder builder; + public N and() { return (N) V1PersistentVolumeClaimFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimListBuilder.java index 2c5e4d0af4..96553bca09 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PersistentVolumeClaimListBuilder extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PersistentVolumeClaimListBuilder + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimList, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListBuilder> { public V1PersistentVolumeClaimListBuilder() { this(false); } + public V1PersistentVolumeClaimListBuilder(java.lang.Boolean validationEnabled) { this(new V1PersistentVolumeClaimList(), validationEnabled); } - public V1PersistentVolumeClaimListBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent fluent) { + + public V1PersistentVolumeClaimListBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent fluent) { this(fluent, false); } - public V1PersistentVolumeClaimListBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PersistentVolumeClaimListBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PersistentVolumeClaimList(), validationEnabled); } - public V1PersistentVolumeClaimListBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimList instance) { + + public V1PersistentVolumeClaimListBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimList instance) { this(fluent, instance, false); } - public V1PersistentVolumeClaimListBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PersistentVolumeClaimListBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1PersistentVolumeClaimListBuilder(io.kubernetes.client.openapi.models.V1 fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PersistentVolumeClaimListBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimList instance) { - this(instance,false); + + public V1PersistentVolumeClaimListBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimList instance) { + this(instance, false); } - public V1PersistentVolumeClaimListBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PersistentVolumeClaimListBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1PersistentVolumeClaimListBuilder(io.kubernetes.client.openapi.models.V1 this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimList build() { V1PersistentVolumeClaimList buildable = new V1PersistentVolumeClaimList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PersistentVolumeClaimListBuilder that = (V1PersistentVolumeClaimListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimListFluent.java index ceb661807c..31cd3809f4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimListFluent.java @@ -1,95 +1,168 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PersistentVolumeClaimListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PersistentVolumeClaimListFluent< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); + public A addToItems(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildFirstItem(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildLastItem(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent>{ + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimListFluentImpl.java index 6cefc16078..5b0163d411 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1PersistentVolumeClaimListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent{ - public V1PersistentVolumeClaimListFluentImpl() { - } - public V1PersistentVolumeClaimListFluentImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimList instance) { + +/** Generated */ +public class V1PersistentVolumeClaimListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent { + public V1PersistentVolumeClaimListFluentImpl() {} + + public V1PersistentVolumeClaimListFluentImpl( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,132 @@ public V1PersistentVolumeClaimListFluentImpl(io.kubernetes.client.openapi.models this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder>(); + } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder>(); + } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = each.next(); @@ -87,174 +165,292 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PersistentVolumeClaimListFluentImpl that = (V1PersistentVolumeClaimListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(this); } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PersistentVolumeClaimListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1PersistentVolumeClaimListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1PersistentVolumeClaimListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimSpecBuilder.java index e75ab53a41..2e5b81ae32 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PersistentVolumeClaimSpecBuilder extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PersistentVolumeClaimSpecBuilder + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder> { public V1PersistentVolumeClaimSpecBuilder() { this(false); } + public V1PersistentVolumeClaimSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1PersistentVolumeClaimSpec(), validationEnabled); } - public V1PersistentVolumeClaimSpecBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent fluent) { + + public V1PersistentVolumeClaimSpecBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent fluent) { this(fluent, false); } - public V1PersistentVolumeClaimSpecBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PersistentVolumeClaimSpecBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PersistentVolumeClaimSpec(), validationEnabled); } - public V1PersistentVolumeClaimSpecBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec instance) { + + public V1PersistentVolumeClaimSpecBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec instance) { this(fluent, instance, false); } - public V1PersistentVolumeClaimSpecBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PersistentVolumeClaimSpecBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAccessModes(instance.getAccessModes()); fluent.withDataSource(instance.getDataSource()); @@ -37,13 +64,18 @@ public V1PersistentVolumeClaimSpecBuilder(io.kubernetes.client.openapi.models.V1 fluent.withVolumeName(instance.getVolumeName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PersistentVolumeClaimSpecBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec instance) { - this(instance,false); + + public V1PersistentVolumeClaimSpecBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec instance) { + this(instance, false); } - public V1PersistentVolumeClaimSpecBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PersistentVolumeClaimSpecBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAccessModes(instance.getAccessModes()); this.withDataSource(instance.getDataSource()); @@ -60,10 +92,12 @@ public V1PersistentVolumeClaimSpecBuilder(io.kubernetes.client.openapi.models.V1 this.withVolumeName(instance.getVolumeName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec build() { V1PersistentVolumeClaimSpec buildable = new V1PersistentVolumeClaimSpec(); buildable.setAccessModes(fluent.getAccessModes()); @@ -76,18 +110,23 @@ public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec build() { buildable.setVolumeName(fluent.getVolumeName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PersistentVolumeClaimSpecBuilder that = (V1PersistentVolumeClaimSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimSpecFluent.java index 55f33e502f..3083406555 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimSpecFluent.java @@ -1,143 +1,249 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1PersistentVolumeClaimSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAccessModes(java.lang.Integer index,java.lang.String item); - public A setToAccessModes(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1PersistentVolumeClaimSpecFluent< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAccessModes(java.lang.Integer index, java.lang.String item); + + public A setToAccessModes(java.lang.Integer index, java.lang.String item); + public A addToAccessModes(java.lang.String... items); + public A addAllToAccessModes(java.util.Collection items); + public A removeFromAccessModes(java.lang.String... items); + public A removeAllFromAccessModes(java.util.Collection items); + public java.util.List getAccessModes(); + public java.lang.String getAccessMode(java.lang.Integer index); + public java.lang.String getFirstAccessMode(); + public java.lang.String getLastAccessMode(); - public java.lang.String getMatchingAccessMode(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAccessMode(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAccessMode( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAccessMode( + java.util.function.Predicate predicate); + public A withAccessModes(java.util.List accessModes); + public A withAccessModes(java.lang.String... accessModes); + public java.lang.Boolean hasAccessModes(); + public A addNewAccessMode(java.lang.String original); - + /** * This method has been deprecated, please use method buildDataSource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference getDataSource(); + public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference buildDataSource(); - public A withDataSource(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference dataSource); + + public A withDataSource( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference dataSource); + public java.lang.Boolean hasDataSource(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested withNewDataSource(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested withNewDataSourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested editDataSource(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested editOrNewDataSource(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested editOrNewDataSourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested + withNewDataSource(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested + withNewDataSourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested + editDataSource(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested + editOrNewDataSource(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested + editOrNewDataSourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item); + /** * This method has been deprecated, please use method buildDataSourceRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference getDataSourceRef(); + public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference buildDataSourceRef(); - public A withDataSourceRef(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference dataSourceRef); + + public A withDataSourceRef( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference dataSourceRef); + public java.lang.Boolean hasDataSourceRef(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested withNewDataSourceRef(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested withNewDataSourceRefLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested editDataSourceRef(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested editOrNewDataSourceRef(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested editOrNewDataSourceRefLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested< + A> + withNewDataSourceRef(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested< + A> + withNewDataSourceRefLike( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested< + A> + editDataSourceRef(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested< + A> + editOrNewDataSourceRef(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested< + A> + editOrNewDataSourceRefLike( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item); + /** * This method has been deprecated, please use method buildResources instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceRequirements getResources(); + public io.kubernetes.client.openapi.models.V1ResourceRequirements buildResources(); + public A withResources(io.kubernetes.client.openapi.models.V1ResourceRequirements resources); + public java.lang.Boolean hasResources(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested withNewResources(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested withNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested editResources(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested editOrNewResources(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested editOrNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested + withNewResources(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested + withNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested + editResources(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested + editOrNewResources(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested + editOrNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item); + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested editSelector(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested + withNewSelector(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested + editSelector(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested + editOrNewSelector(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + public java.lang.String getStorageClassName(); + public A withStorageClassName(java.lang.String storageClassName); + public java.lang.Boolean hasStorageClassName(); - - /** - * Method is deprecated. use withStorageClassName instead. - */ + + /** Method is deprecated. use withStorageClassName instead. */ @java.lang.Deprecated public A withNewStorageClassName(java.lang.String original); + public java.lang.String getVolumeMode(); + public A withVolumeMode(java.lang.String volumeMode); + public java.lang.Boolean hasVolumeMode(); - - /** - * Method is deprecated. use withVolumeMode instead. - */ + + /** Method is deprecated. use withVolumeMode instead. */ @java.lang.Deprecated public A withNewVolumeMode(java.lang.String original); + public java.lang.String getVolumeName(); + public A withVolumeName(java.lang.String volumeName); + public java.lang.Boolean hasVolumeName(); - - /** - * Method is deprecated. use withVolumeName instead. - */ + + /** Method is deprecated. use withVolumeName instead. */ @java.lang.Deprecated public A withNewVolumeName(java.lang.String original); - public interface DataSourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent>{ + + public interface DataSourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent + .DataSourceNested< + N>> { public N and(); + public N endDataSource(); - } - public interface DataSourceRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent>{ + + public interface DataSourceRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent + .DataSourceRefNested< + N>> { public N and(); + public N endDataSourceRef(); - } - public interface ResourcesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent>{ + + public interface ResourcesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested< + N>> { public N and(); + public N endResources(); - } - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested< + N>> { public N and(); + public N endSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimSpecFluentImpl.java index 715d41cef2..6a705f5324 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimSpecFluentImpl.java @@ -1,24 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1PersistentVolumeClaimSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent{ - public V1PersistentVolumeClaimSpecFluentImpl() { - } - public V1PersistentVolumeClaimSpecFluentImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec instance) { +/** Generated */ +public class V1PersistentVolumeClaimSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent { + public V1PersistentVolumeClaimSpecFluentImpl() {} + + public V1PersistentVolumeClaimSpecFluentImpl( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec instance) { this.withAccessModes(instance.getAccessModes()); this.withDataSource(instance.getDataSource()); @@ -34,8 +36,8 @@ public V1PersistentVolumeClaimSpecFluentImpl(io.kubernetes.client.openapi.models this.withVolumeMode(instance.getVolumeMode()); this.withVolumeName(instance.getVolumeName()); - } + private java.util.List accessModes; private io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder dataSource; private io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder dataSourceRef; @@ -44,327 +46,571 @@ public V1PersistentVolumeClaimSpecFluentImpl(io.kubernetes.client.openapi.models private java.lang.String storageClassName; private java.lang.String volumeMode; private java.lang.String volumeName; - public A addToAccessModes(java.lang.Integer index,java.lang.String item) { - if (this.accessModes == null) {this.accessModes = new java.util.ArrayList();} + + public A addToAccessModes(java.lang.Integer index, java.lang.String item) { + if (this.accessModes == null) { + this.accessModes = new java.util.ArrayList(); + } this.accessModes.add(index, item); - return (A)this; + return (A) this; } - public A setToAccessModes(java.lang.Integer index,java.lang.String item) { - if (this.accessModes == null) {this.accessModes = new java.util.ArrayList();} - this.accessModes.set(index, item); return (A)this; + + public A setToAccessModes(java.lang.Integer index, java.lang.String item) { + if (this.accessModes == null) { + this.accessModes = new java.util.ArrayList(); + } + this.accessModes.set(index, item); + return (A) this; } + public A addToAccessModes(java.lang.String... items) { - if (this.accessModes == null) {this.accessModes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.accessModes.add(item);} return (A)this; + if (this.accessModes == null) { + this.accessModes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.accessModes.add(item); + } + return (A) this; } + public A addAllToAccessModes(java.util.Collection items) { - if (this.accessModes == null) {this.accessModes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.accessModes.add(item);} return (A)this; + if (this.accessModes == null) { + this.accessModes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.accessModes.add(item); + } + return (A) this; } + public A removeFromAccessModes(java.lang.String... items) { - for (java.lang.String item : items) {if (this.accessModes!= null){ this.accessModes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.accessModes != null) { + this.accessModes.remove(item); + } + } + return (A) this; } + public A removeAllFromAccessModes(java.util.Collection items) { - for (java.lang.String item : items) {if (this.accessModes!= null){ this.accessModes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.accessModes != null) { + this.accessModes.remove(item); + } + } + return (A) this; } + public java.util.List getAccessModes() { return this.accessModes; } + public java.lang.String getAccessMode(java.lang.Integer index) { return this.accessModes.get(index); } + public java.lang.String getFirstAccessMode() { return this.accessModes.get(0); } + public java.lang.String getLastAccessMode() { return this.accessModes.get(accessModes.size() - 1); } - public java.lang.String getMatchingAccessMode(java.util.function.Predicate predicate) { - for (java.lang.String item: accessModes) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAccessMode( + java.util.function.Predicate predicate) { + for (java.lang.String item : accessModes) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAccessMode(java.util.function.Predicate predicate) { - for (java.lang.String item: accessModes) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAccessMode( + java.util.function.Predicate predicate) { + for (java.lang.String item : accessModes) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAccessModes(java.util.List accessModes) { - if (accessModes != null) {this.accessModes = new java.util.ArrayList(); for (java.lang.String item : accessModes){this.addToAccessModes(item);}} else { this.accessModes = null;} return (A) this; + if (accessModes != null) { + this.accessModes = new java.util.ArrayList(); + for (java.lang.String item : accessModes) { + this.addToAccessModes(item); + } + } else { + this.accessModes = null; + } + return (A) this; } + public A withAccessModes(java.lang.String... accessModes) { - if (this.accessModes != null) {this.accessModes.clear();} - if (accessModes != null) {for (java.lang.String item :accessModes){ this.addToAccessModes(item);}} return (A) this; + if (this.accessModes != null) { + this.accessModes.clear(); + } + if (accessModes != null) { + for (java.lang.String item : accessModes) { + this.addToAccessModes(item); + } + } + return (A) this; } + public java.lang.Boolean hasAccessModes() { return accessModes != null && !accessModes.isEmpty(); } + public A addNewAccessMode(java.lang.String original) { - return (A)addToAccessModes(new String(original)); + return (A) addToAccessModes(new String(original)); } - + /** * This method has been deprecated, please use method buildDataSource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference getDataSource() { - return this.dataSource!=null ?this.dataSource.build():null; + return this.dataSource != null ? this.dataSource.build() : null; } + public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference buildDataSource() { - return this.dataSource!=null ?this.dataSource.build():null; + return this.dataSource != null ? this.dataSource.build() : null; } - public A withDataSource(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference dataSource) { + + public A withDataSource( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference dataSource) { _visitables.get("dataSource").remove(this.dataSource); - if (dataSource!=null){ this.dataSource= new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(dataSource); _visitables.get("dataSource").add(this.dataSource);} return (A) this; + if (dataSource != null) { + this.dataSource = + new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(dataSource); + _visitables.get("dataSource").add(this.dataSource); + } + return (A) this; } + public java.lang.Boolean hasDataSource() { return this.dataSource != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested withNewDataSource() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl.DataSourceNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested + withNewDataSource() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl + .DataSourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested withNewDataSourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl.DataSourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested + withNewDataSourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl + .DataSourceNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested editDataSource() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested + editDataSource() { return withNewDataSourceLike(getDataSource()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested editOrNewDataSource() { - return withNewDataSourceLike(getDataSource() != null ? getDataSource(): new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested + editOrNewDataSource() { + return withNewDataSourceLike( + getDataSource() != null + ? getDataSource() + : new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested editOrNewDataSourceLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { - return withNewDataSourceLike(getDataSource() != null ? getDataSource(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested + editOrNewDataSourceLike( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { + return withNewDataSourceLike(getDataSource() != null ? getDataSource() : item); } - + /** * This method has been deprecated, please use method buildDataSourceRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference getDataSourceRef() { - return this.dataSourceRef!=null ?this.dataSourceRef.build():null; + return this.dataSourceRef != null ? this.dataSourceRef.build() : null; } + public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference buildDataSourceRef() { - return this.dataSourceRef!=null ?this.dataSourceRef.build():null; + return this.dataSourceRef != null ? this.dataSourceRef.build() : null; } - public A withDataSourceRef(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference dataSourceRef) { + + public A withDataSourceRef( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference dataSourceRef) { _visitables.get("dataSourceRef").remove(this.dataSourceRef); - if (dataSourceRef!=null){ this.dataSourceRef= new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(dataSourceRef); _visitables.get("dataSourceRef").add(this.dataSourceRef);} return (A) this; + if (dataSourceRef != null) { + this.dataSourceRef = + new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(dataSourceRef); + _visitables.get("dataSourceRef").add(this.dataSourceRef); + } + return (A) this; } + public java.lang.Boolean hasDataSourceRef() { return this.dataSourceRef != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested withNewDataSourceRef() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl.DataSourceRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested< + A> + withNewDataSourceRef() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl + .DataSourceRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested withNewDataSourceRefLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl.DataSourceRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested< + A> + withNewDataSourceRefLike( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl + .DataSourceRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested editDataSourceRef() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested< + A> + editDataSourceRef() { return withNewDataSourceRefLike(getDataSourceRef()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested editOrNewDataSourceRef() { - return withNewDataSourceRefLike(getDataSourceRef() != null ? getDataSourceRef(): new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested< + A> + editOrNewDataSourceRef() { + return withNewDataSourceRefLike( + getDataSourceRef() != null + ? getDataSourceRef() + : new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested editOrNewDataSourceRefLike(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { - return withNewDataSourceRefLike(getDataSourceRef() != null ? getDataSourceRef(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested< + A> + editOrNewDataSourceRefLike( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { + return withNewDataSourceRefLike(getDataSourceRef() != null ? getDataSourceRef() : item); } - + /** * This method has been deprecated, please use method buildResources instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceRequirements getResources() { - return this.resources!=null ?this.resources.build():null; + return this.resources != null ? this.resources.build() : null; } + public io.kubernetes.client.openapi.models.V1ResourceRequirements buildResources() { - return this.resources!=null ?this.resources.build():null; + return this.resources != null ? this.resources.build() : null; } + public A withResources(io.kubernetes.client.openapi.models.V1ResourceRequirements resources) { _visitables.get("resources").remove(this.resources); - if (resources!=null){ this.resources= new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(resources); _visitables.get("resources").add(this.resources);} return (A) this; + if (resources != null) { + this.resources = + new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(resources); + _visitables.get("resources").add(this.resources); + } + return (A) this; } + public java.lang.Boolean hasResources() { return this.resources != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested withNewResources() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl.ResourcesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested + withNewResources() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl + .ResourcesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested withNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl.ResourcesNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested + withNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl + .ResourcesNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested editResources() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested + editResources() { return withNewResourcesLike(getResources()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested editOrNewResources() { - return withNewResourcesLike(getResources() != null ? getResources(): new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested + editOrNewResources() { + return withNewResourcesLike( + getResources() != null + ? getResources() + : new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested editOrNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { - return withNewResourcesLike(getResources() != null ? getResources(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested + editOrNewResourcesLike(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { + return withNewResourcesLike(getResources() != null ? getResources() : item); } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested withNewSelector() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl.SelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested + withNewSelector() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl + .SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl.SelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl + .SelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested editSelector() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested + editSelector() { return withNewSelectorLike(getSelector()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested + editOrNewSelector() { + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } + public java.lang.String getStorageClassName() { return this.storageClassName; } + public A withStorageClassName(java.lang.String storageClassName) { - this.storageClassName=storageClassName; return (A) this; + this.storageClassName = storageClassName; + return (A) this; } + public java.lang.Boolean hasStorageClassName() { return this.storageClassName != null; } - - /** - * Method is deprecated. use withStorageClassName instead. - */ + + /** Method is deprecated. use withStorageClassName instead. */ @java.lang.Deprecated public A withNewStorageClassName(java.lang.String original) { - return (A)withStorageClassName(new String(original)); + return (A) withStorageClassName(new String(original)); } + public java.lang.String getVolumeMode() { return this.volumeMode; } + public A withVolumeMode(java.lang.String volumeMode) { - this.volumeMode=volumeMode; return (A) this; + this.volumeMode = volumeMode; + return (A) this; } + public java.lang.Boolean hasVolumeMode() { return this.volumeMode != null; } - - /** - * Method is deprecated. use withVolumeMode instead. - */ + + /** Method is deprecated. use withVolumeMode instead. */ @java.lang.Deprecated public A withNewVolumeMode(java.lang.String original) { - return (A)withVolumeMode(new String(original)); + return (A) withVolumeMode(new String(original)); } + public java.lang.String getVolumeName() { return this.volumeName; } + public A withVolumeName(java.lang.String volumeName) { - this.volumeName=volumeName; return (A) this; + this.volumeName = volumeName; + return (A) this; } + public java.lang.Boolean hasVolumeName() { return this.volumeName != null; } - - /** - * Method is deprecated. use withVolumeName instead. - */ + + /** Method is deprecated. use withVolumeName instead. */ @java.lang.Deprecated public A withNewVolumeName(java.lang.String original) { - return (A)withVolumeName(new String(original)); + return (A) withVolumeName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PersistentVolumeClaimSpecFluentImpl that = (V1PersistentVolumeClaimSpecFluentImpl) o; - if (accessModes != null ? !accessModes.equals(that.accessModes) :that.accessModes != null) return false; - if (dataSource != null ? !dataSource.equals(that.dataSource) :that.dataSource != null) return false; - if (dataSourceRef != null ? !dataSourceRef.equals(that.dataSourceRef) :that.dataSourceRef != null) return false; - if (resources != null ? !resources.equals(that.resources) :that.resources != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; - if (storageClassName != null ? !storageClassName.equals(that.storageClassName) :that.storageClassName != null) return false; - if (volumeMode != null ? !volumeMode.equals(that.volumeMode) :that.volumeMode != null) return false; - if (volumeName != null ? !volumeName.equals(that.volumeName) :that.volumeName != null) return false; + if (accessModes != null ? !accessModes.equals(that.accessModes) : that.accessModes != null) + return false; + if (dataSource != null ? !dataSource.equals(that.dataSource) : that.dataSource != null) + return false; + if (dataSourceRef != null + ? !dataSourceRef.equals(that.dataSourceRef) + : that.dataSourceRef != null) return false; + if (resources != null ? !resources.equals(that.resources) : that.resources != null) + return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; + if (storageClassName != null + ? !storageClassName.equals(that.storageClassName) + : that.storageClassName != null) return false; + if (volumeMode != null ? !volumeMode.equals(that.volumeMode) : that.volumeMode != null) + return false; + if (volumeName != null ? !volumeName.equals(that.volumeName) : that.volumeName != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(accessModes, dataSource, dataSourceRef, resources, selector, storageClassName, volumeMode, volumeName, super.hashCode()); + return java.util.Objects.hash( + accessModes, + dataSource, + dataSourceRef, + resources, + selector, + storageClassName, + volumeMode, + volumeName, + super.hashCode()); } - public class DataSourceNestedImpl extends io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested,io.kubernetes.client.fluent.Nested{ + + public class DataSourceNestedImpl + extends io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent + .DataSourceNested< + N>, + io.kubernetes.client.fluent.Nested { DataSourceNestedImpl(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(this, item); } + DataSourceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder builder; + public N and() { return (N) V1PersistentVolumeClaimSpecFluentImpl.this.withDataSource(builder.build()); } + public N endDataSource() { return and(); } - } - public class DataSourceRefNestedImpl extends io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested,io.kubernetes.client.fluent.Nested{ + + public class DataSourceRefNestedImpl + extends io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.DataSourceRefNested< + N>> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent + .DataSourceRefNested< + N>, + io.kubernetes.client.fluent.Nested { DataSourceRefNestedImpl(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(this, item); } + DataSourceRefNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder builder; + public N and() { return (N) V1PersistentVolumeClaimSpecFluentImpl.this.withDataSourceRef(builder.build()); } + public N endDataSourceRef() { return and(); } - } - public class ResourcesNestedImpl extends io.kubernetes.client.openapi.models.V1ResourceRequirementsFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested,io.kubernetes.client.fluent.Nested{ + + public class ResourcesNestedImpl + extends io.kubernetes.client.openapi.models.V1ResourceRequirementsFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.ResourcesNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent + .ResourcesNested< + N>, + io.kubernetes.client.fluent.Nested { ResourcesNestedImpl(io.kubernetes.client.openapi.models.V1ResourceRequirements item) { - this.builder = new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(this, item); } + ResourcesNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder(this); } + io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder builder; + public N and() { return (N) V1PersistentVolumeClaimSpecFluentImpl.this.withResources(builder.build()); } + public N endResources() { return and(); } - } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent.SelectorNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent + .SelectorNested< + N>, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1PersistentVolumeClaimSpecFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimStatusBuilder.java index 1d9ae6ec9d..fc2dbed961 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PersistentVolumeClaimStatusBuilder extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PersistentVolumeClaimStatusBuilder + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusBuilder> { public V1PersistentVolumeClaimStatusBuilder() { this(false); } + public V1PersistentVolumeClaimStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1PersistentVolumeClaimStatus(), validationEnabled); } - public V1PersistentVolumeClaimStatusBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent fluent) { + + public V1PersistentVolumeClaimStatusBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent fluent) { this(fluent, false); } - public V1PersistentVolumeClaimStatusBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PersistentVolumeClaimStatusBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PersistentVolumeClaimStatus(), validationEnabled); } - public V1PersistentVolumeClaimStatusBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus instance) { + + public V1PersistentVolumeClaimStatusBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus instance) { this(fluent, instance, false); } - public V1PersistentVolumeClaimStatusBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PersistentVolumeClaimStatusBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAccessModes(instance.getAccessModes()); fluent.withAllocatedResources(instance.getAllocatedResources()); @@ -33,13 +60,18 @@ public V1PersistentVolumeClaimStatusBuilder(io.kubernetes.client.openapi.models. fluent.withResizeStatus(instance.getResizeStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PersistentVolumeClaimStatusBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus instance) { - this(instance,false); + + public V1PersistentVolumeClaimStatusBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus instance) { + this(instance, false); } - public V1PersistentVolumeClaimStatusBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PersistentVolumeClaimStatusBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAccessModes(instance.getAccessModes()); this.withAllocatedResources(instance.getAllocatedResources()); @@ -52,10 +84,12 @@ public V1PersistentVolumeClaimStatusBuilder(io.kubernetes.client.openapi.models. this.withResizeStatus(instance.getResizeStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus build() { V1PersistentVolumeClaimStatus buildable = new V1PersistentVolumeClaimStatus(); buildable.setAccessModes(fluent.getAccessModes()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus build() buildable.setResizeStatus(fluent.getResizeStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PersistentVolumeClaimStatusBuilder that = (V1PersistentVolumeClaimStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimStatusFluent.java index 9989fc4d11..102e1fd1ba 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimStatusFluent.java @@ -1,102 +1,208 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1PersistentVolumeClaimStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAccessModes(java.lang.Integer index,java.lang.String item); - public A setToAccessModes(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1PersistentVolumeClaimStatusFluent< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAccessModes(java.lang.Integer index, java.lang.String item); + + public A setToAccessModes(java.lang.Integer index, java.lang.String item); + public A addToAccessModes(java.lang.String... items); + public A addAllToAccessModes(java.util.Collection items); + public A removeFromAccessModes(java.lang.String... items); + public A removeAllFromAccessModes(java.util.Collection items); + public java.util.List getAccessModes(); + public java.lang.String getAccessMode(java.lang.Integer index); + public java.lang.String getFirstAccessMode(); + public java.lang.String getLastAccessMode(); - public java.lang.String getMatchingAccessMode(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAccessMode(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAccessMode( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAccessMode( + java.util.function.Predicate predicate); + public A withAccessModes(java.util.List accessModes); + public A withAccessModes(java.lang.String... accessModes); + public java.lang.Boolean hasAccessModes(); + public A addNewAccessMode(java.lang.String original); - public A addToAllocatedResources(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToAllocatedResources(java.util.Map map); + + public A addToAllocatedResources( + java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToAllocatedResources( + java.util.Map map); + public A removeFromAllocatedResources(java.lang.String key); - public A removeFromAllocatedResources(java.util.Map map); - public java.util.Map getAllocatedResources(); - public A withAllocatedResources(java.util.Map allocatedResources); + + public A removeFromAllocatedResources( + java.util.Map map); + + public java.util.Map + getAllocatedResources(); + + public A withAllocatedResources( + java.util.Map allocatedResources); + public java.lang.Boolean hasAllocatedResources(); - public A addToCapacity(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToCapacity(java.util.Map map); + + public A addToCapacity(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToCapacity(java.util.Map map); + public A removeFromCapacity(java.lang.String key); - public A removeFromCapacity(java.util.Map map); - public java.util.Map getCapacity(); - public A withCapacity(java.util.Map capacity); + + public A removeFromCapacity( + java.util.Map map); + + public java.util.Map getCapacity(); + + public A withCapacity( + java.util.Map capacity); + public java.lang.Boolean hasCapacity(); - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item); - public A addToConditions(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition... items); - public A addAllToConditions(java.util.Collection items); - public A removeFromConditions(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item); + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item); + + public A addToConditions( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition... items); + + public A addAllToConditions( + java.util.Collection + items); + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition... items); + + public A removeAllFromConditions( + java.util.Collection + items); + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder> + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition buildCondition(java.lang.Integer index); + public java.util.List + getConditions(); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition buildCondition( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); - public A withConditions(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition... conditions); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder> + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder> + predicate); + + public A withConditions( + java.util.List + conditions); + + public A withConditions( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + addNewConditionLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder> + predicate); + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus.PhaseEnum getPhase(); - public A withPhase(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus.PhaseEnum phase); + + public A withPhase( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus.PhaseEnum phase); + public java.lang.Boolean hasPhase(); + public java.lang.String getResizeStatus(); + public A withResizeStatus(java.lang.String resizeStatus); + public java.lang.Boolean hasResizeStatus(); - - /** - * Method is deprecated. use withResizeStatus instead. - */ + + /** Method is deprecated. use withResizeStatus instead. */ @java.lang.Deprecated public A withNewResizeStatus(java.lang.String original); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent + .ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimStatusFluentImpl.java index 10dc193bb2..e3cbe12a6b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimStatusFluentImpl.java @@ -1,29 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.custom.Quantity; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; -import java.util.Map; - - /** - * Generated - */ -public class V1PersistentVolumeClaimStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent{ - public V1PersistentVolumeClaimStatusFluentImpl() { - } - public V1PersistentVolumeClaimStatusFluentImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus instance) { + +/** Generated */ +public class V1PersistentVolumeClaimStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent { + public V1PersistentVolumeClaimStatusFluentImpl() {} + + public V1PersistentVolumeClaimStatusFluentImpl( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus instance) { this.withAccessModes(instance.getAccessModes()); this.withAllocatedResources(instance.getAllocatedResources()); @@ -35,283 +35,632 @@ public V1PersistentVolumeClaimStatusFluentImpl(io.kubernetes.client.openapi.mode this.withPhase(instance.getPhase()); this.withResizeStatus(instance.getResizeStatus()); - } + private java.util.List accessModes; - private java.util.Map allocatedResources; - private java.util.Map capacity; - private java.util.ArrayList conditions; + private java.util.Map allocatedResources; + private java.util.Map capacity; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder> + conditions; private io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatus.PhaseEnum phase; private java.lang.String resizeStatus; - public A addToAccessModes(java.lang.Integer index,java.lang.String item) { - if (this.accessModes == null) {this.accessModes = new java.util.ArrayList();} + + public A addToAccessModes(java.lang.Integer index, java.lang.String item) { + if (this.accessModes == null) { + this.accessModes = new java.util.ArrayList(); + } this.accessModes.add(index, item); - return (A)this; + return (A) this; } - public A setToAccessModes(java.lang.Integer index,java.lang.String item) { - if (this.accessModes == null) {this.accessModes = new java.util.ArrayList();} - this.accessModes.set(index, item); return (A)this; + + public A setToAccessModes(java.lang.Integer index, java.lang.String item) { + if (this.accessModes == null) { + this.accessModes = new java.util.ArrayList(); + } + this.accessModes.set(index, item); + return (A) this; } + public A addToAccessModes(java.lang.String... items) { - if (this.accessModes == null) {this.accessModes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.accessModes.add(item);} return (A)this; + if (this.accessModes == null) { + this.accessModes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.accessModes.add(item); + } + return (A) this; } + public A addAllToAccessModes(java.util.Collection items) { - if (this.accessModes == null) {this.accessModes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.accessModes.add(item);} return (A)this; + if (this.accessModes == null) { + this.accessModes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.accessModes.add(item); + } + return (A) this; } + public A removeFromAccessModes(java.lang.String... items) { - for (java.lang.String item : items) {if (this.accessModes!= null){ this.accessModes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.accessModes != null) { + this.accessModes.remove(item); + } + } + return (A) this; } + public A removeAllFromAccessModes(java.util.Collection items) { - for (java.lang.String item : items) {if (this.accessModes!= null){ this.accessModes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.accessModes != null) { + this.accessModes.remove(item); + } + } + return (A) this; } + public java.util.List getAccessModes() { return this.accessModes; } + public java.lang.String getAccessMode(java.lang.Integer index) { return this.accessModes.get(index); } + public java.lang.String getFirstAccessMode() { return this.accessModes.get(0); } + public java.lang.String getLastAccessMode() { return this.accessModes.get(accessModes.size() - 1); } - public java.lang.String getMatchingAccessMode(java.util.function.Predicate predicate) { - for (java.lang.String item: accessModes) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAccessMode( + java.util.function.Predicate predicate) { + for (java.lang.String item : accessModes) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAccessMode(java.util.function.Predicate predicate) { - for (java.lang.String item: accessModes) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAccessMode( + java.util.function.Predicate predicate) { + for (java.lang.String item : accessModes) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAccessModes(java.util.List accessModes) { - if (accessModes != null) {this.accessModes = new java.util.ArrayList(); for (java.lang.String item : accessModes){this.addToAccessModes(item);}} else { this.accessModes = null;} return (A) this; + if (accessModes != null) { + this.accessModes = new java.util.ArrayList(); + for (java.lang.String item : accessModes) { + this.addToAccessModes(item); + } + } else { + this.accessModes = null; + } + return (A) this; } + public A withAccessModes(java.lang.String... accessModes) { - if (this.accessModes != null) {this.accessModes.clear();} - if (accessModes != null) {for (java.lang.String item :accessModes){ this.addToAccessModes(item);}} return (A) this; + if (this.accessModes != null) { + this.accessModes.clear(); + } + if (accessModes != null) { + for (java.lang.String item : accessModes) { + this.addToAccessModes(item); + } + } + return (A) this; } + public java.lang.Boolean hasAccessModes() { return accessModes != null && !accessModes.isEmpty(); } + public A addNewAccessMode(java.lang.String original) { - return (A)addToAccessModes(new String(original)); + return (A) addToAccessModes(new String(original)); } - public A addToAllocatedResources(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.allocatedResources == null && key != null && value != null) { this.allocatedResources = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.allocatedResources.put(key, value);} return (A)this; + + public A addToAllocatedResources( + java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.allocatedResources == null && key != null && value != null) { + this.allocatedResources = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.allocatedResources.put(key, value); + } + return (A) this; } - public A addToAllocatedResources(java.util.Map map) { - if(this.allocatedResources == null && map != null) { this.allocatedResources = new java.util.LinkedHashMap(); } - if(map != null) { this.allocatedResources.putAll(map);} return (A)this; + + public A addToAllocatedResources( + java.util.Map map) { + if (this.allocatedResources == null && map != null) { + this.allocatedResources = new java.util.LinkedHashMap(); + } + if (map != null) { + this.allocatedResources.putAll(map); + } + return (A) this; } + public A removeFromAllocatedResources(java.lang.String key) { - if(this.allocatedResources == null) { return (A) this; } - if(key != null && this.allocatedResources != null) {this.allocatedResources.remove(key);} return (A)this; + if (this.allocatedResources == null) { + return (A) this; + } + if (key != null && this.allocatedResources != null) { + this.allocatedResources.remove(key); + } + return (A) this; } - public A removeFromAllocatedResources(java.util.Map map) { - if(this.allocatedResources == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.allocatedResources != null){this.allocatedResources.remove(key);}}} return (A)this; + + public A removeFromAllocatedResources( + java.util.Map map) { + if (this.allocatedResources == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.allocatedResources != null) { + this.allocatedResources.remove(key); + } + } + } + return (A) this; } - public java.util.Map getAllocatedResources() { + + public java.util.Map + getAllocatedResources() { return this.allocatedResources; } - public A withAllocatedResources(java.util.Map allocatedResources) { - if (allocatedResources == null) { this.allocatedResources = null;} else {this.allocatedResources = new java.util.LinkedHashMap(allocatedResources);} return (A) this; + + public A withAllocatedResources( + java.util.Map allocatedResources) { + if (allocatedResources == null) { + this.allocatedResources = null; + } else { + this.allocatedResources = new java.util.LinkedHashMap(allocatedResources); + } + return (A) this; } + public java.lang.Boolean hasAllocatedResources() { return this.allocatedResources != null; } - public A addToCapacity(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.capacity == null && key != null && value != null) { this.capacity = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.capacity.put(key, value);} return (A)this; + + public A addToCapacity(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.capacity == null && key != null && value != null) { + this.capacity = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.capacity.put(key, value); + } + return (A) this; } - public A addToCapacity(java.util.Map map) { - if(this.capacity == null && map != null) { this.capacity = new java.util.LinkedHashMap(); } - if(map != null) { this.capacity.putAll(map);} return (A)this; + + public A addToCapacity( + java.util.Map map) { + if (this.capacity == null && map != null) { + this.capacity = new java.util.LinkedHashMap(); + } + if (map != null) { + this.capacity.putAll(map); + } + return (A) this; } + public A removeFromCapacity(java.lang.String key) { - if(this.capacity == null) { return (A) this; } - if(key != null && this.capacity != null) {this.capacity.remove(key);} return (A)this; + if (this.capacity == null) { + return (A) this; + } + if (key != null && this.capacity != null) { + this.capacity.remove(key); + } + return (A) this; } - public A removeFromCapacity(java.util.Map map) { - if(this.capacity == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.capacity != null){this.capacity.remove(key);}}} return (A)this; + + public A removeFromCapacity( + java.util.Map map) { + if (this.capacity == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.capacity != null) { + this.capacity.remove(key); + } + } + } + return (A) this; } - public java.util.Map getCapacity() { + + public java.util.Map getCapacity() { return this.capacity; } - public A withCapacity(java.util.Map capacity) { - if (capacity == null) { this.capacity = null;} else {this.capacity = new java.util.LinkedHashMap(capacity);} return (A) this; + + public A withCapacity( + java.util.Map capacity) { + if (capacity == null) { + this.capacity = null; + } else { + this.capacity = new java.util.LinkedHashMap(capacity); + } + return (A) this; } + public java.lang.Boolean hasCapacity() { return this.capacity != null; } - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } - public A addToConditions(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addToConditions( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition... items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection + items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition... items) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition... items) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder> + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator + each = conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions() { + public java.util.List + getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition buildFirstCondition() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition + buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List + conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } - public A withConditions(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item :conditions){ this.addToConditions(item);}} return (A) this; + + public A withConditions( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition... conditions) { + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + addNewConditionLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent.ConditionsNested< + N>> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimStatusFluent + .ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder( + this, item); } + ConditionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PersistentVolumeClaimStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) + V1PersistentVolumeClaimStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimTemplateBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimTemplateBuilder.java index 297bc2504c..151d22301b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimTemplateBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimTemplateBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PersistentVolumeClaimTemplateBuilder extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PersistentVolumeClaimTemplateBuilder + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateBuilder> { public V1PersistentVolumeClaimTemplateBuilder() { this(false); } + public V1PersistentVolumeClaimTemplateBuilder(java.lang.Boolean validationEnabled) { this(new V1PersistentVolumeClaimTemplate(), validationEnabled); } - public V1PersistentVolumeClaimTemplateBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent fluent) { + + public V1PersistentVolumeClaimTemplateBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent fluent) { this(fluent, false); } - public V1PersistentVolumeClaimTemplateBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PersistentVolumeClaimTemplateBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PersistentVolumeClaimTemplate(), validationEnabled); } - public V1PersistentVolumeClaimTemplateBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate instance) { + + public V1PersistentVolumeClaimTemplateBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate instance) { this(fluent, instance, false); } - public V1PersistentVolumeClaimTemplateBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PersistentVolumeClaimTemplateBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMetadata(instance.getMetadata()); fluent.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PersistentVolumeClaimTemplateBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate instance) { - this(instance,false); + + public V1PersistentVolumeClaimTemplateBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate instance) { + this(instance, false); } - public V1PersistentVolumeClaimTemplateBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PersistentVolumeClaimTemplateBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate build() { V1PersistentVolumeClaimTemplate buildable = new V1PersistentVolumeClaimTemplate(); buildable.setMetadata(fluent.getMetadata()); buildable.setSpec(fluent.getSpec()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PersistentVolumeClaimTemplateBuilder that = (V1PersistentVolumeClaimTemplateBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimTemplateFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimTemplateFluent.java index 90a4d20c61..5232cdddc6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimTemplateFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimTemplateFluent.java @@ -1,55 +1,98 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PersistentVolumeClaimTemplateFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1PersistentVolumeClaimTemplateFluent< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec getSpec(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested< + N>> { public N and(); + public N endSpec(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimTemplateFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimTemplateFluentImpl.java index 6791c44b25..82cbd83efd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimTemplateFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimTemplateFluentImpl.java @@ -1,135 +1,213 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1PersistentVolumeClaimTemplateFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent { + public V1PersistentVolumeClaimTemplateFluentImpl() {} - /** - * Generated - */ -public class V1PersistentVolumeClaimTemplateFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent{ - public V1PersistentVolumeClaimTemplateFluentImpl() { - } - public V1PersistentVolumeClaimTemplateFluentImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate instance) { + public V1PersistentVolumeClaimTemplateFluentImpl( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplate instance) { this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - } + private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder spec; - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PersistentVolumeClaimTemplateFluentImpl that = (V1PersistentVolumeClaimTemplateFluentImpl) o; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(metadata, spec, super.hashCode()); + return java.util.Objects.hash(metadata, spec, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1PersistentVolumeClaimTemplateFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimTemplateFluent + .SpecNested< + N>, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder(this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimSpecBuilder builder; + public N and() { return (N) V1PersistentVolumeClaimTemplateFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimVolumeSourceBuilder.java index 2b9c451ffb..d8beda8eb8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimVolumeSourceBuilder.java @@ -1,63 +1,103 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PersistentVolumeClaimVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PersistentVolumeClaimVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceBuilder> { public V1PersistentVolumeClaimVolumeSourceBuilder() { this(false); } + public V1PersistentVolumeClaimVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1PersistentVolumeClaimVolumeSource(), validationEnabled); } - public V1PersistentVolumeClaimVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent fluent) { + + public V1PersistentVolumeClaimVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent fluent) { this(fluent, false); } - public V1PersistentVolumeClaimVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PersistentVolumeClaimVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PersistentVolumeClaimVolumeSource(), validationEnabled); } - public V1PersistentVolumeClaimVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource instance) { + + public V1PersistentVolumeClaimVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource instance) { this(fluent, instance, false); } - public V1PersistentVolumeClaimVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PersistentVolumeClaimVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withClaimName(instance.getClaimName()); fluent.withReadOnly(instance.getReadOnly()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PersistentVolumeClaimVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource instance) { - this(instance,false); + + public V1PersistentVolumeClaimVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource instance) { + this(instance, false); } - public V1PersistentVolumeClaimVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PersistentVolumeClaimVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withClaimName(instance.getClaimName()); this.withReadOnly(instance.getReadOnly()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource build() { V1PersistentVolumeClaimVolumeSource buildable = new V1PersistentVolumeClaimVolumeSource(); buildable.setClaimName(fluent.getClaimName()); buildable.setReadOnly(fluent.getReadOnly()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1PersistentVolumeClaimVolumeSourceBuilder that = (V1PersistentVolumeClaimVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1PersistentVolumeClaimVolumeSourceBuilder that = + (V1PersistentVolumeClaimVolumeSourceBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimVolumeSourceFluent.java index a75a216da6..0c91768d64 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimVolumeSourceFluent.java @@ -1,26 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PersistentVolumeClaimVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PersistentVolumeClaimVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getClaimName(); + public A withClaimName(java.lang.String claimName); + public java.lang.Boolean hasClaimName(); - - /** - * Method is deprecated. use withClaimName instead. - */ + + /** Method is deprecated. use withClaimName instead. */ @java.lang.Deprecated public A withNewClaimName(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimVolumeSourceFluentImpl.java index ce47afdf6b..932b07935a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeClaimVolumeSourceFluentImpl.java @@ -1,61 +1,78 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1PersistentVolumeClaimVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent { + public V1PersistentVolumeClaimVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1PersistentVolumeClaimVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent{ - public V1PersistentVolumeClaimVolumeSourceFluentImpl() { - } - public V1PersistentVolumeClaimVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource instance) { + public V1PersistentVolumeClaimVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource instance) { this.withClaimName(instance.getClaimName()); this.withReadOnly(instance.getReadOnly()); - } + private java.lang.String claimName; private java.lang.Boolean readOnly; + public java.lang.String getClaimName() { return this.claimName; } + public A withClaimName(java.lang.String claimName) { - this.claimName=claimName; return (A) this; + this.claimName = claimName; + return (A) this; } + public java.lang.Boolean hasClaimName() { return this.claimName != null; } - - /** - * Method is deprecated. use withClaimName instead. - */ + + /** Method is deprecated. use withClaimName instead. */ @java.lang.Deprecated public A withNewClaimName(java.lang.String original) { - return (A)withClaimName(new String(original)); + return (A) withClaimName(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1PersistentVolumeClaimVolumeSourceFluentImpl that = (V1PersistentVolumeClaimVolumeSourceFluentImpl) o; - if (claimName != null ? !claimName.equals(that.claimName) :that.claimName != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; + V1PersistentVolumeClaimVolumeSourceFluentImpl that = + (V1PersistentVolumeClaimVolumeSourceFluentImpl) o; + if (claimName != null ? !claimName.equals(that.claimName) : that.claimName != null) + return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(claimName, readOnly, super.hashCode()); + return java.util.Objects.hash(claimName, readOnly, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeFluent.java index 5f80b059f0..5fd811aa6a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeFluent.java @@ -1,93 +1,148 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PersistentVolumeFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PersistentVolumeFluent< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec getSpec(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item); + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PersistentVolumeStatus getStatus(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus item); + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeFluentImpl.java index 30fa62e63a..7aae464d77 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1PersistentVolumeFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PersistentVolumeFluent { + public V1PersistentVolumeFluentImpl() {} - /** - * Generated - */ -public class V1PersistentVolumeFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PersistentVolumeFluent{ - public V1PersistentVolumeFluentImpl() { - } - public V1PersistentVolumeFluentImpl(io.kubernetes.client.openapi.models.V1PersistentVolume instance) { + public V1PersistentVolumeFluentImpl( + io.kubernetes.client.openapi.models.V1PersistentVolume instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,306 @@ public V1PersistentVolumeFluentImpl(io.kubernetes.client.openapi.models.V1Persis this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder spec; private io.kubernetes.client.openapi.models.V1PersistentVolumeStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl.SpecNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PersistentVolumeStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1PersistentVolumeStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1PersistentVolumeStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1PersistentVolumeStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested withNewStatus() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested + withNewStatus() { return new io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl.StatusNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1PersistentVolumeStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1PersistentVolumeStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PersistentVolumeFluentImpl that = (V1PersistentVolumeFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1PersistentVolumeFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder builder; + public N and() { return (N) V1PersistentVolumeFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1PersistentVolumeStatusBuilder builder; + public N and() { return (N) V1PersistentVolumeFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeListBuilder.java index cab4a0b100..4b60832b8b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PersistentVolumeListBuilder extends io.kubernetes.client.openapi.models.V1PersistentVolumeListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PersistentVolumeListBuilder + extends io.kubernetes.client.openapi.models.V1PersistentVolumeListFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PersistentVolumeList, + io.kubernetes.client.openapi.models.V1PersistentVolumeListBuilder> { public V1PersistentVolumeListBuilder() { this(false); } + public V1PersistentVolumeListBuilder(java.lang.Boolean validationEnabled) { this(new V1PersistentVolumeList(), validationEnabled); } - public V1PersistentVolumeListBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent fluent) { + + public V1PersistentVolumeListBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent fluent) { this(fluent, false); } - public V1PersistentVolumeListBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PersistentVolumeListBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PersistentVolumeList(), validationEnabled); } - public V1PersistentVolumeListBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeList instance) { + + public V1PersistentVolumeListBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeList instance) { this(fluent, instance, false); } - public V1PersistentVolumeListBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PersistentVolumeListBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1PersistentVolumeListBuilder(io.kubernetes.client.openapi.models.V1Persi fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PersistentVolumeListBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeList instance) { - this(instance,false); + + public V1PersistentVolumeListBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeList instance) { + this(instance, false); } - public V1PersistentVolumeListBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PersistentVolumeListBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1PersistentVolumeListBuilder(io.kubernetes.client.openapi.models.V1Persi this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PersistentVolumeList build() { V1PersistentVolumeList buildable = new V1PersistentVolumeList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1PersistentVolumeList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PersistentVolumeListBuilder that = (V1PersistentVolumeListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeListFluent.java index fb7e8b46da..4f9beaf298 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeListFluent.java @@ -1,95 +1,160 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PersistentVolumeListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PersistentVolumeListFluent< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolume item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolume item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolume item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolume item); + public A addToItems(io.kubernetes.client.openapi.models.V1PersistentVolume... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1PersistentVolume... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1PersistentVolume buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PersistentVolume buildFirstItem(); + public io.kubernetes.client.openapi.models.V1PersistentVolume buildLastItem(); - public io.kubernetes.client.openapi.models.V1PersistentVolume buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PersistentVolume buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1PersistentVolume... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1PersistentVolume item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolume item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1PersistentVolume item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolume item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PersistentVolumeFluent>{ + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PersistentVolumeFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeListFluentImpl.java index 4513dff056..2b1591245d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1PersistentVolumeListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent{ - public V1PersistentVolumeListFluentImpl() { - } - public V1PersistentVolumeListFluentImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeList instance) { + +/** Generated */ +public class V1PersistentVolumeListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent { + public V1PersistentVolumeListFluentImpl() {} + + public V1PersistentVolumeListFluentImpl( + io.kubernetes.client.openapi.models.V1PersistentVolumeList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1PersistentVolumeListFluentImpl(io.kubernetes.client.openapi.models.V1Pe this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolume item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolume item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolume item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolume item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1PersistentVolume... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PersistentVolume item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PersistentVolume item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PersistentVolume item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PersistentVolume item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1PersistentVolume... items) { - for (io.kubernetes.client.openapi.models.V1PersistentVolume item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1PersistentVolume item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PersistentVolume item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PersistentVolume item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder = each.next(); @@ -87,174 +159,283 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1PersistentVolume buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1PersistentVolume buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1PersistentVolume buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PersistentVolume buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PersistentVolume buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PersistentVolume item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PersistentVolume item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1PersistentVolume... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1PersistentVolume item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1PersistentVolume item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1PersistentVolume item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1PersistentVolume item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolume item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolume item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PersistentVolumeListFluentImpl that = (V1PersistentVolumeListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolume item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1PersistentVolumeFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolume item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder(this); } + io.kubernetes.client.openapi.models.V1PersistentVolumeBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PersistentVolumeListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1PersistentVolumeListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1PersistentVolumeListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeSpecBuilder.java index 029056a8b0..580cf3eca7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PersistentVolumeSpecBuilder extends io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PersistentVolumeSpecBuilder + extends io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec, + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder> { public V1PersistentVolumeSpecBuilder() { this(false); } + public V1PersistentVolumeSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1PersistentVolumeSpec(), validationEnabled); } - public V1PersistentVolumeSpecBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent fluent) { + + public V1PersistentVolumeSpecBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent fluent) { this(fluent, false); } - public V1PersistentVolumeSpecBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PersistentVolumeSpecBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PersistentVolumeSpec(), validationEnabled); } - public V1PersistentVolumeSpecBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeSpec instance) { + + public V1PersistentVolumeSpecBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec instance) { this(fluent, instance, false); } - public V1PersistentVolumeSpecBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PersistentVolumeSpecBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAccessModes(instance.getAccessModes()); fluent.withAwsElasticBlockStore(instance.getAwsElasticBlockStore()); @@ -81,13 +108,18 @@ public V1PersistentVolumeSpecBuilder(io.kubernetes.client.openapi.models.V1Persi fluent.withVsphereVolume(instance.getVsphereVolume()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PersistentVolumeSpecBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec instance) { - this(instance,false); + + public V1PersistentVolumeSpecBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec instance) { + this(instance, false); } - public V1PersistentVolumeSpecBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PersistentVolumeSpecBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAccessModes(instance.getAccessModes()); this.withAwsElasticBlockStore(instance.getAwsElasticBlockStore()); @@ -148,10 +180,12 @@ public V1PersistentVolumeSpecBuilder(io.kubernetes.client.openapi.models.V1Persi this.withVsphereVolume(instance.getVsphereVolume()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec build() { V1PersistentVolumeSpec buildable = new V1PersistentVolumeSpec(); buildable.setAccessModes(fluent.getAccessModes()); @@ -186,18 +220,23 @@ public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec build() { buildable.setVsphereVolume(fluent.getVsphereVolume()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PersistentVolumeSpecBuilder that = (V1PersistentVolumeSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeSpecFluent.java index 6f9c14e2bc..e070cee97e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeSpecFluent.java @@ -1,563 +1,1095 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import java.util.ArrayList; -import java.lang.String; -import java.lang.Boolean; -import java.util.Map; -import java.lang.Deprecated; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.util.List; -import io.kubernetes.client.fluent.Fluent; -import java.util.Collection; -import io.kubernetes.client.fluent.Nested; -import io.kubernetes.client.custom.Quantity; -import java.lang.Integer; - - /** - * Generated - */ -public interface V1PersistentVolumeSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAccessModes(java.lang.Integer index,java.lang.String item); - public A setToAccessModes(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1PersistentVolumeSpecFluent< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAccessModes(java.lang.Integer index, java.lang.String item); + + public A setToAccessModes(java.lang.Integer index, java.lang.String item); + public A addToAccessModes(java.lang.String... items); + public A addAllToAccessModes(java.util.Collection items); + public A removeFromAccessModes(java.lang.String... items); + public A removeAllFromAccessModes(java.util.Collection items); + public java.util.List getAccessModes(); + public java.lang.String getAccessMode(java.lang.Integer index); + public java.lang.String getFirstAccessMode(); + public java.lang.String getLastAccessMode(); - public java.lang.String getMatchingAccessMode(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAccessMode(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAccessMode( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAccessMode( + java.util.function.Predicate predicate); + public A withAccessModes(java.util.List accessModes); + public A withAccessModes(java.lang.String... accessModes); + public java.lang.Boolean hasAccessModes(); + public A addNewAccessMode(java.lang.String original); - + /** * This method has been deprecated, please use method buildAwsElasticBlockStore instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource getAwsElasticBlockStore(); - public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource buildAwsElasticBlockStore(); - public A withAwsElasticBlockStore(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource awsElasticBlockStore); + public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource + getAwsElasticBlockStore(); + + public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource + buildAwsElasticBlockStore(); + + public A withAwsElasticBlockStore( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource awsElasticBlockStore); + public java.lang.Boolean hasAwsElasticBlockStore(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AwsElasticBlockStoreNested withNewAwsElasticBlockStore(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AwsElasticBlockStoreNested withNewAwsElasticBlockStoreLike(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AwsElasticBlockStoreNested editAwsElasticBlockStore(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AwsElasticBlockStoreNested editOrNewAwsElasticBlockStore(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AwsElasticBlockStoreNested editOrNewAwsElasticBlockStoreLike(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .AwsElasticBlockStoreNested< + A> + withNewAwsElasticBlockStore(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .AwsElasticBlockStoreNested< + A> + withNewAwsElasticBlockStoreLike( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .AwsElasticBlockStoreNested< + A> + editAwsElasticBlockStore(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .AwsElasticBlockStoreNested< + A> + editOrNewAwsElasticBlockStore(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .AwsElasticBlockStoreNested< + A> + editOrNewAwsElasticBlockStoreLike( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item); + /** * This method has been deprecated, please use method buildAzureDisk instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource getAzureDisk(); + public io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource buildAzureDisk(); + public A withAzureDisk(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource azureDisk); + public java.lang.Boolean hasAzureDisk(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested withNewAzureDisk(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested withNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested editAzureDisk(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested editOrNewAzureDisk(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested editOrNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested + withNewAzureDisk(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested + withNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested + editAzureDisk(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested + editOrNewAzureDisk(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested + editOrNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item); + /** * This method has been deprecated, please use method buildAzureFile instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource getAzureFile(); + public io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource buildAzureFile(); - public A withAzureFile(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource azureFile); + + public A withAzureFile( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource azureFile); + public java.lang.Boolean hasAzureFile(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested withNewAzureFile(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested withNewAzureFileLike(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested editAzureFile(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested editOrNewAzureFile(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested editOrNewAzureFileLike(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource item); - public A addToCapacity(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToCapacity(java.util.Map map); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested + withNewAzureFile(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested + withNewAzureFileLike( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested + editAzureFile(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested + editOrNewAzureFile(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested + editOrNewAzureFileLike( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource item); + + public A addToCapacity(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToCapacity(java.util.Map map); + public A removeFromCapacity(java.lang.String key); - public A removeFromCapacity(java.util.Map map); - public java.util.Map getCapacity(); - public A withCapacity(java.util.Map capacity); + + public A removeFromCapacity( + java.util.Map map); + + public java.util.Map getCapacity(); + + public A withCapacity( + java.util.Map capacity); + public java.lang.Boolean hasCapacity(); - + /** * This method has been deprecated, please use method buildCephfs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource getCephfs(); + public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource buildCephfs(); + public A withCephfs(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource cephfs); + public java.lang.Boolean hasCephfs(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested withNewCephfs(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested withNewCephfsLike(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested editCephfs(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested editOrNewCephfs(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested editOrNewCephfsLike(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested + withNewCephfs(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested + withNewCephfsLike(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested + editCephfs(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested + editOrNewCephfs(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested + editOrNewCephfsLike(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource item); + /** * This method has been deprecated, please use method buildCinder instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource getCinder(); + public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource buildCinder(); + public A withCinder(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource cinder); + public java.lang.Boolean hasCinder(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested withNewCinder(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested withNewCinderLike(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested editCinder(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested editOrNewCinder(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested editOrNewCinderLike(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested + withNewCinder(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested + withNewCinderLike(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested + editCinder(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested + editOrNewCinder(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested + editOrNewCinderLike(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource item); + /** * This method has been deprecated, please use method buildClaimRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getClaimRef(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildClaimRef(); + public A withClaimRef(io.kubernetes.client.openapi.models.V1ObjectReference claimRef); + public java.lang.Boolean hasClaimRef(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested withNewClaimRef(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested withNewClaimRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested editClaimRef(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested editOrNewClaimRef(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested editOrNewClaimRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested + withNewClaimRef(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested + withNewClaimRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested + editClaimRef(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested + editOrNewClaimRef(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested + editOrNewClaimRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + /** * This method has been deprecated, please use method buildCsi instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource getCsi(); + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource buildCsi(); + public A withCsi(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource csi); + public java.lang.Boolean hasCsi(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested withNewCsi(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested withNewCsiLike(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested + withNewCsiLike(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource item); + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested editCsi(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested editOrNewCsi(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested editOrNewCsiLike(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested + editOrNewCsi(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested + editOrNewCsiLike(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource item); + /** * This method has been deprecated, please use method buildFc instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1FCVolumeSource getFc(); + public io.kubernetes.client.openapi.models.V1FCVolumeSource buildFc(); + public A withFc(io.kubernetes.client.openapi.models.V1FCVolumeSource fc); + public java.lang.Boolean hasFc(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested withNewFc(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested withNewFcLike(io.kubernetes.client.openapi.models.V1FCVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested withNewFcLike( + io.kubernetes.client.openapi.models.V1FCVolumeSource item); + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested editFc(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested editOrNewFc(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested editOrNewFcLike(io.kubernetes.client.openapi.models.V1FCVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested + editOrNewFcLike(io.kubernetes.client.openapi.models.V1FCVolumeSource item); + /** * This method has been deprecated, please use method buildFlexVolume instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource getFlexVolume(); + public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource buildFlexVolume(); - public A withFlexVolume(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource flexVolume); + + public A withFlexVolume( + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource flexVolume); + public java.lang.Boolean hasFlexVolume(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested withNewFlexVolume(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested withNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested editFlexVolume(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested editOrNewFlexVolume(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested editOrNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested + withNewFlexVolume(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested + withNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested + editFlexVolume(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested + editOrNewFlexVolume(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested + editOrNewFlexVolumeLike( + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource item); + /** * This method has been deprecated, please use method buildFlocker instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1FlockerVolumeSource getFlocker(); + public io.kubernetes.client.openapi.models.V1FlockerVolumeSource buildFlocker(); + public A withFlocker(io.kubernetes.client.openapi.models.V1FlockerVolumeSource flocker); + public java.lang.Boolean hasFlocker(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested withNewFlocker(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested withNewFlockerLike(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested editFlocker(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested editOrNewFlocker(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested editOrNewFlockerLike(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested + withNewFlocker(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested + withNewFlockerLike(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested + editFlocker(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested + editOrNewFlocker(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested + editOrNewFlockerLike(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item); + /** * This method has been deprecated, please use method buildGcePersistentDisk instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource getGcePersistentDisk(); - public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource buildGcePersistentDisk(); - public A withGcePersistentDisk(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource gcePersistentDisk); + + public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource + buildGcePersistentDisk(); + + public A withGcePersistentDisk( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource gcePersistentDisk); + public java.lang.Boolean hasGcePersistentDisk(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested withNewGcePersistentDisk(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested withNewGcePersistentDiskLike(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested editGcePersistentDisk(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested editOrNewGcePersistentDisk(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested editOrNewGcePersistentDiskLike(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested + withNewGcePersistentDisk(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested + withNewGcePersistentDiskLike( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested + editGcePersistentDisk(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested + editOrNewGcePersistentDisk(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested + editOrNewGcePersistentDiskLike( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item); + /** * This method has been deprecated, please use method buildGlusterfs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource getGlusterfs(); + public io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource buildGlusterfs(); - public A withGlusterfs(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource glusterfs); + + public A withGlusterfs( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource glusterfs); + public java.lang.Boolean hasGlusterfs(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested withNewGlusterfs(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested withNewGlusterfsLike(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested editGlusterfs(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested editOrNewGlusterfs(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested editOrNewGlusterfsLike(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested + withNewGlusterfs(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested + withNewGlusterfsLike( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested + editGlusterfs(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested + editOrNewGlusterfs(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested + editOrNewGlusterfsLike( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource item); + /** * This method has been deprecated, please use method buildHostPath instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HostPathVolumeSource getHostPath(); + public io.kubernetes.client.openapi.models.V1HostPathVolumeSource buildHostPath(); + public A withHostPath(io.kubernetes.client.openapi.models.V1HostPathVolumeSource hostPath); + public java.lang.Boolean hasHostPath(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested withNewHostPath(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested withNewHostPathLike(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested editHostPath(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested editOrNewHostPath(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested editOrNewHostPathLike(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested + withNewHostPath(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested + withNewHostPathLike(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested + editHostPath(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested + editOrNewHostPath(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested + editOrNewHostPathLike(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item); + /** * This method has been deprecated, please use method buildIscsi instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource getIscsi(); + public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource buildIscsi(); + public A withIscsi(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource iscsi); + public java.lang.Boolean hasIscsi(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested withNewIscsi(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested withNewIscsiLike(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested editIscsi(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested editOrNewIscsi(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested editOrNewIscsiLike(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested + withNewIscsi(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested + withNewIscsiLike(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested + editIscsi(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested + editOrNewIscsi(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested + editOrNewIscsiLike(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource item); + /** * This method has been deprecated, please use method buildLocal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalVolumeSource getLocal(); + public io.kubernetes.client.openapi.models.V1LocalVolumeSource buildLocal(); + public A withLocal(io.kubernetes.client.openapi.models.V1LocalVolumeSource local); + public java.lang.Boolean hasLocal(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested withNewLocal(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested withNewLocalLike(io.kubernetes.client.openapi.models.V1LocalVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested editLocal(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested editOrNewLocal(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested editOrNewLocalLike(io.kubernetes.client.openapi.models.V1LocalVolumeSource item); - public A addToMountOptions(java.lang.Integer index,java.lang.String item); - public A setToMountOptions(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested + withNewLocal(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested + withNewLocalLike(io.kubernetes.client.openapi.models.V1LocalVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested + editLocal(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested + editOrNewLocal(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested + editOrNewLocalLike(io.kubernetes.client.openapi.models.V1LocalVolumeSource item); + + public A addToMountOptions(java.lang.Integer index, java.lang.String item); + + public A setToMountOptions(java.lang.Integer index, java.lang.String item); + public A addToMountOptions(java.lang.String... items); + public A addAllToMountOptions(java.util.Collection items); + public A removeFromMountOptions(java.lang.String... items); + public A removeAllFromMountOptions(java.util.Collection items); + public java.util.List getMountOptions(); + public java.lang.String getMountOption(java.lang.Integer index); + public java.lang.String getFirstMountOption(); + public java.lang.String getLastMountOption(); - public java.lang.String getMatchingMountOption(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMountOption(java.util.function.Predicate predicate); + + public java.lang.String getMatchingMountOption( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingMountOption( + java.util.function.Predicate predicate); + public A withMountOptions(java.util.List mountOptions); + public A withMountOptions(java.lang.String... mountOptions); + public java.lang.Boolean hasMountOptions(); + public A addNewMountOption(java.lang.String original); - + /** * This method has been deprecated, please use method buildNfs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NFSVolumeSource getNfs(); + public io.kubernetes.client.openapi.models.V1NFSVolumeSource buildNfs(); + public A withNfs(io.kubernetes.client.openapi.models.V1NFSVolumeSource nfs); + public java.lang.Boolean hasNfs(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested withNewNfs(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested withNewNfsLike(io.kubernetes.client.openapi.models.V1NFSVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested + withNewNfsLike(io.kubernetes.client.openapi.models.V1NFSVolumeSource item); + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested editNfs(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested editOrNewNfs(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested editOrNewNfsLike(io.kubernetes.client.openapi.models.V1NFSVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested + editOrNewNfs(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested + editOrNewNfsLike(io.kubernetes.client.openapi.models.V1NFSVolumeSource item); + /** * This method has been deprecated, please use method buildNodeAffinity instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeNodeAffinity getNodeAffinity(); + public io.kubernetes.client.openapi.models.V1VolumeNodeAffinity buildNodeAffinity(); + public A withNodeAffinity(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity nodeAffinity); + public java.lang.Boolean hasNodeAffinity(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested withNewNodeAffinity(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested withNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested editNodeAffinity(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested editOrNewNodeAffinity(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested editOrNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec.PersistentVolumeReclaimPolicyEnum getPersistentVolumeReclaimPolicy(); - public A withPersistentVolumeReclaimPolicy(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec.PersistentVolumeReclaimPolicyEnum persistentVolumeReclaimPolicy); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested + withNewNodeAffinity(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested + withNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested + editNodeAffinity(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested + editOrNewNodeAffinity(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested + editOrNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec + .PersistentVolumeReclaimPolicyEnum + getPersistentVolumeReclaimPolicy(); + + public A withPersistentVolumeReclaimPolicy( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec.PersistentVolumeReclaimPolicyEnum + persistentVolumeReclaimPolicy); + public java.lang.Boolean hasPersistentVolumeReclaimPolicy(); - + /** * This method has been deprecated, please use method buildPhotonPersistentDisk instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource getPhotonPersistentDisk(); - public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource buildPhotonPersistentDisk(); - public A withPhotonPersistentDisk(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource photonPersistentDisk); + public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource + getPhotonPersistentDisk(); + + public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource + buildPhotonPersistentDisk(); + + public A withPhotonPersistentDisk( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource photonPersistentDisk); + public java.lang.Boolean hasPhotonPersistentDisk(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PhotonPersistentDiskNested withNewPhotonPersistentDisk(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PhotonPersistentDiskNested withNewPhotonPersistentDiskLike(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PhotonPersistentDiskNested editPhotonPersistentDisk(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PhotonPersistentDiskNested editOrNewPhotonPersistentDisk(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PhotonPersistentDiskNested editOrNewPhotonPersistentDiskLike(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PhotonPersistentDiskNested< + A> + withNewPhotonPersistentDisk(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PhotonPersistentDiskNested< + A> + withNewPhotonPersistentDiskLike( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PhotonPersistentDiskNested< + A> + editPhotonPersistentDisk(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PhotonPersistentDiskNested< + A> + editOrNewPhotonPersistentDisk(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PhotonPersistentDiskNested< + A> + editOrNewPhotonPersistentDiskLike( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item); + /** * This method has been deprecated, please use method buildPortworxVolume instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PortworxVolumeSource getPortworxVolume(); + public io.kubernetes.client.openapi.models.V1PortworxVolumeSource buildPortworxVolume(); - public A withPortworxVolume(io.kubernetes.client.openapi.models.V1PortworxVolumeSource portworxVolume); + + public A withPortworxVolume( + io.kubernetes.client.openapi.models.V1PortworxVolumeSource portworxVolume); + public java.lang.Boolean hasPortworxVolume(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested withNewPortworxVolume(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested withNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested editPortworxVolume(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested editOrNewPortworxVolume(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested editOrNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested + withNewPortworxVolume(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested + withNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested + editPortworxVolume(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested + editOrNewPortworxVolume(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested + editOrNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item); + /** * This method has been deprecated, please use method buildQuobyte instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1QuobyteVolumeSource getQuobyte(); + public io.kubernetes.client.openapi.models.V1QuobyteVolumeSource buildQuobyte(); + public A withQuobyte(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource quobyte); + public java.lang.Boolean hasQuobyte(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested withNewQuobyte(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested withNewQuobyteLike(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested editQuobyte(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested editOrNewQuobyte(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested editOrNewQuobyteLike(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested + withNewQuobyte(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested + withNewQuobyteLike(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested + editQuobyte(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested + editOrNewQuobyte(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested + editOrNewQuobyteLike(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item); + /** * This method has been deprecated, please use method buildRbd instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource getRbd(); + public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource buildRbd(); + public A withRbd(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource rbd); + public java.lang.Boolean hasRbd(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested withNewRbd(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested withNewRbdLike(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested + withNewRbdLike(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource item); + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested editRbd(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested editOrNewRbd(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested editOrNewRbdLike(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested + editOrNewRbd(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested + editOrNewRbdLike(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource item); + /** * This method has been deprecated, please use method buildScaleIO instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource getScaleIO(); + public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource buildScaleIO(); + public A withScaleIO(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource scaleIO); + public java.lang.Boolean hasScaleIO(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested withNewScaleIO(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested withNewScaleIOLike(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested editScaleIO(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested editOrNewScaleIO(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested editOrNewScaleIOLike(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested + withNewScaleIO(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested + withNewScaleIOLike(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested + editScaleIO(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested + editOrNewScaleIO(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested + editOrNewScaleIOLike( + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource item); + public java.lang.String getStorageClassName(); + public A withStorageClassName(java.lang.String storageClassName); + public java.lang.Boolean hasStorageClassName(); - - /** - * Method is deprecated. use withStorageClassName instead. - */ + + /** Method is deprecated. use withStorageClassName instead. */ @java.lang.Deprecated public A withNewStorageClassName(java.lang.String original); - + /** * This method has been deprecated, please use method buildStorageos instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource getStorageos(); + public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource buildStorageos(); - public A withStorageos(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource storageos); + + public A withStorageos( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource storageos); + public java.lang.Boolean hasStorageos(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested withNewStorageos(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested withNewStorageosLike(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested editStorageos(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested editOrNewStorageos(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested editOrNewStorageosLike(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested + withNewStorageos(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested + withNewStorageosLike( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested + editStorageos(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested + editOrNewStorageos(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested + editOrNewStorageosLike( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource item); + public java.lang.String getVolumeMode(); + public A withVolumeMode(java.lang.String volumeMode); + public java.lang.Boolean hasVolumeMode(); - - /** - * Method is deprecated. use withVolumeMode instead. - */ + + /** Method is deprecated. use withVolumeMode instead. */ @java.lang.Deprecated public A withNewVolumeMode(java.lang.String original); - + /** * This method has been deprecated, please use method buildVsphereVolume instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource getVsphereVolume(); + public io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource buildVsphereVolume(); - public A withVsphereVolume(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource vsphereVolume); + + public A withVsphereVolume( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource vsphereVolume); + public java.lang.Boolean hasVsphereVolume(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested withNewVsphereVolume(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested withNewVsphereVolumeLike(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested editVsphereVolume(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested editOrNewVsphereVolume(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested editOrNewVsphereVolumeLike(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item); - public interface AwsElasticBlockStoreNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent>{ + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested + withNewVsphereVolume(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested + withNewVsphereVolumeLike( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested + editVsphereVolume(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested + editOrNewVsphereVolume(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested + editOrNewVsphereVolumeLike( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item); + + public interface AwsElasticBlockStoreNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .AwsElasticBlockStoreNested< + N>> { public N and(); + public N endAwsElasticBlockStore(); - } - public interface AzureDiskNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent>{ + + public interface AzureDiskNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested> { public N and(); + public N endAzureDisk(); - } - public interface AzureFileNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent>{ + + public interface AzureFileNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested> { public N and(); + public N endAzureFile(); - } - public interface CephfsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent>{ + + public interface CephfsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested> { public N and(); + public N endCephfs(); - } - public interface CinderNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent>{ + + public interface CinderNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested> { public N and(); + public N endCinder(); - } - public interface ClaimRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface ClaimRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested> { public N and(); + public N endClaimRef(); - } - public interface CsiNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent>{ + + public interface CsiNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested> { public N and(); + public N endCsi(); - } - public interface FcNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent>{ + + public interface FcNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested> { public N and(); + public N endFc(); - } - public interface FlexVolumeNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent>{ + + public interface FlexVolumeNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested< + N>> { public N and(); + public N endFlexVolume(); - } - public interface FlockerNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent>{ + + public interface FlockerNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested> { public N and(); + public N endFlocker(); - } - public interface GcePersistentDiskNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent>{ + + public interface GcePersistentDiskNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .GcePersistentDiskNested< + N>> { public N and(); + public N endGcePersistentDisk(); - } - public interface GlusterfsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent>{ + + public interface GlusterfsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested> { public N and(); + public N endGlusterfs(); - } - public interface HostPathNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent>{ + + public interface HostPathNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested> { public N and(); + public N endHostPath(); - } - public interface IscsiNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent>{ + + public interface IscsiNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested> { public N and(); + public N endIscsi(); - } - public interface LocalNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent>{ + + public interface LocalNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested> { public N and(); + public N endLocal(); - } - public interface NfsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent>{ + + public interface NfsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested> { public N and(); + public N endNfs(); - } - public interface NodeAffinityNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent>{ + + public interface NodeAffinityNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested< + N>> { public N and(); + public N endNodeAffinity(); - } - public interface PhotonPersistentDiskNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent>{ + + public interface PhotonPersistentDiskNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PhotonPersistentDiskNested< + N>> { public N and(); + public N endPhotonPersistentDisk(); - } - public interface PortworxVolumeNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent>{ + + public interface PortworxVolumeNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested< + N>> { public N and(); + public N endPortworxVolume(); - } - public interface QuobyteNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent>{ + + public interface QuobyteNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested> { public N and(); + public N endQuobyte(); - } - public interface RbdNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent>{ + + public interface RbdNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested> { public N and(); + public N endRbd(); - } - public interface ScaleIONested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent>{ + + public interface ScaleIONested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested> { public N and(); + public N endScaleIO(); - } - public interface StorageosNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent>{ + + public interface StorageosNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested> { public N and(); + public N endStorageos(); - } - public interface VsphereVolumeNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent>{ + + public interface VsphereVolumeNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested< + N>> { public N and(); + public N endVsphereVolume(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeSpecFluentImpl.java index 459802c027..9a404b0e56 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeSpecFluentImpl.java @@ -1,27 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Object; -import java.util.Map; -import java.lang.Deprecated; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.util.List; -import java.util.Collection; -import io.kubernetes.client.fluent.Nested; -import io.kubernetes.client.custom.Quantity; -import java.lang.Integer; - - /** - * Generated - */ -public class V1PersistentVolumeSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent{ - public V1PersistentVolumeSpecFluentImpl() { - } - public V1PersistentVolumeSpecFluentImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec instance) { +/** Generated */ +public class V1PersistentVolumeSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent { + public V1PersistentVolumeSpecFluentImpl() {} + + public V1PersistentVolumeSpecFluentImpl( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec instance) { this.withAccessModes(instance.getAccessModes()); this.withAwsElasticBlockStore(instance.getAwsElasticBlockStore()); @@ -81,13 +80,14 @@ public V1PersistentVolumeSpecFluentImpl(io.kubernetes.client.openapi.models.V1Pe this.withVolumeMode(instance.getVolumeMode()); this.withVsphereVolume(instance.getVsphereVolume()); - } + private java.util.List accessModes; - private io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder awsElasticBlockStore; + private io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder + awsElasticBlockStore; private io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder azureDisk; private io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceBuilder azureFile; - private java.util.Map capacity; + private java.util.Map capacity; private io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceBuilder cephfs; private io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceBuilder cinder; private io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder claimRef; @@ -95,7 +95,8 @@ public V1PersistentVolumeSpecFluentImpl(io.kubernetes.client.openapi.models.V1Pe private io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder fc; private io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceBuilder flexVolume; private io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder flocker; - private io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder gcePersistentDisk; + private io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder + gcePersistentDisk; private io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceBuilder glusterfs; private io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder hostPath; private io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceBuilder iscsi; @@ -103,8 +104,11 @@ public V1PersistentVolumeSpecFluentImpl(io.kubernetes.client.openapi.models.V1Pe private java.util.List mountOptions; private io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder nfs; private io.kubernetes.client.openapi.models.V1VolumeNodeAffinityBuilder nodeAffinity; - private io.kubernetes.client.openapi.models.V1PersistentVolumeSpec.PersistentVolumeReclaimPolicyEnum persistentVolumeReclaimPolicy; - private io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder photonPersistentDisk; + private io.kubernetes.client.openapi.models.V1PersistentVolumeSpec + .PersistentVolumeReclaimPolicyEnum + persistentVolumeReclaimPolicy; + private io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder + photonPersistentDisk; private io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder portworxVolume; private io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder quobyte; private io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceBuilder rbd; @@ -113,1420 +117,2558 @@ public V1PersistentVolumeSpecFluentImpl(io.kubernetes.client.openapi.models.V1Pe private io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceBuilder storageos; private java.lang.String volumeMode; private io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder vsphereVolume; - public A addToAccessModes(java.lang.Integer index,java.lang.String item) { - if (this.accessModes == null) {this.accessModes = new java.util.ArrayList();} + + public A addToAccessModes(java.lang.Integer index, java.lang.String item) { + if (this.accessModes == null) { + this.accessModes = new java.util.ArrayList(); + } this.accessModes.add(index, item); - return (A)this; + return (A) this; } - public A setToAccessModes(java.lang.Integer index,java.lang.String item) { - if (this.accessModes == null) {this.accessModes = new java.util.ArrayList();} - this.accessModes.set(index, item); return (A)this; + + public A setToAccessModes(java.lang.Integer index, java.lang.String item) { + if (this.accessModes == null) { + this.accessModes = new java.util.ArrayList(); + } + this.accessModes.set(index, item); + return (A) this; } + public A addToAccessModes(java.lang.String... items) { - if (this.accessModes == null) {this.accessModes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.accessModes.add(item);} return (A)this; + if (this.accessModes == null) { + this.accessModes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.accessModes.add(item); + } + return (A) this; } + public A addAllToAccessModes(java.util.Collection items) { - if (this.accessModes == null) {this.accessModes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.accessModes.add(item);} return (A)this; + if (this.accessModes == null) { + this.accessModes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.accessModes.add(item); + } + return (A) this; } + public A removeFromAccessModes(java.lang.String... items) { - for (java.lang.String item : items) {if (this.accessModes!= null){ this.accessModes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.accessModes != null) { + this.accessModes.remove(item); + } + } + return (A) this; } + public A removeAllFromAccessModes(java.util.Collection items) { - for (java.lang.String item : items) {if (this.accessModes!= null){ this.accessModes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.accessModes != null) { + this.accessModes.remove(item); + } + } + return (A) this; } + public java.util.List getAccessModes() { return this.accessModes; } + public java.lang.String getAccessMode(java.lang.Integer index) { return this.accessModes.get(index); } + public java.lang.String getFirstAccessMode() { return this.accessModes.get(0); } + public java.lang.String getLastAccessMode() { return this.accessModes.get(accessModes.size() - 1); } - public java.lang.String getMatchingAccessMode(java.util.function.Predicate predicate) { - for (java.lang.String item: accessModes) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAccessMode( + java.util.function.Predicate predicate) { + for (java.lang.String item : accessModes) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAccessMode(java.util.function.Predicate predicate) { - for (java.lang.String item: accessModes) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAccessMode( + java.util.function.Predicate predicate) { + for (java.lang.String item : accessModes) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAccessModes(java.util.List accessModes) { - if (accessModes != null) {this.accessModes = new java.util.ArrayList(); for (java.lang.String item : accessModes){this.addToAccessModes(item);}} else { this.accessModes = null;} return (A) this; + if (accessModes != null) { + this.accessModes = new java.util.ArrayList(); + for (java.lang.String item : accessModes) { + this.addToAccessModes(item); + } + } else { + this.accessModes = null; + } + return (A) this; } + public A withAccessModes(java.lang.String... accessModes) { - if (this.accessModes != null) {this.accessModes.clear();} - if (accessModes != null) {for (java.lang.String item :accessModes){ this.addToAccessModes(item);}} return (A) this; + if (this.accessModes != null) { + this.accessModes.clear(); + } + if (accessModes != null) { + for (java.lang.String item : accessModes) { + this.addToAccessModes(item); + } + } + return (A) this; } + public java.lang.Boolean hasAccessModes() { return accessModes != null && !accessModes.isEmpty(); } + public A addNewAccessMode(java.lang.String original) { - return (A)addToAccessModes(new String(original)); + return (A) addToAccessModes(new String(original)); } - + /** * This method has been deprecated, please use method buildAwsElasticBlockStore instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource getAwsElasticBlockStore() { - return this.awsElasticBlockStore!=null ?this.awsElasticBlockStore.build():null; + public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource + getAwsElasticBlockStore() { + return this.awsElasticBlockStore != null ? this.awsElasticBlockStore.build() : null; } - public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource buildAwsElasticBlockStore() { - return this.awsElasticBlockStore!=null ?this.awsElasticBlockStore.build():null; + + public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource + buildAwsElasticBlockStore() { + return this.awsElasticBlockStore != null ? this.awsElasticBlockStore.build() : null; } - public A withAwsElasticBlockStore(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource awsElasticBlockStore) { + + public A withAwsElasticBlockStore( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource awsElasticBlockStore) { _visitables.get("awsElasticBlockStore").remove(this.awsElasticBlockStore); - if (awsElasticBlockStore!=null){ this.awsElasticBlockStore= new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder(awsElasticBlockStore); _visitables.get("awsElasticBlockStore").add(this.awsElasticBlockStore);} return (A) this; + if (awsElasticBlockStore != null) { + this.awsElasticBlockStore = + new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder( + awsElasticBlockStore); + _visitables.get("awsElasticBlockStore").add(this.awsElasticBlockStore); + } + return (A) this; } + public java.lang.Boolean hasAwsElasticBlockStore() { return this.awsElasticBlockStore != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AwsElasticBlockStoreNested withNewAwsElasticBlockStore() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.AwsElasticBlockStoreNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .AwsElasticBlockStoreNested< + A> + withNewAwsElasticBlockStore() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .AwsElasticBlockStoreNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AwsElasticBlockStoreNested withNewAwsElasticBlockStoreLike(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.AwsElasticBlockStoreNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .AwsElasticBlockStoreNested< + A> + withNewAwsElasticBlockStoreLike( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .AwsElasticBlockStoreNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AwsElasticBlockStoreNested editAwsElasticBlockStore() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .AwsElasticBlockStoreNested< + A> + editAwsElasticBlockStore() { return withNewAwsElasticBlockStoreLike(getAwsElasticBlockStore()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AwsElasticBlockStoreNested editOrNewAwsElasticBlockStore() { - return withNewAwsElasticBlockStoreLike(getAwsElasticBlockStore() != null ? getAwsElasticBlockStore(): new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .AwsElasticBlockStoreNested< + A> + editOrNewAwsElasticBlockStore() { + return withNewAwsElasticBlockStoreLike( + getAwsElasticBlockStore() != null + ? getAwsElasticBlockStore() + : new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AwsElasticBlockStoreNested editOrNewAwsElasticBlockStoreLike(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item) { - return withNewAwsElasticBlockStoreLike(getAwsElasticBlockStore() != null ? getAwsElasticBlockStore(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .AwsElasticBlockStoreNested< + A> + editOrNewAwsElasticBlockStoreLike( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item) { + return withNewAwsElasticBlockStoreLike( + getAwsElasticBlockStore() != null ? getAwsElasticBlockStore() : item); } - + /** * This method has been deprecated, please use method buildAzureDisk instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource getAzureDisk() { - return this.azureDisk!=null ?this.azureDisk.build():null; + return this.azureDisk != null ? this.azureDisk.build() : null; } + public io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource buildAzureDisk() { - return this.azureDisk!=null ?this.azureDisk.build():null; + return this.azureDisk != null ? this.azureDisk.build() : null; } + public A withAzureDisk(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource azureDisk) { _visitables.get("azureDisk").remove(this.azureDisk); - if (azureDisk!=null){ this.azureDisk= new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder(azureDisk); _visitables.get("azureDisk").add(this.azureDisk);} return (A) this; + if (azureDisk != null) { + this.azureDisk = + new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder(azureDisk); + _visitables.get("azureDisk").add(this.azureDisk); + } + return (A) this; } + public java.lang.Boolean hasAzureDisk() { return this.azureDisk != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested withNewAzureDisk() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.AzureDiskNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested + withNewAzureDisk() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .AzureDiskNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested withNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.AzureDiskNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested + withNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .AzureDiskNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested editAzureDisk() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested + editAzureDisk() { return withNewAzureDiskLike(getAzureDisk()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested editOrNewAzureDisk() { - return withNewAzureDiskLike(getAzureDisk() != null ? getAzureDisk(): new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested + editOrNewAzureDisk() { + return withNewAzureDiskLike( + getAzureDisk() != null + ? getAzureDisk() + : new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested editOrNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item) { - return withNewAzureDiskLike(getAzureDisk() != null ? getAzureDisk(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested + editOrNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item) { + return withNewAzureDiskLike(getAzureDisk() != null ? getAzureDisk() : item); } - + /** * This method has been deprecated, please use method buildAzureFile instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource getAzureFile() { - return this.azureFile!=null ?this.azureFile.build():null; + return this.azureFile != null ? this.azureFile.build() : null; } + public io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource buildAzureFile() { - return this.azureFile!=null ?this.azureFile.build():null; + return this.azureFile != null ? this.azureFile.build() : null; } - public A withAzureFile(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource azureFile) { + + public A withAzureFile( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource azureFile) { _visitables.get("azureFile").remove(this.azureFile); - if (azureFile!=null){ this.azureFile= new io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceBuilder(azureFile); _visitables.get("azureFile").add(this.azureFile);} return (A) this; + if (azureFile != null) { + this.azureFile = + new io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceBuilder( + azureFile); + _visitables.get("azureFile").add(this.azureFile); + } + return (A) this; } + public java.lang.Boolean hasAzureFile() { return this.azureFile != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested withNewAzureFile() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.AzureFileNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested + withNewAzureFile() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .AzureFileNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested withNewAzureFileLike(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.AzureFileNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested + withNewAzureFileLike( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .AzureFileNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested editAzureFile() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested + editAzureFile() { return withNewAzureFileLike(getAzureFile()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested editOrNewAzureFile() { - return withNewAzureFileLike(getAzureFile() != null ? getAzureFile(): new io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested + editOrNewAzureFile() { + return withNewAzureFileLike( + getAzureFile() != null + ? getAzureFile() + : new io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested editOrNewAzureFileLike(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource item) { - return withNewAzureFileLike(getAzureFile() != null ? getAzureFile(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested + editOrNewAzureFileLike( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource item) { + return withNewAzureFileLike(getAzureFile() != null ? getAzureFile() : item); } - public A addToCapacity(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.capacity == null && key != null && value != null) { this.capacity = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.capacity.put(key, value);} return (A)this; + + public A addToCapacity(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.capacity == null && key != null && value != null) { + this.capacity = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.capacity.put(key, value); + } + return (A) this; } - public A addToCapacity(java.util.Map map) { - if(this.capacity == null && map != null) { this.capacity = new java.util.LinkedHashMap(); } - if(map != null) { this.capacity.putAll(map);} return (A)this; + + public A addToCapacity( + java.util.Map map) { + if (this.capacity == null && map != null) { + this.capacity = new java.util.LinkedHashMap(); + } + if (map != null) { + this.capacity.putAll(map); + } + return (A) this; } + public A removeFromCapacity(java.lang.String key) { - if(this.capacity == null) { return (A) this; } - if(key != null && this.capacity != null) {this.capacity.remove(key);} return (A)this; + if (this.capacity == null) { + return (A) this; + } + if (key != null && this.capacity != null) { + this.capacity.remove(key); + } + return (A) this; } - public A removeFromCapacity(java.util.Map map) { - if(this.capacity == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.capacity != null){this.capacity.remove(key);}}} return (A)this; + + public A removeFromCapacity( + java.util.Map map) { + if (this.capacity == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.capacity != null) { + this.capacity.remove(key); + } + } + } + return (A) this; } - public java.util.Map getCapacity() { + + public java.util.Map getCapacity() { return this.capacity; } - public A withCapacity(java.util.Map capacity) { - if (capacity == null) { this.capacity = null;} else {this.capacity = new java.util.LinkedHashMap(capacity);} return (A) this; + + public A withCapacity( + java.util.Map capacity) { + if (capacity == null) { + this.capacity = null; + } else { + this.capacity = new java.util.LinkedHashMap(capacity); + } + return (A) this; } + public java.lang.Boolean hasCapacity() { return this.capacity != null; } - + /** * This method has been deprecated, please use method buildCephfs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource getCephfs() { - return this.cephfs!=null ?this.cephfs.build():null; + return this.cephfs != null ? this.cephfs.build() : null; } + public io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource buildCephfs() { - return this.cephfs!=null ?this.cephfs.build():null; + return this.cephfs != null ? this.cephfs.build() : null; } + public A withCephfs(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource cephfs) { _visitables.get("cephfs").remove(this.cephfs); - if (cephfs!=null){ this.cephfs= new io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceBuilder(cephfs); _visitables.get("cephfs").add(this.cephfs);} return (A) this; + if (cephfs != null) { + this.cephfs = + new io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceBuilder(cephfs); + _visitables.get("cephfs").add(this.cephfs); + } + return (A) this; } + public java.lang.Boolean hasCephfs() { return this.cephfs != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested withNewCephfs() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.CephfsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested + withNewCephfs() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .CephfsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested withNewCephfsLike(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.CephfsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested + withNewCephfsLike(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .CephfsNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested editCephfs() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested + editCephfs() { return withNewCephfsLike(getCephfs()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested editOrNewCephfs() { - return withNewCephfsLike(getCephfs() != null ? getCephfs(): new io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested + editOrNewCephfs() { + return withNewCephfsLike( + getCephfs() != null + ? getCephfs() + : new io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested editOrNewCephfsLike(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource item) { - return withNewCephfsLike(getCephfs() != null ? getCephfs(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested + editOrNewCephfsLike(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource item) { + return withNewCephfsLike(getCephfs() != null ? getCephfs() : item); } - + /** * This method has been deprecated, please use method buildCinder instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource getCinder() { - return this.cinder!=null ?this.cinder.build():null; + return this.cinder != null ? this.cinder.build() : null; } + public io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource buildCinder() { - return this.cinder!=null ?this.cinder.build():null; + return this.cinder != null ? this.cinder.build() : null; } + public A withCinder(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource cinder) { _visitables.get("cinder").remove(this.cinder); - if (cinder!=null){ this.cinder= new io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceBuilder(cinder); _visitables.get("cinder").add(this.cinder);} return (A) this; + if (cinder != null) { + this.cinder = + new io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceBuilder(cinder); + _visitables.get("cinder").add(this.cinder); + } + return (A) this; } + public java.lang.Boolean hasCinder() { return this.cinder != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested withNewCinder() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.CinderNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested + withNewCinder() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .CinderNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested withNewCinderLike(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.CinderNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested + withNewCinderLike(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .CinderNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested editCinder() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested + editCinder() { return withNewCinderLike(getCinder()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested editOrNewCinder() { - return withNewCinderLike(getCinder() != null ? getCinder(): new io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested + editOrNewCinder() { + return withNewCinderLike( + getCinder() != null + ? getCinder() + : new io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested editOrNewCinderLike(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource item) { - return withNewCinderLike(getCinder() != null ? getCinder(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested + editOrNewCinderLike(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource item) { + return withNewCinderLike(getCinder() != null ? getCinder() : item); } - + /** * This method has been deprecated, please use method buildClaimRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getClaimRef() { - return this.claimRef!=null ?this.claimRef.build():null; + return this.claimRef != null ? this.claimRef.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectReference buildClaimRef() { - return this.claimRef!=null ?this.claimRef.build():null; + return this.claimRef != null ? this.claimRef.build() : null; } + public A withClaimRef(io.kubernetes.client.openapi.models.V1ObjectReference claimRef) { _visitables.get("claimRef").remove(this.claimRef); - if (claimRef!=null){ this.claimRef= new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(claimRef); _visitables.get("claimRef").add(this.claimRef);} return (A) this; + if (claimRef != null) { + this.claimRef = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(claimRef); + _visitables.get("claimRef").add(this.claimRef); + } + return (A) this; } + public java.lang.Boolean hasClaimRef() { return this.claimRef != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested withNewClaimRef() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.ClaimRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested + withNewClaimRef() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .ClaimRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested withNewClaimRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.ClaimRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested + withNewClaimRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .ClaimRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested editClaimRef() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested + editClaimRef() { return withNewClaimRefLike(getClaimRef()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested editOrNewClaimRef() { - return withNewClaimRefLike(getClaimRef() != null ? getClaimRef(): new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested + editOrNewClaimRef() { + return withNewClaimRefLike( + getClaimRef() != null + ? getClaimRef() + : new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested editOrNewClaimRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return withNewClaimRefLike(getClaimRef() != null ? getClaimRef(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested + editOrNewClaimRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return withNewClaimRefLike(getClaimRef() != null ? getClaimRef() : item); } - + /** * This method has been deprecated, please use method buildCsi instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource getCsi() { - return this.csi!=null ?this.csi.build():null; + return this.csi != null ? this.csi.build() : null; } + public io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource buildCsi() { - return this.csi!=null ?this.csi.build():null; + return this.csi != null ? this.csi.build() : null; } + public A withCsi(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource csi) { _visitables.get("csi").remove(this.csi); - if (csi!=null){ this.csi= new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceBuilder(csi); _visitables.get("csi").add(this.csi);} return (A) this; + if (csi != null) { + this.csi = new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceBuilder(csi); + _visitables.get("csi").add(this.csi); + } + return (A) this; } + public java.lang.Boolean hasCsi() { return this.csi != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested withNewCsi() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested + withNewCsi() { return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.CsiNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested withNewCsiLike(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.CsiNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested + withNewCsiLike(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.CsiNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested editCsi() { return withNewCsiLike(getCsi()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested editOrNewCsi() { - return withNewCsiLike(getCsi() != null ? getCsi(): new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested + editOrNewCsi() { + return withNewCsiLike( + getCsi() != null + ? getCsi() + : new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested editOrNewCsiLike(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource item) { - return withNewCsiLike(getCsi() != null ? getCsi(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested + editOrNewCsiLike(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource item) { + return withNewCsiLike(getCsi() != null ? getCsi() : item); } - + /** * This method has been deprecated, please use method buildFc instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1FCVolumeSource getFc() { - return this.fc!=null ?this.fc.build():null; + return this.fc != null ? this.fc.build() : null; } + public io.kubernetes.client.openapi.models.V1FCVolumeSource buildFc() { - return this.fc!=null ?this.fc.build():null; + return this.fc != null ? this.fc.build() : null; } + public A withFc(io.kubernetes.client.openapi.models.V1FCVolumeSource fc) { _visitables.get("fc").remove(this.fc); - if (fc!=null){ this.fc= new io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder(fc); _visitables.get("fc").add(this.fc);} return (A) this; + if (fc != null) { + this.fc = new io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder(fc); + _visitables.get("fc").add(this.fc); + } + return (A) this; } + public java.lang.Boolean hasFc() { return this.fc != null; } + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested withNewFc() { return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.FcNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested withNewFcLike(io.kubernetes.client.openapi.models.V1FCVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.FcNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested withNewFcLike( + io.kubernetes.client.openapi.models.V1FCVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.FcNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested editFc() { return withNewFcLike(getFc()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested editOrNewFc() { - return withNewFcLike(getFc() != null ? getFc(): new io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested + editOrNewFc() { + return withNewFcLike( + getFc() != null + ? getFc() + : new io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested editOrNewFcLike(io.kubernetes.client.openapi.models.V1FCVolumeSource item) { - return withNewFcLike(getFc() != null ? getFc(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested + editOrNewFcLike(io.kubernetes.client.openapi.models.V1FCVolumeSource item) { + return withNewFcLike(getFc() != null ? getFc() : item); } - + /** * This method has been deprecated, please use method buildFlexVolume instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource getFlexVolume() { - return this.flexVolume!=null ?this.flexVolume.build():null; + return this.flexVolume != null ? this.flexVolume.build() : null; } + public io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource buildFlexVolume() { - return this.flexVolume!=null ?this.flexVolume.build():null; + return this.flexVolume != null ? this.flexVolume.build() : null; } - public A withFlexVolume(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource flexVolume) { + + public A withFlexVolume( + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource flexVolume) { _visitables.get("flexVolume").remove(this.flexVolume); - if (flexVolume!=null){ this.flexVolume= new io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceBuilder(flexVolume); _visitables.get("flexVolume").add(this.flexVolume);} return (A) this; + if (flexVolume != null) { + this.flexVolume = + new io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceBuilder(flexVolume); + _visitables.get("flexVolume").add(this.flexVolume); + } + return (A) this; } + public java.lang.Boolean hasFlexVolume() { return this.flexVolume != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested withNewFlexVolume() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.FlexVolumeNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested + withNewFlexVolume() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .FlexVolumeNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested withNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.FlexVolumeNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested + withNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .FlexVolumeNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested editFlexVolume() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested + editFlexVolume() { return withNewFlexVolumeLike(getFlexVolume()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested editOrNewFlexVolume() { - return withNewFlexVolumeLike(getFlexVolume() != null ? getFlexVolume(): new io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested + editOrNewFlexVolume() { + return withNewFlexVolumeLike( + getFlexVolume() != null + ? getFlexVolume() + : new io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested editOrNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource item) { - return withNewFlexVolumeLike(getFlexVolume() != null ? getFlexVolume(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested + editOrNewFlexVolumeLike( + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource item) { + return withNewFlexVolumeLike(getFlexVolume() != null ? getFlexVolume() : item); } - + /** * This method has been deprecated, please use method buildFlocker instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1FlockerVolumeSource getFlocker() { - return this.flocker!=null ?this.flocker.build():null; + return this.flocker != null ? this.flocker.build() : null; } + public io.kubernetes.client.openapi.models.V1FlockerVolumeSource buildFlocker() { - return this.flocker!=null ?this.flocker.build():null; + return this.flocker != null ? this.flocker.build() : null; } + public A withFlocker(io.kubernetes.client.openapi.models.V1FlockerVolumeSource flocker) { _visitables.get("flocker").remove(this.flocker); - if (flocker!=null){ this.flocker= new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder(flocker); _visitables.get("flocker").add(this.flocker);} return (A) this; + if (flocker != null) { + this.flocker = new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder(flocker); + _visitables.get("flocker").add(this.flocker); + } + return (A) this; } + public java.lang.Boolean hasFlocker() { return this.flocker != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested withNewFlocker() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.FlockerNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested + withNewFlocker() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .FlockerNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested withNewFlockerLike(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.FlockerNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested + withNewFlockerLike(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .FlockerNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested editFlocker() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested + editFlocker() { return withNewFlockerLike(getFlocker()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested editOrNewFlocker() { - return withNewFlockerLike(getFlocker() != null ? getFlocker(): new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested + editOrNewFlocker() { + return withNewFlockerLike( + getFlocker() != null + ? getFlocker() + : new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested editOrNewFlockerLike(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item) { - return withNewFlockerLike(getFlocker() != null ? getFlocker(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested + editOrNewFlockerLike(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item) { + return withNewFlockerLike(getFlocker() != null ? getFlocker() : item); } - + /** * This method has been deprecated, please use method buildGcePersistentDisk instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource getGcePersistentDisk() { - return this.gcePersistentDisk!=null ?this.gcePersistentDisk.build():null; + public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource + getGcePersistentDisk() { + return this.gcePersistentDisk != null ? this.gcePersistentDisk.build() : null; } - public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource buildGcePersistentDisk() { - return this.gcePersistentDisk!=null ?this.gcePersistentDisk.build():null; + + public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource + buildGcePersistentDisk() { + return this.gcePersistentDisk != null ? this.gcePersistentDisk.build() : null; } - public A withGcePersistentDisk(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource gcePersistentDisk) { + + public A withGcePersistentDisk( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource gcePersistentDisk) { _visitables.get("gcePersistentDisk").remove(this.gcePersistentDisk); - if (gcePersistentDisk!=null){ this.gcePersistentDisk= new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder(gcePersistentDisk); _visitables.get("gcePersistentDisk").add(this.gcePersistentDisk);} return (A) this; + if (gcePersistentDisk != null) { + this.gcePersistentDisk = + new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder( + gcePersistentDisk); + _visitables.get("gcePersistentDisk").add(this.gcePersistentDisk); + } + return (A) this; } + public java.lang.Boolean hasGcePersistentDisk() { return this.gcePersistentDisk != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested withNewGcePersistentDisk() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.GcePersistentDiskNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested + withNewGcePersistentDisk() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .GcePersistentDiskNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested withNewGcePersistentDiskLike(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.GcePersistentDiskNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested + withNewGcePersistentDiskLike( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .GcePersistentDiskNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested editGcePersistentDisk() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested + editGcePersistentDisk() { return withNewGcePersistentDiskLike(getGcePersistentDisk()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested editOrNewGcePersistentDisk() { - return withNewGcePersistentDiskLike(getGcePersistentDisk() != null ? getGcePersistentDisk(): new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested + editOrNewGcePersistentDisk() { + return withNewGcePersistentDiskLike( + getGcePersistentDisk() != null + ? getGcePersistentDisk() + : new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested editOrNewGcePersistentDiskLike(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item) { - return withNewGcePersistentDiskLike(getGcePersistentDisk() != null ? getGcePersistentDisk(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested + editOrNewGcePersistentDiskLike( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item) { + return withNewGcePersistentDiskLike( + getGcePersistentDisk() != null ? getGcePersistentDisk() : item); } - + /** * This method has been deprecated, please use method buildGlusterfs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource getGlusterfs() { - return this.glusterfs!=null ?this.glusterfs.build():null; + return this.glusterfs != null ? this.glusterfs.build() : null; } + public io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource buildGlusterfs() { - return this.glusterfs!=null ?this.glusterfs.build():null; + return this.glusterfs != null ? this.glusterfs.build() : null; } - public A withGlusterfs(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource glusterfs) { + + public A withGlusterfs( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource glusterfs) { _visitables.get("glusterfs").remove(this.glusterfs); - if (glusterfs!=null){ this.glusterfs= new io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceBuilder(glusterfs); _visitables.get("glusterfs").add(this.glusterfs);} return (A) this; + if (glusterfs != null) { + this.glusterfs = + new io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceBuilder( + glusterfs); + _visitables.get("glusterfs").add(this.glusterfs); + } + return (A) this; } + public java.lang.Boolean hasGlusterfs() { return this.glusterfs != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested withNewGlusterfs() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.GlusterfsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested + withNewGlusterfs() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .GlusterfsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested withNewGlusterfsLike(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.GlusterfsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested + withNewGlusterfsLike( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .GlusterfsNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested editGlusterfs() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested + editGlusterfs() { return withNewGlusterfsLike(getGlusterfs()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested editOrNewGlusterfs() { - return withNewGlusterfsLike(getGlusterfs() != null ? getGlusterfs(): new io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested + editOrNewGlusterfs() { + return withNewGlusterfsLike( + getGlusterfs() != null + ? getGlusterfs() + : new io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested editOrNewGlusterfsLike(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource item) { - return withNewGlusterfsLike(getGlusterfs() != null ? getGlusterfs(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested + editOrNewGlusterfsLike( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource item) { + return withNewGlusterfsLike(getGlusterfs() != null ? getGlusterfs() : item); } - + /** * This method has been deprecated, please use method buildHostPath instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HostPathVolumeSource getHostPath() { - return this.hostPath!=null ?this.hostPath.build():null; + return this.hostPath != null ? this.hostPath.build() : null; } + public io.kubernetes.client.openapi.models.V1HostPathVolumeSource buildHostPath() { - return this.hostPath!=null ?this.hostPath.build():null; + return this.hostPath != null ? this.hostPath.build() : null; } + public A withHostPath(io.kubernetes.client.openapi.models.V1HostPathVolumeSource hostPath) { _visitables.get("hostPath").remove(this.hostPath); - if (hostPath!=null){ this.hostPath= new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder(hostPath); _visitables.get("hostPath").add(this.hostPath);} return (A) this; + if (hostPath != null) { + this.hostPath = + new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder(hostPath); + _visitables.get("hostPath").add(this.hostPath); + } + return (A) this; } + public java.lang.Boolean hasHostPath() { return this.hostPath != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested withNewHostPath() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.HostPathNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested + withNewHostPath() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .HostPathNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested withNewHostPathLike(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.HostPathNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested + withNewHostPathLike(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .HostPathNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested editHostPath() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested + editHostPath() { return withNewHostPathLike(getHostPath()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested editOrNewHostPath() { - return withNewHostPathLike(getHostPath() != null ? getHostPath(): new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested + editOrNewHostPath() { + return withNewHostPathLike( + getHostPath() != null + ? getHostPath() + : new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested editOrNewHostPathLike(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item) { - return withNewHostPathLike(getHostPath() != null ? getHostPath(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested + editOrNewHostPathLike(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item) { + return withNewHostPathLike(getHostPath() != null ? getHostPath() : item); } - + /** * This method has been deprecated, please use method buildIscsi instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource getIscsi() { - return this.iscsi!=null ?this.iscsi.build():null; + return this.iscsi != null ? this.iscsi.build() : null; } + public io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource buildIscsi() { - return this.iscsi!=null ?this.iscsi.build():null; + return this.iscsi != null ? this.iscsi.build() : null; } + public A withIscsi(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource iscsi) { _visitables.get("iscsi").remove(this.iscsi); - if (iscsi!=null){ this.iscsi= new io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceBuilder(iscsi); _visitables.get("iscsi").add(this.iscsi);} return (A) this; + if (iscsi != null) { + this.iscsi = + new io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceBuilder(iscsi); + _visitables.get("iscsi").add(this.iscsi); + } + return (A) this; } + public java.lang.Boolean hasIscsi() { return this.iscsi != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested withNewIscsi() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.IscsiNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested + withNewIscsi() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .IscsiNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested withNewIscsiLike(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.IscsiNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested + withNewIscsiLike(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.IscsiNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested editIscsi() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested + editIscsi() { return withNewIscsiLike(getIscsi()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested editOrNewIscsi() { - return withNewIscsiLike(getIscsi() != null ? getIscsi(): new io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested + editOrNewIscsi() { + return withNewIscsiLike( + getIscsi() != null + ? getIscsi() + : new io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested editOrNewIscsiLike(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource item) { - return withNewIscsiLike(getIscsi() != null ? getIscsi(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested + editOrNewIscsiLike(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource item) { + return withNewIscsiLike(getIscsi() != null ? getIscsi() : item); } - + /** * This method has been deprecated, please use method buildLocal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalVolumeSource getLocal() { - return this.local!=null ?this.local.build():null; + return this.local != null ? this.local.build() : null; } + public io.kubernetes.client.openapi.models.V1LocalVolumeSource buildLocal() { - return this.local!=null ?this.local.build():null; + return this.local != null ? this.local.build() : null; } + public A withLocal(io.kubernetes.client.openapi.models.V1LocalVolumeSource local) { _visitables.get("local").remove(this.local); - if (local!=null){ this.local= new io.kubernetes.client.openapi.models.V1LocalVolumeSourceBuilder(local); _visitables.get("local").add(this.local);} return (A) this; + if (local != null) { + this.local = new io.kubernetes.client.openapi.models.V1LocalVolumeSourceBuilder(local); + _visitables.get("local").add(this.local); + } + return (A) this; } + public java.lang.Boolean hasLocal() { return this.local != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested withNewLocal() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.LocalNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested + withNewLocal() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .LocalNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested withNewLocalLike(io.kubernetes.client.openapi.models.V1LocalVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.LocalNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested + withNewLocalLike(io.kubernetes.client.openapi.models.V1LocalVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.LocalNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested editLocal() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested + editLocal() { return withNewLocalLike(getLocal()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested editOrNewLocal() { - return withNewLocalLike(getLocal() != null ? getLocal(): new io.kubernetes.client.openapi.models.V1LocalVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested + editOrNewLocal() { + return withNewLocalLike( + getLocal() != null + ? getLocal() + : new io.kubernetes.client.openapi.models.V1LocalVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested editOrNewLocalLike(io.kubernetes.client.openapi.models.V1LocalVolumeSource item) { - return withNewLocalLike(getLocal() != null ? getLocal(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested + editOrNewLocalLike(io.kubernetes.client.openapi.models.V1LocalVolumeSource item) { + return withNewLocalLike(getLocal() != null ? getLocal() : item); } - public A addToMountOptions(java.lang.Integer index,java.lang.String item) { - if (this.mountOptions == null) {this.mountOptions = new java.util.ArrayList();} + + public A addToMountOptions(java.lang.Integer index, java.lang.String item) { + if (this.mountOptions == null) { + this.mountOptions = new java.util.ArrayList(); + } this.mountOptions.add(index, item); - return (A)this; + return (A) this; } - public A setToMountOptions(java.lang.Integer index,java.lang.String item) { - if (this.mountOptions == null) {this.mountOptions = new java.util.ArrayList();} - this.mountOptions.set(index, item); return (A)this; + + public A setToMountOptions(java.lang.Integer index, java.lang.String item) { + if (this.mountOptions == null) { + this.mountOptions = new java.util.ArrayList(); + } + this.mountOptions.set(index, item); + return (A) this; } + public A addToMountOptions(java.lang.String... items) { - if (this.mountOptions == null) {this.mountOptions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.mountOptions.add(item);} return (A)this; + if (this.mountOptions == null) { + this.mountOptions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.mountOptions.add(item); + } + return (A) this; } + public A addAllToMountOptions(java.util.Collection items) { - if (this.mountOptions == null) {this.mountOptions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.mountOptions.add(item);} return (A)this; + if (this.mountOptions == null) { + this.mountOptions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.mountOptions.add(item); + } + return (A) this; } + public A removeFromMountOptions(java.lang.String... items) { - for (java.lang.String item : items) {if (this.mountOptions!= null){ this.mountOptions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.mountOptions != null) { + this.mountOptions.remove(item); + } + } + return (A) this; } + public A removeAllFromMountOptions(java.util.Collection items) { - for (java.lang.String item : items) {if (this.mountOptions!= null){ this.mountOptions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.mountOptions != null) { + this.mountOptions.remove(item); + } + } + return (A) this; } + public java.util.List getMountOptions() { return this.mountOptions; } + public java.lang.String getMountOption(java.lang.Integer index) { return this.mountOptions.get(index); } + public java.lang.String getFirstMountOption() { return this.mountOptions.get(0); } + public java.lang.String getLastMountOption() { return this.mountOptions.get(mountOptions.size() - 1); } - public java.lang.String getMatchingMountOption(java.util.function.Predicate predicate) { - for (java.lang.String item: mountOptions) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingMountOption( + java.util.function.Predicate predicate) { + for (java.lang.String item : mountOptions) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingMountOption(java.util.function.Predicate predicate) { - for (java.lang.String item: mountOptions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMountOption( + java.util.function.Predicate predicate) { + for (java.lang.String item : mountOptions) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withMountOptions(java.util.List mountOptions) { - if (mountOptions != null) {this.mountOptions = new java.util.ArrayList(); for (java.lang.String item : mountOptions){this.addToMountOptions(item);}} else { this.mountOptions = null;} return (A) this; + if (mountOptions != null) { + this.mountOptions = new java.util.ArrayList(); + for (java.lang.String item : mountOptions) { + this.addToMountOptions(item); + } + } else { + this.mountOptions = null; + } + return (A) this; } + public A withMountOptions(java.lang.String... mountOptions) { - if (this.mountOptions != null) {this.mountOptions.clear();} - if (mountOptions != null) {for (java.lang.String item :mountOptions){ this.addToMountOptions(item);}} return (A) this; + if (this.mountOptions != null) { + this.mountOptions.clear(); + } + if (mountOptions != null) { + for (java.lang.String item : mountOptions) { + this.addToMountOptions(item); + } + } + return (A) this; } + public java.lang.Boolean hasMountOptions() { return mountOptions != null && !mountOptions.isEmpty(); } + public A addNewMountOption(java.lang.String original) { - return (A)addToMountOptions(new String(original)); + return (A) addToMountOptions(new String(original)); } - + /** * This method has been deprecated, please use method buildNfs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NFSVolumeSource getNfs() { - return this.nfs!=null ?this.nfs.build():null; + return this.nfs != null ? this.nfs.build() : null; } + public io.kubernetes.client.openapi.models.V1NFSVolumeSource buildNfs() { - return this.nfs!=null ?this.nfs.build():null; + return this.nfs != null ? this.nfs.build() : null; } + public A withNfs(io.kubernetes.client.openapi.models.V1NFSVolumeSource nfs) { _visitables.get("nfs").remove(this.nfs); - if (nfs!=null){ this.nfs= new io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder(nfs); _visitables.get("nfs").add(this.nfs);} return (A) this; + if (nfs != null) { + this.nfs = new io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder(nfs); + _visitables.get("nfs").add(this.nfs); + } + return (A) this; } + public java.lang.Boolean hasNfs() { return this.nfs != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested withNewNfs() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested + withNewNfs() { return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.NfsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested withNewNfsLike(io.kubernetes.client.openapi.models.V1NFSVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.NfsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested + withNewNfsLike(io.kubernetes.client.openapi.models.V1NFSVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.NfsNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested editNfs() { return withNewNfsLike(getNfs()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested editOrNewNfs() { - return withNewNfsLike(getNfs() != null ? getNfs(): new io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested + editOrNewNfs() { + return withNewNfsLike( + getNfs() != null + ? getNfs() + : new io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested editOrNewNfsLike(io.kubernetes.client.openapi.models.V1NFSVolumeSource item) { - return withNewNfsLike(getNfs() != null ? getNfs(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested + editOrNewNfsLike(io.kubernetes.client.openapi.models.V1NFSVolumeSource item) { + return withNewNfsLike(getNfs() != null ? getNfs() : item); } - + /** * This method has been deprecated, please use method buildNodeAffinity instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeNodeAffinity getNodeAffinity() { - return this.nodeAffinity!=null ?this.nodeAffinity.build():null; + return this.nodeAffinity != null ? this.nodeAffinity.build() : null; } + public io.kubernetes.client.openapi.models.V1VolumeNodeAffinity buildNodeAffinity() { - return this.nodeAffinity!=null ?this.nodeAffinity.build():null; + return this.nodeAffinity != null ? this.nodeAffinity.build() : null; } + public A withNodeAffinity(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity nodeAffinity) { _visitables.get("nodeAffinity").remove(this.nodeAffinity); - if (nodeAffinity!=null){ this.nodeAffinity= new io.kubernetes.client.openapi.models.V1VolumeNodeAffinityBuilder(nodeAffinity); _visitables.get("nodeAffinity").add(this.nodeAffinity);} return (A) this; + if (nodeAffinity != null) { + this.nodeAffinity = + new io.kubernetes.client.openapi.models.V1VolumeNodeAffinityBuilder(nodeAffinity); + _visitables.get("nodeAffinity").add(this.nodeAffinity); + } + return (A) this; } + public java.lang.Boolean hasNodeAffinity() { return this.nodeAffinity != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested withNewNodeAffinity() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.NodeAffinityNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested + withNewNodeAffinity() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .NodeAffinityNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested withNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.NodeAffinityNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested + withNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .NodeAffinityNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested editNodeAffinity() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested + editNodeAffinity() { return withNewNodeAffinityLike(getNodeAffinity()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested editOrNewNodeAffinity() { - return withNewNodeAffinityLike(getNodeAffinity() != null ? getNodeAffinity(): new io.kubernetes.client.openapi.models.V1VolumeNodeAffinityBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested + editOrNewNodeAffinity() { + return withNewNodeAffinityLike( + getNodeAffinity() != null + ? getNodeAffinity() + : new io.kubernetes.client.openapi.models.V1VolumeNodeAffinityBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested editOrNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity item) { - return withNewNodeAffinityLike(getNodeAffinity() != null ? getNodeAffinity(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested + editOrNewNodeAffinityLike(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity item) { + return withNewNodeAffinityLike(getNodeAffinity() != null ? getNodeAffinity() : item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec.PersistentVolumeReclaimPolicyEnum getPersistentVolumeReclaimPolicy() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec + .PersistentVolumeReclaimPolicyEnum + getPersistentVolumeReclaimPolicy() { return this.persistentVolumeReclaimPolicy; } - public A withPersistentVolumeReclaimPolicy(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec.PersistentVolumeReclaimPolicyEnum persistentVolumeReclaimPolicy) { - this.persistentVolumeReclaimPolicy=persistentVolumeReclaimPolicy; return (A) this; + + public A withPersistentVolumeReclaimPolicy( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec.PersistentVolumeReclaimPolicyEnum + persistentVolumeReclaimPolicy) { + this.persistentVolumeReclaimPolicy = persistentVolumeReclaimPolicy; + return (A) this; } + public java.lang.Boolean hasPersistentVolumeReclaimPolicy() { return this.persistentVolumeReclaimPolicy != null; } - + /** * This method has been deprecated, please use method buildPhotonPersistentDisk instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource getPhotonPersistentDisk() { - return this.photonPersistentDisk!=null ?this.photonPersistentDisk.build():null; + public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource + getPhotonPersistentDisk() { + return this.photonPersistentDisk != null ? this.photonPersistentDisk.build() : null; } - public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource buildPhotonPersistentDisk() { - return this.photonPersistentDisk!=null ?this.photonPersistentDisk.build():null; + + public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource + buildPhotonPersistentDisk() { + return this.photonPersistentDisk != null ? this.photonPersistentDisk.build() : null; } - public A withPhotonPersistentDisk(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource photonPersistentDisk) { + + public A withPhotonPersistentDisk( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource photonPersistentDisk) { _visitables.get("photonPersistentDisk").remove(this.photonPersistentDisk); - if (photonPersistentDisk!=null){ this.photonPersistentDisk= new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder(photonPersistentDisk); _visitables.get("photonPersistentDisk").add(this.photonPersistentDisk);} return (A) this; + if (photonPersistentDisk != null) { + this.photonPersistentDisk = + new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder( + photonPersistentDisk); + _visitables.get("photonPersistentDisk").add(this.photonPersistentDisk); + } + return (A) this; } + public java.lang.Boolean hasPhotonPersistentDisk() { return this.photonPersistentDisk != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PhotonPersistentDiskNested withNewPhotonPersistentDisk() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.PhotonPersistentDiskNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PhotonPersistentDiskNested< + A> + withNewPhotonPersistentDisk() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .PhotonPersistentDiskNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PhotonPersistentDiskNested withNewPhotonPersistentDiskLike(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.PhotonPersistentDiskNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PhotonPersistentDiskNested< + A> + withNewPhotonPersistentDiskLike( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .PhotonPersistentDiskNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PhotonPersistentDiskNested editPhotonPersistentDisk() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PhotonPersistentDiskNested< + A> + editPhotonPersistentDisk() { return withNewPhotonPersistentDiskLike(getPhotonPersistentDisk()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PhotonPersistentDiskNested editOrNewPhotonPersistentDisk() { - return withNewPhotonPersistentDiskLike(getPhotonPersistentDisk() != null ? getPhotonPersistentDisk(): new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PhotonPersistentDiskNested< + A> + editOrNewPhotonPersistentDisk() { + return withNewPhotonPersistentDiskLike( + getPhotonPersistentDisk() != null + ? getPhotonPersistentDisk() + : new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PhotonPersistentDiskNested editOrNewPhotonPersistentDiskLike(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item) { - return withNewPhotonPersistentDiskLike(getPhotonPersistentDisk() != null ? getPhotonPersistentDisk(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PhotonPersistentDiskNested< + A> + editOrNewPhotonPersistentDiskLike( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item) { + return withNewPhotonPersistentDiskLike( + getPhotonPersistentDisk() != null ? getPhotonPersistentDisk() : item); } - + /** * This method has been deprecated, please use method buildPortworxVolume instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PortworxVolumeSource getPortworxVolume() { - return this.portworxVolume!=null ?this.portworxVolume.build():null; + return this.portworxVolume != null ? this.portworxVolume.build() : null; } + public io.kubernetes.client.openapi.models.V1PortworxVolumeSource buildPortworxVolume() { - return this.portworxVolume!=null ?this.portworxVolume.build():null; + return this.portworxVolume != null ? this.portworxVolume.build() : null; } - public A withPortworxVolume(io.kubernetes.client.openapi.models.V1PortworxVolumeSource portworxVolume) { + + public A withPortworxVolume( + io.kubernetes.client.openapi.models.V1PortworxVolumeSource portworxVolume) { _visitables.get("portworxVolume").remove(this.portworxVolume); - if (portworxVolume!=null){ this.portworxVolume= new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder(portworxVolume); _visitables.get("portworxVolume").add(this.portworxVolume);} return (A) this; + if (portworxVolume != null) { + this.portworxVolume = + new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder(portworxVolume); + _visitables.get("portworxVolume").add(this.portworxVolume); + } + return (A) this; } + public java.lang.Boolean hasPortworxVolume() { return this.portworxVolume != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested withNewPortworxVolume() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.PortworxVolumeNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested + withNewPortworxVolume() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .PortworxVolumeNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested withNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.PortworxVolumeNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested + withNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .PortworxVolumeNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested editPortworxVolume() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested + editPortworxVolume() { return withNewPortworxVolumeLike(getPortworxVolume()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested editOrNewPortworxVolume() { - return withNewPortworxVolumeLike(getPortworxVolume() != null ? getPortworxVolume(): new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested + editOrNewPortworxVolume() { + return withNewPortworxVolumeLike( + getPortworxVolume() != null + ? getPortworxVolume() + : new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested editOrNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item) { - return withNewPortworxVolumeLike(getPortworxVolume() != null ? getPortworxVolume(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested + editOrNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item) { + return withNewPortworxVolumeLike(getPortworxVolume() != null ? getPortworxVolume() : item); } - + /** * This method has been deprecated, please use method buildQuobyte instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1QuobyteVolumeSource getQuobyte() { - return this.quobyte!=null ?this.quobyte.build():null; + return this.quobyte != null ? this.quobyte.build() : null; } + public io.kubernetes.client.openapi.models.V1QuobyteVolumeSource buildQuobyte() { - return this.quobyte!=null ?this.quobyte.build():null; + return this.quobyte != null ? this.quobyte.build() : null; } + public A withQuobyte(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource quobyte) { _visitables.get("quobyte").remove(this.quobyte); - if (quobyte!=null){ this.quobyte= new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder(quobyte); _visitables.get("quobyte").add(this.quobyte);} return (A) this; + if (quobyte != null) { + this.quobyte = new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder(quobyte); + _visitables.get("quobyte").add(this.quobyte); + } + return (A) this; } + public java.lang.Boolean hasQuobyte() { return this.quobyte != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested withNewQuobyte() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.QuobyteNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested + withNewQuobyte() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .QuobyteNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested withNewQuobyteLike(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.QuobyteNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested + withNewQuobyteLike(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .QuobyteNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested editQuobyte() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested + editQuobyte() { return withNewQuobyteLike(getQuobyte()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested editOrNewQuobyte() { - return withNewQuobyteLike(getQuobyte() != null ? getQuobyte(): new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested + editOrNewQuobyte() { + return withNewQuobyteLike( + getQuobyte() != null + ? getQuobyte() + : new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested editOrNewQuobyteLike(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item) { - return withNewQuobyteLike(getQuobyte() != null ? getQuobyte(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested + editOrNewQuobyteLike(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item) { + return withNewQuobyteLike(getQuobyte() != null ? getQuobyte() : item); } - + /** * This method has been deprecated, please use method buildRbd instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource getRbd() { - return this.rbd!=null ?this.rbd.build():null; + return this.rbd != null ? this.rbd.build() : null; } + public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource buildRbd() { - return this.rbd!=null ?this.rbd.build():null; + return this.rbd != null ? this.rbd.build() : null; } + public A withRbd(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource rbd) { _visitables.get("rbd").remove(this.rbd); - if (rbd!=null){ this.rbd= new io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceBuilder(rbd); _visitables.get("rbd").add(this.rbd);} return (A) this; + if (rbd != null) { + this.rbd = new io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceBuilder(rbd); + _visitables.get("rbd").add(this.rbd); + } + return (A) this; } + public java.lang.Boolean hasRbd() { return this.rbd != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested withNewRbd() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested + withNewRbd() { return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.RbdNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested withNewRbdLike(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.RbdNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested + withNewRbdLike(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.RbdNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested editRbd() { return withNewRbdLike(getRbd()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested editOrNewRbd() { - return withNewRbdLike(getRbd() != null ? getRbd(): new io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested + editOrNewRbd() { + return withNewRbdLike( + getRbd() != null + ? getRbd() + : new io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested editOrNewRbdLike(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource item) { - return withNewRbdLike(getRbd() != null ? getRbd(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested + editOrNewRbdLike(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource item) { + return withNewRbdLike(getRbd() != null ? getRbd() : item); } - + /** * This method has been deprecated, please use method buildScaleIO instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource getScaleIO() { - return this.scaleIO!=null ?this.scaleIO.build():null; + return this.scaleIO != null ? this.scaleIO.build() : null; } + public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource buildScaleIO() { - return this.scaleIO!=null ?this.scaleIO.build():null; + return this.scaleIO != null ? this.scaleIO.build() : null; } - public A withScaleIO(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource scaleIO) { + + public A withScaleIO( + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource scaleIO) { _visitables.get("scaleIO").remove(this.scaleIO); - if (scaleIO!=null){ this.scaleIO= new io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceBuilder(scaleIO); _visitables.get("scaleIO").add(this.scaleIO);} return (A) this; + if (scaleIO != null) { + this.scaleIO = + new io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceBuilder(scaleIO); + _visitables.get("scaleIO").add(this.scaleIO); + } + return (A) this; } + public java.lang.Boolean hasScaleIO() { return this.scaleIO != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested withNewScaleIO() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.ScaleIONestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested + withNewScaleIO() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .ScaleIONestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested withNewScaleIOLike(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.ScaleIONestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested + withNewScaleIOLike(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .ScaleIONestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested editScaleIO() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested + editScaleIO() { return withNewScaleIOLike(getScaleIO()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested editOrNewScaleIO() { - return withNewScaleIOLike(getScaleIO() != null ? getScaleIO(): new io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested + editOrNewScaleIO() { + return withNewScaleIOLike( + getScaleIO() != null + ? getScaleIO() + : new io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested editOrNewScaleIOLike(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource item) { - return withNewScaleIOLike(getScaleIO() != null ? getScaleIO(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested + editOrNewScaleIOLike( + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource item) { + return withNewScaleIOLike(getScaleIO() != null ? getScaleIO() : item); } + public java.lang.String getStorageClassName() { return this.storageClassName; } + public A withStorageClassName(java.lang.String storageClassName) { - this.storageClassName=storageClassName; return (A) this; + this.storageClassName = storageClassName; + return (A) this; } + public java.lang.Boolean hasStorageClassName() { return this.storageClassName != null; } - - /** - * Method is deprecated. use withStorageClassName instead. - */ + + /** Method is deprecated. use withStorageClassName instead. */ @java.lang.Deprecated public A withNewStorageClassName(java.lang.String original) { - return (A)withStorageClassName(new String(original)); + return (A) withStorageClassName(new String(original)); } - + /** * This method has been deprecated, please use method buildStorageos instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource getStorageos() { - return this.storageos!=null ?this.storageos.build():null; + return this.storageos != null ? this.storageos.build() : null; } + public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource buildStorageos() { - return this.storageos!=null ?this.storageos.build():null; + return this.storageos != null ? this.storageos.build() : null; } - public A withStorageos(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource storageos) { + + public A withStorageos( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource storageos) { _visitables.get("storageos").remove(this.storageos); - if (storageos!=null){ this.storageos= new io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceBuilder(storageos); _visitables.get("storageos").add(this.storageos);} return (A) this; + if (storageos != null) { + this.storageos = + new io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceBuilder( + storageos); + _visitables.get("storageos").add(this.storageos); + } + return (A) this; } + public java.lang.Boolean hasStorageos() { return this.storageos != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested withNewStorageos() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.StorageosNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested + withNewStorageos() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .StorageosNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested withNewStorageosLike(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.StorageosNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested + withNewStorageosLike( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .StorageosNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested editStorageos() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested + editStorageos() { return withNewStorageosLike(getStorageos()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested editOrNewStorageos() { - return withNewStorageosLike(getStorageos() != null ? getStorageos(): new io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested + editOrNewStorageos() { + return withNewStorageosLike( + getStorageos() != null + ? getStorageos() + : new io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested editOrNewStorageosLike(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource item) { - return withNewStorageosLike(getStorageos() != null ? getStorageos(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested + editOrNewStorageosLike( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource item) { + return withNewStorageosLike(getStorageos() != null ? getStorageos() : item); } + public java.lang.String getVolumeMode() { return this.volumeMode; } + public A withVolumeMode(java.lang.String volumeMode) { - this.volumeMode=volumeMode; return (A) this; + this.volumeMode = volumeMode; + return (A) this; } + public java.lang.Boolean hasVolumeMode() { return this.volumeMode != null; } - - /** - * Method is deprecated. use withVolumeMode instead. - */ + + /** Method is deprecated. use withVolumeMode instead. */ @java.lang.Deprecated public A withNewVolumeMode(java.lang.String original) { - return (A)withVolumeMode(new String(original)); + return (A) withVolumeMode(new String(original)); } - + /** * This method has been deprecated, please use method buildVsphereVolume instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource getVsphereVolume() { - return this.vsphereVolume!=null ?this.vsphereVolume.build():null; + return this.vsphereVolume != null ? this.vsphereVolume.build() : null; } + public io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource buildVsphereVolume() { - return this.vsphereVolume!=null ?this.vsphereVolume.build():null; + return this.vsphereVolume != null ? this.vsphereVolume.build() : null; } - public A withVsphereVolume(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource vsphereVolume) { + + public A withVsphereVolume( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource vsphereVolume) { _visitables.get("vsphereVolume").remove(this.vsphereVolume); - if (vsphereVolume!=null){ this.vsphereVolume= new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder(vsphereVolume); _visitables.get("vsphereVolume").add(this.vsphereVolume);} return (A) this; + if (vsphereVolume != null) { + this.vsphereVolume = + new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder( + vsphereVolume); + _visitables.get("vsphereVolume").add(this.vsphereVolume); + } + return (A) this; } + public java.lang.Boolean hasVsphereVolume() { return this.vsphereVolume != null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested withNewVsphereVolume() { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.VsphereVolumeNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested + withNewVsphereVolume() { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .VsphereVolumeNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested withNewVsphereVolumeLike(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl.VsphereVolumeNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested + withNewVsphereVolumeLike( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl + .VsphereVolumeNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested editVsphereVolume() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested + editVsphereVolume() { return withNewVsphereVolumeLike(getVsphereVolume()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested editOrNewVsphereVolume() { - return withNewVsphereVolumeLike(getVsphereVolume() != null ? getVsphereVolume(): new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested + editOrNewVsphereVolume() { + return withNewVsphereVolumeLike( + getVsphereVolume() != null + ? getVsphereVolume() + : new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested editOrNewVsphereVolumeLike(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item) { - return withNewVsphereVolumeLike(getVsphereVolume() != null ? getVsphereVolume(): item); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested + editOrNewVsphereVolumeLike( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item) { + return withNewVsphereVolumeLike(getVsphereVolume() != null ? getVsphereVolume() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PersistentVolumeSpecFluentImpl that = (V1PersistentVolumeSpecFluentImpl) o; - if (accessModes != null ? !accessModes.equals(that.accessModes) :that.accessModes != null) return false; - if (awsElasticBlockStore != null ? !awsElasticBlockStore.equals(that.awsElasticBlockStore) :that.awsElasticBlockStore != null) return false; - if (azureDisk != null ? !azureDisk.equals(that.azureDisk) :that.azureDisk != null) return false; - if (azureFile != null ? !azureFile.equals(that.azureFile) :that.azureFile != null) return false; - if (capacity != null ? !capacity.equals(that.capacity) :that.capacity != null) return false; - if (cephfs != null ? !cephfs.equals(that.cephfs) :that.cephfs != null) return false; - if (cinder != null ? !cinder.equals(that.cinder) :that.cinder != null) return false; - if (claimRef != null ? !claimRef.equals(that.claimRef) :that.claimRef != null) return false; - if (csi != null ? !csi.equals(that.csi) :that.csi != null) return false; - if (fc != null ? !fc.equals(that.fc) :that.fc != null) return false; - if (flexVolume != null ? !flexVolume.equals(that.flexVolume) :that.flexVolume != null) return false; - if (flocker != null ? !flocker.equals(that.flocker) :that.flocker != null) return false; - if (gcePersistentDisk != null ? !gcePersistentDisk.equals(that.gcePersistentDisk) :that.gcePersistentDisk != null) return false; - if (glusterfs != null ? !glusterfs.equals(that.glusterfs) :that.glusterfs != null) return false; - if (hostPath != null ? !hostPath.equals(that.hostPath) :that.hostPath != null) return false; - if (iscsi != null ? !iscsi.equals(that.iscsi) :that.iscsi != null) return false; - if (local != null ? !local.equals(that.local) :that.local != null) return false; - if (mountOptions != null ? !mountOptions.equals(that.mountOptions) :that.mountOptions != null) return false; - if (nfs != null ? !nfs.equals(that.nfs) :that.nfs != null) return false; - if (nodeAffinity != null ? !nodeAffinity.equals(that.nodeAffinity) :that.nodeAffinity != null) return false; - if (persistentVolumeReclaimPolicy != null ? !persistentVolumeReclaimPolicy.equals(that.persistentVolumeReclaimPolicy) :that.persistentVolumeReclaimPolicy != null) return false; - if (photonPersistentDisk != null ? !photonPersistentDisk.equals(that.photonPersistentDisk) :that.photonPersistentDisk != null) return false; - if (portworxVolume != null ? !portworxVolume.equals(that.portworxVolume) :that.portworxVolume != null) return false; - if (quobyte != null ? !quobyte.equals(that.quobyte) :that.quobyte != null) return false; - if (rbd != null ? !rbd.equals(that.rbd) :that.rbd != null) return false; - if (scaleIO != null ? !scaleIO.equals(that.scaleIO) :that.scaleIO != null) return false; - if (storageClassName != null ? !storageClassName.equals(that.storageClassName) :that.storageClassName != null) return false; - if (storageos != null ? !storageos.equals(that.storageos) :that.storageos != null) return false; - if (volumeMode != null ? !volumeMode.equals(that.volumeMode) :that.volumeMode != null) return false; - if (vsphereVolume != null ? !vsphereVolume.equals(that.vsphereVolume) :that.vsphereVolume != null) return false; + if (accessModes != null ? !accessModes.equals(that.accessModes) : that.accessModes != null) + return false; + if (awsElasticBlockStore != null + ? !awsElasticBlockStore.equals(that.awsElasticBlockStore) + : that.awsElasticBlockStore != null) return false; + if (azureDisk != null ? !azureDisk.equals(that.azureDisk) : that.azureDisk != null) + return false; + if (azureFile != null ? !azureFile.equals(that.azureFile) : that.azureFile != null) + return false; + if (capacity != null ? !capacity.equals(that.capacity) : that.capacity != null) return false; + if (cephfs != null ? !cephfs.equals(that.cephfs) : that.cephfs != null) return false; + if (cinder != null ? !cinder.equals(that.cinder) : that.cinder != null) return false; + if (claimRef != null ? !claimRef.equals(that.claimRef) : that.claimRef != null) return false; + if (csi != null ? !csi.equals(that.csi) : that.csi != null) return false; + if (fc != null ? !fc.equals(that.fc) : that.fc != null) return false; + if (flexVolume != null ? !flexVolume.equals(that.flexVolume) : that.flexVolume != null) + return false; + if (flocker != null ? !flocker.equals(that.flocker) : that.flocker != null) return false; + if (gcePersistentDisk != null + ? !gcePersistentDisk.equals(that.gcePersistentDisk) + : that.gcePersistentDisk != null) return false; + if (glusterfs != null ? !glusterfs.equals(that.glusterfs) : that.glusterfs != null) + return false; + if (hostPath != null ? !hostPath.equals(that.hostPath) : that.hostPath != null) return false; + if (iscsi != null ? !iscsi.equals(that.iscsi) : that.iscsi != null) return false; + if (local != null ? !local.equals(that.local) : that.local != null) return false; + if (mountOptions != null ? !mountOptions.equals(that.mountOptions) : that.mountOptions != null) + return false; + if (nfs != null ? !nfs.equals(that.nfs) : that.nfs != null) return false; + if (nodeAffinity != null ? !nodeAffinity.equals(that.nodeAffinity) : that.nodeAffinity != null) + return false; + if (persistentVolumeReclaimPolicy != null + ? !persistentVolumeReclaimPolicy.equals(that.persistentVolumeReclaimPolicy) + : that.persistentVolumeReclaimPolicy != null) return false; + if (photonPersistentDisk != null + ? !photonPersistentDisk.equals(that.photonPersistentDisk) + : that.photonPersistentDisk != null) return false; + if (portworxVolume != null + ? !portworxVolume.equals(that.portworxVolume) + : that.portworxVolume != null) return false; + if (quobyte != null ? !quobyte.equals(that.quobyte) : that.quobyte != null) return false; + if (rbd != null ? !rbd.equals(that.rbd) : that.rbd != null) return false; + if (scaleIO != null ? !scaleIO.equals(that.scaleIO) : that.scaleIO != null) return false; + if (storageClassName != null + ? !storageClassName.equals(that.storageClassName) + : that.storageClassName != null) return false; + if (storageos != null ? !storageos.equals(that.storageos) : that.storageos != null) + return false; + if (volumeMode != null ? !volumeMode.equals(that.volumeMode) : that.volumeMode != null) + return false; + if (vsphereVolume != null + ? !vsphereVolume.equals(that.vsphereVolume) + : that.vsphereVolume != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(accessModes, awsElasticBlockStore, azureDisk, azureFile, capacity, cephfs, cinder, claimRef, csi, fc, flexVolume, flocker, gcePersistentDisk, glusterfs, hostPath, iscsi, local, mountOptions, nfs, nodeAffinity, persistentVolumeReclaimPolicy, photonPersistentDisk, portworxVolume, quobyte, rbd, scaleIO, storageClassName, storageos, volumeMode, vsphereVolume, super.hashCode()); + return java.util.Objects.hash( + accessModes, + awsElasticBlockStore, + azureDisk, + azureFile, + capacity, + cephfs, + cinder, + claimRef, + csi, + fc, + flexVolume, + flocker, + gcePersistentDisk, + glusterfs, + hostPath, + iscsi, + local, + mountOptions, + nfs, + nodeAffinity, + persistentVolumeReclaimPolicy, + photonPersistentDisk, + portworxVolume, + quobyte, + rbd, + scaleIO, + storageClassName, + storageos, + volumeMode, + vsphereVolume, + super.hashCode()); } - public class AwsElasticBlockStoreNestedImpl extends io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AwsElasticBlockStoreNested,io.kubernetes.client.fluent.Nested{ - AwsElasticBlockStoreNestedImpl(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder(this, item); + + public class AwsElasticBlockStoreNestedImpl + extends io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .AwsElasticBlockStoreNested< + N>> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .AwsElasticBlockStoreNested< + N>, + io.kubernetes.client.fluent.Nested { + AwsElasticBlockStoreNestedImpl( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder( + this, item); } + AwsElasticBlockStoreNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withAwsElasticBlockStore(builder.build()); } + public N endAwsElasticBlockStore() { return and(); } - } - public class AzureDiskNestedImpl extends io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested,io.kubernetes.client.fluent.Nested{ + + public class AzureDiskNestedImpl + extends io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureDiskNested< + N>, + io.kubernetes.client.fluent.Nested { AzureDiskNestedImpl(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder(this, item); } + AzureDiskNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withAzureDisk(builder.build()); } + public N endAzureDisk() { return and(); } - } - public class AzureFileNestedImpl extends io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested,io.kubernetes.client.fluent.Nested{ - AzureFileNestedImpl(io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceBuilder(this, item); + + public class AzureFileNestedImpl + extends io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.AzureFileNested< + N>, + io.kubernetes.client.fluent.Nested { + AzureFileNestedImpl( + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceBuilder( + this, item); } + AzureFileNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1AzureFilePersistentVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withAzureFile(builder.build()); } + public N endAzureFile() { return and(); } - } - public class CephfsNestedImpl extends io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested,io.kubernetes.client.fluent.Nested{ + + public class CephfsNestedImpl + extends io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CephfsNested, + io.kubernetes.client.fluent.Nested { CephfsNestedImpl(io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceBuilder(this, item); } + CephfsNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1CephFSPersistentVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withCephfs(builder.build()); } + public N endCephfs() { return and(); } - } - public class CinderNestedImpl extends io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested,io.kubernetes.client.fluent.Nested{ + + public class CinderNestedImpl + extends io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CinderNested, + io.kubernetes.client.fluent.Nested { CinderNestedImpl(io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceBuilder(this, item); } + CinderNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1CinderPersistentVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withCinder(builder.build()); } + public N endCinder() { return and(); } - } - public class ClaimRefNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested,io.kubernetes.client.fluent.Nested{ + + public class ClaimRefNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ClaimRefNested, + io.kubernetes.client.fluent.Nested { ClaimRefNestedImpl(io.kubernetes.client.openapi.models.V1ObjectReference item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + ClaimRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withClaimRef(builder.build()); } + public N endClaimRef() { return and(); } - } - public class CsiNestedImpl extends io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested,io.kubernetes.client.fluent.Nested{ + + public class CsiNestedImpl + extends io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.CsiNested, + io.kubernetes.client.fluent.Nested { CsiNestedImpl(io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceBuilder(this, item); } + CsiNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1CSIPersistentVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withCsi(builder.build()); } + public N endCsi() { return and(); } - } - public class FcNestedImpl extends io.kubernetes.client.openapi.models.V1FCVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested,io.kubernetes.client.fluent.Nested{ + + public class FcNestedImpl + extends io.kubernetes.client.openapi.models.V1FCVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FcNested, + io.kubernetes.client.fluent.Nested { FcNestedImpl(io.kubernetes.client.openapi.models.V1FCVolumeSource item) { this.builder = new io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder(this, item); } + FcNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withFc(builder.build()); } + public N endFc() { return and(); } - } - public class FlexVolumeNestedImpl extends io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested,io.kubernetes.client.fluent.Nested{ + + public class FlexVolumeNestedImpl + extends io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlexVolumeNested< + N>, + io.kubernetes.client.fluent.Nested { FlexVolumeNestedImpl(io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceBuilder(this, item); } + FlexVolumeNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1FlexPersistentVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withFlexVolume(builder.build()); } + public N endFlexVolume() { return and(); } - } - public class FlockerNestedImpl extends io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested,io.kubernetes.client.fluent.Nested{ + + public class FlockerNestedImpl + extends io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.FlockerNested, + io.kubernetes.client.fluent.Nested { FlockerNestedImpl(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder(this, item); } + FlockerNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withFlocker(builder.build()); } + public N endFlocker() { return and(); } - } - public class GcePersistentDiskNestedImpl extends io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested,io.kubernetes.client.fluent.Nested{ - GcePersistentDiskNestedImpl(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder(this, item); + + public class GcePersistentDiskNestedImpl + extends io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GcePersistentDiskNested< + N>> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .GcePersistentDiskNested< + N>, + io.kubernetes.client.fluent.Nested { + GcePersistentDiskNestedImpl( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder( + this, item); } + GcePersistentDiskNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withGcePersistentDisk(builder.build()); } + public N endGcePersistentDisk() { return and(); } - } - public class GlusterfsNestedImpl extends io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested,io.kubernetes.client.fluent.Nested{ - GlusterfsNestedImpl(io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceBuilder(this, item); + + public class GlusterfsNestedImpl + extends io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.GlusterfsNested< + N>, + io.kubernetes.client.fluent.Nested { + GlusterfsNestedImpl( + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceBuilder( + this, item); } + GlusterfsNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1GlusterfsPersistentVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withGlusterfs(builder.build()); } + public N endGlusterfs() { return and(); } - } - public class HostPathNestedImpl extends io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested,io.kubernetes.client.fluent.Nested{ + + public class HostPathNestedImpl + extends io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.HostPathNested, + io.kubernetes.client.fluent.Nested { HostPathNestedImpl(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder(this, item); } + HostPathNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withHostPath(builder.build()); } + public N endHostPath() { return and(); } - } - public class IscsiNestedImpl extends io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested,io.kubernetes.client.fluent.Nested{ + + public class IscsiNestedImpl + extends io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.IscsiNested, + io.kubernetes.client.fluent.Nested { IscsiNestedImpl(io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceBuilder(this, item); } + IscsiNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1ISCSIPersistentVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withIscsi(builder.build()); } + public N endIscsi() { return and(); } - } - public class LocalNestedImpl extends io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested,io.kubernetes.client.fluent.Nested{ + + public class LocalNestedImpl + extends io.kubernetes.client.openapi.models.V1LocalVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.LocalNested, + io.kubernetes.client.fluent.Nested { LocalNestedImpl(io.kubernetes.client.openapi.models.V1LocalVolumeSource item) { this.builder = new io.kubernetes.client.openapi.models.V1LocalVolumeSourceBuilder(this, item); } + LocalNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LocalVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1LocalVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withLocal(builder.build()); } + public N endLocal() { return and(); } - } - public class NfsNestedImpl extends io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested,io.kubernetes.client.fluent.Nested{ + + public class NfsNestedImpl + extends io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NfsNested, + io.kubernetes.client.fluent.Nested { NfsNestedImpl(io.kubernetes.client.openapi.models.V1NFSVolumeSource item) { this.builder = new io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder(this, item); } + NfsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withNfs(builder.build()); } + public N endNfs() { return and(); } - } - public class NodeAffinityNestedImpl extends io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested,io.kubernetes.client.fluent.Nested{ + + public class NodeAffinityNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.NodeAffinityNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .NodeAffinityNested< + N>, + io.kubernetes.client.fluent.Nested { NodeAffinityNestedImpl(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity item) { - this.builder = new io.kubernetes.client.openapi.models.V1VolumeNodeAffinityBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1VolumeNodeAffinityBuilder(this, item); } + NodeAffinityNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1VolumeNodeAffinityBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeNodeAffinityBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withNodeAffinity(builder.build()); } + public N endNodeAffinity() { return and(); } - } - public class PhotonPersistentDiskNestedImpl extends io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PhotonPersistentDiskNested,io.kubernetes.client.fluent.Nested{ - PhotonPersistentDiskNestedImpl(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder(this, item); + + public class PhotonPersistentDiskNestedImpl + extends io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PhotonPersistentDiskNested< + N>> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PhotonPersistentDiskNested< + N>, + io.kubernetes.client.fluent.Nested { + PhotonPersistentDiskNestedImpl( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder( + this, item); } + PhotonPersistentDiskNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withPhotonPersistentDisk(builder.build()); } + public N endPhotonPersistentDisk() { return and(); } - } - public class PortworxVolumeNestedImpl extends io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested,io.kubernetes.client.fluent.Nested{ + + public class PortworxVolumeNestedImpl + extends io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.PortworxVolumeNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .PortworxVolumeNested< + N>, + io.kubernetes.client.fluent.Nested { PortworxVolumeNestedImpl(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder(this, item); } + PortworxVolumeNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withPortworxVolume(builder.build()); } + public N endPortworxVolume() { return and(); } - } - public class QuobyteNestedImpl extends io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested,io.kubernetes.client.fluent.Nested{ + + public class QuobyteNestedImpl + extends io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.QuobyteNested, + io.kubernetes.client.fluent.Nested { QuobyteNestedImpl(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder(this, item); } + QuobyteNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withQuobyte(builder.build()); } + public N endQuobyte() { return and(); } - } - public class RbdNestedImpl extends io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested,io.kubernetes.client.fluent.Nested{ + + public class RbdNestedImpl + extends io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.RbdNested, + io.kubernetes.client.fluent.Nested { RbdNestedImpl(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceBuilder(this, item); } + RbdNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withRbd(builder.build()); } + public N endRbd() { return and(); } - } - public class ScaleIONestedImpl extends io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested,io.kubernetes.client.fluent.Nested{ + + public class ScaleIONestedImpl + extends io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.ScaleIONested, + io.kubernetes.client.fluent.Nested { ScaleIONestedImpl(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceBuilder( + this, item); } + ScaleIONestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withScaleIO(builder.build()); } + public N endScaleIO() { return and(); } - } - public class StorageosNestedImpl extends io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested,io.kubernetes.client.fluent.Nested{ - StorageosNestedImpl(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceBuilder(this, item); + + public class StorageosNestedImpl + extends io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.StorageosNested< + N>, + io.kubernetes.client.fluent.Nested { + StorageosNestedImpl( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceBuilder( + this, item); } + StorageosNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withStorageos(builder.build()); } + public N endStorageos() { return and(); } - } - public class VsphereVolumeNestedImpl extends io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested,io.kubernetes.client.fluent.Nested{ - VsphereVolumeNestedImpl(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder(this, item); + + public class VsphereVolumeNestedImpl + extends io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent.VsphereVolumeNested> + implements io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent + .VsphereVolumeNested< + N>, + io.kubernetes.client.fluent.Nested { + VsphereVolumeNestedImpl( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder( + this, item); } + VsphereVolumeNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder builder; + public N and() { return (N) V1PersistentVolumeSpecFluentImpl.this.withVsphereVolume(builder.build()); } + public N endVsphereVolume() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeStatusBuilder.java index b76bba0571..49c8f06d37 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeStatusBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PersistentVolumeStatusBuilder extends io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PersistentVolumeStatusBuilder + extends io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluentImpl< + io.kubernetes.client.openapi.models.V1PersistentVolumeStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PersistentVolumeStatus, + io.kubernetes.client.openapi.models.V1PersistentVolumeStatusBuilder> { public V1PersistentVolumeStatusBuilder() { this(false); } + public V1PersistentVolumeStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1PersistentVolumeStatus(), validationEnabled); } - public V1PersistentVolumeStatusBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent fluent) { + + public V1PersistentVolumeStatusBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent fluent) { this(fluent, false); } - public V1PersistentVolumeStatusBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PersistentVolumeStatusBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PersistentVolumeStatus(), validationEnabled); } - public V1PersistentVolumeStatusBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeStatus instance) { + + public V1PersistentVolumeStatusBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeStatus instance) { this(fluent, instance, false); } - public V1PersistentVolumeStatusBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent fluent,io.kubernetes.client.openapi.models.V1PersistentVolumeStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PersistentVolumeStatusBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent fluent, + io.kubernetes.client.openapi.models.V1PersistentVolumeStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMessage(instance.getMessage()); fluent.withPhase(instance.getPhase()); fluent.withReason(instance.getReason()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PersistentVolumeStatusBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus instance) { - this(instance,false); + + public V1PersistentVolumeStatusBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeStatus instance) { + this(instance, false); } - public V1PersistentVolumeStatusBuilder(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PersistentVolumeStatusBuilder( + io.kubernetes.client.openapi.models.V1PersistentVolumeStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMessage(instance.getMessage()); this.withPhase(instance.getPhase()); this.withReason(instance.getReason()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PersistentVolumeStatus build() { V1PersistentVolumeStatus buildable = new V1PersistentVolumeStatus(); buildable.setMessage(fluent.getMessage()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1PersistentVolumeStatus build() { buildable.setReason(fluent.getReason()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PersistentVolumeStatusBuilder that = (V1PersistentVolumeStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeStatusFluent.java index 619dde3bc9..47cd77903d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeStatusFluent.java @@ -1,35 +1,44 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PersistentVolumeStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PersistentVolumeStatusFluent< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public io.kubernetes.client.openapi.models.V1PersistentVolumeStatus.PhaseEnum getPhase(); + public A withPhase(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus.PhaseEnum phase); + public java.lang.Boolean hasPhase(); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeStatusFluentImpl.java index 7ed25e7779..a2e5e69e0d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PersistentVolumeStatusFluentImpl.java @@ -1,82 +1,99 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1PersistentVolumeStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent{ - public V1PersistentVolumeStatusFluentImpl() { - } - public V1PersistentVolumeStatusFluentImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus instance) { +/** Generated */ +public class V1PersistentVolumeStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PersistentVolumeStatusFluent { + public V1PersistentVolumeStatusFluentImpl() {} + + public V1PersistentVolumeStatusFluentImpl( + io.kubernetes.client.openapi.models.V1PersistentVolumeStatus instance) { this.withMessage(instance.getMessage()); this.withPhase(instance.getPhase()); this.withReason(instance.getReason()); - } + private java.lang.String message; private io.kubernetes.client.openapi.models.V1PersistentVolumeStatus.PhaseEnum phase; private java.lang.String reason; + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public io.kubernetes.client.openapi.models.V1PersistentVolumeStatus.PhaseEnum getPhase() { return this.phase; } + public A withPhase(io.kubernetes.client.openapi.models.V1PersistentVolumeStatus.PhaseEnum phase) { - this.phase=phase; return (A) this; + this.phase = phase; + return (A) this; } + public java.lang.Boolean hasPhase() { return this.phase != null; } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PersistentVolumeStatusFluentImpl that = (V1PersistentVolumeStatusFluentImpl) o; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (phase != null ? !phase.equals(that.phase) :that.phase != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (phase != null ? !phase.equals(that.phase) : that.phase != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(message, phase, reason, super.hashCode()); + return java.util.Objects.hash(message, phase, reason, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PhotonPersistentDiskVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PhotonPersistentDiskVolumeSourceBuilder.java index 17382b387b..5f74eed097 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PhotonPersistentDiskVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PhotonPersistentDiskVolumeSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PhotonPersistentDiskVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PhotonPersistentDiskVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource, + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder> { public V1PhotonPersistentDiskVolumeSourceBuilder() { this(false); } + public V1PhotonPersistentDiskVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1PhotonPersistentDiskVolumeSource(), validationEnabled); } - public V1PhotonPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent fluent) { + + public V1PhotonPersistentDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent fluent) { this(fluent, false); } - public V1PhotonPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PhotonPersistentDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PhotonPersistentDiskVolumeSource(), validationEnabled); } - public V1PhotonPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource instance) { + + public V1PhotonPersistentDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource instance) { this(fluent, instance, false); } - public V1PhotonPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PhotonPersistentDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withPdID(instance.getPdID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PhotonPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource instance) { - this(instance,false); + + public V1PhotonPersistentDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource instance) { + this(instance, false); } - public V1PhotonPersistentDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PhotonPersistentDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withPdID(instance.getPdID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource build() { V1PhotonPersistentDiskVolumeSource buildable = new V1PhotonPersistentDiskVolumeSource(); buildable.setFsType(fluent.getFsType()); buildable.setPdID(fluent.getPdID()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PhotonPersistentDiskVolumeSourceBuilder that = (V1PhotonPersistentDiskVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PhotonPersistentDiskVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PhotonPersistentDiskVolumeSourceFluent.java index 3018bc2fdf..0518468ea6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PhotonPersistentDiskVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PhotonPersistentDiskVolumeSourceFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PhotonPersistentDiskVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PhotonPersistentDiskVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.String getPdID(); + public A withPdID(java.lang.String pdID); + public java.lang.Boolean hasPdID(); - - /** - * Method is deprecated. use withPdID instead. - */ + + /** Method is deprecated. use withPdID instead. */ @java.lang.Deprecated public A withNewPdID(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PhotonPersistentDiskVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PhotonPersistentDiskVolumeSourceFluentImpl.java index 0e2d38a752..46f08ee143 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PhotonPersistentDiskVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PhotonPersistentDiskVolumeSourceFluentImpl.java @@ -1,69 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1PhotonPersistentDiskVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent { + public V1PhotonPersistentDiskVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1PhotonPersistentDiskVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent{ - public V1PhotonPersistentDiskVolumeSourceFluentImpl() { - } - public V1PhotonPersistentDiskVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource instance) { + public V1PhotonPersistentDiskVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource instance) { this.withFsType(instance.getFsType()); this.withPdID(instance.getPdID()); - } + private java.lang.String fsType; private java.lang.String pdID; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.String getPdID() { return this.pdID; } + public A withPdID(java.lang.String pdID) { - this.pdID=pdID; return (A) this; + this.pdID = pdID; + return (A) this; } + public java.lang.Boolean hasPdID() { return this.pdID != null; } - - /** - * Method is deprecated. use withPdID instead. - */ + + /** Method is deprecated. use withPdID instead. */ @java.lang.Deprecated public A withNewPdID(java.lang.String original) { - return (A)withPdID(new String(original)); + return (A) withPdID(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1PhotonPersistentDiskVolumeSourceFluentImpl that = (V1PhotonPersistentDiskVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (pdID != null ? !pdID.equals(that.pdID) :that.pdID != null) return false; + V1PhotonPersistentDiskVolumeSourceFluentImpl that = + (V1PhotonPersistentDiskVolumeSourceFluentImpl) o; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (pdID != null ? !pdID.equals(that.pdID) : that.pdID != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, pdID, super.hashCode()); + return java.util.Objects.hash(fsType, pdID, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityBuilder.java index 6886f41aa4..b7ff2bff2e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityBuilder.java @@ -1,63 +1,106 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodAffinityBuilder extends io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodAffinityBuilder + extends io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl< + io.kubernetes.client.openapi.models.V1PodAffinityBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodAffinity, + io.kubernetes.client.openapi.models.V1PodAffinityBuilder> { public V1PodAffinityBuilder() { this(false); } + public V1PodAffinityBuilder(java.lang.Boolean validationEnabled) { this(new V1PodAffinity(), validationEnabled); } + public V1PodAffinityBuilder(io.kubernetes.client.openapi.models.V1PodAffinityFluent fluent) { this(fluent, false); } - public V1PodAffinityBuilder(io.kubernetes.client.openapi.models.V1PodAffinityFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodAffinityBuilder( + io.kubernetes.client.openapi.models.V1PodAffinityFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodAffinity(), validationEnabled); } - public V1PodAffinityBuilder(io.kubernetes.client.openapi.models.V1PodAffinityFluent fluent,io.kubernetes.client.openapi.models.V1PodAffinity instance) { + + public V1PodAffinityBuilder( + io.kubernetes.client.openapi.models.V1PodAffinityFluent fluent, + io.kubernetes.client.openapi.models.V1PodAffinity instance) { this(fluent, instance, false); } - public V1PodAffinityBuilder(io.kubernetes.client.openapi.models.V1PodAffinityFluent fluent,io.kubernetes.client.openapi.models.V1PodAffinity instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; - fluent.withPreferredDuringSchedulingIgnoredDuringExecution(instance.getPreferredDuringSchedulingIgnoredDuringExecution()); - fluent.withRequiredDuringSchedulingIgnoredDuringExecution(instance.getRequiredDuringSchedulingIgnoredDuringExecution()); + public V1PodAffinityBuilder( + io.kubernetes.client.openapi.models.V1PodAffinityFluent fluent, + io.kubernetes.client.openapi.models.V1PodAffinity instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; + fluent.withPreferredDuringSchedulingIgnoredDuringExecution( + instance.getPreferredDuringSchedulingIgnoredDuringExecution()); + + fluent.withRequiredDuringSchedulingIgnoredDuringExecution( + instance.getRequiredDuringSchedulingIgnoredDuringExecution()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodAffinityBuilder(io.kubernetes.client.openapi.models.V1PodAffinity instance) { - this(instance,false); + this(instance, false); } - public V1PodAffinityBuilder(io.kubernetes.client.openapi.models.V1PodAffinity instance,java.lang.Boolean validationEnabled) { - this.fluent = this; - this.withPreferredDuringSchedulingIgnoredDuringExecution(instance.getPreferredDuringSchedulingIgnoredDuringExecution()); - this.withRequiredDuringSchedulingIgnoredDuringExecution(instance.getRequiredDuringSchedulingIgnoredDuringExecution()); + public V1PodAffinityBuilder( + io.kubernetes.client.openapi.models.V1PodAffinity instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; + this.withPreferredDuringSchedulingIgnoredDuringExecution( + instance.getPreferredDuringSchedulingIgnoredDuringExecution()); - this.validationEnabled = validationEnabled; + this.withRequiredDuringSchedulingIgnoredDuringExecution( + instance.getRequiredDuringSchedulingIgnoredDuringExecution()); + + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodAffinityFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodAffinity build() { V1PodAffinity buildable = new V1PodAffinity(); - buildable.setPreferredDuringSchedulingIgnoredDuringExecution(fluent.getPreferredDuringSchedulingIgnoredDuringExecution()); - buildable.setRequiredDuringSchedulingIgnoredDuringExecution(fluent.getRequiredDuringSchedulingIgnoredDuringExecution()); + buildable.setPreferredDuringSchedulingIgnoredDuringExecution( + fluent.getPreferredDuringSchedulingIgnoredDuringExecution()); + buildable.setRequiredDuringSchedulingIgnoredDuringExecution( + fluent.getRequiredDuringSchedulingIgnoredDuringExecution()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodAffinityBuilder that = (V1PodAffinityBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityFluent.java index 7b9b5bb91e..57d54eca9e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityFluent.java @@ -1,92 +1,249 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodAffinityFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); - public A setToPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); - public A addToPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items); - public A addAllToPreferredDuringSchedulingIgnoredDuringExecution(java.util.Collection items); - public A removeFromPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items); - public A removeAllFromPreferredDuringSchedulingIgnoredDuringExecution(java.util.Collection items); - public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - +/** Generated */ +public interface V1PodAffinityFluent< + A extends io.kubernetes.client.openapi.models.V1PodAffinityFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToPreferredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); + + public A setToPreferredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); + + public A addToPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items); + + public A addAllToPreferredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items); + + public A removeFromPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items); + + public A removeAllFromPreferredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items); + + public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate); + /** - * This method has been deprecated, please use method buildPreferredDuringSchedulingIgnoredDuringExecution instead. + * This method has been deprecated, please use method + * buildPreferredDuringSchedulingIgnoredDuringExecution instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getPreferredDuringSchedulingIgnoredDuringExecution(); - public java.util.List buildPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildFirstPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildLastPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public A withPreferredDuringSchedulingIgnoredDuringExecution(java.util.List preferredDuringSchedulingIgnoredDuringExecution); - public A withPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... preferredDuringSchedulingIgnoredDuringExecution); + public java.util.List + getPreferredDuringSchedulingIgnoredDuringExecution(); + + public java.util.List + buildPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildFirstPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildLastPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate); + + public java.lang.Boolean hasMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate); + + public A withPreferredDuringSchedulingIgnoredDuringExecution( + java.util.List + preferredDuringSchedulingIgnoredDuringExecution); + + public A withPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... + preferredDuringSchedulingIgnoredDuringExecution); + public java.lang.Boolean hasPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested addNewPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested addNewPreferredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editFirstPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editLastPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public A addToRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodAffinityTerm item); - public A setToRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodAffinityTerm item); - public A addToRequiredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PodAffinityTerm... items); - public A addAllToRequiredDuringSchedulingIgnoredDuringExecution(java.util.Collection items); - public A removeFromRequiredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PodAffinityTerm... items); - public A removeAllFromRequiredDuringSchedulingIgnoredDuringExecution(java.util.Collection items); - public A removeMatchingFromRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editFirstPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editLastPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate); + + public A addToRequiredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item); + + public A setToRequiredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item); + + public A addToRequiredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PodAffinityTerm... items); + + public A addAllToRequiredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items); + + public A removeFromRequiredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PodAffinityTerm... items); + + public A removeAllFromRequiredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items); + + public A removeMatchingFromRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate); + /** - * This method has been deprecated, please use method buildRequiredDuringSchedulingIgnoredDuringExecution instead. + * This method has been deprecated, please use method + * buildRequiredDuringSchedulingIgnoredDuringExecution instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getRequiredDuringSchedulingIgnoredDuringExecution(); - public java.util.List buildRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildFirstRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildLastRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildMatchingRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public A withRequiredDuringSchedulingIgnoredDuringExecution(java.util.List requiredDuringSchedulingIgnoredDuringExecution); - public A withRequiredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PodAffinityTerm... requiredDuringSchedulingIgnoredDuringExecution); + public java.util.List + getRequiredDuringSchedulingIgnoredDuringExecution(); + + public java.util.List + buildRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildFirstRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildLastRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildMatchingRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate); + + public A withRequiredDuringSchedulingIgnoredDuringExecution( + java.util.List + requiredDuringSchedulingIgnoredDuringExecution); + + public A withRequiredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PodAffinityTerm... + requiredDuringSchedulingIgnoredDuringExecution); + public java.lang.Boolean hasRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested addNewRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested addNewRequiredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1PodAffinityTerm item); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested setNewRequiredDuringSchedulingIgnoredDuringExecutionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodAffinityTerm item); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editFirstRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editLastRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editMatchingRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public interface PreferredDuringSchedulingIgnoredDuringExecutionNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent>{ + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1PodAffinityTerm item); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + setNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editFirstRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editLastRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editMatchingRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate); + + public interface PreferredDuringSchedulingIgnoredDuringExecutionNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent< + io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + N>> { public N and(); + public N endPreferredDuringSchedulingIgnoredDuringExecution(); - } - public interface RequiredDuringSchedulingIgnoredDuringExecutionNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodAffinityTermFluent>{ + + public interface RequiredDuringSchedulingIgnoredDuringExecutionNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodAffinityTermFluent< + io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + N>> { public N and(); + public N endRequiredDuringSchedulingIgnoredDuringExecution(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityFluentImpl.java index 57314a5edc..209087098e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityFluentImpl.java @@ -1,60 +1,149 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1PodAffinityFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodAffinityFluent{ - public V1PodAffinityFluentImpl() { - } - public V1PodAffinityFluentImpl(io.kubernetes.client.openapi.models.V1PodAffinity instance) { - this.withPreferredDuringSchedulingIgnoredDuringExecution(instance.getPreferredDuringSchedulingIgnoredDuringExecution()); +/** Generated */ +public class V1PodAffinityFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodAffinityFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodAffinityFluent { + public V1PodAffinityFluentImpl() {} - this.withRequiredDuringSchedulingIgnoredDuringExecution(instance.getRequiredDuringSchedulingIgnoredDuringExecution()); + public V1PodAffinityFluentImpl(io.kubernetes.client.openapi.models.V1PodAffinity instance) { + this.withPreferredDuringSchedulingIgnoredDuringExecution( + instance.getPreferredDuringSchedulingIgnoredDuringExecution()); + this.withRequiredDuringSchedulingIgnoredDuringExecution( + instance.getRequiredDuringSchedulingIgnoredDuringExecution()); } - private java.util.ArrayList preferredDuringSchedulingIgnoredDuringExecution; - private java.util.ArrayList requiredDuringSchedulingIgnoredDuringExecution; - public A addToPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { - if (this.preferredDuringSchedulingIgnoredDuringExecution == null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(index >= 0 ? index : _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").size(), builder);this.preferredDuringSchedulingIgnoredDuringExecution.add(index >= 0 ? index : preferredDuringSchedulingIgnoredDuringExecution.size(), builder); return (A)this; + + private java.util.ArrayList + preferredDuringSchedulingIgnoredDuringExecution; + private java.util.ArrayList + requiredDuringSchedulingIgnoredDuringExecution; + + public A addToPreferredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { + if (this.preferredDuringSchedulingIgnoredDuringExecution == null) { + this.preferredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder>(); + } + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); + _visitables + .get("preferredDuringSchedulingIgnoredDuringExecution") + .add( + index >= 0 + ? index + : _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").size(), + builder); + this.preferredDuringSchedulingIgnoredDuringExecution.add( + index >= 0 ? index : preferredDuringSchedulingIgnoredDuringExecution.size(), builder); + return (A) this; } - public A setToPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { - if (this.preferredDuringSchedulingIgnoredDuringExecution == null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); - if (index < 0 || index >= _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").size()) { _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder); } else { _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").set(index, builder);} - if (index < 0 || index >= preferredDuringSchedulingIgnoredDuringExecution.size()) { preferredDuringSchedulingIgnoredDuringExecution.add(builder); } else { preferredDuringSchedulingIgnoredDuringExecution.set(index, builder);} - return (A)this; + + public A setToPreferredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { + if (this.preferredDuringSchedulingIgnoredDuringExecution == null) { + this.preferredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder>(); + } + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); + if (index < 0 + || index >= _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").size()) { + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder); + } else { + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").set(index, builder); + } + if (index < 0 || index >= preferredDuringSchedulingIgnoredDuringExecution.size()) { + preferredDuringSchedulingIgnoredDuringExecution.add(builder); + } else { + preferredDuringSchedulingIgnoredDuringExecution.set(index, builder); + } + return (A) this; } - public A addToPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items) { - if (this.preferredDuringSchedulingIgnoredDuringExecution == null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder);this.preferredDuringSchedulingIgnoredDuringExecution.add(builder);} return (A)this; + + public A addToPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items) { + if (this.preferredDuringSchedulingIgnoredDuringExecution == null) { + this.preferredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder); + this.preferredDuringSchedulingIgnoredDuringExecution.add(builder); + } + return (A) this; } - public A addAllToPreferredDuringSchedulingIgnoredDuringExecution(java.util.Collection items) { - if (this.preferredDuringSchedulingIgnoredDuringExecution == null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder);this.preferredDuringSchedulingIgnoredDuringExecution.add(builder);} return (A)this; + + public A addAllToPreferredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items) { + if (this.preferredDuringSchedulingIgnoredDuringExecution == null) { + this.preferredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder); + this.preferredDuringSchedulingIgnoredDuringExecution.add(builder); + } + return (A) this; } - public A removeFromPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items) { - for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").remove(builder);if (this.preferredDuringSchedulingIgnoredDuringExecution != null) {this.preferredDuringSchedulingIgnoredDuringExecution.remove(builder);}} return (A)this; + + public A removeFromPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items) { + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").remove(builder); + if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { + this.preferredDuringSchedulingIgnoredDuringExecution.remove(builder); + } + } + return (A) this; } - public A removeAllFromPreferredDuringSchedulingIgnoredDuringExecution(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").remove(builder);if (this.preferredDuringSchedulingIgnoredDuringExecution != null) {this.preferredDuringSchedulingIgnoredDuringExecution.remove(builder);}} return (A)this; + + public A removeAllFromPreferredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").remove(builder); + if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { + this.preferredDuringSchedulingIgnoredDuringExecution.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { + + public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate) { if (preferredDuringSchedulingIgnoredDuringExecution == null) return (A) this; - final Iterator each = preferredDuringSchedulingIgnoredDuringExecution.iterator(); + final Iterator each = + preferredDuringSchedulingIgnoredDuringExecution.iterator(); final List visitables = _visitables.get("preferredDuringSchedulingIgnoredDuringExecution"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = each.next(); @@ -63,104 +152,300 @@ public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution(java. each.remove(); } } - return (A)this; + return (A) this; } - + /** - * This method has been deprecated, please use method buildPreferredDuringSchedulingIgnoredDuringExecution instead. + * This method has been deprecated, please use method + * buildPreferredDuringSchedulingIgnoredDuringExecution instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getPreferredDuringSchedulingIgnoredDuringExecution() { - return preferredDuringSchedulingIgnoredDuringExecution != null ? build(preferredDuringSchedulingIgnoredDuringExecution) : null; + public java.util.List + getPreferredDuringSchedulingIgnoredDuringExecution() { + return preferredDuringSchedulingIgnoredDuringExecution != null + ? build(preferredDuringSchedulingIgnoredDuringExecution) + : null; } - public java.util.List buildPreferredDuringSchedulingIgnoredDuringExecution() { - return preferredDuringSchedulingIgnoredDuringExecution != null ? build(preferredDuringSchedulingIgnoredDuringExecution) : null; + + public java.util.List + buildPreferredDuringSchedulingIgnoredDuringExecution() { + return preferredDuringSchedulingIgnoredDuringExecution != null + ? build(preferredDuringSchedulingIgnoredDuringExecution) + : null; } - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { return this.preferredDuringSchedulingIgnoredDuringExecution.get(index).build(); } - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildFirstPreferredDuringSchedulingIgnoredDuringExecution() { + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildFirstPreferredDuringSchedulingIgnoredDuringExecution() { return this.preferredDuringSchedulingIgnoredDuringExecution.get(0).build(); } - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildLastPreferredDuringSchedulingIgnoredDuringExecution() { - return this.preferredDuringSchedulingIgnoredDuringExecution.get(preferredDuringSchedulingIgnoredDuringExecution.size() - 1).build(); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildLastPreferredDuringSchedulingIgnoredDuringExecution() { + return this.preferredDuringSchedulingIgnoredDuringExecution + .get(preferredDuringSchedulingIgnoredDuringExecution.size() - 1) + .build(); } - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder item: preferredDuringSchedulingIgnoredDuringExecution) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder item : + preferredDuringSchedulingIgnoredDuringExecution) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder item: preferredDuringSchedulingIgnoredDuringExecution) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder item : + preferredDuringSchedulingIgnoredDuringExecution) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withPreferredDuringSchedulingIgnoredDuringExecution(java.util.List preferredDuringSchedulingIgnoredDuringExecution) { - if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").removeAll(this.preferredDuringSchedulingIgnoredDuringExecution);} - if (preferredDuringSchedulingIgnoredDuringExecution != null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : preferredDuringSchedulingIgnoredDuringExecution){this.addToPreferredDuringSchedulingIgnoredDuringExecution(item);}} else { this.preferredDuringSchedulingIgnoredDuringExecution = null;} return (A) this; + + public A withPreferredDuringSchedulingIgnoredDuringExecution( + java.util.List + preferredDuringSchedulingIgnoredDuringExecution) { + if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { + _visitables + .get("preferredDuringSchedulingIgnoredDuringExecution") + .removeAll(this.preferredDuringSchedulingIgnoredDuringExecution); + } + if (preferredDuringSchedulingIgnoredDuringExecution != null) { + this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : + preferredDuringSchedulingIgnoredDuringExecution) { + this.addToPreferredDuringSchedulingIgnoredDuringExecution(item); + } + } else { + this.preferredDuringSchedulingIgnoredDuringExecution = null; + } + return (A) this; } - public A withPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... preferredDuringSchedulingIgnoredDuringExecution) { - if (this.preferredDuringSchedulingIgnoredDuringExecution != null) {this.preferredDuringSchedulingIgnoredDuringExecution.clear();} - if (preferredDuringSchedulingIgnoredDuringExecution != null) {for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item :preferredDuringSchedulingIgnoredDuringExecution){ this.addToPreferredDuringSchedulingIgnoredDuringExecution(item);}} return (A) this; + + public A withPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... + preferredDuringSchedulingIgnoredDuringExecution) { + if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { + this.preferredDuringSchedulingIgnoredDuringExecution.clear(); + } + if (preferredDuringSchedulingIgnoredDuringExecution != null) { + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : + preferredDuringSchedulingIgnoredDuringExecution) { + this.addToPreferredDuringSchedulingIgnoredDuringExecution(item); + } + } + return (A) this; } + public java.lang.Boolean hasPreferredDuringSchedulingIgnoredDuringExecution() { - return preferredDuringSchedulingIgnoredDuringExecution != null && !preferredDuringSchedulingIgnoredDuringExecution.isEmpty(); + return preferredDuringSchedulingIgnoredDuringExecution != null + && !preferredDuringSchedulingIgnoredDuringExecution.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested addNewPreferredDuringSchedulingIgnoredDuringExecution() { - return new io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl.PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewPreferredDuringSchedulingIgnoredDuringExecution() { + return new io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl + .PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested addNewPreferredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { - return new io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl.PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { + return new io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl + .PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { - return new io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl.PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { + return new io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl + .PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { - if (preferredDuringSchedulingIgnoredDuringExecution.size() <= index) throw new RuntimeException("Can't edit preferredDuringSchedulingIgnoredDuringExecution. Index exceeds size."); - return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { + if (preferredDuringSchedulingIgnoredDuringExecution.size() <= index) + throw new RuntimeException( + "Can't edit preferredDuringSchedulingIgnoredDuringExecution. Index exceeds size."); + return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editFirstPreferredDuringSchedulingIgnoredDuringExecution() { - if (preferredDuringSchedulingIgnoredDuringExecution.size() == 0) throw new RuntimeException("Can't edit first preferredDuringSchedulingIgnoredDuringExecution. The list is empty."); - return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(0, buildPreferredDuringSchedulingIgnoredDuringExecution(0)); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editFirstPreferredDuringSchedulingIgnoredDuringExecution() { + if (preferredDuringSchedulingIgnoredDuringExecution.size() == 0) + throw new RuntimeException( + "Can't edit first preferredDuringSchedulingIgnoredDuringExecution. The list is empty."); + return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + 0, buildPreferredDuringSchedulingIgnoredDuringExecution(0)); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editLastPreferredDuringSchedulingIgnoredDuringExecution() { + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editLastPreferredDuringSchedulingIgnoredDuringExecution() { int index = preferredDuringSchedulingIgnoredDuringExecution.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last preferredDuringSchedulingIgnoredDuringExecution. The list is empty."); - return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); + if (index < 0) + throw new RuntimeException( + "Can't edit last preferredDuringSchedulingIgnoredDuringExecution. The list is empty."); + return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item);_visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(index >= 0 ? index : _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").size(), builder);this.requiredDuringSchedulingIgnoredDuringExecution.add(index >= 0 ? index : requiredDuringSchedulingIgnoredDuringExecution.size(), builder); return (A)this; - } - public A setToRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { - if (this.requiredDuringSchedulingIgnoredDuringExecution == null) {this.requiredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); - if (index < 0 || index >= _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").size()) { _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(builder); } else { _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").set(index, builder);} - if (index < 0 || index >= requiredDuringSchedulingIgnoredDuringExecution.size()) { requiredDuringSchedulingIgnoredDuringExecution.add(builder); } else { requiredDuringSchedulingIgnoredDuringExecution.set(index, builder);} - return (A)this; - } - public A addToRequiredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PodAffinityTerm... items) { - if (this.requiredDuringSchedulingIgnoredDuringExecution == null) {this.requiredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item);_visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(builder);this.requiredDuringSchedulingIgnoredDuringExecution.add(builder);} return (A)this; - } - public A addAllToRequiredDuringSchedulingIgnoredDuringExecution(java.util.Collection items) { - if (this.requiredDuringSchedulingIgnoredDuringExecution == null) {this.requiredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item);_visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(builder);this.requiredDuringSchedulingIgnoredDuringExecution.add(builder);} return (A)this; - } - public A removeFromRequiredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PodAffinityTerm... items) { - for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item);_visitables.get("requiredDuringSchedulingIgnoredDuringExecution").remove(builder);if (this.requiredDuringSchedulingIgnoredDuringExecution != null) {this.requiredDuringSchedulingIgnoredDuringExecution.remove(builder);}} return (A)this; - } - public A removeAllFromRequiredDuringSchedulingIgnoredDuringExecution(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item);_visitables.get("requiredDuringSchedulingIgnoredDuringExecution").remove(builder);if (this.requiredDuringSchedulingIgnoredDuringExecution != null) {this.requiredDuringSchedulingIgnoredDuringExecution.remove(builder);}} return (A)this; - } - public A removeMatchingFromRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { + for (int i = 0; i < preferredDuringSchedulingIgnoredDuringExecution.size(); i++) { + if (predicate.test(preferredDuringSchedulingIgnoredDuringExecution.get(i))) { + index = i; + break; + } + } + if (index < 0) + throw new RuntimeException( + "Can't edit matching preferredDuringSchedulingIgnoredDuringExecution. No match found."); + return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); + } + + public A addToRequiredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { + if (this.requiredDuringSchedulingIgnoredDuringExecution == null) { + this.requiredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); + _visitables + .get("requiredDuringSchedulingIgnoredDuringExecution") + .add( + index >= 0 + ? index + : _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").size(), + builder); + this.requiredDuringSchedulingIgnoredDuringExecution.add( + index >= 0 ? index : requiredDuringSchedulingIgnoredDuringExecution.size(), builder); + return (A) this; + } + + public A setToRequiredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { + if (this.requiredDuringSchedulingIgnoredDuringExecution == null) { + this.requiredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); + if (index < 0 + || index >= _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").size()) { + _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(builder); + } else { + _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").set(index, builder); + } + if (index < 0 || index >= requiredDuringSchedulingIgnoredDuringExecution.size()) { + requiredDuringSchedulingIgnoredDuringExecution.add(builder); + } else { + requiredDuringSchedulingIgnoredDuringExecution.set(index, builder); + } + return (A) this; + } + + public A addToRequiredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PodAffinityTerm... items) { + if (this.requiredDuringSchedulingIgnoredDuringExecution == null) { + this.requiredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); + _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(builder); + this.requiredDuringSchedulingIgnoredDuringExecution.add(builder); + } + return (A) this; + } + + public A addAllToRequiredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items) { + if (this.requiredDuringSchedulingIgnoredDuringExecution == null) { + this.requiredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); + _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(builder); + this.requiredDuringSchedulingIgnoredDuringExecution.add(builder); + } + return (A) this; + } + + public A removeFromRequiredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PodAffinityTerm... items) { + for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); + _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").remove(builder); + if (this.requiredDuringSchedulingIgnoredDuringExecution != null) { + this.requiredDuringSchedulingIgnoredDuringExecution.remove(builder); + } + } + return (A) this; + } + + public A removeAllFromRequiredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); + _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").remove(builder); + if (this.requiredDuringSchedulingIgnoredDuringExecution != null) { + this.requiredDuringSchedulingIgnoredDuringExecution.remove(builder); + } + } + return (A) this; + } + + public A removeMatchingFromRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate) { if (requiredDuringSchedulingIgnoredDuringExecution == null) return (A) this; - final Iterator each = requiredDuringSchedulingIgnoredDuringExecution.iterator(); + final Iterator each = + requiredDuringSchedulingIgnoredDuringExecution.iterator(); final List visitables = _visitables.get("requiredDuringSchedulingIgnoredDuringExecution"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = each.next(); @@ -169,124 +454,281 @@ public A removeMatchingFromRequiredDuringSchedulingIgnoredDuringExecution(java.u each.remove(); } } - return (A)this; + return (A) this; } - + /** - * This method has been deprecated, please use method buildRequiredDuringSchedulingIgnoredDuringExecution instead. + * This method has been deprecated, please use method + * buildRequiredDuringSchedulingIgnoredDuringExecution instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getRequiredDuringSchedulingIgnoredDuringExecution() { - return requiredDuringSchedulingIgnoredDuringExecution != null ? build(requiredDuringSchedulingIgnoredDuringExecution) : null; + public java.util.List + getRequiredDuringSchedulingIgnoredDuringExecution() { + return requiredDuringSchedulingIgnoredDuringExecution != null + ? build(requiredDuringSchedulingIgnoredDuringExecution) + : null; } - public java.util.List buildRequiredDuringSchedulingIgnoredDuringExecution() { - return requiredDuringSchedulingIgnoredDuringExecution != null ? build(requiredDuringSchedulingIgnoredDuringExecution) : null; + + public java.util.List + buildRequiredDuringSchedulingIgnoredDuringExecution() { + return requiredDuringSchedulingIgnoredDuringExecution != null + ? build(requiredDuringSchedulingIgnoredDuringExecution) + : null; } - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { return this.requiredDuringSchedulingIgnoredDuringExecution.get(index).build(); } - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildFirstRequiredDuringSchedulingIgnoredDuringExecution() { + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildFirstRequiredDuringSchedulingIgnoredDuringExecution() { return this.requiredDuringSchedulingIgnoredDuringExecution.get(0).build(); } - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildLastRequiredDuringSchedulingIgnoredDuringExecution() { - return this.requiredDuringSchedulingIgnoredDuringExecution.get(requiredDuringSchedulingIgnoredDuringExecution.size() - 1).build(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildLastRequiredDuringSchedulingIgnoredDuringExecution() { + return this.requiredDuringSchedulingIgnoredDuringExecution + .get(requiredDuringSchedulingIgnoredDuringExecution.size() - 1) + .build(); } - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildMatchingRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder item: requiredDuringSchedulingIgnoredDuringExecution) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildMatchingRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder item : + requiredDuringSchedulingIgnoredDuringExecution) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder item: requiredDuringSchedulingIgnoredDuringExecution) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder item : + requiredDuringSchedulingIgnoredDuringExecution) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withRequiredDuringSchedulingIgnoredDuringExecution(java.util.List requiredDuringSchedulingIgnoredDuringExecution) { - if (this.requiredDuringSchedulingIgnoredDuringExecution != null) { _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").removeAll(this.requiredDuringSchedulingIgnoredDuringExecution);} - if (requiredDuringSchedulingIgnoredDuringExecution != null) {this.requiredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : requiredDuringSchedulingIgnoredDuringExecution){this.addToRequiredDuringSchedulingIgnoredDuringExecution(item);}} else { this.requiredDuringSchedulingIgnoredDuringExecution = null;} return (A) this; + + public A withRequiredDuringSchedulingIgnoredDuringExecution( + java.util.List + requiredDuringSchedulingIgnoredDuringExecution) { + if (this.requiredDuringSchedulingIgnoredDuringExecution != null) { + _visitables + .get("requiredDuringSchedulingIgnoredDuringExecution") + .removeAll(this.requiredDuringSchedulingIgnoredDuringExecution); + } + if (requiredDuringSchedulingIgnoredDuringExecution != null) { + this.requiredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : + requiredDuringSchedulingIgnoredDuringExecution) { + this.addToRequiredDuringSchedulingIgnoredDuringExecution(item); + } + } else { + this.requiredDuringSchedulingIgnoredDuringExecution = null; + } + return (A) this; } - public A withRequiredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PodAffinityTerm... requiredDuringSchedulingIgnoredDuringExecution) { - if (this.requiredDuringSchedulingIgnoredDuringExecution != null) {this.requiredDuringSchedulingIgnoredDuringExecution.clear();} - if (requiredDuringSchedulingIgnoredDuringExecution != null) {for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item :requiredDuringSchedulingIgnoredDuringExecution){ this.addToRequiredDuringSchedulingIgnoredDuringExecution(item);}} return (A) this; + + public A withRequiredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PodAffinityTerm... + requiredDuringSchedulingIgnoredDuringExecution) { + if (this.requiredDuringSchedulingIgnoredDuringExecution != null) { + this.requiredDuringSchedulingIgnoredDuringExecution.clear(); + } + if (requiredDuringSchedulingIgnoredDuringExecution != null) { + for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : + requiredDuringSchedulingIgnoredDuringExecution) { + this.addToRequiredDuringSchedulingIgnoredDuringExecution(item); + } + } + return (A) this; } + public java.lang.Boolean hasRequiredDuringSchedulingIgnoredDuringExecution() { - return requiredDuringSchedulingIgnoredDuringExecution != null && !requiredDuringSchedulingIgnoredDuringExecution.isEmpty(); + return requiredDuringSchedulingIgnoredDuringExecution != null + && !requiredDuringSchedulingIgnoredDuringExecution.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested addNewRequiredDuringSchedulingIgnoredDuringExecution() { - return new io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl.RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewRequiredDuringSchedulingIgnoredDuringExecution() { + return new io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl + .RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested addNewRequiredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { - return new io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl.RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { + return new io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl + .RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested setNewRequiredDuringSchedulingIgnoredDuringExecutionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { - return new io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl.RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + setNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { + return new io.kubernetes.client.openapi.models.V1PodAffinityFluentImpl + .RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { - if (requiredDuringSchedulingIgnoredDuringExecution.size() <= index) throw new RuntimeException("Can't edit requiredDuringSchedulingIgnoredDuringExecution. Index exceeds size."); - return setNewRequiredDuringSchedulingIgnoredDuringExecutionLike(index, buildRequiredDuringSchedulingIgnoredDuringExecution(index)); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { + if (requiredDuringSchedulingIgnoredDuringExecution.size() <= index) + throw new RuntimeException( + "Can't edit requiredDuringSchedulingIgnoredDuringExecution. Index exceeds size."); + return setNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + index, buildRequiredDuringSchedulingIgnoredDuringExecution(index)); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editFirstRequiredDuringSchedulingIgnoredDuringExecution() { - if (requiredDuringSchedulingIgnoredDuringExecution.size() == 0) throw new RuntimeException("Can't edit first requiredDuringSchedulingIgnoredDuringExecution. The list is empty."); - return setNewRequiredDuringSchedulingIgnoredDuringExecutionLike(0, buildRequiredDuringSchedulingIgnoredDuringExecution(0)); + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editFirstRequiredDuringSchedulingIgnoredDuringExecution() { + if (requiredDuringSchedulingIgnoredDuringExecution.size() == 0) + throw new RuntimeException( + "Can't edit first requiredDuringSchedulingIgnoredDuringExecution. The list is empty."); + return setNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + 0, buildRequiredDuringSchedulingIgnoredDuringExecution(0)); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editLastRequiredDuringSchedulingIgnoredDuringExecution() { + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editLastRequiredDuringSchedulingIgnoredDuringExecution() { int index = requiredDuringSchedulingIgnoredDuringExecution.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last requiredDuringSchedulingIgnoredDuringExecution. The list is empty."); - return setNewRequiredDuringSchedulingIgnoredDuringExecutionLike(index, buildRequiredDuringSchedulingIgnoredDuringExecution(index)); + if (index < 0) + throw new RuntimeException( + "Can't edit last requiredDuringSchedulingIgnoredDuringExecution. The list is empty."); + return setNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + index, buildRequiredDuringSchedulingIgnoredDuringExecution(index)); } - public io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editMatchingRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editMatchingRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluentImpl> implements io.kubernetes.client.openapi.models.V1PodAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested,io.kubernetes.client.fluent.Nested{ - PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { + + public class PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl + extends io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluentImpl< + io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + N>> + implements io.kubernetes.client.openapi.models.V1PodAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + N>, + io.kubernetes.client.fluent.Nested { + PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(this, item); } + PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(this); } + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodAffinityFluentImpl.this.setToPreferredDuringSchedulingIgnoredDuringExecution(index,builder.build()); + return (N) + V1PodAffinityFluentImpl.this.setToPreferredDuringSchedulingIgnoredDuringExecution( + index, builder.build()); } + public N endPreferredDuringSchedulingIgnoredDuringExecution() { return and(); } - } - public class RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl extends io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl> implements io.kubernetes.client.openapi.models.V1PodAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested,io.kubernetes.client.fluent.Nested{ - RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { + + public class RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl + extends io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl< + io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + N>> + implements io.kubernetes.client.openapi.models.V1PodAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + N>, + io.kubernetes.client.fluent.Nested { + RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(this, item); } + RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(this); } + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodAffinityFluentImpl.this.setToRequiredDuringSchedulingIgnoredDuringExecution(index,builder.build()); + return (N) + V1PodAffinityFluentImpl.this.setToRequiredDuringSchedulingIgnoredDuringExecution( + index, builder.build()); } + public N endRequiredDuringSchedulingIgnoredDuringExecution() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityTermBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityTermBuilder.java index 6f31317850..7a8ffdc18f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityTermBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityTermBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodAffinityTermBuilder extends io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodAffinityTermBuilder + extends io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl< + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodAffinityTerm, + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder> { public V1PodAffinityTermBuilder() { this(false); } + public V1PodAffinityTermBuilder(java.lang.Boolean validationEnabled) { this(new V1PodAffinityTerm(), validationEnabled); } - public V1PodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1PodAffinityTermFluent fluent) { + + public V1PodAffinityTermBuilder( + io.kubernetes.client.openapi.models.V1PodAffinityTermFluent fluent) { this(fluent, false); } - public V1PodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1PodAffinityTermFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodAffinityTermBuilder( + io.kubernetes.client.openapi.models.V1PodAffinityTermFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodAffinityTerm(), validationEnabled); } - public V1PodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1PodAffinityTermFluent fluent,io.kubernetes.client.openapi.models.V1PodAffinityTerm instance) { + + public V1PodAffinityTermBuilder( + io.kubernetes.client.openapi.models.V1PodAffinityTermFluent fluent, + io.kubernetes.client.openapi.models.V1PodAffinityTerm instance) { this(fluent, instance, false); } - public V1PodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1PodAffinityTermFluent fluent,io.kubernetes.client.openapi.models.V1PodAffinityTerm instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodAffinityTermBuilder( + io.kubernetes.client.openapi.models.V1PodAffinityTermFluent fluent, + io.kubernetes.client.openapi.models.V1PodAffinityTerm instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLabelSelector(instance.getLabelSelector()); fluent.withNamespaceSelector(instance.getNamespaceSelector()); @@ -29,13 +56,17 @@ public V1PodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1PodAffinit fluent.withTopologyKey(instance.getTopologyKey()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1PodAffinityTerm instance) { - this(instance,false); + this(instance, false); } - public V1PodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1PodAffinityTerm instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodAffinityTermBuilder( + io.kubernetes.client.openapi.models.V1PodAffinityTerm instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLabelSelector(instance.getLabelSelector()); this.withNamespaceSelector(instance.getNamespaceSelector()); @@ -44,10 +75,12 @@ public V1PodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1PodAffinit this.withTopologyKey(instance.getTopologyKey()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodAffinityTermFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodAffinityTerm build() { V1PodAffinityTerm buildable = new V1PodAffinityTerm(); buildable.setLabelSelector(fluent.getLabelSelector()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1PodAffinityTerm build() { buildable.setTopologyKey(fluent.getTopologyKey()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodAffinityTermBuilder that = (V1PodAffinityTermBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityTermFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityTermFluent.java index d07fbc3cda..d1bd80286d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityTermFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityTermFluent.java @@ -1,85 +1,141 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodAffinityTermFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1PodAffinityTermFluent< + A extends io.kubernetes.client.openapi.models.V1PodAffinityTermFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildLabelSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getLabelSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildLabelSelector(); + public A withLabelSelector(io.kubernetes.client.openapi.models.V1LabelSelector labelSelector); + public java.lang.Boolean hasLabelSelector(); - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested withNewLabelSelector(); - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested withNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested editLabelSelector(); - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested editOrNewLabelSelector(); - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested editOrNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested + withNewLabelSelector(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested + withNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested + editLabelSelector(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested + editOrNewLabelSelector(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested + editOrNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + /** * This method has been deprecated, please use method buildNamespaceSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getNamespaceSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildNamespaceSelector(); - public A withNamespaceSelector(io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector); + + public A withNamespaceSelector( + io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector); + public java.lang.Boolean hasNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested withNewNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested editNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested editOrNewNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public A addToNamespaces(java.lang.Integer index,java.lang.String item); - public A setToNamespaces(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested + withNewNamespaceSelector(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested + withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested + editNamespaceSelector(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested + editOrNewNamespaceSelector(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested + editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public A addToNamespaces(java.lang.Integer index, java.lang.String item); + + public A setToNamespaces(java.lang.Integer index, java.lang.String item); + public A addToNamespaces(java.lang.String... items); + public A addAllToNamespaces(java.util.Collection items); + public A removeFromNamespaces(java.lang.String... items); + public A removeAllFromNamespaces(java.util.Collection items); + public java.util.List getNamespaces(); + public java.lang.String getNamespace(java.lang.Integer index); + public java.lang.String getFirstNamespace(); + public java.lang.String getLastNamespace(); - public java.lang.String getMatchingNamespace(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingNamespace(java.util.function.Predicate predicate); + + public java.lang.String getMatchingNamespace( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingNamespace( + java.util.function.Predicate predicate); + public A withNamespaces(java.util.List namespaces); + public A withNamespaces(java.lang.String... namespaces); + public java.lang.Boolean hasNamespaces(); + public A addNewNamespace(java.lang.String original); + public java.lang.String getTopologyKey(); + public A withTopologyKey(java.lang.String topologyKey); + public java.lang.Boolean hasTopologyKey(); - - /** - * Method is deprecated. use withTopologyKey instead. - */ + + /** Method is deprecated. use withTopologyKey instead. */ @java.lang.Deprecated public A withNewTopologyKey(java.lang.String original); - public interface LabelSelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface LabelSelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested> { public N and(); + public N endLabelSelector(); - } - public interface NamespaceSelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface NamespaceSelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested< + N>> { public N and(); + public N endNamespaceSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityTermFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityTermFluentImpl.java index 3e50e478c4..1efe90b4d3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityTermFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAffinityTermFluentImpl.java @@ -1,24 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1PodAffinityTermFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodAffinityTermFluent{ - public V1PodAffinityTermFluentImpl() { - } - public V1PodAffinityTermFluentImpl(io.kubernetes.client.openapi.models.V1PodAffinityTerm instance) { +/** Generated */ +public class V1PodAffinityTermFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodAffinityTermFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodAffinityTermFluent { + public V1PodAffinityTermFluentImpl() {} + + public V1PodAffinityTermFluentImpl( + io.kubernetes.client.openapi.models.V1PodAffinityTerm instance) { this.withLabelSelector(instance.getLabelSelector()); this.withNamespaceSelector(instance.getNamespaceSelector()); @@ -26,195 +28,341 @@ public V1PodAffinityTermFluentImpl(io.kubernetes.client.openapi.models.V1PodAffi this.withNamespaces(instance.getNamespaces()); this.withTopologyKey(instance.getTopologyKey()); - } + private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder labelSelector; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder namespaceSelector; private java.util.List namespaces; private java.lang.String topologyKey; - + /** * This method has been deprecated, please use method buildLabelSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getLabelSelector() { - return this.labelSelector!=null ?this.labelSelector.build():null; + return this.labelSelector != null ? this.labelSelector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildLabelSelector() { - return this.labelSelector!=null ?this.labelSelector.build():null; + return this.labelSelector != null ? this.labelSelector.build() : null; } + public A withLabelSelector(io.kubernetes.client.openapi.models.V1LabelSelector labelSelector) { _visitables.get("labelSelector").remove(this.labelSelector); - if (labelSelector!=null){ this.labelSelector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(labelSelector); _visitables.get("labelSelector").add(this.labelSelector);} return (A) this; + if (labelSelector != null) { + this.labelSelector = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(labelSelector); + _visitables.get("labelSelector").add(this.labelSelector); + } + return (A) this; } + public java.lang.Boolean hasLabelSelector() { return this.labelSelector != null; } - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested withNewLabelSelector() { - return new io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl.LabelSelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested + withNewLabelSelector() { + return new io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl + .LabelSelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested withNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl.LabelSelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested + withNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl + .LabelSelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested editLabelSelector() { + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested + editLabelSelector() { return withNewLabelSelectorLike(getLabelSelector()); } - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested editOrNewLabelSelector() { - return withNewLabelSelectorLike(getLabelSelector() != null ? getLabelSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested + editOrNewLabelSelector() { + return withNewLabelSelectorLike( + getLabelSelector() != null + ? getLabelSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested editOrNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewLabelSelectorLike(getLabelSelector() != null ? getLabelSelector(): item); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested + editOrNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewLabelSelectorLike(getLabelSelector() != null ? getLabelSelector() : item); } - + /** * This method has been deprecated, please use method buildNamespaceSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getNamespaceSelector() { - return this.namespaceSelector!=null ?this.namespaceSelector.build():null; + return this.namespaceSelector != null ? this.namespaceSelector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildNamespaceSelector() { - return this.namespaceSelector!=null ?this.namespaceSelector.build():null; + return this.namespaceSelector != null ? this.namespaceSelector.build() : null; } - public A withNamespaceSelector(io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector) { + + public A withNamespaceSelector( + io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector) { _visitables.get("namespaceSelector").remove(this.namespaceSelector); - if (namespaceSelector!=null){ this.namespaceSelector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(namespaceSelector); _visitables.get("namespaceSelector").add(this.namespaceSelector);} return (A) this; + if (namespaceSelector != null) { + this.namespaceSelector = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(namespaceSelector); + _visitables.get("namespaceSelector").add(this.namespaceSelector); + } + return (A) this; } + public java.lang.Boolean hasNamespaceSelector() { return this.namespaceSelector != null; } - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested withNewNamespaceSelector() { - return new io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl.NamespaceSelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested + withNewNamespaceSelector() { + return new io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl + .NamespaceSelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl.NamespaceSelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested + withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl + .NamespaceSelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested editNamespaceSelector() { + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested + editNamespaceSelector() { return withNewNamespaceSelectorLike(getNamespaceSelector()); } - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested editOrNewNamespaceSelector() { - return withNewNamespaceSelectorLike(getNamespaceSelector() != null ? getNamespaceSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested + editOrNewNamespaceSelector() { + return withNewNamespaceSelectorLike( + getNamespaceSelector() != null + ? getNamespaceSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewNamespaceSelectorLike(getNamespaceSelector() != null ? getNamespaceSelector(): item); + + public io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested + editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewNamespaceSelectorLike( + getNamespaceSelector() != null ? getNamespaceSelector() : item); } - public A addToNamespaces(java.lang.Integer index,java.lang.String item) { - if (this.namespaces == null) {this.namespaces = new java.util.ArrayList();} + + public A addToNamespaces(java.lang.Integer index, java.lang.String item) { + if (this.namespaces == null) { + this.namespaces = new java.util.ArrayList(); + } this.namespaces.add(index, item); - return (A)this; + return (A) this; } - public A setToNamespaces(java.lang.Integer index,java.lang.String item) { - if (this.namespaces == null) {this.namespaces = new java.util.ArrayList();} - this.namespaces.set(index, item); return (A)this; + + public A setToNamespaces(java.lang.Integer index, java.lang.String item) { + if (this.namespaces == null) { + this.namespaces = new java.util.ArrayList(); + } + this.namespaces.set(index, item); + return (A) this; } + public A addToNamespaces(java.lang.String... items) { - if (this.namespaces == null) {this.namespaces = new java.util.ArrayList();} - for (java.lang.String item : items) {this.namespaces.add(item);} return (A)this; + if (this.namespaces == null) { + this.namespaces = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.namespaces.add(item); + } + return (A) this; } + public A addAllToNamespaces(java.util.Collection items) { - if (this.namespaces == null) {this.namespaces = new java.util.ArrayList();} - for (java.lang.String item : items) {this.namespaces.add(item);} return (A)this; + if (this.namespaces == null) { + this.namespaces = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.namespaces.add(item); + } + return (A) this; } + public A removeFromNamespaces(java.lang.String... items) { - for (java.lang.String item : items) {if (this.namespaces!= null){ this.namespaces.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.namespaces != null) { + this.namespaces.remove(item); + } + } + return (A) this; } + public A removeAllFromNamespaces(java.util.Collection items) { - for (java.lang.String item : items) {if (this.namespaces!= null){ this.namespaces.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.namespaces != null) { + this.namespaces.remove(item); + } + } + return (A) this; } + public java.util.List getNamespaces() { return this.namespaces; } + public java.lang.String getNamespace(java.lang.Integer index) { return this.namespaces.get(index); } + public java.lang.String getFirstNamespace() { return this.namespaces.get(0); } + public java.lang.String getLastNamespace() { return this.namespaces.get(namespaces.size() - 1); } - public java.lang.String getMatchingNamespace(java.util.function.Predicate predicate) { - for (java.lang.String item: namespaces) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingNamespace( + java.util.function.Predicate predicate) { + for (java.lang.String item : namespaces) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingNamespace(java.util.function.Predicate predicate) { - for (java.lang.String item: namespaces) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingNamespace( + java.util.function.Predicate predicate) { + for (java.lang.String item : namespaces) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withNamespaces(java.util.List namespaces) { - if (namespaces != null) {this.namespaces = new java.util.ArrayList(); for (java.lang.String item : namespaces){this.addToNamespaces(item);}} else { this.namespaces = null;} return (A) this; + if (namespaces != null) { + this.namespaces = new java.util.ArrayList(); + for (java.lang.String item : namespaces) { + this.addToNamespaces(item); + } + } else { + this.namespaces = null; + } + return (A) this; } + public A withNamespaces(java.lang.String... namespaces) { - if (this.namespaces != null) {this.namespaces.clear();} - if (namespaces != null) {for (java.lang.String item :namespaces){ this.addToNamespaces(item);}} return (A) this; + if (this.namespaces != null) { + this.namespaces.clear(); + } + if (namespaces != null) { + for (java.lang.String item : namespaces) { + this.addToNamespaces(item); + } + } + return (A) this; } + public java.lang.Boolean hasNamespaces() { return namespaces != null && !namespaces.isEmpty(); } + public A addNewNamespace(java.lang.String original) { - return (A)addToNamespaces(new String(original)); + return (A) addToNamespaces(new String(original)); } + public java.lang.String getTopologyKey() { return this.topologyKey; } + public A withTopologyKey(java.lang.String topologyKey) { - this.topologyKey=topologyKey; return (A) this; + this.topologyKey = topologyKey; + return (A) this; } + public java.lang.Boolean hasTopologyKey() { return this.topologyKey != null; } - - /** - * Method is deprecated. use withTopologyKey instead. - */ + + /** Method is deprecated. use withTopologyKey instead. */ @java.lang.Deprecated public A withNewTopologyKey(java.lang.String original) { - return (A)withTopologyKey(new String(original)); + return (A) withTopologyKey(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodAffinityTermFluentImpl that = (V1PodAffinityTermFluentImpl) o; - if (labelSelector != null ? !labelSelector.equals(that.labelSelector) :that.labelSelector != null) return false; - if (namespaceSelector != null ? !namespaceSelector.equals(that.namespaceSelector) :that.namespaceSelector != null) return false; - if (namespaces != null ? !namespaces.equals(that.namespaces) :that.namespaces != null) return false; - if (topologyKey != null ? !topologyKey.equals(that.topologyKey) :that.topologyKey != null) return false; + if (labelSelector != null + ? !labelSelector.equals(that.labelSelector) + : that.labelSelector != null) return false; + if (namespaceSelector != null + ? !namespaceSelector.equals(that.namespaceSelector) + : that.namespaceSelector != null) return false; + if (namespaces != null ? !namespaces.equals(that.namespaces) : that.namespaces != null) + return false; + if (topologyKey != null ? !topologyKey.equals(that.topologyKey) : that.topologyKey != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(labelSelector, namespaceSelector, namespaces, topologyKey, super.hashCode()); + return java.util.Objects.hash( + labelSelector, namespaceSelector, namespaces, topologyKey, super.hashCode()); } - public class LabelSelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested,io.kubernetes.client.fluent.Nested{ + + public class LabelSelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested> + implements io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.LabelSelectorNested, + io.kubernetes.client.fluent.Nested { LabelSelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + LabelSelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1PodAffinityTermFluentImpl.this.withLabelSelector(builder.build()); } + public N endLabelSelector() { return and(); } - } - public class NamespaceSelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested,io.kubernetes.client.fluent.Nested{ + + public class NamespaceSelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1PodAffinityTermFluent.NamespaceSelectorNested> + implements io.kubernetes.client.openapi.models.V1PodAffinityTermFluent + .NamespaceSelectorNested< + N>, + io.kubernetes.client.fluent.Nested { NamespaceSelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + NamespaceSelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1PodAffinityTermFluentImpl.this.withNamespaceSelector(builder.build()); } + public N endNamespaceSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAntiAffinityBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAntiAffinityBuilder.java index bcc3198ef5..582dbd072b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAntiAffinityBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAntiAffinityBuilder.java @@ -1,63 +1,107 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodAntiAffinityBuilder extends io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodAntiAffinityBuilder + extends io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl< + io.kubernetes.client.openapi.models.V1PodAntiAffinityBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodAntiAffinity, + io.kubernetes.client.openapi.models.V1PodAntiAffinityBuilder> { public V1PodAntiAffinityBuilder() { this(false); } + public V1PodAntiAffinityBuilder(java.lang.Boolean validationEnabled) { this(new V1PodAntiAffinity(), validationEnabled); } - public V1PodAntiAffinityBuilder(io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent fluent) { + + public V1PodAntiAffinityBuilder( + io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent fluent) { this(fluent, false); } - public V1PodAntiAffinityBuilder(io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodAntiAffinityBuilder( + io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodAntiAffinity(), validationEnabled); } - public V1PodAntiAffinityBuilder(io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent fluent,io.kubernetes.client.openapi.models.V1PodAntiAffinity instance) { + + public V1PodAntiAffinityBuilder( + io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent fluent, + io.kubernetes.client.openapi.models.V1PodAntiAffinity instance) { this(fluent, instance, false); } - public V1PodAntiAffinityBuilder(io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent fluent,io.kubernetes.client.openapi.models.V1PodAntiAffinity instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; - fluent.withPreferredDuringSchedulingIgnoredDuringExecution(instance.getPreferredDuringSchedulingIgnoredDuringExecution()); - fluent.withRequiredDuringSchedulingIgnoredDuringExecution(instance.getRequiredDuringSchedulingIgnoredDuringExecution()); + public V1PodAntiAffinityBuilder( + io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent fluent, + io.kubernetes.client.openapi.models.V1PodAntiAffinity instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; + fluent.withPreferredDuringSchedulingIgnoredDuringExecution( + instance.getPreferredDuringSchedulingIgnoredDuringExecution()); + + fluent.withRequiredDuringSchedulingIgnoredDuringExecution( + instance.getRequiredDuringSchedulingIgnoredDuringExecution()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodAntiAffinityBuilder(io.kubernetes.client.openapi.models.V1PodAntiAffinity instance) { - this(instance,false); + this(instance, false); } - public V1PodAntiAffinityBuilder(io.kubernetes.client.openapi.models.V1PodAntiAffinity instance,java.lang.Boolean validationEnabled) { - this.fluent = this; - this.withPreferredDuringSchedulingIgnoredDuringExecution(instance.getPreferredDuringSchedulingIgnoredDuringExecution()); - this.withRequiredDuringSchedulingIgnoredDuringExecution(instance.getRequiredDuringSchedulingIgnoredDuringExecution()); + public V1PodAntiAffinityBuilder( + io.kubernetes.client.openapi.models.V1PodAntiAffinity instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; + this.withPreferredDuringSchedulingIgnoredDuringExecution( + instance.getPreferredDuringSchedulingIgnoredDuringExecution()); - this.validationEnabled = validationEnabled; + this.withRequiredDuringSchedulingIgnoredDuringExecution( + instance.getRequiredDuringSchedulingIgnoredDuringExecution()); + + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodAntiAffinity build() { V1PodAntiAffinity buildable = new V1PodAntiAffinity(); - buildable.setPreferredDuringSchedulingIgnoredDuringExecution(fluent.getPreferredDuringSchedulingIgnoredDuringExecution()); - buildable.setRequiredDuringSchedulingIgnoredDuringExecution(fluent.getRequiredDuringSchedulingIgnoredDuringExecution()); + buildable.setPreferredDuringSchedulingIgnoredDuringExecution( + fluent.getPreferredDuringSchedulingIgnoredDuringExecution()); + buildable.setRequiredDuringSchedulingIgnoredDuringExecution( + fluent.getRequiredDuringSchedulingIgnoredDuringExecution()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodAntiAffinityBuilder that = (V1PodAntiAffinityBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAntiAffinityFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAntiAffinityFluent.java index d530713ee6..7dfedef125 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAntiAffinityFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAntiAffinityFluent.java @@ -1,92 +1,249 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodAntiAffinityFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); - public A setToPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); - public A addToPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items); - public A addAllToPreferredDuringSchedulingIgnoredDuringExecution(java.util.Collection items); - public A removeFromPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items); - public A removeAllFromPreferredDuringSchedulingIgnoredDuringExecution(java.util.Collection items); - public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - +/** Generated */ +public interface V1PodAntiAffinityFluent< + A extends io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToPreferredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); + + public A setToPreferredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); + + public A addToPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items); + + public A addAllToPreferredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items); + + public A removeFromPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items); + + public A removeAllFromPreferredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items); + + public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate); + /** - * This method has been deprecated, please use method buildPreferredDuringSchedulingIgnoredDuringExecution instead. + * This method has been deprecated, please use method + * buildPreferredDuringSchedulingIgnoredDuringExecution instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getPreferredDuringSchedulingIgnoredDuringExecution(); - public java.util.List buildPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildFirstPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildLastPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public A withPreferredDuringSchedulingIgnoredDuringExecution(java.util.List preferredDuringSchedulingIgnoredDuringExecution); - public A withPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... preferredDuringSchedulingIgnoredDuringExecution); + public java.util.List + getPreferredDuringSchedulingIgnoredDuringExecution(); + + public java.util.List + buildPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildFirstPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildLastPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate); + + public java.lang.Boolean hasMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate); + + public A withPreferredDuringSchedulingIgnoredDuringExecution( + java.util.List + preferredDuringSchedulingIgnoredDuringExecution); + + public A withPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... + preferredDuringSchedulingIgnoredDuringExecution); + public java.lang.Boolean hasPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested addNewPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested addNewPreferredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editFirstPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editLastPreferredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public A addToRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodAffinityTerm item); - public A setToRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodAffinityTerm item); - public A addToRequiredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PodAffinityTerm... items); - public A addAllToRequiredDuringSchedulingIgnoredDuringExecution(java.util.Collection items); - public A removeFromRequiredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PodAffinityTerm... items); - public A removeAllFromRequiredDuringSchedulingIgnoredDuringExecution(java.util.Collection items); - public A removeMatchingFromRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editFirstPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editLastPreferredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate); + + public A addToRequiredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item); + + public A setToRequiredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item); + + public A addToRequiredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PodAffinityTerm... items); + + public A addAllToRequiredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items); + + public A removeFromRequiredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PodAffinityTerm... items); + + public A removeAllFromRequiredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items); + + public A removeMatchingFromRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate); + /** - * This method has been deprecated, please use method buildRequiredDuringSchedulingIgnoredDuringExecution instead. + * This method has been deprecated, please use method + * buildRequiredDuringSchedulingIgnoredDuringExecution instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getRequiredDuringSchedulingIgnoredDuringExecution(); - public java.util.List buildRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildFirstRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildLastRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildMatchingRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public A withRequiredDuringSchedulingIgnoredDuringExecution(java.util.List requiredDuringSchedulingIgnoredDuringExecution); - public A withRequiredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PodAffinityTerm... requiredDuringSchedulingIgnoredDuringExecution); + public java.util.List + getRequiredDuringSchedulingIgnoredDuringExecution(); + + public java.util.List + buildRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildFirstRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildLastRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildMatchingRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate); + + public A withRequiredDuringSchedulingIgnoredDuringExecution( + java.util.List + requiredDuringSchedulingIgnoredDuringExecution); + + public A withRequiredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PodAffinityTerm... + requiredDuringSchedulingIgnoredDuringExecution); + public java.lang.Boolean hasRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested addNewRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested addNewRequiredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1PodAffinityTerm item); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested setNewRequiredDuringSchedulingIgnoredDuringExecutionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodAffinityTerm item); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editFirstRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editLastRequiredDuringSchedulingIgnoredDuringExecution(); - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editMatchingRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate); - public interface PreferredDuringSchedulingIgnoredDuringExecutionNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent>{ + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1PodAffinityTerm item); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + setNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editFirstRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editLastRequiredDuringSchedulingIgnoredDuringExecution(); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editMatchingRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate); + + public interface PreferredDuringSchedulingIgnoredDuringExecutionNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent< + io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + N>> { public N and(); + public N endPreferredDuringSchedulingIgnoredDuringExecution(); - } - public interface RequiredDuringSchedulingIgnoredDuringExecutionNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodAffinityTermFluent>{ + + public interface RequiredDuringSchedulingIgnoredDuringExecutionNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodAffinityTermFluent< + io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + N>> { public N and(); + public N endRequiredDuringSchedulingIgnoredDuringExecution(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAntiAffinityFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAntiAffinityFluentImpl.java index b6573fd46c..17ec8bd3e0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAntiAffinityFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodAntiAffinityFluentImpl.java @@ -1,60 +1,150 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1PodAntiAffinityFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent{ - public V1PodAntiAffinityFluentImpl() { - } - public V1PodAntiAffinityFluentImpl(io.kubernetes.client.openapi.models.V1PodAntiAffinity instance) { - this.withPreferredDuringSchedulingIgnoredDuringExecution(instance.getPreferredDuringSchedulingIgnoredDuringExecution()); +/** Generated */ +public class V1PodAntiAffinityFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent { + public V1PodAntiAffinityFluentImpl() {} - this.withRequiredDuringSchedulingIgnoredDuringExecution(instance.getRequiredDuringSchedulingIgnoredDuringExecution()); + public V1PodAntiAffinityFluentImpl( + io.kubernetes.client.openapi.models.V1PodAntiAffinity instance) { + this.withPreferredDuringSchedulingIgnoredDuringExecution( + instance.getPreferredDuringSchedulingIgnoredDuringExecution()); + this.withRequiredDuringSchedulingIgnoredDuringExecution( + instance.getRequiredDuringSchedulingIgnoredDuringExecution()); } - private java.util.ArrayList preferredDuringSchedulingIgnoredDuringExecution; - private java.util.ArrayList requiredDuringSchedulingIgnoredDuringExecution; - public A addToPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { - if (this.preferredDuringSchedulingIgnoredDuringExecution == null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(index >= 0 ? index : _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").size(), builder);this.preferredDuringSchedulingIgnoredDuringExecution.add(index >= 0 ? index : preferredDuringSchedulingIgnoredDuringExecution.size(), builder); return (A)this; + + private java.util.ArrayList + preferredDuringSchedulingIgnoredDuringExecution; + private java.util.ArrayList + requiredDuringSchedulingIgnoredDuringExecution; + + public A addToPreferredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { + if (this.preferredDuringSchedulingIgnoredDuringExecution == null) { + this.preferredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder>(); + } + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); + _visitables + .get("preferredDuringSchedulingIgnoredDuringExecution") + .add( + index >= 0 + ? index + : _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").size(), + builder); + this.preferredDuringSchedulingIgnoredDuringExecution.add( + index >= 0 ? index : preferredDuringSchedulingIgnoredDuringExecution.size(), builder); + return (A) this; } - public A setToPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { - if (this.preferredDuringSchedulingIgnoredDuringExecution == null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); - if (index < 0 || index >= _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").size()) { _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder); } else { _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").set(index, builder);} - if (index < 0 || index >= preferredDuringSchedulingIgnoredDuringExecution.size()) { preferredDuringSchedulingIgnoredDuringExecution.add(builder); } else { preferredDuringSchedulingIgnoredDuringExecution.set(index, builder);} - return (A)this; + + public A setToPreferredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { + if (this.preferredDuringSchedulingIgnoredDuringExecution == null) { + this.preferredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder>(); + } + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); + if (index < 0 + || index >= _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").size()) { + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder); + } else { + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").set(index, builder); + } + if (index < 0 || index >= preferredDuringSchedulingIgnoredDuringExecution.size()) { + preferredDuringSchedulingIgnoredDuringExecution.add(builder); + } else { + preferredDuringSchedulingIgnoredDuringExecution.set(index, builder); + } + return (A) this; } - public A addToPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items) { - if (this.preferredDuringSchedulingIgnoredDuringExecution == null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder);this.preferredDuringSchedulingIgnoredDuringExecution.add(builder);} return (A)this; + + public A addToPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items) { + if (this.preferredDuringSchedulingIgnoredDuringExecution == null) { + this.preferredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder); + this.preferredDuringSchedulingIgnoredDuringExecution.add(builder); + } + return (A) this; } - public A addAllToPreferredDuringSchedulingIgnoredDuringExecution(java.util.Collection items) { - if (this.preferredDuringSchedulingIgnoredDuringExecution == null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder);this.preferredDuringSchedulingIgnoredDuringExecution.add(builder);} return (A)this; + + public A addAllToPreferredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items) { + if (this.preferredDuringSchedulingIgnoredDuringExecution == null) { + this.preferredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").add(builder); + this.preferredDuringSchedulingIgnoredDuringExecution.add(builder); + } + return (A) this; } - public A removeFromPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items) { - for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").remove(builder);if (this.preferredDuringSchedulingIgnoredDuringExecution != null) {this.preferredDuringSchedulingIgnoredDuringExecution.remove(builder);}} return (A)this; + + public A removeFromPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... items) { + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").remove(builder); + if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { + this.preferredDuringSchedulingIgnoredDuringExecution.remove(builder); + } + } + return (A) this; } - public A removeAllFromPreferredDuringSchedulingIgnoredDuringExecution(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item);_visitables.get("preferredDuringSchedulingIgnoredDuringExecution").remove(builder);if (this.preferredDuringSchedulingIgnoredDuringExecution != null) {this.preferredDuringSchedulingIgnoredDuringExecution.remove(builder);}} return (A)this; + + public A removeAllFromPreferredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(item); + _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").remove(builder); + if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { + this.preferredDuringSchedulingIgnoredDuringExecution.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { + + public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate) { if (preferredDuringSchedulingIgnoredDuringExecution == null) return (A) this; - final Iterator each = preferredDuringSchedulingIgnoredDuringExecution.iterator(); + final Iterator each = + preferredDuringSchedulingIgnoredDuringExecution.iterator(); final List visitables = _visitables.get("preferredDuringSchedulingIgnoredDuringExecution"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder = each.next(); @@ -63,104 +153,300 @@ public A removeMatchingFromPreferredDuringSchedulingIgnoredDuringExecution(java. each.remove(); } } - return (A)this; + return (A) this; } - + /** - * This method has been deprecated, please use method buildPreferredDuringSchedulingIgnoredDuringExecution instead. + * This method has been deprecated, please use method + * buildPreferredDuringSchedulingIgnoredDuringExecution instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getPreferredDuringSchedulingIgnoredDuringExecution() { - return preferredDuringSchedulingIgnoredDuringExecution != null ? build(preferredDuringSchedulingIgnoredDuringExecution) : null; + public java.util.List + getPreferredDuringSchedulingIgnoredDuringExecution() { + return preferredDuringSchedulingIgnoredDuringExecution != null + ? build(preferredDuringSchedulingIgnoredDuringExecution) + : null; } - public java.util.List buildPreferredDuringSchedulingIgnoredDuringExecution() { - return preferredDuringSchedulingIgnoredDuringExecution != null ? build(preferredDuringSchedulingIgnoredDuringExecution) : null; + + public java.util.List + buildPreferredDuringSchedulingIgnoredDuringExecution() { + return preferredDuringSchedulingIgnoredDuringExecution != null + ? build(preferredDuringSchedulingIgnoredDuringExecution) + : null; } - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { return this.preferredDuringSchedulingIgnoredDuringExecution.get(index).build(); } - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildFirstPreferredDuringSchedulingIgnoredDuringExecution() { + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildFirstPreferredDuringSchedulingIgnoredDuringExecution() { return this.preferredDuringSchedulingIgnoredDuringExecution.get(0).build(); } - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildLastPreferredDuringSchedulingIgnoredDuringExecution() { - return this.preferredDuringSchedulingIgnoredDuringExecution.get(preferredDuringSchedulingIgnoredDuringExecution.size() - 1).build(); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildLastPreferredDuringSchedulingIgnoredDuringExecution() { + return this.preferredDuringSchedulingIgnoredDuringExecution + .get(preferredDuringSchedulingIgnoredDuringExecution.size() - 1) + .build(); } - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm buildMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder item: preferredDuringSchedulingIgnoredDuringExecution) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm + buildMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder item : + preferredDuringSchedulingIgnoredDuringExecution) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder item: preferredDuringSchedulingIgnoredDuringExecution) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder item : + preferredDuringSchedulingIgnoredDuringExecution) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withPreferredDuringSchedulingIgnoredDuringExecution(java.util.List preferredDuringSchedulingIgnoredDuringExecution) { - if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { _visitables.get("preferredDuringSchedulingIgnoredDuringExecution").removeAll(this.preferredDuringSchedulingIgnoredDuringExecution);} - if (preferredDuringSchedulingIgnoredDuringExecution != null) {this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : preferredDuringSchedulingIgnoredDuringExecution){this.addToPreferredDuringSchedulingIgnoredDuringExecution(item);}} else { this.preferredDuringSchedulingIgnoredDuringExecution = null;} return (A) this; + + public A withPreferredDuringSchedulingIgnoredDuringExecution( + java.util.List + preferredDuringSchedulingIgnoredDuringExecution) { + if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { + _visitables + .get("preferredDuringSchedulingIgnoredDuringExecution") + .removeAll(this.preferredDuringSchedulingIgnoredDuringExecution); + } + if (preferredDuringSchedulingIgnoredDuringExecution != null) { + this.preferredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : + preferredDuringSchedulingIgnoredDuringExecution) { + this.addToPreferredDuringSchedulingIgnoredDuringExecution(item); + } + } else { + this.preferredDuringSchedulingIgnoredDuringExecution = null; + } + return (A) this; } - public A withPreferredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... preferredDuringSchedulingIgnoredDuringExecution) { - if (this.preferredDuringSchedulingIgnoredDuringExecution != null) {this.preferredDuringSchedulingIgnoredDuringExecution.clear();} - if (preferredDuringSchedulingIgnoredDuringExecution != null) {for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item :preferredDuringSchedulingIgnoredDuringExecution){ this.addToPreferredDuringSchedulingIgnoredDuringExecution(item);}} return (A) this; + + public A withPreferredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm... + preferredDuringSchedulingIgnoredDuringExecution) { + if (this.preferredDuringSchedulingIgnoredDuringExecution != null) { + this.preferredDuringSchedulingIgnoredDuringExecution.clear(); + } + if (preferredDuringSchedulingIgnoredDuringExecution != null) { + for (io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item : + preferredDuringSchedulingIgnoredDuringExecution) { + this.addToPreferredDuringSchedulingIgnoredDuringExecution(item); + } + } + return (A) this; } + public java.lang.Boolean hasPreferredDuringSchedulingIgnoredDuringExecution() { - return preferredDuringSchedulingIgnoredDuringExecution != null && !preferredDuringSchedulingIgnoredDuringExecution.isEmpty(); + return preferredDuringSchedulingIgnoredDuringExecution != null + && !preferredDuringSchedulingIgnoredDuringExecution.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested addNewPreferredDuringSchedulingIgnoredDuringExecution() { - return new io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl.PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewPreferredDuringSchedulingIgnoredDuringExecution() { + return new io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl + .PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested addNewPreferredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { - return new io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl.PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { + return new io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl + .PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { - return new io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl.PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { + return new io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl + .PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { - if (preferredDuringSchedulingIgnoredDuringExecution.size() <= index) throw new RuntimeException("Can't edit preferredDuringSchedulingIgnoredDuringExecution. Index exceeds size."); - return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editPreferredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { + if (preferredDuringSchedulingIgnoredDuringExecution.size() <= index) + throw new RuntimeException( + "Can't edit preferredDuringSchedulingIgnoredDuringExecution. Index exceeds size."); + return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editFirstPreferredDuringSchedulingIgnoredDuringExecution() { - if (preferredDuringSchedulingIgnoredDuringExecution.size() == 0) throw new RuntimeException("Can't edit first preferredDuringSchedulingIgnoredDuringExecution. The list is empty."); - return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(0, buildPreferredDuringSchedulingIgnoredDuringExecution(0)); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editFirstPreferredDuringSchedulingIgnoredDuringExecution() { + if (preferredDuringSchedulingIgnoredDuringExecution.size() == 0) + throw new RuntimeException( + "Can't edit first preferredDuringSchedulingIgnoredDuringExecution. The list is empty."); + return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + 0, buildPreferredDuringSchedulingIgnoredDuringExecution(0)); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editLastPreferredDuringSchedulingIgnoredDuringExecution() { + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editLastPreferredDuringSchedulingIgnoredDuringExecution() { int index = preferredDuringSchedulingIgnoredDuringExecution.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last preferredDuringSchedulingIgnoredDuringExecution. The list is empty."); - return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike(index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); + if (index < 0) + throw new RuntimeException( + "Can't edit last preferredDuringSchedulingIgnoredDuringExecution. The list is empty."); + return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested editMatchingPreferredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + A> + editMatchingPreferredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item);_visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(index >= 0 ? index : _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").size(), builder);this.requiredDuringSchedulingIgnoredDuringExecution.add(index >= 0 ? index : requiredDuringSchedulingIgnoredDuringExecution.size(), builder); return (A)this; - } - public A setToRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { - if (this.requiredDuringSchedulingIgnoredDuringExecution == null) {this.requiredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); - if (index < 0 || index >= _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").size()) { _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(builder); } else { _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").set(index, builder);} - if (index < 0 || index >= requiredDuringSchedulingIgnoredDuringExecution.size()) { requiredDuringSchedulingIgnoredDuringExecution.add(builder); } else { requiredDuringSchedulingIgnoredDuringExecution.set(index, builder);} - return (A)this; - } - public A addToRequiredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PodAffinityTerm... items) { - if (this.requiredDuringSchedulingIgnoredDuringExecution == null) {this.requiredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item);_visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(builder);this.requiredDuringSchedulingIgnoredDuringExecution.add(builder);} return (A)this; - } - public A addAllToRequiredDuringSchedulingIgnoredDuringExecution(java.util.Collection items) { - if (this.requiredDuringSchedulingIgnoredDuringExecution == null) {this.requiredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item);_visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(builder);this.requiredDuringSchedulingIgnoredDuringExecution.add(builder);} return (A)this; - } - public A removeFromRequiredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PodAffinityTerm... items) { - for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item);_visitables.get("requiredDuringSchedulingIgnoredDuringExecution").remove(builder);if (this.requiredDuringSchedulingIgnoredDuringExecution != null) {this.requiredDuringSchedulingIgnoredDuringExecution.remove(builder);}} return (A)this; - } - public A removeAllFromRequiredDuringSchedulingIgnoredDuringExecution(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) {io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item);_visitables.get("requiredDuringSchedulingIgnoredDuringExecution").remove(builder);if (this.requiredDuringSchedulingIgnoredDuringExecution != null) {this.requiredDuringSchedulingIgnoredDuringExecution.remove(builder);}} return (A)this; - } - public A removeMatchingFromRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { + for (int i = 0; i < preferredDuringSchedulingIgnoredDuringExecution.size(); i++) { + if (predicate.test(preferredDuringSchedulingIgnoredDuringExecution.get(i))) { + index = i; + break; + } + } + if (index < 0) + throw new RuntimeException( + "Can't edit matching preferredDuringSchedulingIgnoredDuringExecution. No match found."); + return setNewPreferredDuringSchedulingIgnoredDuringExecutionLike( + index, buildPreferredDuringSchedulingIgnoredDuringExecution(index)); + } + + public A addToRequiredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { + if (this.requiredDuringSchedulingIgnoredDuringExecution == null) { + this.requiredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); + _visitables + .get("requiredDuringSchedulingIgnoredDuringExecution") + .add( + index >= 0 + ? index + : _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").size(), + builder); + this.requiredDuringSchedulingIgnoredDuringExecution.add( + index >= 0 ? index : requiredDuringSchedulingIgnoredDuringExecution.size(), builder); + return (A) this; + } + + public A setToRequiredDuringSchedulingIgnoredDuringExecution( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { + if (this.requiredDuringSchedulingIgnoredDuringExecution == null) { + this.requiredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); + if (index < 0 + || index >= _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").size()) { + _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(builder); + } else { + _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").set(index, builder); + } + if (index < 0 || index >= requiredDuringSchedulingIgnoredDuringExecution.size()) { + requiredDuringSchedulingIgnoredDuringExecution.add(builder); + } else { + requiredDuringSchedulingIgnoredDuringExecution.set(index, builder); + } + return (A) this; + } + + public A addToRequiredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PodAffinityTerm... items) { + if (this.requiredDuringSchedulingIgnoredDuringExecution == null) { + this.requiredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); + _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(builder); + this.requiredDuringSchedulingIgnoredDuringExecution.add(builder); + } + return (A) this; + } + + public A addAllToRequiredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items) { + if (this.requiredDuringSchedulingIgnoredDuringExecution == null) { + this.requiredDuringSchedulingIgnoredDuringExecution = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); + _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").add(builder); + this.requiredDuringSchedulingIgnoredDuringExecution.add(builder); + } + return (A) this; + } + + public A removeFromRequiredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PodAffinityTerm... items) { + for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); + _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").remove(builder); + if (this.requiredDuringSchedulingIgnoredDuringExecution != null) { + this.requiredDuringSchedulingIgnoredDuringExecution.remove(builder); + } + } + return (A) this; + } + + public A removeAllFromRequiredDuringSchedulingIgnoredDuringExecution( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : items) { + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = + new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(item); + _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").remove(builder); + if (this.requiredDuringSchedulingIgnoredDuringExecution != null) { + this.requiredDuringSchedulingIgnoredDuringExecution.remove(builder); + } + } + return (A) this; + } + + public A removeMatchingFromRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate) { if (requiredDuringSchedulingIgnoredDuringExecution == null) return (A) this; - final Iterator each = requiredDuringSchedulingIgnoredDuringExecution.iterator(); + final Iterator each = + requiredDuringSchedulingIgnoredDuringExecution.iterator(); final List visitables = _visitables.get("requiredDuringSchedulingIgnoredDuringExecution"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder = each.next(); @@ -169,124 +455,281 @@ public A removeMatchingFromRequiredDuringSchedulingIgnoredDuringExecution(java.u each.remove(); } } - return (A)this; + return (A) this; } - + /** - * This method has been deprecated, please use method buildRequiredDuringSchedulingIgnoredDuringExecution instead. + * This method has been deprecated, please use method + * buildRequiredDuringSchedulingIgnoredDuringExecution instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getRequiredDuringSchedulingIgnoredDuringExecution() { - return requiredDuringSchedulingIgnoredDuringExecution != null ? build(requiredDuringSchedulingIgnoredDuringExecution) : null; + public java.util.List + getRequiredDuringSchedulingIgnoredDuringExecution() { + return requiredDuringSchedulingIgnoredDuringExecution != null + ? build(requiredDuringSchedulingIgnoredDuringExecution) + : null; } - public java.util.List buildRequiredDuringSchedulingIgnoredDuringExecution() { - return requiredDuringSchedulingIgnoredDuringExecution != null ? build(requiredDuringSchedulingIgnoredDuringExecution) : null; + + public java.util.List + buildRequiredDuringSchedulingIgnoredDuringExecution() { + return requiredDuringSchedulingIgnoredDuringExecution != null + ? build(requiredDuringSchedulingIgnoredDuringExecution) + : null; } - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { return this.requiredDuringSchedulingIgnoredDuringExecution.get(index).build(); } - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildFirstRequiredDuringSchedulingIgnoredDuringExecution() { + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildFirstRequiredDuringSchedulingIgnoredDuringExecution() { return this.requiredDuringSchedulingIgnoredDuringExecution.get(0).build(); } - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildLastRequiredDuringSchedulingIgnoredDuringExecution() { - return this.requiredDuringSchedulingIgnoredDuringExecution.get(requiredDuringSchedulingIgnoredDuringExecution.size() - 1).build(); + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildLastRequiredDuringSchedulingIgnoredDuringExecution() { + return this.requiredDuringSchedulingIgnoredDuringExecution + .get(requiredDuringSchedulingIgnoredDuringExecution.size() - 1) + .build(); } - public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildMatchingRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder item: requiredDuringSchedulingIgnoredDuringExecution) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PodAffinityTerm + buildMatchingRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder item : + requiredDuringSchedulingIgnoredDuringExecution) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder item: requiredDuringSchedulingIgnoredDuringExecution) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder item : + requiredDuringSchedulingIgnoredDuringExecution) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withRequiredDuringSchedulingIgnoredDuringExecution(java.util.List requiredDuringSchedulingIgnoredDuringExecution) { - if (this.requiredDuringSchedulingIgnoredDuringExecution != null) { _visitables.get("requiredDuringSchedulingIgnoredDuringExecution").removeAll(this.requiredDuringSchedulingIgnoredDuringExecution);} - if (requiredDuringSchedulingIgnoredDuringExecution != null) {this.requiredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : requiredDuringSchedulingIgnoredDuringExecution){this.addToRequiredDuringSchedulingIgnoredDuringExecution(item);}} else { this.requiredDuringSchedulingIgnoredDuringExecution = null;} return (A) this; + + public A withRequiredDuringSchedulingIgnoredDuringExecution( + java.util.List + requiredDuringSchedulingIgnoredDuringExecution) { + if (this.requiredDuringSchedulingIgnoredDuringExecution != null) { + _visitables + .get("requiredDuringSchedulingIgnoredDuringExecution") + .removeAll(this.requiredDuringSchedulingIgnoredDuringExecution); + } + if (requiredDuringSchedulingIgnoredDuringExecution != null) { + this.requiredDuringSchedulingIgnoredDuringExecution = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : + requiredDuringSchedulingIgnoredDuringExecution) { + this.addToRequiredDuringSchedulingIgnoredDuringExecution(item); + } + } else { + this.requiredDuringSchedulingIgnoredDuringExecution = null; + } + return (A) this; } - public A withRequiredDuringSchedulingIgnoredDuringExecution(io.kubernetes.client.openapi.models.V1PodAffinityTerm... requiredDuringSchedulingIgnoredDuringExecution) { - if (this.requiredDuringSchedulingIgnoredDuringExecution != null) {this.requiredDuringSchedulingIgnoredDuringExecution.clear();} - if (requiredDuringSchedulingIgnoredDuringExecution != null) {for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item :requiredDuringSchedulingIgnoredDuringExecution){ this.addToRequiredDuringSchedulingIgnoredDuringExecution(item);}} return (A) this; + + public A withRequiredDuringSchedulingIgnoredDuringExecution( + io.kubernetes.client.openapi.models.V1PodAffinityTerm... + requiredDuringSchedulingIgnoredDuringExecution) { + if (this.requiredDuringSchedulingIgnoredDuringExecution != null) { + this.requiredDuringSchedulingIgnoredDuringExecution.clear(); + } + if (requiredDuringSchedulingIgnoredDuringExecution != null) { + for (io.kubernetes.client.openapi.models.V1PodAffinityTerm item : + requiredDuringSchedulingIgnoredDuringExecution) { + this.addToRequiredDuringSchedulingIgnoredDuringExecution(item); + } + } + return (A) this; } + public java.lang.Boolean hasRequiredDuringSchedulingIgnoredDuringExecution() { - return requiredDuringSchedulingIgnoredDuringExecution != null && !requiredDuringSchedulingIgnoredDuringExecution.isEmpty(); + return requiredDuringSchedulingIgnoredDuringExecution != null + && !requiredDuringSchedulingIgnoredDuringExecution.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested addNewRequiredDuringSchedulingIgnoredDuringExecution() { - return new io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl.RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewRequiredDuringSchedulingIgnoredDuringExecution() { + return new io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl + .RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested addNewRequiredDuringSchedulingIgnoredDuringExecutionLike(io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { - return new io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl.RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + addNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { + return new io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl + .RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested setNewRequiredDuringSchedulingIgnoredDuringExecutionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { - return new io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl.RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + setNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { + return new io.kubernetes.client.openapi.models.V1PodAntiAffinityFluentImpl + .RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { - if (requiredDuringSchedulingIgnoredDuringExecution.size() <= index) throw new RuntimeException("Can't edit requiredDuringSchedulingIgnoredDuringExecution. Index exceeds size."); - return setNewRequiredDuringSchedulingIgnoredDuringExecutionLike(index, buildRequiredDuringSchedulingIgnoredDuringExecution(index)); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editRequiredDuringSchedulingIgnoredDuringExecution(java.lang.Integer index) { + if (requiredDuringSchedulingIgnoredDuringExecution.size() <= index) + throw new RuntimeException( + "Can't edit requiredDuringSchedulingIgnoredDuringExecution. Index exceeds size."); + return setNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + index, buildRequiredDuringSchedulingIgnoredDuringExecution(index)); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editFirstRequiredDuringSchedulingIgnoredDuringExecution() { - if (requiredDuringSchedulingIgnoredDuringExecution.size() == 0) throw new RuntimeException("Can't edit first requiredDuringSchedulingIgnoredDuringExecution. The list is empty."); - return setNewRequiredDuringSchedulingIgnoredDuringExecutionLike(0, buildRequiredDuringSchedulingIgnoredDuringExecution(0)); + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editFirstRequiredDuringSchedulingIgnoredDuringExecution() { + if (requiredDuringSchedulingIgnoredDuringExecution.size() == 0) + throw new RuntimeException( + "Can't edit first requiredDuringSchedulingIgnoredDuringExecution. The list is empty."); + return setNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + 0, buildRequiredDuringSchedulingIgnoredDuringExecution(0)); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editLastRequiredDuringSchedulingIgnoredDuringExecution() { + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editLastRequiredDuringSchedulingIgnoredDuringExecution() { int index = requiredDuringSchedulingIgnoredDuringExecution.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last requiredDuringSchedulingIgnoredDuringExecution. The list is empty."); - return setNewRequiredDuringSchedulingIgnoredDuringExecutionLike(index, buildRequiredDuringSchedulingIgnoredDuringExecution(index)); + if (index < 0) + throw new RuntimeException( + "Can't edit last requiredDuringSchedulingIgnoredDuringExecution. The list is empty."); + return setNewRequiredDuringSchedulingIgnoredDuringExecutionLike( + index, buildRequiredDuringSchedulingIgnoredDuringExecution(index)); } - public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested editMatchingRequiredDuringSchedulingIgnoredDuringExecution(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + A> + editMatchingRequiredDuringSchedulingIgnoredDuringExecution( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluentImpl> implements io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.PreferredDuringSchedulingIgnoredDuringExecutionNested,io.kubernetes.client.fluent.Nested{ - PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { + + public class PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl + extends io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluentImpl< + io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + N>> + implements io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .PreferredDuringSchedulingIgnoredDuringExecutionNested< + N>, + io.kubernetes.client.fluent.Nested { + PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(this, item); } + PreferredDuringSchedulingIgnoredDuringExecutionNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder(this); } + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodAntiAffinityFluentImpl.this.setToPreferredDuringSchedulingIgnoredDuringExecution(index,builder.build()); + return (N) + V1PodAntiAffinityFluentImpl.this.setToPreferredDuringSchedulingIgnoredDuringExecution( + index, builder.build()); } + public N endPreferredDuringSchedulingIgnoredDuringExecution() { return and(); } - } - public class RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl extends io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl> implements io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent.RequiredDuringSchedulingIgnoredDuringExecutionNested,io.kubernetes.client.fluent.Nested{ - RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { + + public class RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl + extends io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl< + io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + N>> + implements io.kubernetes.client.openapi.models.V1PodAntiAffinityFluent + .RequiredDuringSchedulingIgnoredDuringExecutionNested< + N>, + io.kubernetes.client.fluent.Nested { + RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(this, item); } + RequiredDuringSchedulingIgnoredDuringExecutionNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(this); } + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodAntiAffinityFluentImpl.this.setToRequiredDuringSchedulingIgnoredDuringExecution(index,builder.build()); + return (N) + V1PodAntiAffinityFluentImpl.this.setToRequiredDuringSchedulingIgnoredDuringExecution( + index, builder.build()); } + public N endRequiredDuringSchedulingIgnoredDuringExecution() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodBuilder.java index d835386bbc..065dcfd7ff 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodBuilder extends io.kubernetes.client.openapi.models.V1PodFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodBuilder + extends io.kubernetes.client.openapi.models.V1PodFluentImpl< + io.kubernetes.client.openapi.models.V1PodBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Pod, + io.kubernetes.client.openapi.models.V1PodBuilder> { public V1PodBuilder() { this(false); } + public V1PodBuilder(java.lang.Boolean validationEnabled) { this(new V1Pod(), validationEnabled); } + public V1PodBuilder(io.kubernetes.client.openapi.models.V1PodFluent fluent) { this(fluent, false); } - public V1PodBuilder(io.kubernetes.client.openapi.models.V1PodFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodBuilder( + io.kubernetes.client.openapi.models.V1PodFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Pod(), validationEnabled); } - public V1PodBuilder(io.kubernetes.client.openapi.models.V1PodFluent fluent,io.kubernetes.client.openapi.models.V1Pod instance) { + + public V1PodBuilder( + io.kubernetes.client.openapi.models.V1PodFluent fluent, + io.kubernetes.client.openapi.models.V1Pod instance) { this(fluent, instance, false); } - public V1PodBuilder(io.kubernetes.client.openapi.models.V1PodFluent fluent,io.kubernetes.client.openapi.models.V1Pod instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodBuilder( + io.kubernetes.client.openapi.models.V1PodFluent fluent, + io.kubernetes.client.openapi.models.V1Pod instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,16 @@ public V1PodBuilder(io.kubernetes.client.openapi.models.V1PodFluent fluent,io fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodBuilder(io.kubernetes.client.openapi.models.V1Pod instance) { - this(instance,false); + this(instance, false); } - public V1PodBuilder(io.kubernetes.client.openapi.models.V1Pod instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodBuilder( + io.kubernetes.client.openapi.models.V1Pod instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +77,12 @@ public V1PodBuilder(io.kubernetes.client.openapi.models.V1Pod instance,java.lang this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Pod build() { V1Pod buildable = new V1Pod(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +92,23 @@ public io.kubernetes.client.openapi.models.V1Pod build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodBuilder that = (V1PodBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodConditionBuilder.java index 9cbd180002..d18b139000 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodConditionBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodConditionBuilder extends io.kubernetes.client.openapi.models.V1PodConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodConditionBuilder + extends io.kubernetes.client.openapi.models.V1PodConditionFluentImpl< + io.kubernetes.client.openapi.models.V1PodConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodCondition, + io.kubernetes.client.openapi.models.V1PodConditionBuilder> { public V1PodConditionBuilder() { this(false); } + public V1PodConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1PodCondition(), validationEnabled); } + public V1PodConditionBuilder(io.kubernetes.client.openapi.models.V1PodConditionFluent fluent) { this(fluent, false); } - public V1PodConditionBuilder(io.kubernetes.client.openapi.models.V1PodConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodConditionBuilder( + io.kubernetes.client.openapi.models.V1PodConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodCondition(), validationEnabled); } - public V1PodConditionBuilder(io.kubernetes.client.openapi.models.V1PodConditionFluent fluent,io.kubernetes.client.openapi.models.V1PodCondition instance) { + + public V1PodConditionBuilder( + io.kubernetes.client.openapi.models.V1PodConditionFluent fluent, + io.kubernetes.client.openapi.models.V1PodCondition instance) { this(fluent, instance, false); } - public V1PodConditionBuilder(io.kubernetes.client.openapi.models.V1PodConditionFluent fluent,io.kubernetes.client.openapi.models.V1PodCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodConditionBuilder( + io.kubernetes.client.openapi.models.V1PodConditionFluent fluent, + io.kubernetes.client.openapi.models.V1PodCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastProbeTime(instance.getLastProbeTime()); fluent.withLastTransitionTime(instance.getLastTransitionTime()); @@ -33,13 +59,17 @@ public V1PodConditionBuilder(io.kubernetes.client.openapi.models.V1PodConditionF fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodConditionBuilder(io.kubernetes.client.openapi.models.V1PodCondition instance) { - this(instance,false); + this(instance, false); } - public V1PodConditionBuilder(io.kubernetes.client.openapi.models.V1PodCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodConditionBuilder( + io.kubernetes.client.openapi.models.V1PodCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastProbeTime(instance.getLastProbeTime()); this.withLastTransitionTime(instance.getLastTransitionTime()); @@ -52,10 +82,12 @@ public V1PodConditionBuilder(io.kubernetes.client.openapi.models.V1PodCondition this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodCondition build() { V1PodCondition buildable = new V1PodCondition(); buildable.setLastProbeTime(fluent.getLastProbeTime()); @@ -66,18 +98,23 @@ public io.kubernetes.client.openapi.models.V1PodCondition build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodConditionBuilder that = (V1PodConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodConditionFluent.java index bf79d185c6..219750f82b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodConditionFluent.java @@ -1,51 +1,66 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PodConditionFluent< + A extends io.kubernetes.client.openapi.models.V1PodConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastProbeTime(); + public A withLastProbeTime(java.time.OffsetDateTime lastProbeTime); + public java.lang.Boolean hasLastProbeTime(); + public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public io.kubernetes.client.openapi.models.V1PodCondition.TypeEnum getType(); + public A withType(io.kubernetes.client.openapi.models.V1PodCondition.TypeEnum type); + public java.lang.Boolean hasType(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodConditionFluentImpl.java index 5c06626530..6294f9d418 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodConditionFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1PodConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodConditionFluent { + public V1PodConditionFluentImpl() {} - /** - * Generated - */ -public class V1PodConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodConditionFluent{ - public V1PodConditionFluentImpl() { - } public V1PodConditionFluentImpl(io.kubernetes.client.openapi.models.V1PodCondition instance) { this.withLastProbeTime(instance.getLastProbeTime()); @@ -25,106 +31,130 @@ public V1PodConditionFluentImpl(io.kubernetes.client.openapi.models.V1PodConditi this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastProbeTime; private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private io.kubernetes.client.openapi.models.V1PodCondition.TypeEnum type; + public java.time.OffsetDateTime getLastProbeTime() { return this.lastProbeTime; } + public A withLastProbeTime(java.time.OffsetDateTime lastProbeTime) { - this.lastProbeTime=lastProbeTime; return (A) this; + this.lastProbeTime = lastProbeTime; + return (A) this; } + public java.lang.Boolean hasLastProbeTime() { return this.lastProbeTime != null; } + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public io.kubernetes.client.openapi.models.V1PodCondition.TypeEnum getType() { return this.type; } + public A withType(io.kubernetes.client.openapi.models.V1PodCondition.TypeEnum type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodConditionFluentImpl that = (V1PodConditionFluentImpl) o; - if (lastProbeTime != null ? !lastProbeTime.equals(that.lastProbeTime) :that.lastProbeTime != null) return false; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (lastProbeTime != null + ? !lastProbeTime.equals(that.lastProbeTime) + : that.lastProbeTime != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastProbeTime, lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastProbeTime, lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigBuilder.java index 281aa35158..22d516a620 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigBuilder.java @@ -1,49 +1,81 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodDNSConfigBuilder extends io.kubernetes.client.openapi.models.V1PodDNSConfigFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodDNSConfigBuilder + extends io.kubernetes.client.openapi.models.V1PodDNSConfigFluentImpl< + io.kubernetes.client.openapi.models.V1PodDNSConfigBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodDNSConfig, + io.kubernetes.client.openapi.models.V1PodDNSConfigBuilder> { public V1PodDNSConfigBuilder() { this(false); } + public V1PodDNSConfigBuilder(java.lang.Boolean validationEnabled) { this(new V1PodDNSConfig(), validationEnabled); } + public V1PodDNSConfigBuilder(io.kubernetes.client.openapi.models.V1PodDNSConfigFluent fluent) { this(fluent, false); } - public V1PodDNSConfigBuilder(io.kubernetes.client.openapi.models.V1PodDNSConfigFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodDNSConfigBuilder( + io.kubernetes.client.openapi.models.V1PodDNSConfigFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodDNSConfig(), validationEnabled); } - public V1PodDNSConfigBuilder(io.kubernetes.client.openapi.models.V1PodDNSConfigFluent fluent,io.kubernetes.client.openapi.models.V1PodDNSConfig instance) { + + public V1PodDNSConfigBuilder( + io.kubernetes.client.openapi.models.V1PodDNSConfigFluent fluent, + io.kubernetes.client.openapi.models.V1PodDNSConfig instance) { this(fluent, instance, false); } - public V1PodDNSConfigBuilder(io.kubernetes.client.openapi.models.V1PodDNSConfigFluent fluent,io.kubernetes.client.openapi.models.V1PodDNSConfig instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodDNSConfigBuilder( + io.kubernetes.client.openapi.models.V1PodDNSConfigFluent fluent, + io.kubernetes.client.openapi.models.V1PodDNSConfig instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNameservers(instance.getNameservers()); fluent.withOptions(instance.getOptions()); fluent.withSearches(instance.getSearches()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodDNSConfigBuilder(io.kubernetes.client.openapi.models.V1PodDNSConfig instance) { - this(instance,false); + this(instance, false); } - public V1PodDNSConfigBuilder(io.kubernetes.client.openapi.models.V1PodDNSConfig instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodDNSConfigBuilder( + io.kubernetes.client.openapi.models.V1PodDNSConfig instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNameservers(instance.getNameservers()); this.withOptions(instance.getOptions()); this.withSearches(instance.getSearches()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodDNSConfigFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodDNSConfig build() { V1PodDNSConfig buildable = new V1PodDNSConfig(); buildable.setNameservers(fluent.getNameservers()); @@ -51,18 +83,23 @@ public io.kubernetes.client.openapi.models.V1PodDNSConfig build() { buildable.setSearches(fluent.getSearches()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodDNSConfigBuilder that = (V1PodDNSConfigBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigFluent.java index 7f9c98a28a..d449a91e52 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigFluent.java @@ -1,89 +1,169 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodDNSConfigFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToNameservers(java.lang.Integer index,java.lang.String item); - public A setToNameservers(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1PodDNSConfigFluent< + A extends io.kubernetes.client.openapi.models.V1PodDNSConfigFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToNameservers(java.lang.Integer index, java.lang.String item); + + public A setToNameservers(java.lang.Integer index, java.lang.String item); + public A addToNameservers(java.lang.String... items); + public A addAllToNameservers(java.util.Collection items); + public A removeFromNameservers(java.lang.String... items); + public A removeAllFromNameservers(java.util.Collection items); + public java.util.List getNameservers(); + public java.lang.String getNameserver(java.lang.Integer index); + public java.lang.String getFirstNameserver(); + public java.lang.String getLastNameserver(); - public java.lang.String getMatchingNameserver(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingNameserver(java.util.function.Predicate predicate); + + public java.lang.String getMatchingNameserver( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingNameserver( + java.util.function.Predicate predicate); + public A withNameservers(java.util.List nameservers); + public A withNameservers(java.lang.String... nameservers); + public java.lang.Boolean hasNameservers(); + public A addNewNameserver(java.lang.String original); - public A addToOptions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDNSConfigOption item); - public A setToOptions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDNSConfigOption item); + + public A addToOptions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDNSConfigOption item); + + public A setToOptions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDNSConfigOption item); + public A addToOptions(io.kubernetes.client.openapi.models.V1PodDNSConfigOption... items); - public A addAllToOptions(java.util.Collection items); + + public A addAllToOptions( + java.util.Collection items); + public A removeFromOptions(io.kubernetes.client.openapi.models.V1PodDNSConfigOption... items); - public A removeAllFromOptions(java.util.Collection items); - public A removeMatchingFromOptions(java.util.function.Predicate predicate); - + + public A removeAllFromOptions( + java.util.Collection items); + + public A removeMatchingFromOptions( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildOptions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getOptions(); + public java.util.List buildOptions(); - public io.kubernetes.client.openapi.models.V1PodDNSConfigOption buildOption(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodDNSConfigOption buildOption( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PodDNSConfigOption buildFirstOption(); + public io.kubernetes.client.openapi.models.V1PodDNSConfigOption buildLastOption(); - public io.kubernetes.client.openapi.models.V1PodDNSConfigOption buildMatchingOption(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingOption(java.util.function.Predicate predicate); - public A withOptions(java.util.List options); + + public io.kubernetes.client.openapi.models.V1PodDNSConfigOption buildMatchingOption( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingOption( + java.util.function.Predicate + predicate); + + public A withOptions( + java.util.List options); + public A withOptions(io.kubernetes.client.openapi.models.V1PodDNSConfigOption... options); + public java.lang.Boolean hasOptions(); + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested addNewOption(); - public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested addNewOptionLike(io.kubernetes.client.openapi.models.V1PodDNSConfigOption item); - public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested setNewOptionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDNSConfigOption item); - public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested editOption(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested editFirstOption(); + + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested addNewOptionLike( + io.kubernetes.client.openapi.models.V1PodDNSConfigOption item); + + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested setNewOptionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDNSConfigOption item); + + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested editOption( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested + editFirstOption(); + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested editLastOption(); - public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested editMatchingOption(java.util.function.Predicate predicate); - public A addToSearches(java.lang.Integer index,java.lang.String item); - public A setToSearches(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested + editMatchingOption( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder> + predicate); + + public A addToSearches(java.lang.Integer index, java.lang.String item); + + public A setToSearches(java.lang.Integer index, java.lang.String item); + public A addToSearches(java.lang.String... items); + public A addAllToSearches(java.util.Collection items); + public A removeFromSearches(java.lang.String... items); + public A removeAllFromSearches(java.util.Collection items); + public java.util.List getSearches(); + public java.lang.String getSearch(java.lang.Integer index); + public java.lang.String getFirstSearch(); + public java.lang.String getLastSearch(); - public java.lang.String getMatchingSearch(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingSearch(java.util.function.Predicate predicate); + + public java.lang.String getMatchingSearch( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingSearch( + java.util.function.Predicate predicate); + public A withSearches(java.util.List searches); + public A withSearches(java.lang.String... searches); + public java.lang.Boolean hasSearches(); + public A addNewSearch(java.lang.String original); - public interface OptionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent>{ + + public interface OptionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent< + io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested> { public N and(); + public N endOption(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigFluentImpl.java index 63a8f64a5f..42b6c54c50 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigFluentImpl.java @@ -1,118 +1,260 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1PodDNSConfigFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodDNSConfigFluent{ - public V1PodDNSConfigFluentImpl() { - } +/** Generated */ +public class V1PodDNSConfigFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodDNSConfigFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodDNSConfigFluent { + public V1PodDNSConfigFluentImpl() {} + public V1PodDNSConfigFluentImpl(io.kubernetes.client.openapi.models.V1PodDNSConfig instance) { this.withNameservers(instance.getNameservers()); this.withOptions(instance.getOptions()); this.withSearches(instance.getSearches()); - } + private java.util.List nameservers; - private java.util.ArrayList options; + private java.util.ArrayList + options; private java.util.List searches; - public A addToNameservers(java.lang.Integer index,java.lang.String item) { - if (this.nameservers == null) {this.nameservers = new java.util.ArrayList();} + + public A addToNameservers(java.lang.Integer index, java.lang.String item) { + if (this.nameservers == null) { + this.nameservers = new java.util.ArrayList(); + } this.nameservers.add(index, item); - return (A)this; + return (A) this; } - public A setToNameservers(java.lang.Integer index,java.lang.String item) { - if (this.nameservers == null) {this.nameservers = new java.util.ArrayList();} - this.nameservers.set(index, item); return (A)this; + + public A setToNameservers(java.lang.Integer index, java.lang.String item) { + if (this.nameservers == null) { + this.nameservers = new java.util.ArrayList(); + } + this.nameservers.set(index, item); + return (A) this; } + public A addToNameservers(java.lang.String... items) { - if (this.nameservers == null) {this.nameservers = new java.util.ArrayList();} - for (java.lang.String item : items) {this.nameservers.add(item);} return (A)this; + if (this.nameservers == null) { + this.nameservers = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.nameservers.add(item); + } + return (A) this; } + public A addAllToNameservers(java.util.Collection items) { - if (this.nameservers == null) {this.nameservers = new java.util.ArrayList();} - for (java.lang.String item : items) {this.nameservers.add(item);} return (A)this; + if (this.nameservers == null) { + this.nameservers = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.nameservers.add(item); + } + return (A) this; } + public A removeFromNameservers(java.lang.String... items) { - for (java.lang.String item : items) {if (this.nameservers!= null){ this.nameservers.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.nameservers != null) { + this.nameservers.remove(item); + } + } + return (A) this; } + public A removeAllFromNameservers(java.util.Collection items) { - for (java.lang.String item : items) {if (this.nameservers!= null){ this.nameservers.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.nameservers != null) { + this.nameservers.remove(item); + } + } + return (A) this; } + public java.util.List getNameservers() { return this.nameservers; } + public java.lang.String getNameserver(java.lang.Integer index) { return this.nameservers.get(index); } + public java.lang.String getFirstNameserver() { return this.nameservers.get(0); } + public java.lang.String getLastNameserver() { return this.nameservers.get(nameservers.size() - 1); } - public java.lang.String getMatchingNameserver(java.util.function.Predicate predicate) { - for (java.lang.String item: nameservers) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingNameserver( + java.util.function.Predicate predicate) { + for (java.lang.String item : nameservers) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingNameserver(java.util.function.Predicate predicate) { - for (java.lang.String item: nameservers) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingNameserver( + java.util.function.Predicate predicate) { + for (java.lang.String item : nameservers) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withNameservers(java.util.List nameservers) { - if (nameservers != null) {this.nameservers = new java.util.ArrayList(); for (java.lang.String item : nameservers){this.addToNameservers(item);}} else { this.nameservers = null;} return (A) this; + if (nameservers != null) { + this.nameservers = new java.util.ArrayList(); + for (java.lang.String item : nameservers) { + this.addToNameservers(item); + } + } else { + this.nameservers = null; + } + return (A) this; } + public A withNameservers(java.lang.String... nameservers) { - if (this.nameservers != null) {this.nameservers.clear();} - if (nameservers != null) {for (java.lang.String item :nameservers){ this.addToNameservers(item);}} return (A) this; + if (this.nameservers != null) { + this.nameservers.clear(); + } + if (nameservers != null) { + for (java.lang.String item : nameservers) { + this.addToNameservers(item); + } + } + return (A) this; } + public java.lang.Boolean hasNameservers() { return nameservers != null && !nameservers.isEmpty(); } + public A addNewNameserver(java.lang.String original) { - return (A)addToNameservers(new String(original)); + return (A) addToNameservers(new String(original)); } - public A addToOptions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDNSConfigOption item) { - if (this.options == null) {this.options = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder = new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(item);_visitables.get("options").add(index >= 0 ? index : _visitables.get("options").size(), builder);this.options.add(index >= 0 ? index : options.size(), builder); return (A)this; + + public A addToOptions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDNSConfigOption item) { + if (this.options == null) { + this.options = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder>(); + } + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder = + new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(item); + _visitables.get("options").add(index >= 0 ? index : _visitables.get("options").size(), builder); + this.options.add(index >= 0 ? index : options.size(), builder); + return (A) this; } - public A setToOptions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDNSConfigOption item) { - if (this.options == null) {this.options = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder = new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(item); - if (index < 0 || index >= _visitables.get("options").size()) { _visitables.get("options").add(builder); } else { _visitables.get("options").set(index, builder);} - if (index < 0 || index >= options.size()) { options.add(builder); } else { options.set(index, builder);} - return (A)this; + + public A setToOptions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDNSConfigOption item) { + if (this.options == null) { + this.options = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder>(); + } + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder = + new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(item); + if (index < 0 || index >= _visitables.get("options").size()) { + _visitables.get("options").add(builder); + } else { + _visitables.get("options").set(index, builder); + } + if (index < 0 || index >= options.size()) { + options.add(builder); + } else { + options.set(index, builder); + } + return (A) this; } + public A addToOptions(io.kubernetes.client.openapi.models.V1PodDNSConfigOption... items) { - if (this.options == null) {this.options = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodDNSConfigOption item : items) {io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder = new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(item);_visitables.get("options").add(builder);this.options.add(builder);} return (A)this; + if (this.options == null) { + this.options = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1PodDNSConfigOption item : items) { + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder = + new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(item); + _visitables.get("options").add(builder); + this.options.add(builder); + } + return (A) this; } - public A addAllToOptions(java.util.Collection items) { - if (this.options == null) {this.options = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodDNSConfigOption item : items) {io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder = new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(item);_visitables.get("options").add(builder);this.options.add(builder);} return (A)this; + + public A addAllToOptions( + java.util.Collection items) { + if (this.options == null) { + this.options = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1PodDNSConfigOption item : items) { + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder = + new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(item); + _visitables.get("options").add(builder); + this.options.add(builder); + } + return (A) this; } + public A removeFromOptions(io.kubernetes.client.openapi.models.V1PodDNSConfigOption... items) { - for (io.kubernetes.client.openapi.models.V1PodDNSConfigOption item : items) {io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder = new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(item);_visitables.get("options").remove(builder);if (this.options != null) {this.options.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1PodDNSConfigOption item : items) { + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder = + new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(item); + _visitables.get("options").remove(builder); + if (this.options != null) { + this.options.remove(builder); + } + } + return (A) this; } - public A removeAllFromOptions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PodDNSConfigOption item : items) {io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder = new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(item);_visitables.get("options").remove(builder);if (this.options != null) {this.options.remove(builder);}} return (A)this; + + public A removeAllFromOptions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PodDNSConfigOption item : items) { + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder = + new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(item); + _visitables.get("options").remove(builder); + if (this.options != null) { + this.options.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromOptions(java.util.function.Predicate predicate) { + + public A removeMatchingFromOptions( + java.util.function.Predicate + predicate) { if (options == null) return (A) this; - final Iterator each = options.iterator(); + final Iterator each = + options.iterator(); final List visitables = _visitables.get("options"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder = each.next(); @@ -121,160 +263,306 @@ public A removeMatchingFromOptions(java.util.function.Predicate getOptions() { return options != null ? build(options) : null; } + public java.util.List buildOptions() { return options != null ? build(options) : null; } - public io.kubernetes.client.openapi.models.V1PodDNSConfigOption buildOption(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PodDNSConfigOption buildOption( + java.lang.Integer index) { return this.options.get(index).build(); } + public io.kubernetes.client.openapi.models.V1PodDNSConfigOption buildFirstOption() { return this.options.get(0).build(); } + public io.kubernetes.client.openapi.models.V1PodDNSConfigOption buildLastOption() { return this.options.get(options.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PodDNSConfigOption buildMatchingOption(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder item: options) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PodDNSConfigOption buildMatchingOption( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder item : options) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingOption(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder item: options) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingOption( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder item : options) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withOptions(java.util.List options) { - if (this.options != null) { _visitables.get("options").removeAll(this.options);} - if (options != null) {this.options = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PodDNSConfigOption item : options){this.addToOptions(item);}} else { this.options = null;} return (A) this; + + public A withOptions( + java.util.List options) { + if (this.options != null) { + _visitables.get("options").removeAll(this.options); + } + if (options != null) { + this.options = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PodDNSConfigOption item : options) { + this.addToOptions(item); + } + } else { + this.options = null; + } + return (A) this; } + public A withOptions(io.kubernetes.client.openapi.models.V1PodDNSConfigOption... options) { - if (this.options != null) {this.options.clear();} - if (options != null) {for (io.kubernetes.client.openapi.models.V1PodDNSConfigOption item :options){ this.addToOptions(item);}} return (A) this; + if (this.options != null) { + this.options.clear(); + } + if (options != null) { + for (io.kubernetes.client.openapi.models.V1PodDNSConfigOption item : options) { + this.addToOptions(item); + } + } + return (A) this; } + public java.lang.Boolean hasOptions() { return options != null && !options.isEmpty(); } + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested addNewOption() { return new io.kubernetes.client.openapi.models.V1PodDNSConfigFluentImpl.OptionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested addNewOptionLike(io.kubernetes.client.openapi.models.V1PodDNSConfigOption item) { - return new io.kubernetes.client.openapi.models.V1PodDNSConfigFluentImpl.OptionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested addNewOptionLike( + io.kubernetes.client.openapi.models.V1PodDNSConfigOption item) { + return new io.kubernetes.client.openapi.models.V1PodDNSConfigFluentImpl.OptionsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested setNewOptionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDNSConfigOption item) { - return new io.kubernetes.client.openapi.models.V1PodDNSConfigFluentImpl.OptionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested setNewOptionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDNSConfigOption item) { + return new io.kubernetes.client.openapi.models.V1PodDNSConfigFluentImpl.OptionsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested editOption(java.lang.Integer index) { - if (options.size() <= index) throw new RuntimeException("Can't edit options. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested editOption( + java.lang.Integer index) { + if (options.size() <= index) + throw new RuntimeException("Can't edit options. Index exceeds size."); return setNewOptionLike(index, buildOption(index)); } - public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested editFirstOption() { - if (options.size() == 0) throw new RuntimeException("Can't edit first options. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested + editFirstOption() { + if (options.size() == 0) + throw new RuntimeException("Can't edit first options. The list is empty."); return setNewOptionLike(0, buildOption(0)); } - public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested editLastOption() { + + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested + editLastOption() { int index = options.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last options. The list is empty."); return setNewOptionLike(index, buildOption(index)); } - public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested editMatchingOption(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested + editMatchingOption( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder> + predicate) { int index = -1; - for (int i=0;i();} + + public A addToSearches(java.lang.Integer index, java.lang.String item) { + if (this.searches == null) { + this.searches = new java.util.ArrayList(); + } this.searches.add(index, item); - return (A)this; + return (A) this; } - public A setToSearches(java.lang.Integer index,java.lang.String item) { - if (this.searches == null) {this.searches = new java.util.ArrayList();} - this.searches.set(index, item); return (A)this; + + public A setToSearches(java.lang.Integer index, java.lang.String item) { + if (this.searches == null) { + this.searches = new java.util.ArrayList(); + } + this.searches.set(index, item); + return (A) this; } + public A addToSearches(java.lang.String... items) { - if (this.searches == null) {this.searches = new java.util.ArrayList();} - for (java.lang.String item : items) {this.searches.add(item);} return (A)this; + if (this.searches == null) { + this.searches = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.searches.add(item); + } + return (A) this; } + public A addAllToSearches(java.util.Collection items) { - if (this.searches == null) {this.searches = new java.util.ArrayList();} - for (java.lang.String item : items) {this.searches.add(item);} return (A)this; + if (this.searches == null) { + this.searches = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.searches.add(item); + } + return (A) this; } + public A removeFromSearches(java.lang.String... items) { - for (java.lang.String item : items) {if (this.searches!= null){ this.searches.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.searches != null) { + this.searches.remove(item); + } + } + return (A) this; } + public A removeAllFromSearches(java.util.Collection items) { - for (java.lang.String item : items) {if (this.searches!= null){ this.searches.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.searches != null) { + this.searches.remove(item); + } + } + return (A) this; } + public java.util.List getSearches() { return this.searches; } + public java.lang.String getSearch(java.lang.Integer index) { return this.searches.get(index); } + public java.lang.String getFirstSearch() { return this.searches.get(0); } + public java.lang.String getLastSearch() { return this.searches.get(searches.size() - 1); } - public java.lang.String getMatchingSearch(java.util.function.Predicate predicate) { - for (java.lang.String item: searches) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingSearch( + java.util.function.Predicate predicate) { + for (java.lang.String item : searches) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingSearch(java.util.function.Predicate predicate) { - for (java.lang.String item: searches) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingSearch( + java.util.function.Predicate predicate) { + for (java.lang.String item : searches) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withSearches(java.util.List searches) { - if (searches != null) {this.searches = new java.util.ArrayList(); for (java.lang.String item : searches){this.addToSearches(item);}} else { this.searches = null;} return (A) this; + if (searches != null) { + this.searches = new java.util.ArrayList(); + for (java.lang.String item : searches) { + this.addToSearches(item); + } + } else { + this.searches = null; + } + return (A) this; } + public A withSearches(java.lang.String... searches) { - if (this.searches != null) {this.searches.clear();} - if (searches != null) {for (java.lang.String item :searches){ this.addToSearches(item);}} return (A) this; + if (this.searches != null) { + this.searches.clear(); + } + if (searches != null) { + for (java.lang.String item : searches) { + this.addToSearches(item); + } + } + return (A) this; } + public java.lang.Boolean hasSearches() { return searches != null && !searches.isEmpty(); } + public A addNewSearch(java.lang.String original) { - return (A)addToSearches(new String(original)); + return (A) addToSearches(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodDNSConfigFluentImpl that = (V1PodDNSConfigFluentImpl) o; - if (nameservers != null ? !nameservers.equals(that.nameservers) :that.nameservers != null) return false; - if (options != null ? !options.equals(that.options) :that.options != null) return false; - if (searches != null ? !searches.equals(that.searches) :that.searches != null) return false; + if (nameservers != null ? !nameservers.equals(that.nameservers) : that.nameservers != null) + return false; + if (options != null ? !options.equals(that.options) : that.options != null) return false; + if (searches != null ? !searches.equals(that.searches) : that.searches != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(nameservers, options, searches, super.hashCode()); + return java.util.Objects.hash(nameservers, options, searches, super.hashCode()); } - public class OptionsNestedImpl extends io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluentImpl> implements io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested,io.kubernetes.client.fluent.Nested{ - OptionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDNSConfigOption item) { + + public class OptionsNestedImpl + extends io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluentImpl< + io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested> + implements io.kubernetes.client.openapi.models.V1PodDNSConfigFluent.OptionsNested, + io.kubernetes.client.fluent.Nested { + OptionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDNSConfigOption item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(this, item); } + OptionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder(this); } + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodDNSConfigFluentImpl.this.setToOptions(index,builder.build()); + return (N) V1PodDNSConfigFluentImpl.this.setToOptions(index, builder.build()); } + public N endOption() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigOptionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigOptionBuilder.java index 1870949cff..d4f1ae2b30 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigOptionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigOptionBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodDNSConfigOptionBuilder extends io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodDNSConfigOptionBuilder + extends io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluentImpl< + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodDNSConfigOption, + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionBuilder> { public V1PodDNSConfigOptionBuilder() { this(false); } + public V1PodDNSConfigOptionBuilder(java.lang.Boolean validationEnabled) { this(new V1PodDNSConfigOption(), validationEnabled); } - public V1PodDNSConfigOptionBuilder(io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent fluent) { + + public V1PodDNSConfigOptionBuilder( + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent fluent) { this(fluent, false); } - public V1PodDNSConfigOptionBuilder(io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodDNSConfigOptionBuilder( + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodDNSConfigOption(), validationEnabled); } - public V1PodDNSConfigOptionBuilder(io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent fluent,io.kubernetes.client.openapi.models.V1PodDNSConfigOption instance) { + + public V1PodDNSConfigOptionBuilder( + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent fluent, + io.kubernetes.client.openapi.models.V1PodDNSConfigOption instance) { this(fluent, instance, false); } - public V1PodDNSConfigOptionBuilder(io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent fluent,io.kubernetes.client.openapi.models.V1PodDNSConfigOption instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodDNSConfigOptionBuilder( + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent fluent, + io.kubernetes.client.openapi.models.V1PodDNSConfigOption instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PodDNSConfigOptionBuilder(io.kubernetes.client.openapi.models.V1PodDNSConfigOption instance) { - this(instance,false); + + public V1PodDNSConfigOptionBuilder( + io.kubernetes.client.openapi.models.V1PodDNSConfigOption instance) { + this(instance, false); } - public V1PodDNSConfigOptionBuilder(io.kubernetes.client.openapi.models.V1PodDNSConfigOption instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodDNSConfigOptionBuilder( + io.kubernetes.client.openapi.models.V1PodDNSConfigOption instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodDNSConfigOption build() { V1PodDNSConfigOption buildable = new V1PodDNSConfigOption(); buildable.setName(fluent.getName()); buildable.setValue(fluent.getValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodDNSConfigOptionBuilder that = (V1PodDNSConfigOptionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigOptionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigOptionFluent.java index 079f2b94ad..a161a279a3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigOptionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigOptionFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodDNSConfigOptionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PodDNSConfigOptionFluent< + A extends io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getValue(); + public A withValue(java.lang.String value); + public java.lang.Boolean hasValue(); - - /** - * Method is deprecated. use withValue instead. - */ + + /** Method is deprecated. use withValue instead. */ @java.lang.Deprecated public A withNewValue(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigOptionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigOptionFluentImpl.java index bc880d6ba6..8f4f732b7e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigOptionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDNSConfigOptionFluentImpl.java @@ -1,69 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1PodDNSConfigOptionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent { + public V1PodDNSConfigOptionFluentImpl() {} - /** - * Generated - */ -public class V1PodDNSConfigOptionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodDNSConfigOptionFluent{ - public V1PodDNSConfigOptionFluentImpl() { - } - public V1PodDNSConfigOptionFluentImpl(io.kubernetes.client.openapi.models.V1PodDNSConfigOption instance) { + public V1PodDNSConfigOptionFluentImpl( + io.kubernetes.client.openapi.models.V1PodDNSConfigOption instance) { this.withName(instance.getName()); this.withValue(instance.getValue()); - } + private java.lang.String name; private java.lang.String value; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getValue() { return this.value; } + public A withValue(java.lang.String value) { - this.value=value; return (A) this; + this.value = value; + return (A) this; } + public java.lang.Boolean hasValue() { return this.value != null; } - - /** - * Method is deprecated. use withValue instead. - */ + + /** Method is deprecated. use withValue instead. */ @java.lang.Deprecated public A withNewValue(java.lang.String original) { - return (A)withValue(new String(original)); + return (A) withValue(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodDNSConfigOptionFluentImpl that = (V1PodDNSConfigOptionFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (value != null ? !value.equals(that.value) :that.value != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (value != null ? !value.equals(that.value) : that.value != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, value, super.hashCode()); + return java.util.Objects.hash(name, value, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetBuilder.java index 4cdd2acc0c..1fba30fa82 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodDisruptionBudgetBuilder extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodDisruptionBudgetBuilder + extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodDisruptionBudget, + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder> { public V1PodDisruptionBudgetBuilder() { this(false); } + public V1PodDisruptionBudgetBuilder(java.lang.Boolean validationEnabled) { this(new V1PodDisruptionBudget(), validationEnabled); } - public V1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent fluent) { + + public V1PodDisruptionBudgetBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent fluent) { this(fluent, false); } - public V1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodDisruptionBudgetBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodDisruptionBudget(), validationEnabled); } - public V1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent fluent,io.kubernetes.client.openapi.models.V1PodDisruptionBudget instance) { + + public V1PodDisruptionBudgetBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent fluent, + io.kubernetes.client.openapi.models.V1PodDisruptionBudget instance) { this(fluent, instance, false); } - public V1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent fluent,io.kubernetes.client.openapi.models.V1PodDisruptionBudget instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodDisruptionBudgetBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent fluent, + io.kubernetes.client.openapi.models.V1PodDisruptionBudget instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1PodDis fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudget instance) { - this(instance,false); + + public V1PodDisruptionBudgetBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudget instance) { + this(instance, false); } - public V1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudget instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodDisruptionBudgetBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudget instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1PodDis this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodDisruptionBudget build() { V1PodDisruptionBudget buildable = new V1PodDisruptionBudget(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1PodDisruptionBudget build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodDisruptionBudgetBuilder that = (V1PodDisruptionBudgetBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetFluent.java index 42d6e143a5..7984a16efd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetFluent.java @@ -1,93 +1,151 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodDisruptionBudgetFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PodDisruptionBudgetFluent< + A extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec getSpec(); + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec item); + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec item); - + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus getStatus(); + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus item); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetFluentImpl.java index 69a6e02fa7..811ac866f6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1PodDisruptionBudgetFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent { + public V1PodDisruptionBudgetFluentImpl() {} - /** - * Generated - */ -public class V1PodDisruptionBudgetFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent{ - public V1PodDisruptionBudgetFluentImpl() { - } - public V1PodDisruptionBudgetFluentImpl(io.kubernetes.client.openapi.models.V1PodDisruptionBudget instance) { + public V1PodDisruptionBudgetFluentImpl( + io.kubernetes.client.openapi.models.V1PodDisruptionBudget instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,311 @@ public V1PodDisruptionBudgetFluentImpl(io.kubernetes.client.openapi.models.V1Pod this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecBuilder spec; private io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested withNewSpec() { + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested + withNewSpec() { return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec item) { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec item) { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl.SpecNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus item) { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus item) { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl.StatusNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodDisruptionBudgetFluentImpl that = (V1PodDisruptionBudgetFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1PodDisruptionBudgetFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluentImpl< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecBuilder builder; + public N and() { return (N) V1PodDisruptionBudgetFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluentImpl< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusBuilder(this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusBuilder builder; + public N and() { return (N) V1PodDisruptionBudgetFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetListBuilder.java index bb095bf657..31701e9c69 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodDisruptionBudgetListBuilder extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodDisruptionBudgetListBuilder + extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluentImpl< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetList, + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListBuilder> { public V1PodDisruptionBudgetListBuilder() { this(false); } + public V1PodDisruptionBudgetListBuilder(java.lang.Boolean validationEnabled) { this(new V1PodDisruptionBudgetList(), validationEnabled); } - public V1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent fluent) { + + public V1PodDisruptionBudgetListBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent fluent) { this(fluent, false); } - public V1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodDisruptionBudgetListBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodDisruptionBudgetList(), validationEnabled); } - public V1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent fluent,io.kubernetes.client.openapi.models.V1PodDisruptionBudgetList instance) { + + public V1PodDisruptionBudgetListBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent fluent, + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetList instance) { this(fluent, instance, false); } - public V1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent fluent,io.kubernetes.client.openapi.models.V1PodDisruptionBudgetList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodDisruptionBudgetListBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent fluent, + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1Po fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetList instance) { - this(instance,false); + + public V1PodDisruptionBudgetListBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetList instance) { + this(instance, false); } - public V1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodDisruptionBudgetListBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1Po this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetList build() { V1PodDisruptionBudgetList buildable = new V1PodDisruptionBudgetList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodDisruptionBudgetListBuilder that = (V1PodDisruptionBudgetListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetListFluent.java index 5da3efbed3..61ea61c5b0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetListFluent.java @@ -1,95 +1,163 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodDisruptionBudgetListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PodDisruptionBudgetListFluent< + A extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDisruptionBudget item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDisruptionBudget item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDisruptionBudget item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDisruptionBudget item); + public A addToItems(io.kubernetes.client.openapi.models.V1PodDisruptionBudget... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1PodDisruptionBudget... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudget buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudget buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PodDisruptionBudget buildFirstItem(); + public io.kubernetes.client.openapi.models.V1PodDisruptionBudget buildLastItem(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudget buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudget buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1PodDisruptionBudget... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudget item); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDisruptionBudget item); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudget item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDisruptionBudget item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent>{ + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluent< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetListFluentImpl.java index 42b5f752f3..021d15ac4a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1PodDisruptionBudgetListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent{ - public V1PodDisruptionBudgetListFluentImpl() { - } - public V1PodDisruptionBudgetListFluentImpl(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetList instance) { + +/** Generated */ +public class V1PodDisruptionBudgetListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent { + public V1PodDisruptionBudgetListFluentImpl() {} + + public V1PodDisruptionBudgetListFluentImpl( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,131 @@ public V1PodDisruptionBudgetListFluentImpl(io.kubernetes.client.openapi.models.V this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDisruptionBudget item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder = new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDisruptionBudget item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder>(); + } + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder = + new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDisruptionBudget item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder = new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDisruptionBudget item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder>(); + } + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder = + new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1PodDisruptionBudget... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodDisruptionBudget item : items) {io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder = new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1PodDisruptionBudget item : items) { + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder = + new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodDisruptionBudget item : items) {io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder = new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1PodDisruptionBudget item : items) { + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder = + new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1PodDisruptionBudget... items) { - for (io.kubernetes.client.openapi.models.V1PodDisruptionBudget item : items) {io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder = new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1PodDisruptionBudget item : items) { + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder = + new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PodDisruptionBudget item : items) {io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder = new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PodDisruptionBudget item : items) { + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder = + new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder = each.next(); @@ -87,174 +164,287 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudget buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudget buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1PodDisruptionBudget buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1PodDisruptionBudget buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudget buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudget buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PodDisruptionBudget item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PodDisruptionBudget item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1PodDisruptionBudget... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1PodDisruptionBudget item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1PodDisruptionBudget item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudget item) { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1PodDisruptionBudget item) { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDisruptionBudget item) { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDisruptionBudget item) { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodDisruptionBudgetListFluentImpl that = (V1PodDisruptionBudgetListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl> implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodDisruptionBudget item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetFluentImpl< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodDisruptionBudget item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder(this); } + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodDisruptionBudgetListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1PodDisruptionBudgetListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetListFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1PodDisruptionBudgetListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetSpecBuilder.java index 94c2b50c88..3cb26df8e3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetSpecBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodDisruptionBudgetSpecBuilder extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodDisruptionBudgetSpecBuilder + extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluentImpl< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec, + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecBuilder> { public V1PodDisruptionBudgetSpecBuilder() { this(false); } + public V1PodDisruptionBudgetSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1PodDisruptionBudgetSpec(), validationEnabled); } - public V1PodDisruptionBudgetSpecBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent fluent) { + + public V1PodDisruptionBudgetSpecBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent fluent) { this(fluent, false); } - public V1PodDisruptionBudgetSpecBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodDisruptionBudgetSpecBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodDisruptionBudgetSpec(), validationEnabled); } - public V1PodDisruptionBudgetSpecBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent fluent,io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec instance) { + + public V1PodDisruptionBudgetSpecBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent fluent, + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec instance) { this(fluent, instance, false); } - public V1PodDisruptionBudgetSpecBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent fluent,io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodDisruptionBudgetSpecBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent fluent, + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMaxUnavailable(instance.getMaxUnavailable()); fluent.withMinAvailable(instance.getMinAvailable()); fluent.withSelector(instance.getSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PodDisruptionBudgetSpecBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec instance) { - this(instance,false); + + public V1PodDisruptionBudgetSpecBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec instance) { + this(instance, false); } - public V1PodDisruptionBudgetSpecBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodDisruptionBudgetSpecBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMaxUnavailable(instance.getMaxUnavailable()); this.withMinAvailable(instance.getMinAvailable()); this.withSelector(instance.getSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec build() { V1PodDisruptionBudgetSpec buildable = new V1PodDisruptionBudgetSpec(); buildable.setMaxUnavailable(fluent.getMaxUnavailable()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec build() { buildable.setSelector(fluent.getSelector()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodDisruptionBudgetSpecBuilder that = (V1PodDisruptionBudgetSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetSpecFluent.java index cebccd1d78..40399abb13 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetSpecFluent.java @@ -1,46 +1,77 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.custom.IntOrString; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodDisruptionBudgetSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PodDisruptionBudgetSpecFluent< + A extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public io.kubernetes.client.custom.IntOrString getMaxUnavailable(); + public A withMaxUnavailable(io.kubernetes.client.custom.IntOrString maxUnavailable); + public java.lang.Boolean hasMaxUnavailable(); + public A withNewMaxUnavailable(int value); + public A withNewMaxUnavailable(java.lang.String value); + public io.kubernetes.client.custom.IntOrString getMinAvailable(); + public A withMinAvailable(io.kubernetes.client.custom.IntOrString minAvailable); + public java.lang.Boolean hasMinAvailable(); + public A withNewMinAvailable(int value); + public A withNewMinAvailable(java.lang.String value); - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested editSelector(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested + withNewSelector(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested + editSelector(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested + editOrNewSelector(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested< + N>> { public N and(); + public N endSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetSpecFluentImpl.java index 1554a0e582..789c187f74 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetSpecFluentImpl.java @@ -1,121 +1,177 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; import io.kubernetes.client.custom.IntOrString; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1PodDisruptionBudgetSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent{ - public V1PodDisruptionBudgetSpecFluentImpl() { - } - public V1PodDisruptionBudgetSpecFluentImpl(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec instance) { + +/** Generated */ +public class V1PodDisruptionBudgetSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent { + public V1PodDisruptionBudgetSpecFluentImpl() {} + + public V1PodDisruptionBudgetSpecFluentImpl( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpec instance) { this.withMaxUnavailable(instance.getMaxUnavailable()); this.withMinAvailable(instance.getMinAvailable()); this.withSelector(instance.getSelector()); - } + private io.kubernetes.client.custom.IntOrString maxUnavailable; private io.kubernetes.client.custom.IntOrString minAvailable; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder selector; + public io.kubernetes.client.custom.IntOrString getMaxUnavailable() { return this.maxUnavailable; } + public A withMaxUnavailable(io.kubernetes.client.custom.IntOrString maxUnavailable) { - this.maxUnavailable=maxUnavailable; return (A) this; + this.maxUnavailable = maxUnavailable; + return (A) this; } + public java.lang.Boolean hasMaxUnavailable() { return this.maxUnavailable != null; } + public A withNewMaxUnavailable(int value) { - return (A)withMaxUnavailable(new IntOrString(value)); + return (A) withMaxUnavailable(new IntOrString(value)); } + public A withNewMaxUnavailable(java.lang.String value) { - return (A)withMaxUnavailable(new IntOrString(value)); + return (A) withMaxUnavailable(new IntOrString(value)); } + public io.kubernetes.client.custom.IntOrString getMinAvailable() { return this.minAvailable; } + public A withMinAvailable(io.kubernetes.client.custom.IntOrString minAvailable) { - this.minAvailable=minAvailable; return (A) this; + this.minAvailable = minAvailable; + return (A) this; } + public java.lang.Boolean hasMinAvailable() { return this.minAvailable != null; } + public A withNewMinAvailable(int value) { - return (A)withMinAvailable(new IntOrString(value)); + return (A) withMinAvailable(new IntOrString(value)); } + public A withNewMinAvailable(java.lang.String value) { - return (A)withMinAvailable(new IntOrString(value)); + return (A) withMinAvailable(new IntOrString(value)); } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested withNewSelector() { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluentImpl.SelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested + withNewSelector() { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluentImpl + .SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluentImpl.SelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluentImpl + .SelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested editSelector() { + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested + editSelector() { return withNewSelectorLike(getSelector()); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested + editOrNewSelector() { + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodDisruptionBudgetSpecFluentImpl that = (V1PodDisruptionBudgetSpecFluentImpl) o; - if (maxUnavailable != null ? !maxUnavailable.equals(that.maxUnavailable) :that.maxUnavailable != null) return false; - if (minAvailable != null ? !minAvailable.equals(that.minAvailable) :that.minAvailable != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; + if (maxUnavailable != null + ? !maxUnavailable.equals(that.maxUnavailable) + : that.maxUnavailable != null) return false; + if (minAvailable != null ? !minAvailable.equals(that.minAvailable) : that.minAvailable != null) + return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(maxUnavailable, minAvailable, selector, super.hashCode()); + return java.util.Objects.hash(maxUnavailable, minAvailable, selector, super.hashCode()); } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested> + implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetSpecFluent.SelectorNested< + N>, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1PodDisruptionBudgetSpecFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetStatusBuilder.java index 9eb09a388b..6a4cad0f83 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodDisruptionBudgetStatusBuilder extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodDisruptionBudgetStatusBuilder + extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluentImpl< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus, + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusBuilder> { public V1PodDisruptionBudgetStatusBuilder() { this(false); } + public V1PodDisruptionBudgetStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1PodDisruptionBudgetStatus(), validationEnabled); } - public V1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent fluent) { + + public V1PodDisruptionBudgetStatusBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent fluent) { this(fluent, false); } - public V1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodDisruptionBudgetStatusBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodDisruptionBudgetStatus(), validationEnabled); } - public V1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent fluent,io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus instance) { + + public V1PodDisruptionBudgetStatusBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent fluent, + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus instance) { this(fluent, instance, false); } - public V1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent fluent,io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodDisruptionBudgetStatusBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent fluent, + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditions(instance.getConditions()); fluent.withCurrentHealthy(instance.getCurrentHealthy()); @@ -35,13 +62,18 @@ public V1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1 fluent.withObservedGeneration(instance.getObservedGeneration()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus instance) { - this(instance,false); + + public V1PodDisruptionBudgetStatusBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus instance) { + this(instance, false); } - public V1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodDisruptionBudgetStatusBuilder( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditions(instance.getConditions()); this.withCurrentHealthy(instance.getCurrentHealthy()); @@ -56,10 +88,12 @@ public V1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1 this.withObservedGeneration(instance.getObservedGeneration()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus build() { V1PodDisruptionBudgetStatus buildable = new V1PodDisruptionBudgetStatus(); buildable.setConditions(fluent.getConditions()); @@ -71,18 +105,23 @@ public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus build() { buildable.setObservedGeneration(fluent.getObservedGeneration()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodDisruptionBudgetStatusBuilder that = (V1PodDisruptionBudgetStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetStatusFluent.java index 2c78998f48..160a354f54 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetStatusFluent.java @@ -1,83 +1,149 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import java.lang.Long; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1PodDisruptionBudgetStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item); +/** Generated */ +public interface V1PodDisruptionBudgetStatusFluent< + A extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1Condition... items); - public A addAllToConditions(java.util.Collection items); + + public A addAllToConditions( + java.util.Collection items); + public A removeFromConditions(io.kubernetes.client.openapi.models.V1Condition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getConditions(); + public java.util.List buildConditions(); + public io.kubernetes.client.openapi.models.V1Condition buildCondition(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Condition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1Condition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1Condition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); + + public io.kubernetes.client.openapi.models.V1Condition buildMatchingCondition( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate); + + public A withConditions( + java.util.List conditions); + public A withConditions(io.kubernetes.client.openapi.models.V1Condition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1Condition item); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1Condition item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate + predicate); + public java.lang.Integer getCurrentHealthy(); + public A withCurrentHealthy(java.lang.Integer currentHealthy); + public java.lang.Boolean hasCurrentHealthy(); + public java.lang.Integer getDesiredHealthy(); + public A withDesiredHealthy(java.lang.Integer desiredHealthy); + public java.lang.Boolean hasDesiredHealthy(); - public A addToDisruptedPods(java.lang.String key,java.time.OffsetDateTime value); - public A addToDisruptedPods(java.util.Map map); + + public A addToDisruptedPods(java.lang.String key, java.time.OffsetDateTime value); + + public A addToDisruptedPods(java.util.Map map); + public A removeFromDisruptedPods(java.lang.String key); - public A removeFromDisruptedPods(java.util.Map map); - public java.util.Map getDisruptedPods(); - public A withDisruptedPods(java.util.Map disruptedPods); + + public A removeFromDisruptedPods(java.util.Map map); + + public java.util.Map getDisruptedPods(); + + public A withDisruptedPods( + java.util.Map disruptedPods); + public java.lang.Boolean hasDisruptedPods(); + public java.lang.Integer getDisruptionsAllowed(); + public A withDisruptionsAllowed(java.lang.Integer disruptionsAllowed); + public java.lang.Boolean hasDisruptionsAllowed(); + public java.lang.Integer getExpectedPods(); + public A withExpectedPods(java.lang.Integer expectedPods); + public java.lang.Boolean hasExpectedPods(); + public java.lang.Long getObservedGeneration(); + public A withObservedGeneration(java.lang.Long observedGeneration); + public java.lang.Boolean hasObservedGeneration(); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ConditionFluent< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent + .ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetStatusFluentImpl.java index 8b2dd11e4e..a50d92ac8e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodDisruptionBudgetStatusFluentImpl.java @@ -1,30 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.lang.Long; -import java.util.Collection; -import java.lang.Object; -import java.util.Map; - - /** - * Generated - */ -public class V1PodDisruptionBudgetStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent{ - public V1PodDisruptionBudgetStatusFluentImpl() { - } - public V1PodDisruptionBudgetStatusFluentImpl(io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus instance) { + +/** Generated */ +public class V1PodDisruptionBudgetStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent { + public V1PodDisruptionBudgetStatusFluentImpl() {} + + public V1PodDisruptionBudgetStatusFluentImpl( + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatus instance) { this.withConditions(instance.getConditions()); this.withCurrentHealthy(instance.getCurrentHealthy()); @@ -38,43 +37,112 @@ public V1PodDisruptionBudgetStatusFluentImpl(io.kubernetes.client.openapi.models this.withExpectedPods(instance.getExpectedPods()); this.withObservedGeneration(instance.getObservedGeneration()); - } + private java.util.ArrayList conditions; private java.lang.Integer currentHealthy; private java.lang.Integer desiredHealthy; - private java.util.Map disruptedPods; + private java.util.Map disruptedPods; private java.lang.Integer disruptionsAllowed; private java.lang.Integer expectedPods; private java.lang.Long observedGeneration; - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } + public A addToConditions(io.kubernetes.client.openapi.models.V1Condition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Condition item : items) {io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Condition item : items) { + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Condition item : items) {io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Condition item : items) { + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } + public A removeFromConditions(io.kubernetes.client.openapi.models.V1Condition... items) { - for (io.kubernetes.client.openapi.models.V1Condition item : items) {io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Condition item : items) { + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Condition item : items) {io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Condition item : items) { + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ConditionBuilder builder = each.next(); @@ -83,180 +151,336 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { return conditions != null ? build(conditions) : null; } + public java.util.List buildConditions() { return conditions != null ? build(conditions) : null; } + public io.kubernetes.client.openapi.models.V1Condition buildCondition(java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Condition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Condition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Condition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Condition buildMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Condition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Condition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } + public A withConditions(io.kubernetes.client.openapi.models.V1Condition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1Condition item :conditions){ this.addToConditions(item);}} return (A) this; + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1Condition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1Condition item) { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1Condition item) { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item) { - return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item) { + return new io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i map) { - if(this.disruptedPods == null && map != null) { this.disruptedPods = new java.util.LinkedHashMap(); } - if(map != null) { this.disruptedPods.putAll(map);} return (A)this; + + public A addToDisruptedPods(java.util.Map map) { + if (this.disruptedPods == null && map != null) { + this.disruptedPods = new java.util.LinkedHashMap(); + } + if (map != null) { + this.disruptedPods.putAll(map); + } + return (A) this; } + public A removeFromDisruptedPods(java.lang.String key) { - if(this.disruptedPods == null) { return (A) this; } - if(key != null && this.disruptedPods != null) {this.disruptedPods.remove(key);} return (A)this; + if (this.disruptedPods == null) { + return (A) this; + } + if (key != null && this.disruptedPods != null) { + this.disruptedPods.remove(key); + } + return (A) this; } - public A removeFromDisruptedPods(java.util.Map map) { - if(this.disruptedPods == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.disruptedPods != null){this.disruptedPods.remove(key);}}} return (A)this; + + public A removeFromDisruptedPods(java.util.Map map) { + if (this.disruptedPods == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.disruptedPods != null) { + this.disruptedPods.remove(key); + } + } + } + return (A) this; } - public java.util.Map getDisruptedPods() { + + public java.util.Map getDisruptedPods() { return this.disruptedPods; } - public A withDisruptedPods(java.util.Map disruptedPods) { - if (disruptedPods == null) { this.disruptedPods = null;} else {this.disruptedPods = new java.util.LinkedHashMap(disruptedPods);} return (A) this; + + public A withDisruptedPods( + java.util.Map disruptedPods) { + if (disruptedPods == null) { + this.disruptedPods = null; + } else { + this.disruptedPods = new java.util.LinkedHashMap(disruptedPods); + } + return (A) this; } + public java.lang.Boolean hasDisruptedPods() { return this.disruptedPods != null; } + public java.lang.Integer getDisruptionsAllowed() { return this.disruptionsAllowed; } + public A withDisruptionsAllowed(java.lang.Integer disruptionsAllowed) { - this.disruptionsAllowed=disruptionsAllowed; return (A) this; + this.disruptionsAllowed = disruptionsAllowed; + return (A) this; } + public java.lang.Boolean hasDisruptionsAllowed() { return this.disruptionsAllowed != null; } + public java.lang.Integer getExpectedPods() { return this.expectedPods; } + public A withExpectedPods(java.lang.Integer expectedPods) { - this.expectedPods=expectedPods; return (A) this; + this.expectedPods = expectedPods; + return (A) this; } + public java.lang.Boolean hasExpectedPods() { return this.expectedPods != null; } + public java.lang.Long getObservedGeneration() { return this.observedGeneration; } + public A withObservedGeneration(java.lang.Long observedGeneration) { - this.observedGeneration=observedGeneration; return (A) this; + this.observedGeneration = observedGeneration; + return (A) this; } + public java.lang.Boolean hasObservedGeneration() { return this.observedGeneration != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodDisruptionBudgetStatusFluentImpl that = (V1PodDisruptionBudgetStatusFluentImpl) o; - if (conditions != null ? !conditions.equals(that.conditions) :that.conditions != null) return false; - if (currentHealthy != null ? !currentHealthy.equals(that.currentHealthy) :that.currentHealthy != null) return false; - if (desiredHealthy != null ? !desiredHealthy.equals(that.desiredHealthy) :that.desiredHealthy != null) return false; - if (disruptedPods != null ? !disruptedPods.equals(that.disruptedPods) :that.disruptedPods != null) return false; - if (disruptionsAllowed != null ? !disruptionsAllowed.equals(that.disruptionsAllowed) :that.disruptionsAllowed != null) return false; - if (expectedPods != null ? !expectedPods.equals(that.expectedPods) :that.expectedPods != null) return false; - if (observedGeneration != null ? !observedGeneration.equals(that.observedGeneration) :that.observedGeneration != null) return false; + if (conditions != null ? !conditions.equals(that.conditions) : that.conditions != null) + return false; + if (currentHealthy != null + ? !currentHealthy.equals(that.currentHealthy) + : that.currentHealthy != null) return false; + if (desiredHealthy != null + ? !desiredHealthy.equals(that.desiredHealthy) + : that.desiredHealthy != null) return false; + if (disruptedPods != null + ? !disruptedPods.equals(that.disruptedPods) + : that.disruptedPods != null) return false; + if (disruptionsAllowed != null + ? !disruptionsAllowed.equals(that.disruptionsAllowed) + : that.disruptionsAllowed != null) return false; + if (expectedPods != null ? !expectedPods.equals(that.expectedPods) : that.expectedPods != null) + return false; + if (observedGeneration != null + ? !observedGeneration.equals(that.observedGeneration) + : that.observedGeneration != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(conditions, currentHealthy, desiredHealthy, disruptedPods, disruptionsAllowed, expectedPods, observedGeneration, super.hashCode()); + return java.util.Objects.hash( + conditions, + currentHealthy, + desiredHealthy, + disruptedPods, + disruptionsAllowed, + expectedPods, + observedGeneration, + super.hashCode()); } - public class ConditionsNestedImpl extends io.kubernetes.client.openapi.models.V1ConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1ConditionFluentImpl< + io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1PodDisruptionBudgetStatusFluent + .ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1ConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodDisruptionBudgetStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1PodDisruptionBudgetStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodFluent.java index 32ffa20d2f..5a424977b1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodFluent.java @@ -1,93 +1,142 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PodFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodSpec getSpec(); + public io.kubernetes.client.openapi.models.V1PodSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1PodSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1PodSpec item); + + public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1PodSpec item); + public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PodSpec item); - + + public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1PodSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodStatus getStatus(); + public io.kubernetes.client.openapi.models.V1PodStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1PodStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1PodStatus item); + + public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1PodStatus item); + public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PodStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1PodStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodSpecFluent< + io.kubernetes.client.openapi.models.V1PodFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodStatusFluent< + io.kubernetes.client.openapi.models.V1PodFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodFluentImpl.java index 0367b21b2c..9784392012 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1PodFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodFluent { + public V1PodFluentImpl() {} - /** - * Generated - */ -public class V1PodFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodFluent{ - public V1PodFluentImpl() { - } public V1PodFluentImpl(io.kubernetes.client.openapi.models.V1Pod instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +28,294 @@ public V1PodFluentImpl(io.kubernetes.client.openapi.models.V1Pod instance) { this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1PodSpecBuilder spec; private io.kubernetes.client.openapi.models.V1PodStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1PodFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1PodFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1PodSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1PodSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1PodSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1PodSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1PodFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1PodSpec item) { + + public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1PodSpec item) { return new io.kubernetes.client.openapi.models.V1PodFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1PodSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1PodSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PodSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1PodFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1PodSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1PodStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1PodStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1PodStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1PodStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1PodFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1PodStatus item) { + + public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1PodStatus item) { return new io.kubernetes.client.openapi.models.V1PodFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1PodStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1PodStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1PodStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1PodFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1PodStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodFluentImpl that = (V1PodFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1PodFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1PodFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1PodSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1PodFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1PodSpecFluentImpl< + io.kubernetes.client.openapi.models.V1PodFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1PodFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1PodSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1PodSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PodSpecBuilder builder; + public N and() { return (N) V1PodFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1PodStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1PodFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1PodStatusFluentImpl< + io.kubernetes.client.openapi.models.V1PodFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1PodFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1PodStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1PodStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1PodStatusBuilder builder; + public N and() { return (N) V1PodFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodIPBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodIPBuilder.java index 2181fe9110..604a307e47 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodIPBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodIPBuilder.java @@ -1,58 +1,94 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodIPBuilder extends io.kubernetes.client.openapi.models.V1PodIPFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodIPBuilder + extends io.kubernetes.client.openapi.models.V1PodIPFluentImpl< + io.kubernetes.client.openapi.models.V1PodIPBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodIP, + io.kubernetes.client.openapi.models.V1PodIPBuilder> { public V1PodIPBuilder() { this(false); } + public V1PodIPBuilder(java.lang.Boolean validationEnabled) { this(new V1PodIP(), validationEnabled); } + public V1PodIPBuilder(io.kubernetes.client.openapi.models.V1PodIPFluent fluent) { this(fluent, false); } - public V1PodIPBuilder(io.kubernetes.client.openapi.models.V1PodIPFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodIPBuilder( + io.kubernetes.client.openapi.models.V1PodIPFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodIP(), validationEnabled); } - public V1PodIPBuilder(io.kubernetes.client.openapi.models.V1PodIPFluent fluent,io.kubernetes.client.openapi.models.V1PodIP instance) { + + public V1PodIPBuilder( + io.kubernetes.client.openapi.models.V1PodIPFluent fluent, + io.kubernetes.client.openapi.models.V1PodIP instance) { this(fluent, instance, false); } - public V1PodIPBuilder(io.kubernetes.client.openapi.models.V1PodIPFluent fluent,io.kubernetes.client.openapi.models.V1PodIP instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodIPBuilder( + io.kubernetes.client.openapi.models.V1PodIPFluent fluent, + io.kubernetes.client.openapi.models.V1PodIP instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withIp(instance.getIp()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodIPBuilder(io.kubernetes.client.openapi.models.V1PodIP instance) { - this(instance,false); + this(instance, false); } - public V1PodIPBuilder(io.kubernetes.client.openapi.models.V1PodIP instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodIPBuilder( + io.kubernetes.client.openapi.models.V1PodIP instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withIp(instance.getIp()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodIPFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodIP build() { V1PodIP buildable = new V1PodIP(); buildable.setIp(fluent.getIp()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodIPBuilder that = (V1PodIPBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodIPFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodIPFluent.java index 185c5a68d9..e32578825c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodIPFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodIPFluent.java @@ -1,23 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodIPFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PodIPFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getIp(); + public A withIp(java.lang.String ip); + public java.lang.Boolean hasIp(); - - /** - * Method is deprecated. use withIp instead. - */ + + /** Method is deprecated. use withIp instead. */ @java.lang.Deprecated public A withNewIp(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodIPFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodIPFluentImpl.java index 118f504801..296286257b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodIPFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodIPFluentImpl.java @@ -1,48 +1,57 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1PodIPFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodIPFluent{ - public V1PodIPFluentImpl() { - } +/** Generated */ +public class V1PodIPFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodIPFluent { + public V1PodIPFluentImpl() {} + public V1PodIPFluentImpl(io.kubernetes.client.openapi.models.V1PodIP instance) { this.withIp(instance.getIp()); - } + private java.lang.String ip; + public java.lang.String getIp() { return this.ip; } + public A withIp(java.lang.String ip) { - this.ip=ip; return (A) this; + this.ip = ip; + return (A) this; } + public java.lang.Boolean hasIp() { return this.ip != null; } - - /** - * Method is deprecated. use withIp instead. - */ + + /** Method is deprecated. use withIp instead. */ @java.lang.Deprecated public A withNewIp(java.lang.String original) { - return (A)withIp(new String(original)); + return (A) withIp(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodIPFluentImpl that = (V1PodIPFluentImpl) o; - if (ip != null ? !ip.equals(that.ip) :that.ip != null) return false; + if (ip != null ? !ip.equals(that.ip) : that.ip != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(ip, super.hashCode()); + return java.util.Objects.hash(ip, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodListBuilder.java index 1ea0454503..30690d96d5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodListBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodListBuilder extends io.kubernetes.client.openapi.models.V1PodListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodListBuilder + extends io.kubernetes.client.openapi.models.V1PodListFluentImpl< + io.kubernetes.client.openapi.models.V1PodListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodList, + io.kubernetes.client.openapi.models.V1PodListBuilder> { public V1PodListBuilder() { this(false); } + public V1PodListBuilder(java.lang.Boolean validationEnabled) { this(new V1PodList(), validationEnabled); } + public V1PodListBuilder(io.kubernetes.client.openapi.models.V1PodListFluent fluent) { this(fluent, false); } - public V1PodListBuilder(io.kubernetes.client.openapi.models.V1PodListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodListBuilder( + io.kubernetes.client.openapi.models.V1PodListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodList(), validationEnabled); } - public V1PodListBuilder(io.kubernetes.client.openapi.models.V1PodListFluent fluent,io.kubernetes.client.openapi.models.V1PodList instance) { + + public V1PodListBuilder( + io.kubernetes.client.openapi.models.V1PodListFluent fluent, + io.kubernetes.client.openapi.models.V1PodList instance) { this(fluent, instance, false); } - public V1PodListBuilder(io.kubernetes.client.openapi.models.V1PodListFluent fluent,io.kubernetes.client.openapi.models.V1PodList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodListBuilder( + io.kubernetes.client.openapi.models.V1PodListFluent fluent, + io.kubernetes.client.openapi.models.V1PodList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +55,16 @@ public V1PodListBuilder(io.kubernetes.client.openapi.models.V1PodListFluent f fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodListBuilder(io.kubernetes.client.openapi.models.V1PodList instance) { - this(instance,false); + this(instance, false); } - public V1PodListBuilder(io.kubernetes.client.openapi.models.V1PodList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodListBuilder( + io.kubernetes.client.openapi.models.V1PodList instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +73,12 @@ public V1PodListBuilder(io.kubernetes.client.openapi.models.V1PodList instance,j this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodList build() { V1PodList buildable = new V1PodList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +87,23 @@ public io.kubernetes.client.openapi.models.V1PodList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodListBuilder that = (V1PodListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodListFluent.java index f583511bfa..329eb52e65 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodListFluent.java @@ -1,95 +1,143 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PodListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Pod item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Pod item); + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Pod item); + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Pod item); + public A addToItems(io.kubernetes.client.openapi.models.V1Pod... items); + public A addAllToItems(java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1Pod... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1Pod buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Pod buildFirstItem(); + public io.kubernetes.client.openapi.models.V1Pod buildLastItem(); - public io.kubernetes.client.openapi.models.V1Pod buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Pod buildMatchingItem( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1Pod... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Pod item); - public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Pod item); - public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Pod item); + + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Pod item); + + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodFluent>{ + + public io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodFluent< + io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodListFluentImpl.java index 562d635ee3..12e700f0d9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodListFluentImpl.java @@ -1,25 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1PodListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodListFluent{ - public V1PodListFluentImpl() { - } +/** Generated */ +public class V1PodListFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodListFluent { + public V1PodListFluentImpl() {} + public V1PodListFluentImpl(io.kubernetes.client.openapi.models.V1PodList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +29,115 @@ public V1PodListFluentImpl(io.kubernetes.client.openapi.models.V1PodList instanc this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Pod item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodBuilder builder = new io.kubernetes.client.openapi.models.V1PodBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Pod item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodBuilder builder = + new io.kubernetes.client.openapi.models.V1PodBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Pod item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodBuilder builder = new io.kubernetes.client.openapi.models.V1PodBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Pod item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodBuilder builder = + new io.kubernetes.client.openapi.models.V1PodBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1Pod... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Pod item : items) {io.kubernetes.client.openapi.models.V1PodBuilder builder = new io.kubernetes.client.openapi.models.V1PodBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Pod item : items) { + io.kubernetes.client.openapi.models.V1PodBuilder builder = + new io.kubernetes.client.openapi.models.V1PodBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Pod item : items) {io.kubernetes.client.openapi.models.V1PodBuilder builder = new io.kubernetes.client.openapi.models.V1PodBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Pod item : items) { + io.kubernetes.client.openapi.models.V1PodBuilder builder = + new io.kubernetes.client.openapi.models.V1PodBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1Pod... items) { - for (io.kubernetes.client.openapi.models.V1Pod item : items) {io.kubernetes.client.openapi.models.V1PodBuilder builder = new io.kubernetes.client.openapi.models.V1PodBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Pod item : items) { + io.kubernetes.client.openapi.models.V1PodBuilder builder = + new io.kubernetes.client.openapi.models.V1PodBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Pod item : items) {io.kubernetes.client.openapi.models.V1PodBuilder builder = new io.kubernetes.client.openapi.models.V1PodBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Pod item : items) { + io.kubernetes.client.openapi.models.V1PodBuilder builder = + new io.kubernetes.client.openapi.models.V1PodBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +148,265 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1Pod buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Pod buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Pod buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Pod buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Pod buildMatchingItem( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1PodBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1PodBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Pod item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Pod item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1Pod... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1Pod item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1Pod item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1PodListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Pod item) { + + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Pod item) { return new io.kubernetes.client.openapi.models.V1PodListFluentImpl.ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Pod item) { + + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Pod item) { return new io.kubernetes.client.openapi.models.V1PodListFluentImpl.ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate) { int index = -1; - for (int i=0;i withNewMetadata() { return new io.kubernetes.client.openapi.models.V1PodListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + + public io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ListMeta item) { return new io.kubernetes.client.openapi.models.V1PodListFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodListFluentImpl that = (V1PodListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1PodFluentImpl> implements io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Pod item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1PodFluentImpl< + io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1PodListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Pod item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1PodBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PodBuilder(this); } + io.kubernetes.client.openapi.models.V1PodBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1PodListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1PodListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1PodListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodOSBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodOSBuilder.java index f725e880a6..cc325fa70a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodOSBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodOSBuilder.java @@ -1,58 +1,94 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodOSBuilder extends io.kubernetes.client.openapi.models.V1PodOSFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodOSBuilder + extends io.kubernetes.client.openapi.models.V1PodOSFluentImpl< + io.kubernetes.client.openapi.models.V1PodOSBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodOS, + io.kubernetes.client.openapi.models.V1PodOSBuilder> { public V1PodOSBuilder() { this(false); } + public V1PodOSBuilder(java.lang.Boolean validationEnabled) { this(new V1PodOS(), validationEnabled); } + public V1PodOSBuilder(io.kubernetes.client.openapi.models.V1PodOSFluent fluent) { this(fluent, false); } - public V1PodOSBuilder(io.kubernetes.client.openapi.models.V1PodOSFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodOSBuilder( + io.kubernetes.client.openapi.models.V1PodOSFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodOS(), validationEnabled); } - public V1PodOSBuilder(io.kubernetes.client.openapi.models.V1PodOSFluent fluent,io.kubernetes.client.openapi.models.V1PodOS instance) { + + public V1PodOSBuilder( + io.kubernetes.client.openapi.models.V1PodOSFluent fluent, + io.kubernetes.client.openapi.models.V1PodOS instance) { this(fluent, instance, false); } - public V1PodOSBuilder(io.kubernetes.client.openapi.models.V1PodOSFluent fluent,io.kubernetes.client.openapi.models.V1PodOS instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodOSBuilder( + io.kubernetes.client.openapi.models.V1PodOSFluent fluent, + io.kubernetes.client.openapi.models.V1PodOS instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodOSBuilder(io.kubernetes.client.openapi.models.V1PodOS instance) { - this(instance,false); + this(instance, false); } - public V1PodOSBuilder(io.kubernetes.client.openapi.models.V1PodOS instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodOSBuilder( + io.kubernetes.client.openapi.models.V1PodOS instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodOSFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodOS build() { V1PodOS buildable = new V1PodOS(); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodOSBuilder that = (V1PodOSBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodOSFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodOSFluent.java index 8843845870..5b0a9beaed 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodOSFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodOSFluent.java @@ -1,23 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodOSFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PodOSFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodOSFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodOSFluentImpl.java index 954a905dac..43b7030802 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodOSFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodOSFluentImpl.java @@ -1,48 +1,57 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1PodOSFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodOSFluent{ - public V1PodOSFluentImpl() { - } +/** Generated */ +public class V1PodOSFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodOSFluent { + public V1PodOSFluentImpl() {} + public V1PodOSFluentImpl(io.kubernetes.client.openapi.models.V1PodOS instance) { this.withName(instance.getName()); - } + private java.lang.String name; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodOSFluentImpl that = (V1PodOSFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, super.hashCode()); + return java.util.Objects.hash(name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodReadinessGateBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodReadinessGateBuilder.java index e13ccf34a5..9368261ddf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodReadinessGateBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodReadinessGateBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodReadinessGateBuilder extends io.kubernetes.client.openapi.models.V1PodReadinessGateFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodReadinessGateBuilder + extends io.kubernetes.client.openapi.models.V1PodReadinessGateFluentImpl< + io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodReadinessGate, + io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder> { public V1PodReadinessGateBuilder() { this(false); } + public V1PodReadinessGateBuilder(java.lang.Boolean validationEnabled) { this(new V1PodReadinessGate(), validationEnabled); } - public V1PodReadinessGateBuilder(io.kubernetes.client.openapi.models.V1PodReadinessGateFluent fluent) { + + public V1PodReadinessGateBuilder( + io.kubernetes.client.openapi.models.V1PodReadinessGateFluent fluent) { this(fluent, false); } - public V1PodReadinessGateBuilder(io.kubernetes.client.openapi.models.V1PodReadinessGateFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodReadinessGateBuilder( + io.kubernetes.client.openapi.models.V1PodReadinessGateFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodReadinessGate(), validationEnabled); } - public V1PodReadinessGateBuilder(io.kubernetes.client.openapi.models.V1PodReadinessGateFluent fluent,io.kubernetes.client.openapi.models.V1PodReadinessGate instance) { + + public V1PodReadinessGateBuilder( + io.kubernetes.client.openapi.models.V1PodReadinessGateFluent fluent, + io.kubernetes.client.openapi.models.V1PodReadinessGate instance) { this(fluent, instance, false); } - public V1PodReadinessGateBuilder(io.kubernetes.client.openapi.models.V1PodReadinessGateFluent fluent,io.kubernetes.client.openapi.models.V1PodReadinessGate instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodReadinessGateBuilder( + io.kubernetes.client.openapi.models.V1PodReadinessGateFluent fluent, + io.kubernetes.client.openapi.models.V1PodReadinessGate instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditionType(instance.getConditionType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PodReadinessGateBuilder(io.kubernetes.client.openapi.models.V1PodReadinessGate instance) { - this(instance,false); + + public V1PodReadinessGateBuilder( + io.kubernetes.client.openapi.models.V1PodReadinessGate instance) { + this(instance, false); } - public V1PodReadinessGateBuilder(io.kubernetes.client.openapi.models.V1PodReadinessGate instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodReadinessGateBuilder( + io.kubernetes.client.openapi.models.V1PodReadinessGate instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditionType(instance.getConditionType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodReadinessGateFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodReadinessGate build() { V1PodReadinessGate buildable = new V1PodReadinessGate(); buildable.setConditionType(fluent.getConditionType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodReadinessGateBuilder that = (V1PodReadinessGateBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodReadinessGateFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodReadinessGateFluent.java index 4b7b6a0165..208a192fad 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodReadinessGateFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodReadinessGateFluent.java @@ -1,16 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public interface V1PodReadinessGateFluent< + A extends io.kubernetes.client.openapi.models.V1PodReadinessGateFluent> + extends io.kubernetes.client.fluent.Fluent { + public io.kubernetes.client.openapi.models.V1PodReadinessGate.ConditionTypeEnum + getConditionType(); + + public A withConditionType( + io.kubernetes.client.openapi.models.V1PodReadinessGate.ConditionTypeEnum conditionType); - /** - * Generated - */ -public interface V1PodReadinessGateFluent> extends io.kubernetes.client.fluent.Fluent{ - public io.kubernetes.client.openapi.models.V1PodReadinessGate.ConditionTypeEnum getConditionType(); - public A withConditionType(io.kubernetes.client.openapi.models.V1PodReadinessGate.ConditionTypeEnum conditionType); public java.lang.Boolean hasConditionType(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodReadinessGateFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodReadinessGateFluentImpl.java index e216280426..ba5d55f930 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodReadinessGateFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodReadinessGateFluentImpl.java @@ -1,38 +1,57 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1PodReadinessGateFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodReadinessGateFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodReadinessGateFluent { + public V1PodReadinessGateFluentImpl() {} - /** - * Generated - */ -public class V1PodReadinessGateFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodReadinessGateFluent{ - public V1PodReadinessGateFluentImpl() { - } - public V1PodReadinessGateFluentImpl(io.kubernetes.client.openapi.models.V1PodReadinessGate instance) { + public V1PodReadinessGateFluentImpl( + io.kubernetes.client.openapi.models.V1PodReadinessGate instance) { this.withConditionType(instance.getConditionType()); - } + private io.kubernetes.client.openapi.models.V1PodReadinessGate.ConditionTypeEnum conditionType; - public io.kubernetes.client.openapi.models.V1PodReadinessGate.ConditionTypeEnum getConditionType() { + + public io.kubernetes.client.openapi.models.V1PodReadinessGate.ConditionTypeEnum + getConditionType() { return this.conditionType; } - public A withConditionType(io.kubernetes.client.openapi.models.V1PodReadinessGate.ConditionTypeEnum conditionType) { - this.conditionType=conditionType; return (A) this; + + public A withConditionType( + io.kubernetes.client.openapi.models.V1PodReadinessGate.ConditionTypeEnum conditionType) { + this.conditionType = conditionType; + return (A) this; } + public java.lang.Boolean hasConditionType() { return this.conditionType != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodReadinessGateFluentImpl that = (V1PodReadinessGateFluentImpl) o; - if (conditionType != null ? !conditionType.equals(that.conditionType) :that.conditionType != null) return false; + if (conditionType != null + ? !conditionType.equals(that.conditionType) + : that.conditionType != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(conditionType, super.hashCode()); + return java.util.Objects.hash(conditionType, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSecurityContextBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSecurityContextBuilder.java index 3976bd67fd..ddfc87c87b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSecurityContextBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSecurityContextBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodSecurityContextBuilder extends io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodSecurityContextBuilder + extends io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl< + io.kubernetes.client.openapi.models.V1PodSecurityContextBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodSecurityContext, + io.kubernetes.client.openapi.models.V1PodSecurityContextBuilder> { public V1PodSecurityContextBuilder() { this(false); } + public V1PodSecurityContextBuilder(java.lang.Boolean validationEnabled) { this(new V1PodSecurityContext(), validationEnabled); } - public V1PodSecurityContextBuilder(io.kubernetes.client.openapi.models.V1PodSecurityContextFluent fluent) { + + public V1PodSecurityContextBuilder( + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent fluent) { this(fluent, false); } - public V1PodSecurityContextBuilder(io.kubernetes.client.openapi.models.V1PodSecurityContextFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodSecurityContextBuilder( + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodSecurityContext(), validationEnabled); } - public V1PodSecurityContextBuilder(io.kubernetes.client.openapi.models.V1PodSecurityContextFluent fluent,io.kubernetes.client.openapi.models.V1PodSecurityContext instance) { + + public V1PodSecurityContextBuilder( + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent fluent, + io.kubernetes.client.openapi.models.V1PodSecurityContext instance) { this(fluent, instance, false); } - public V1PodSecurityContextBuilder(io.kubernetes.client.openapi.models.V1PodSecurityContextFluent fluent,io.kubernetes.client.openapi.models.V1PodSecurityContext instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodSecurityContextBuilder( + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent fluent, + io.kubernetes.client.openapi.models.V1PodSecurityContext instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsGroup(instance.getFsGroup()); fluent.withFsGroupChangePolicy(instance.getFsGroupChangePolicy()); @@ -41,13 +68,18 @@ public V1PodSecurityContextBuilder(io.kubernetes.client.openapi.models.V1PodSecu fluent.withWindowsOptions(instance.getWindowsOptions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PodSecurityContextBuilder(io.kubernetes.client.openapi.models.V1PodSecurityContext instance) { - this(instance,false); + + public V1PodSecurityContextBuilder( + io.kubernetes.client.openapi.models.V1PodSecurityContext instance) { + this(instance, false); } - public V1PodSecurityContextBuilder(io.kubernetes.client.openapi.models.V1PodSecurityContext instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodSecurityContextBuilder( + io.kubernetes.client.openapi.models.V1PodSecurityContext instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsGroup(instance.getFsGroup()); this.withFsGroupChangePolicy(instance.getFsGroupChangePolicy()); @@ -68,10 +100,12 @@ public V1PodSecurityContextBuilder(io.kubernetes.client.openapi.models.V1PodSecu this.withWindowsOptions(instance.getWindowsOptions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodSecurityContext build() { V1PodSecurityContext buildable = new V1PodSecurityContext(); buildable.setFsGroup(fluent.getFsGroup()); @@ -86,18 +120,23 @@ public io.kubernetes.client.openapi.models.V1PodSecurityContext build() { buildable.setWindowsOptions(fluent.getWindowsOptions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodSecurityContextBuilder that = (V1PodSecurityContextBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSecurityContextFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSecurityContextFluent.java index b99074ce8d..0a77cb1af6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSecurityContextFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSecurityContextFluent.java @@ -1,154 +1,281 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.lang.Long; -import java.util.Collection; - - /** - * Generated - */ -public interface V1PodSecurityContextFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PodSecurityContextFluent< + A extends io.kubernetes.client.openapi.models.V1PodSecurityContextFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Long getFsGroup(); + public A withFsGroup(java.lang.Long fsGroup); + public java.lang.Boolean hasFsGroup(); + public java.lang.String getFsGroupChangePolicy(); + public A withFsGroupChangePolicy(java.lang.String fsGroupChangePolicy); + public java.lang.Boolean hasFsGroupChangePolicy(); - - /** - * Method is deprecated. use withFsGroupChangePolicy instead. - */ + + /** Method is deprecated. use withFsGroupChangePolicy instead. */ @java.lang.Deprecated public A withNewFsGroupChangePolicy(java.lang.String original); + public java.lang.Long getRunAsGroup(); + public A withRunAsGroup(java.lang.Long runAsGroup); + public java.lang.Boolean hasRunAsGroup(); + public java.lang.Boolean getRunAsNonRoot(); + public A withRunAsNonRoot(java.lang.Boolean runAsNonRoot); + public java.lang.Boolean hasRunAsNonRoot(); + public java.lang.Long getRunAsUser(); + public A withRunAsUser(java.lang.Long runAsUser); + public java.lang.Boolean hasRunAsUser(); - + /** * This method has been deprecated, please use method buildSeLinuxOptions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SELinuxOptions getSeLinuxOptions(); + public io.kubernetes.client.openapi.models.V1SELinuxOptions buildSeLinuxOptions(); + public A withSeLinuxOptions(io.kubernetes.client.openapi.models.V1SELinuxOptions seLinuxOptions); + public java.lang.Boolean hasSeLinuxOptions(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested withNewSeLinuxOptions(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested withNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested editSeLinuxOptions(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested editOrNewSeLinuxOptions(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested editOrNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item); - + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested + withNewSeLinuxOptions(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested + withNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested + editSeLinuxOptions(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested + editOrNewSeLinuxOptions(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested + editOrNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item); + /** * This method has been deprecated, please use method buildSeccompProfile instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SeccompProfile getSeccompProfile(); + public io.kubernetes.client.openapi.models.V1SeccompProfile buildSeccompProfile(); + public A withSeccompProfile(io.kubernetes.client.openapi.models.V1SeccompProfile seccompProfile); + public java.lang.Boolean hasSeccompProfile(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested withNewSeccompProfile(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested withNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested editSeccompProfile(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested editOrNewSeccompProfile(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested editOrNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item); - public A addToSupplementalGroups(java.lang.Integer index,java.lang.Long item); - public A setToSupplementalGroups(java.lang.Integer index,java.lang.Long item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested + withNewSeccompProfile(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested + withNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested + editSeccompProfile(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested + editOrNewSeccompProfile(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested + editOrNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item); + + public A addToSupplementalGroups(java.lang.Integer index, java.lang.Long item); + + public A setToSupplementalGroups(java.lang.Integer index, java.lang.Long item); + public A addToSupplementalGroups(java.lang.Long... items); + public A addAllToSupplementalGroups(java.util.Collection items); + public A removeFromSupplementalGroups(java.lang.Long... items); + public A removeAllFromSupplementalGroups(java.util.Collection items); + public java.util.List getSupplementalGroups(); + public java.lang.Long getSupplementalGroup(java.lang.Integer index); + public java.lang.Long getFirstSupplementalGroup(); + public java.lang.Long getLastSupplementalGroup(); - public java.lang.Long getMatchingSupplementalGroup(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingSupplementalGroup(java.util.function.Predicate predicate); + + public java.lang.Long getMatchingSupplementalGroup( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingSupplementalGroup( + java.util.function.Predicate predicate); + public A withSupplementalGroups(java.util.List supplementalGroups); + public A withSupplementalGroups(java.lang.Long... supplementalGroups); + public java.lang.Boolean hasSupplementalGroups(); - public A addToSysctls(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Sysctl item); - public A setToSysctls(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Sysctl item); + + public A addToSysctls(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Sysctl item); + + public A setToSysctls(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Sysctl item); + public A addToSysctls(io.kubernetes.client.openapi.models.V1Sysctl... items); - public A addAllToSysctls(java.util.Collection items); + + public A addAllToSysctls( + java.util.Collection items); + public A removeFromSysctls(io.kubernetes.client.openapi.models.V1Sysctl... items); - public A removeAllFromSysctls(java.util.Collection items); - public A removeMatchingFromSysctls(java.util.function.Predicate predicate); - + + public A removeAllFromSysctls( + java.util.Collection items); + + public A removeMatchingFromSysctls( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildSysctls instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getSysctls(); + public java.util.List buildSysctls(); + public io.kubernetes.client.openapi.models.V1Sysctl buildSysctl(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Sysctl buildFirstSysctl(); + public io.kubernetes.client.openapi.models.V1Sysctl buildLastSysctl(); - public io.kubernetes.client.openapi.models.V1Sysctl buildMatchingSysctl(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingSysctl(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Sysctl buildMatchingSysctl( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingSysctl( + java.util.function.Predicate predicate); + public A withSysctls(java.util.List sysctls); + public A withSysctls(io.kubernetes.client.openapi.models.V1Sysctl... sysctls); + public java.lang.Boolean hasSysctls(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested addNewSysctl(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested addNewSysctlLike(io.kubernetes.client.openapi.models.V1Sysctl item); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested setNewSysctlLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Sysctl item); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested editSysctl(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested editFirstSysctl(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested editLastSysctl(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested editMatchingSysctl(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested + addNewSysctl(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested + addNewSysctlLike(io.kubernetes.client.openapi.models.V1Sysctl item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested + setNewSysctlLike(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Sysctl item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested editSysctl( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested + editFirstSysctl(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested + editLastSysctl(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested + editMatchingSysctl( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildWindowsOptions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions getWindowsOptions(); + public io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions buildWindowsOptions(); - public A withWindowsOptions(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions windowsOptions); + + public A withWindowsOptions( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions windowsOptions); + public java.lang.Boolean hasWindowsOptions(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested withNewWindowsOptions(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested withNewWindowsOptionsLike(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested editWindowsOptions(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested editOrNewWindowsOptions(); - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested editOrNewWindowsOptionsLike(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item); - public interface SeLinuxOptionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent>{ + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested + withNewWindowsOptions(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested + withNewWindowsOptionsLike( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested + editWindowsOptions(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested + editOrNewWindowsOptions(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested + editOrNewWindowsOptionsLike( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item); + + public interface SeLinuxOptionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent< + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested< + N>> { public N and(); + public N endSeLinuxOptions(); - } - public interface SeccompProfileNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SeccompProfileFluent>{ + + public interface SeccompProfileNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SeccompProfileFluent< + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested< + N>> { public N and(); + public N endSeccompProfile(); - } - public interface SysctlsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SysctlFluent>{ + + public interface SysctlsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SysctlFluent< + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested> { public N and(); + public N endSysctl(); - } - public interface WindowsOptionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent>{ + + public interface WindowsOptionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent< + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested< + N>> { public N and(); + public N endWindowsOptions(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSecurityContextFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSecurityContextFluentImpl.java index b80fd2cc91..1aacd51902 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSecurityContextFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSecurityContextFluentImpl.java @@ -1,27 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.lang.Long; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1PodSecurityContextFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodSecurityContextFluent{ - public V1PodSecurityContextFluentImpl() { - } - public V1PodSecurityContextFluentImpl(io.kubernetes.client.openapi.models.V1PodSecurityContext instance) { + +/** Generated */ +public class V1PodSecurityContextFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodSecurityContextFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodSecurityContextFluent { + public V1PodSecurityContextFluentImpl() {} + + public V1PodSecurityContextFluentImpl( + io.kubernetes.client.openapi.models.V1PodSecurityContext instance) { this.withFsGroup(instance.getFsGroup()); this.withFsGroupChangePolicy(instance.getFsGroupChangePolicy()); @@ -41,8 +43,8 @@ public V1PodSecurityContextFluentImpl(io.kubernetes.client.openapi.models.V1PodS this.withSysctls(instance.getSysctls()); this.withWindowsOptions(instance.getWindowsOptions()); - } + private java.lang.Long fsGroup; private java.lang.String fsGroupChangePolicy; private java.lang.Long runAsGroup; @@ -53,204 +55,398 @@ public V1PodSecurityContextFluentImpl(io.kubernetes.client.openapi.models.V1PodS private java.util.List supplementalGroups; private java.util.ArrayList sysctls; private io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder windowsOptions; + public java.lang.Long getFsGroup() { return this.fsGroup; } + public A withFsGroup(java.lang.Long fsGroup) { - this.fsGroup=fsGroup; return (A) this; + this.fsGroup = fsGroup; + return (A) this; } + public java.lang.Boolean hasFsGroup() { return this.fsGroup != null; } + public java.lang.String getFsGroupChangePolicy() { return this.fsGroupChangePolicy; } + public A withFsGroupChangePolicy(java.lang.String fsGroupChangePolicy) { - this.fsGroupChangePolicy=fsGroupChangePolicy; return (A) this; + this.fsGroupChangePolicy = fsGroupChangePolicy; + return (A) this; } + public java.lang.Boolean hasFsGroupChangePolicy() { return this.fsGroupChangePolicy != null; } - - /** - * Method is deprecated. use withFsGroupChangePolicy instead. - */ + + /** Method is deprecated. use withFsGroupChangePolicy instead. */ @java.lang.Deprecated public A withNewFsGroupChangePolicy(java.lang.String original) { - return (A)withFsGroupChangePolicy(new String(original)); + return (A) withFsGroupChangePolicy(new String(original)); } + public java.lang.Long getRunAsGroup() { return this.runAsGroup; } + public A withRunAsGroup(java.lang.Long runAsGroup) { - this.runAsGroup=runAsGroup; return (A) this; + this.runAsGroup = runAsGroup; + return (A) this; } + public java.lang.Boolean hasRunAsGroup() { return this.runAsGroup != null; } + public java.lang.Boolean getRunAsNonRoot() { return this.runAsNonRoot; } + public A withRunAsNonRoot(java.lang.Boolean runAsNonRoot) { - this.runAsNonRoot=runAsNonRoot; return (A) this; + this.runAsNonRoot = runAsNonRoot; + return (A) this; } + public java.lang.Boolean hasRunAsNonRoot() { return this.runAsNonRoot != null; } + public java.lang.Long getRunAsUser() { return this.runAsUser; } + public A withRunAsUser(java.lang.Long runAsUser) { - this.runAsUser=runAsUser; return (A) this; + this.runAsUser = runAsUser; + return (A) this; } + public java.lang.Boolean hasRunAsUser() { return this.runAsUser != null; } - + /** * This method has been deprecated, please use method buildSeLinuxOptions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SELinuxOptions getSeLinuxOptions() { - return this.seLinuxOptions!=null ?this.seLinuxOptions.build():null; + return this.seLinuxOptions != null ? this.seLinuxOptions.build() : null; } + public io.kubernetes.client.openapi.models.V1SELinuxOptions buildSeLinuxOptions() { - return this.seLinuxOptions!=null ?this.seLinuxOptions.build():null; + return this.seLinuxOptions != null ? this.seLinuxOptions.build() : null; } + public A withSeLinuxOptions(io.kubernetes.client.openapi.models.V1SELinuxOptions seLinuxOptions) { _visitables.get("seLinuxOptions").remove(this.seLinuxOptions); - if (seLinuxOptions!=null){ this.seLinuxOptions= new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder(seLinuxOptions); _visitables.get("seLinuxOptions").add(this.seLinuxOptions);} return (A) this; + if (seLinuxOptions != null) { + this.seLinuxOptions = + new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder(seLinuxOptions); + _visitables.get("seLinuxOptions").add(this.seLinuxOptions); + } + return (A) this; } + public java.lang.Boolean hasSeLinuxOptions() { return this.seLinuxOptions != null; } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested withNewSeLinuxOptions() { - return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl.SeLinuxOptionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested + withNewSeLinuxOptions() { + return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl + .SeLinuxOptionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested withNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { - return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl.SeLinuxOptionsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested + withNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { + return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl + .SeLinuxOptionsNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested editSeLinuxOptions() { + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested + editSeLinuxOptions() { return withNewSeLinuxOptionsLike(getSeLinuxOptions()); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested editOrNewSeLinuxOptions() { - return withNewSeLinuxOptionsLike(getSeLinuxOptions() != null ? getSeLinuxOptions(): new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested + editOrNewSeLinuxOptions() { + return withNewSeLinuxOptionsLike( + getSeLinuxOptions() != null + ? getSeLinuxOptions() + : new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested editOrNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { - return withNewSeLinuxOptionsLike(getSeLinuxOptions() != null ? getSeLinuxOptions(): item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested + editOrNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { + return withNewSeLinuxOptionsLike(getSeLinuxOptions() != null ? getSeLinuxOptions() : item); } - + /** * This method has been deprecated, please use method buildSeccompProfile instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SeccompProfile getSeccompProfile() { - return this.seccompProfile!=null ?this.seccompProfile.build():null; + return this.seccompProfile != null ? this.seccompProfile.build() : null; } + public io.kubernetes.client.openapi.models.V1SeccompProfile buildSeccompProfile() { - return this.seccompProfile!=null ?this.seccompProfile.build():null; + return this.seccompProfile != null ? this.seccompProfile.build() : null; } + public A withSeccompProfile(io.kubernetes.client.openapi.models.V1SeccompProfile seccompProfile) { _visitables.get("seccompProfile").remove(this.seccompProfile); - if (seccompProfile!=null){ this.seccompProfile= new io.kubernetes.client.openapi.models.V1SeccompProfileBuilder(seccompProfile); _visitables.get("seccompProfile").add(this.seccompProfile);} return (A) this; + if (seccompProfile != null) { + this.seccompProfile = + new io.kubernetes.client.openapi.models.V1SeccompProfileBuilder(seccompProfile); + _visitables.get("seccompProfile").add(this.seccompProfile); + } + return (A) this; } + public java.lang.Boolean hasSeccompProfile() { return this.seccompProfile != null; } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested withNewSeccompProfile() { - return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl.SeccompProfileNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested + withNewSeccompProfile() { + return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl + .SeccompProfileNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested withNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item) { - return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl.SeccompProfileNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested + withNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item) { + return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl + .SeccompProfileNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested editSeccompProfile() { + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested + editSeccompProfile() { return withNewSeccompProfileLike(getSeccompProfile()); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested editOrNewSeccompProfile() { - return withNewSeccompProfileLike(getSeccompProfile() != null ? getSeccompProfile(): new io.kubernetes.client.openapi.models.V1SeccompProfileBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested + editOrNewSeccompProfile() { + return withNewSeccompProfileLike( + getSeccompProfile() != null + ? getSeccompProfile() + : new io.kubernetes.client.openapi.models.V1SeccompProfileBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested editOrNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item) { - return withNewSeccompProfileLike(getSeccompProfile() != null ? getSeccompProfile(): item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested + editOrNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item) { + return withNewSeccompProfileLike(getSeccompProfile() != null ? getSeccompProfile() : item); } - public A addToSupplementalGroups(java.lang.Integer index,java.lang.Long item) { - if (this.supplementalGroups == null) {this.supplementalGroups = new java.util.ArrayList();} + + public A addToSupplementalGroups(java.lang.Integer index, java.lang.Long item) { + if (this.supplementalGroups == null) { + this.supplementalGroups = new java.util.ArrayList(); + } this.supplementalGroups.add(index, item); - return (A)this; + return (A) this; } - public A setToSupplementalGroups(java.lang.Integer index,java.lang.Long item) { - if (this.supplementalGroups == null) {this.supplementalGroups = new java.util.ArrayList();} - this.supplementalGroups.set(index, item); return (A)this; + + public A setToSupplementalGroups(java.lang.Integer index, java.lang.Long item) { + if (this.supplementalGroups == null) { + this.supplementalGroups = new java.util.ArrayList(); + } + this.supplementalGroups.set(index, item); + return (A) this; } + public A addToSupplementalGroups(java.lang.Long... items) { - if (this.supplementalGroups == null) {this.supplementalGroups = new java.util.ArrayList();} - for (java.lang.Long item : items) {this.supplementalGroups.add(item);} return (A)this; + if (this.supplementalGroups == null) { + this.supplementalGroups = new java.util.ArrayList(); + } + for (java.lang.Long item : items) { + this.supplementalGroups.add(item); + } + return (A) this; } + public A addAllToSupplementalGroups(java.util.Collection items) { - if (this.supplementalGroups == null) {this.supplementalGroups = new java.util.ArrayList();} - for (java.lang.Long item : items) {this.supplementalGroups.add(item);} return (A)this; + if (this.supplementalGroups == null) { + this.supplementalGroups = new java.util.ArrayList(); + } + for (java.lang.Long item : items) { + this.supplementalGroups.add(item); + } + return (A) this; } + public A removeFromSupplementalGroups(java.lang.Long... items) { - for (java.lang.Long item : items) {if (this.supplementalGroups!= null){ this.supplementalGroups.remove(item);}} return (A)this; + for (java.lang.Long item : items) { + if (this.supplementalGroups != null) { + this.supplementalGroups.remove(item); + } + } + return (A) this; } + public A removeAllFromSupplementalGroups(java.util.Collection items) { - for (java.lang.Long item : items) {if (this.supplementalGroups!= null){ this.supplementalGroups.remove(item);}} return (A)this; + for (java.lang.Long item : items) { + if (this.supplementalGroups != null) { + this.supplementalGroups.remove(item); + } + } + return (A) this; } + public java.util.List getSupplementalGroups() { return this.supplementalGroups; } + public java.lang.Long getSupplementalGroup(java.lang.Integer index) { return this.supplementalGroups.get(index); } + public java.lang.Long getFirstSupplementalGroup() { return this.supplementalGroups.get(0); } + public java.lang.Long getLastSupplementalGroup() { return this.supplementalGroups.get(supplementalGroups.size() - 1); } - public java.lang.Long getMatchingSupplementalGroup(java.util.function.Predicate predicate) { - for (java.lang.Long item: supplementalGroups) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.Long getMatchingSupplementalGroup( + java.util.function.Predicate predicate) { + for (java.lang.Long item : supplementalGroups) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingSupplementalGroup(java.util.function.Predicate predicate) { - for (java.lang.Long item: supplementalGroups) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingSupplementalGroup( + java.util.function.Predicate predicate) { + for (java.lang.Long item : supplementalGroups) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withSupplementalGroups(java.util.List supplementalGroups) { - if (supplementalGroups != null) {this.supplementalGroups = new java.util.ArrayList(); for (java.lang.Long item : supplementalGroups){this.addToSupplementalGroups(item);}} else { this.supplementalGroups = null;} return (A) this; + if (supplementalGroups != null) { + this.supplementalGroups = new java.util.ArrayList(); + for (java.lang.Long item : supplementalGroups) { + this.addToSupplementalGroups(item); + } + } else { + this.supplementalGroups = null; + } + return (A) this; } + public A withSupplementalGroups(java.lang.Long... supplementalGroups) { - if (this.supplementalGroups != null) {this.supplementalGroups.clear();} - if (supplementalGroups != null) {for (java.lang.Long item :supplementalGroups){ this.addToSupplementalGroups(item);}} return (A) this; + if (this.supplementalGroups != null) { + this.supplementalGroups.clear(); + } + if (supplementalGroups != null) { + for (java.lang.Long item : supplementalGroups) { + this.addToSupplementalGroups(item); + } + } + return (A) this; } + public java.lang.Boolean hasSupplementalGroups() { return supplementalGroups != null && !supplementalGroups.isEmpty(); } - public A addToSysctls(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Sysctl item) { - if (this.sysctls == null) {this.sysctls = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1SysctlBuilder builder = new io.kubernetes.client.openapi.models.V1SysctlBuilder(item);_visitables.get("sysctls").add(index >= 0 ? index : _visitables.get("sysctls").size(), builder);this.sysctls.add(index >= 0 ? index : sysctls.size(), builder); return (A)this; + + public A addToSysctls( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Sysctl item) { + if (this.sysctls == null) { + this.sysctls = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1SysctlBuilder builder = + new io.kubernetes.client.openapi.models.V1SysctlBuilder(item); + _visitables.get("sysctls").add(index >= 0 ? index : _visitables.get("sysctls").size(), builder); + this.sysctls.add(index >= 0 ? index : sysctls.size(), builder); + return (A) this; } - public A setToSysctls(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Sysctl item) { - if (this.sysctls == null) {this.sysctls = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1SysctlBuilder builder = new io.kubernetes.client.openapi.models.V1SysctlBuilder(item); - if (index < 0 || index >= _visitables.get("sysctls").size()) { _visitables.get("sysctls").add(builder); } else { _visitables.get("sysctls").set(index, builder);} - if (index < 0 || index >= sysctls.size()) { sysctls.add(builder); } else { sysctls.set(index, builder);} - return (A)this; + + public A setToSysctls( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Sysctl item) { + if (this.sysctls == null) { + this.sysctls = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1SysctlBuilder builder = + new io.kubernetes.client.openapi.models.V1SysctlBuilder(item); + if (index < 0 || index >= _visitables.get("sysctls").size()) { + _visitables.get("sysctls").add(builder); + } else { + _visitables.get("sysctls").set(index, builder); + } + if (index < 0 || index >= sysctls.size()) { + sysctls.add(builder); + } else { + sysctls.set(index, builder); + } + return (A) this; } + public A addToSysctls(io.kubernetes.client.openapi.models.V1Sysctl... items) { - if (this.sysctls == null) {this.sysctls = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Sysctl item : items) {io.kubernetes.client.openapi.models.V1SysctlBuilder builder = new io.kubernetes.client.openapi.models.V1SysctlBuilder(item);_visitables.get("sysctls").add(builder);this.sysctls.add(builder);} return (A)this; + if (this.sysctls == null) { + this.sysctls = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Sysctl item : items) { + io.kubernetes.client.openapi.models.V1SysctlBuilder builder = + new io.kubernetes.client.openapi.models.V1SysctlBuilder(item); + _visitables.get("sysctls").add(builder); + this.sysctls.add(builder); + } + return (A) this; } - public A addAllToSysctls(java.util.Collection items) { - if (this.sysctls == null) {this.sysctls = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Sysctl item : items) {io.kubernetes.client.openapi.models.V1SysctlBuilder builder = new io.kubernetes.client.openapi.models.V1SysctlBuilder(item);_visitables.get("sysctls").add(builder);this.sysctls.add(builder);} return (A)this; + + public A addAllToSysctls( + java.util.Collection items) { + if (this.sysctls == null) { + this.sysctls = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Sysctl item : items) { + io.kubernetes.client.openapi.models.V1SysctlBuilder builder = + new io.kubernetes.client.openapi.models.V1SysctlBuilder(item); + _visitables.get("sysctls").add(builder); + this.sysctls.add(builder); + } + return (A) this; } + public A removeFromSysctls(io.kubernetes.client.openapi.models.V1Sysctl... items) { - for (io.kubernetes.client.openapi.models.V1Sysctl item : items) {io.kubernetes.client.openapi.models.V1SysctlBuilder builder = new io.kubernetes.client.openapi.models.V1SysctlBuilder(item);_visitables.get("sysctls").remove(builder);if (this.sysctls != null) {this.sysctls.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Sysctl item : items) { + io.kubernetes.client.openapi.models.V1SysctlBuilder builder = + new io.kubernetes.client.openapi.models.V1SysctlBuilder(item); + _visitables.get("sysctls").remove(builder); + if (this.sysctls != null) { + this.sysctls.remove(builder); + } + } + return (A) this; } - public A removeAllFromSysctls(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Sysctl item : items) {io.kubernetes.client.openapi.models.V1SysctlBuilder builder = new io.kubernetes.client.openapi.models.V1SysctlBuilder(item);_visitables.get("sysctls").remove(builder);if (this.sysctls != null) {this.sysctls.remove(builder);}} return (A)this; + + public A removeAllFromSysctls( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Sysctl item : items) { + io.kubernetes.client.openapi.models.V1SysctlBuilder builder = + new io.kubernetes.client.openapi.models.V1SysctlBuilder(item); + _visitables.get("sysctls").remove(builder); + if (this.sysctls != null) { + this.sysctls.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromSysctls(java.util.function.Predicate predicate) { + + public A removeMatchingFromSysctls( + java.util.function.Predicate predicate) { if (sysctls == null) return (A) this; final Iterator each = sysctls.iterator(); final List visitables = _visitables.get("sysctls"); @@ -261,195 +457,354 @@ public A removeMatchingFromSysctls(java.util.function.Predicate getSysctls() { return sysctls != null ? build(sysctls) : null; } + public java.util.List buildSysctls() { return sysctls != null ? build(sysctls) : null; } + public io.kubernetes.client.openapi.models.V1Sysctl buildSysctl(java.lang.Integer index) { return this.sysctls.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Sysctl buildFirstSysctl() { return this.sysctls.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Sysctl buildLastSysctl() { return this.sysctls.get(sysctls.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Sysctl buildMatchingSysctl(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1SysctlBuilder item: sysctls) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Sysctl buildMatchingSysctl( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1SysctlBuilder item : sysctls) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingSysctl(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1SysctlBuilder item: sysctls) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingSysctl( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1SysctlBuilder item : sysctls) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withSysctls(java.util.List sysctls) { - if (this.sysctls != null) { _visitables.get("sysctls").removeAll(this.sysctls);} - if (sysctls != null) {this.sysctls = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Sysctl item : sysctls){this.addToSysctls(item);}} else { this.sysctls = null;} return (A) this; + if (this.sysctls != null) { + _visitables.get("sysctls").removeAll(this.sysctls); + } + if (sysctls != null) { + this.sysctls = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Sysctl item : sysctls) { + this.addToSysctls(item); + } + } else { + this.sysctls = null; + } + return (A) this; } + public A withSysctls(io.kubernetes.client.openapi.models.V1Sysctl... sysctls) { - if (this.sysctls != null) {this.sysctls.clear();} - if (sysctls != null) {for (io.kubernetes.client.openapi.models.V1Sysctl item :sysctls){ this.addToSysctls(item);}} return (A) this; + if (this.sysctls != null) { + this.sysctls.clear(); + } + if (sysctls != null) { + for (io.kubernetes.client.openapi.models.V1Sysctl item : sysctls) { + this.addToSysctls(item); + } + } + return (A) this; } + public java.lang.Boolean hasSysctls() { return sysctls != null && !sysctls.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested addNewSysctl() { - return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl.SysctlsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested + addNewSysctl() { + return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl + .SysctlsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested addNewSysctlLike(io.kubernetes.client.openapi.models.V1Sysctl item) { - return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl.SysctlsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested + addNewSysctlLike(io.kubernetes.client.openapi.models.V1Sysctl item) { + return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl.SysctlsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested setNewSysctlLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Sysctl item) { - return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl.SysctlsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested + setNewSysctlLike(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Sysctl item) { + return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl.SysctlsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested editSysctl(java.lang.Integer index) { - if (sysctls.size() <= index) throw new RuntimeException("Can't edit sysctls. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested editSysctl( + java.lang.Integer index) { + if (sysctls.size() <= index) + throw new RuntimeException("Can't edit sysctls. Index exceeds size."); return setNewSysctlLike(index, buildSysctl(index)); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested editFirstSysctl() { - if (sysctls.size() == 0) throw new RuntimeException("Can't edit first sysctls. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested + editFirstSysctl() { + if (sysctls.size() == 0) + throw new RuntimeException("Can't edit first sysctls. The list is empty."); return setNewSysctlLike(0, buildSysctl(0)); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested editLastSysctl() { + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested + editLastSysctl() { int index = sysctls.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last sysctls. The list is empty."); return setNewSysctlLike(index, buildSysctl(index)); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested editMatchingSysctl(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested + editMatchingSysctl( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewWindowsOptions() { - return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl.WindowsOptionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested + withNewWindowsOptions() { + return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl + .WindowsOptionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested withNewWindowsOptionsLike(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item) { - return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl.WindowsOptionsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested + withNewWindowsOptionsLike( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item) { + return new io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl + .WindowsOptionsNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested editWindowsOptions() { + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested + editWindowsOptions() { return withNewWindowsOptionsLike(getWindowsOptions()); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested editOrNewWindowsOptions() { - return withNewWindowsOptionsLike(getWindowsOptions() != null ? getWindowsOptions(): new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested + editOrNewWindowsOptions() { + return withNewWindowsOptionsLike( + getWindowsOptions() != null + ? getWindowsOptions() + : new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested editOrNewWindowsOptionsLike(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item) { - return withNewWindowsOptionsLike(getWindowsOptions() != null ? getWindowsOptions(): item); + + public io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested + editOrNewWindowsOptionsLike( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item) { + return withNewWindowsOptionsLike(getWindowsOptions() != null ? getWindowsOptions() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodSecurityContextFluentImpl that = (V1PodSecurityContextFluentImpl) o; - if (fsGroup != null ? !fsGroup.equals(that.fsGroup) :that.fsGroup != null) return false; - if (fsGroupChangePolicy != null ? !fsGroupChangePolicy.equals(that.fsGroupChangePolicy) :that.fsGroupChangePolicy != null) return false; - if (runAsGroup != null ? !runAsGroup.equals(that.runAsGroup) :that.runAsGroup != null) return false; - if (runAsNonRoot != null ? !runAsNonRoot.equals(that.runAsNonRoot) :that.runAsNonRoot != null) return false; - if (runAsUser != null ? !runAsUser.equals(that.runAsUser) :that.runAsUser != null) return false; - if (seLinuxOptions != null ? !seLinuxOptions.equals(that.seLinuxOptions) :that.seLinuxOptions != null) return false; - if (seccompProfile != null ? !seccompProfile.equals(that.seccompProfile) :that.seccompProfile != null) return false; - if (supplementalGroups != null ? !supplementalGroups.equals(that.supplementalGroups) :that.supplementalGroups != null) return false; - if (sysctls != null ? !sysctls.equals(that.sysctls) :that.sysctls != null) return false; - if (windowsOptions != null ? !windowsOptions.equals(that.windowsOptions) :that.windowsOptions != null) return false; + if (fsGroup != null ? !fsGroup.equals(that.fsGroup) : that.fsGroup != null) return false; + if (fsGroupChangePolicy != null + ? !fsGroupChangePolicy.equals(that.fsGroupChangePolicy) + : that.fsGroupChangePolicy != null) return false; + if (runAsGroup != null ? !runAsGroup.equals(that.runAsGroup) : that.runAsGroup != null) + return false; + if (runAsNonRoot != null ? !runAsNonRoot.equals(that.runAsNonRoot) : that.runAsNonRoot != null) + return false; + if (runAsUser != null ? !runAsUser.equals(that.runAsUser) : that.runAsUser != null) + return false; + if (seLinuxOptions != null + ? !seLinuxOptions.equals(that.seLinuxOptions) + : that.seLinuxOptions != null) return false; + if (seccompProfile != null + ? !seccompProfile.equals(that.seccompProfile) + : that.seccompProfile != null) return false; + if (supplementalGroups != null + ? !supplementalGroups.equals(that.supplementalGroups) + : that.supplementalGroups != null) return false; + if (sysctls != null ? !sysctls.equals(that.sysctls) : that.sysctls != null) return false; + if (windowsOptions != null + ? !windowsOptions.equals(that.windowsOptions) + : that.windowsOptions != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsGroup, fsGroupChangePolicy, runAsGroup, runAsNonRoot, runAsUser, seLinuxOptions, seccompProfile, supplementalGroups, sysctls, windowsOptions, super.hashCode()); + return java.util.Objects.hash( + fsGroup, + fsGroupChangePolicy, + runAsGroup, + runAsNonRoot, + runAsUser, + seLinuxOptions, + seccompProfile, + supplementalGroups, + sysctls, + windowsOptions, + super.hashCode()); } - public class SeLinuxOptionsNestedImpl extends io.kubernetes.client.openapi.models.V1SELinuxOptionsFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested,io.kubernetes.client.fluent.Nested{ + + public class SeLinuxOptionsNestedImpl + extends io.kubernetes.client.openapi.models.V1SELinuxOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeLinuxOptionsNested> + implements io.kubernetes.client.openapi.models.V1PodSecurityContextFluent + .SeLinuxOptionsNested< + N>, + io.kubernetes.client.fluent.Nested { SeLinuxOptionsNestedImpl(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { this.builder = new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder(this, item); } + SeLinuxOptionsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder(this); } + io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder builder; + public N and() { return (N) V1PodSecurityContextFluentImpl.this.withSeLinuxOptions(builder.build()); } + public N endSeLinuxOptions() { return and(); } - } - public class SeccompProfileNestedImpl extends io.kubernetes.client.openapi.models.V1SeccompProfileFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested,io.kubernetes.client.fluent.Nested{ + + public class SeccompProfileNestedImpl + extends io.kubernetes.client.openapi.models.V1SeccompProfileFluentImpl< + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SeccompProfileNested> + implements io.kubernetes.client.openapi.models.V1PodSecurityContextFluent + .SeccompProfileNested< + N>, + io.kubernetes.client.fluent.Nested { SeccompProfileNestedImpl(io.kubernetes.client.openapi.models.V1SeccompProfile item) { this.builder = new io.kubernetes.client.openapi.models.V1SeccompProfileBuilder(this, item); } + SeccompProfileNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SeccompProfileBuilder(this); } + io.kubernetes.client.openapi.models.V1SeccompProfileBuilder builder; + public N and() { return (N) V1PodSecurityContextFluentImpl.this.withSeccompProfile(builder.build()); } + public N endSeccompProfile() { return and(); } - } - public class SysctlsNestedImpl extends io.kubernetes.client.openapi.models.V1SysctlFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested,io.kubernetes.client.fluent.Nested{ - SysctlsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Sysctl item) { + + public class SysctlsNestedImpl + extends io.kubernetes.client.openapi.models.V1SysctlFluentImpl< + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested> + implements io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.SysctlsNested, + io.kubernetes.client.fluent.Nested { + SysctlsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Sysctl item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1SysctlBuilder(this, item); } + SysctlsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1SysctlBuilder(this); } + io.kubernetes.client.openapi.models.V1SysctlBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodSecurityContextFluentImpl.this.setToSysctls(index,builder.build()); + return (N) V1PodSecurityContextFluentImpl.this.setToSysctls(index, builder.build()); } + public N endSysctl() { return and(); } - } - public class WindowsOptionsNestedImpl extends io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested,io.kubernetes.client.fluent.Nested{ - WindowsOptionsNestedImpl(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item) { - this.builder = new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder(this, item); + + public class WindowsOptionsNestedImpl + extends io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent.WindowsOptionsNested> + implements io.kubernetes.client.openapi.models.V1PodSecurityContextFluent + .WindowsOptionsNested< + N>, + io.kubernetes.client.fluent.Nested { + WindowsOptionsNestedImpl( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item) { + this.builder = + new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder( + this, item); } + WindowsOptionsNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder(this); } + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder builder; + public N and() { return (N) V1PodSecurityContextFluentImpl.this.withWindowsOptions(builder.build()); } + public N endWindowsOptions() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSpecBuilder.java index 223925bc24..b60f006e19 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSpecBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodSpecBuilder extends io.kubernetes.client.openapi.models.V1PodSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodSpecBuilder + extends io.kubernetes.client.openapi.models.V1PodSpecFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodSpec, + io.kubernetes.client.openapi.models.V1PodSpecBuilder> { public V1PodSpecBuilder() { this(false); } + public V1PodSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1PodSpec(), validationEnabled); } + public V1PodSpecBuilder(io.kubernetes.client.openapi.models.V1PodSpecFluent fluent) { this(fluent, false); } - public V1PodSpecBuilder(io.kubernetes.client.openapi.models.V1PodSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodSpecBuilder( + io.kubernetes.client.openapi.models.V1PodSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodSpec(), validationEnabled); } - public V1PodSpecBuilder(io.kubernetes.client.openapi.models.V1PodSpecFluent fluent,io.kubernetes.client.openapi.models.V1PodSpec instance) { + + public V1PodSpecBuilder( + io.kubernetes.client.openapi.models.V1PodSpecFluent fluent, + io.kubernetes.client.openapi.models.V1PodSpec instance) { this(fluent, instance, false); } - public V1PodSpecBuilder(io.kubernetes.client.openapi.models.V1PodSpecFluent fluent,io.kubernetes.client.openapi.models.V1PodSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodSpecBuilder( + io.kubernetes.client.openapi.models.V1PodSpecFluent fluent, + io.kubernetes.client.openapi.models.V1PodSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withActiveDeadlineSeconds(instance.getActiveDeadlineSeconds()); fluent.withAffinity(instance.getAffinity()); @@ -93,13 +119,16 @@ public V1PodSpecBuilder(io.kubernetes.client.openapi.models.V1PodSpecFluent f fluent.withVolumes(instance.getVolumes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodSpecBuilder(io.kubernetes.client.openapi.models.V1PodSpec instance) { - this(instance,false); + this(instance, false); } - public V1PodSpecBuilder(io.kubernetes.client.openapi.models.V1PodSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodSpecBuilder( + io.kubernetes.client.openapi.models.V1PodSpec instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withActiveDeadlineSeconds(instance.getActiveDeadlineSeconds()); this.withAffinity(instance.getAffinity()); @@ -172,10 +201,12 @@ public V1PodSpecBuilder(io.kubernetes.client.openapi.models.V1PodSpec instance,j this.withVolumes(instance.getVolumes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodSpec build() { V1PodSpec buildable = new V1PodSpec(); buildable.setActiveDeadlineSeconds(fluent.getActiveDeadlineSeconds()); @@ -216,18 +247,23 @@ public io.kubernetes.client.openapi.models.V1PodSpec build() { buildable.setVolumes(fluent.getVolumes()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodSpecBuilder that = (V1PodSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSpecFluent.java index b6efdf7e3d..76c232b343 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSpecFluent.java @@ -1,552 +1,1137 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Long; -import java.util.Collection; -import java.util.Map; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import java.util.Iterator; -import io.kubernetes.client.custom.Quantity; -import java.lang.Integer; - - /** - * Generated - */ -public interface V1PodSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PodSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Long getActiveDeadlineSeconds(); + public A withActiveDeadlineSeconds(java.lang.Long activeDeadlineSeconds); + public java.lang.Boolean hasActiveDeadlineSeconds(); - + /** * This method has been deprecated, please use method buildAffinity instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Affinity getAffinity(); + public io.kubernetes.client.openapi.models.V1Affinity buildAffinity(); + public A withAffinity(io.kubernetes.client.openapi.models.V1Affinity affinity); + public java.lang.Boolean hasAffinity(); + public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested withNewAffinity(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested withNewAffinityLike(io.kubernetes.client.openapi.models.V1Affinity item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested withNewAffinityLike( + io.kubernetes.client.openapi.models.V1Affinity item); + public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested editAffinity(); + public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested editOrNewAffinity(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested editOrNewAffinityLike(io.kubernetes.client.openapi.models.V1Affinity item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested + editOrNewAffinityLike(io.kubernetes.client.openapi.models.V1Affinity item); + public java.lang.Boolean getAutomountServiceAccountToken(); + public A withAutomountServiceAccountToken(java.lang.Boolean automountServiceAccountToken); + public java.lang.Boolean hasAutomountServiceAccountToken(); - public A addToContainers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Container item); - public A setToContainers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Container item); + + public A addToContainers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item); + + public A setToContainers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item); + public A addToContainers(io.kubernetes.client.openapi.models.V1Container... items); - public A addAllToContainers(java.util.Collection items); + + public A addAllToContainers( + java.util.Collection items); + public A removeFromContainers(io.kubernetes.client.openapi.models.V1Container... items); - public A removeAllFromContainers(java.util.Collection items); - public A removeMatchingFromContainers(java.util.function.Predicate predicate); - + + public A removeAllFromContainers( + java.util.Collection items); + + public A removeMatchingFromContainers( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildContainers instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getContainers(); + public java.util.List buildContainers(); + public io.kubernetes.client.openapi.models.V1Container buildContainer(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Container buildFirstContainer(); + public io.kubernetes.client.openapi.models.V1Container buildLastContainer(); - public io.kubernetes.client.openapi.models.V1Container buildMatchingContainer(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingContainer(java.util.function.Predicate predicate); - public A withContainers(java.util.List containers); + + public io.kubernetes.client.openapi.models.V1Container buildMatchingContainer( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingContainer( + java.util.function.Predicate + predicate); + + public A withContainers( + java.util.List containers); + public A withContainers(io.kubernetes.client.openapi.models.V1Container... containers); + public java.lang.Boolean hasContainers(); + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested addNewContainer(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested addNewContainerLike(io.kubernetes.client.openapi.models.V1Container item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested setNewContainerLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Container item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested editContainer(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested editFirstContainer(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested editLastContainer(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested editMatchingContainer(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested + addNewContainerLike(io.kubernetes.client.openapi.models.V1Container item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested + setNewContainerLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested editContainer( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested + editFirstContainer(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested + editLastContainer(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested + editMatchingContainer( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildDnsConfig instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodDNSConfig getDnsConfig(); + public io.kubernetes.client.openapi.models.V1PodDNSConfig buildDnsConfig(); + public A withDnsConfig(io.kubernetes.client.openapi.models.V1PodDNSConfig dnsConfig); + public java.lang.Boolean hasDnsConfig(); + public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested withNewDnsConfig(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested withNewDnsConfigLike(io.kubernetes.client.openapi.models.V1PodDNSConfig item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested + withNewDnsConfigLike(io.kubernetes.client.openapi.models.V1PodDNSConfig item); + public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested editDnsConfig(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested editOrNewDnsConfig(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested editOrNewDnsConfigLike(io.kubernetes.client.openapi.models.V1PodDNSConfig item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested + editOrNewDnsConfig(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested + editOrNewDnsConfigLike(io.kubernetes.client.openapi.models.V1PodDNSConfig item); + public io.kubernetes.client.openapi.models.V1PodSpec.DnsPolicyEnum getDnsPolicy(); + public A withDnsPolicy(io.kubernetes.client.openapi.models.V1PodSpec.DnsPolicyEnum dnsPolicy); + public java.lang.Boolean hasDnsPolicy(); + public java.lang.Boolean getEnableServiceLinks(); + public A withEnableServiceLinks(java.lang.Boolean enableServiceLinks); + public java.lang.Boolean hasEnableServiceLinks(); - public A addToEphemeralContainers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EphemeralContainer item); - public A setToEphemeralContainers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EphemeralContainer item); - public A addToEphemeralContainers(io.kubernetes.client.openapi.models.V1EphemeralContainer... items); - public A addAllToEphemeralContainers(java.util.Collection items); - public A removeFromEphemeralContainers(io.kubernetes.client.openapi.models.V1EphemeralContainer... items); - public A removeAllFromEphemeralContainers(java.util.Collection items); - public A removeMatchingFromEphemeralContainers(java.util.function.Predicate predicate); - + + public A addToEphemeralContainers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EphemeralContainer item); + + public A setToEphemeralContainers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EphemeralContainer item); + + public A addToEphemeralContainers( + io.kubernetes.client.openapi.models.V1EphemeralContainer... items); + + public A addAllToEphemeralContainers( + java.util.Collection items); + + public A removeFromEphemeralContainers( + io.kubernetes.client.openapi.models.V1EphemeralContainer... items); + + public A removeAllFromEphemeralContainers( + java.util.Collection items); + + public A removeMatchingFromEphemeralContainers( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildEphemeralContainers instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getEphemeralContainers(); - public java.util.List buildEphemeralContainers(); - public io.kubernetes.client.openapi.models.V1EphemeralContainer buildEphemeralContainer(java.lang.Integer index); + public java.util.List + getEphemeralContainers(); + + public java.util.List + buildEphemeralContainers(); + + public io.kubernetes.client.openapi.models.V1EphemeralContainer buildEphemeralContainer( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1EphemeralContainer buildFirstEphemeralContainer(); + public io.kubernetes.client.openapi.models.V1EphemeralContainer buildLastEphemeralContainer(); - public io.kubernetes.client.openapi.models.V1EphemeralContainer buildMatchingEphemeralContainer(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingEphemeralContainer(java.util.function.Predicate predicate); - public A withEphemeralContainers(java.util.List ephemeralContainers); - public A withEphemeralContainers(io.kubernetes.client.openapi.models.V1EphemeralContainer... ephemeralContainers); + + public io.kubernetes.client.openapi.models.V1EphemeralContainer buildMatchingEphemeralContainer( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingEphemeralContainer( + java.util.function.Predicate + predicate); + + public A withEphemeralContainers( + java.util.List ephemeralContainers); + + public A withEphemeralContainers( + io.kubernetes.client.openapi.models.V1EphemeralContainer... ephemeralContainers); + public java.lang.Boolean hasEphemeralContainers(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested addNewEphemeralContainer(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested addNewEphemeralContainerLike(io.kubernetes.client.openapi.models.V1EphemeralContainer item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested setNewEphemeralContainerLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EphemeralContainer item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested editEphemeralContainer(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested editFirstEphemeralContainer(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested editLastEphemeralContainer(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested editMatchingEphemeralContainer(java.util.function.Predicate predicate); - public A addToHostAliases(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HostAlias item); - public A setToHostAliases(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HostAlias item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + addNewEphemeralContainer(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + addNewEphemeralContainerLike(io.kubernetes.client.openapi.models.V1EphemeralContainer item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + setNewEphemeralContainerLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EphemeralContainer item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + editEphemeralContainer(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + editFirstEphemeralContainer(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + editLastEphemeralContainer(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + editMatchingEphemeralContainer( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder> + predicate); + + public A addToHostAliases( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HostAlias item); + + public A setToHostAliases( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HostAlias item); + public A addToHostAliases(io.kubernetes.client.openapi.models.V1HostAlias... items); - public A addAllToHostAliases(java.util.Collection items); + + public A addAllToHostAliases( + java.util.Collection items); + public A removeFromHostAliases(io.kubernetes.client.openapi.models.V1HostAlias... items); - public A removeAllFromHostAliases(java.util.Collection items); - public A removeMatchingFromHostAliases(java.util.function.Predicate predicate); - + + public A removeAllFromHostAliases( + java.util.Collection items); + + public A removeMatchingFromHostAliases( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildHostAliases instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getHostAliases(); + public java.util.List buildHostAliases(); + public io.kubernetes.client.openapi.models.V1HostAlias buildHostAlias(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1HostAlias buildFirstHostAlias(); + public io.kubernetes.client.openapi.models.V1HostAlias buildLastHostAlias(); - public io.kubernetes.client.openapi.models.V1HostAlias buildMatchingHostAlias(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingHostAlias(java.util.function.Predicate predicate); - public A withHostAliases(java.util.List hostAliases); + + public io.kubernetes.client.openapi.models.V1HostAlias buildMatchingHostAlias( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingHostAlias( + java.util.function.Predicate + predicate); + + public A withHostAliases( + java.util.List hostAliases); + public A withHostAliases(io.kubernetes.client.openapi.models.V1HostAlias... hostAliases); + public java.lang.Boolean hasHostAliases(); + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested addNewHostAlias(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested addNewHostAliasLike(io.kubernetes.client.openapi.models.V1HostAlias item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested setNewHostAliasLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HostAlias item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested editHostAlias(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested editFirstHostAlias(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested editLastHostAlias(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested editMatchingHostAlias(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested + addNewHostAliasLike(io.kubernetes.client.openapi.models.V1HostAlias item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested + setNewHostAliasLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HostAlias item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested editHostAlias( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested + editFirstHostAlias(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested + editLastHostAlias(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested + editMatchingHostAlias( + java.util.function.Predicate + predicate); + public java.lang.Boolean getHostIPC(); + public A withHostIPC(java.lang.Boolean hostIPC); + public java.lang.Boolean hasHostIPC(); + public java.lang.Boolean getHostNetwork(); + public A withHostNetwork(java.lang.Boolean hostNetwork); + public java.lang.Boolean hasHostNetwork(); + public java.lang.Boolean getHostPID(); + public A withHostPID(java.lang.Boolean hostPID); + public java.lang.Boolean hasHostPID(); + public java.lang.String getHostname(); + public A withHostname(java.lang.String hostname); + public java.lang.Boolean hasHostname(); - - /** - * Method is deprecated. use withHostname instead. - */ + + /** Method is deprecated. use withHostname instead. */ @java.lang.Deprecated public A withNewHostname(java.lang.String original); - public A addToImagePullSecrets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public A setToImagePullSecrets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public A addToImagePullSecrets(io.kubernetes.client.openapi.models.V1LocalObjectReference... items); - public A addAllToImagePullSecrets(java.util.Collection items); - public A removeFromImagePullSecrets(io.kubernetes.client.openapi.models.V1LocalObjectReference... items); - public A removeAllFromImagePullSecrets(java.util.Collection items); - public A removeMatchingFromImagePullSecrets(java.util.function.Predicate predicate); - + + public A addToImagePullSecrets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public A setToImagePullSecrets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public A addToImagePullSecrets( + io.kubernetes.client.openapi.models.V1LocalObjectReference... items); + + public A addAllToImagePullSecrets( + java.util.Collection items); + + public A removeFromImagePullSecrets( + io.kubernetes.client.openapi.models.V1LocalObjectReference... items); + + public A removeAllFromImagePullSecrets( + java.util.Collection items); + + public A removeMatchingFromImagePullSecrets( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate); + /** * This method has been deprecated, please use method buildImagePullSecrets instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getImagePullSecrets(); - public java.util.List buildImagePullSecrets(); - public io.kubernetes.client.openapi.models.V1LocalObjectReference buildImagePullSecret(java.lang.Integer index); + public java.util.List + getImagePullSecrets(); + + public java.util.List + buildImagePullSecrets(); + + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildImagePullSecret( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildFirstImagePullSecret(); + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildLastImagePullSecret(); - public io.kubernetes.client.openapi.models.V1LocalObjectReference buildMatchingImagePullSecret(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingImagePullSecret(java.util.function.Predicate predicate); - public A withImagePullSecrets(java.util.List imagePullSecrets); - public A withImagePullSecrets(io.kubernetes.client.openapi.models.V1LocalObjectReference... imagePullSecrets); + + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildMatchingImagePullSecret( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate); + + public java.lang.Boolean hasMatchingImagePullSecret( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate); + + public A withImagePullSecrets( + java.util.List imagePullSecrets); + + public A withImagePullSecrets( + io.kubernetes.client.openapi.models.V1LocalObjectReference... imagePullSecrets); + public java.lang.Boolean hasImagePullSecrets(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested addNewImagePullSecret(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested addNewImagePullSecretLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested setNewImagePullSecretLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested editImagePullSecret(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested editFirstImagePullSecret(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested editLastImagePullSecret(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested editMatchingImagePullSecret(java.util.function.Predicate predicate); - public A addToInitContainers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Container item); - public A setToInitContainers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Container item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + addNewImagePullSecret(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + addNewImagePullSecretLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + setNewImagePullSecretLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + editImagePullSecret(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + editFirstImagePullSecret(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + editLastImagePullSecret(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + editMatchingImagePullSecret( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate); + + public A addToInitContainers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item); + + public A setToInitContainers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item); + public A addToInitContainers(io.kubernetes.client.openapi.models.V1Container... items); - public A addAllToInitContainers(java.util.Collection items); + + public A addAllToInitContainers( + java.util.Collection items); + public A removeFromInitContainers(io.kubernetes.client.openapi.models.V1Container... items); - public A removeAllFromInitContainers(java.util.Collection items); - public A removeMatchingFromInitContainers(java.util.function.Predicate predicate); - + + public A removeAllFromInitContainers( + java.util.Collection items); + + public A removeMatchingFromInitContainers( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildInitContainers instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getInitContainers(); + public java.util.List buildInitContainers(); - public io.kubernetes.client.openapi.models.V1Container buildInitContainer(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1Container buildInitContainer( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Container buildFirstInitContainer(); + public io.kubernetes.client.openapi.models.V1Container buildLastInitContainer(); - public io.kubernetes.client.openapi.models.V1Container buildMatchingInitContainer(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingInitContainer(java.util.function.Predicate predicate); - public A withInitContainers(java.util.List initContainers); + + public io.kubernetes.client.openapi.models.V1Container buildMatchingInitContainer( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingInitContainer( + java.util.function.Predicate + predicate); + + public A withInitContainers( + java.util.List initContainers); + public A withInitContainers(io.kubernetes.client.openapi.models.V1Container... initContainers); + public java.lang.Boolean hasInitContainers(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested addNewInitContainer(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested addNewInitContainerLike(io.kubernetes.client.openapi.models.V1Container item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested setNewInitContainerLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Container item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested editInitContainer(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested editFirstInitContainer(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested editLastInitContainer(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested editMatchingInitContainer(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + addNewInitContainer(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + addNewInitContainerLike(io.kubernetes.client.openapi.models.V1Container item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + setNewInitContainerLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + editInitContainer(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + editFirstInitContainer(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + editLastInitContainer(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + editMatchingInitContainer( + java.util.function.Predicate + predicate); + public java.lang.String getNodeName(); + public A withNodeName(java.lang.String nodeName); + public java.lang.Boolean hasNodeName(); - - /** - * Method is deprecated. use withNodeName instead. - */ + + /** Method is deprecated. use withNodeName instead. */ @java.lang.Deprecated public A withNewNodeName(java.lang.String original); - public A addToNodeSelector(java.lang.String key,java.lang.String value); - public A addToNodeSelector(java.util.Map map); + + public A addToNodeSelector(java.lang.String key, java.lang.String value); + + public A addToNodeSelector(java.util.Map map); + public A removeFromNodeSelector(java.lang.String key); - public A removeFromNodeSelector(java.util.Map map); - public java.util.Map getNodeSelector(); - public A withNodeSelector(java.util.Map nodeSelector); + + public A removeFromNodeSelector(java.util.Map map); + + public java.util.Map getNodeSelector(); + + public A withNodeSelector(java.util.Map nodeSelector); + public java.lang.Boolean hasNodeSelector(); - + /** * This method has been deprecated, please use method buildOs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodOS getOs(); + public io.kubernetes.client.openapi.models.V1PodOS buildOs(); + public A withOs(io.kubernetes.client.openapi.models.V1PodOS os); + public java.lang.Boolean hasOs(); + public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested withNewOs(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested withNewOsLike(io.kubernetes.client.openapi.models.V1PodOS item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested withNewOsLike( + io.kubernetes.client.openapi.models.V1PodOS item); + public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested editOs(); + public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested editOrNewOs(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested editOrNewOsLike(io.kubernetes.client.openapi.models.V1PodOS item); - public A addToOverhead(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToOverhead(java.util.Map map); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested editOrNewOsLike( + io.kubernetes.client.openapi.models.V1PodOS item); + + public A addToOverhead(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToOverhead(java.util.Map map); + public A removeFromOverhead(java.lang.String key); - public A removeFromOverhead(java.util.Map map); - public java.util.Map getOverhead(); - public A withOverhead(java.util.Map overhead); + + public A removeFromOverhead( + java.util.Map map); + + public java.util.Map getOverhead(); + + public A withOverhead( + java.util.Map overhead); + public java.lang.Boolean hasOverhead(); + public java.lang.String getPreemptionPolicy(); + public A withPreemptionPolicy(java.lang.String preemptionPolicy); + public java.lang.Boolean hasPreemptionPolicy(); - - /** - * Method is deprecated. use withPreemptionPolicy instead. - */ + + /** Method is deprecated. use withPreemptionPolicy instead. */ @java.lang.Deprecated public A withNewPreemptionPolicy(java.lang.String original); + public java.lang.Integer getPriority(); + public A withPriority(java.lang.Integer priority); + public java.lang.Boolean hasPriority(); + public java.lang.String getPriorityClassName(); + public A withPriorityClassName(java.lang.String priorityClassName); + public java.lang.Boolean hasPriorityClassName(); - - /** - * Method is deprecated. use withPriorityClassName instead. - */ + + /** Method is deprecated. use withPriorityClassName instead. */ @java.lang.Deprecated public A withNewPriorityClassName(java.lang.String original); - public A addToReadinessGates(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodReadinessGate item); - public A setToReadinessGates(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodReadinessGate item); + + public A addToReadinessGates( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodReadinessGate item); + + public A setToReadinessGates( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodReadinessGate item); + public A addToReadinessGates(io.kubernetes.client.openapi.models.V1PodReadinessGate... items); - public A addAllToReadinessGates(java.util.Collection items); - public A removeFromReadinessGates(io.kubernetes.client.openapi.models.V1PodReadinessGate... items); - public A removeAllFromReadinessGates(java.util.Collection items); - public A removeMatchingFromReadinessGates(java.util.function.Predicate predicate); - + + public A addAllToReadinessGates( + java.util.Collection items); + + public A removeFromReadinessGates( + io.kubernetes.client.openapi.models.V1PodReadinessGate... items); + + public A removeAllFromReadinessGates( + java.util.Collection items); + + public A removeMatchingFromReadinessGates( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildReadinessGates instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getReadinessGates(); - public java.util.List buildReadinessGates(); - public io.kubernetes.client.openapi.models.V1PodReadinessGate buildReadinessGate(java.lang.Integer index); + + public java.util.List + buildReadinessGates(); + + public io.kubernetes.client.openapi.models.V1PodReadinessGate buildReadinessGate( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PodReadinessGate buildFirstReadinessGate(); + public io.kubernetes.client.openapi.models.V1PodReadinessGate buildLastReadinessGate(); - public io.kubernetes.client.openapi.models.V1PodReadinessGate buildMatchingReadinessGate(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingReadinessGate(java.util.function.Predicate predicate); - public A withReadinessGates(java.util.List readinessGates); - public A withReadinessGates(io.kubernetes.client.openapi.models.V1PodReadinessGate... readinessGates); + + public io.kubernetes.client.openapi.models.V1PodReadinessGate buildMatchingReadinessGate( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingReadinessGate( + java.util.function.Predicate + predicate); + + public A withReadinessGates( + java.util.List readinessGates); + + public A withReadinessGates( + io.kubernetes.client.openapi.models.V1PodReadinessGate... readinessGates); + public java.lang.Boolean hasReadinessGates(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested addNewReadinessGate(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested addNewReadinessGateLike(io.kubernetes.client.openapi.models.V1PodReadinessGate item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested setNewReadinessGateLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodReadinessGate item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested editReadinessGate(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested editFirstReadinessGate(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested editLastReadinessGate(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested editMatchingReadinessGate(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + addNewReadinessGate(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + addNewReadinessGateLike(io.kubernetes.client.openapi.models.V1PodReadinessGate item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + setNewReadinessGateLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodReadinessGate item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + editReadinessGate(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + editFirstReadinessGate(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + editLastReadinessGate(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + editMatchingReadinessGate( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder> + predicate); + public io.kubernetes.client.openapi.models.V1PodSpec.RestartPolicyEnum getRestartPolicy(); - public A withRestartPolicy(io.kubernetes.client.openapi.models.V1PodSpec.RestartPolicyEnum restartPolicy); + + public A withRestartPolicy( + io.kubernetes.client.openapi.models.V1PodSpec.RestartPolicyEnum restartPolicy); + public java.lang.Boolean hasRestartPolicy(); + public java.lang.String getRuntimeClassName(); + public A withRuntimeClassName(java.lang.String runtimeClassName); + public java.lang.Boolean hasRuntimeClassName(); - - /** - * Method is deprecated. use withRuntimeClassName instead. - */ + + /** Method is deprecated. use withRuntimeClassName instead. */ @java.lang.Deprecated public A withNewRuntimeClassName(java.lang.String original); + public java.lang.String getSchedulerName(); + public A withSchedulerName(java.lang.String schedulerName); + public java.lang.Boolean hasSchedulerName(); - - /** - * Method is deprecated. use withSchedulerName instead. - */ + + /** Method is deprecated. use withSchedulerName instead. */ @java.lang.Deprecated public A withNewSchedulerName(java.lang.String original); - + /** * This method has been deprecated, please use method buildSecurityContext instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodSecurityContext getSecurityContext(); + public io.kubernetes.client.openapi.models.V1PodSecurityContext buildSecurityContext(); - public A withSecurityContext(io.kubernetes.client.openapi.models.V1PodSecurityContext securityContext); + + public A withSecurityContext( + io.kubernetes.client.openapi.models.V1PodSecurityContext securityContext); + public java.lang.Boolean hasSecurityContext(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested withNewSecurityContext(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested withNewSecurityContextLike(io.kubernetes.client.openapi.models.V1PodSecurityContext item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested editSecurityContext(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested editOrNewSecurityContext(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested editOrNewSecurityContextLike(io.kubernetes.client.openapi.models.V1PodSecurityContext item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested + withNewSecurityContext(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested + withNewSecurityContextLike(io.kubernetes.client.openapi.models.V1PodSecurityContext item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested + editSecurityContext(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested + editOrNewSecurityContext(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested + editOrNewSecurityContextLike(io.kubernetes.client.openapi.models.V1PodSecurityContext item); + public java.lang.String getServiceAccount(); + public A withServiceAccount(java.lang.String serviceAccount); + public java.lang.Boolean hasServiceAccount(); - - /** - * Method is deprecated. use withServiceAccount instead. - */ + + /** Method is deprecated. use withServiceAccount instead. */ @java.lang.Deprecated public A withNewServiceAccount(java.lang.String original); + public java.lang.String getServiceAccountName(); + public A withServiceAccountName(java.lang.String serviceAccountName); + public java.lang.Boolean hasServiceAccountName(); - - /** - * Method is deprecated. use withServiceAccountName instead. - */ + + /** Method is deprecated. use withServiceAccountName instead. */ @java.lang.Deprecated public A withNewServiceAccountName(java.lang.String original); + public java.lang.Boolean getSetHostnameAsFQDN(); + public A withSetHostnameAsFQDN(java.lang.Boolean setHostnameAsFQDN); + public java.lang.Boolean hasSetHostnameAsFQDN(); + public java.lang.Boolean getShareProcessNamespace(); + public A withShareProcessNamespace(java.lang.Boolean shareProcessNamespace); + public java.lang.Boolean hasShareProcessNamespace(); + public java.lang.String getSubdomain(); + public A withSubdomain(java.lang.String subdomain); + public java.lang.Boolean hasSubdomain(); - - /** - * Method is deprecated. use withSubdomain instead. - */ + + /** Method is deprecated. use withSubdomain instead. */ @java.lang.Deprecated public A withNewSubdomain(java.lang.String original); + public java.lang.Long getTerminationGracePeriodSeconds(); + public A withTerminationGracePeriodSeconds(java.lang.Long terminationGracePeriodSeconds); + public java.lang.Boolean hasTerminationGracePeriodSeconds(); - public A addToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item); - public A setToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item); + + public A addToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item); + + public A setToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item); + public A addToTolerations(io.kubernetes.client.openapi.models.V1Toleration... items); - public A addAllToTolerations(java.util.Collection items); + + public A addAllToTolerations( + java.util.Collection items); + public A removeFromTolerations(io.kubernetes.client.openapi.models.V1Toleration... items); - public A removeAllFromTolerations(java.util.Collection items); - public A removeMatchingFromTolerations(java.util.function.Predicate predicate); - + + public A removeAllFromTolerations( + java.util.Collection items); + + public A removeMatchingFromTolerations( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildTolerations instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getTolerations(); + public java.util.List buildTolerations(); + public io.kubernetes.client.openapi.models.V1Toleration buildToleration(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Toleration buildFirstToleration(); + public io.kubernetes.client.openapi.models.V1Toleration buildLastToleration(); - public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingToleration(java.util.function.Predicate predicate); - public A withTolerations(java.util.List tolerations); + + public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingToleration( + java.util.function.Predicate + predicate); + + public A withTolerations( + java.util.List tolerations); + public A withTolerations(io.kubernetes.client.openapi.models.V1Toleration... tolerations); + public java.lang.Boolean hasTolerations(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested addNewToleration(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested setNewTolerationLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested editToleration(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested editFirstToleration(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested editLastToleration(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested editMatchingToleration(java.util.function.Predicate predicate); - public A addToTopologySpreadConstraints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item); - public A setToTopologySpreadConstraints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item); - public A addToTopologySpreadConstraints(io.kubernetes.client.openapi.models.V1TopologySpreadConstraint... items); - public A addAllToTopologySpreadConstraints(java.util.Collection items); - public A removeFromTopologySpreadConstraints(io.kubernetes.client.openapi.models.V1TopologySpreadConstraint... items); - public A removeAllFromTopologySpreadConstraints(java.util.Collection items); - public A removeMatchingFromTopologySpreadConstraints(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested + addNewToleration(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested + addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested + setNewTolerationLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested editToleration( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested + editFirstToleration(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested + editLastToleration(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested + editMatchingToleration( + java.util.function.Predicate + predicate); + + public A addToTopologySpreadConstraints( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item); + + public A setToTopologySpreadConstraints( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item); + + public A addToTopologySpreadConstraints( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint... items); + + public A addAllToTopologySpreadConstraints( + java.util.Collection items); + + public A removeFromTopologySpreadConstraints( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint... items); + + public A removeAllFromTopologySpreadConstraints( + java.util.Collection items); + + public A removeMatchingFromTopologySpreadConstraints( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder> + predicate); + /** * This method has been deprecated, please use method buildTopologySpreadConstraints instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getTopologySpreadConstraints(); - public java.util.List buildTopologySpreadConstraints(); - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint buildTopologySpreadConstraint(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint buildFirstTopologySpreadConstraint(); - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint buildLastTopologySpreadConstraint(); - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint buildMatchingTopologySpreadConstraint(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingTopologySpreadConstraint(java.util.function.Predicate predicate); - public A withTopologySpreadConstraints(java.util.List topologySpreadConstraints); - public A withTopologySpreadConstraints(io.kubernetes.client.openapi.models.V1TopologySpreadConstraint... topologySpreadConstraints); + public java.util.List + getTopologySpreadConstraints(); + + public java.util.List + buildTopologySpreadConstraints(); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint + buildTopologySpreadConstraint(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint + buildFirstTopologySpreadConstraint(); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint + buildLastTopologySpreadConstraint(); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint + buildMatchingTopologySpreadConstraint( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder> + predicate); + + public java.lang.Boolean hasMatchingTopologySpreadConstraint( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder> + predicate); + + public A withTopologySpreadConstraints( + java.util.List + topologySpreadConstraints); + + public A withTopologySpreadConstraints( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint... topologySpreadConstraints); + public java.lang.Boolean hasTopologySpreadConstraints(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested addNewTopologySpreadConstraint(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested addNewTopologySpreadConstraintLike(io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested setNewTopologySpreadConstraintLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested editTopologySpreadConstraint(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested editFirstTopologySpreadConstraint(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested editLastTopologySpreadConstraint(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested editMatchingTopologySpreadConstraint(java.util.function.Predicate predicate); - public A addToVolumes(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Volume item); - public A setToVolumes(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Volume item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + addNewTopologySpreadConstraint(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + addNewTopologySpreadConstraintLike( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + setNewTopologySpreadConstraintLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + editTopologySpreadConstraint(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + editFirstTopologySpreadConstraint(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + editLastTopologySpreadConstraint(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + editMatchingTopologySpreadConstraint( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder> + predicate); + + public A addToVolumes(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Volume item); + + public A setToVolumes(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Volume item); + public A addToVolumes(io.kubernetes.client.openapi.models.V1Volume... items); - public A addAllToVolumes(java.util.Collection items); + + public A addAllToVolumes( + java.util.Collection items); + public A removeFromVolumes(io.kubernetes.client.openapi.models.V1Volume... items); - public A removeAllFromVolumes(java.util.Collection items); - public A removeMatchingFromVolumes(java.util.function.Predicate predicate); - + + public A removeAllFromVolumes( + java.util.Collection items); + + public A removeMatchingFromVolumes( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildVolumes instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getVolumes(); + public java.util.List buildVolumes(); + public io.kubernetes.client.openapi.models.V1Volume buildVolume(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Volume buildFirstVolume(); + public io.kubernetes.client.openapi.models.V1Volume buildLastVolume(); - public io.kubernetes.client.openapi.models.V1Volume buildMatchingVolume(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVolume(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Volume buildMatchingVolume( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingVolume( + java.util.function.Predicate predicate); + public A withVolumes(java.util.List volumes); + public A withVolumes(io.kubernetes.client.openapi.models.V1Volume... volumes); + public java.lang.Boolean hasVolumes(); + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested addNewVolume(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested addNewVolumeLike(io.kubernetes.client.openapi.models.V1Volume item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested setNewVolumeLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Volume item); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested editVolume(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested addNewVolumeLike( + io.kubernetes.client.openapi.models.V1Volume item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested setNewVolumeLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Volume item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested editVolume( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested editFirstVolume(); + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested editLastVolume(); - public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested editMatchingVolume(java.util.function.Predicate predicate); - public interface AffinityNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1AffinityFluent>{ + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested editMatchingVolume( + java.util.function.Predicate predicate); + + public interface AffinityNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1AffinityFluent< + io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested> { public N and(); + public N endAffinity(); - } - public interface ContainersNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ContainerFluent>{ + + public interface ContainersNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ContainerFluent< + io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested> { public N and(); + public N endContainer(); - } - public interface DnsConfigNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodDNSConfigFluent>{ + + public interface DnsConfigNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodDNSConfigFluent< + io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested> { public N and(); + public N endDnsConfig(); - } - public interface EphemeralContainersNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EphemeralContainerFluent>{ + + public interface EphemeralContainersNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EphemeralContainerFluent< + io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested> { public N and(); + public N endEphemeralContainer(); - } - public interface HostAliasesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1HostAliasFluent>{ + + public interface HostAliasesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1HostAliasFluent< + io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested> { public N and(); + public N endHostAlias(); - } - public interface ImagePullSecretsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent>{ + + public interface ImagePullSecretsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested> { public N and(); + public N endImagePullSecret(); - } - public interface InitContainersNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ContainerFluent>{ + + public interface InitContainersNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ContainerFluent< + io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested> { public N and(); + public N endInitContainer(); - } - public interface OsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodOSFluent>{ + + public interface OsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodOSFluent< + io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested> { public N and(); + public N endOs(); - } - public interface ReadinessGatesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodReadinessGateFluent>{ + + public interface ReadinessGatesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodReadinessGateFluent< + io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested> { public N and(); + public N endReadinessGate(); - } - public interface SecurityContextNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodSecurityContextFluent>{ + + public interface SecurityContextNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodSecurityContextFluent< + io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested> { public N and(); + public N endSecurityContext(); - } - public interface TolerationsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TolerationFluent>{ + + public interface TolerationsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TolerationFluent< + io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested> { public N and(); + public N endToleration(); - } - public interface TopologySpreadConstraintsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent>{ + + public interface TopologySpreadConstraintsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent< + io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested< + N>> { public N and(); + public N endTopologySpreadConstraint(); - } - public interface VolumesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeFluent>{ + + public interface VolumesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeFluent< + io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested> { public N and(); + public N endVolume(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSpecFluentImpl.java index 37eafa7be8..b3cc9b755a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodSpecFluentImpl.java @@ -1,29 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.List; -import java.lang.Boolean; -import java.lang.Long; -import java.util.Collection; -import java.lang.Object; -import java.util.Map; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; import java.util.Iterator; -import io.kubernetes.client.custom.Quantity; -import java.lang.Integer; +import java.util.List; + +/** Generated */ +public class V1PodSpecFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodSpecFluent { + public V1PodSpecFluentImpl() {} - /** - * Generated - */ -public class V1PodSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodSpecFluent{ - public V1PodSpecFluentImpl() { - } public V1PodSpecFluentImpl(io.kubernetes.client.openapi.models.V1PodSpec instance) { this.withActiveDeadlineSeconds(instance.getActiveDeadlineSeconds()); @@ -96,8 +93,8 @@ public V1PodSpecFluentImpl(io.kubernetes.client.openapi.models.V1PodSpec instanc this.withTopologySpreadConstraints(instance.getTopologySpreadConstraints()); this.withVolumes(instance.getVolumes()); - } + private java.lang.Long activeDeadlineSeconds; private io.kubernetes.client.openapi.models.V1AffinityBuilder affinity; private java.lang.Boolean automountServiceAccountToken; @@ -105,22 +102,26 @@ public V1PodSpecFluentImpl(io.kubernetes.client.openapi.models.V1PodSpec instanc private io.kubernetes.client.openapi.models.V1PodDNSConfigBuilder dnsConfig; private io.kubernetes.client.openapi.models.V1PodSpec.DnsPolicyEnum dnsPolicy; private java.lang.Boolean enableServiceLinks; - private java.util.ArrayList ephemeralContainers; + private java.util.ArrayList + ephemeralContainers; private java.util.ArrayList hostAliases; private java.lang.Boolean hostIPC; private java.lang.Boolean hostNetwork; private java.lang.Boolean hostPID; private java.lang.String hostname; - private java.util.ArrayList imagePullSecrets; - private java.util.ArrayList initContainers; + private java.util.ArrayList + imagePullSecrets; + private java.util.ArrayList + initContainers; private java.lang.String nodeName; - private java.util.Map nodeSelector; + private java.util.Map nodeSelector; private io.kubernetes.client.openapi.models.V1PodOSBuilder os; - private java.util.Map overhead; + private java.util.Map overhead; private java.lang.String preemptionPolicy; private java.lang.Integer priority; private java.lang.String priorityClassName; - private java.util.ArrayList readinessGates; + private java.util.ArrayList + readinessGates; private io.kubernetes.client.openapi.models.V1PodSpec.RestartPolicyEnum restartPolicy; private java.lang.String runtimeClassName; private java.lang.String schedulerName; @@ -132,88 +133,184 @@ public V1PodSpecFluentImpl(io.kubernetes.client.openapi.models.V1PodSpec instanc private java.lang.String subdomain; private java.lang.Long terminationGracePeriodSeconds; private java.util.ArrayList tolerations; - private java.util.ArrayList topologySpreadConstraints; + private java.util.ArrayList + topologySpreadConstraints; private java.util.ArrayList volumes; + public java.lang.Long getActiveDeadlineSeconds() { return this.activeDeadlineSeconds; } + public A withActiveDeadlineSeconds(java.lang.Long activeDeadlineSeconds) { - this.activeDeadlineSeconds=activeDeadlineSeconds; return (A) this; + this.activeDeadlineSeconds = activeDeadlineSeconds; + return (A) this; } + public java.lang.Boolean hasActiveDeadlineSeconds() { return this.activeDeadlineSeconds != null; } - + /** * This method has been deprecated, please use method buildAffinity instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Affinity getAffinity() { - return this.affinity!=null ?this.affinity.build():null; + return this.affinity != null ? this.affinity.build() : null; } + public io.kubernetes.client.openapi.models.V1Affinity buildAffinity() { - return this.affinity!=null ?this.affinity.build():null; + return this.affinity != null ? this.affinity.build() : null; } + public A withAffinity(io.kubernetes.client.openapi.models.V1Affinity affinity) { _visitables.get("affinity").remove(this.affinity); - if (affinity!=null){ this.affinity= new io.kubernetes.client.openapi.models.V1AffinityBuilder(affinity); _visitables.get("affinity").add(this.affinity);} return (A) this; + if (affinity != null) { + this.affinity = new io.kubernetes.client.openapi.models.V1AffinityBuilder(affinity); + _visitables.get("affinity").add(this.affinity); + } + return (A) this; } + public java.lang.Boolean hasAffinity() { return this.affinity != null; } + public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested withNewAffinity() { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.AffinityNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested withNewAffinityLike(io.kubernetes.client.openapi.models.V1Affinity item) { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested withNewAffinityLike( + io.kubernetes.client.openapi.models.V1Affinity item) { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.AffinityNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested editAffinity() { return withNewAffinityLike(getAffinity()); } + public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested editOrNewAffinity() { - return withNewAffinityLike(getAffinity() != null ? getAffinity(): new io.kubernetes.client.openapi.models.V1AffinityBuilder().build()); + return withNewAffinityLike( + getAffinity() != null + ? getAffinity() + : new io.kubernetes.client.openapi.models.V1AffinityBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested editOrNewAffinityLike(io.kubernetes.client.openapi.models.V1Affinity item) { - return withNewAffinityLike(getAffinity() != null ? getAffinity(): item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested + editOrNewAffinityLike(io.kubernetes.client.openapi.models.V1Affinity item) { + return withNewAffinityLike(getAffinity() != null ? getAffinity() : item); } + public java.lang.Boolean getAutomountServiceAccountToken() { return this.automountServiceAccountToken; } + public A withAutomountServiceAccountToken(java.lang.Boolean automountServiceAccountToken) { - this.automountServiceAccountToken=automountServiceAccountToken; return (A) this; + this.automountServiceAccountToken = automountServiceAccountToken; + return (A) this; } + public java.lang.Boolean hasAutomountServiceAccountToken() { return this.automountServiceAccountToken != null; } - public A addToContainers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Container item) { - if (this.containers == null) {this.containers = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ContainerBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(item);_visitables.get("containers").add(index >= 0 ? index : _visitables.get("containers").size(), builder);this.containers.add(index >= 0 ? index : containers.size(), builder); return (A)this; + + public A addToContainers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item) { + if (this.containers == null) { + this.containers = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); + _visitables + .get("containers") + .add(index >= 0 ? index : _visitables.get("containers").size(), builder); + this.containers.add(index >= 0 ? index : containers.size(), builder); + return (A) this; } - public A setToContainers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Container item) { - if (this.containers == null) {this.containers = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ContainerBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); - if (index < 0 || index >= _visitables.get("containers").size()) { _visitables.get("containers").add(builder); } else { _visitables.get("containers").set(index, builder);} - if (index < 0 || index >= containers.size()) { containers.add(builder); } else { containers.set(index, builder);} - return (A)this; + + public A setToContainers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item) { + if (this.containers == null) { + this.containers = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); + if (index < 0 || index >= _visitables.get("containers").size()) { + _visitables.get("containers").add(builder); + } else { + _visitables.get("containers").set(index, builder); + } + if (index < 0 || index >= containers.size()) { + containers.add(builder); + } else { + containers.set(index, builder); + } + return (A) this; } + public A addToContainers(io.kubernetes.client.openapi.models.V1Container... items) { - if (this.containers == null) {this.containers = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Container item : items) {io.kubernetes.client.openapi.models.V1ContainerBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(item);_visitables.get("containers").add(builder);this.containers.add(builder);} return (A)this; + if (this.containers == null) { + this.containers = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Container item : items) { + io.kubernetes.client.openapi.models.V1ContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); + _visitables.get("containers").add(builder); + this.containers.add(builder); + } + return (A) this; } - public A addAllToContainers(java.util.Collection items) { - if (this.containers == null) {this.containers = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Container item : items) {io.kubernetes.client.openapi.models.V1ContainerBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(item);_visitables.get("containers").add(builder);this.containers.add(builder);} return (A)this; + + public A addAllToContainers( + java.util.Collection items) { + if (this.containers == null) { + this.containers = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Container item : items) { + io.kubernetes.client.openapi.models.V1ContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); + _visitables.get("containers").add(builder); + this.containers.add(builder); + } + return (A) this; } + public A removeFromContainers(io.kubernetes.client.openapi.models.V1Container... items) { - for (io.kubernetes.client.openapi.models.V1Container item : items) {io.kubernetes.client.openapi.models.V1ContainerBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(item);_visitables.get("containers").remove(builder);if (this.containers != null) {this.containers.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Container item : items) { + io.kubernetes.client.openapi.models.V1ContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); + _visitables.get("containers").remove(builder); + if (this.containers != null) { + this.containers.remove(builder); + } + } + return (A) this; } - public A removeAllFromContainers(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Container item : items) {io.kubernetes.client.openapi.models.V1ContainerBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(item);_visitables.get("containers").remove(builder);if (this.containers != null) {this.containers.remove(builder);}} return (A)this; + + public A removeAllFromContainers( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Container item : items) { + io.kubernetes.client.openapi.models.V1ContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); + _visitables.get("containers").remove(builder); + if (this.containers != null) { + this.containers.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromContainers(java.util.function.Predicate predicate) { + + public A removeMatchingFromContainers( + java.util.function.Predicate + predicate) { if (containers == null) return (A) this; - final Iterator each = containers.iterator(); + final Iterator each = + containers.iterator(); final List visitables = _visitables.get("containers"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ContainerBuilder builder = each.next(); @@ -222,156 +319,323 @@ public A removeMatchingFromContainers(java.util.function.Predicate getContainers() { return containers != null ? build(containers) : null; } + public java.util.List buildContainers() { return containers != null ? build(containers) : null; } + public io.kubernetes.client.openapi.models.V1Container buildContainer(java.lang.Integer index) { return this.containers.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Container buildFirstContainer() { return this.containers.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Container buildLastContainer() { return this.containers.get(containers.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Container buildMatchingContainer(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerBuilder item: containers) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Container buildMatchingContainer( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerBuilder item : containers) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingContainer(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerBuilder item: containers) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingContainer( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerBuilder item : containers) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withContainers(java.util.List containers) { - if (this.containers != null) { _visitables.get("containers").removeAll(this.containers);} - if (containers != null) {this.containers = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Container item : containers){this.addToContainers(item);}} else { this.containers = null;} return (A) this; + + public A withContainers( + java.util.List containers) { + if (this.containers != null) { + _visitables.get("containers").removeAll(this.containers); + } + if (containers != null) { + this.containers = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Container item : containers) { + this.addToContainers(item); + } + } else { + this.containers = null; + } + return (A) this; } + public A withContainers(io.kubernetes.client.openapi.models.V1Container... containers) { - if (this.containers != null) {this.containers.clear();} - if (containers != null) {for (io.kubernetes.client.openapi.models.V1Container item :containers){ this.addToContainers(item);}} return (A) this; + if (this.containers != null) { + this.containers.clear(); + } + if (containers != null) { + for (io.kubernetes.client.openapi.models.V1Container item : containers) { + this.addToContainers(item); + } + } + return (A) this; } + public java.lang.Boolean hasContainers() { return containers != null && !containers.isEmpty(); } + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested addNewContainer() { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ContainersNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested addNewContainerLike(io.kubernetes.client.openapi.models.V1Container item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ContainersNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested + addNewContainerLike(io.kubernetes.client.openapi.models.V1Container item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ContainersNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested setNewContainerLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Container item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ContainersNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested + setNewContainerLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ContainersNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested editContainer(java.lang.Integer index) { - if (containers.size() <= index) throw new RuntimeException("Can't edit containers. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested editContainer( + java.lang.Integer index) { + if (containers.size() <= index) + throw new RuntimeException("Can't edit containers. Index exceeds size."); return setNewContainerLike(index, buildContainer(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested editFirstContainer() { - if (containers.size() == 0) throw new RuntimeException("Can't edit first containers. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested + editFirstContainer() { + if (containers.size() == 0) + throw new RuntimeException("Can't edit first containers. The list is empty."); return setNewContainerLike(0, buildContainer(0)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested editLastContainer() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested + editLastContainer() { int index = containers.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last containers. The list is empty."); return setNewContainerLike(index, buildContainer(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested editMatchingContainer(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested + editMatchingContainer( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewDnsConfig() { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.DnsConfigNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested withNewDnsConfigLike(io.kubernetes.client.openapi.models.V1PodDNSConfig item) { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested + withNewDnsConfigLike(io.kubernetes.client.openapi.models.V1PodDNSConfig item) { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.DnsConfigNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested editDnsConfig() { return withNewDnsConfigLike(getDnsConfig()); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested editOrNewDnsConfig() { - return withNewDnsConfigLike(getDnsConfig() != null ? getDnsConfig(): new io.kubernetes.client.openapi.models.V1PodDNSConfigBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested + editOrNewDnsConfig() { + return withNewDnsConfigLike( + getDnsConfig() != null + ? getDnsConfig() + : new io.kubernetes.client.openapi.models.V1PodDNSConfigBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested editOrNewDnsConfigLike(io.kubernetes.client.openapi.models.V1PodDNSConfig item) { - return withNewDnsConfigLike(getDnsConfig() != null ? getDnsConfig(): item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested + editOrNewDnsConfigLike(io.kubernetes.client.openapi.models.V1PodDNSConfig item) { + return withNewDnsConfigLike(getDnsConfig() != null ? getDnsConfig() : item); } + public io.kubernetes.client.openapi.models.V1PodSpec.DnsPolicyEnum getDnsPolicy() { return this.dnsPolicy; } + public A withDnsPolicy(io.kubernetes.client.openapi.models.V1PodSpec.DnsPolicyEnum dnsPolicy) { - this.dnsPolicy=dnsPolicy; return (A) this; + this.dnsPolicy = dnsPolicy; + return (A) this; } + public java.lang.Boolean hasDnsPolicy() { return this.dnsPolicy != null; } + public java.lang.Boolean getEnableServiceLinks() { return this.enableServiceLinks; } + public A withEnableServiceLinks(java.lang.Boolean enableServiceLinks) { - this.enableServiceLinks=enableServiceLinks; return (A) this; + this.enableServiceLinks = enableServiceLinks; + return (A) this; } + public java.lang.Boolean hasEnableServiceLinks() { return this.enableServiceLinks != null; } - public A addToEphemeralContainers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EphemeralContainer item) { - if (this.ephemeralContainers == null) {this.ephemeralContainers = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder = new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(item);_visitables.get("ephemeralContainers").add(index >= 0 ? index : _visitables.get("ephemeralContainers").size(), builder);this.ephemeralContainers.add(index >= 0 ? index : ephemeralContainers.size(), builder); return (A)this; + + public A addToEphemeralContainers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EphemeralContainer item) { + if (this.ephemeralContainers == null) { + this.ephemeralContainers = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder>(); + } + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(item); + _visitables + .get("ephemeralContainers") + .add(index >= 0 ? index : _visitables.get("ephemeralContainers").size(), builder); + this.ephemeralContainers.add(index >= 0 ? index : ephemeralContainers.size(), builder); + return (A) this; } - public A setToEphemeralContainers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EphemeralContainer item) { - if (this.ephemeralContainers == null) {this.ephemeralContainers = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder = new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(item); - if (index < 0 || index >= _visitables.get("ephemeralContainers").size()) { _visitables.get("ephemeralContainers").add(builder); } else { _visitables.get("ephemeralContainers").set(index, builder);} - if (index < 0 || index >= ephemeralContainers.size()) { ephemeralContainers.add(builder); } else { ephemeralContainers.set(index, builder);} - return (A)this; + + public A setToEphemeralContainers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EphemeralContainer item) { + if (this.ephemeralContainers == null) { + this.ephemeralContainers = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder>(); + } + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(item); + if (index < 0 || index >= _visitables.get("ephemeralContainers").size()) { + _visitables.get("ephemeralContainers").add(builder); + } else { + _visitables.get("ephemeralContainers").set(index, builder); + } + if (index < 0 || index >= ephemeralContainers.size()) { + ephemeralContainers.add(builder); + } else { + ephemeralContainers.set(index, builder); + } + return (A) this; } - public A addToEphemeralContainers(io.kubernetes.client.openapi.models.V1EphemeralContainer... items) { - if (this.ephemeralContainers == null) {this.ephemeralContainers = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EphemeralContainer item : items) {io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder = new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(item);_visitables.get("ephemeralContainers").add(builder);this.ephemeralContainers.add(builder);} return (A)this; + + public A addToEphemeralContainers( + io.kubernetes.client.openapi.models.V1EphemeralContainer... items) { + if (this.ephemeralContainers == null) { + this.ephemeralContainers = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1EphemeralContainer item : items) { + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(item); + _visitables.get("ephemeralContainers").add(builder); + this.ephemeralContainers.add(builder); + } + return (A) this; } - public A addAllToEphemeralContainers(java.util.Collection items) { - if (this.ephemeralContainers == null) {this.ephemeralContainers = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1EphemeralContainer item : items) {io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder = new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(item);_visitables.get("ephemeralContainers").add(builder);this.ephemeralContainers.add(builder);} return (A)this; + + public A addAllToEphemeralContainers( + java.util.Collection items) { + if (this.ephemeralContainers == null) { + this.ephemeralContainers = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1EphemeralContainer item : items) { + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(item); + _visitables.get("ephemeralContainers").add(builder); + this.ephemeralContainers.add(builder); + } + return (A) this; } - public A removeFromEphemeralContainers(io.kubernetes.client.openapi.models.V1EphemeralContainer... items) { - for (io.kubernetes.client.openapi.models.V1EphemeralContainer item : items) {io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder = new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(item);_visitables.get("ephemeralContainers").remove(builder);if (this.ephemeralContainers != null) {this.ephemeralContainers.remove(builder);}} return (A)this; + + public A removeFromEphemeralContainers( + io.kubernetes.client.openapi.models.V1EphemeralContainer... items) { + for (io.kubernetes.client.openapi.models.V1EphemeralContainer item : items) { + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(item); + _visitables.get("ephemeralContainers").remove(builder); + if (this.ephemeralContainers != null) { + this.ephemeralContainers.remove(builder); + } + } + return (A) this; } - public A removeAllFromEphemeralContainers(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1EphemeralContainer item : items) {io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder = new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(item);_visitables.get("ephemeralContainers").remove(builder);if (this.ephemeralContainers != null) {this.ephemeralContainers.remove(builder);}} return (A)this; + + public A removeAllFromEphemeralContainers( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1EphemeralContainer item : items) { + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(item); + _visitables.get("ephemeralContainers").remove(builder); + if (this.ephemeralContainers != null) { + this.ephemeralContainers.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromEphemeralContainers(java.util.function.Predicate predicate) { + + public A removeMatchingFromEphemeralContainers( + java.util.function.Predicate + predicate) { if (ephemeralContainers == null) return (A) this; - final Iterator each = ephemeralContainers.iterator(); + final Iterator each = + ephemeralContainers.iterator(); final List visitables = _visitables.get("ephemeralContainers"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder = each.next(); @@ -380,104 +644,250 @@ public A removeMatchingFromEphemeralContainers(java.util.function.Predicate getEphemeralContainers() { + public java.util.List + getEphemeralContainers() { return ephemeralContainers != null ? build(ephemeralContainers) : null; } - public java.util.List buildEphemeralContainers() { + + public java.util.List + buildEphemeralContainers() { return ephemeralContainers != null ? build(ephemeralContainers) : null; } - public io.kubernetes.client.openapi.models.V1EphemeralContainer buildEphemeralContainer(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1EphemeralContainer buildEphemeralContainer( + java.lang.Integer index) { return this.ephemeralContainers.get(index).build(); } + public io.kubernetes.client.openapi.models.V1EphemeralContainer buildFirstEphemeralContainer() { return this.ephemeralContainers.get(0).build(); } + public io.kubernetes.client.openapi.models.V1EphemeralContainer buildLastEphemeralContainer() { return this.ephemeralContainers.get(ephemeralContainers.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1EphemeralContainer buildMatchingEphemeralContainer(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder item: ephemeralContainers) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1EphemeralContainer buildMatchingEphemeralContainer( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder item : + ephemeralContainers) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingEphemeralContainer(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder item: ephemeralContainers) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingEphemeralContainer( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder item : + ephemeralContainers) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withEphemeralContainers(java.util.List ephemeralContainers) { - if (this.ephemeralContainers != null) { _visitables.get("ephemeralContainers").removeAll(this.ephemeralContainers);} - if (ephemeralContainers != null) {this.ephemeralContainers = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1EphemeralContainer item : ephemeralContainers){this.addToEphemeralContainers(item);}} else { this.ephemeralContainers = null;} return (A) this; + + public A withEphemeralContainers( + java.util.List + ephemeralContainers) { + if (this.ephemeralContainers != null) { + _visitables.get("ephemeralContainers").removeAll(this.ephemeralContainers); + } + if (ephemeralContainers != null) { + this.ephemeralContainers = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1EphemeralContainer item : ephemeralContainers) { + this.addToEphemeralContainers(item); + } + } else { + this.ephemeralContainers = null; + } + return (A) this; } - public A withEphemeralContainers(io.kubernetes.client.openapi.models.V1EphemeralContainer... ephemeralContainers) { - if (this.ephemeralContainers != null) {this.ephemeralContainers.clear();} - if (ephemeralContainers != null) {for (io.kubernetes.client.openapi.models.V1EphemeralContainer item :ephemeralContainers){ this.addToEphemeralContainers(item);}} return (A) this; + + public A withEphemeralContainers( + io.kubernetes.client.openapi.models.V1EphemeralContainer... ephemeralContainers) { + if (this.ephemeralContainers != null) { + this.ephemeralContainers.clear(); + } + if (ephemeralContainers != null) { + for (io.kubernetes.client.openapi.models.V1EphemeralContainer item : ephemeralContainers) { + this.addToEphemeralContainers(item); + } + } + return (A) this; } + public java.lang.Boolean hasEphemeralContainers() { return ephemeralContainers != null && !ephemeralContainers.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested addNewEphemeralContainer() { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.EphemeralContainersNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + addNewEphemeralContainer() { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl + .EphemeralContainersNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested addNewEphemeralContainerLike(io.kubernetes.client.openapi.models.V1EphemeralContainer item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.EphemeralContainersNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + addNewEphemeralContainerLike(io.kubernetes.client.openapi.models.V1EphemeralContainer item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl + .EphemeralContainersNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested setNewEphemeralContainerLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EphemeralContainer item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.EphemeralContainersNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + setNewEphemeralContainerLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EphemeralContainer item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl + .EphemeralContainersNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested editEphemeralContainer(java.lang.Integer index) { - if (ephemeralContainers.size() <= index) throw new RuntimeException("Can't edit ephemeralContainers. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + editEphemeralContainer(java.lang.Integer index) { + if (ephemeralContainers.size() <= index) + throw new RuntimeException("Can't edit ephemeralContainers. Index exceeds size."); return setNewEphemeralContainerLike(index, buildEphemeralContainer(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested editFirstEphemeralContainer() { - if (ephemeralContainers.size() == 0) throw new RuntimeException("Can't edit first ephemeralContainers. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + editFirstEphemeralContainer() { + if (ephemeralContainers.size() == 0) + throw new RuntimeException("Can't edit first ephemeralContainers. The list is empty."); return setNewEphemeralContainerLike(0, buildEphemeralContainer(0)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested editLastEphemeralContainer() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + editLastEphemeralContainer() { int index = ephemeralContainers.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last ephemeralContainers. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last ephemeralContainers. The list is empty."); return setNewEphemeralContainerLike(index, buildEphemeralContainer(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested editMatchingEphemeralContainer(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested + editMatchingEphemeralContainer( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1HostAliasBuilder builder = new io.kubernetes.client.openapi.models.V1HostAliasBuilder(item);_visitables.get("hostAliases").add(index >= 0 ? index : _visitables.get("hostAliases").size(), builder);this.hostAliases.add(index >= 0 ? index : hostAliases.size(), builder); return (A)this; + + public A addToHostAliases( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HostAlias item) { + if (this.hostAliases == null) { + this.hostAliases = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1HostAliasBuilder builder = + new io.kubernetes.client.openapi.models.V1HostAliasBuilder(item); + _visitables + .get("hostAliases") + .add(index >= 0 ? index : _visitables.get("hostAliases").size(), builder); + this.hostAliases.add(index >= 0 ? index : hostAliases.size(), builder); + return (A) this; } - public A setToHostAliases(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HostAlias item) { - if (this.hostAliases == null) {this.hostAliases = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1HostAliasBuilder builder = new io.kubernetes.client.openapi.models.V1HostAliasBuilder(item); - if (index < 0 || index >= _visitables.get("hostAliases").size()) { _visitables.get("hostAliases").add(builder); } else { _visitables.get("hostAliases").set(index, builder);} - if (index < 0 || index >= hostAliases.size()) { hostAliases.add(builder); } else { hostAliases.set(index, builder);} - return (A)this; + + public A setToHostAliases( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HostAlias item) { + if (this.hostAliases == null) { + this.hostAliases = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1HostAliasBuilder builder = + new io.kubernetes.client.openapi.models.V1HostAliasBuilder(item); + if (index < 0 || index >= _visitables.get("hostAliases").size()) { + _visitables.get("hostAliases").add(builder); + } else { + _visitables.get("hostAliases").set(index, builder); + } + if (index < 0 || index >= hostAliases.size()) { + hostAliases.add(builder); + } else { + hostAliases.set(index, builder); + } + return (A) this; } + public A addToHostAliases(io.kubernetes.client.openapi.models.V1HostAlias... items) { - if (this.hostAliases == null) {this.hostAliases = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1HostAlias item : items) {io.kubernetes.client.openapi.models.V1HostAliasBuilder builder = new io.kubernetes.client.openapi.models.V1HostAliasBuilder(item);_visitables.get("hostAliases").add(builder);this.hostAliases.add(builder);} return (A)this; + if (this.hostAliases == null) { + this.hostAliases = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1HostAlias item : items) { + io.kubernetes.client.openapi.models.V1HostAliasBuilder builder = + new io.kubernetes.client.openapi.models.V1HostAliasBuilder(item); + _visitables.get("hostAliases").add(builder); + this.hostAliases.add(builder); + } + return (A) this; } - public A addAllToHostAliases(java.util.Collection items) { - if (this.hostAliases == null) {this.hostAliases = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1HostAlias item : items) {io.kubernetes.client.openapi.models.V1HostAliasBuilder builder = new io.kubernetes.client.openapi.models.V1HostAliasBuilder(item);_visitables.get("hostAliases").add(builder);this.hostAliases.add(builder);} return (A)this; + + public A addAllToHostAliases( + java.util.Collection items) { + if (this.hostAliases == null) { + this.hostAliases = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1HostAlias item : items) { + io.kubernetes.client.openapi.models.V1HostAliasBuilder builder = + new io.kubernetes.client.openapi.models.V1HostAliasBuilder(item); + _visitables.get("hostAliases").add(builder); + this.hostAliases.add(builder); + } + return (A) this; } + public A removeFromHostAliases(io.kubernetes.client.openapi.models.V1HostAlias... items) { - for (io.kubernetes.client.openapi.models.V1HostAlias item : items) {io.kubernetes.client.openapi.models.V1HostAliasBuilder builder = new io.kubernetes.client.openapi.models.V1HostAliasBuilder(item);_visitables.get("hostAliases").remove(builder);if (this.hostAliases != null) {this.hostAliases.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1HostAlias item : items) { + io.kubernetes.client.openapi.models.V1HostAliasBuilder builder = + new io.kubernetes.client.openapi.models.V1HostAliasBuilder(item); + _visitables.get("hostAliases").remove(builder); + if (this.hostAliases != null) { + this.hostAliases.remove(builder); + } + } + return (A) this; } - public A removeAllFromHostAliases(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1HostAlias item : items) {io.kubernetes.client.openapi.models.V1HostAliasBuilder builder = new io.kubernetes.client.openapi.models.V1HostAliasBuilder(item);_visitables.get("hostAliases").remove(builder);if (this.hostAliases != null) {this.hostAliases.remove(builder);}} return (A)this; + + public A removeAllFromHostAliases( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1HostAlias item : items) { + io.kubernetes.client.openapi.models.V1HostAliasBuilder builder = + new io.kubernetes.client.openapi.models.V1HostAliasBuilder(item); + _visitables.get("hostAliases").remove(builder); + if (this.hostAliases != null) { + this.hostAliases.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromHostAliases(java.util.function.Predicate predicate) { + + public A removeMatchingFromHostAliases( + java.util.function.Predicate + predicate) { if (hostAliases == null) return (A) this; - final Iterator each = hostAliases.iterator(); + final Iterator each = + hostAliases.iterator(); final List visitables = _visitables.get("hostAliases"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1HostAliasBuilder builder = each.next(); @@ -486,148 +896,304 @@ public A removeMatchingFromHostAliases(java.util.function.Predicate getHostAliases() { return hostAliases != null ? build(hostAliases) : null; } + public java.util.List buildHostAliases() { return hostAliases != null ? build(hostAliases) : null; } + public io.kubernetes.client.openapi.models.V1HostAlias buildHostAlias(java.lang.Integer index) { return this.hostAliases.get(index).build(); } + public io.kubernetes.client.openapi.models.V1HostAlias buildFirstHostAlias() { return this.hostAliases.get(0).build(); } + public io.kubernetes.client.openapi.models.V1HostAlias buildLastHostAlias() { return this.hostAliases.get(hostAliases.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1HostAlias buildMatchingHostAlias(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1HostAliasBuilder item: hostAliases) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1HostAlias buildMatchingHostAlias( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1HostAliasBuilder item : hostAliases) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingHostAlias(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1HostAliasBuilder item: hostAliases) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingHostAlias( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1HostAliasBuilder item : hostAliases) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withHostAliases(java.util.List hostAliases) { - if (this.hostAliases != null) { _visitables.get("hostAliases").removeAll(this.hostAliases);} - if (hostAliases != null) {this.hostAliases = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1HostAlias item : hostAliases){this.addToHostAliases(item);}} else { this.hostAliases = null;} return (A) this; + + public A withHostAliases( + java.util.List hostAliases) { + if (this.hostAliases != null) { + _visitables.get("hostAliases").removeAll(this.hostAliases); + } + if (hostAliases != null) { + this.hostAliases = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1HostAlias item : hostAliases) { + this.addToHostAliases(item); + } + } else { + this.hostAliases = null; + } + return (A) this; } + public A withHostAliases(io.kubernetes.client.openapi.models.V1HostAlias... hostAliases) { - if (this.hostAliases != null) {this.hostAliases.clear();} - if (hostAliases != null) {for (io.kubernetes.client.openapi.models.V1HostAlias item :hostAliases){ this.addToHostAliases(item);}} return (A) this; + if (this.hostAliases != null) { + this.hostAliases.clear(); + } + if (hostAliases != null) { + for (io.kubernetes.client.openapi.models.V1HostAlias item : hostAliases) { + this.addToHostAliases(item); + } + } + return (A) this; } + public java.lang.Boolean hasHostAliases() { return hostAliases != null && !hostAliases.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested addNewHostAlias() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested + addNewHostAlias() { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.HostAliasesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested addNewHostAliasLike(io.kubernetes.client.openapi.models.V1HostAlias item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.HostAliasesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested + addNewHostAliasLike(io.kubernetes.client.openapi.models.V1HostAlias item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.HostAliasesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested setNewHostAliasLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HostAlias item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.HostAliasesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested + setNewHostAliasLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HostAlias item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.HostAliasesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested editHostAlias(java.lang.Integer index) { - if (hostAliases.size() <= index) throw new RuntimeException("Can't edit hostAliases. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested editHostAlias( + java.lang.Integer index) { + if (hostAliases.size() <= index) + throw new RuntimeException("Can't edit hostAliases. Index exceeds size."); return setNewHostAliasLike(index, buildHostAlias(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested editFirstHostAlias() { - if (hostAliases.size() == 0) throw new RuntimeException("Can't edit first hostAliases. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested + editFirstHostAlias() { + if (hostAliases.size() == 0) + throw new RuntimeException("Can't edit first hostAliases. The list is empty."); return setNewHostAliasLike(0, buildHostAlias(0)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested editLastHostAlias() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested + editLastHostAlias() { int index = hostAliases.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last hostAliases. The list is empty."); return setNewHostAliasLike(index, buildHostAlias(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested editMatchingHostAlias(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested + editMatchingHostAlias( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item);_visitables.get("imagePullSecrets").add(index >= 0 ? index : _visitables.get("imagePullSecrets").size(), builder);this.imagePullSecrets.add(index >= 0 ? index : imagePullSecrets.size(), builder); return (A)this; + + public A addToImagePullSecrets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + if (this.imagePullSecrets == null) { + this.imagePullSecrets = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder>(); + } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); + _visitables + .get("imagePullSecrets") + .add(index >= 0 ? index : _visitables.get("imagePullSecrets").size(), builder); + this.imagePullSecrets.add(index >= 0 ? index : imagePullSecrets.size(), builder); + return (A) this; } - public A setToImagePullSecrets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - if (this.imagePullSecrets == null) {this.imagePullSecrets = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); - if (index < 0 || index >= _visitables.get("imagePullSecrets").size()) { _visitables.get("imagePullSecrets").add(builder); } else { _visitables.get("imagePullSecrets").set(index, builder);} - if (index < 0 || index >= imagePullSecrets.size()) { imagePullSecrets.add(builder); } else { imagePullSecrets.set(index, builder);} - return (A)this; + + public A setToImagePullSecrets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + if (this.imagePullSecrets == null) { + this.imagePullSecrets = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder>(); + } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); + if (index < 0 || index >= _visitables.get("imagePullSecrets").size()) { + _visitables.get("imagePullSecrets").add(builder); + } else { + _visitables.get("imagePullSecrets").set(index, builder); + } + if (index < 0 || index >= imagePullSecrets.size()) { + imagePullSecrets.add(builder); + } else { + imagePullSecrets.set(index, builder); + } + return (A) this; } - public A addToImagePullSecrets(io.kubernetes.client.openapi.models.V1LocalObjectReference... items) { - if (this.imagePullSecrets == null) {this.imagePullSecrets = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) {io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item);_visitables.get("imagePullSecrets").add(builder);this.imagePullSecrets.add(builder);} return (A)this; + + public A addToImagePullSecrets( + io.kubernetes.client.openapi.models.V1LocalObjectReference... items) { + if (this.imagePullSecrets == null) { + this.imagePullSecrets = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) { + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); + _visitables.get("imagePullSecrets").add(builder); + this.imagePullSecrets.add(builder); + } + return (A) this; } - public A addAllToImagePullSecrets(java.util.Collection items) { - if (this.imagePullSecrets == null) {this.imagePullSecrets = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) {io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item);_visitables.get("imagePullSecrets").add(builder);this.imagePullSecrets.add(builder);} return (A)this; + + public A addAllToImagePullSecrets( + java.util.Collection items) { + if (this.imagePullSecrets == null) { + this.imagePullSecrets = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) { + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); + _visitables.get("imagePullSecrets").add(builder); + this.imagePullSecrets.add(builder); + } + return (A) this; } - public A removeFromImagePullSecrets(io.kubernetes.client.openapi.models.V1LocalObjectReference... items) { - for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) {io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item);_visitables.get("imagePullSecrets").remove(builder);if (this.imagePullSecrets != null) {this.imagePullSecrets.remove(builder);}} return (A)this; + + public A removeFromImagePullSecrets( + io.kubernetes.client.openapi.models.V1LocalObjectReference... items) { + for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) { + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); + _visitables.get("imagePullSecrets").remove(builder); + if (this.imagePullSecrets != null) { + this.imagePullSecrets.remove(builder); + } + } + return (A) this; } - public A removeAllFromImagePullSecrets(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) {io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item);_visitables.get("imagePullSecrets").remove(builder);if (this.imagePullSecrets != null) {this.imagePullSecrets.remove(builder);}} return (A)this; + + public A removeAllFromImagePullSecrets( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) { + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); + _visitables.get("imagePullSecrets").remove(builder); + if (this.imagePullSecrets != null) { + this.imagePullSecrets.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromImagePullSecrets(java.util.function.Predicate predicate) { + + public A removeMatchingFromImagePullSecrets( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate) { if (imagePullSecrets == null) return (A) this; - final Iterator each = imagePullSecrets.iterator(); + final Iterator each = + imagePullSecrets.iterator(); final List visitables = _visitables.get("imagePullSecrets"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = each.next(); @@ -636,104 +1202,251 @@ public A removeMatchingFromImagePullSecrets(java.util.function.Predicate getImagePullSecrets() { + public java.util.List + getImagePullSecrets() { return imagePullSecrets != null ? build(imagePullSecrets) : null; } - public java.util.List buildImagePullSecrets() { + + public java.util.List + buildImagePullSecrets() { return imagePullSecrets != null ? build(imagePullSecrets) : null; } - public io.kubernetes.client.openapi.models.V1LocalObjectReference buildImagePullSecret(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildImagePullSecret( + java.lang.Integer index) { return this.imagePullSecrets.get(index).build(); } + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildFirstImagePullSecret() { return this.imagePullSecrets.get(0).build(); } + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildLastImagePullSecret() { return this.imagePullSecrets.get(imagePullSecrets.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1LocalObjectReference buildMatchingImagePullSecret(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder item: imagePullSecrets) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildMatchingImagePullSecret( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder item : + imagePullSecrets) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingImagePullSecret(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder item: imagePullSecrets) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingImagePullSecret( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder item : + imagePullSecrets) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withImagePullSecrets(java.util.List imagePullSecrets) { - if (this.imagePullSecrets != null) { _visitables.get("imagePullSecrets").removeAll(this.imagePullSecrets);} - if (imagePullSecrets != null) {this.imagePullSecrets = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : imagePullSecrets){this.addToImagePullSecrets(item);}} else { this.imagePullSecrets = null;} return (A) this; + + public A withImagePullSecrets( + java.util.List imagePullSecrets) { + if (this.imagePullSecrets != null) { + _visitables.get("imagePullSecrets").removeAll(this.imagePullSecrets); + } + if (imagePullSecrets != null) { + this.imagePullSecrets = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : imagePullSecrets) { + this.addToImagePullSecrets(item); + } + } else { + this.imagePullSecrets = null; + } + return (A) this; } - public A withImagePullSecrets(io.kubernetes.client.openapi.models.V1LocalObjectReference... imagePullSecrets) { - if (this.imagePullSecrets != null) {this.imagePullSecrets.clear();} - if (imagePullSecrets != null) {for (io.kubernetes.client.openapi.models.V1LocalObjectReference item :imagePullSecrets){ this.addToImagePullSecrets(item);}} return (A) this; + + public A withImagePullSecrets( + io.kubernetes.client.openapi.models.V1LocalObjectReference... imagePullSecrets) { + if (this.imagePullSecrets != null) { + this.imagePullSecrets.clear(); + } + if (imagePullSecrets != null) { + for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : imagePullSecrets) { + this.addToImagePullSecrets(item); + } + } + return (A) this; } + public java.lang.Boolean hasImagePullSecrets() { return imagePullSecrets != null && !imagePullSecrets.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested addNewImagePullSecret() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + addNewImagePullSecret() { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ImagePullSecretsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested addNewImagePullSecretLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ImagePullSecretsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + addNewImagePullSecretLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ImagePullSecretsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested setNewImagePullSecretLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ImagePullSecretsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + setNewImagePullSecretLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ImagePullSecretsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested editImagePullSecret(java.lang.Integer index) { - if (imagePullSecrets.size() <= index) throw new RuntimeException("Can't edit imagePullSecrets. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + editImagePullSecret(java.lang.Integer index) { + if (imagePullSecrets.size() <= index) + throw new RuntimeException("Can't edit imagePullSecrets. Index exceeds size."); return setNewImagePullSecretLike(index, buildImagePullSecret(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested editFirstImagePullSecret() { - if (imagePullSecrets.size() == 0) throw new RuntimeException("Can't edit first imagePullSecrets. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + editFirstImagePullSecret() { + if (imagePullSecrets.size() == 0) + throw new RuntimeException("Can't edit first imagePullSecrets. The list is empty."); return setNewImagePullSecretLike(0, buildImagePullSecret(0)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested editLastImagePullSecret() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + editLastImagePullSecret() { int index = imagePullSecrets.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last imagePullSecrets. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last imagePullSecrets. The list is empty."); return setNewImagePullSecretLike(index, buildImagePullSecret(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested editMatchingImagePullSecret(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested + editMatchingImagePullSecret( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1ContainerBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(item);_visitables.get("initContainers").add(index >= 0 ? index : _visitables.get("initContainers").size(), builder);this.initContainers.add(index >= 0 ? index : initContainers.size(), builder); return (A)this; + + public A addToInitContainers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item) { + if (this.initContainers == null) { + this.initContainers = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); + _visitables + .get("initContainers") + .add(index >= 0 ? index : _visitables.get("initContainers").size(), builder); + this.initContainers.add(index >= 0 ? index : initContainers.size(), builder); + return (A) this; } - public A setToInitContainers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Container item) { - if (this.initContainers == null) {this.initContainers = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ContainerBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); - if (index < 0 || index >= _visitables.get("initContainers").size()) { _visitables.get("initContainers").add(builder); } else { _visitables.get("initContainers").set(index, builder);} - if (index < 0 || index >= initContainers.size()) { initContainers.add(builder); } else { initContainers.set(index, builder);} - return (A)this; + + public A setToInitContainers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item) { + if (this.initContainers == null) { + this.initContainers = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); + if (index < 0 || index >= _visitables.get("initContainers").size()) { + _visitables.get("initContainers").add(builder); + } else { + _visitables.get("initContainers").set(index, builder); + } + if (index < 0 || index >= initContainers.size()) { + initContainers.add(builder); + } else { + initContainers.set(index, builder); + } + return (A) this; } + public A addToInitContainers(io.kubernetes.client.openapi.models.V1Container... items) { - if (this.initContainers == null) {this.initContainers = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Container item : items) {io.kubernetes.client.openapi.models.V1ContainerBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(item);_visitables.get("initContainers").add(builder);this.initContainers.add(builder);} return (A)this; + if (this.initContainers == null) { + this.initContainers = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Container item : items) { + io.kubernetes.client.openapi.models.V1ContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); + _visitables.get("initContainers").add(builder); + this.initContainers.add(builder); + } + return (A) this; } - public A addAllToInitContainers(java.util.Collection items) { - if (this.initContainers == null) {this.initContainers = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Container item : items) {io.kubernetes.client.openapi.models.V1ContainerBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(item);_visitables.get("initContainers").add(builder);this.initContainers.add(builder);} return (A)this; + + public A addAllToInitContainers( + java.util.Collection items) { + if (this.initContainers == null) { + this.initContainers = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Container item : items) { + io.kubernetes.client.openapi.models.V1ContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); + _visitables.get("initContainers").add(builder); + this.initContainers.add(builder); + } + return (A) this; } + public A removeFromInitContainers(io.kubernetes.client.openapi.models.V1Container... items) { - for (io.kubernetes.client.openapi.models.V1Container item : items) {io.kubernetes.client.openapi.models.V1ContainerBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(item);_visitables.get("initContainers").remove(builder);if (this.initContainers != null) {this.initContainers.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Container item : items) { + io.kubernetes.client.openapi.models.V1ContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); + _visitables.get("initContainers").remove(builder); + if (this.initContainers != null) { + this.initContainers.remove(builder); + } + } + return (A) this; } - public A removeAllFromInitContainers(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Container item : items) {io.kubernetes.client.openapi.models.V1ContainerBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(item);_visitables.get("initContainers").remove(builder);if (this.initContainers != null) {this.initContainers.remove(builder);}} return (A)this; + + public A removeAllFromInitContainers( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Container item : items) { + io.kubernetes.client.openapi.models.V1ContainerBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerBuilder(item); + _visitables.get("initContainers").remove(builder); + if (this.initContainers != null) { + this.initContainers.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromInitContainers(java.util.function.Predicate predicate) { + + public A removeMatchingFromInitContainers( + java.util.function.Predicate + predicate) { if (initContainers == null) return (A) this; - final Iterator each = initContainers.iterator(); + final Iterator each = + initContainers.iterator(); final List visitables = _visitables.get("initContainers"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ContainerBuilder builder = each.next(); @@ -742,248 +1455,489 @@ public A removeMatchingFromInitContainers(java.util.function.Predicate getInitContainers() { return initContainers != null ? build(initContainers) : null; } + public java.util.List buildInitContainers() { return initContainers != null ? build(initContainers) : null; } - public io.kubernetes.client.openapi.models.V1Container buildInitContainer(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1Container buildInitContainer( + java.lang.Integer index) { return this.initContainers.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Container buildFirstInitContainer() { return this.initContainers.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Container buildLastInitContainer() { return this.initContainers.get(initContainers.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Container buildMatchingInitContainer(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerBuilder item: initContainers) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Container buildMatchingInitContainer( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerBuilder item : initContainers) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingInitContainer(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerBuilder item: initContainers) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingInitContainer( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerBuilder item : initContainers) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withInitContainers(java.util.List initContainers) { - if (this.initContainers != null) { _visitables.get("initContainers").removeAll(this.initContainers);} - if (initContainers != null) {this.initContainers = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Container item : initContainers){this.addToInitContainers(item);}} else { this.initContainers = null;} return (A) this; + + public A withInitContainers( + java.util.List initContainers) { + if (this.initContainers != null) { + _visitables.get("initContainers").removeAll(this.initContainers); + } + if (initContainers != null) { + this.initContainers = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Container item : initContainers) { + this.addToInitContainers(item); + } + } else { + this.initContainers = null; + } + return (A) this; } + public A withInitContainers(io.kubernetes.client.openapi.models.V1Container... initContainers) { - if (this.initContainers != null) {this.initContainers.clear();} - if (initContainers != null) {for (io.kubernetes.client.openapi.models.V1Container item :initContainers){ this.addToInitContainers(item);}} return (A) this; + if (this.initContainers != null) { + this.initContainers.clear(); + } + if (initContainers != null) { + for (io.kubernetes.client.openapi.models.V1Container item : initContainers) { + this.addToInitContainers(item); + } + } + return (A) this; } + public java.lang.Boolean hasInitContainers() { return initContainers != null && !initContainers.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested addNewInitContainer() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + addNewInitContainer() { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.InitContainersNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested addNewInitContainerLike(io.kubernetes.client.openapi.models.V1Container item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.InitContainersNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + addNewInitContainerLike(io.kubernetes.client.openapi.models.V1Container item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.InitContainersNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested setNewInitContainerLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Container item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.InitContainersNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + setNewInitContainerLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.InitContainersNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested editInitContainer(java.lang.Integer index) { - if (initContainers.size() <= index) throw new RuntimeException("Can't edit initContainers. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + editInitContainer(java.lang.Integer index) { + if (initContainers.size() <= index) + throw new RuntimeException("Can't edit initContainers. Index exceeds size."); return setNewInitContainerLike(index, buildInitContainer(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested editFirstInitContainer() { - if (initContainers.size() == 0) throw new RuntimeException("Can't edit first initContainers. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + editFirstInitContainer() { + if (initContainers.size() == 0) + throw new RuntimeException("Can't edit first initContainers. The list is empty."); return setNewInitContainerLike(0, buildInitContainer(0)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested editLastInitContainer() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + editLastInitContainer() { int index = initContainers.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last initContainers. The list is empty."); return setNewInitContainerLike(index, buildInitContainer(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested editMatchingInitContainer(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested + editMatchingInitContainer( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i map) { - if(this.nodeSelector == null && map != null) { this.nodeSelector = new java.util.LinkedHashMap(); } - if(map != null) { this.nodeSelector.putAll(map);} return (A)this; + + public A addToNodeSelector(java.util.Map map) { + if (this.nodeSelector == null && map != null) { + this.nodeSelector = new java.util.LinkedHashMap(); + } + if (map != null) { + this.nodeSelector.putAll(map); + } + return (A) this; } + public A removeFromNodeSelector(java.lang.String key) { - if(this.nodeSelector == null) { return (A) this; } - if(key != null && this.nodeSelector != null) {this.nodeSelector.remove(key);} return (A)this; + if (this.nodeSelector == null) { + return (A) this; + } + if (key != null && this.nodeSelector != null) { + this.nodeSelector.remove(key); + } + return (A) this; } - public A removeFromNodeSelector(java.util.Map map) { - if(this.nodeSelector == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.nodeSelector != null){this.nodeSelector.remove(key);}}} return (A)this; + + public A removeFromNodeSelector(java.util.Map map) { + if (this.nodeSelector == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.nodeSelector != null) { + this.nodeSelector.remove(key); + } + } + } + return (A) this; } - public java.util.Map getNodeSelector() { + + public java.util.Map getNodeSelector() { return this.nodeSelector; } - public A withNodeSelector(java.util.Map nodeSelector) { - if (nodeSelector == null) { this.nodeSelector = null;} else {this.nodeSelector = new java.util.LinkedHashMap(nodeSelector);} return (A) this; + + public A withNodeSelector(java.util.Map nodeSelector) { + if (nodeSelector == null) { + this.nodeSelector = null; + } else { + this.nodeSelector = new java.util.LinkedHashMap(nodeSelector); + } + return (A) this; } + public java.lang.Boolean hasNodeSelector() { return this.nodeSelector != null; } - + /** * This method has been deprecated, please use method buildOs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodOS getOs() { - return this.os!=null ?this.os.build():null; + return this.os != null ? this.os.build() : null; } + public io.kubernetes.client.openapi.models.V1PodOS buildOs() { - return this.os!=null ?this.os.build():null; + return this.os != null ? this.os.build() : null; } + public A withOs(io.kubernetes.client.openapi.models.V1PodOS os) { _visitables.get("os").remove(this.os); - if (os!=null){ this.os= new io.kubernetes.client.openapi.models.V1PodOSBuilder(os); _visitables.get("os").add(this.os);} return (A) this; + if (os != null) { + this.os = new io.kubernetes.client.openapi.models.V1PodOSBuilder(os); + _visitables.get("os").add(this.os); + } + return (A) this; } + public java.lang.Boolean hasOs() { return this.os != null; } + public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested withNewOs() { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.OsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested withNewOsLike(io.kubernetes.client.openapi.models.V1PodOS item) { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested withNewOsLike( + io.kubernetes.client.openapi.models.V1PodOS item) { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.OsNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested editOs() { return withNewOsLike(getOs()); } + public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested editOrNewOs() { - return withNewOsLike(getOs() != null ? getOs(): new io.kubernetes.client.openapi.models.V1PodOSBuilder().build()); + return withNewOsLike( + getOs() != null + ? getOs() + : new io.kubernetes.client.openapi.models.V1PodOSBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested editOrNewOsLike(io.kubernetes.client.openapi.models.V1PodOS item) { - return withNewOsLike(getOs() != null ? getOs(): item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested editOrNewOsLike( + io.kubernetes.client.openapi.models.V1PodOS item) { + return withNewOsLike(getOs() != null ? getOs() : item); } - public A addToOverhead(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.overhead == null && key != null && value != null) { this.overhead = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.overhead.put(key, value);} return (A)this; + + public A addToOverhead(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.overhead == null && key != null && value != null) { + this.overhead = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.overhead.put(key, value); + } + return (A) this; } - public A addToOverhead(java.util.Map map) { - if(this.overhead == null && map != null) { this.overhead = new java.util.LinkedHashMap(); } - if(map != null) { this.overhead.putAll(map);} return (A)this; + + public A addToOverhead( + java.util.Map map) { + if (this.overhead == null && map != null) { + this.overhead = new java.util.LinkedHashMap(); + } + if (map != null) { + this.overhead.putAll(map); + } + return (A) this; } + public A removeFromOverhead(java.lang.String key) { - if(this.overhead == null) { return (A) this; } - if(key != null && this.overhead != null) {this.overhead.remove(key);} return (A)this; + if (this.overhead == null) { + return (A) this; + } + if (key != null && this.overhead != null) { + this.overhead.remove(key); + } + return (A) this; } - public A removeFromOverhead(java.util.Map map) { - if(this.overhead == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.overhead != null){this.overhead.remove(key);}}} return (A)this; + + public A removeFromOverhead( + java.util.Map map) { + if (this.overhead == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.overhead != null) { + this.overhead.remove(key); + } + } + } + return (A) this; } - public java.util.Map getOverhead() { + + public java.util.Map getOverhead() { return this.overhead; } - public A withOverhead(java.util.Map overhead) { - if (overhead == null) { this.overhead = null;} else {this.overhead = new java.util.LinkedHashMap(overhead);} return (A) this; + + public A withOverhead( + java.util.Map overhead) { + if (overhead == null) { + this.overhead = null; + } else { + this.overhead = new java.util.LinkedHashMap(overhead); + } + return (A) this; } + public java.lang.Boolean hasOverhead() { return this.overhead != null; } + public java.lang.String getPreemptionPolicy() { return this.preemptionPolicy; } + public A withPreemptionPolicy(java.lang.String preemptionPolicy) { - this.preemptionPolicy=preemptionPolicy; return (A) this; + this.preemptionPolicy = preemptionPolicy; + return (A) this; } + public java.lang.Boolean hasPreemptionPolicy() { return this.preemptionPolicy != null; } - - /** - * Method is deprecated. use withPreemptionPolicy instead. - */ + + /** Method is deprecated. use withPreemptionPolicy instead. */ @java.lang.Deprecated public A withNewPreemptionPolicy(java.lang.String original) { - return (A)withPreemptionPolicy(new String(original)); + return (A) withPreemptionPolicy(new String(original)); } + public java.lang.Integer getPriority() { return this.priority; } + public A withPriority(java.lang.Integer priority) { - this.priority=priority; return (A) this; + this.priority = priority; + return (A) this; } + public java.lang.Boolean hasPriority() { return this.priority != null; } + public java.lang.String getPriorityClassName() { return this.priorityClassName; } + public A withPriorityClassName(java.lang.String priorityClassName) { - this.priorityClassName=priorityClassName; return (A) this; + this.priorityClassName = priorityClassName; + return (A) this; } + public java.lang.Boolean hasPriorityClassName() { return this.priorityClassName != null; } - - /** - * Method is deprecated. use withPriorityClassName instead. - */ + + /** Method is deprecated. use withPriorityClassName instead. */ @java.lang.Deprecated public A withNewPriorityClassName(java.lang.String original) { - return (A)withPriorityClassName(new String(original)); + return (A) withPriorityClassName(new String(original)); } - public A addToReadinessGates(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodReadinessGate item) { - if (this.readinessGates == null) {this.readinessGates = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder = new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(item);_visitables.get("readinessGates").add(index >= 0 ? index : _visitables.get("readinessGates").size(), builder);this.readinessGates.add(index >= 0 ? index : readinessGates.size(), builder); return (A)this; + + public A addToReadinessGates( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodReadinessGate item) { + if (this.readinessGates == null) { + this.readinessGates = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder = + new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(item); + _visitables + .get("readinessGates") + .add(index >= 0 ? index : _visitables.get("readinessGates").size(), builder); + this.readinessGates.add(index >= 0 ? index : readinessGates.size(), builder); + return (A) this; } - public A setToReadinessGates(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodReadinessGate item) { - if (this.readinessGates == null) {this.readinessGates = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder = new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(item); - if (index < 0 || index >= _visitables.get("readinessGates").size()) { _visitables.get("readinessGates").add(builder); } else { _visitables.get("readinessGates").set(index, builder);} - if (index < 0 || index >= readinessGates.size()) { readinessGates.add(builder); } else { readinessGates.set(index, builder);} - return (A)this; + + public A setToReadinessGates( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodReadinessGate item) { + if (this.readinessGates == null) { + this.readinessGates = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder = + new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(item); + if (index < 0 || index >= _visitables.get("readinessGates").size()) { + _visitables.get("readinessGates").add(builder); + } else { + _visitables.get("readinessGates").set(index, builder); + } + if (index < 0 || index >= readinessGates.size()) { + readinessGates.add(builder); + } else { + readinessGates.set(index, builder); + } + return (A) this; } + public A addToReadinessGates(io.kubernetes.client.openapi.models.V1PodReadinessGate... items) { - if (this.readinessGates == null) {this.readinessGates = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodReadinessGate item : items) {io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder = new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(item);_visitables.get("readinessGates").add(builder);this.readinessGates.add(builder);} return (A)this; + if (this.readinessGates == null) { + this.readinessGates = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PodReadinessGate item : items) { + io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder = + new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(item); + _visitables.get("readinessGates").add(builder); + this.readinessGates.add(builder); + } + return (A) this; } - public A addAllToReadinessGates(java.util.Collection items) { - if (this.readinessGates == null) {this.readinessGates = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodReadinessGate item : items) {io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder = new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(item);_visitables.get("readinessGates").add(builder);this.readinessGates.add(builder);} return (A)this; + + public A addAllToReadinessGates( + java.util.Collection items) { + if (this.readinessGates == null) { + this.readinessGates = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PodReadinessGate item : items) { + io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder = + new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(item); + _visitables.get("readinessGates").add(builder); + this.readinessGates.add(builder); + } + return (A) this; } - public A removeFromReadinessGates(io.kubernetes.client.openapi.models.V1PodReadinessGate... items) { - for (io.kubernetes.client.openapi.models.V1PodReadinessGate item : items) {io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder = new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(item);_visitables.get("readinessGates").remove(builder);if (this.readinessGates != null) {this.readinessGates.remove(builder);}} return (A)this; + + public A removeFromReadinessGates( + io.kubernetes.client.openapi.models.V1PodReadinessGate... items) { + for (io.kubernetes.client.openapi.models.V1PodReadinessGate item : items) { + io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder = + new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(item); + _visitables.get("readinessGates").remove(builder); + if (this.readinessGates != null) { + this.readinessGates.remove(builder); + } + } + return (A) this; } - public A removeAllFromReadinessGates(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PodReadinessGate item : items) {io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder = new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(item);_visitables.get("readinessGates").remove(builder);if (this.readinessGates != null) {this.readinessGates.remove(builder);}} return (A)this; + + public A removeAllFromReadinessGates( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PodReadinessGate item : items) { + io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder = + new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(item); + _visitables.get("readinessGates").remove(builder); + if (this.readinessGates != null) { + this.readinessGates.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromReadinessGates(java.util.function.Predicate predicate) { + + public A removeMatchingFromReadinessGates( + java.util.function.Predicate + predicate) { if (readinessGates == null) return (A) this; - final Iterator each = readinessGates.iterator(); + final Iterator each = + readinessGates.iterator(); final List visitables = _visitables.get("readinessGates"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder = each.next(); @@ -992,259 +1946,451 @@ public A removeMatchingFromReadinessGates(java.util.function.Predicate getReadinessGates() { + public java.util.List + getReadinessGates() { return readinessGates != null ? build(readinessGates) : null; } - public java.util.List buildReadinessGates() { + + public java.util.List + buildReadinessGates() { return readinessGates != null ? build(readinessGates) : null; } - public io.kubernetes.client.openapi.models.V1PodReadinessGate buildReadinessGate(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PodReadinessGate buildReadinessGate( + java.lang.Integer index) { return this.readinessGates.get(index).build(); } + public io.kubernetes.client.openapi.models.V1PodReadinessGate buildFirstReadinessGate() { return this.readinessGates.get(0).build(); } + public io.kubernetes.client.openapi.models.V1PodReadinessGate buildLastReadinessGate() { return this.readinessGates.get(readinessGates.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PodReadinessGate buildMatchingReadinessGate(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder item: readinessGates) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PodReadinessGate buildMatchingReadinessGate( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder item : readinessGates) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingReadinessGate(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder item: readinessGates) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingReadinessGate( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder item : readinessGates) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withReadinessGates(java.util.List readinessGates) { - if (this.readinessGates != null) { _visitables.get("readinessGates").removeAll(this.readinessGates);} - if (readinessGates != null) {this.readinessGates = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PodReadinessGate item : readinessGates){this.addToReadinessGates(item);}} else { this.readinessGates = null;} return (A) this; + + public A withReadinessGates( + java.util.List readinessGates) { + if (this.readinessGates != null) { + _visitables.get("readinessGates").removeAll(this.readinessGates); + } + if (readinessGates != null) { + this.readinessGates = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PodReadinessGate item : readinessGates) { + this.addToReadinessGates(item); + } + } else { + this.readinessGates = null; + } + return (A) this; } - public A withReadinessGates(io.kubernetes.client.openapi.models.V1PodReadinessGate... readinessGates) { - if (this.readinessGates != null) {this.readinessGates.clear();} - if (readinessGates != null) {for (io.kubernetes.client.openapi.models.V1PodReadinessGate item :readinessGates){ this.addToReadinessGates(item);}} return (A) this; + + public A withReadinessGates( + io.kubernetes.client.openapi.models.V1PodReadinessGate... readinessGates) { + if (this.readinessGates != null) { + this.readinessGates.clear(); + } + if (readinessGates != null) { + for (io.kubernetes.client.openapi.models.V1PodReadinessGate item : readinessGates) { + this.addToReadinessGates(item); + } + } + return (A) this; } + public java.lang.Boolean hasReadinessGates() { return readinessGates != null && !readinessGates.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested addNewReadinessGate() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + addNewReadinessGate() { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ReadinessGatesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested addNewReadinessGateLike(io.kubernetes.client.openapi.models.V1PodReadinessGate item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ReadinessGatesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + addNewReadinessGateLike(io.kubernetes.client.openapi.models.V1PodReadinessGate item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ReadinessGatesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested setNewReadinessGateLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodReadinessGate item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ReadinessGatesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + setNewReadinessGateLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodReadinessGate item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.ReadinessGatesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested editReadinessGate(java.lang.Integer index) { - if (readinessGates.size() <= index) throw new RuntimeException("Can't edit readinessGates. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + editReadinessGate(java.lang.Integer index) { + if (readinessGates.size() <= index) + throw new RuntimeException("Can't edit readinessGates. Index exceeds size."); return setNewReadinessGateLike(index, buildReadinessGate(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested editFirstReadinessGate() { - if (readinessGates.size() == 0) throw new RuntimeException("Can't edit first readinessGates. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + editFirstReadinessGate() { + if (readinessGates.size() == 0) + throw new RuntimeException("Can't edit first readinessGates. The list is empty."); return setNewReadinessGateLike(0, buildReadinessGate(0)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested editLastReadinessGate() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + editLastReadinessGate() { int index = readinessGates.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last readinessGates. The list is empty."); return setNewReadinessGateLike(index, buildReadinessGate(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested editMatchingReadinessGate(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested + editMatchingReadinessGate( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder> + predicate) { int index = -1; - for (int i=0;i withNewSecurityContext() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested + withNewSecurityContext() { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.SecurityContextNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested withNewSecurityContextLike(io.kubernetes.client.openapi.models.V1PodSecurityContext item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.SecurityContextNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested + withNewSecurityContextLike(io.kubernetes.client.openapi.models.V1PodSecurityContext item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.SecurityContextNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested editSecurityContext() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested + editSecurityContext() { return withNewSecurityContextLike(getSecurityContext()); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested editOrNewSecurityContext() { - return withNewSecurityContextLike(getSecurityContext() != null ? getSecurityContext(): new io.kubernetes.client.openapi.models.V1PodSecurityContextBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested + editOrNewSecurityContext() { + return withNewSecurityContextLike( + getSecurityContext() != null + ? getSecurityContext() + : new io.kubernetes.client.openapi.models.V1PodSecurityContextBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested editOrNewSecurityContextLike(io.kubernetes.client.openapi.models.V1PodSecurityContext item) { - return withNewSecurityContextLike(getSecurityContext() != null ? getSecurityContext(): item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested + editOrNewSecurityContextLike(io.kubernetes.client.openapi.models.V1PodSecurityContext item) { + return withNewSecurityContextLike(getSecurityContext() != null ? getSecurityContext() : item); } + public java.lang.String getServiceAccount() { return this.serviceAccount; } + public A withServiceAccount(java.lang.String serviceAccount) { - this.serviceAccount=serviceAccount; return (A) this; + this.serviceAccount = serviceAccount; + return (A) this; } + public java.lang.Boolean hasServiceAccount() { return this.serviceAccount != null; } - - /** - * Method is deprecated. use withServiceAccount instead. - */ + + /** Method is deprecated. use withServiceAccount instead. */ @java.lang.Deprecated public A withNewServiceAccount(java.lang.String original) { - return (A)withServiceAccount(new String(original)); + return (A) withServiceAccount(new String(original)); } + public java.lang.String getServiceAccountName() { return this.serviceAccountName; } + public A withServiceAccountName(java.lang.String serviceAccountName) { - this.serviceAccountName=serviceAccountName; return (A) this; + this.serviceAccountName = serviceAccountName; + return (A) this; } + public java.lang.Boolean hasServiceAccountName() { return this.serviceAccountName != null; } - - /** - * Method is deprecated. use withServiceAccountName instead. - */ + + /** Method is deprecated. use withServiceAccountName instead. */ @java.lang.Deprecated public A withNewServiceAccountName(java.lang.String original) { - return (A)withServiceAccountName(new String(original)); + return (A) withServiceAccountName(new String(original)); } + public java.lang.Boolean getSetHostnameAsFQDN() { return this.setHostnameAsFQDN; } + public A withSetHostnameAsFQDN(java.lang.Boolean setHostnameAsFQDN) { - this.setHostnameAsFQDN=setHostnameAsFQDN; return (A) this; + this.setHostnameAsFQDN = setHostnameAsFQDN; + return (A) this; } + public java.lang.Boolean hasSetHostnameAsFQDN() { return this.setHostnameAsFQDN != null; } + public java.lang.Boolean getShareProcessNamespace() { return this.shareProcessNamespace; } + public A withShareProcessNamespace(java.lang.Boolean shareProcessNamespace) { - this.shareProcessNamespace=shareProcessNamespace; return (A) this; + this.shareProcessNamespace = shareProcessNamespace; + return (A) this; } + public java.lang.Boolean hasShareProcessNamespace() { return this.shareProcessNamespace != null; } + public java.lang.String getSubdomain() { return this.subdomain; } + public A withSubdomain(java.lang.String subdomain) { - this.subdomain=subdomain; return (A) this; + this.subdomain = subdomain; + return (A) this; } + public java.lang.Boolean hasSubdomain() { return this.subdomain != null; } - - /** - * Method is deprecated. use withSubdomain instead. - */ + + /** Method is deprecated. use withSubdomain instead. */ @java.lang.Deprecated public A withNewSubdomain(java.lang.String original) { - return (A)withSubdomain(new String(original)); + return (A) withSubdomain(new String(original)); } + public java.lang.Long getTerminationGracePeriodSeconds() { return this.terminationGracePeriodSeconds; } + public A withTerminationGracePeriodSeconds(java.lang.Long terminationGracePeriodSeconds) { - this.terminationGracePeriodSeconds=terminationGracePeriodSeconds; return (A) this; + this.terminationGracePeriodSeconds = terminationGracePeriodSeconds; + return (A) this; } + public java.lang.Boolean hasTerminationGracePeriodSeconds() { return this.terminationGracePeriodSeconds != null; } - public A addToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").add(index >= 0 ? index : _visitables.get("tolerations").size(), builder);this.tolerations.add(index >= 0 ? index : tolerations.size(), builder); return (A)this; + + public A addToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables + .get("tolerations") + .add(index >= 0 ? index : _visitables.get("tolerations").size(), builder); + this.tolerations.add(index >= 0 ? index : tolerations.size(), builder); + return (A) this; } - public A setToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); - if (index < 0 || index >= _visitables.get("tolerations").size()) { _visitables.get("tolerations").add(builder); } else { _visitables.get("tolerations").set(index, builder);} - if (index < 0 || index >= tolerations.size()) { tolerations.add(builder); } else { tolerations.set(index, builder);} - return (A)this; + + public A setToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + if (index < 0 || index >= _visitables.get("tolerations").size()) { + _visitables.get("tolerations").add(builder); + } else { + _visitables.get("tolerations").set(index, builder); + } + if (index < 0 || index >= tolerations.size()) { + tolerations.add(builder); + } else { + tolerations.set(index, builder); + } + return (A) this; } + public A addToTolerations(io.kubernetes.client.openapi.models.V1Toleration... items) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").add(builder);this.tolerations.add(builder);} return (A)this; + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").add(builder); + this.tolerations.add(builder); + } + return (A) this; } - public A addAllToTolerations(java.util.Collection items) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").add(builder);this.tolerations.add(builder);} return (A)this; + + public A addAllToTolerations( + java.util.Collection items) { + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").add(builder); + this.tolerations.add(builder); + } + return (A) this; } + public A removeFromTolerations(io.kubernetes.client.openapi.models.V1Toleration... items) { - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").remove(builder);if (this.tolerations != null) {this.tolerations.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").remove(builder); + if (this.tolerations != null) { + this.tolerations.remove(builder); + } + } + return (A) this; } - public A removeAllFromTolerations(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").remove(builder);if (this.tolerations != null) {this.tolerations.remove(builder);}} return (A)this; + + public A removeAllFromTolerations( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").remove(builder); + if (this.tolerations != null) { + this.tolerations.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromTolerations(java.util.function.Predicate predicate) { + + public A removeMatchingFromTolerations( + java.util.function.Predicate + predicate) { if (tolerations == null) return (A) this; - final Iterator each = tolerations.iterator(); + final Iterator each = + tolerations.iterator(); final List visitables = _visitables.get("tolerations"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1TolerationBuilder builder = each.next(); @@ -1253,104 +2399,249 @@ public A removeMatchingFromTolerations(java.util.function.Predicate getTolerations() { return tolerations != null ? build(tolerations) : null; } + public java.util.List buildTolerations() { return tolerations != null ? build(tolerations) : null; } + public io.kubernetes.client.openapi.models.V1Toleration buildToleration(java.lang.Integer index) { return this.tolerations.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Toleration buildFirstToleration() { return this.tolerations.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Toleration buildLastToleration() { return this.tolerations.get(tolerations.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TolerationBuilder item: tolerations) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1TolerationBuilder item : tolerations) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingToleration(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TolerationBuilder item: tolerations) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingToleration( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1TolerationBuilder item : tolerations) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withTolerations(java.util.List tolerations) { - if (this.tolerations != null) { _visitables.get("tolerations").removeAll(this.tolerations);} - if (tolerations != null) {this.tolerations = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Toleration item : tolerations){this.addToTolerations(item);}} else { this.tolerations = null;} return (A) this; + + public A withTolerations( + java.util.List tolerations) { + if (this.tolerations != null) { + _visitables.get("tolerations").removeAll(this.tolerations); + } + if (tolerations != null) { + this.tolerations = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Toleration item : tolerations) { + this.addToTolerations(item); + } + } else { + this.tolerations = null; + } + return (A) this; } + public A withTolerations(io.kubernetes.client.openapi.models.V1Toleration... tolerations) { - if (this.tolerations != null) {this.tolerations.clear();} - if (tolerations != null) {for (io.kubernetes.client.openapi.models.V1Toleration item :tolerations){ this.addToTolerations(item);}} return (A) this; + if (this.tolerations != null) { + this.tolerations.clear(); + } + if (tolerations != null) { + for (io.kubernetes.client.openapi.models.V1Toleration item : tolerations) { + this.addToTolerations(item); + } + } + return (A) this; } + public java.lang.Boolean hasTolerations() { return tolerations != null && !tolerations.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested addNewToleration() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested + addNewToleration() { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.TolerationsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.TolerationsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested + addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.TolerationsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested setNewTolerationLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.TolerationsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested + setNewTolerationLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.TolerationsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested editToleration(java.lang.Integer index) { - if (tolerations.size() <= index) throw new RuntimeException("Can't edit tolerations. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested editToleration( + java.lang.Integer index) { + if (tolerations.size() <= index) + throw new RuntimeException("Can't edit tolerations. Index exceeds size."); return setNewTolerationLike(index, buildToleration(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested editFirstToleration() { - if (tolerations.size() == 0) throw new RuntimeException("Can't edit first tolerations. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested + editFirstToleration() { + if (tolerations.size() == 0) + throw new RuntimeException("Can't edit first tolerations. The list is empty."); return setNewTolerationLike(0, buildToleration(0)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested editLastToleration() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested + editLastToleration() { int index = tolerations.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last tolerations. The list is empty."); return setNewTolerationLike(index, buildToleration(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested editMatchingToleration(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested + editMatchingToleration( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(item);_visitables.get("topologySpreadConstraints").add(index >= 0 ? index : _visitables.get("topologySpreadConstraints").size(), builder);this.topologySpreadConstraints.add(index >= 0 ? index : topologySpreadConstraints.size(), builder); return (A)this; + + public A addToTopologySpreadConstraints( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item) { + if (this.topologySpreadConstraints == null) { + this.topologySpreadConstraints = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder>(); + } + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(item); + _visitables + .get("topologySpreadConstraints") + .add(index >= 0 ? index : _visitables.get("topologySpreadConstraints").size(), builder); + this.topologySpreadConstraints.add( + index >= 0 ? index : topologySpreadConstraints.size(), builder); + return (A) this; } - public A setToTopologySpreadConstraints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item) { - if (this.topologySpreadConstraints == null) {this.topologySpreadConstraints = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(item); - if (index < 0 || index >= _visitables.get("topologySpreadConstraints").size()) { _visitables.get("topologySpreadConstraints").add(builder); } else { _visitables.get("topologySpreadConstraints").set(index, builder);} - if (index < 0 || index >= topologySpreadConstraints.size()) { topologySpreadConstraints.add(builder); } else { topologySpreadConstraints.set(index, builder);} - return (A)this; + + public A setToTopologySpreadConstraints( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item) { + if (this.topologySpreadConstraints == null) { + this.topologySpreadConstraints = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder>(); + } + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(item); + if (index < 0 || index >= _visitables.get("topologySpreadConstraints").size()) { + _visitables.get("topologySpreadConstraints").add(builder); + } else { + _visitables.get("topologySpreadConstraints").set(index, builder); + } + if (index < 0 || index >= topologySpreadConstraints.size()) { + topologySpreadConstraints.add(builder); + } else { + topologySpreadConstraints.set(index, builder); + } + return (A) this; } - public A addToTopologySpreadConstraints(io.kubernetes.client.openapi.models.V1TopologySpreadConstraint... items) { - if (this.topologySpreadConstraints == null) {this.topologySpreadConstraints = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item : items) {io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(item);_visitables.get("topologySpreadConstraints").add(builder);this.topologySpreadConstraints.add(builder);} return (A)this; + + public A addToTopologySpreadConstraints( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint... items) { + if (this.topologySpreadConstraints == null) { + this.topologySpreadConstraints = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item : items) { + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(item); + _visitables.get("topologySpreadConstraints").add(builder); + this.topologySpreadConstraints.add(builder); + } + return (A) this; } - public A addAllToTopologySpreadConstraints(java.util.Collection items) { - if (this.topologySpreadConstraints == null) {this.topologySpreadConstraints = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item : items) {io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(item);_visitables.get("topologySpreadConstraints").add(builder);this.topologySpreadConstraints.add(builder);} return (A)this; + + public A addAllToTopologySpreadConstraints( + java.util.Collection items) { + if (this.topologySpreadConstraints == null) { + this.topologySpreadConstraints = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item : items) { + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(item); + _visitables.get("topologySpreadConstraints").add(builder); + this.topologySpreadConstraints.add(builder); + } + return (A) this; } - public A removeFromTopologySpreadConstraints(io.kubernetes.client.openapi.models.V1TopologySpreadConstraint... items) { - for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item : items) {io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(item);_visitables.get("topologySpreadConstraints").remove(builder);if (this.topologySpreadConstraints != null) {this.topologySpreadConstraints.remove(builder);}} return (A)this; + + public A removeFromTopologySpreadConstraints( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint... items) { + for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item : items) { + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(item); + _visitables.get("topologySpreadConstraints").remove(builder); + if (this.topologySpreadConstraints != null) { + this.topologySpreadConstraints.remove(builder); + } + } + return (A) this; } - public A removeAllFromTopologySpreadConstraints(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item : items) {io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(item);_visitables.get("topologySpreadConstraints").remove(builder);if (this.topologySpreadConstraints != null) {this.topologySpreadConstraints.remove(builder);}} return (A)this; + + public A removeAllFromTopologySpreadConstraints( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item : items) { + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(item); + _visitables.get("topologySpreadConstraints").remove(builder); + if (this.topologySpreadConstraints != null) { + this.topologySpreadConstraints.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromTopologySpreadConstraints(java.util.function.Predicate predicate) { + + public A removeMatchingFromTopologySpreadConstraints( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder> + predicate) { if (topologySpreadConstraints == null) return (A) this; - final Iterator each = topologySpreadConstraints.iterator(); + final Iterator each = + topologySpreadConstraints.iterator(); final List visitables = _visitables.get("topologySpreadConstraints"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder = each.next(); @@ -1359,102 +2650,249 @@ public A removeMatchingFromTopologySpreadConstraints(java.util.function.Predicat each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildTopologySpreadConstraints instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getTopologySpreadConstraints() { + public java.util.List + getTopologySpreadConstraints() { return topologySpreadConstraints != null ? build(topologySpreadConstraints) : null; } - public java.util.List buildTopologySpreadConstraints() { + + public java.util.List + buildTopologySpreadConstraints() { return topologySpreadConstraints != null ? build(topologySpreadConstraints) : null; } - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint buildTopologySpreadConstraint(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint + buildTopologySpreadConstraint(java.lang.Integer index) { return this.topologySpreadConstraints.get(index).build(); } - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint buildFirstTopologySpreadConstraint() { + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint + buildFirstTopologySpreadConstraint() { return this.topologySpreadConstraints.get(0).build(); } - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint buildLastTopologySpreadConstraint() { + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint + buildLastTopologySpreadConstraint() { return this.topologySpreadConstraints.get(topologySpreadConstraints.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint buildMatchingTopologySpreadConstraint(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder item: topologySpreadConstraints) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint + buildMatchingTopologySpreadConstraint( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder item : + topologySpreadConstraints) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingTopologySpreadConstraint(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder item: topologySpreadConstraints) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingTopologySpreadConstraint( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder item : + topologySpreadConstraints) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withTopologySpreadConstraints(java.util.List topologySpreadConstraints) { - if (this.topologySpreadConstraints != null) { _visitables.get("topologySpreadConstraints").removeAll(this.topologySpreadConstraints);} - if (topologySpreadConstraints != null) {this.topologySpreadConstraints = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item : topologySpreadConstraints){this.addToTopologySpreadConstraints(item);}} else { this.topologySpreadConstraints = null;} return (A) this; + + public A withTopologySpreadConstraints( + java.util.List + topologySpreadConstraints) { + if (this.topologySpreadConstraints != null) { + _visitables.get("topologySpreadConstraints").removeAll(this.topologySpreadConstraints); + } + if (topologySpreadConstraints != null) { + this.topologySpreadConstraints = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item : + topologySpreadConstraints) { + this.addToTopologySpreadConstraints(item); + } + } else { + this.topologySpreadConstraints = null; + } + return (A) this; } - public A withTopologySpreadConstraints(io.kubernetes.client.openapi.models.V1TopologySpreadConstraint... topologySpreadConstraints) { - if (this.topologySpreadConstraints != null) {this.topologySpreadConstraints.clear();} - if (topologySpreadConstraints != null) {for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item :topologySpreadConstraints){ this.addToTopologySpreadConstraints(item);}} return (A) this; + + public A withTopologySpreadConstraints( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint... topologySpreadConstraints) { + if (this.topologySpreadConstraints != null) { + this.topologySpreadConstraints.clear(); + } + if (topologySpreadConstraints != null) { + for (io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item : + topologySpreadConstraints) { + this.addToTopologySpreadConstraints(item); + } + } + return (A) this; } + public java.lang.Boolean hasTopologySpreadConstraints() { return topologySpreadConstraints != null && !topologySpreadConstraints.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested addNewTopologySpreadConstraint() { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.TopologySpreadConstraintsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + addNewTopologySpreadConstraint() { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl + .TopologySpreadConstraintsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested addNewTopologySpreadConstraintLike(io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.TopologySpreadConstraintsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + addNewTopologySpreadConstraintLike( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl + .TopologySpreadConstraintsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested setNewTopologySpreadConstraintLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.TopologySpreadConstraintsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + setNewTopologySpreadConstraintLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl + .TopologySpreadConstraintsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested editTopologySpreadConstraint(java.lang.Integer index) { - if (topologySpreadConstraints.size() <= index) throw new RuntimeException("Can't edit topologySpreadConstraints. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + editTopologySpreadConstraint(java.lang.Integer index) { + if (topologySpreadConstraints.size() <= index) + throw new RuntimeException("Can't edit topologySpreadConstraints. Index exceeds size."); return setNewTopologySpreadConstraintLike(index, buildTopologySpreadConstraint(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested editFirstTopologySpreadConstraint() { - if (topologySpreadConstraints.size() == 0) throw new RuntimeException("Can't edit first topologySpreadConstraints. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + editFirstTopologySpreadConstraint() { + if (topologySpreadConstraints.size() == 0) + throw new RuntimeException("Can't edit first topologySpreadConstraints. The list is empty."); return setNewTopologySpreadConstraintLike(0, buildTopologySpreadConstraint(0)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested editLastTopologySpreadConstraint() { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + editLastTopologySpreadConstraint() { int index = topologySpreadConstraints.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last topologySpreadConstraints. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last topologySpreadConstraints. The list is empty."); return setNewTopologySpreadConstraintLike(index, buildTopologySpreadConstraint(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested editMatchingTopologySpreadConstraint(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested + editMatchingTopologySpreadConstraint( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1VolumeBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeBuilder(item);_visitables.get("volumes").add(index >= 0 ? index : _visitables.get("volumes").size(), builder);this.volumes.add(index >= 0 ? index : volumes.size(), builder); return (A)this; + + public A addToVolumes( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Volume item) { + if (this.volumes == null) { + this.volumes = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeBuilder(item); + _visitables.get("volumes").add(index >= 0 ? index : _visitables.get("volumes").size(), builder); + this.volumes.add(index >= 0 ? index : volumes.size(), builder); + return (A) this; } - public A setToVolumes(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Volume item) { - if (this.volumes == null) {this.volumes = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1VolumeBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeBuilder(item); - if (index < 0 || index >= _visitables.get("volumes").size()) { _visitables.get("volumes").add(builder); } else { _visitables.get("volumes").set(index, builder);} - if (index < 0 || index >= volumes.size()) { volumes.add(builder); } else { volumes.set(index, builder);} - return (A)this; + + public A setToVolumes( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Volume item) { + if (this.volumes == null) { + this.volumes = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeBuilder(item); + if (index < 0 || index >= _visitables.get("volumes").size()) { + _visitables.get("volumes").add(builder); + } else { + _visitables.get("volumes").set(index, builder); + } + if (index < 0 || index >= volumes.size()) { + volumes.add(builder); + } else { + volumes.set(index, builder); + } + return (A) this; } + public A addToVolumes(io.kubernetes.client.openapi.models.V1Volume... items) { - if (this.volumes == null) {this.volumes = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Volume item : items) {io.kubernetes.client.openapi.models.V1VolumeBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeBuilder(item);_visitables.get("volumes").add(builder);this.volumes.add(builder);} return (A)this; + if (this.volumes == null) { + this.volumes = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Volume item : items) { + io.kubernetes.client.openapi.models.V1VolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeBuilder(item); + _visitables.get("volumes").add(builder); + this.volumes.add(builder); + } + return (A) this; } - public A addAllToVolumes(java.util.Collection items) { - if (this.volumes == null) {this.volumes = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Volume item : items) {io.kubernetes.client.openapi.models.V1VolumeBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeBuilder(item);_visitables.get("volumes").add(builder);this.volumes.add(builder);} return (A)this; + + public A addAllToVolumes( + java.util.Collection items) { + if (this.volumes == null) { + this.volumes = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Volume item : items) { + io.kubernetes.client.openapi.models.V1VolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeBuilder(item); + _visitables.get("volumes").add(builder); + this.volumes.add(builder); + } + return (A) this; } + public A removeFromVolumes(io.kubernetes.client.openapi.models.V1Volume... items) { - for (io.kubernetes.client.openapi.models.V1Volume item : items) {io.kubernetes.client.openapi.models.V1VolumeBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeBuilder(item);_visitables.get("volumes").remove(builder);if (this.volumes != null) {this.volumes.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Volume item : items) { + io.kubernetes.client.openapi.models.V1VolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeBuilder(item); + _visitables.get("volumes").remove(builder); + if (this.volumes != null) { + this.volumes.remove(builder); + } + } + return (A) this; } - public A removeAllFromVolumes(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Volume item : items) {io.kubernetes.client.openapi.models.V1VolumeBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeBuilder(item);_visitables.get("volumes").remove(builder);if (this.volumes != null) {this.volumes.remove(builder);}} return (A)this; + + public A removeAllFromVolumes( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Volume item : items) { + io.kubernetes.client.openapi.models.V1VolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeBuilder(item); + _visitables.get("volumes").remove(builder); + if (this.volumes != null) { + this.volumes.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromVolumes(java.util.function.Predicate predicate) { + + public A removeMatchingFromVolumes( + java.util.function.Predicate predicate) { if (volumes == null) return (A) this; final Iterator each = volumes.iterator(); final List visitables = _visitables.get("volumes"); @@ -1465,355 +2903,615 @@ public A removeMatchingFromVolumes(java.util.function.Predicate getVolumes() { return volumes != null ? build(volumes) : null; } + public java.util.List buildVolumes() { return volumes != null ? build(volumes) : null; } + public io.kubernetes.client.openapi.models.V1Volume buildVolume(java.lang.Integer index) { return this.volumes.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Volume buildFirstVolume() { return this.volumes.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Volume buildLastVolume() { return this.volumes.get(volumes.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Volume buildMatchingVolume(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeBuilder item: volumes) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Volume buildMatchingVolume( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeBuilder item : volumes) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingVolume(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeBuilder item: volumes) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVolume( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeBuilder item : volumes) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withVolumes(java.util.List volumes) { - if (this.volumes != null) { _visitables.get("volumes").removeAll(this.volumes);} - if (volumes != null) {this.volumes = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Volume item : volumes){this.addToVolumes(item);}} else { this.volumes = null;} return (A) this; + if (this.volumes != null) { + _visitables.get("volumes").removeAll(this.volumes); + } + if (volumes != null) { + this.volumes = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Volume item : volumes) { + this.addToVolumes(item); + } + } else { + this.volumes = null; + } + return (A) this; } + public A withVolumes(io.kubernetes.client.openapi.models.V1Volume... volumes) { - if (this.volumes != null) {this.volumes.clear();} - if (volumes != null) {for (io.kubernetes.client.openapi.models.V1Volume item :volumes){ this.addToVolumes(item);}} return (A) this; + if (this.volumes != null) { + this.volumes.clear(); + } + if (volumes != null) { + for (io.kubernetes.client.openapi.models.V1Volume item : volumes) { + this.addToVolumes(item); + } + } + return (A) this; } + public java.lang.Boolean hasVolumes() { return volumes != null && !volumes.isEmpty(); } + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested addNewVolume() { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.VolumesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested addNewVolumeLike(io.kubernetes.client.openapi.models.V1Volume item) { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested addNewVolumeLike( + io.kubernetes.client.openapi.models.V1Volume item) { return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.VolumesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested setNewVolumeLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Volume item) { - return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.VolumesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested setNewVolumeLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Volume item) { + return new io.kubernetes.client.openapi.models.V1PodSpecFluentImpl.VolumesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested editVolume(java.lang.Integer index) { - if (volumes.size() <= index) throw new RuntimeException("Can't edit volumes. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested editVolume( + java.lang.Integer index) { + if (volumes.size() <= index) + throw new RuntimeException("Can't edit volumes. Index exceeds size."); return setNewVolumeLike(index, buildVolume(index)); } + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested editFirstVolume() { - if (volumes.size() == 0) throw new RuntimeException("Can't edit first volumes. The list is empty."); + if (volumes.size() == 0) + throw new RuntimeException("Can't edit first volumes. The list is empty."); return setNewVolumeLike(0, buildVolume(0)); } + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested editLastVolume() { int index = volumes.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last volumes. The list is empty."); return setNewVolumeLike(index, buildVolume(index)); } - public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested editMatchingVolume(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested editMatchingVolume( + java.util.function.Predicate predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1AffinityFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested,io.kubernetes.client.fluent.Nested{ + + public class AffinityNestedImpl + extends io.kubernetes.client.openapi.models.V1AffinityFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested> + implements io.kubernetes.client.openapi.models.V1PodSpecFluent.AffinityNested, + io.kubernetes.client.fluent.Nested { AffinityNestedImpl(io.kubernetes.client.openapi.models.V1Affinity item) { this.builder = new io.kubernetes.client.openapi.models.V1AffinityBuilder(this, item); } + AffinityNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1AffinityBuilder(this); } + io.kubernetes.client.openapi.models.V1AffinityBuilder builder; + public N and() { return (N) V1PodSpecFluentImpl.this.withAffinity(builder.build()); } + public N endAffinity() { return and(); } - } - public class ContainersNestedImpl extends io.kubernetes.client.openapi.models.V1ContainerFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested,io.kubernetes.client.fluent.Nested{ - ContainersNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Container item) { + + public class ContainersNestedImpl + extends io.kubernetes.client.openapi.models.V1ContainerFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested> + implements io.kubernetes.client.openapi.models.V1PodSpecFluent.ContainersNested, + io.kubernetes.client.fluent.Nested { + ContainersNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(this, item); } + ContainersNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(this); } + io.kubernetes.client.openapi.models.V1ContainerBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodSpecFluentImpl.this.setToContainers(index,builder.build()); + return (N) V1PodSpecFluentImpl.this.setToContainers(index, builder.build()); } + public N endContainer() { return and(); } - } - public class DnsConfigNestedImpl extends io.kubernetes.client.openapi.models.V1PodDNSConfigFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested,io.kubernetes.client.fluent.Nested{ + + public class DnsConfigNestedImpl + extends io.kubernetes.client.openapi.models.V1PodDNSConfigFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested> + implements io.kubernetes.client.openapi.models.V1PodSpecFluent.DnsConfigNested, + io.kubernetes.client.fluent.Nested { DnsConfigNestedImpl(io.kubernetes.client.openapi.models.V1PodDNSConfig item) { this.builder = new io.kubernetes.client.openapi.models.V1PodDNSConfigBuilder(this, item); } + DnsConfigNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodDNSConfigBuilder(this); } + io.kubernetes.client.openapi.models.V1PodDNSConfigBuilder builder; + public N and() { return (N) V1PodSpecFluentImpl.this.withDnsConfig(builder.build()); } + public N endDnsConfig() { return and(); } - } - public class EphemeralContainersNestedImpl extends io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested,io.kubernetes.client.fluent.Nested{ - EphemeralContainersNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1EphemeralContainer item) { + + public class EphemeralContainersNestedImpl + extends io.kubernetes.client.openapi.models.V1EphemeralContainerFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested> + implements io.kubernetes.client.openapi.models.V1PodSpecFluent.EphemeralContainersNested, + io.kubernetes.client.fluent.Nested { + EphemeralContainersNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1EphemeralContainer item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(this, item); } + EphemeralContainersNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder(this); } + io.kubernetes.client.openapi.models.V1EphemeralContainerBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodSpecFluentImpl.this.setToEphemeralContainers(index,builder.build()); + return (N) V1PodSpecFluentImpl.this.setToEphemeralContainers(index, builder.build()); } + public N endEphemeralContainer() { return and(); } - } - public class HostAliasesNestedImpl extends io.kubernetes.client.openapi.models.V1HostAliasFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested,io.kubernetes.client.fluent.Nested{ - HostAliasesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1HostAlias item) { + + public class HostAliasesNestedImpl + extends io.kubernetes.client.openapi.models.V1HostAliasFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested> + implements io.kubernetes.client.openapi.models.V1PodSpecFluent.HostAliasesNested, + io.kubernetes.client.fluent.Nested { + HostAliasesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1HostAlias item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1HostAliasBuilder(this, item); } + HostAliasesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1HostAliasBuilder(this); } + io.kubernetes.client.openapi.models.V1HostAliasBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodSpecFluentImpl.this.setToHostAliases(index,builder.build()); + return (N) V1PodSpecFluentImpl.this.setToHostAliases(index, builder.build()); } + public N endHostAlias() { return and(); } - } - public class ImagePullSecretsNestedImpl extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested,io.kubernetes.client.fluent.Nested{ - ImagePullSecretsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + + public class ImagePullSecretsNestedImpl + extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested> + implements io.kubernetes.client.openapi.models.V1PodSpecFluent.ImagePullSecretsNested, + io.kubernetes.client.fluent.Nested { + ImagePullSecretsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LocalObjectReference item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); } + ImagePullSecretsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodSpecFluentImpl.this.setToImagePullSecrets(index,builder.build()); + return (N) V1PodSpecFluentImpl.this.setToImagePullSecrets(index, builder.build()); } + public N endImagePullSecret() { return and(); } - } - public class InitContainersNestedImpl extends io.kubernetes.client.openapi.models.V1ContainerFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested,io.kubernetes.client.fluent.Nested{ - InitContainersNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Container item) { + + public class InitContainersNestedImpl + extends io.kubernetes.client.openapi.models.V1ContainerFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested> + implements io.kubernetes.client.openapi.models.V1PodSpecFluent.InitContainersNested, + io.kubernetes.client.fluent.Nested { + InitContainersNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Container item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(this, item); } + InitContainersNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ContainerBuilder(this); } + io.kubernetes.client.openapi.models.V1ContainerBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodSpecFluentImpl.this.setToInitContainers(index,builder.build()); + return (N) V1PodSpecFluentImpl.this.setToInitContainers(index, builder.build()); } + public N endInitContainer() { return and(); } - } - public class OsNestedImpl extends io.kubernetes.client.openapi.models.V1PodOSFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested,io.kubernetes.client.fluent.Nested{ + + public class OsNestedImpl + extends io.kubernetes.client.openapi.models.V1PodOSFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested> + implements io.kubernetes.client.openapi.models.V1PodSpecFluent.OsNested, + io.kubernetes.client.fluent.Nested { OsNestedImpl(io.kubernetes.client.openapi.models.V1PodOS item) { this.builder = new io.kubernetes.client.openapi.models.V1PodOSBuilder(this, item); } + OsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodOSBuilder(this); } + io.kubernetes.client.openapi.models.V1PodOSBuilder builder; + public N and() { return (N) V1PodSpecFluentImpl.this.withOs(builder.build()); } + public N endOs() { return and(); } - } - public class ReadinessGatesNestedImpl extends io.kubernetes.client.openapi.models.V1PodReadinessGateFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested,io.kubernetes.client.fluent.Nested{ - ReadinessGatesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodReadinessGate item) { + + public class ReadinessGatesNestedImpl + extends io.kubernetes.client.openapi.models.V1PodReadinessGateFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested> + implements io.kubernetes.client.openapi.models.V1PodSpecFluent.ReadinessGatesNested, + io.kubernetes.client.fluent.Nested { + ReadinessGatesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodReadinessGate item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(this, item); } + ReadinessGatesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder(this); } + io.kubernetes.client.openapi.models.V1PodReadinessGateBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodSpecFluentImpl.this.setToReadinessGates(index,builder.build()); + return (N) V1PodSpecFluentImpl.this.setToReadinessGates(index, builder.build()); } + public N endReadinessGate() { return and(); } - } - public class SecurityContextNestedImpl extends io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested,io.kubernetes.client.fluent.Nested{ + + public class SecurityContextNestedImpl + extends io.kubernetes.client.openapi.models.V1PodSecurityContextFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested> + implements io.kubernetes.client.openapi.models.V1PodSpecFluent.SecurityContextNested, + io.kubernetes.client.fluent.Nested { SecurityContextNestedImpl(io.kubernetes.client.openapi.models.V1PodSecurityContext item) { - this.builder = new io.kubernetes.client.openapi.models.V1PodSecurityContextBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PodSecurityContextBuilder(this, item); } + SecurityContextNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodSecurityContextBuilder(this); } + io.kubernetes.client.openapi.models.V1PodSecurityContextBuilder builder; + public N and() { return (N) V1PodSpecFluentImpl.this.withSecurityContext(builder.build()); } + public N endSecurityContext() { return and(); } - } - public class TolerationsNestedImpl extends io.kubernetes.client.openapi.models.V1TolerationFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested,io.kubernetes.client.fluent.Nested{ - TolerationsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { + + public class TolerationsNestedImpl + extends io.kubernetes.client.openapi.models.V1TolerationFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested> + implements io.kubernetes.client.openapi.models.V1PodSpecFluent.TolerationsNested, + io.kubernetes.client.fluent.Nested { + TolerationsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(this, item); } + TolerationsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(this); } + io.kubernetes.client.openapi.models.V1TolerationBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodSpecFluentImpl.this.setToTolerations(index,builder.build()); + return (N) V1PodSpecFluentImpl.this.setToTolerations(index, builder.build()); } + public N endToleration() { return and(); } - } - public class TopologySpreadConstraintsNestedImpl extends io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested,io.kubernetes.client.fluent.Nested{ - TopologySpreadConstraintsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item) { + + public class TopologySpreadConstraintsNestedImpl + extends io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecFluent.TopologySpreadConstraintsNested> + implements io.kubernetes.client.openapi.models.V1PodSpecFluent + .TopologySpreadConstraintsNested< + N>, + io.kubernetes.client.fluent.Nested { + TopologySpreadConstraintsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(this, item); } + TopologySpreadConstraintsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder(this); } + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodSpecFluentImpl.this.setToTopologySpreadConstraints(index,builder.build()); + return (N) V1PodSpecFluentImpl.this.setToTopologySpreadConstraints(index, builder.build()); } + public N endTopologySpreadConstraint() { return and(); } - } - public class VolumesNestedImpl extends io.kubernetes.client.openapi.models.V1VolumeFluentImpl> implements io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested,io.kubernetes.client.fluent.Nested{ - VolumesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Volume item) { + + public class VolumesNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeFluentImpl< + io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested> + implements io.kubernetes.client.openapi.models.V1PodSpecFluent.VolumesNested, + io.kubernetes.client.fluent.Nested { + VolumesNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Volume item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1VolumeBuilder(this, item); } + VolumesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1VolumeBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodSpecFluentImpl.this.setToVolumes(index,builder.build()); + return (N) V1PodSpecFluentImpl.this.setToVolumes(index, builder.build()); } + public N endVolume() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodStatusBuilder.java index e5f42672d3..db8ea8c39c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodStatusBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodStatusBuilder extends io.kubernetes.client.openapi.models.V1PodStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodStatusBuilder + extends io.kubernetes.client.openapi.models.V1PodStatusFluentImpl< + io.kubernetes.client.openapi.models.V1PodStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodStatus, + io.kubernetes.client.openapi.models.V1PodStatusBuilder> { public V1PodStatusBuilder() { this(false); } + public V1PodStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1PodStatus(), validationEnabled); } + public V1PodStatusBuilder(io.kubernetes.client.openapi.models.V1PodStatusFluent fluent) { this(fluent, false); } - public V1PodStatusBuilder(io.kubernetes.client.openapi.models.V1PodStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodStatusBuilder( + io.kubernetes.client.openapi.models.V1PodStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodStatus(), validationEnabled); } - public V1PodStatusBuilder(io.kubernetes.client.openapi.models.V1PodStatusFluent fluent,io.kubernetes.client.openapi.models.V1PodStatus instance) { + + public V1PodStatusBuilder( + io.kubernetes.client.openapi.models.V1PodStatusFluent fluent, + io.kubernetes.client.openapi.models.V1PodStatus instance) { this(fluent, instance, false); } - public V1PodStatusBuilder(io.kubernetes.client.openapi.models.V1PodStatusFluent fluent,io.kubernetes.client.openapi.models.V1PodStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodStatusBuilder( + io.kubernetes.client.openapi.models.V1PodStatusFluent fluent, + io.kubernetes.client.openapi.models.V1PodStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditions(instance.getConditions()); fluent.withContainerStatuses(instance.getContainerStatuses()); @@ -47,13 +73,17 @@ public V1PodStatusBuilder(io.kubernetes.client.openapi.models.V1PodStatusFluent< fluent.withStartTime(instance.getStartTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodStatusBuilder(io.kubernetes.client.openapi.models.V1PodStatus instance) { - this(instance,false); + this(instance, false); } - public V1PodStatusBuilder(io.kubernetes.client.openapi.models.V1PodStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodStatusBuilder( + io.kubernetes.client.openapi.models.V1PodStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditions(instance.getConditions()); this.withContainerStatuses(instance.getContainerStatuses()); @@ -80,10 +110,12 @@ public V1PodStatusBuilder(io.kubernetes.client.openapi.models.V1PodStatus instan this.withStartTime(instance.getStartTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodStatus build() { V1PodStatus buildable = new V1PodStatus(); buildable.setConditions(fluent.getConditions()); @@ -101,18 +133,23 @@ public io.kubernetes.client.openapi.models.V1PodStatus build() { buildable.setStartTime(fluent.getStartTime()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodStatusBuilder that = (V1PodStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodStatusFluent.java index b735b31ffc..c38219c15f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodStatusFluent.java @@ -1,252 +1,516 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.util.Collection; - - /** - * Generated - */ -public interface V1PodStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodCondition item); +/** Generated */ +public interface V1PodStatusFluent< + A extends io.kubernetes.client.openapi.models.V1PodStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodCondition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodCondition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1PodCondition... items); - public A addAllToConditions(java.util.Collection items); + + public A addAllToConditions( + java.util.Collection items); + public A removeFromConditions(io.kubernetes.client.openapi.models.V1PodCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getConditions(); + public java.util.List buildConditions(); + public io.kubernetes.client.openapi.models.V1PodCondition buildCondition(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PodCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1PodCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1PodCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); + + public io.kubernetes.client.openapi.models.V1PodCondition buildMatchingCondition( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate); + + public A withConditions( + java.util.List conditions); + public A withConditions(io.kubernetes.client.openapi.models.V1PodCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1PodCondition item); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodCondition item); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - public A addToContainerStatuses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item); - public A setToContainerStatuses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1PodCondition item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodCondition item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested editCondition( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate + predicate); + + public A addToContainerStatuses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item); + + public A setToContainerStatuses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item); + public A addToContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... items); - public A addAllToContainerStatuses(java.util.Collection items); - public A removeFromContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... items); - public A removeAllFromContainerStatuses(java.util.Collection items); - public A removeMatchingFromContainerStatuses(java.util.function.Predicate predicate); - + + public A addAllToContainerStatuses( + java.util.Collection items); + + public A removeFromContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... items); + + public A removeAllFromContainerStatuses( + java.util.Collection items); + + public A removeMatchingFromContainerStatuses( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildContainerStatuses instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getContainerStatuses(); - public java.util.List buildContainerStatuses(); - public io.kubernetes.client.openapi.models.V1ContainerStatus buildContainerStatus(java.lang.Integer index); + public java.util.List + getContainerStatuses(); + + public java.util.List + buildContainerStatuses(); + + public io.kubernetes.client.openapi.models.V1ContainerStatus buildContainerStatus( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ContainerStatus buildFirstContainerStatus(); + public io.kubernetes.client.openapi.models.V1ContainerStatus buildLastContainerStatus(); - public io.kubernetes.client.openapi.models.V1ContainerStatus buildMatchingContainerStatus(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingContainerStatus(java.util.function.Predicate predicate); - public A withContainerStatuses(java.util.List containerStatuses); - public A withContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... containerStatuses); + + public io.kubernetes.client.openapi.models.V1ContainerStatus buildMatchingContainerStatus( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingContainerStatus( + java.util.function.Predicate + predicate); + + public A withContainerStatuses( + java.util.List containerStatuses); + + public A withContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... containerStatuses); + public java.lang.Boolean hasContainerStatuses(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested addNewContainerStatus(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested addNewContainerStatusLike(io.kubernetes.client.openapi.models.V1ContainerStatus item); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested setNewContainerStatusLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested editContainerStatus(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested editFirstContainerStatus(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested editLastContainerStatus(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested editMatchingContainerStatus(java.util.function.Predicate predicate); - public A addToEphemeralContainerStatuses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item); - public A setToEphemeralContainerStatuses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item); - public A addToEphemeralContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... items); - public A addAllToEphemeralContainerStatuses(java.util.Collection items); - public A removeFromEphemeralContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... items); - public A removeAllFromEphemeralContainerStatuses(java.util.Collection items); - public A removeMatchingFromEphemeralContainerStatuses(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + addNewContainerStatus(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + addNewContainerStatusLike(io.kubernetes.client.openapi.models.V1ContainerStatus item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + setNewContainerStatusLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + editContainerStatus(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + editFirstContainerStatus(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + editLastContainerStatus(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + editMatchingContainerStatus( + java.util.function.Predicate + predicate); + + public A addToEphemeralContainerStatuses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item); + + public A setToEphemeralContainerStatuses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item); + + public A addToEphemeralContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... items); + + public A addAllToEphemeralContainerStatuses( + java.util.Collection items); + + public A removeFromEphemeralContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... items); + + public A removeAllFromEphemeralContainerStatuses( + java.util.Collection items); + + public A removeMatchingFromEphemeralContainerStatuses( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildEphemeralContainerStatuses instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getEphemeralContainerStatuses(); - public java.util.List buildEphemeralContainerStatuses(); - public io.kubernetes.client.openapi.models.V1ContainerStatus buildEphemeralContainerStatus(java.lang.Integer index); + public java.util.List + getEphemeralContainerStatuses(); + + public java.util.List + buildEphemeralContainerStatuses(); + + public io.kubernetes.client.openapi.models.V1ContainerStatus buildEphemeralContainerStatus( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ContainerStatus buildFirstEphemeralContainerStatus(); + public io.kubernetes.client.openapi.models.V1ContainerStatus buildLastEphemeralContainerStatus(); - public io.kubernetes.client.openapi.models.V1ContainerStatus buildMatchingEphemeralContainerStatus(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingEphemeralContainerStatus(java.util.function.Predicate predicate); - public A withEphemeralContainerStatuses(java.util.List ephemeralContainerStatuses); - public A withEphemeralContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... ephemeralContainerStatuses); + + public io.kubernetes.client.openapi.models.V1ContainerStatus + buildMatchingEphemeralContainerStatus( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingEphemeralContainerStatus( + java.util.function.Predicate + predicate); + + public A withEphemeralContainerStatuses( + java.util.List + ephemeralContainerStatuses); + + public A withEphemeralContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... ephemeralContainerStatuses); + public java.lang.Boolean hasEphemeralContainerStatuses(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested addNewEphemeralContainerStatus(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested addNewEphemeralContainerStatusLike(io.kubernetes.client.openapi.models.V1ContainerStatus item); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested setNewEphemeralContainerStatusLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested editEphemeralContainerStatus(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested editFirstEphemeralContainerStatus(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested editLastEphemeralContainerStatus(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested editMatchingEphemeralContainerStatus(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + addNewEphemeralContainerStatus(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + addNewEphemeralContainerStatusLike( + io.kubernetes.client.openapi.models.V1ContainerStatus item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + setNewEphemeralContainerStatusLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + editEphemeralContainerStatus(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + editFirstEphemeralContainerStatus(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + editLastEphemeralContainerStatus(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + editMatchingEphemeralContainerStatus( + java.util.function.Predicate + predicate); + public java.lang.String getHostIP(); + public A withHostIP(java.lang.String hostIP); + public java.lang.Boolean hasHostIP(); - - /** - * Method is deprecated. use withHostIP instead. - */ + + /** Method is deprecated. use withHostIP instead. */ @java.lang.Deprecated public A withNewHostIP(java.lang.String original); - public A addToInitContainerStatuses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item); - public A setToInitContainerStatuses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item); - public A addToInitContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... items); - public A addAllToInitContainerStatuses(java.util.Collection items); - public A removeFromInitContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... items); - public A removeAllFromInitContainerStatuses(java.util.Collection items); - public A removeMatchingFromInitContainerStatuses(java.util.function.Predicate predicate); - + + public A addToInitContainerStatuses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item); + + public A setToInitContainerStatuses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item); + + public A addToInitContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... items); + + public A addAllToInitContainerStatuses( + java.util.Collection items); + + public A removeFromInitContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... items); + + public A removeAllFromInitContainerStatuses( + java.util.Collection items); + + public A removeMatchingFromInitContainerStatuses( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildInitContainerStatuses instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getInitContainerStatuses(); - public java.util.List buildInitContainerStatuses(); - public io.kubernetes.client.openapi.models.V1ContainerStatus buildInitContainerStatus(java.lang.Integer index); + public java.util.List + getInitContainerStatuses(); + + public java.util.List + buildInitContainerStatuses(); + + public io.kubernetes.client.openapi.models.V1ContainerStatus buildInitContainerStatus( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ContainerStatus buildFirstInitContainerStatus(); + public io.kubernetes.client.openapi.models.V1ContainerStatus buildLastInitContainerStatus(); - public io.kubernetes.client.openapi.models.V1ContainerStatus buildMatchingInitContainerStatus(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingInitContainerStatus(java.util.function.Predicate predicate); - public A withInitContainerStatuses(java.util.List initContainerStatuses); - public A withInitContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... initContainerStatuses); + + public io.kubernetes.client.openapi.models.V1ContainerStatus buildMatchingInitContainerStatus( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingInitContainerStatus( + java.util.function.Predicate + predicate); + + public A withInitContainerStatuses( + java.util.List initContainerStatuses); + + public A withInitContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... initContainerStatuses); + public java.lang.Boolean hasInitContainerStatuses(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested addNewInitContainerStatus(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested addNewInitContainerStatusLike(io.kubernetes.client.openapi.models.V1ContainerStatus item); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested setNewInitContainerStatusLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested editInitContainerStatus(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested editFirstInitContainerStatus(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested editLastInitContainerStatus(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested editMatchingInitContainerStatus(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + addNewInitContainerStatus(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + addNewInitContainerStatusLike(io.kubernetes.client.openapi.models.V1ContainerStatus item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + setNewInitContainerStatusLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + editInitContainerStatus(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + editFirstInitContainerStatus(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + editLastInitContainerStatus(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + editMatchingInitContainerStatus( + java.util.function.Predicate + predicate); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getNominatedNodeName(); + public A withNominatedNodeName(java.lang.String nominatedNodeName); + public java.lang.Boolean hasNominatedNodeName(); - - /** - * Method is deprecated. use withNominatedNodeName instead. - */ + + /** Method is deprecated. use withNominatedNodeName instead. */ @java.lang.Deprecated public A withNewNominatedNodeName(java.lang.String original); + public io.kubernetes.client.openapi.models.V1PodStatus.PhaseEnum getPhase(); + public A withPhase(io.kubernetes.client.openapi.models.V1PodStatus.PhaseEnum phase); + public java.lang.Boolean hasPhase(); + public java.lang.String getPodIP(); + public A withPodIP(java.lang.String podIP); + public java.lang.Boolean hasPodIP(); - - /** - * Method is deprecated. use withPodIP instead. - */ + + /** Method is deprecated. use withPodIP instead. */ @java.lang.Deprecated public A withNewPodIP(java.lang.String original); - public A addToPodIPs(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodIP item); - public A setToPodIPs(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodIP item); + + public A addToPodIPs(java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodIP item); + + public A setToPodIPs(java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodIP item); + public A addToPodIPs(io.kubernetes.client.openapi.models.V1PodIP... items); + public A addAllToPodIPs(java.util.Collection items); + public A removeFromPodIPs(io.kubernetes.client.openapi.models.V1PodIP... items); - public A removeAllFromPodIPs(java.util.Collection items); - public A removeMatchingFromPodIPs(java.util.function.Predicate predicate); - + + public A removeAllFromPodIPs( + java.util.Collection items); + + public A removeMatchingFromPodIPs( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildPodIPs instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getPodIPs(); + public java.util.List buildPodIPs(); + public io.kubernetes.client.openapi.models.V1PodIP buildPodIP(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PodIP buildFirstPodIP(); + public io.kubernetes.client.openapi.models.V1PodIP buildLastPodIP(); - public io.kubernetes.client.openapi.models.V1PodIP buildMatchingPodIP(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPodIP(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PodIP buildMatchingPodIP( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingPodIP( + java.util.function.Predicate predicate); + public A withPodIPs(java.util.List podIPs); + public A withPodIPs(io.kubernetes.client.openapi.models.V1PodIP... podIPs); + public java.lang.Boolean hasPodIPs(); + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested addNewPodIP(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested addNewPodIPLike(io.kubernetes.client.openapi.models.V1PodIP item); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested setNewPodIPLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodIP item); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested editPodIP(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested addNewPodIPLike( + io.kubernetes.client.openapi.models.V1PodIP item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested setNewPodIPLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodIP item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested editPodIP( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested editFirstPodIP(); + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested editLastPodIP(); - public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested editMatchingPodIP(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested editMatchingPodIP( + java.util.function.Predicate predicate); + public io.kubernetes.client.openapi.models.V1PodStatus.QosClassEnum getQosClass(); + public A withQosClass(io.kubernetes.client.openapi.models.V1PodStatus.QosClassEnum qosClass); + public java.lang.Boolean hasQosClass(); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.time.OffsetDateTime getStartTime(); + public A withStartTime(java.time.OffsetDateTime startTime); + public java.lang.Boolean hasStartTime(); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodConditionFluent< + io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested> { public N and(); + public N endCondition(); - } - public interface ContainerStatusesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ContainerStatusFluent>{ + + public interface ContainerStatusesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ContainerStatusFluent< + io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested> { public N and(); + public N endContainerStatus(); - } - public interface EphemeralContainerStatusesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ContainerStatusFluent>{ + + public interface EphemeralContainerStatusesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ContainerStatusFluent< + io.kubernetes.client.openapi.models.V1PodStatusFluent + .EphemeralContainerStatusesNested< + N>> { public N and(); + public N endEphemeralContainerStatus(); - } - public interface InitContainerStatusesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ContainerStatusFluent>{ + + public interface InitContainerStatusesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ContainerStatusFluent< + io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested< + N>> { public N and(); + public N endInitContainerStatus(); - } - public interface PodIPsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodIPFluent>{ + + public interface PodIPsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodIPFluent< + io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested> { public N and(); + public N endPodIP(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodStatusFluentImpl.java index 81a8babe19..d74da0f0d6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodStatusFluentImpl.java @@ -1,26 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1PodStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodStatusFluent{ - public V1PodStatusFluentImpl() { - } + +/** Generated */ +public class V1PodStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodStatusFluent { + public V1PodStatusFluentImpl() {} + public V1PodStatusFluentImpl(io.kubernetes.client.openapi.models.V1PodStatus instance) { this.withConditions(instance.getConditions()); @@ -47,13 +48,16 @@ public V1PodStatusFluentImpl(io.kubernetes.client.openapi.models.V1PodStatus ins this.withReason(instance.getReason()); this.withStartTime(instance.getStartTime()); - } + private java.util.ArrayList conditions; - private java.util.ArrayList containerStatuses; - private java.util.ArrayList ephemeralContainerStatuses; + private java.util.ArrayList + containerStatuses; + private java.util.ArrayList + ephemeralContainerStatuses; private java.lang.String hostIP; - private java.util.ArrayList initContainerStatuses; + private java.util.ArrayList + initContainerStatuses; private java.lang.String message; private java.lang.String nominatedNodeName; private io.kubernetes.client.openapi.models.V1PodStatus.PhaseEnum phase; @@ -62,34 +66,103 @@ public V1PodStatusFluentImpl(io.kubernetes.client.openapi.models.V1PodStatus ins private io.kubernetes.client.openapi.models.V1PodStatus.QosClassEnum qosClass; private java.lang.String reason; private java.time.OffsetDateTime startTime; - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodConditionBuilder builder = new io.kubernetes.client.openapi.models.V1PodConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1PodConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodConditionBuilder builder = new io.kubernetes.client.openapi.models.V1PodConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1PodConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } + public A addToConditions(io.kubernetes.client.openapi.models.V1PodCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodCondition item : items) {io.kubernetes.client.openapi.models.V1PodConditionBuilder builder = new io.kubernetes.client.openapi.models.V1PodConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PodCondition item : items) { + io.kubernetes.client.openapi.models.V1PodConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1PodConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodCondition item : items) {io.kubernetes.client.openapi.models.V1PodConditionBuilder builder = new io.kubernetes.client.openapi.models.V1PodConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PodCondition item : items) { + io.kubernetes.client.openapi.models.V1PodConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1PodConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } + public A removeFromConditions(io.kubernetes.client.openapi.models.V1PodCondition... items) { - for (io.kubernetes.client.openapi.models.V1PodCondition item : items) {io.kubernetes.client.openapi.models.V1PodConditionBuilder builder = new io.kubernetes.client.openapi.models.V1PodConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1PodCondition item : items) { + io.kubernetes.client.openapi.models.V1PodConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1PodConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PodCondition item : items) {io.kubernetes.client.openapi.models.V1PodConditionBuilder builder = new io.kubernetes.client.openapi.models.V1PodConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PodCondition item : items) { + io.kubernetes.client.openapi.models.V1PodConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1PodConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1PodConditionBuilder builder = each.next(); @@ -98,104 +171,241 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { return conditions != null ? build(conditions) : null; } + public java.util.List buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1PodCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PodCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1PodCondition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1PodCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PodCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PodCondition buildMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PodCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PodCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } + public A withConditions(io.kubernetes.client.openapi.models.V1PodCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1PodCondition item :conditions){ this.addToConditions(item);}} return (A) this; + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1PodCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested addNewCondition() { + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested + addNewCondition() { return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1PodCondition item) { - return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1PodCondition item) { + return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.ConditionsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodCondition item) { - return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodCondition item) { + return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.ConditionsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested editCondition( + java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("containerStatuses").add(index >= 0 ? index : _visitables.get("containerStatuses").size(), builder);this.containerStatuses.add(index >= 0 ? index : containerStatuses.size(), builder); return (A)this; + + public A addToContainerStatuses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item) { + if (this.containerStatuses == null) { + this.containerStatuses = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables + .get("containerStatuses") + .add(index >= 0 ? index : _visitables.get("containerStatuses").size(), builder); + this.containerStatuses.add(index >= 0 ? index : containerStatuses.size(), builder); + return (A) this; } - public A setToContainerStatuses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item) { - if (this.containerStatuses == null) {this.containerStatuses = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); - if (index < 0 || index >= _visitables.get("containerStatuses").size()) { _visitables.get("containerStatuses").add(builder); } else { _visitables.get("containerStatuses").set(index, builder);} - if (index < 0 || index >= containerStatuses.size()) { containerStatuses.add(builder); } else { containerStatuses.set(index, builder);} - return (A)this; + + public A setToContainerStatuses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item) { + if (this.containerStatuses == null) { + this.containerStatuses = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + if (index < 0 || index >= _visitables.get("containerStatuses").size()) { + _visitables.get("containerStatuses").add(builder); + } else { + _visitables.get("containerStatuses").set(index, builder); + } + if (index < 0 || index >= containerStatuses.size()) { + containerStatuses.add(builder); + } else { + containerStatuses.set(index, builder); + } + return (A) this; } + public A addToContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... items) { - if (this.containerStatuses == null) {this.containerStatuses = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) {io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("containerStatuses").add(builder);this.containerStatuses.add(builder);} return (A)this; + if (this.containerStatuses == null) { + this.containerStatuses = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) { + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables.get("containerStatuses").add(builder); + this.containerStatuses.add(builder); + } + return (A) this; } - public A addAllToContainerStatuses(java.util.Collection items) { - if (this.containerStatuses == null) {this.containerStatuses = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) {io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("containerStatuses").add(builder);this.containerStatuses.add(builder);} return (A)this; + + public A addAllToContainerStatuses( + java.util.Collection items) { + if (this.containerStatuses == null) { + this.containerStatuses = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) { + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables.get("containerStatuses").add(builder); + this.containerStatuses.add(builder); + } + return (A) this; } - public A removeFromContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... items) { - for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) {io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("containerStatuses").remove(builder);if (this.containerStatuses != null) {this.containerStatuses.remove(builder);}} return (A)this; + + public A removeFromContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... items) { + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) { + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables.get("containerStatuses").remove(builder); + if (this.containerStatuses != null) { + this.containerStatuses.remove(builder); + } + } + return (A) this; } - public A removeAllFromContainerStatuses(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) {io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("containerStatuses").remove(builder);if (this.containerStatuses != null) {this.containerStatuses.remove(builder);}} return (A)this; + + public A removeAllFromContainerStatuses( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) { + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables.get("containerStatuses").remove(builder); + if (this.containerStatuses != null) { + this.containerStatuses.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromContainerStatuses(java.util.function.Predicate predicate) { + + public A removeMatchingFromContainerStatuses( + java.util.function.Predicate + predicate) { if (containerStatuses == null) return (A) this; - final Iterator each = containerStatuses.iterator(); + final Iterator each = + containerStatuses.iterator(); final List visitables = _visitables.get("containerStatuses"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = each.next(); @@ -204,104 +414,249 @@ public A removeMatchingFromContainerStatuses(java.util.function.Predicate getContainerStatuses() { + public java.util.List + getContainerStatuses() { return containerStatuses != null ? build(containerStatuses) : null; } - public java.util.List buildContainerStatuses() { + + public java.util.List + buildContainerStatuses() { return containerStatuses != null ? build(containerStatuses) : null; } - public io.kubernetes.client.openapi.models.V1ContainerStatus buildContainerStatus(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ContainerStatus buildContainerStatus( + java.lang.Integer index) { return this.containerStatuses.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ContainerStatus buildFirstContainerStatus() { return this.containerStatuses.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ContainerStatus buildLastContainerStatus() { return this.containerStatuses.get(containerStatuses.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ContainerStatus buildMatchingContainerStatus(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerStatusBuilder item: containerStatuses) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ContainerStatus buildMatchingContainerStatus( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerStatusBuilder item : containerStatuses) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingContainerStatus(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerStatusBuilder item: containerStatuses) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingContainerStatus( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerStatusBuilder item : containerStatuses) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withContainerStatuses(java.util.List containerStatuses) { - if (this.containerStatuses != null) { _visitables.get("containerStatuses").removeAll(this.containerStatuses);} - if (containerStatuses != null) {this.containerStatuses = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ContainerStatus item : containerStatuses){this.addToContainerStatuses(item);}} else { this.containerStatuses = null;} return (A) this; + + public A withContainerStatuses( + java.util.List containerStatuses) { + if (this.containerStatuses != null) { + _visitables.get("containerStatuses").removeAll(this.containerStatuses); + } + if (containerStatuses != null) { + this.containerStatuses = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : containerStatuses) { + this.addToContainerStatuses(item); + } + } else { + this.containerStatuses = null; + } + return (A) this; } - public A withContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... containerStatuses) { - if (this.containerStatuses != null) {this.containerStatuses.clear();} - if (containerStatuses != null) {for (io.kubernetes.client.openapi.models.V1ContainerStatus item :containerStatuses){ this.addToContainerStatuses(item);}} return (A) this; + + public A withContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... containerStatuses) { + if (this.containerStatuses != null) { + this.containerStatuses.clear(); + } + if (containerStatuses != null) { + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : containerStatuses) { + this.addToContainerStatuses(item); + } + } + return (A) this; } + public java.lang.Boolean hasContainerStatuses() { return containerStatuses != null && !containerStatuses.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested addNewContainerStatus() { - return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.ContainerStatusesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + addNewContainerStatus() { + return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl + .ContainerStatusesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested addNewContainerStatusLike(io.kubernetes.client.openapi.models.V1ContainerStatus item) { - return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.ContainerStatusesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + addNewContainerStatusLike(io.kubernetes.client.openapi.models.V1ContainerStatus item) { + return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl + .ContainerStatusesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested setNewContainerStatusLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item) { - return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.ContainerStatusesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + setNewContainerStatusLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item) { + return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl + .ContainerStatusesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested editContainerStatus(java.lang.Integer index) { - if (containerStatuses.size() <= index) throw new RuntimeException("Can't edit containerStatuses. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + editContainerStatus(java.lang.Integer index) { + if (containerStatuses.size() <= index) + throw new RuntimeException("Can't edit containerStatuses. Index exceeds size."); return setNewContainerStatusLike(index, buildContainerStatus(index)); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested editFirstContainerStatus() { - if (containerStatuses.size() == 0) throw new RuntimeException("Can't edit first containerStatuses. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + editFirstContainerStatus() { + if (containerStatuses.size() == 0) + throw new RuntimeException("Can't edit first containerStatuses. The list is empty."); return setNewContainerStatusLike(0, buildContainerStatus(0)); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested editLastContainerStatus() { + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + editLastContainerStatus() { int index = containerStatuses.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last containerStatuses. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last containerStatuses. The list is empty."); return setNewContainerStatusLike(index, buildContainerStatus(index)); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested editMatchingContainerStatus(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested + editMatchingContainerStatus( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("ephemeralContainerStatuses").add(index >= 0 ? index : _visitables.get("ephemeralContainerStatuses").size(), builder);this.ephemeralContainerStatuses.add(index >= 0 ? index : ephemeralContainerStatuses.size(), builder); return (A)this; + + public A addToEphemeralContainerStatuses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item) { + if (this.ephemeralContainerStatuses == null) { + this.ephemeralContainerStatuses = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables + .get("ephemeralContainerStatuses") + .add(index >= 0 ? index : _visitables.get("ephemeralContainerStatuses").size(), builder); + this.ephemeralContainerStatuses.add( + index >= 0 ? index : ephemeralContainerStatuses.size(), builder); + return (A) this; } - public A setToEphemeralContainerStatuses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item) { - if (this.ephemeralContainerStatuses == null) {this.ephemeralContainerStatuses = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); - if (index < 0 || index >= _visitables.get("ephemeralContainerStatuses").size()) { _visitables.get("ephemeralContainerStatuses").add(builder); } else { _visitables.get("ephemeralContainerStatuses").set(index, builder);} - if (index < 0 || index >= ephemeralContainerStatuses.size()) { ephemeralContainerStatuses.add(builder); } else { ephemeralContainerStatuses.set(index, builder);} - return (A)this; + + public A setToEphemeralContainerStatuses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item) { + if (this.ephemeralContainerStatuses == null) { + this.ephemeralContainerStatuses = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + if (index < 0 || index >= _visitables.get("ephemeralContainerStatuses").size()) { + _visitables.get("ephemeralContainerStatuses").add(builder); + } else { + _visitables.get("ephemeralContainerStatuses").set(index, builder); + } + if (index < 0 || index >= ephemeralContainerStatuses.size()) { + ephemeralContainerStatuses.add(builder); + } else { + ephemeralContainerStatuses.set(index, builder); + } + return (A) this; } - public A addToEphemeralContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... items) { - if (this.ephemeralContainerStatuses == null) {this.ephemeralContainerStatuses = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) {io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("ephemeralContainerStatuses").add(builder);this.ephemeralContainerStatuses.add(builder);} return (A)this; + + public A addToEphemeralContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... items) { + if (this.ephemeralContainerStatuses == null) { + this.ephemeralContainerStatuses = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) { + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables.get("ephemeralContainerStatuses").add(builder); + this.ephemeralContainerStatuses.add(builder); + } + return (A) this; } - public A addAllToEphemeralContainerStatuses(java.util.Collection items) { - if (this.ephemeralContainerStatuses == null) {this.ephemeralContainerStatuses = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) {io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("ephemeralContainerStatuses").add(builder);this.ephemeralContainerStatuses.add(builder);} return (A)this; + + public A addAllToEphemeralContainerStatuses( + java.util.Collection items) { + if (this.ephemeralContainerStatuses == null) { + this.ephemeralContainerStatuses = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) { + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables.get("ephemeralContainerStatuses").add(builder); + this.ephemeralContainerStatuses.add(builder); + } + return (A) this; } - public A removeFromEphemeralContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... items) { - for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) {io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("ephemeralContainerStatuses").remove(builder);if (this.ephemeralContainerStatuses != null) {this.ephemeralContainerStatuses.remove(builder);}} return (A)this; + + public A removeFromEphemeralContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... items) { + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) { + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables.get("ephemeralContainerStatuses").remove(builder); + if (this.ephemeralContainerStatuses != null) { + this.ephemeralContainerStatuses.remove(builder); + } + } + return (A) this; } - public A removeAllFromEphemeralContainerStatuses(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) {io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("ephemeralContainerStatuses").remove(builder);if (this.ephemeralContainerStatuses != null) {this.ephemeralContainerStatuses.remove(builder);}} return (A)this; + + public A removeAllFromEphemeralContainerStatuses( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) { + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables.get("ephemeralContainerStatuses").remove(builder); + if (this.ephemeralContainerStatuses != null) { + this.ephemeralContainerStatuses.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromEphemeralContainerStatuses(java.util.function.Predicate predicate) { + + public A removeMatchingFromEphemeralContainerStatuses( + java.util.function.Predicate + predicate) { if (ephemeralContainerStatuses == null) return (A) this; - final Iterator each = ephemeralContainerStatuses.iterator(); + final Iterator each = + ephemeralContainerStatuses.iterator(); final List visitables = _visitables.get("ephemeralContainerStatuses"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = each.next(); @@ -310,121 +665,275 @@ public A removeMatchingFromEphemeralContainerStatuses(java.util.function.Predica each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildEphemeralContainerStatuses instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getEphemeralContainerStatuses() { + public java.util.List + getEphemeralContainerStatuses() { return ephemeralContainerStatuses != null ? build(ephemeralContainerStatuses) : null; } - public java.util.List buildEphemeralContainerStatuses() { + + public java.util.List + buildEphemeralContainerStatuses() { return ephemeralContainerStatuses != null ? build(ephemeralContainerStatuses) : null; } - public io.kubernetes.client.openapi.models.V1ContainerStatus buildEphemeralContainerStatus(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ContainerStatus buildEphemeralContainerStatus( + java.lang.Integer index) { return this.ephemeralContainerStatuses.get(index).build(); } - public io.kubernetes.client.openapi.models.V1ContainerStatus buildFirstEphemeralContainerStatus() { + + public io.kubernetes.client.openapi.models.V1ContainerStatus + buildFirstEphemeralContainerStatus() { return this.ephemeralContainerStatuses.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ContainerStatus buildLastEphemeralContainerStatus() { return this.ephemeralContainerStatuses.get(ephemeralContainerStatuses.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ContainerStatus buildMatchingEphemeralContainerStatus(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerStatusBuilder item: ephemeralContainerStatuses) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ContainerStatus + buildMatchingEphemeralContainerStatus( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerStatusBuilder item : + ephemeralContainerStatuses) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingEphemeralContainerStatus(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerStatusBuilder item: ephemeralContainerStatuses) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingEphemeralContainerStatus( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerStatusBuilder item : + ephemeralContainerStatuses) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withEphemeralContainerStatuses(java.util.List ephemeralContainerStatuses) { - if (this.ephemeralContainerStatuses != null) { _visitables.get("ephemeralContainerStatuses").removeAll(this.ephemeralContainerStatuses);} - if (ephemeralContainerStatuses != null) {this.ephemeralContainerStatuses = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ContainerStatus item : ephemeralContainerStatuses){this.addToEphemeralContainerStatuses(item);}} else { this.ephemeralContainerStatuses = null;} return (A) this; + + public A withEphemeralContainerStatuses( + java.util.List + ephemeralContainerStatuses) { + if (this.ephemeralContainerStatuses != null) { + _visitables.get("ephemeralContainerStatuses").removeAll(this.ephemeralContainerStatuses); + } + if (ephemeralContainerStatuses != null) { + this.ephemeralContainerStatuses = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : + ephemeralContainerStatuses) { + this.addToEphemeralContainerStatuses(item); + } + } else { + this.ephemeralContainerStatuses = null; + } + return (A) this; } - public A withEphemeralContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... ephemeralContainerStatuses) { - if (this.ephemeralContainerStatuses != null) {this.ephemeralContainerStatuses.clear();} - if (ephemeralContainerStatuses != null) {for (io.kubernetes.client.openapi.models.V1ContainerStatus item :ephemeralContainerStatuses){ this.addToEphemeralContainerStatuses(item);}} return (A) this; + + public A withEphemeralContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... ephemeralContainerStatuses) { + if (this.ephemeralContainerStatuses != null) { + this.ephemeralContainerStatuses.clear(); + } + if (ephemeralContainerStatuses != null) { + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : + ephemeralContainerStatuses) { + this.addToEphemeralContainerStatuses(item); + } + } + return (A) this; } + public java.lang.Boolean hasEphemeralContainerStatuses() { return ephemeralContainerStatuses != null && !ephemeralContainerStatuses.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested addNewEphemeralContainerStatus() { - return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.EphemeralContainerStatusesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + addNewEphemeralContainerStatus() { + return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl + .EphemeralContainerStatusesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested addNewEphemeralContainerStatusLike(io.kubernetes.client.openapi.models.V1ContainerStatus item) { - return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.EphemeralContainerStatusesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + addNewEphemeralContainerStatusLike( + io.kubernetes.client.openapi.models.V1ContainerStatus item) { + return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl + .EphemeralContainerStatusesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested setNewEphemeralContainerStatusLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item) { - return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.EphemeralContainerStatusesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + setNewEphemeralContainerStatusLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item) { + return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl + .EphemeralContainerStatusesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested editEphemeralContainerStatus(java.lang.Integer index) { - if (ephemeralContainerStatuses.size() <= index) throw new RuntimeException("Can't edit ephemeralContainerStatuses. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + editEphemeralContainerStatus(java.lang.Integer index) { + if (ephemeralContainerStatuses.size() <= index) + throw new RuntimeException("Can't edit ephemeralContainerStatuses. Index exceeds size."); return setNewEphemeralContainerStatusLike(index, buildEphemeralContainerStatus(index)); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested editFirstEphemeralContainerStatus() { - if (ephemeralContainerStatuses.size() == 0) throw new RuntimeException("Can't edit first ephemeralContainerStatuses. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + editFirstEphemeralContainerStatus() { + if (ephemeralContainerStatuses.size() == 0) + throw new RuntimeException("Can't edit first ephemeralContainerStatuses. The list is empty."); return setNewEphemeralContainerStatusLike(0, buildEphemeralContainerStatus(0)); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested editLastEphemeralContainerStatus() { + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + editLastEphemeralContainerStatus() { int index = ephemeralContainerStatuses.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last ephemeralContainerStatuses. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last ephemeralContainerStatuses. The list is empty."); return setNewEphemeralContainerStatusLike(index, buildEphemeralContainerStatus(index)); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested editMatchingEphemeralContainerStatus(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested + editMatchingEphemeralContainerStatus( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("initContainerStatuses").add(index >= 0 ? index : _visitables.get("initContainerStatuses").size(), builder);this.initContainerStatuses.add(index >= 0 ? index : initContainerStatuses.size(), builder); return (A)this; + + public A addToInitContainerStatuses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item) { + if (this.initContainerStatuses == null) { + this.initContainerStatuses = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables + .get("initContainerStatuses") + .add(index >= 0 ? index : _visitables.get("initContainerStatuses").size(), builder); + this.initContainerStatuses.add(index >= 0 ? index : initContainerStatuses.size(), builder); + return (A) this; } - public A setToInitContainerStatuses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item) { - if (this.initContainerStatuses == null) {this.initContainerStatuses = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); - if (index < 0 || index >= _visitables.get("initContainerStatuses").size()) { _visitables.get("initContainerStatuses").add(builder); } else { _visitables.get("initContainerStatuses").set(index, builder);} - if (index < 0 || index >= initContainerStatuses.size()) { initContainerStatuses.add(builder); } else { initContainerStatuses.set(index, builder);} - return (A)this; + + public A setToInitContainerStatuses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item) { + if (this.initContainerStatuses == null) { + this.initContainerStatuses = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + if (index < 0 || index >= _visitables.get("initContainerStatuses").size()) { + _visitables.get("initContainerStatuses").add(builder); + } else { + _visitables.get("initContainerStatuses").set(index, builder); + } + if (index < 0 || index >= initContainerStatuses.size()) { + initContainerStatuses.add(builder); + } else { + initContainerStatuses.set(index, builder); + } + return (A) this; } - public A addToInitContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... items) { - if (this.initContainerStatuses == null) {this.initContainerStatuses = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) {io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("initContainerStatuses").add(builder);this.initContainerStatuses.add(builder);} return (A)this; + + public A addToInitContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... items) { + if (this.initContainerStatuses == null) { + this.initContainerStatuses = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) { + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables.get("initContainerStatuses").add(builder); + this.initContainerStatuses.add(builder); + } + return (A) this; } - public A addAllToInitContainerStatuses(java.util.Collection items) { - if (this.initContainerStatuses == null) {this.initContainerStatuses = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) {io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("initContainerStatuses").add(builder);this.initContainerStatuses.add(builder);} return (A)this; + + public A addAllToInitContainerStatuses( + java.util.Collection items) { + if (this.initContainerStatuses == null) { + this.initContainerStatuses = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) { + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables.get("initContainerStatuses").add(builder); + this.initContainerStatuses.add(builder); + } + return (A) this; } - public A removeFromInitContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... items) { - for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) {io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("initContainerStatuses").remove(builder);if (this.initContainerStatuses != null) {this.initContainerStatuses.remove(builder);}} return (A)this; + + public A removeFromInitContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... items) { + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) { + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables.get("initContainerStatuses").remove(builder); + if (this.initContainerStatuses != null) { + this.initContainerStatuses.remove(builder); + } + } + return (A) this; } - public A removeAllFromInitContainerStatuses(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) {io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item);_visitables.get("initContainerStatuses").remove(builder);if (this.initContainerStatuses != null) {this.initContainerStatuses.remove(builder);}} return (A)this; + + public A removeAllFromInitContainerStatuses( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : items) { + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = + new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(item); + _visitables.get("initContainerStatuses").remove(builder); + if (this.initContainerStatuses != null) { + this.initContainerStatuses.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromInitContainerStatuses(java.util.function.Predicate predicate) { + + public A removeMatchingFromInitContainerStatuses( + java.util.function.Predicate + predicate) { if (initContainerStatuses == null) return (A) this; - final Iterator each = initContainerStatuses.iterator(); + final Iterator each = + initContainerStatuses.iterator(); final List visitables = _visitables.get("initContainerStatuses"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder = each.next(); @@ -433,162 +942,305 @@ public A removeMatchingFromInitContainerStatuses(java.util.function.Predicate getInitContainerStatuses() { + public java.util.List + getInitContainerStatuses() { return initContainerStatuses != null ? build(initContainerStatuses) : null; } - public java.util.List buildInitContainerStatuses() { + + public java.util.List + buildInitContainerStatuses() { return initContainerStatuses != null ? build(initContainerStatuses) : null; } - public io.kubernetes.client.openapi.models.V1ContainerStatus buildInitContainerStatus(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ContainerStatus buildInitContainerStatus( + java.lang.Integer index) { return this.initContainerStatuses.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ContainerStatus buildFirstInitContainerStatus() { return this.initContainerStatuses.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ContainerStatus buildLastInitContainerStatus() { return this.initContainerStatuses.get(initContainerStatuses.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ContainerStatus buildMatchingInitContainerStatus(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerStatusBuilder item: initContainerStatuses) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ContainerStatus buildMatchingInitContainerStatus( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerStatusBuilder item : + initContainerStatuses) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingInitContainerStatus(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ContainerStatusBuilder item: initContainerStatuses) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingInitContainerStatus( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ContainerStatusBuilder item : + initContainerStatuses) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withInitContainerStatuses(java.util.List initContainerStatuses) { - if (this.initContainerStatuses != null) { _visitables.get("initContainerStatuses").removeAll(this.initContainerStatuses);} - if (initContainerStatuses != null) {this.initContainerStatuses = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ContainerStatus item : initContainerStatuses){this.addToInitContainerStatuses(item);}} else { this.initContainerStatuses = null;} return (A) this; + + public A withInitContainerStatuses( + java.util.List initContainerStatuses) { + if (this.initContainerStatuses != null) { + _visitables.get("initContainerStatuses").removeAll(this.initContainerStatuses); + } + if (initContainerStatuses != null) { + this.initContainerStatuses = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : initContainerStatuses) { + this.addToInitContainerStatuses(item); + } + } else { + this.initContainerStatuses = null; + } + return (A) this; } - public A withInitContainerStatuses(io.kubernetes.client.openapi.models.V1ContainerStatus... initContainerStatuses) { - if (this.initContainerStatuses != null) {this.initContainerStatuses.clear();} - if (initContainerStatuses != null) {for (io.kubernetes.client.openapi.models.V1ContainerStatus item :initContainerStatuses){ this.addToInitContainerStatuses(item);}} return (A) this; + + public A withInitContainerStatuses( + io.kubernetes.client.openapi.models.V1ContainerStatus... initContainerStatuses) { + if (this.initContainerStatuses != null) { + this.initContainerStatuses.clear(); + } + if (initContainerStatuses != null) { + for (io.kubernetes.client.openapi.models.V1ContainerStatus item : initContainerStatuses) { + this.addToInitContainerStatuses(item); + } + } + return (A) this; } + public java.lang.Boolean hasInitContainerStatuses() { return initContainerStatuses != null && !initContainerStatuses.isEmpty(); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested addNewInitContainerStatus() { - return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.InitContainerStatusesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + addNewInitContainerStatus() { + return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl + .InitContainerStatusesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested addNewInitContainerStatusLike(io.kubernetes.client.openapi.models.V1ContainerStatus item) { - return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.InitContainerStatusesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + addNewInitContainerStatusLike(io.kubernetes.client.openapi.models.V1ContainerStatus item) { + return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl + .InitContainerStatusesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested setNewInitContainerStatusLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item) { - return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.InitContainerStatusesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + setNewInitContainerStatusLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item) { + return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl + .InitContainerStatusesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested editInitContainerStatus(java.lang.Integer index) { - if (initContainerStatuses.size() <= index) throw new RuntimeException("Can't edit initContainerStatuses. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + editInitContainerStatus(java.lang.Integer index) { + if (initContainerStatuses.size() <= index) + throw new RuntimeException("Can't edit initContainerStatuses. Index exceeds size."); return setNewInitContainerStatusLike(index, buildInitContainerStatus(index)); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested editFirstInitContainerStatus() { - if (initContainerStatuses.size() == 0) throw new RuntimeException("Can't edit first initContainerStatuses. The list is empty."); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + editFirstInitContainerStatus() { + if (initContainerStatuses.size() == 0) + throw new RuntimeException("Can't edit first initContainerStatuses. The list is empty."); return setNewInitContainerStatusLike(0, buildInitContainerStatus(0)); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested editLastInitContainerStatus() { + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + editLastInitContainerStatus() { int index = initContainerStatuses.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last initContainerStatuses. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last initContainerStatuses. The list is empty."); return setNewInitContainerStatusLike(index, buildInitContainerStatus(index)); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested editMatchingInitContainerStatus(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested + editMatchingInitContainerStatus( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1PodIPBuilder builder = new io.kubernetes.client.openapi.models.V1PodIPBuilder(item);_visitables.get("podIPs").add(index >= 0 ? index : _visitables.get("podIPs").size(), builder);this.podIPs.add(index >= 0 ? index : podIPs.size(), builder); return (A)this; + + public A addToPodIPs(java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodIP item) { + if (this.podIPs == null) { + this.podIPs = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodIPBuilder builder = + new io.kubernetes.client.openapi.models.V1PodIPBuilder(item); + _visitables.get("podIPs").add(index >= 0 ? index : _visitables.get("podIPs").size(), builder); + this.podIPs.add(index >= 0 ? index : podIPs.size(), builder); + return (A) this; } - public A setToPodIPs(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodIP item) { - if (this.podIPs == null) {this.podIPs = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodIPBuilder builder = new io.kubernetes.client.openapi.models.V1PodIPBuilder(item); - if (index < 0 || index >= _visitables.get("podIPs").size()) { _visitables.get("podIPs").add(builder); } else { _visitables.get("podIPs").set(index, builder);} - if (index < 0 || index >= podIPs.size()) { podIPs.add(builder); } else { podIPs.set(index, builder);} - return (A)this; + + public A setToPodIPs(java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodIP item) { + if (this.podIPs == null) { + this.podIPs = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodIPBuilder builder = + new io.kubernetes.client.openapi.models.V1PodIPBuilder(item); + if (index < 0 || index >= _visitables.get("podIPs").size()) { + _visitables.get("podIPs").add(builder); + } else { + _visitables.get("podIPs").set(index, builder); + } + if (index < 0 || index >= podIPs.size()) { + podIPs.add(builder); + } else { + podIPs.set(index, builder); + } + return (A) this; } + public A addToPodIPs(io.kubernetes.client.openapi.models.V1PodIP... items) { - if (this.podIPs == null) {this.podIPs = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodIP item : items) {io.kubernetes.client.openapi.models.V1PodIPBuilder builder = new io.kubernetes.client.openapi.models.V1PodIPBuilder(item);_visitables.get("podIPs").add(builder);this.podIPs.add(builder);} return (A)this; + if (this.podIPs == null) { + this.podIPs = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PodIP item : items) { + io.kubernetes.client.openapi.models.V1PodIPBuilder builder = + new io.kubernetes.client.openapi.models.V1PodIPBuilder(item); + _visitables.get("podIPs").add(builder); + this.podIPs.add(builder); + } + return (A) this; } + public A addAllToPodIPs(java.util.Collection items) { - if (this.podIPs == null) {this.podIPs = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodIP item : items) {io.kubernetes.client.openapi.models.V1PodIPBuilder builder = new io.kubernetes.client.openapi.models.V1PodIPBuilder(item);_visitables.get("podIPs").add(builder);this.podIPs.add(builder);} return (A)this; + if (this.podIPs == null) { + this.podIPs = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PodIP item : items) { + io.kubernetes.client.openapi.models.V1PodIPBuilder builder = + new io.kubernetes.client.openapi.models.V1PodIPBuilder(item); + _visitables.get("podIPs").add(builder); + this.podIPs.add(builder); + } + return (A) this; } + public A removeFromPodIPs(io.kubernetes.client.openapi.models.V1PodIP... items) { - for (io.kubernetes.client.openapi.models.V1PodIP item : items) {io.kubernetes.client.openapi.models.V1PodIPBuilder builder = new io.kubernetes.client.openapi.models.V1PodIPBuilder(item);_visitables.get("podIPs").remove(builder);if (this.podIPs != null) {this.podIPs.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1PodIP item : items) { + io.kubernetes.client.openapi.models.V1PodIPBuilder builder = + new io.kubernetes.client.openapi.models.V1PodIPBuilder(item); + _visitables.get("podIPs").remove(builder); + if (this.podIPs != null) { + this.podIPs.remove(builder); + } + } + return (A) this; } - public A removeAllFromPodIPs(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PodIP item : items) {io.kubernetes.client.openapi.models.V1PodIPBuilder builder = new io.kubernetes.client.openapi.models.V1PodIPBuilder(item);_visitables.get("podIPs").remove(builder);if (this.podIPs != null) {this.podIPs.remove(builder);}} return (A)this; + + public A removeAllFromPodIPs( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PodIP item : items) { + io.kubernetes.client.openapi.models.V1PodIPBuilder builder = + new io.kubernetes.client.openapi.models.V1PodIPBuilder(item); + _visitables.get("podIPs").remove(builder); + if (this.podIPs != null) { + this.podIPs.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPodIPs(java.util.function.Predicate predicate) { + + public A removeMatchingFromPodIPs( + java.util.function.Predicate predicate) { if (podIPs == null) return (A) this; final Iterator each = podIPs.iterator(); final List visitables = _visitables.get("podIPs"); @@ -599,227 +1251,365 @@ public A removeMatchingFromPodIPs(java.util.function.Predicate getPodIPs() { return podIPs != null ? build(podIPs) : null; } + public java.util.List buildPodIPs() { return podIPs != null ? build(podIPs) : null; } + public io.kubernetes.client.openapi.models.V1PodIP buildPodIP(java.lang.Integer index) { return this.podIPs.get(index).build(); } + public io.kubernetes.client.openapi.models.V1PodIP buildFirstPodIP() { return this.podIPs.get(0).build(); } + public io.kubernetes.client.openapi.models.V1PodIP buildLastPodIP() { return this.podIPs.get(podIPs.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PodIP buildMatchingPodIP(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodIPBuilder item: podIPs) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PodIP buildMatchingPodIP( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1PodIPBuilder item : podIPs) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPodIP(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodIPBuilder item: podIPs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPodIP( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1PodIPBuilder item : podIPs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withPodIPs(java.util.List podIPs) { - if (this.podIPs != null) { _visitables.get("podIPs").removeAll(this.podIPs);} - if (podIPs != null) {this.podIPs = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PodIP item : podIPs){this.addToPodIPs(item);}} else { this.podIPs = null;} return (A) this; + if (this.podIPs != null) { + _visitables.get("podIPs").removeAll(this.podIPs); + } + if (podIPs != null) { + this.podIPs = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PodIP item : podIPs) { + this.addToPodIPs(item); + } + } else { + this.podIPs = null; + } + return (A) this; } + public A withPodIPs(io.kubernetes.client.openapi.models.V1PodIP... podIPs) { - if (this.podIPs != null) {this.podIPs.clear();} - if (podIPs != null) {for (io.kubernetes.client.openapi.models.V1PodIP item :podIPs){ this.addToPodIPs(item);}} return (A) this; + if (this.podIPs != null) { + this.podIPs.clear(); + } + if (podIPs != null) { + for (io.kubernetes.client.openapi.models.V1PodIP item : podIPs) { + this.addToPodIPs(item); + } + } + return (A) this; } + public java.lang.Boolean hasPodIPs() { return podIPs != null && !podIPs.isEmpty(); } + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested addNewPodIP() { return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.PodIPsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested addNewPodIPLike(io.kubernetes.client.openapi.models.V1PodIP item) { + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested addNewPodIPLike( + io.kubernetes.client.openapi.models.V1PodIP item) { return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.PodIPsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested setNewPodIPLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodIP item) { - return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.PodIPsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested setNewPodIPLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodIP item) { + return new io.kubernetes.client.openapi.models.V1PodStatusFluentImpl.PodIPsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested editPodIP(java.lang.Integer index) { - if (podIPs.size() <= index) throw new RuntimeException("Can't edit podIPs. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested editPodIP( + java.lang.Integer index) { + if (podIPs.size() <= index) + throw new RuntimeException("Can't edit podIPs. Index exceeds size."); return setNewPodIPLike(index, buildPodIP(index)); } + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested editFirstPodIP() { - if (podIPs.size() == 0) throw new RuntimeException("Can't edit first podIPs. The list is empty."); + if (podIPs.size() == 0) + throw new RuntimeException("Can't edit first podIPs. The list is empty."); return setNewPodIPLike(0, buildPodIP(0)); } + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested editLastPodIP() { int index = podIPs.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last podIPs. The list is empty."); return setNewPodIPLike(index, buildPodIP(index)); } - public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested editMatchingPodIP(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested editMatchingPodIP( + java.util.function.Predicate predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1PodConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1PodConditionFluentImpl< + io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1PodStatusFluent.ConditionsNested, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodCondition item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1PodConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PodConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1PodConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1PodStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - public class ContainerStatusesNestedImpl extends io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested,io.kubernetes.client.fluent.Nested{ - ContainerStatusesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item) { + + public class ContainerStatusesNestedImpl + extends io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl< + io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested> + implements io.kubernetes.client.openapi.models.V1PodStatusFluent.ContainerStatusesNested, + io.kubernetes.client.fluent.Nested { + ContainerStatusesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(this, item); } + ContainerStatusesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodStatusFluentImpl.this.setToContainerStatuses(index,builder.build()); + return (N) V1PodStatusFluentImpl.this.setToContainerStatuses(index, builder.build()); } + public N endContainerStatus() { return and(); } - } - public class EphemeralContainerStatusesNestedImpl extends io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested,io.kubernetes.client.fluent.Nested{ - EphemeralContainerStatusesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item) { + + public class EphemeralContainerStatusesNestedImpl + extends io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl< + io.kubernetes.client.openapi.models.V1PodStatusFluent.EphemeralContainerStatusesNested> + implements io.kubernetes.client.openapi.models.V1PodStatusFluent + .EphemeralContainerStatusesNested< + N>, + io.kubernetes.client.fluent.Nested { + EphemeralContainerStatusesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(this, item); } + EphemeralContainerStatusesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodStatusFluentImpl.this.setToEphemeralContainerStatuses(index,builder.build()); + return (N) V1PodStatusFluentImpl.this.setToEphemeralContainerStatuses(index, builder.build()); } + public N endEphemeralContainerStatus() { return and(); } - } - public class InitContainerStatusesNestedImpl extends io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested,io.kubernetes.client.fluent.Nested{ - InitContainerStatusesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ContainerStatus item) { + + public class InitContainerStatusesNestedImpl + extends io.kubernetes.client.openapi.models.V1ContainerStatusFluentImpl< + io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested> + implements io.kubernetes.client.openapi.models.V1PodStatusFluent.InitContainerStatusesNested< + N>, + io.kubernetes.client.fluent.Nested { + InitContainerStatusesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ContainerStatus item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(this, item); } + InitContainerStatusesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ContainerStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1ContainerStatusBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodStatusFluentImpl.this.setToInitContainerStatuses(index,builder.build()); + return (N) V1PodStatusFluentImpl.this.setToInitContainerStatuses(index, builder.build()); } + public N endInitContainerStatus() { return and(); } - } - public class PodIPsNestedImpl extends io.kubernetes.client.openapi.models.V1PodIPFluentImpl> implements io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested,io.kubernetes.client.fluent.Nested{ - PodIPsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodIP item) { + + public class PodIPsNestedImpl + extends io.kubernetes.client.openapi.models.V1PodIPFluentImpl< + io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested> + implements io.kubernetes.client.openapi.models.V1PodStatusFluent.PodIPsNested, + io.kubernetes.client.fluent.Nested { + PodIPsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodIP item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1PodIPBuilder(this, item); } + PodIPsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PodIPBuilder(this); } + io.kubernetes.client.openapi.models.V1PodIPBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodStatusFluentImpl.this.setToPodIPs(index,builder.build()); + return (N) V1PodStatusFluentImpl.this.setToPodIPs(index, builder.build()); } + public N endPodIP() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateBuilder.java index 2174a4e0ff..d17454a5a5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodTemplateBuilder extends io.kubernetes.client.openapi.models.V1PodTemplateFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodTemplateBuilder + extends io.kubernetes.client.openapi.models.V1PodTemplateFluentImpl< + io.kubernetes.client.openapi.models.V1PodTemplateBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodTemplate, + io.kubernetes.client.openapi.models.V1PodTemplateBuilder> { public V1PodTemplateBuilder() { this(false); } + public V1PodTemplateBuilder(java.lang.Boolean validationEnabled) { this(new V1PodTemplate(), validationEnabled); } + public V1PodTemplateBuilder(io.kubernetes.client.openapi.models.V1PodTemplateFluent fluent) { this(fluent, false); } - public V1PodTemplateBuilder(io.kubernetes.client.openapi.models.V1PodTemplateFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodTemplateBuilder( + io.kubernetes.client.openapi.models.V1PodTemplateFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodTemplate(), validationEnabled); } - public V1PodTemplateBuilder(io.kubernetes.client.openapi.models.V1PodTemplateFluent fluent,io.kubernetes.client.openapi.models.V1PodTemplate instance) { + + public V1PodTemplateBuilder( + io.kubernetes.client.openapi.models.V1PodTemplateFluent fluent, + io.kubernetes.client.openapi.models.V1PodTemplate instance) { this(fluent, instance, false); } - public V1PodTemplateBuilder(io.kubernetes.client.openapi.models.V1PodTemplateFluent fluent,io.kubernetes.client.openapi.models.V1PodTemplate instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodTemplateBuilder( + io.kubernetes.client.openapi.models.V1PodTemplateFluent fluent, + io.kubernetes.client.openapi.models.V1PodTemplate instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +55,17 @@ public V1PodTemplateBuilder(io.kubernetes.client.openapi.models.V1PodTemplateFlu fluent.withTemplate(instance.getTemplate()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodTemplateBuilder(io.kubernetes.client.openapi.models.V1PodTemplate instance) { - this(instance,false); + this(instance, false); } - public V1PodTemplateBuilder(io.kubernetes.client.openapi.models.V1PodTemplate instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodTemplateBuilder( + io.kubernetes.client.openapi.models.V1PodTemplate instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +74,12 @@ public V1PodTemplateBuilder(io.kubernetes.client.openapi.models.V1PodTemplate in this.withTemplate(instance.getTemplate()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodTemplateFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodTemplate build() { V1PodTemplate buildable = new V1PodTemplate(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1PodTemplate build() { buildable.setTemplate(fluent.getTemplate()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodTemplateBuilder that = (V1PodTemplateBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateFluent.java index 3febab6a98..f6bdb9f691 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateFluent.java @@ -1,73 +1,112 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodTemplateFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PodTemplateFluent< + A extends io.kubernetes.client.openapi.models.V1PodTemplateFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate(); + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate(); + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template); + public java.lang.Boolean hasTemplate(); - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested withNewTemplate(); - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested + withNewTemplate(); + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested + withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested editTemplate(); - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested editOrNewTemplate(); - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested + editOrNewTemplate(); + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface TemplateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent>{ + + public interface TemplateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent< + io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested> { public N and(); + public N endTemplate(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateFluentImpl.java index 21256008ae..b3ecc50c41 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1PodTemplateFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodTemplateFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodTemplateFluent { + public V1PodTemplateFluentImpl() {} - /** - * Generated - */ -public class V1PodTemplateFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodTemplateFluent{ - public V1PodTemplateFluentImpl() { - } public V1PodTemplateFluentImpl(io.kubernetes.client.openapi.models.V1PodTemplate instance) { this.withApiVersion(instance.getApiVersion()); @@ -21,158 +27,220 @@ public V1PodTemplateFluentImpl(io.kubernetes.client.openapi.models.V1PodTemplate this.withMetadata(instance.getMetadata()); this.withTemplate(instance.getTemplate()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder template; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1PodTemplateFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1PodTemplateFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template) { _visitables.get("template").remove(this.template); - if (template!=null){ this.template= new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); _visitables.get("template").add(this.template);} return (A) this; + if (template != null) { + this.template = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); + _visitables.get("template").add(this.template); + } + return (A) this; } + public java.lang.Boolean hasTemplate() { return this.template != null; } - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested withNewTemplate() { + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested + withNewTemplate() { return new io.kubernetes.client.openapi.models.V1PodTemplateFluentImpl.TemplateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested + withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { return new io.kubernetes.client.openapi.models.V1PodTemplateFluentImpl.TemplateNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested editTemplate() { return withNewTemplateLike(getTemplate()); } - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested editOrNewTemplate() { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested + editOrNewTemplate() { + return withNewTemplateLike( + getTemplate() != null + ? getTemplate() + : new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): item); + + public io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + return withNewTemplateLike(getTemplate() != null ? getTemplate() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodTemplateFluentImpl that = (V1PodTemplateFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (template != null ? !template.equals(that.template) :that.template != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (template != null ? !template.equals(that.template) : that.template != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, template, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, template, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1PodTemplateFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1PodTemplateFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class TemplateNestedImpl extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested,io.kubernetes.client.fluent.Nested{ + + public class TemplateNestedImpl + extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl< + io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested> + implements io.kubernetes.client.openapi.models.V1PodTemplateFluent.TemplateNested, + io.kubernetes.client.fluent.Nested { TemplateNestedImpl(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this, item); } + TemplateNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder builder; + public N and() { return (N) V1PodTemplateFluentImpl.this.withTemplate(builder.build()); } + public N endTemplate() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateListBuilder.java index 6f01bd6189..2dcce68c98 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodTemplateListBuilder extends io.kubernetes.client.openapi.models.V1PodTemplateListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodTemplateListBuilder + extends io.kubernetes.client.openapi.models.V1PodTemplateListFluentImpl< + io.kubernetes.client.openapi.models.V1PodTemplateListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodTemplateList, + io.kubernetes.client.openapi.models.V1PodTemplateListBuilder> { public V1PodTemplateListBuilder() { this(false); } + public V1PodTemplateListBuilder(java.lang.Boolean validationEnabled) { this(new V1PodTemplateList(), validationEnabled); } - public V1PodTemplateListBuilder(io.kubernetes.client.openapi.models.V1PodTemplateListFluent fluent) { + + public V1PodTemplateListBuilder( + io.kubernetes.client.openapi.models.V1PodTemplateListFluent fluent) { this(fluent, false); } - public V1PodTemplateListBuilder(io.kubernetes.client.openapi.models.V1PodTemplateListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodTemplateListBuilder( + io.kubernetes.client.openapi.models.V1PodTemplateListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodTemplateList(), validationEnabled); } - public V1PodTemplateListBuilder(io.kubernetes.client.openapi.models.V1PodTemplateListFluent fluent,io.kubernetes.client.openapi.models.V1PodTemplateList instance) { + + public V1PodTemplateListBuilder( + io.kubernetes.client.openapi.models.V1PodTemplateListFluent fluent, + io.kubernetes.client.openapi.models.V1PodTemplateList instance) { this(fluent, instance, false); } - public V1PodTemplateListBuilder(io.kubernetes.client.openapi.models.V1PodTemplateListFluent fluent,io.kubernetes.client.openapi.models.V1PodTemplateList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodTemplateListBuilder( + io.kubernetes.client.openapi.models.V1PodTemplateListFluent fluent, + io.kubernetes.client.openapi.models.V1PodTemplateList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1PodTemplateListBuilder(io.kubernetes.client.openapi.models.V1PodTemplat fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodTemplateListBuilder(io.kubernetes.client.openapi.models.V1PodTemplateList instance) { - this(instance,false); + this(instance, false); } - public V1PodTemplateListBuilder(io.kubernetes.client.openapi.models.V1PodTemplateList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodTemplateListBuilder( + io.kubernetes.client.openapi.models.V1PodTemplateList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1PodTemplateListBuilder(io.kubernetes.client.openapi.models.V1PodTemplat this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodTemplateListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodTemplateList build() { V1PodTemplateList buildable = new V1PodTemplateList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1PodTemplateList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodTemplateListBuilder that = (V1PodTemplateListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateListFluent.java index 9e1b616db1..9c6f72298b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateListFluent.java @@ -1,95 +1,155 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodTemplateListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PodTemplateListFluent< + A extends io.kubernetes.client.openapi.models.V1PodTemplateListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodTemplate item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodTemplate item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodTemplate item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodTemplate item); + public A addToItems(io.kubernetes.client.openapi.models.V1PodTemplate... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1PodTemplate... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1PodTemplate buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PodTemplate buildFirstItem(); + public io.kubernetes.client.openapi.models.V1PodTemplate buildLastItem(); - public io.kubernetes.client.openapi.models.V1PodTemplate buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PodTemplate buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1PodTemplate... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1PodTemplate item); - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodTemplate item); - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1PodTemplate item); + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodTemplate item); + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodTemplateFluent>{ + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodTemplateFluent< + io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateListFluentImpl.java index cd9fd65bb6..970d2041cb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1PodTemplateListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodTemplateListFluent{ - public V1PodTemplateListFluentImpl() { - } - public V1PodTemplateListFluentImpl(io.kubernetes.client.openapi.models.V1PodTemplateList instance) { + +/** Generated */ +public class V1PodTemplateListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodTemplateListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodTemplateListFluent { + public V1PodTemplateListFluentImpl() {} + + public V1PodTemplateListFluentImpl( + io.kubernetes.client.openapi.models.V1PodTemplateList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1PodTemplateListFluentImpl(io.kubernetes.client.openapi.models.V1PodTemp this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodTemplate item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder = new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodTemplate item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder = + new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodTemplate item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder = new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodTemplate item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder = + new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1PodTemplate... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodTemplate item : items) {io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder = new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PodTemplate item : items) { + io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder = + new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PodTemplate item : items) {io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder = new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PodTemplate item : items) { + io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder = + new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1PodTemplate... items) { - for (io.kubernetes.client.openapi.models.V1PodTemplate item : items) {io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder = new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1PodTemplate item : items) { + io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder = + new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PodTemplate item : items) {io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder = new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PodTemplate item : items) { + io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder = + new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder = each.next(); @@ -87,174 +159,277 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1PodTemplate buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1PodTemplate buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1PodTemplate buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PodTemplate buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodTemplateBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PodTemplate buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodTemplateBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PodTemplateBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PodTemplateBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PodTemplate item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PodTemplate item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1PodTemplate... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1PodTemplate item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1PodTemplate item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1PodTemplateListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1PodTemplate item) { - return new io.kubernetes.client.openapi.models.V1PodTemplateListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1PodTemplate item) { + return new io.kubernetes.client.openapi.models.V1PodTemplateListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodTemplate item) { - return new io.kubernetes.client.openapi.models.V1PodTemplateListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodTemplate item) { + return new io.kubernetes.client.openapi.models.V1PodTemplateListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1PodTemplateListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1PodTemplateListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1PodTemplateListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodTemplateListFluentImpl that = (V1PodTemplateListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1PodTemplateFluentImpl> implements io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PodTemplate item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1PodTemplateFluentImpl< + io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1PodTemplateListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PodTemplate item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateBuilder(this); } + io.kubernetes.client.openapi.models.V1PodTemplateBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PodTemplateListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1PodTemplateListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1PodTemplateListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1PodTemplateListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateSpecBuilder.java index c330b8c75f..af211f9e2b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateSpecBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PodTemplateSpecBuilder extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PodTemplateSpecBuilder + extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl< + io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PodTemplateSpec, + io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder> { public V1PodTemplateSpecBuilder() { this(false); } + public V1PodTemplateSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1PodTemplateSpec(), validationEnabled); } - public V1PodTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent fluent) { + + public V1PodTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent fluent) { this(fluent, false); } - public V1PodTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PodTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PodTemplateSpec(), validationEnabled); } - public V1PodTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent fluent,io.kubernetes.client.openapi.models.V1PodTemplateSpec instance) { + + public V1PodTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent fluent, + io.kubernetes.client.openapi.models.V1PodTemplateSpec instance) { this(fluent, instance, false); } - public V1PodTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent fluent,io.kubernetes.client.openapi.models.V1PodTemplateSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PodTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent fluent, + io.kubernetes.client.openapi.models.V1PodTemplateSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMetadata(instance.getMetadata()); fluent.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PodTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1PodTemplateSpec instance) { - this(instance,false); + this(instance, false); } - public V1PodTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1PodTemplateSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PodTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1PodTemplateSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PodTemplateSpec build() { V1PodTemplateSpec buildable = new V1PodTemplateSpec(); buildable.setMetadata(fluent.getMetadata()); buildable.setSpec(fluent.getSpec()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PodTemplateSpecBuilder that = (V1PodTemplateSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateSpecFluent.java index e27e9b1662..f3f690a2ec 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateSpecFluent.java @@ -1,55 +1,92 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PodTemplateSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1PodTemplateSpecFluent< + A extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodSpec getSpec(); + public io.kubernetes.client.openapi.models.V1PodSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1PodSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1PodSpec item); + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1PodSpec item); + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PodSpec item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PodSpec item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodSpecFluent< + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested> { public N and(); + public N endSpec(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateSpecFluentImpl.java index f7e54eaf90..9631d2a84e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PodTemplateSpecFluentImpl.java @@ -1,135 +1,200 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1PodTemplateSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent { + public V1PodTemplateSpecFluentImpl() {} - /** - * Generated - */ -public class V1PodTemplateSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent{ - public V1PodTemplateSpecFluentImpl() { - } - public V1PodTemplateSpecFluentImpl(io.kubernetes.client.openapi.models.V1PodTemplateSpec instance) { + public V1PodTemplateSpecFluentImpl( + io.kubernetes.client.openapi.models.V1PodTemplateSpec instance) { this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - } + private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1PodSpecBuilder spec; - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1PodSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1PodSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1PodSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1PodSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1PodSpec item) { + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1PodSpec item) { return new io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1PodSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1PodSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PodSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1PodSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PodTemplateSpecFluentImpl that = (V1PodTemplateSpecFluentImpl) o; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(metadata, spec, super.hashCode()); + return java.util.Objects.hash(metadata, spec, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1PodTemplateSpecFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1PodSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1PodSpecFluentImpl< + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1PodSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1PodSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PodSpecBuilder builder; + public N and() { return (N) V1PodTemplateSpecFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PolicyRuleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PolicyRuleBuilder.java index 328c114429..df3e8288e2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PolicyRuleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PolicyRuleBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PolicyRuleBuilder extends io.kubernetes.client.openapi.models.V1PolicyRuleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PolicyRuleBuilder + extends io.kubernetes.client.openapi.models.V1PolicyRuleFluentImpl< + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PolicyRule, + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder> { public V1PolicyRuleBuilder() { this(false); } + public V1PolicyRuleBuilder(java.lang.Boolean validationEnabled) { this(new V1PolicyRule(), validationEnabled); } + public V1PolicyRuleBuilder(io.kubernetes.client.openapi.models.V1PolicyRuleFluent fluent) { this(fluent, false); } - public V1PolicyRuleBuilder(io.kubernetes.client.openapi.models.V1PolicyRuleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1PolicyRuleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PolicyRule(), validationEnabled); } - public V1PolicyRuleBuilder(io.kubernetes.client.openapi.models.V1PolicyRuleFluent fluent,io.kubernetes.client.openapi.models.V1PolicyRule instance) { + + public V1PolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1PolicyRuleFluent fluent, + io.kubernetes.client.openapi.models.V1PolicyRule instance) { this(fluent, instance, false); } - public V1PolicyRuleBuilder(io.kubernetes.client.openapi.models.V1PolicyRuleFluent fluent,io.kubernetes.client.openapi.models.V1PolicyRule instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1PolicyRuleFluent fluent, + io.kubernetes.client.openapi.models.V1PolicyRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiGroups(instance.getApiGroups()); fluent.withNonResourceURLs(instance.getNonResourceURLs()); @@ -31,13 +57,17 @@ public V1PolicyRuleBuilder(io.kubernetes.client.openapi.models.V1PolicyRuleFluen fluent.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PolicyRuleBuilder(io.kubernetes.client.openapi.models.V1PolicyRule instance) { - this(instance,false); + this(instance, false); } - public V1PolicyRuleBuilder(io.kubernetes.client.openapi.models.V1PolicyRule instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1PolicyRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiGroups(instance.getApiGroups()); this.withNonResourceURLs(instance.getNonResourceURLs()); @@ -48,10 +78,12 @@ public V1PolicyRuleBuilder(io.kubernetes.client.openapi.models.V1PolicyRule inst this.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PolicyRuleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PolicyRule build() { V1PolicyRule buildable = new V1PolicyRule(); buildable.setApiGroups(fluent.getApiGroups()); @@ -61,18 +93,23 @@ public io.kubernetes.client.openapi.models.V1PolicyRule build() { buildable.setVerbs(fluent.getVerbs()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PolicyRuleBuilder that = (V1PolicyRuleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PolicyRuleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PolicyRuleFluent.java index d734330aa7..6224b47180 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PolicyRuleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PolicyRuleFluent.java @@ -1,98 +1,187 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1PolicyRuleFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToApiGroups(java.lang.Integer index,java.lang.String item); - public A setToApiGroups(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1PolicyRuleFluent< + A extends io.kubernetes.client.openapi.models.V1PolicyRuleFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToApiGroups(java.lang.Integer index, java.lang.String item); + + public A setToApiGroups(java.lang.Integer index, java.lang.String item); + public A addToApiGroups(java.lang.String... items); + public A addAllToApiGroups(java.util.Collection items); + public A removeFromApiGroups(java.lang.String... items); + public A removeAllFromApiGroups(java.util.Collection items); + public java.util.List getApiGroups(); + public java.lang.String getApiGroup(java.lang.Integer index); + public java.lang.String getFirstApiGroup(); + public java.lang.String getLastApiGroup(); - public java.lang.String getMatchingApiGroup(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingApiGroup(java.util.function.Predicate predicate); + + public java.lang.String getMatchingApiGroup( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingApiGroup( + java.util.function.Predicate predicate); + public A withApiGroups(java.util.List apiGroups); + public A withApiGroups(java.lang.String... apiGroups); + public java.lang.Boolean hasApiGroups(); + public A addNewApiGroup(java.lang.String original); - public A addToNonResourceURLs(java.lang.Integer index,java.lang.String item); - public A setToNonResourceURLs(java.lang.Integer index,java.lang.String item); + + public A addToNonResourceURLs(java.lang.Integer index, java.lang.String item); + + public A setToNonResourceURLs(java.lang.Integer index, java.lang.String item); + public A addToNonResourceURLs(java.lang.String... items); + public A addAllToNonResourceURLs(java.util.Collection items); + public A removeFromNonResourceURLs(java.lang.String... items); + public A removeAllFromNonResourceURLs(java.util.Collection items); + public java.util.List getNonResourceURLs(); + public java.lang.String getNonResourceURL(java.lang.Integer index); + public java.lang.String getFirstNonResourceURL(); + public java.lang.String getLastNonResourceURL(); - public java.lang.String getMatchingNonResourceURL(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingNonResourceURL(java.util.function.Predicate predicate); + + public java.lang.String getMatchingNonResourceURL( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingNonResourceURL( + java.util.function.Predicate predicate); + public A withNonResourceURLs(java.util.List nonResourceURLs); + public A withNonResourceURLs(java.lang.String... nonResourceURLs); + public java.lang.Boolean hasNonResourceURLs(); + public A addNewNonResourceURL(java.lang.String original); - public A addToResourceNames(java.lang.Integer index,java.lang.String item); - public A setToResourceNames(java.lang.Integer index,java.lang.String item); + + public A addToResourceNames(java.lang.Integer index, java.lang.String item); + + public A setToResourceNames(java.lang.Integer index, java.lang.String item); + public A addToResourceNames(java.lang.String... items); + public A addAllToResourceNames(java.util.Collection items); + public A removeFromResourceNames(java.lang.String... items); + public A removeAllFromResourceNames(java.util.Collection items); + public java.util.List getResourceNames(); + public java.lang.String getResourceName(java.lang.Integer index); + public java.lang.String getFirstResourceName(); + public java.lang.String getLastResourceName(); - public java.lang.String getMatchingResourceName(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingResourceName(java.util.function.Predicate predicate); + + public java.lang.String getMatchingResourceName( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingResourceName( + java.util.function.Predicate predicate); + public A withResourceNames(java.util.List resourceNames); + public A withResourceNames(java.lang.String... resourceNames); + public java.lang.Boolean hasResourceNames(); + public A addNewResourceName(java.lang.String original); - public A addToResources(java.lang.Integer index,java.lang.String item); - public A setToResources(java.lang.Integer index,java.lang.String item); + + public A addToResources(java.lang.Integer index, java.lang.String item); + + public A setToResources(java.lang.Integer index, java.lang.String item); + public A addToResources(java.lang.String... items); + public A addAllToResources(java.util.Collection items); + public A removeFromResources(java.lang.String... items); + public A removeAllFromResources(java.util.Collection items); + public java.util.List getResources(); + public java.lang.String getResource(java.lang.Integer index); + public java.lang.String getFirstResource(); + public java.lang.String getLastResource(); - public java.lang.String getMatchingResource(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingResource(java.util.function.Predicate predicate); + + public java.lang.String getMatchingResource( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingResource( + java.util.function.Predicate predicate); + public A withResources(java.util.List resources); + public A withResources(java.lang.String... resources); + public java.lang.Boolean hasResources(); + public A addNewResource(java.lang.String original); - public A addToVerbs(java.lang.Integer index,java.lang.String item); - public A setToVerbs(java.lang.Integer index,java.lang.String item); + + public A addToVerbs(java.lang.Integer index, java.lang.String item); + + public A setToVerbs(java.lang.Integer index, java.lang.String item); + public A addToVerbs(java.lang.String... items); + public A addAllToVerbs(java.util.Collection items); + public A removeFromVerbs(java.lang.String... items); + public A removeAllFromVerbs(java.util.Collection items); + public java.util.List getVerbs(); + public java.lang.String getVerb(java.lang.Integer index); + public java.lang.String getFirstVerb(); + public java.lang.String getLastVerb(); + public java.lang.String getMatchingVerb(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate); + public A withVerbs(java.util.List verbs); + public A withVerbs(java.lang.String... verbs); + public java.lang.Boolean hasVerbs(); + public A addNewVerb(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PolicyRuleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PolicyRuleFluentImpl.java index 636284f729..b6c194b6e1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PolicyRuleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PolicyRuleFluentImpl.java @@ -1,21 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.ArrayList; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public class V1PolicyRuleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PolicyRuleFluent{ - public V1PolicyRuleFluentImpl() { - } +/** Generated */ +public class V1PolicyRuleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PolicyRuleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PolicyRuleFluent { + public V1PolicyRuleFluentImpl() {} + public V1PolicyRuleFluentImpl(io.kubernetes.client.openapi.models.V1PolicyRule instance) { this.withApiGroups(instance.getApiGroups()); @@ -26,296 +29,644 @@ public V1PolicyRuleFluentImpl(io.kubernetes.client.openapi.models.V1PolicyRule i this.withResources(instance.getResources()); this.withVerbs(instance.getVerbs()); - } + private java.util.List apiGroups; private java.util.List nonResourceURLs; private java.util.List resourceNames; private java.util.List resources; private java.util.List verbs; - public A addToApiGroups(java.lang.Integer index,java.lang.String item) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} + + public A addToApiGroups(java.lang.Integer index, java.lang.String item) { + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } this.apiGroups.add(index, item); - return (A)this; + return (A) this; } - public A setToApiGroups(java.lang.Integer index,java.lang.String item) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - this.apiGroups.set(index, item); return (A)this; + + public A setToApiGroups(java.lang.Integer index, java.lang.String item) { + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + this.apiGroups.set(index, item); + return (A) this; } + public A addToApiGroups(java.lang.String... items) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.apiGroups.add(item);} return (A)this; + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.apiGroups.add(item); + } + return (A) this; } + public A addAllToApiGroups(java.util.Collection items) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.apiGroups.add(item);} return (A)this; + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.apiGroups.add(item); + } + return (A) this; } + public A removeFromApiGroups(java.lang.String... items) { - for (java.lang.String item : items) {if (this.apiGroups!= null){ this.apiGroups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.apiGroups != null) { + this.apiGroups.remove(item); + } + } + return (A) this; } + public A removeAllFromApiGroups(java.util.Collection items) { - for (java.lang.String item : items) {if (this.apiGroups!= null){ this.apiGroups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.apiGroups != null) { + this.apiGroups.remove(item); + } + } + return (A) this; } + public java.util.List getApiGroups() { return this.apiGroups; } + public java.lang.String getApiGroup(java.lang.Integer index) { return this.apiGroups.get(index); } + public java.lang.String getFirstApiGroup() { return this.apiGroups.get(0); } + public java.lang.String getLastApiGroup() { return this.apiGroups.get(apiGroups.size() - 1); } - public java.lang.String getMatchingApiGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: apiGroups) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingApiGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : apiGroups) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingApiGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: apiGroups) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingApiGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : apiGroups) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withApiGroups(java.util.List apiGroups) { - if (apiGroups != null) {this.apiGroups = new java.util.ArrayList(); for (java.lang.String item : apiGroups){this.addToApiGroups(item);}} else { this.apiGroups = null;} return (A) this; + if (apiGroups != null) { + this.apiGroups = new java.util.ArrayList(); + for (java.lang.String item : apiGroups) { + this.addToApiGroups(item); + } + } else { + this.apiGroups = null; + } + return (A) this; } + public A withApiGroups(java.lang.String... apiGroups) { - if (this.apiGroups != null) {this.apiGroups.clear();} - if (apiGroups != null) {for (java.lang.String item :apiGroups){ this.addToApiGroups(item);}} return (A) this; + if (this.apiGroups != null) { + this.apiGroups.clear(); + } + if (apiGroups != null) { + for (java.lang.String item : apiGroups) { + this.addToApiGroups(item); + } + } + return (A) this; } + public java.lang.Boolean hasApiGroups() { return apiGroups != null && !apiGroups.isEmpty(); } + public A addNewApiGroup(java.lang.String original) { - return (A)addToApiGroups(new String(original)); + return (A) addToApiGroups(new String(original)); } - public A addToNonResourceURLs(java.lang.Integer index,java.lang.String item) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} + + public A addToNonResourceURLs(java.lang.Integer index, java.lang.String item) { + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } this.nonResourceURLs.add(index, item); - return (A)this; + return (A) this; } - public A setToNonResourceURLs(java.lang.Integer index,java.lang.String item) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} - this.nonResourceURLs.set(index, item); return (A)this; + + public A setToNonResourceURLs(java.lang.Integer index, java.lang.String item) { + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } + this.nonResourceURLs.set(index, item); + return (A) this; } + public A addToNonResourceURLs(java.lang.String... items) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.nonResourceURLs.add(item);} return (A)this; + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.nonResourceURLs.add(item); + } + return (A) this; } + public A addAllToNonResourceURLs(java.util.Collection items) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.nonResourceURLs.add(item);} return (A)this; + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.nonResourceURLs.add(item); + } + return (A) this; } + public A removeFromNonResourceURLs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.nonResourceURLs!= null){ this.nonResourceURLs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.nonResourceURLs != null) { + this.nonResourceURLs.remove(item); + } + } + return (A) this; } + public A removeAllFromNonResourceURLs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.nonResourceURLs!= null){ this.nonResourceURLs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.nonResourceURLs != null) { + this.nonResourceURLs.remove(item); + } + } + return (A) this; } + public java.util.List getNonResourceURLs() { return this.nonResourceURLs; } + public java.lang.String getNonResourceURL(java.lang.Integer index) { return this.nonResourceURLs.get(index); } + public java.lang.String getFirstNonResourceURL() { return this.nonResourceURLs.get(0); } + public java.lang.String getLastNonResourceURL() { return this.nonResourceURLs.get(nonResourceURLs.size() - 1); } - public java.lang.String getMatchingNonResourceURL(java.util.function.Predicate predicate) { - for (java.lang.String item: nonResourceURLs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingNonResourceURL( + java.util.function.Predicate predicate) { + for (java.lang.String item : nonResourceURLs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingNonResourceURL(java.util.function.Predicate predicate) { - for (java.lang.String item: nonResourceURLs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingNonResourceURL( + java.util.function.Predicate predicate) { + for (java.lang.String item : nonResourceURLs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withNonResourceURLs(java.util.List nonResourceURLs) { - if (nonResourceURLs != null) {this.nonResourceURLs = new java.util.ArrayList(); for (java.lang.String item : nonResourceURLs){this.addToNonResourceURLs(item);}} else { this.nonResourceURLs = null;} return (A) this; + if (nonResourceURLs != null) { + this.nonResourceURLs = new java.util.ArrayList(); + for (java.lang.String item : nonResourceURLs) { + this.addToNonResourceURLs(item); + } + } else { + this.nonResourceURLs = null; + } + return (A) this; } + public A withNonResourceURLs(java.lang.String... nonResourceURLs) { - if (this.nonResourceURLs != null) {this.nonResourceURLs.clear();} - if (nonResourceURLs != null) {for (java.lang.String item :nonResourceURLs){ this.addToNonResourceURLs(item);}} return (A) this; + if (this.nonResourceURLs != null) { + this.nonResourceURLs.clear(); + } + if (nonResourceURLs != null) { + for (java.lang.String item : nonResourceURLs) { + this.addToNonResourceURLs(item); + } + } + return (A) this; } + public java.lang.Boolean hasNonResourceURLs() { return nonResourceURLs != null && !nonResourceURLs.isEmpty(); } + public A addNewNonResourceURL(java.lang.String original) { - return (A)addToNonResourceURLs(new String(original)); + return (A) addToNonResourceURLs(new String(original)); } - public A addToResourceNames(java.lang.Integer index,java.lang.String item) { - if (this.resourceNames == null) {this.resourceNames = new java.util.ArrayList();} + + public A addToResourceNames(java.lang.Integer index, java.lang.String item) { + if (this.resourceNames == null) { + this.resourceNames = new java.util.ArrayList(); + } this.resourceNames.add(index, item); - return (A)this; + return (A) this; } - public A setToResourceNames(java.lang.Integer index,java.lang.String item) { - if (this.resourceNames == null) {this.resourceNames = new java.util.ArrayList();} - this.resourceNames.set(index, item); return (A)this; + + public A setToResourceNames(java.lang.Integer index, java.lang.String item) { + if (this.resourceNames == null) { + this.resourceNames = new java.util.ArrayList(); + } + this.resourceNames.set(index, item); + return (A) this; } + public A addToResourceNames(java.lang.String... items) { - if (this.resourceNames == null) {this.resourceNames = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resourceNames.add(item);} return (A)this; + if (this.resourceNames == null) { + this.resourceNames = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resourceNames.add(item); + } + return (A) this; } + public A addAllToResourceNames(java.util.Collection items) { - if (this.resourceNames == null) {this.resourceNames = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resourceNames.add(item);} return (A)this; + if (this.resourceNames == null) { + this.resourceNames = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resourceNames.add(item); + } + return (A) this; } + public A removeFromResourceNames(java.lang.String... items) { - for (java.lang.String item : items) {if (this.resourceNames!= null){ this.resourceNames.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resourceNames != null) { + this.resourceNames.remove(item); + } + } + return (A) this; } + public A removeAllFromResourceNames(java.util.Collection items) { - for (java.lang.String item : items) {if (this.resourceNames!= null){ this.resourceNames.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resourceNames != null) { + this.resourceNames.remove(item); + } + } + return (A) this; } + public java.util.List getResourceNames() { return this.resourceNames; } + public java.lang.String getResourceName(java.lang.Integer index) { return this.resourceNames.get(index); } + public java.lang.String getFirstResourceName() { return this.resourceNames.get(0); } + public java.lang.String getLastResourceName() { return this.resourceNames.get(resourceNames.size() - 1); } - public java.lang.String getMatchingResourceName(java.util.function.Predicate predicate) { - for (java.lang.String item: resourceNames) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingResourceName( + java.util.function.Predicate predicate) { + for (java.lang.String item : resourceNames) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingResourceName(java.util.function.Predicate predicate) { - for (java.lang.String item: resourceNames) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingResourceName( + java.util.function.Predicate predicate) { + for (java.lang.String item : resourceNames) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withResourceNames(java.util.List resourceNames) { - if (resourceNames != null) {this.resourceNames = new java.util.ArrayList(); for (java.lang.String item : resourceNames){this.addToResourceNames(item);}} else { this.resourceNames = null;} return (A) this; + if (resourceNames != null) { + this.resourceNames = new java.util.ArrayList(); + for (java.lang.String item : resourceNames) { + this.addToResourceNames(item); + } + } else { + this.resourceNames = null; + } + return (A) this; } + public A withResourceNames(java.lang.String... resourceNames) { - if (this.resourceNames != null) {this.resourceNames.clear();} - if (resourceNames != null) {for (java.lang.String item :resourceNames){ this.addToResourceNames(item);}} return (A) this; + if (this.resourceNames != null) { + this.resourceNames.clear(); + } + if (resourceNames != null) { + for (java.lang.String item : resourceNames) { + this.addToResourceNames(item); + } + } + return (A) this; } + public java.lang.Boolean hasResourceNames() { return resourceNames != null && !resourceNames.isEmpty(); } + public A addNewResourceName(java.lang.String original) { - return (A)addToResourceNames(new String(original)); + return (A) addToResourceNames(new String(original)); } - public A addToResources(java.lang.Integer index,java.lang.String item) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} + + public A addToResources(java.lang.Integer index, java.lang.String item) { + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } this.resources.add(index, item); - return (A)this; + return (A) this; } - public A setToResources(java.lang.Integer index,java.lang.String item) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - this.resources.set(index, item); return (A)this; + + public A setToResources(java.lang.Integer index, java.lang.String item) { + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + this.resources.set(index, item); + return (A) this; } + public A addToResources(java.lang.String... items) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resources.add(item);} return (A)this; + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resources.add(item); + } + return (A) this; } + public A addAllToResources(java.util.Collection items) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resources.add(item);} return (A)this; + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resources.add(item); + } + return (A) this; } + public A removeFromResources(java.lang.String... items) { - for (java.lang.String item : items) {if (this.resources!= null){ this.resources.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resources != null) { + this.resources.remove(item); + } + } + return (A) this; } + public A removeAllFromResources(java.util.Collection items) { - for (java.lang.String item : items) {if (this.resources!= null){ this.resources.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resources != null) { + this.resources.remove(item); + } + } + return (A) this; } + public java.util.List getResources() { return this.resources; } + public java.lang.String getResource(java.lang.Integer index) { return this.resources.get(index); } + public java.lang.String getFirstResource() { return this.resources.get(0); } + public java.lang.String getLastResource() { return this.resources.get(resources.size() - 1); } - public java.lang.String getMatchingResource(java.util.function.Predicate predicate) { - for (java.lang.String item: resources) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingResource( + java.util.function.Predicate predicate) { + for (java.lang.String item : resources) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingResource(java.util.function.Predicate predicate) { - for (java.lang.String item: resources) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingResource( + java.util.function.Predicate predicate) { + for (java.lang.String item : resources) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withResources(java.util.List resources) { - if (resources != null) {this.resources = new java.util.ArrayList(); for (java.lang.String item : resources){this.addToResources(item);}} else { this.resources = null;} return (A) this; + if (resources != null) { + this.resources = new java.util.ArrayList(); + for (java.lang.String item : resources) { + this.addToResources(item); + } + } else { + this.resources = null; + } + return (A) this; } + public A withResources(java.lang.String... resources) { - if (this.resources != null) {this.resources.clear();} - if (resources != null) {for (java.lang.String item :resources){ this.addToResources(item);}} return (A) this; + if (this.resources != null) { + this.resources.clear(); + } + if (resources != null) { + for (java.lang.String item : resources) { + this.addToResources(item); + } + } + return (A) this; } + public java.lang.Boolean hasResources() { return resources != null && !resources.isEmpty(); } + public A addNewResource(java.lang.String original) { - return (A)addToResources(new String(original)); + return (A) addToResources(new String(original)); } - public A addToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} + + public A addToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } this.verbs.add(index, item); - return (A)this; + return (A) this; } - public A setToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - this.verbs.set(index, item); return (A)this; + + public A setToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + this.verbs.set(index, item); + return (A) this; } + public A addToVerbs(java.lang.String... items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A addAllToVerbs(java.util.Collection items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A removeFromVerbs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public A removeAllFromVerbs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public java.util.List getVerbs() { return this.verbs; } + public java.lang.String getVerb(java.lang.Integer index) { return this.verbs.get(index); } + public java.lang.String getFirstVerb() { return this.verbs.get(0); } + public java.lang.String getLastVerb() { return this.verbs.get(verbs.size() - 1); } - public java.lang.String getMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withVerbs(java.util.List verbs) { - if (verbs != null) {this.verbs = new java.util.ArrayList(); for (java.lang.String item : verbs){this.addToVerbs(item);}} else { this.verbs = null;} return (A) this; + if (verbs != null) { + this.verbs = new java.util.ArrayList(); + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } else { + this.verbs = null; + } + return (A) this; } + public A withVerbs(java.lang.String... verbs) { - if (this.verbs != null) {this.verbs.clear();} - if (verbs != null) {for (java.lang.String item :verbs){ this.addToVerbs(item);}} return (A) this; + if (this.verbs != null) { + this.verbs.clear(); + } + if (verbs != null) { + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } + return (A) this; } + public java.lang.Boolean hasVerbs() { return verbs != null && !verbs.isEmpty(); } + public A addNewVerb(java.lang.String original) { - return (A)addToVerbs(new String(original)); + return (A) addToVerbs(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PolicyRuleFluentImpl that = (V1PolicyRuleFluentImpl) o; - if (apiGroups != null ? !apiGroups.equals(that.apiGroups) :that.apiGroups != null) return false; - if (nonResourceURLs != null ? !nonResourceURLs.equals(that.nonResourceURLs) :that.nonResourceURLs != null) return false; - if (resourceNames != null ? !resourceNames.equals(that.resourceNames) :that.resourceNames != null) return false; - if (resources != null ? !resources.equals(that.resources) :that.resources != null) return false; - if (verbs != null ? !verbs.equals(that.verbs) :that.verbs != null) return false; + if (apiGroups != null ? !apiGroups.equals(that.apiGroups) : that.apiGroups != null) + return false; + if (nonResourceURLs != null + ? !nonResourceURLs.equals(that.nonResourceURLs) + : that.nonResourceURLs != null) return false; + if (resourceNames != null + ? !resourceNames.equals(that.resourceNames) + : that.resourceNames != null) return false; + if (resources != null ? !resources.equals(that.resources) : that.resources != null) + return false; + if (verbs != null ? !verbs.equals(that.verbs) : that.verbs != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiGroups, nonResourceURLs, resourceNames, resources, verbs, super.hashCode()); + return java.util.Objects.hash( + apiGroups, nonResourceURLs, resourceNames, resources, verbs, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortStatusBuilder.java index 1f3aa0e03a..672ca16486 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortStatusBuilder.java @@ -1,49 +1,81 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PortStatusBuilder extends io.kubernetes.client.openapi.models.V1PortStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PortStatusBuilder + extends io.kubernetes.client.openapi.models.V1PortStatusFluentImpl< + io.kubernetes.client.openapi.models.V1PortStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PortStatus, + io.kubernetes.client.openapi.models.V1PortStatusBuilder> { public V1PortStatusBuilder() { this(false); } + public V1PortStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1PortStatus(), validationEnabled); } + public V1PortStatusBuilder(io.kubernetes.client.openapi.models.V1PortStatusFluent fluent) { this(fluent, false); } - public V1PortStatusBuilder(io.kubernetes.client.openapi.models.V1PortStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PortStatusBuilder( + io.kubernetes.client.openapi.models.V1PortStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PortStatus(), validationEnabled); } - public V1PortStatusBuilder(io.kubernetes.client.openapi.models.V1PortStatusFluent fluent,io.kubernetes.client.openapi.models.V1PortStatus instance) { + + public V1PortStatusBuilder( + io.kubernetes.client.openapi.models.V1PortStatusFluent fluent, + io.kubernetes.client.openapi.models.V1PortStatus instance) { this(fluent, instance, false); } - public V1PortStatusBuilder(io.kubernetes.client.openapi.models.V1PortStatusFluent fluent,io.kubernetes.client.openapi.models.V1PortStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PortStatusBuilder( + io.kubernetes.client.openapi.models.V1PortStatusFluent fluent, + io.kubernetes.client.openapi.models.V1PortStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withError(instance.getError()); fluent.withPort(instance.getPort()); fluent.withProtocol(instance.getProtocol()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PortStatusBuilder(io.kubernetes.client.openapi.models.V1PortStatus instance) { - this(instance,false); + this(instance, false); } - public V1PortStatusBuilder(io.kubernetes.client.openapi.models.V1PortStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PortStatusBuilder( + io.kubernetes.client.openapi.models.V1PortStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withError(instance.getError()); this.withPort(instance.getPort()); this.withProtocol(instance.getProtocol()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PortStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PortStatus build() { V1PortStatus buildable = new V1PortStatus(); buildable.setError(fluent.getError()); @@ -51,18 +83,23 @@ public io.kubernetes.client.openapi.models.V1PortStatus build() { buildable.setProtocol(fluent.getProtocol()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PortStatusBuilder that = (V1PortStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortStatusFluent.java index 713f72d3bd..b4097bf461 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortStatusFluent.java @@ -1,30 +1,40 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PortStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PortStatusFluent< + A extends io.kubernetes.client.openapi.models.V1PortStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getError(); + public A withError(java.lang.String error); + public java.lang.Boolean hasError(); - - /** - * Method is deprecated. use withError instead. - */ + + /** Method is deprecated. use withError instead. */ @java.lang.Deprecated public A withNewError(java.lang.String original); + public java.lang.Integer getPort(); + public A withPort(java.lang.Integer port); + public java.lang.Boolean hasPort(); + public io.kubernetes.client.openapi.models.V1PortStatus.ProtocolEnum getProtocol(); + public A withProtocol(io.kubernetes.client.openapi.models.V1PortStatus.ProtocolEnum protocol); + public java.lang.Boolean hasProtocol(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortStatusFluentImpl.java index 8e88b40985..034ad53ffb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortStatusFluentImpl.java @@ -1,75 +1,92 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1PortStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PortStatusFluent{ - public V1PortStatusFluentImpl() { - } +/** Generated */ +public class V1PortStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PortStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PortStatusFluent { + public V1PortStatusFluentImpl() {} + public V1PortStatusFluentImpl(io.kubernetes.client.openapi.models.V1PortStatus instance) { this.withError(instance.getError()); this.withPort(instance.getPort()); this.withProtocol(instance.getProtocol()); - } + private java.lang.String error; private java.lang.Integer port; private io.kubernetes.client.openapi.models.V1PortStatus.ProtocolEnum protocol; + public java.lang.String getError() { return this.error; } + public A withError(java.lang.String error) { - this.error=error; return (A) this; + this.error = error; + return (A) this; } + public java.lang.Boolean hasError() { return this.error != null; } - - /** - * Method is deprecated. use withError instead. - */ + + /** Method is deprecated. use withError instead. */ @java.lang.Deprecated public A withNewError(java.lang.String original) { - return (A)withError(new String(original)); + return (A) withError(new String(original)); } + public java.lang.Integer getPort() { return this.port; } + public A withPort(java.lang.Integer port) { - this.port=port; return (A) this; + this.port = port; + return (A) this; } + public java.lang.Boolean hasPort() { return this.port != null; } + public io.kubernetes.client.openapi.models.V1PortStatus.ProtocolEnum getProtocol() { return this.protocol; } + public A withProtocol(io.kubernetes.client.openapi.models.V1PortStatus.ProtocolEnum protocol) { - this.protocol=protocol; return (A) this; + this.protocol = protocol; + return (A) this; } + public java.lang.Boolean hasProtocol() { return this.protocol != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PortStatusFluentImpl that = (V1PortStatusFluentImpl) o; - if (error != null ? !error.equals(that.error) :that.error != null) return false; - if (port != null ? !port.equals(that.port) :that.port != null) return false; - if (protocol != null ? !protocol.equals(that.protocol) :that.protocol != null) return false; + if (error != null ? !error.equals(that.error) : that.error != null) return false; + if (port != null ? !port.equals(that.port) : that.port != null) return false; + if (protocol != null ? !protocol.equals(that.protocol) : that.protocol != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(error, port, protocol, super.hashCode()); + return java.util.Objects.hash(error, port, protocol, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortworxVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortworxVolumeSourceBuilder.java index 04e3ee1607..29ffc55f2a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortworxVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortworxVolumeSourceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PortworxVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PortworxVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PortworxVolumeSource, + io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder> { public V1PortworxVolumeSourceBuilder() { this(false); } + public V1PortworxVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1PortworxVolumeSource(), validationEnabled); } - public V1PortworxVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent fluent) { + + public V1PortworxVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent fluent) { this(fluent, false); } - public V1PortworxVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PortworxVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PortworxVolumeSource(), validationEnabled); } - public V1PortworxVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1PortworxVolumeSource instance) { + + public V1PortworxVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1PortworxVolumeSource instance) { this(fluent, instance, false); } - public V1PortworxVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1PortworxVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PortworxVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1PortworxVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withReadOnly(instance.getReadOnly()); fluent.withVolumeID(instance.getVolumeID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PortworxVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PortworxVolumeSource instance) { - this(instance,false); + + public V1PortworxVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PortworxVolumeSource instance) { + this(instance, false); } - public V1PortworxVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1PortworxVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PortworxVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1PortworxVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withReadOnly(instance.getReadOnly()); this.withVolumeID(instance.getVolumeID()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PortworxVolumeSource build() { V1PortworxVolumeSource buildable = new V1PortworxVolumeSource(); buildable.setFsType(fluent.getFsType()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1PortworxVolumeSource build() { buildable.setVolumeID(fluent.getVolumeID()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PortworxVolumeSourceBuilder that = (V1PortworxVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortworxVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortworxVolumeSourceFluent.java index dca9c3886f..129aedd157 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortworxVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortworxVolumeSourceFluent.java @@ -1,35 +1,44 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PortworxVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PortworxVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); + public java.lang.String getVolumeID(); + public A withVolumeID(java.lang.String volumeID); + public java.lang.Boolean hasVolumeID(); - - /** - * Method is deprecated. use withVolumeID instead. - */ + + /** Method is deprecated. use withVolumeID instead. */ @java.lang.Deprecated public A withNewVolumeID(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortworxVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortworxVolumeSourceFluentImpl.java index 8d9b2230ec..d11a6ada0f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortworxVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PortworxVolumeSourceFluentImpl.java @@ -1,82 +1,99 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1PortworxVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent{ - public V1PortworxVolumeSourceFluentImpl() { - } - public V1PortworxVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1PortworxVolumeSource instance) { +/** Generated */ +public class V1PortworxVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent { + public V1PortworxVolumeSourceFluentImpl() {} + + public V1PortworxVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1PortworxVolumeSource instance) { this.withFsType(instance.getFsType()); this.withReadOnly(instance.getReadOnly()); this.withVolumeID(instance.getVolumeID()); - } + private java.lang.String fsType; private java.lang.Boolean readOnly; private java.lang.String volumeID; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public java.lang.String getVolumeID() { return this.volumeID; } + public A withVolumeID(java.lang.String volumeID) { - this.volumeID=volumeID; return (A) this; + this.volumeID = volumeID; + return (A) this; } + public java.lang.Boolean hasVolumeID() { return this.volumeID != null; } - - /** - * Method is deprecated. use withVolumeID instead. - */ + + /** Method is deprecated. use withVolumeID instead. */ @java.lang.Deprecated public A withNewVolumeID(java.lang.String original) { - return (A)withVolumeID(new String(original)); + return (A) withVolumeID(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PortworxVolumeSourceFluentImpl that = (V1PortworxVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (volumeID != null ? !volumeID.equals(that.volumeID) :that.volumeID != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (volumeID != null ? !volumeID.equals(that.volumeID) : that.volumeID != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, readOnly, volumeID, super.hashCode()); + return java.util.Objects.hash(fsType, readOnly, volumeID, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreconditionsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreconditionsBuilder.java index e5b7d71883..6cdaa900f4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreconditionsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreconditionsBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PreconditionsBuilder extends io.kubernetes.client.openapi.models.V1PreconditionsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PreconditionsBuilder + extends io.kubernetes.client.openapi.models.V1PreconditionsFluentImpl< + io.kubernetes.client.openapi.models.V1PreconditionsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Preconditions, + io.kubernetes.client.openapi.models.V1PreconditionsBuilder> { public V1PreconditionsBuilder() { this(false); } + public V1PreconditionsBuilder(java.lang.Boolean validationEnabled) { this(new V1Preconditions(), validationEnabled); } - public V1PreconditionsBuilder(io.kubernetes.client.openapi.models.V1PreconditionsFluent fluent) { + + public V1PreconditionsBuilder( + io.kubernetes.client.openapi.models.V1PreconditionsFluent fluent) { this(fluent, false); } - public V1PreconditionsBuilder(io.kubernetes.client.openapi.models.V1PreconditionsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PreconditionsBuilder( + io.kubernetes.client.openapi.models.V1PreconditionsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Preconditions(), validationEnabled); } - public V1PreconditionsBuilder(io.kubernetes.client.openapi.models.V1PreconditionsFluent fluent,io.kubernetes.client.openapi.models.V1Preconditions instance) { + + public V1PreconditionsBuilder( + io.kubernetes.client.openapi.models.V1PreconditionsFluent fluent, + io.kubernetes.client.openapi.models.V1Preconditions instance) { this(fluent, instance, false); } - public V1PreconditionsBuilder(io.kubernetes.client.openapi.models.V1PreconditionsFluent fluent,io.kubernetes.client.openapi.models.V1Preconditions instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PreconditionsBuilder( + io.kubernetes.client.openapi.models.V1PreconditionsFluent fluent, + io.kubernetes.client.openapi.models.V1Preconditions instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withResourceVersion(instance.getResourceVersion()); fluent.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PreconditionsBuilder(io.kubernetes.client.openapi.models.V1Preconditions instance) { - this(instance,false); + this(instance, false); } - public V1PreconditionsBuilder(io.kubernetes.client.openapi.models.V1Preconditions instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PreconditionsBuilder( + io.kubernetes.client.openapi.models.V1Preconditions instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withResourceVersion(instance.getResourceVersion()); this.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PreconditionsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Preconditions build() { V1Preconditions buildable = new V1Preconditions(); buildable.setResourceVersion(fluent.getResourceVersion()); buildable.setUid(fluent.getUid()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PreconditionsBuilder that = (V1PreconditionsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreconditionsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreconditionsFluent.java index 2f7b33b616..22c70cd8b6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreconditionsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreconditionsFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PreconditionsFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PreconditionsFluent< + A extends io.kubernetes.client.openapi.models.V1PreconditionsFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getResourceVersion(); + public A withResourceVersion(java.lang.String resourceVersion); + public java.lang.Boolean hasResourceVersion(); - - /** - * Method is deprecated. use withResourceVersion instead. - */ + + /** Method is deprecated. use withResourceVersion instead. */ @java.lang.Deprecated public A withNewResourceVersion(java.lang.String original); + public java.lang.String getUid(); + public A withUid(java.lang.String uid); + public java.lang.Boolean hasUid(); - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreconditionsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreconditionsFluentImpl.java index e21e423498..bb44a9c8f3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreconditionsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreconditionsFluentImpl.java @@ -1,69 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1PreconditionsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PreconditionsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PreconditionsFluent { + public V1PreconditionsFluentImpl() {} - /** - * Generated - */ -public class V1PreconditionsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PreconditionsFluent{ - public V1PreconditionsFluentImpl() { - } public V1PreconditionsFluentImpl(io.kubernetes.client.openapi.models.V1Preconditions instance) { this.withResourceVersion(instance.getResourceVersion()); this.withUid(instance.getUid()); - } + private java.lang.String resourceVersion; private java.lang.String uid; + public java.lang.String getResourceVersion() { return this.resourceVersion; } + public A withResourceVersion(java.lang.String resourceVersion) { - this.resourceVersion=resourceVersion; return (A) this; + this.resourceVersion = resourceVersion; + return (A) this; } + public java.lang.Boolean hasResourceVersion() { return this.resourceVersion != null; } - - /** - * Method is deprecated. use withResourceVersion instead. - */ + + /** Method is deprecated. use withResourceVersion instead. */ @java.lang.Deprecated public A withNewResourceVersion(java.lang.String original) { - return (A)withResourceVersion(new String(original)); + return (A) withResourceVersion(new String(original)); } + public java.lang.String getUid() { return this.uid; } + public A withUid(java.lang.String uid) { - this.uid=uid; return (A) this; + this.uid = uid; + return (A) this; } + public java.lang.Boolean hasUid() { return this.uid != null; } - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original) { - return (A)withUid(new String(original)); + return (A) withUid(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PreconditionsFluentImpl that = (V1PreconditionsFluentImpl) o; - if (resourceVersion != null ? !resourceVersion.equals(that.resourceVersion) :that.resourceVersion != null) return false; - if (uid != null ? !uid.equals(that.uid) :that.uid != null) return false; + if (resourceVersion != null + ? !resourceVersion.equals(that.resourceVersion) + : that.resourceVersion != null) return false; + if (uid != null ? !uid.equals(that.uid) : that.uid != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(resourceVersion, uid, super.hashCode()); + return java.util.Objects.hash(resourceVersion, uid, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreferredSchedulingTermBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreferredSchedulingTermBuilder.java index 1d774af7ec..c698880e70 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreferredSchedulingTermBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreferredSchedulingTermBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PreferredSchedulingTermBuilder extends io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PreferredSchedulingTermBuilder + extends io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluentImpl< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm, + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermBuilder> { public V1PreferredSchedulingTermBuilder() { this(false); } + public V1PreferredSchedulingTermBuilder(java.lang.Boolean validationEnabled) { this(new V1PreferredSchedulingTerm(), validationEnabled); } - public V1PreferredSchedulingTermBuilder(io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent fluent) { + + public V1PreferredSchedulingTermBuilder( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent fluent) { this(fluent, false); } - public V1PreferredSchedulingTermBuilder(io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PreferredSchedulingTermBuilder( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PreferredSchedulingTerm(), validationEnabled); } - public V1PreferredSchedulingTermBuilder(io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent fluent,io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm instance) { + + public V1PreferredSchedulingTermBuilder( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent fluent, + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm instance) { this(fluent, instance, false); } - public V1PreferredSchedulingTermBuilder(io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent fluent,io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PreferredSchedulingTermBuilder( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent fluent, + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPreference(instance.getPreference()); fluent.withWeight(instance.getWeight()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PreferredSchedulingTermBuilder(io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm instance) { - this(instance,false); + + public V1PreferredSchedulingTermBuilder( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm instance) { + this(instance, false); } - public V1PreferredSchedulingTermBuilder(io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PreferredSchedulingTermBuilder( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPreference(instance.getPreference()); this.withWeight(instance.getWeight()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm build() { V1PreferredSchedulingTerm buildable = new V1PreferredSchedulingTerm(); buildable.setPreference(fluent.getPreference()); buildable.setWeight(fluent.getWeight()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PreferredSchedulingTermBuilder that = (V1PreferredSchedulingTermBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreferredSchedulingTermFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreferredSchedulingTermFluent.java index 60a2ab28d0..504f736068 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreferredSchedulingTermFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreferredSchedulingTermFluent.java @@ -1,39 +1,64 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PreferredSchedulingTermFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1PreferredSchedulingTermFluent< + A extends io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildPreference instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeSelectorTerm getPreference(); + public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildPreference(); + public A withPreference(io.kubernetes.client.openapi.models.V1NodeSelectorTerm preference); + public java.lang.Boolean hasPreference(); - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested withNewPreference(); - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested withNewPreferenceLike(io.kubernetes.client.openapi.models.V1NodeSelectorTerm item); - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested editPreference(); - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested editOrNewPreference(); - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested editOrNewPreferenceLike(io.kubernetes.client.openapi.models.V1NodeSelectorTerm item); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested + withNewPreference(); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested + withNewPreferenceLike(io.kubernetes.client.openapi.models.V1NodeSelectorTerm item); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested + editPreference(); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested + editOrNewPreference(); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested + editOrNewPreferenceLike(io.kubernetes.client.openapi.models.V1NodeSelectorTerm item); + public java.lang.Integer getWeight(); + public A withWeight(java.lang.Integer weight); + public java.lang.Boolean hasWeight(); - public interface PreferenceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent>{ + + public interface PreferenceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeSelectorTermFluent< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested< + N>> { public N and(); + public N endPreference(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreferredSchedulingTermFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreferredSchedulingTermFluentImpl.java index a59152898a..aba26b50d6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreferredSchedulingTermFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PreferredSchedulingTermFluentImpl.java @@ -1,95 +1,142 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1PreferredSchedulingTermFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent { + public V1PreferredSchedulingTermFluentImpl() {} - /** - * Generated - */ -public class V1PreferredSchedulingTermFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent{ - public V1PreferredSchedulingTermFluentImpl() { - } - public V1PreferredSchedulingTermFluentImpl(io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm instance) { + public V1PreferredSchedulingTermFluentImpl( + io.kubernetes.client.openapi.models.V1PreferredSchedulingTerm instance) { this.withPreference(instance.getPreference()); this.withWeight(instance.getWeight()); - } + private io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder preference; private java.lang.Integer weight; - + /** * This method has been deprecated, please use method buildPreference instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeSelectorTerm getPreference() { - return this.preference!=null ?this.preference.build():null; + return this.preference != null ? this.preference.build() : null; } + public io.kubernetes.client.openapi.models.V1NodeSelectorTerm buildPreference() { - return this.preference!=null ?this.preference.build():null; + return this.preference != null ? this.preference.build() : null; } + public A withPreference(io.kubernetes.client.openapi.models.V1NodeSelectorTerm preference) { _visitables.get("preference").remove(this.preference); - if (preference!=null){ this.preference= new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(preference); _visitables.get("preference").add(this.preference);} return (A) this; + if (preference != null) { + this.preference = + new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(preference); + _visitables.get("preference").add(this.preference); + } + return (A) this; } + public java.lang.Boolean hasPreference() { return this.preference != null; } - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested withNewPreference() { - return new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluentImpl.PreferenceNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested + withNewPreference() { + return new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluentImpl + .PreferenceNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested withNewPreferenceLike(io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { - return new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluentImpl.PreferenceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested + withNewPreferenceLike(io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { + return new io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluentImpl + .PreferenceNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested editPreference() { + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested + editPreference() { return withNewPreferenceLike(getPreference()); } - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested editOrNewPreference() { - return withNewPreferenceLike(getPreference() != null ? getPreference(): new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested + editOrNewPreference() { + return withNewPreferenceLike( + getPreference() != null + ? getPreference() + : new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested editOrNewPreferenceLike(io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { - return withNewPreferenceLike(getPreference() != null ? getPreference(): item); + + public io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested + editOrNewPreferenceLike(io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { + return withNewPreferenceLike(getPreference() != null ? getPreference() : item); } + public java.lang.Integer getWeight() { return this.weight; } + public A withWeight(java.lang.Integer weight) { - this.weight=weight; return (A) this; + this.weight = weight; + return (A) this; } + public java.lang.Boolean hasWeight() { return this.weight != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PreferredSchedulingTermFluentImpl that = (V1PreferredSchedulingTermFluentImpl) o; - if (preference != null ? !preference.equals(that.preference) :that.preference != null) return false; - if (weight != null ? !weight.equals(that.weight) :that.weight != null) return false; + if (preference != null ? !preference.equals(that.preference) : that.preference != null) + return false; + if (weight != null ? !weight.equals(that.weight) : that.weight != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(preference, weight, super.hashCode()); + return java.util.Objects.hash(preference, weight, super.hashCode()); } - public class PreferenceNestedImpl extends io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl> implements io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested,io.kubernetes.client.fluent.Nested{ + + public class PreferenceNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeSelectorTermFluentImpl< + io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent.PreferenceNested> + implements io.kubernetes.client.openapi.models.V1PreferredSchedulingTermFluent + .PreferenceNested< + N>, + io.kubernetes.client.fluent.Nested { PreferenceNestedImpl(io.kubernetes.client.openapi.models.V1NodeSelectorTerm item) { this.builder = new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(this, item); } + PreferenceNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeSelectorTermBuilder builder; + public N and() { return (N) V1PreferredSchedulingTermFluentImpl.this.withPreference(builder.build()); } + public N endPreference() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassBuilder.java index 3f1d615e49..f3038725ee 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PriorityClassBuilder extends io.kubernetes.client.openapi.models.V1PriorityClassFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PriorityClassBuilder + extends io.kubernetes.client.openapi.models.V1PriorityClassFluentImpl< + io.kubernetes.client.openapi.models.V1PriorityClassBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PriorityClass, + io.kubernetes.client.openapi.models.V1PriorityClassBuilder> { public V1PriorityClassBuilder() { this(false); } + public V1PriorityClassBuilder(java.lang.Boolean validationEnabled) { this(new V1PriorityClass(), validationEnabled); } - public V1PriorityClassBuilder(io.kubernetes.client.openapi.models.V1PriorityClassFluent fluent) { + + public V1PriorityClassBuilder( + io.kubernetes.client.openapi.models.V1PriorityClassFluent fluent) { this(fluent, false); } - public V1PriorityClassBuilder(io.kubernetes.client.openapi.models.V1PriorityClassFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PriorityClassBuilder( + io.kubernetes.client.openapi.models.V1PriorityClassFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PriorityClass(), validationEnabled); } - public V1PriorityClassBuilder(io.kubernetes.client.openapi.models.V1PriorityClassFluent fluent,io.kubernetes.client.openapi.models.V1PriorityClass instance) { + + public V1PriorityClassBuilder( + io.kubernetes.client.openapi.models.V1PriorityClassFluent fluent, + io.kubernetes.client.openapi.models.V1PriorityClass instance) { this(fluent, instance, false); } - public V1PriorityClassBuilder(io.kubernetes.client.openapi.models.V1PriorityClassFluent fluent,io.kubernetes.client.openapi.models.V1PriorityClass instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PriorityClassBuilder( + io.kubernetes.client.openapi.models.V1PriorityClassFluent fluent, + io.kubernetes.client.openapi.models.V1PriorityClass instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withDescription(instance.getDescription()); @@ -35,13 +62,17 @@ public V1PriorityClassBuilder(io.kubernetes.client.openapi.models.V1PriorityClas fluent.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1PriorityClassBuilder(io.kubernetes.client.openapi.models.V1PriorityClass instance) { - this(instance,false); + this(instance, false); } - public V1PriorityClassBuilder(io.kubernetes.client.openapi.models.V1PriorityClass instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PriorityClassBuilder( + io.kubernetes.client.openapi.models.V1PriorityClass instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withDescription(instance.getDescription()); @@ -56,10 +87,12 @@ public V1PriorityClassBuilder(io.kubernetes.client.openapi.models.V1PriorityClas this.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PriorityClassFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PriorityClass build() { V1PriorityClass buildable = new V1PriorityClass(); buildable.setApiVersion(fluent.getApiVersion()); @@ -71,18 +104,23 @@ public io.kubernetes.client.openapi.models.V1PriorityClass build() { buildable.setValue(fluent.getValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PriorityClassBuilder that = (V1PriorityClassBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassFluent.java index 999a46966b..e673d701d3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassFluent.java @@ -1,78 +1,107 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PriorityClassFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PriorityClassFluent< + A extends io.kubernetes.client.openapi.models.V1PriorityClassFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getDescription(); + public A withDescription(java.lang.String description); + public java.lang.Boolean hasDescription(); - - /** - * Method is deprecated. use withDescription instead. - */ + + /** Method is deprecated. use withDescription instead. */ @java.lang.Deprecated public A withNewDescription(java.lang.String original); + public java.lang.Boolean getGlobalDefault(); + public A withGlobalDefault(java.lang.Boolean globalDefault); + public java.lang.Boolean hasGlobalDefault(); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public java.lang.String getPreemptionPolicy(); + public A withPreemptionPolicy(java.lang.String preemptionPolicy); + public java.lang.Boolean hasPreemptionPolicy(); - - /** - * Method is deprecated. use withPreemptionPolicy instead. - */ + + /** Method is deprecated. use withPreemptionPolicy instead. */ @java.lang.Deprecated public A withNewPreemptionPolicy(java.lang.String original); + public java.lang.Integer getValue(); + public A withValue(java.lang.Integer value); + public java.lang.Boolean hasValue(); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassFluentImpl.java index 76a620b429..1b24e6e304 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassFluentImpl.java @@ -1,19 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1PriorityClassFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PriorityClassFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PriorityClassFluent { + public V1PriorityClassFluentImpl() {} - /** - * Generated - */ -public class V1PriorityClassFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PriorityClassFluent{ - public V1PriorityClassFluentImpl() { - } public V1PriorityClassFluentImpl(io.kubernetes.client.openapi.models.V1PriorityClass instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,8 +33,8 @@ public V1PriorityClassFluentImpl(io.kubernetes.client.openapi.models.V1PriorityC this.withPreemptionPolicy(instance.getPreemptionPolicy()); this.withValue(instance.getValue()); - } + private java.lang.String apiVersion; private java.lang.String description; private java.lang.Boolean globalDefault; @@ -37,157 +42,218 @@ public V1PriorityClassFluentImpl(io.kubernetes.client.openapi.models.V1PriorityC private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private java.lang.String preemptionPolicy; private java.lang.Integer value; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getDescription() { return this.description; } + public A withDescription(java.lang.String description) { - this.description=description; return (A) this; + this.description = description; + return (A) this; } + public java.lang.Boolean hasDescription() { return this.description != null; } - - /** - * Method is deprecated. use withDescription instead. - */ + + /** Method is deprecated. use withDescription instead. */ @java.lang.Deprecated public A withNewDescription(java.lang.String original) { - return (A)withDescription(new String(original)); + return (A) withDescription(new String(original)); } + public java.lang.Boolean getGlobalDefault() { return this.globalDefault; } + public A withGlobalDefault(java.lang.Boolean globalDefault) { - this.globalDefault=globalDefault; return (A) this; + this.globalDefault = globalDefault; + return (A) this; } + public java.lang.Boolean hasGlobalDefault() { return this.globalDefault != null; } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1PriorityClassFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1PriorityClassFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1PriorityClassFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public java.lang.String getPreemptionPolicy() { return this.preemptionPolicy; } + public A withPreemptionPolicy(java.lang.String preemptionPolicy) { - this.preemptionPolicy=preemptionPolicy; return (A) this; + this.preemptionPolicy = preemptionPolicy; + return (A) this; } + public java.lang.Boolean hasPreemptionPolicy() { return this.preemptionPolicy != null; } - - /** - * Method is deprecated. use withPreemptionPolicy instead. - */ + + /** Method is deprecated. use withPreemptionPolicy instead. */ @java.lang.Deprecated public A withNewPreemptionPolicy(java.lang.String original) { - return (A)withPreemptionPolicy(new String(original)); + return (A) withPreemptionPolicy(new String(original)); } + public java.lang.Integer getValue() { return this.value; } + public A withValue(java.lang.Integer value) { - this.value=value; return (A) this; + this.value = value; + return (A) this; } + public java.lang.Boolean hasValue() { return this.value != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PriorityClassFluentImpl that = (V1PriorityClassFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (description != null ? !description.equals(that.description) :that.description != null) return false; - if (globalDefault != null ? !globalDefault.equals(that.globalDefault) :that.globalDefault != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (preemptionPolicy != null ? !preemptionPolicy.equals(that.preemptionPolicy) :that.preemptionPolicy != null) return false; - if (value != null ? !value.equals(that.value) :that.value != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (description != null ? !description.equals(that.description) : that.description != null) + return false; + if (globalDefault != null + ? !globalDefault.equals(that.globalDefault) + : that.globalDefault != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (preemptionPolicy != null + ? !preemptionPolicy.equals(that.preemptionPolicy) + : that.preemptionPolicy != null) return false; + if (value != null ? !value.equals(that.value) : that.value != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, description, globalDefault, kind, metadata, preemptionPolicy, value, super.hashCode()); + return java.util.Objects.hash( + apiVersion, + description, + globalDefault, + kind, + metadata, + preemptionPolicy, + value, + super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1PriorityClassFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1PriorityClassFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassListBuilder.java index 5e07870051..729c48e425 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1PriorityClassListBuilder extends io.kubernetes.client.openapi.models.V1PriorityClassListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1PriorityClassListBuilder + extends io.kubernetes.client.openapi.models.V1PriorityClassListFluentImpl< + io.kubernetes.client.openapi.models.V1PriorityClassListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1PriorityClassList, + io.kubernetes.client.openapi.models.V1PriorityClassListBuilder> { public V1PriorityClassListBuilder() { this(false); } + public V1PriorityClassListBuilder(java.lang.Boolean validationEnabled) { this(new V1PriorityClassList(), validationEnabled); } - public V1PriorityClassListBuilder(io.kubernetes.client.openapi.models.V1PriorityClassListFluent fluent) { + + public V1PriorityClassListBuilder( + io.kubernetes.client.openapi.models.V1PriorityClassListFluent fluent) { this(fluent, false); } - public V1PriorityClassListBuilder(io.kubernetes.client.openapi.models.V1PriorityClassListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1PriorityClassListBuilder( + io.kubernetes.client.openapi.models.V1PriorityClassListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1PriorityClassList(), validationEnabled); } - public V1PriorityClassListBuilder(io.kubernetes.client.openapi.models.V1PriorityClassListFluent fluent,io.kubernetes.client.openapi.models.V1PriorityClassList instance) { + + public V1PriorityClassListBuilder( + io.kubernetes.client.openapi.models.V1PriorityClassListFluent fluent, + io.kubernetes.client.openapi.models.V1PriorityClassList instance) { this(fluent, instance, false); } - public V1PriorityClassListBuilder(io.kubernetes.client.openapi.models.V1PriorityClassListFluent fluent,io.kubernetes.client.openapi.models.V1PriorityClassList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1PriorityClassListBuilder( + io.kubernetes.client.openapi.models.V1PriorityClassListFluent fluent, + io.kubernetes.client.openapi.models.V1PriorityClassList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1PriorityClassListBuilder(io.kubernetes.client.openapi.models.V1Priority fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1PriorityClassListBuilder(io.kubernetes.client.openapi.models.V1PriorityClassList instance) { - this(instance,false); + + public V1PriorityClassListBuilder( + io.kubernetes.client.openapi.models.V1PriorityClassList instance) { + this(instance, false); } - public V1PriorityClassListBuilder(io.kubernetes.client.openapi.models.V1PriorityClassList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1PriorityClassListBuilder( + io.kubernetes.client.openapi.models.V1PriorityClassList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1PriorityClassListBuilder(io.kubernetes.client.openapi.models.V1Priority this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1PriorityClassListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1PriorityClassList build() { V1PriorityClassList buildable = new V1PriorityClassList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1PriorityClassList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1PriorityClassListBuilder that = (V1PriorityClassListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassListFluent.java index edbb7cfd59..1db06a73ad 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassListFluent.java @@ -1,95 +1,158 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1PriorityClassListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1PriorityClassListFluent< + A extends io.kubernetes.client.openapi.models.V1PriorityClassListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PriorityClass item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PriorityClass item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PriorityClass item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PriorityClass item); + public A addToItems(io.kubernetes.client.openapi.models.V1PriorityClass... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1PriorityClass... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1PriorityClass buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PriorityClass buildFirstItem(); + public io.kubernetes.client.openapi.models.V1PriorityClass buildLastItem(); - public io.kubernetes.client.openapi.models.V1PriorityClass buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PriorityClass buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1PriorityClass... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1PriorityClass item); - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PriorityClass item); - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1PriorityClass item); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PriorityClass item); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PriorityClassFluent>{ + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PriorityClassFluent< + io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassListFluentImpl.java index 33f31ba364..118d804b21 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1PriorityClassListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1PriorityClassListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1PriorityClassListFluent{ - public V1PriorityClassListFluentImpl() { - } - public V1PriorityClassListFluentImpl(io.kubernetes.client.openapi.models.V1PriorityClassList instance) { + +/** Generated */ +public class V1PriorityClassListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1PriorityClassListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1PriorityClassListFluent { + public V1PriorityClassListFluentImpl() {} + + public V1PriorityClassListFluentImpl( + io.kubernetes.client.openapi.models.V1PriorityClassList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1PriorityClassListFluentImpl(io.kubernetes.client.openapi.models.V1Prior this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PriorityClass item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder = new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PriorityClass item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder = + new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PriorityClass item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder = new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PriorityClass item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder = + new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1PriorityClass... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PriorityClass item : items) {io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder = new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PriorityClass item : items) { + io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder = + new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PriorityClass item : items) {io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder = new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PriorityClass item : items) { + io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder = + new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1PriorityClass... items) { - for (io.kubernetes.client.openapi.models.V1PriorityClass item : items) {io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder = new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1PriorityClass item : items) { + io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder = + new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PriorityClass item : items) {io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder = new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PriorityClass item : items) { + io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder = + new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder = each.next(); @@ -87,174 +159,280 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1PriorityClass buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1PriorityClass buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1PriorityClass buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PriorityClass buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PriorityClassBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PriorityClass buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PriorityClassBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PriorityClassBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PriorityClassBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PriorityClass item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PriorityClass item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1PriorityClass... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1PriorityClass item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1PriorityClass item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1PriorityClassListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1PriorityClass item) { - return new io.kubernetes.client.openapi.models.V1PriorityClassListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1PriorityClass item) { + return new io.kubernetes.client.openapi.models.V1PriorityClassListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PriorityClass item) { - return new io.kubernetes.client.openapi.models.V1PriorityClassListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PriorityClass item) { + return new io.kubernetes.client.openapi.models.V1PriorityClassListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1PriorityClassListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1PriorityClassListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1PriorityClassListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1PriorityClassListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1PriorityClassListFluentImpl that = (V1PriorityClassListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1PriorityClassFluentImpl> implements io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PriorityClass item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1PriorityClassFluentImpl< + io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1PriorityClassListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PriorityClass item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PriorityClassBuilder(this); } + io.kubernetes.client.openapi.models.V1PriorityClassBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1PriorityClassListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1PriorityClassListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1PriorityClassListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1PriorityClassListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProbeBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProbeBuilder.java index df577020d5..ded3cf4abd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProbeBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProbeBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ProbeBuilder extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ProbeBuilder + extends io.kubernetes.client.openapi.models.V1ProbeFluentImpl< + io.kubernetes.client.openapi.models.V1ProbeBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Probe, + io.kubernetes.client.openapi.models.V1ProbeBuilder> { public V1ProbeBuilder() { this(false); } + public V1ProbeBuilder(java.lang.Boolean validationEnabled) { this(new V1Probe(), validationEnabled); } + public V1ProbeBuilder(io.kubernetes.client.openapi.models.V1ProbeFluent fluent) { this(fluent, false); } - public V1ProbeBuilder(io.kubernetes.client.openapi.models.V1ProbeFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ProbeBuilder( + io.kubernetes.client.openapi.models.V1ProbeFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Probe(), validationEnabled); } - public V1ProbeBuilder(io.kubernetes.client.openapi.models.V1ProbeFluent fluent,io.kubernetes.client.openapi.models.V1Probe instance) { + + public V1ProbeBuilder( + io.kubernetes.client.openapi.models.V1ProbeFluent fluent, + io.kubernetes.client.openapi.models.V1Probe instance) { this(fluent, instance, false); } - public V1ProbeBuilder(io.kubernetes.client.openapi.models.V1ProbeFluent fluent,io.kubernetes.client.openapi.models.V1Probe instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ProbeBuilder( + io.kubernetes.client.openapi.models.V1ProbeFluent fluent, + io.kubernetes.client.openapi.models.V1Probe instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withExec(instance.getExec()); fluent.withFailureThreshold(instance.getFailureThreshold()); @@ -41,13 +67,16 @@ public V1ProbeBuilder(io.kubernetes.client.openapi.models.V1ProbeFluent fluen fluent.withTimeoutSeconds(instance.getTimeoutSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ProbeBuilder(io.kubernetes.client.openapi.models.V1Probe instance) { - this(instance,false); + this(instance, false); } - public V1ProbeBuilder(io.kubernetes.client.openapi.models.V1Probe instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ProbeBuilder( + io.kubernetes.client.openapi.models.V1Probe instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withExec(instance.getExec()); this.withFailureThreshold(instance.getFailureThreshold()); @@ -68,10 +97,12 @@ public V1ProbeBuilder(io.kubernetes.client.openapi.models.V1Probe instance,java. this.withTimeoutSeconds(instance.getTimeoutSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ProbeFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Probe build() { V1Probe buildable = new V1Probe(); buildable.setExec(fluent.getExec()); @@ -86,18 +117,23 @@ public io.kubernetes.client.openapi.models.V1Probe build() { buildable.setTimeoutSeconds(fluent.getTimeoutSeconds()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ProbeBuilder that = (V1ProbeBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProbeFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProbeFluent.java index dcb1c8a175..d15fdfa524 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProbeFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProbeFluent.java @@ -1,115 +1,194 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.lang.Long; - - /** - * Generated - */ -public interface V1ProbeFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1ProbeFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildExec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ExecAction getExec(); + public io.kubernetes.client.openapi.models.V1ExecAction buildExec(); + public A withExec(io.kubernetes.client.openapi.models.V1ExecAction exec); + public java.lang.Boolean hasExec(); + public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested withNewExec(); - public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested withNewExecLike(io.kubernetes.client.openapi.models.V1ExecAction item); + + public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested withNewExecLike( + io.kubernetes.client.openapi.models.V1ExecAction item); + public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested editExec(); + public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested editOrNewExec(); - public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested editOrNewExecLike(io.kubernetes.client.openapi.models.V1ExecAction item); + + public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested editOrNewExecLike( + io.kubernetes.client.openapi.models.V1ExecAction item); + public java.lang.Integer getFailureThreshold(); + public A withFailureThreshold(java.lang.Integer failureThreshold); + public java.lang.Boolean hasFailureThreshold(); - + /** * This method has been deprecated, please use method buildGrpc instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1GRPCAction getGrpc(); + public io.kubernetes.client.openapi.models.V1GRPCAction buildGrpc(); + public A withGrpc(io.kubernetes.client.openapi.models.V1GRPCAction grpc); + public java.lang.Boolean hasGrpc(); + public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested withNewGrpc(); - public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested withNewGrpcLike(io.kubernetes.client.openapi.models.V1GRPCAction item); + + public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested withNewGrpcLike( + io.kubernetes.client.openapi.models.V1GRPCAction item); + public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested editGrpc(); + public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested editOrNewGrpc(); - public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested editOrNewGrpcLike(io.kubernetes.client.openapi.models.V1GRPCAction item); - + + public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested editOrNewGrpcLike( + io.kubernetes.client.openapi.models.V1GRPCAction item); + /** * This method has been deprecated, please use method buildHttpGet instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HTTPGetAction getHttpGet(); + public io.kubernetes.client.openapi.models.V1HTTPGetAction buildHttpGet(); + public A withHttpGet(io.kubernetes.client.openapi.models.V1HTTPGetAction httpGet); + public java.lang.Boolean hasHttpGet(); + public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested withNewHttpGet(); - public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested withNewHttpGetLike(io.kubernetes.client.openapi.models.V1HTTPGetAction item); + + public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested withNewHttpGetLike( + io.kubernetes.client.openapi.models.V1HTTPGetAction item); + public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested editHttpGet(); + public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested editOrNewHttpGet(); - public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested editOrNewHttpGetLike(io.kubernetes.client.openapi.models.V1HTTPGetAction item); + + public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested editOrNewHttpGetLike( + io.kubernetes.client.openapi.models.V1HTTPGetAction item); + public java.lang.Integer getInitialDelaySeconds(); + public A withInitialDelaySeconds(java.lang.Integer initialDelaySeconds); + public java.lang.Boolean hasInitialDelaySeconds(); + public java.lang.Integer getPeriodSeconds(); + public A withPeriodSeconds(java.lang.Integer periodSeconds); + public java.lang.Boolean hasPeriodSeconds(); + public java.lang.Integer getSuccessThreshold(); + public A withSuccessThreshold(java.lang.Integer successThreshold); + public java.lang.Boolean hasSuccessThreshold(); - + /** * This method has been deprecated, please use method buildTcpSocket instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TCPSocketAction getTcpSocket(); + public io.kubernetes.client.openapi.models.V1TCPSocketAction buildTcpSocket(); + public A withTcpSocket(io.kubernetes.client.openapi.models.V1TCPSocketAction tcpSocket); + public java.lang.Boolean hasTcpSocket(); + public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested withNewTcpSocket(); - public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested withNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item); + + public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested withNewTcpSocketLike( + io.kubernetes.client.openapi.models.V1TCPSocketAction item); + public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested editTcpSocket(); + public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested editOrNewTcpSocket(); - public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested editOrNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item); + + public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested + editOrNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item); + public java.lang.Long getTerminationGracePeriodSeconds(); + public A withTerminationGracePeriodSeconds(java.lang.Long terminationGracePeriodSeconds); + public java.lang.Boolean hasTerminationGracePeriodSeconds(); + public java.lang.Integer getTimeoutSeconds(); + public A withTimeoutSeconds(java.lang.Integer timeoutSeconds); + public java.lang.Boolean hasTimeoutSeconds(); - public interface ExecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ExecActionFluent>{ + + public interface ExecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ExecActionFluent< + io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested> { public N and(); + public N endExec(); - } - public interface GrpcNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1GRPCActionFluent>{ + + public interface GrpcNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1GRPCActionFluent< + io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested> { public N and(); + public N endGrpc(); - } - public interface HttpGetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1HTTPGetActionFluent>{ + + public interface HttpGetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1HTTPGetActionFluent< + io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested> { public N and(); + public N endHttpGet(); - } - public interface TcpSocketNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TCPSocketActionFluent>{ + + public interface TcpSocketNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TCPSocketActionFluent< + io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested> { public N and(); + public N endTcpSocket(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProbeFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProbeFluentImpl.java index b76eebfb22..67eff3ee8a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProbeFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProbeFluentImpl.java @@ -1,19 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Integer; -import java.lang.Long; -import java.lang.Object; +/** Generated */ +public class V1ProbeFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ProbeFluent { + public V1ProbeFluentImpl() {} - /** - * Generated - */ -public class V1ProbeFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ProbeFluent{ - public V1ProbeFluentImpl() { - } public V1ProbeFluentImpl(io.kubernetes.client.openapi.models.V1Probe instance) { this.withExec(instance.getExec()); @@ -34,8 +38,8 @@ public V1ProbeFluentImpl(io.kubernetes.client.openapi.models.V1Probe instance) { this.withTerminationGracePeriodSeconds(instance.getTerminationGracePeriodSeconds()); this.withTimeoutSeconds(instance.getTimeoutSeconds()); - } + private io.kubernetes.client.openapi.models.V1ExecActionBuilder exec; private java.lang.Integer failureThreshold; private io.kubernetes.client.openapi.models.V1GRPCActionBuilder grpc; @@ -46,278 +50,431 @@ public V1ProbeFluentImpl(io.kubernetes.client.openapi.models.V1Probe instance) { private io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder tcpSocket; private java.lang.Long terminationGracePeriodSeconds; private java.lang.Integer timeoutSeconds; - + /** * This method has been deprecated, please use method buildExec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ExecAction getExec() { - return this.exec!=null ?this.exec.build():null; + return this.exec != null ? this.exec.build() : null; } + public io.kubernetes.client.openapi.models.V1ExecAction buildExec() { - return this.exec!=null ?this.exec.build():null; + return this.exec != null ? this.exec.build() : null; } + public A withExec(io.kubernetes.client.openapi.models.V1ExecAction exec) { _visitables.get("exec").remove(this.exec); - if (exec!=null){ this.exec= new io.kubernetes.client.openapi.models.V1ExecActionBuilder(exec); _visitables.get("exec").add(this.exec);} return (A) this; + if (exec != null) { + this.exec = new io.kubernetes.client.openapi.models.V1ExecActionBuilder(exec); + _visitables.get("exec").add(this.exec); + } + return (A) this; } + public java.lang.Boolean hasExec() { return this.exec != null; } + public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested withNewExec() { return new io.kubernetes.client.openapi.models.V1ProbeFluentImpl.ExecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested withNewExecLike(io.kubernetes.client.openapi.models.V1ExecAction item) { + + public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested withNewExecLike( + io.kubernetes.client.openapi.models.V1ExecAction item) { return new io.kubernetes.client.openapi.models.V1ProbeFluentImpl.ExecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested editExec() { return withNewExecLike(getExec()); } + public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested editOrNewExec() { - return withNewExecLike(getExec() != null ? getExec(): new io.kubernetes.client.openapi.models.V1ExecActionBuilder().build()); + return withNewExecLike( + getExec() != null + ? getExec() + : new io.kubernetes.client.openapi.models.V1ExecActionBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested editOrNewExecLike(io.kubernetes.client.openapi.models.V1ExecAction item) { - return withNewExecLike(getExec() != null ? getExec(): item); + + public io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested editOrNewExecLike( + io.kubernetes.client.openapi.models.V1ExecAction item) { + return withNewExecLike(getExec() != null ? getExec() : item); } + public java.lang.Integer getFailureThreshold() { return this.failureThreshold; } + public A withFailureThreshold(java.lang.Integer failureThreshold) { - this.failureThreshold=failureThreshold; return (A) this; + this.failureThreshold = failureThreshold; + return (A) this; } + public java.lang.Boolean hasFailureThreshold() { return this.failureThreshold != null; } - + /** * This method has been deprecated, please use method buildGrpc instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1GRPCAction getGrpc() { - return this.grpc!=null ?this.grpc.build():null; + return this.grpc != null ? this.grpc.build() : null; } + public io.kubernetes.client.openapi.models.V1GRPCAction buildGrpc() { - return this.grpc!=null ?this.grpc.build():null; + return this.grpc != null ? this.grpc.build() : null; } + public A withGrpc(io.kubernetes.client.openapi.models.V1GRPCAction grpc) { _visitables.get("grpc").remove(this.grpc); - if (grpc!=null){ this.grpc= new io.kubernetes.client.openapi.models.V1GRPCActionBuilder(grpc); _visitables.get("grpc").add(this.grpc);} return (A) this; + if (grpc != null) { + this.grpc = new io.kubernetes.client.openapi.models.V1GRPCActionBuilder(grpc); + _visitables.get("grpc").add(this.grpc); + } + return (A) this; } + public java.lang.Boolean hasGrpc() { return this.grpc != null; } + public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested withNewGrpc() { return new io.kubernetes.client.openapi.models.V1ProbeFluentImpl.GrpcNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested withNewGrpcLike(io.kubernetes.client.openapi.models.V1GRPCAction item) { + + public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested withNewGrpcLike( + io.kubernetes.client.openapi.models.V1GRPCAction item) { return new io.kubernetes.client.openapi.models.V1ProbeFluentImpl.GrpcNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested editGrpc() { return withNewGrpcLike(getGrpc()); } + public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested editOrNewGrpc() { - return withNewGrpcLike(getGrpc() != null ? getGrpc(): new io.kubernetes.client.openapi.models.V1GRPCActionBuilder().build()); + return withNewGrpcLike( + getGrpc() != null + ? getGrpc() + : new io.kubernetes.client.openapi.models.V1GRPCActionBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested editOrNewGrpcLike(io.kubernetes.client.openapi.models.V1GRPCAction item) { - return withNewGrpcLike(getGrpc() != null ? getGrpc(): item); + + public io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested editOrNewGrpcLike( + io.kubernetes.client.openapi.models.V1GRPCAction item) { + return withNewGrpcLike(getGrpc() != null ? getGrpc() : item); } - + /** * This method has been deprecated, please use method buildHttpGet instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HTTPGetAction getHttpGet() { - return this.httpGet!=null ?this.httpGet.build():null; + return this.httpGet != null ? this.httpGet.build() : null; } + public io.kubernetes.client.openapi.models.V1HTTPGetAction buildHttpGet() { - return this.httpGet!=null ?this.httpGet.build():null; + return this.httpGet != null ? this.httpGet.build() : null; } + public A withHttpGet(io.kubernetes.client.openapi.models.V1HTTPGetAction httpGet) { _visitables.get("httpGet").remove(this.httpGet); - if (httpGet!=null){ this.httpGet= new io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder(httpGet); _visitables.get("httpGet").add(this.httpGet);} return (A) this; + if (httpGet != null) { + this.httpGet = new io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder(httpGet); + _visitables.get("httpGet").add(this.httpGet); + } + return (A) this; } + public java.lang.Boolean hasHttpGet() { return this.httpGet != null; } + public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested withNewHttpGet() { return new io.kubernetes.client.openapi.models.V1ProbeFluentImpl.HttpGetNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested withNewHttpGetLike(io.kubernetes.client.openapi.models.V1HTTPGetAction item) { + + public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested withNewHttpGetLike( + io.kubernetes.client.openapi.models.V1HTTPGetAction item) { return new io.kubernetes.client.openapi.models.V1ProbeFluentImpl.HttpGetNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested editHttpGet() { return withNewHttpGetLike(getHttpGet()); } + public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested editOrNewHttpGet() { - return withNewHttpGetLike(getHttpGet() != null ? getHttpGet(): new io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder().build()); + return withNewHttpGetLike( + getHttpGet() != null + ? getHttpGet() + : new io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested editOrNewHttpGetLike(io.kubernetes.client.openapi.models.V1HTTPGetAction item) { - return withNewHttpGetLike(getHttpGet() != null ? getHttpGet(): item); + + public io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested editOrNewHttpGetLike( + io.kubernetes.client.openapi.models.V1HTTPGetAction item) { + return withNewHttpGetLike(getHttpGet() != null ? getHttpGet() : item); } + public java.lang.Integer getInitialDelaySeconds() { return this.initialDelaySeconds; } + public A withInitialDelaySeconds(java.lang.Integer initialDelaySeconds) { - this.initialDelaySeconds=initialDelaySeconds; return (A) this; + this.initialDelaySeconds = initialDelaySeconds; + return (A) this; } + public java.lang.Boolean hasInitialDelaySeconds() { return this.initialDelaySeconds != null; } + public java.lang.Integer getPeriodSeconds() { return this.periodSeconds; } + public A withPeriodSeconds(java.lang.Integer periodSeconds) { - this.periodSeconds=periodSeconds; return (A) this; + this.periodSeconds = periodSeconds; + return (A) this; } + public java.lang.Boolean hasPeriodSeconds() { return this.periodSeconds != null; } + public java.lang.Integer getSuccessThreshold() { return this.successThreshold; } + public A withSuccessThreshold(java.lang.Integer successThreshold) { - this.successThreshold=successThreshold; return (A) this; + this.successThreshold = successThreshold; + return (A) this; } + public java.lang.Boolean hasSuccessThreshold() { return this.successThreshold != null; } - + /** * This method has been deprecated, please use method buildTcpSocket instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TCPSocketAction getTcpSocket() { - return this.tcpSocket!=null ?this.tcpSocket.build():null; + return this.tcpSocket != null ? this.tcpSocket.build() : null; } + public io.kubernetes.client.openapi.models.V1TCPSocketAction buildTcpSocket() { - return this.tcpSocket!=null ?this.tcpSocket.build():null; + return this.tcpSocket != null ? this.tcpSocket.build() : null; } + public A withTcpSocket(io.kubernetes.client.openapi.models.V1TCPSocketAction tcpSocket) { _visitables.get("tcpSocket").remove(this.tcpSocket); - if (tcpSocket!=null){ this.tcpSocket= new io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder(tcpSocket); _visitables.get("tcpSocket").add(this.tcpSocket);} return (A) this; + if (tcpSocket != null) { + this.tcpSocket = new io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder(tcpSocket); + _visitables.get("tcpSocket").add(this.tcpSocket); + } + return (A) this; } + public java.lang.Boolean hasTcpSocket() { return this.tcpSocket != null; } + public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested withNewTcpSocket() { return new io.kubernetes.client.openapi.models.V1ProbeFluentImpl.TcpSocketNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested withNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item) { + + public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested withNewTcpSocketLike( + io.kubernetes.client.openapi.models.V1TCPSocketAction item) { return new io.kubernetes.client.openapi.models.V1ProbeFluentImpl.TcpSocketNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested editTcpSocket() { return withNewTcpSocketLike(getTcpSocket()); } + public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested editOrNewTcpSocket() { - return withNewTcpSocketLike(getTcpSocket() != null ? getTcpSocket(): new io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder().build()); + return withNewTcpSocketLike( + getTcpSocket() != null + ? getTcpSocket() + : new io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested editOrNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item) { - return withNewTcpSocketLike(getTcpSocket() != null ? getTcpSocket(): item); + + public io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested + editOrNewTcpSocketLike(io.kubernetes.client.openapi.models.V1TCPSocketAction item) { + return withNewTcpSocketLike(getTcpSocket() != null ? getTcpSocket() : item); } + public java.lang.Long getTerminationGracePeriodSeconds() { return this.terminationGracePeriodSeconds; } + public A withTerminationGracePeriodSeconds(java.lang.Long terminationGracePeriodSeconds) { - this.terminationGracePeriodSeconds=terminationGracePeriodSeconds; return (A) this; + this.terminationGracePeriodSeconds = terminationGracePeriodSeconds; + return (A) this; } + public java.lang.Boolean hasTerminationGracePeriodSeconds() { return this.terminationGracePeriodSeconds != null; } + public java.lang.Integer getTimeoutSeconds() { return this.timeoutSeconds; } + public A withTimeoutSeconds(java.lang.Integer timeoutSeconds) { - this.timeoutSeconds=timeoutSeconds; return (A) this; + this.timeoutSeconds = timeoutSeconds; + return (A) this; } + public java.lang.Boolean hasTimeoutSeconds() { return this.timeoutSeconds != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ProbeFluentImpl that = (V1ProbeFluentImpl) o; - if (exec != null ? !exec.equals(that.exec) :that.exec != null) return false; - if (failureThreshold != null ? !failureThreshold.equals(that.failureThreshold) :that.failureThreshold != null) return false; - if (grpc != null ? !grpc.equals(that.grpc) :that.grpc != null) return false; - if (httpGet != null ? !httpGet.equals(that.httpGet) :that.httpGet != null) return false; - if (initialDelaySeconds != null ? !initialDelaySeconds.equals(that.initialDelaySeconds) :that.initialDelaySeconds != null) return false; - if (periodSeconds != null ? !periodSeconds.equals(that.periodSeconds) :that.periodSeconds != null) return false; - if (successThreshold != null ? !successThreshold.equals(that.successThreshold) :that.successThreshold != null) return false; - if (tcpSocket != null ? !tcpSocket.equals(that.tcpSocket) :that.tcpSocket != null) return false; - if (terminationGracePeriodSeconds != null ? !terminationGracePeriodSeconds.equals(that.terminationGracePeriodSeconds) :that.terminationGracePeriodSeconds != null) return false; - if (timeoutSeconds != null ? !timeoutSeconds.equals(that.timeoutSeconds) :that.timeoutSeconds != null) return false; + if (exec != null ? !exec.equals(that.exec) : that.exec != null) return false; + if (failureThreshold != null + ? !failureThreshold.equals(that.failureThreshold) + : that.failureThreshold != null) return false; + if (grpc != null ? !grpc.equals(that.grpc) : that.grpc != null) return false; + if (httpGet != null ? !httpGet.equals(that.httpGet) : that.httpGet != null) return false; + if (initialDelaySeconds != null + ? !initialDelaySeconds.equals(that.initialDelaySeconds) + : that.initialDelaySeconds != null) return false; + if (periodSeconds != null + ? !periodSeconds.equals(that.periodSeconds) + : that.periodSeconds != null) return false; + if (successThreshold != null + ? !successThreshold.equals(that.successThreshold) + : that.successThreshold != null) return false; + if (tcpSocket != null ? !tcpSocket.equals(that.tcpSocket) : that.tcpSocket != null) + return false; + if (terminationGracePeriodSeconds != null + ? !terminationGracePeriodSeconds.equals(that.terminationGracePeriodSeconds) + : that.terminationGracePeriodSeconds != null) return false; + if (timeoutSeconds != null + ? !timeoutSeconds.equals(that.timeoutSeconds) + : that.timeoutSeconds != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(exec, failureThreshold, grpc, httpGet, initialDelaySeconds, periodSeconds, successThreshold, tcpSocket, terminationGracePeriodSeconds, timeoutSeconds, super.hashCode()); + return java.util.Objects.hash( + exec, + failureThreshold, + grpc, + httpGet, + initialDelaySeconds, + periodSeconds, + successThreshold, + tcpSocket, + terminationGracePeriodSeconds, + timeoutSeconds, + super.hashCode()); } - public class ExecNestedImpl extends io.kubernetes.client.openapi.models.V1ExecActionFluentImpl> implements io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested,io.kubernetes.client.fluent.Nested{ + + public class ExecNestedImpl + extends io.kubernetes.client.openapi.models.V1ExecActionFluentImpl< + io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested> + implements io.kubernetes.client.openapi.models.V1ProbeFluent.ExecNested, + io.kubernetes.client.fluent.Nested { ExecNestedImpl(io.kubernetes.client.openapi.models.V1ExecAction item) { this.builder = new io.kubernetes.client.openapi.models.V1ExecActionBuilder(this, item); } + ExecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ExecActionBuilder(this); } + io.kubernetes.client.openapi.models.V1ExecActionBuilder builder; + public N and() { return (N) V1ProbeFluentImpl.this.withExec(builder.build()); } + public N endExec() { return and(); } - } - public class GrpcNestedImpl extends io.kubernetes.client.openapi.models.V1GRPCActionFluentImpl> implements io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested,io.kubernetes.client.fluent.Nested{ + + public class GrpcNestedImpl + extends io.kubernetes.client.openapi.models.V1GRPCActionFluentImpl< + io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested> + implements io.kubernetes.client.openapi.models.V1ProbeFluent.GrpcNested, + io.kubernetes.client.fluent.Nested { GrpcNestedImpl(io.kubernetes.client.openapi.models.V1GRPCAction item) { this.builder = new io.kubernetes.client.openapi.models.V1GRPCActionBuilder(this, item); } + GrpcNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1GRPCActionBuilder(this); } + io.kubernetes.client.openapi.models.V1GRPCActionBuilder builder; + public N and() { return (N) V1ProbeFluentImpl.this.withGrpc(builder.build()); } + public N endGrpc() { return and(); } - } - public class HttpGetNestedImpl extends io.kubernetes.client.openapi.models.V1HTTPGetActionFluentImpl> implements io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested,io.kubernetes.client.fluent.Nested{ + + public class HttpGetNestedImpl + extends io.kubernetes.client.openapi.models.V1HTTPGetActionFluentImpl< + io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested> + implements io.kubernetes.client.openapi.models.V1ProbeFluent.HttpGetNested, + io.kubernetes.client.fluent.Nested { HttpGetNestedImpl(io.kubernetes.client.openapi.models.V1HTTPGetAction item) { this.builder = new io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder(this, item); } + HttpGetNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder(this); } + io.kubernetes.client.openapi.models.V1HTTPGetActionBuilder builder; + public N and() { return (N) V1ProbeFluentImpl.this.withHttpGet(builder.build()); } + public N endHttpGet() { return and(); } - } - public class TcpSocketNestedImpl extends io.kubernetes.client.openapi.models.V1TCPSocketActionFluentImpl> implements io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested,io.kubernetes.client.fluent.Nested{ + + public class TcpSocketNestedImpl + extends io.kubernetes.client.openapi.models.V1TCPSocketActionFluentImpl< + io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested> + implements io.kubernetes.client.openapi.models.V1ProbeFluent.TcpSocketNested, + io.kubernetes.client.fluent.Nested { TcpSocketNestedImpl(io.kubernetes.client.openapi.models.V1TCPSocketAction item) { this.builder = new io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder(this, item); } + TcpSocketNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder(this); } + io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder builder; + public N and() { return (N) V1ProbeFluentImpl.this.withTcpSocket(builder.build()); } + public N endTcpSocket() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProjectedVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProjectedVolumeSourceBuilder.java index 109d4f5098..a81c1fb150 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProjectedVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProjectedVolumeSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ProjectedVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ProjectedVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ProjectedVolumeSource, + io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceBuilder> { public V1ProjectedVolumeSourceBuilder() { this(false); } + public V1ProjectedVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1ProjectedVolumeSource(), validationEnabled); } - public V1ProjectedVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent fluent) { + + public V1ProjectedVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent fluent) { this(fluent, false); } - public V1ProjectedVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ProjectedVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ProjectedVolumeSource(), validationEnabled); } - public V1ProjectedVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1ProjectedVolumeSource instance) { + + public V1ProjectedVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ProjectedVolumeSource instance) { this(fluent, instance, false); } - public V1ProjectedVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1ProjectedVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ProjectedVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ProjectedVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDefaultMode(instance.getDefaultMode()); fluent.withSources(instance.getSources()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ProjectedVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ProjectedVolumeSource instance) { - this(instance,false); + + public V1ProjectedVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ProjectedVolumeSource instance) { + this(instance, false); } - public V1ProjectedVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ProjectedVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ProjectedVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ProjectedVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDefaultMode(instance.getDefaultMode()); this.withSources(instance.getSources()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSource build() { V1ProjectedVolumeSource buildable = new V1ProjectedVolumeSource(); buildable.setDefaultMode(fluent.getDefaultMode()); buildable.setSources(fluent.getSources()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ProjectedVolumeSourceBuilder that = (V1ProjectedVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProjectedVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProjectedVolumeSourceFluent.java index 989a72d944..2e75b5169b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProjectedVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProjectedVolumeSourceFluent.java @@ -1,60 +1,110 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ProjectedVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ProjectedVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getDefaultMode(); + public A withDefaultMode(java.lang.Integer defaultMode); + public java.lang.Boolean hasDefaultMode(); - public A addToSources(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeProjection item); - public A setToSources(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeProjection item); + + public A addToSources( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeProjection item); + + public A setToSources( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeProjection item); + public A addToSources(io.kubernetes.client.openapi.models.V1VolumeProjection... items); - public A addAllToSources(java.util.Collection items); + + public A addAllToSources( + java.util.Collection items); + public A removeFromSources(io.kubernetes.client.openapi.models.V1VolumeProjection... items); - public A removeAllFromSources(java.util.Collection items); - public A removeMatchingFromSources(java.util.function.Predicate predicate); - + + public A removeAllFromSources( + java.util.Collection items); + + public A removeMatchingFromSources( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildSources instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getSources(); + public java.util.List buildSources(); - public io.kubernetes.client.openapi.models.V1VolumeProjection buildSource(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1VolumeProjection buildSource( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1VolumeProjection buildFirstSource(); + public io.kubernetes.client.openapi.models.V1VolumeProjection buildLastSource(); - public io.kubernetes.client.openapi.models.V1VolumeProjection buildMatchingSource(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingSource(java.util.function.Predicate predicate); - public A withSources(java.util.List sources); + + public io.kubernetes.client.openapi.models.V1VolumeProjection buildMatchingSource( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingSource( + java.util.function.Predicate + predicate); + + public A withSources( + java.util.List sources); + public A withSources(io.kubernetes.client.openapi.models.V1VolumeProjection... sources); + public java.lang.Boolean hasSources(); - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested addNewSource(); - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested addNewSourceLike(io.kubernetes.client.openapi.models.V1VolumeProjection item); - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested setNewSourceLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeProjection item); - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested editSource(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested editFirstSource(); - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested editLastSource(); - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested editMatchingSource(java.util.function.Predicate predicate); - public interface SourcesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeProjectionFluent>{ + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + addNewSource(); + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + addNewSourceLike(io.kubernetes.client.openapi.models.V1VolumeProjection item); + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + setNewSourceLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeProjection item); + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + editSource(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + editFirstSource(); + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + editLastSource(); + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + editMatchingSource( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder> + predicate); + + public interface SourcesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent< + io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested> { public N and(); + public N endSource(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProjectedVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProjectedVolumeSourceFluentImpl.java index 8ba31015cb..cb662f440f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProjectedVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ProjectedVolumeSourceFluentImpl.java @@ -1,69 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1ProjectedVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent{ - public V1ProjectedVolumeSourceFluentImpl() { - } - public V1ProjectedVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1ProjectedVolumeSource instance) { +/** Generated */ +public class V1ProjectedVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent { + public V1ProjectedVolumeSourceFluentImpl() {} + + public V1ProjectedVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1ProjectedVolumeSource instance) { this.withDefaultMode(instance.getDefaultMode()); this.withSources(instance.getSources()); - } + private java.lang.Integer defaultMode; - private java.util.ArrayList sources; + private java.util.ArrayList + sources; + public java.lang.Integer getDefaultMode() { return this.defaultMode; } + public A withDefaultMode(java.lang.Integer defaultMode) { - this.defaultMode=defaultMode; return (A) this; + this.defaultMode = defaultMode; + return (A) this; } + public java.lang.Boolean hasDefaultMode() { return this.defaultMode != null; } - public A addToSources(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeProjection item) { - if (this.sources == null) {this.sources = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(item);_visitables.get("sources").add(index >= 0 ? index : _visitables.get("sources").size(), builder);this.sources.add(index >= 0 ? index : sources.size(), builder); return (A)this; + + public A addToSources( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeProjection item) { + if (this.sources == null) { + this.sources = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(item); + _visitables.get("sources").add(index >= 0 ? index : _visitables.get("sources").size(), builder); + this.sources.add(index >= 0 ? index : sources.size(), builder); + return (A) this; } - public A setToSources(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeProjection item) { - if (this.sources == null) {this.sources = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(item); - if (index < 0 || index >= _visitables.get("sources").size()) { _visitables.get("sources").add(builder); } else { _visitables.get("sources").set(index, builder);} - if (index < 0 || index >= sources.size()) { sources.add(builder); } else { sources.set(index, builder);} - return (A)this; + + public A setToSources( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeProjection item) { + if (this.sources == null) { + this.sources = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(item); + if (index < 0 || index >= _visitables.get("sources").size()) { + _visitables.get("sources").add(builder); + } else { + _visitables.get("sources").set(index, builder); + } + if (index < 0 || index >= sources.size()) { + sources.add(builder); + } else { + sources.set(index, builder); + } + return (A) this; } + public A addToSources(io.kubernetes.client.openapi.models.V1VolumeProjection... items) { - if (this.sources == null) {this.sources = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1VolumeProjection item : items) {io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(item);_visitables.get("sources").add(builder);this.sources.add(builder);} return (A)this; + if (this.sources == null) { + this.sources = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1VolumeProjection item : items) { + io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(item); + _visitables.get("sources").add(builder); + this.sources.add(builder); + } + return (A) this; } - public A addAllToSources(java.util.Collection items) { - if (this.sources == null) {this.sources = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1VolumeProjection item : items) {io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(item);_visitables.get("sources").add(builder);this.sources.add(builder);} return (A)this; + + public A addAllToSources( + java.util.Collection items) { + if (this.sources == null) { + this.sources = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1VolumeProjection item : items) { + io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(item); + _visitables.get("sources").add(builder); + this.sources.add(builder); + } + return (A) this; } + public A removeFromSources(io.kubernetes.client.openapi.models.V1VolumeProjection... items) { - for (io.kubernetes.client.openapi.models.V1VolumeProjection item : items) {io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(item);_visitables.get("sources").remove(builder);if (this.sources != null) {this.sources.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1VolumeProjection item : items) { + io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(item); + _visitables.get("sources").remove(builder); + if (this.sources != null) { + this.sources.remove(builder); + } + } + return (A) this; } - public A removeAllFromSources(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1VolumeProjection item : items) {io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(item);_visitables.get("sources").remove(builder);if (this.sources != null) {this.sources.remove(builder);}} return (A)this; + + public A removeAllFromSources( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1VolumeProjection item : items) { + io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(item); + _visitables.get("sources").remove(builder); + if (this.sources != null) { + this.sources.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromSources(java.util.function.Predicate predicate) { + + public A removeMatchingFromSources( + java.util.function.Predicate + predicate) { if (sources == null) return (A) this; - final Iterator each = sources.iterator(); + final Iterator each = + sources.iterator(); final List visitables = _visitables.get("sources"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder = each.next(); @@ -72,105 +148,185 @@ public A removeMatchingFromSources(java.util.function.Predicate getSources() { return sources != null ? build(sources) : null; } + public java.util.List buildSources() { return sources != null ? build(sources) : null; } - public io.kubernetes.client.openapi.models.V1VolumeProjection buildSource(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1VolumeProjection buildSource( + java.lang.Integer index) { return this.sources.get(index).build(); } + public io.kubernetes.client.openapi.models.V1VolumeProjection buildFirstSource() { return this.sources.get(0).build(); } + public io.kubernetes.client.openapi.models.V1VolumeProjection buildLastSource() { return this.sources.get(sources.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1VolumeProjection buildMatchingSource(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder item: sources) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1VolumeProjection buildMatchingSource( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder item : sources) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingSource(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder item: sources) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingSource( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder item : sources) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withSources(java.util.List sources) { - if (this.sources != null) { _visitables.get("sources").removeAll(this.sources);} - if (sources != null) {this.sources = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1VolumeProjection item : sources){this.addToSources(item);}} else { this.sources = null;} return (A) this; + + public A withSources( + java.util.List sources) { + if (this.sources != null) { + _visitables.get("sources").removeAll(this.sources); + } + if (sources != null) { + this.sources = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1VolumeProjection item : sources) { + this.addToSources(item); + } + } else { + this.sources = null; + } + return (A) this; } + public A withSources(io.kubernetes.client.openapi.models.V1VolumeProjection... sources) { - if (this.sources != null) {this.sources.clear();} - if (sources != null) {for (io.kubernetes.client.openapi.models.V1VolumeProjection item :sources){ this.addToSources(item);}} return (A) this; + if (this.sources != null) { + this.sources.clear(); + } + if (sources != null) { + for (io.kubernetes.client.openapi.models.V1VolumeProjection item : sources) { + this.addToSources(item); + } + } + return (A) this; } + public java.lang.Boolean hasSources() { return sources != null && !sources.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested addNewSource() { - return new io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluentImpl.SourcesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + addNewSource() { + return new io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluentImpl + .SourcesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested addNewSourceLike(io.kubernetes.client.openapi.models.V1VolumeProjection item) { - return new io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluentImpl.SourcesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + addNewSourceLike(io.kubernetes.client.openapi.models.V1VolumeProjection item) { + return new io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluentImpl + .SourcesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested setNewSourceLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeProjection item) { - return new io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluentImpl.SourcesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + setNewSourceLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeProjection item) { + return new io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluentImpl + .SourcesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested editSource(java.lang.Integer index) { - if (sources.size() <= index) throw new RuntimeException("Can't edit sources. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + editSource(java.lang.Integer index) { + if (sources.size() <= index) + throw new RuntimeException("Can't edit sources. Index exceeds size."); return setNewSourceLike(index, buildSource(index)); } - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested editFirstSource() { - if (sources.size() == 0) throw new RuntimeException("Can't edit first sources. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + editFirstSource() { + if (sources.size() == 0) + throw new RuntimeException("Can't edit first sources. The list is empty."); return setNewSourceLike(0, buildSource(0)); } - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested editLastSource() { + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + editLastSource() { int index = sources.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last sources. The list is empty."); return setNewSourceLike(index, buildSource(index)); } - public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested editMatchingSource(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested + editMatchingSource( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl> implements io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested,io.kubernetes.client.fluent.Nested{ - SourcesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeProjection item) { + + public class SourcesNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl< + io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested> + implements io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent.SourcesNested, + io.kubernetes.client.fluent.Nested { + SourcesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeProjection item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(this, item); } + SourcesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ProjectedVolumeSourceFluentImpl.this.setToSources(index,builder.build()); + return (N) V1ProjectedVolumeSourceFluentImpl.this.setToSources(index, builder.build()); } + public N endSource() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1QuobyteVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1QuobyteVolumeSourceBuilder.java index b0384a30a0..482b3a8db5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1QuobyteVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1QuobyteVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1QuobyteVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1QuobyteVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1QuobyteVolumeSource, + io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder> { public V1QuobyteVolumeSourceBuilder() { this(false); } + public V1QuobyteVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1QuobyteVolumeSource(), validationEnabled); } - public V1QuobyteVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent fluent) { + + public V1QuobyteVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent fluent) { this(fluent, false); } - public V1QuobyteVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1QuobyteVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1QuobyteVolumeSource(), validationEnabled); } - public V1QuobyteVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1QuobyteVolumeSource instance) { + + public V1QuobyteVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1QuobyteVolumeSource instance) { this(fluent, instance, false); } - public V1QuobyteVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1QuobyteVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1QuobyteVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1QuobyteVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withGroup(instance.getGroup()); fluent.withReadOnly(instance.getReadOnly()); @@ -33,13 +60,18 @@ public V1QuobyteVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1Quobyt fluent.withVolume(instance.getVolume()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1QuobyteVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource instance) { - this(instance,false); + + public V1QuobyteVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1QuobyteVolumeSource instance) { + this(instance, false); } - public V1QuobyteVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1QuobyteVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1QuobyteVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withGroup(instance.getGroup()); this.withReadOnly(instance.getReadOnly()); @@ -52,10 +84,12 @@ public V1QuobyteVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1Quobyt this.withVolume(instance.getVolume()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1QuobyteVolumeSource build() { V1QuobyteVolumeSource buildable = new V1QuobyteVolumeSource(); buildable.setGroup(fluent.getGroup()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1QuobyteVolumeSource build() { buildable.setVolume(fluent.getVolume()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1QuobyteVolumeSourceBuilder that = (V1QuobyteVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1QuobyteVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1QuobyteVolumeSourceFluent.java index 4fab6bad02..431208e6a6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1QuobyteVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1QuobyteVolumeSourceFluent.java @@ -1,62 +1,74 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1QuobyteVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1QuobyteVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getGroup(); + public A withGroup(java.lang.String group); + public java.lang.Boolean hasGroup(); - - /** - * Method is deprecated. use withGroup instead. - */ + + /** Method is deprecated. use withGroup instead. */ @java.lang.Deprecated public A withNewGroup(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); + public java.lang.String getRegistry(); + public A withRegistry(java.lang.String registry); + public java.lang.Boolean hasRegistry(); - - /** - * Method is deprecated. use withRegistry instead. - */ + + /** Method is deprecated. use withRegistry instead. */ @java.lang.Deprecated public A withNewRegistry(java.lang.String original); + public java.lang.String getTenant(); + public A withTenant(java.lang.String tenant); + public java.lang.Boolean hasTenant(); - - /** - * Method is deprecated. use withTenant instead. - */ + + /** Method is deprecated. use withTenant instead. */ @java.lang.Deprecated public A withNewTenant(java.lang.String original); + public java.lang.String getUser(); + public A withUser(java.lang.String user); + public java.lang.Boolean hasUser(); - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original); + public java.lang.String getVolume(); + public A withVolume(java.lang.String volume); + public java.lang.Boolean hasVolume(); - - /** - * Method is deprecated. use withVolume instead. - */ + + /** Method is deprecated. use withVolume instead. */ @java.lang.Deprecated public A withNewVolume(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1QuobyteVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1QuobyteVolumeSourceFluentImpl.java index 153a7bd401..91fa89ac89 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1QuobyteVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1QuobyteVolumeSourceFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1QuobyteVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent { + public V1QuobyteVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1QuobyteVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent{ - public V1QuobyteVolumeSourceFluentImpl() { - } - public V1QuobyteVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource instance) { + public V1QuobyteVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1QuobyteVolumeSource instance) { this.withGroup(instance.getGroup()); this.withReadOnly(instance.getReadOnly()); @@ -24,122 +32,138 @@ public V1QuobyteVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1Quo this.withUser(instance.getUser()); this.withVolume(instance.getVolume()); - } + private java.lang.String group; private java.lang.Boolean readOnly; private java.lang.String registry; private java.lang.String tenant; private java.lang.String user; private java.lang.String volume; + public java.lang.String getGroup() { return this.group; } + public A withGroup(java.lang.String group) { - this.group=group; return (A) this; + this.group = group; + return (A) this; } + public java.lang.Boolean hasGroup() { return this.group != null; } - - /** - * Method is deprecated. use withGroup instead. - */ + + /** Method is deprecated. use withGroup instead. */ @java.lang.Deprecated public A withNewGroup(java.lang.String original) { - return (A)withGroup(new String(original)); + return (A) withGroup(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public java.lang.String getRegistry() { return this.registry; } + public A withRegistry(java.lang.String registry) { - this.registry=registry; return (A) this; + this.registry = registry; + return (A) this; } + public java.lang.Boolean hasRegistry() { return this.registry != null; } - - /** - * Method is deprecated. use withRegistry instead. - */ + + /** Method is deprecated. use withRegistry instead. */ @java.lang.Deprecated public A withNewRegistry(java.lang.String original) { - return (A)withRegistry(new String(original)); + return (A) withRegistry(new String(original)); } + public java.lang.String getTenant() { return this.tenant; } + public A withTenant(java.lang.String tenant) { - this.tenant=tenant; return (A) this; + this.tenant = tenant; + return (A) this; } + public java.lang.Boolean hasTenant() { return this.tenant != null; } - - /** - * Method is deprecated. use withTenant instead. - */ + + /** Method is deprecated. use withTenant instead. */ @java.lang.Deprecated public A withNewTenant(java.lang.String original) { - return (A)withTenant(new String(original)); + return (A) withTenant(new String(original)); } + public java.lang.String getUser() { return this.user; } + public A withUser(java.lang.String user) { - this.user=user; return (A) this; + this.user = user; + return (A) this; } + public java.lang.Boolean hasUser() { return this.user != null; } - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original) { - return (A)withUser(new String(original)); + return (A) withUser(new String(original)); } + public java.lang.String getVolume() { return this.volume; } + public A withVolume(java.lang.String volume) { - this.volume=volume; return (A) this; + this.volume = volume; + return (A) this; } + public java.lang.Boolean hasVolume() { return this.volume != null; } - - /** - * Method is deprecated. use withVolume instead. - */ + + /** Method is deprecated. use withVolume instead. */ @java.lang.Deprecated public A withNewVolume(java.lang.String original) { - return (A)withVolume(new String(original)); + return (A) withVolume(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1QuobyteVolumeSourceFluentImpl that = (V1QuobyteVolumeSourceFluentImpl) o; - if (group != null ? !group.equals(that.group) :that.group != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (registry != null ? !registry.equals(that.registry) :that.registry != null) return false; - if (tenant != null ? !tenant.equals(that.tenant) :that.tenant != null) return false; - if (user != null ? !user.equals(that.user) :that.user != null) return false; - if (volume != null ? !volume.equals(that.volume) :that.volume != null) return false; + if (group != null ? !group.equals(that.group) : that.group != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (registry != null ? !registry.equals(that.registry) : that.registry != null) return false; + if (tenant != null ? !tenant.equals(that.tenant) : that.tenant != null) return false; + if (user != null ? !user.equals(that.user) : that.user != null) return false; + if (volume != null ? !volume.equals(that.volume) : that.volume != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(group, readOnly, registry, tenant, user, volume, super.hashCode()); + return java.util.Objects.hash( + group, readOnly, registry, tenant, user, volume, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDPersistentVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDPersistentVolumeSourceBuilder.java index caea7bfe3c..2d78e8cbf0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDPersistentVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDPersistentVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1RBDPersistentVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1RBDPersistentVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource, + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceBuilder> { public V1RBDPersistentVolumeSourceBuilder() { this(false); } + public V1RBDPersistentVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1RBDPersistentVolumeSource(), validationEnabled); } - public V1RBDPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent fluent) { + + public V1RBDPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent fluent) { this(fluent, false); } - public V1RBDPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1RBDPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1RBDPersistentVolumeSource(), validationEnabled); } - public V1RBDPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource instance) { + + public V1RBDPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource instance) { this(fluent, instance, false); } - public V1RBDPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1RBDPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withImage(instance.getImage()); @@ -37,13 +64,18 @@ public V1RBDPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1 fluent.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1RBDPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource instance) { - this(instance,false); + + public V1RBDPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource instance) { + this(instance, false); } - public V1RBDPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1RBDPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withImage(instance.getImage()); @@ -60,10 +92,12 @@ public V1RBDPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1 this.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource build() { V1RBDPersistentVolumeSource buildable = new V1RBDPersistentVolumeSource(); buildable.setFsType(fluent.getFsType()); @@ -76,18 +110,23 @@ public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource build() { buildable.setUser(fluent.getUser()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1RBDPersistentVolumeSourceBuilder that = (V1RBDPersistentVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDPersistentVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDPersistentVolumeSourceFluent.java index 1db537199c..b7b5197e40 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDPersistentVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDPersistentVolumeSourceFluent.java @@ -1,104 +1,147 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1RBDPersistentVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1RBDPersistentVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.String getImage(); + public A withImage(java.lang.String image); + public java.lang.Boolean hasImage(); - - /** - * Method is deprecated. use withImage instead. - */ + + /** Method is deprecated. use withImage instead. */ @java.lang.Deprecated public A withNewImage(java.lang.String original); + public java.lang.String getKeyring(); + public A withKeyring(java.lang.String keyring); + public java.lang.Boolean hasKeyring(); - - /** - * Method is deprecated. use withKeyring instead. - */ + + /** Method is deprecated. use withKeyring instead. */ @java.lang.Deprecated public A withNewKeyring(java.lang.String original); - public A addToMonitors(java.lang.Integer index,java.lang.String item); - public A setToMonitors(java.lang.Integer index,java.lang.String item); + + public A addToMonitors(java.lang.Integer index, java.lang.String item); + + public A setToMonitors(java.lang.Integer index, java.lang.String item); + public A addToMonitors(java.lang.String... items); + public A addAllToMonitors(java.util.Collection items); + public A removeFromMonitors(java.lang.String... items); + public A removeAllFromMonitors(java.util.Collection items); + public java.util.List getMonitors(); + public java.lang.String getMonitor(java.lang.Integer index); + public java.lang.String getFirstMonitor(); + public java.lang.String getLastMonitor(); - public java.lang.String getMatchingMonitor(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMonitor(java.util.function.Predicate predicate); + + public java.lang.String getMatchingMonitor( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingMonitor( + java.util.function.Predicate predicate); + public A withMonitors(java.util.List monitors); + public A withMonitors(java.lang.String... monitors); + public java.lang.Boolean hasMonitors(); + public A addNewMonitor(java.lang.String original); + public java.lang.String getPool(); + public A withPool(java.lang.String pool); + public java.lang.Boolean hasPool(); - - /** - * Method is deprecated. use withPool instead. - */ + + /** Method is deprecated. use withPool instead. */ @java.lang.Deprecated public A withNewPool(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1SecretReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); - public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + public java.lang.String getUser(); + public A withUser(java.lang.String user); + public java.lang.Boolean hasUser(); - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretReferenceFluent>{ + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretReferenceFluent< + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested< + N>> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDPersistentVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDPersistentVolumeSourceFluentImpl.java index e6ad902bd3..06157969ea 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDPersistentVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDPersistentVolumeSourceFluentImpl.java @@ -1,24 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1RBDPersistentVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent{ - public V1RBDPersistentVolumeSourceFluentImpl() { - } - public V1RBDPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource instance) { +/** Generated */ +public class V1RBDPersistentVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent { + public V1RBDPersistentVolumeSourceFluentImpl() {} + + public V1RBDPersistentVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSource instance) { this.withFsType(instance.getFsType()); this.withImage(instance.getImage()); @@ -34,8 +36,8 @@ public V1RBDPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models this.withSecretRef(instance.getSecretRef()); this.withUser(instance.getUser()); - } + private java.lang.String fsType; private java.lang.String image; private java.lang.String keyring; @@ -44,220 +46,338 @@ public V1RBDPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models private java.lang.Boolean readOnly; private io.kubernetes.client.openapi.models.V1SecretReferenceBuilder secretRef; private java.lang.String user; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.String getImage() { return this.image; } + public A withImage(java.lang.String image) { - this.image=image; return (A) this; + this.image = image; + return (A) this; } + public java.lang.Boolean hasImage() { return this.image != null; } - - /** - * Method is deprecated. use withImage instead. - */ + + /** Method is deprecated. use withImage instead. */ @java.lang.Deprecated public A withNewImage(java.lang.String original) { - return (A)withImage(new String(original)); + return (A) withImage(new String(original)); } + public java.lang.String getKeyring() { return this.keyring; } + public A withKeyring(java.lang.String keyring) { - this.keyring=keyring; return (A) this; + this.keyring = keyring; + return (A) this; } + public java.lang.Boolean hasKeyring() { return this.keyring != null; } - - /** - * Method is deprecated. use withKeyring instead. - */ + + /** Method is deprecated. use withKeyring instead. */ @java.lang.Deprecated public A withNewKeyring(java.lang.String original) { - return (A)withKeyring(new String(original)); + return (A) withKeyring(new String(original)); } - public A addToMonitors(java.lang.Integer index,java.lang.String item) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} + + public A addToMonitors(java.lang.Integer index, java.lang.String item) { + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } this.monitors.add(index, item); - return (A)this; + return (A) this; } - public A setToMonitors(java.lang.Integer index,java.lang.String item) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} - this.monitors.set(index, item); return (A)this; + + public A setToMonitors(java.lang.Integer index, java.lang.String item) { + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } + this.monitors.set(index, item); + return (A) this; } + public A addToMonitors(java.lang.String... items) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} - for (java.lang.String item : items) {this.monitors.add(item);} return (A)this; + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.monitors.add(item); + } + return (A) this; } + public A addAllToMonitors(java.util.Collection items) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} - for (java.lang.String item : items) {this.monitors.add(item);} return (A)this; + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.monitors.add(item); + } + return (A) this; } + public A removeFromMonitors(java.lang.String... items) { - for (java.lang.String item : items) {if (this.monitors!= null){ this.monitors.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.monitors != null) { + this.monitors.remove(item); + } + } + return (A) this; } + public A removeAllFromMonitors(java.util.Collection items) { - for (java.lang.String item : items) {if (this.monitors!= null){ this.monitors.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.monitors != null) { + this.monitors.remove(item); + } + } + return (A) this; } + public java.util.List getMonitors() { return this.monitors; } + public java.lang.String getMonitor(java.lang.Integer index) { return this.monitors.get(index); } + public java.lang.String getFirstMonitor() { return this.monitors.get(0); } + public java.lang.String getLastMonitor() { return this.monitors.get(monitors.size() - 1); } - public java.lang.String getMatchingMonitor(java.util.function.Predicate predicate) { - for (java.lang.String item: monitors) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingMonitor( + java.util.function.Predicate predicate) { + for (java.lang.String item : monitors) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingMonitor(java.util.function.Predicate predicate) { - for (java.lang.String item: monitors) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMonitor( + java.util.function.Predicate predicate) { + for (java.lang.String item : monitors) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withMonitors(java.util.List monitors) { - if (monitors != null) {this.monitors = new java.util.ArrayList(); for (java.lang.String item : monitors){this.addToMonitors(item);}} else { this.monitors = null;} return (A) this; + if (monitors != null) { + this.monitors = new java.util.ArrayList(); + for (java.lang.String item : monitors) { + this.addToMonitors(item); + } + } else { + this.monitors = null; + } + return (A) this; } + public A withMonitors(java.lang.String... monitors) { - if (this.monitors != null) {this.monitors.clear();} - if (monitors != null) {for (java.lang.String item :monitors){ this.addToMonitors(item);}} return (A) this; + if (this.monitors != null) { + this.monitors.clear(); + } + if (monitors != null) { + for (java.lang.String item : monitors) { + this.addToMonitors(item); + } + } + return (A) this; } + public java.lang.Boolean hasMonitors() { return monitors != null && !monitors.isEmpty(); } + public A addNewMonitor(java.lang.String original) { - return (A)addToMonitors(new String(original)); + return (A) addToMonitors(new String(original)); } + public java.lang.String getPool() { return this.pool; } + public A withPool(java.lang.String pool) { - this.pool=pool; return (A) this; + this.pool = pool; + return (A) this; } + public java.lang.Boolean hasPool() { return this.pool != null; } - - /** - * Method is deprecated. use withPool instead. - */ + + /** Method is deprecated. use withPool instead. */ @java.lang.Deprecated public A withNewPool(java.lang.String original) { - return (A)withPool(new String(original)); + return (A) withPool(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return new io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return new io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public java.lang.String getUser() { return this.user; } + public A withUser(java.lang.String user) { - this.user=user; return (A) this; + this.user = user; + return (A) this; } + public java.lang.Boolean hasUser() { return this.user != null; } - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original) { - return (A)withUser(new String(original)); + return (A) withUser(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1RBDPersistentVolumeSourceFluentImpl that = (V1RBDPersistentVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (image != null ? !image.equals(that.image) :that.image != null) return false; - if (keyring != null ? !keyring.equals(that.keyring) :that.keyring != null) return false; - if (monitors != null ? !monitors.equals(that.monitors) :that.monitors != null) return false; - if (pool != null ? !pool.equals(that.pool) :that.pool != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; - if (user != null ? !user.equals(that.user) :that.user != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (image != null ? !image.equals(that.image) : that.image != null) return false; + if (keyring != null ? !keyring.equals(that.keyring) : that.keyring != null) return false; + if (monitors != null ? !monitors.equals(that.monitors) : that.monitors != null) return false; + if (pool != null ? !pool.equals(that.pool) : that.pool != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; + if (user != null ? !user.equals(that.user) : that.user != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, image, keyring, monitors, pool, readOnly, secretRef, user, super.hashCode()); + return java.util.Objects.hash( + fsType, image, keyring, monitors, pool, readOnly, secretRef, user, super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent.SecretRefNested> + implements io.kubernetes.client.openapi.models.V1RBDPersistentVolumeSourceFluent + .SecretRefNested< + N>, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1SecretReference item) { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretReferenceBuilder builder; + public N and() { return (N) V1RBDPersistentVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDVolumeSourceBuilder.java index 280e154f4a..a16e5258b3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1RBDVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1RBDVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1RBDVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1RBDVolumeSource, + io.kubernetes.client.openapi.models.V1RBDVolumeSourceBuilder> { public V1RBDVolumeSourceBuilder() { this(false); } + public V1RBDVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1RBDVolumeSource(), validationEnabled); } - public V1RBDVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent fluent) { + + public V1RBDVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent fluent) { this(fluent, false); } - public V1RBDVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1RBDVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1RBDVolumeSource(), validationEnabled); } - public V1RBDVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1RBDVolumeSource instance) { + + public V1RBDVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1RBDVolumeSource instance) { this(fluent, instance, false); } - public V1RBDVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1RBDVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1RBDVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1RBDVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withImage(instance.getImage()); @@ -37,13 +64,17 @@ public V1RBDVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDVolumeS fluent.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1RBDVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDVolumeSource instance) { - this(instance,false); + this(instance, false); } - public V1RBDVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1RBDVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1RBDVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withImage(instance.getImage()); @@ -60,10 +91,12 @@ public V1RBDVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1RBDVolumeS this.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1RBDVolumeSource build() { V1RBDVolumeSource buildable = new V1RBDVolumeSource(); buildable.setFsType(fluent.getFsType()); @@ -76,18 +109,23 @@ public io.kubernetes.client.openapi.models.V1RBDVolumeSource build() { buildable.setUser(fluent.getUser()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1RBDVolumeSourceBuilder that = (V1RBDVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDVolumeSourceFluent.java index df27457b19..af07747f02 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDVolumeSourceFluent.java @@ -1,104 +1,146 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1RBDVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1RBDVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.String getImage(); + public A withImage(java.lang.String image); + public java.lang.Boolean hasImage(); - - /** - * Method is deprecated. use withImage instead. - */ + + /** Method is deprecated. use withImage instead. */ @java.lang.Deprecated public A withNewImage(java.lang.String original); + public java.lang.String getKeyring(); + public A withKeyring(java.lang.String keyring); + public java.lang.Boolean hasKeyring(); - - /** - * Method is deprecated. use withKeyring instead. - */ + + /** Method is deprecated. use withKeyring instead. */ @java.lang.Deprecated public A withNewKeyring(java.lang.String original); - public A addToMonitors(java.lang.Integer index,java.lang.String item); - public A setToMonitors(java.lang.Integer index,java.lang.String item); + + public A addToMonitors(java.lang.Integer index, java.lang.String item); + + public A setToMonitors(java.lang.Integer index, java.lang.String item); + public A addToMonitors(java.lang.String... items); + public A addAllToMonitors(java.util.Collection items); + public A removeFromMonitors(java.lang.String... items); + public A removeAllFromMonitors(java.util.Collection items); + public java.util.List getMonitors(); + public java.lang.String getMonitor(java.lang.Integer index); + public java.lang.String getFirstMonitor(); + public java.lang.String getLastMonitor(); - public java.lang.String getMatchingMonitor(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMonitor(java.util.function.Predicate predicate); + + public java.lang.String getMatchingMonitor( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingMonitor( + java.util.function.Predicate predicate); + public A withMonitors(java.util.List monitors); + public A withMonitors(java.lang.String... monitors); + public java.lang.Boolean hasMonitors(); + public A addNewMonitor(java.lang.String original); + public java.lang.String getPool(); + public A withPool(java.lang.String pool); + public java.lang.Boolean hasPool(); - - /** - * Method is deprecated. use withPool instead. - */ + + /** Method is deprecated. use withPool instead. */ @java.lang.Deprecated public A withNewPool(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + public java.lang.String getUser(); + public A withUser(java.lang.String user); + public java.lang.Boolean hasUser(); - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent>{ + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDVolumeSourceFluentImpl.java index 794fb5678e..1c60383305 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RBDVolumeSourceFluentImpl.java @@ -1,24 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1RBDVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent{ - public V1RBDVolumeSourceFluentImpl() { - } - public V1RBDVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1RBDVolumeSource instance) { +/** Generated */ +public class V1RBDVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent { + public V1RBDVolumeSourceFluentImpl() {} + + public V1RBDVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1RBDVolumeSource instance) { this.withFsType(instance.getFsType()); this.withImage(instance.getImage()); @@ -34,8 +36,8 @@ public V1RBDVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1RBDVolu this.withSecretRef(instance.getSecretRef()); this.withUser(instance.getUser()); - } + private java.lang.String fsType; private java.lang.String image; private java.lang.String keyring; @@ -44,220 +46,338 @@ public V1RBDVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1RBDVolu private java.lang.Boolean readOnly; private io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder secretRef; private java.lang.String user; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.String getImage() { return this.image; } + public A withImage(java.lang.String image) { - this.image=image; return (A) this; + this.image = image; + return (A) this; } + public java.lang.Boolean hasImage() { return this.image != null; } - - /** - * Method is deprecated. use withImage instead. - */ + + /** Method is deprecated. use withImage instead. */ @java.lang.Deprecated public A withNewImage(java.lang.String original) { - return (A)withImage(new String(original)); + return (A) withImage(new String(original)); } + public java.lang.String getKeyring() { return this.keyring; } + public A withKeyring(java.lang.String keyring) { - this.keyring=keyring; return (A) this; + this.keyring = keyring; + return (A) this; } + public java.lang.Boolean hasKeyring() { return this.keyring != null; } - - /** - * Method is deprecated. use withKeyring instead. - */ + + /** Method is deprecated. use withKeyring instead. */ @java.lang.Deprecated public A withNewKeyring(java.lang.String original) { - return (A)withKeyring(new String(original)); + return (A) withKeyring(new String(original)); } - public A addToMonitors(java.lang.Integer index,java.lang.String item) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} + + public A addToMonitors(java.lang.Integer index, java.lang.String item) { + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } this.monitors.add(index, item); - return (A)this; + return (A) this; } - public A setToMonitors(java.lang.Integer index,java.lang.String item) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} - this.monitors.set(index, item); return (A)this; + + public A setToMonitors(java.lang.Integer index, java.lang.String item) { + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } + this.monitors.set(index, item); + return (A) this; } + public A addToMonitors(java.lang.String... items) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} - for (java.lang.String item : items) {this.monitors.add(item);} return (A)this; + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.monitors.add(item); + } + return (A) this; } + public A addAllToMonitors(java.util.Collection items) { - if (this.monitors == null) {this.monitors = new java.util.ArrayList();} - for (java.lang.String item : items) {this.monitors.add(item);} return (A)this; + if (this.monitors == null) { + this.monitors = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.monitors.add(item); + } + return (A) this; } + public A removeFromMonitors(java.lang.String... items) { - for (java.lang.String item : items) {if (this.monitors!= null){ this.monitors.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.monitors != null) { + this.monitors.remove(item); + } + } + return (A) this; } + public A removeAllFromMonitors(java.util.Collection items) { - for (java.lang.String item : items) {if (this.monitors!= null){ this.monitors.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.monitors != null) { + this.monitors.remove(item); + } + } + return (A) this; } + public java.util.List getMonitors() { return this.monitors; } + public java.lang.String getMonitor(java.lang.Integer index) { return this.monitors.get(index); } + public java.lang.String getFirstMonitor() { return this.monitors.get(0); } + public java.lang.String getLastMonitor() { return this.monitors.get(monitors.size() - 1); } - public java.lang.String getMatchingMonitor(java.util.function.Predicate predicate) { - for (java.lang.String item: monitors) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingMonitor( + java.util.function.Predicate predicate) { + for (java.lang.String item : monitors) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingMonitor(java.util.function.Predicate predicate) { - for (java.lang.String item: monitors) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMonitor( + java.util.function.Predicate predicate) { + for (java.lang.String item : monitors) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withMonitors(java.util.List monitors) { - if (monitors != null) {this.monitors = new java.util.ArrayList(); for (java.lang.String item : monitors){this.addToMonitors(item);}} else { this.monitors = null;} return (A) this; + if (monitors != null) { + this.monitors = new java.util.ArrayList(); + for (java.lang.String item : monitors) { + this.addToMonitors(item); + } + } else { + this.monitors = null; + } + return (A) this; } + public A withMonitors(java.lang.String... monitors) { - if (this.monitors != null) {this.monitors.clear();} - if (monitors != null) {for (java.lang.String item :monitors){ this.addToMonitors(item);}} return (A) this; + if (this.monitors != null) { + this.monitors.clear(); + } + if (monitors != null) { + for (java.lang.String item : monitors) { + this.addToMonitors(item); + } + } + return (A) this; } + public java.lang.Boolean hasMonitors() { return monitors != null && !monitors.isEmpty(); } + public A addNewMonitor(java.lang.String original) { - return (A)addToMonitors(new String(original)); + return (A) addToMonitors(new String(original)); } + public java.lang.String getPool() { return this.pool; } + public A withPool(java.lang.String pool) { - this.pool=pool; return (A) this; + this.pool = pool; + return (A) this; } + public java.lang.Boolean hasPool() { return this.pool != null; } - - /** - * Method is deprecated. use withPool instead. - */ + + /** Method is deprecated. use withPool instead. */ @java.lang.Deprecated public A withNewPool(java.lang.String original) { - return (A)withPool(new String(original)); + return (A) withPool(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluentImpl.SecretRefNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public java.lang.String getUser() { return this.user; } + public A withUser(java.lang.String user) { - this.user=user; return (A) this; + this.user = user; + return (A) this; } + public java.lang.Boolean hasUser() { return this.user != null; } - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original) { - return (A)withUser(new String(original)); + return (A) withUser(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1RBDVolumeSourceFluentImpl that = (V1RBDVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (image != null ? !image.equals(that.image) :that.image != null) return false; - if (keyring != null ? !keyring.equals(that.keyring) :that.keyring != null) return false; - if (monitors != null ? !monitors.equals(that.monitors) :that.monitors != null) return false; - if (pool != null ? !pool.equals(that.pool) :that.pool != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; - if (user != null ? !user.equals(that.user) :that.user != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (image != null ? !image.equals(that.image) : that.image != null) return false; + if (keyring != null ? !keyring.equals(that.keyring) : that.keyring != null) return false; + if (monitors != null ? !monitors.equals(that.monitors) : that.monitors != null) return false; + if (pool != null ? !pool.equals(that.pool) : that.pool != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; + if (user != null ? !user.equals(that.user) : that.user != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, image, keyring, monitors, pool, readOnly, secretRef, user, super.hashCode()); + return java.util.Objects.hash( + fsType, image, keyring, monitors, pool, readOnly, secretRef, user, super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested> + implements io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent.SecretRefNested, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder; + public N and() { return (N) V1RBDVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetBuilder.java index 6519999522..68b8804700 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ReplicaSetBuilder extends io.kubernetes.client.openapi.models.V1ReplicaSetFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ReplicaSetBuilder + extends io.kubernetes.client.openapi.models.V1ReplicaSetFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicaSetBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ReplicaSet, + io.kubernetes.client.openapi.models.V1ReplicaSetBuilder> { public V1ReplicaSetBuilder() { this(false); } + public V1ReplicaSetBuilder(java.lang.Boolean validationEnabled) { this(new V1ReplicaSet(), validationEnabled); } + public V1ReplicaSetBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetFluent fluent) { this(fluent, false); } - public V1ReplicaSetBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ReplicaSetBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ReplicaSet(), validationEnabled); } - public V1ReplicaSetBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetFluent fluent,io.kubernetes.client.openapi.models.V1ReplicaSet instance) { + + public V1ReplicaSetBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicaSet instance) { this(fluent, instance, false); } - public V1ReplicaSetBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetFluent fluent,io.kubernetes.client.openapi.models.V1ReplicaSet instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ReplicaSetBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicaSet instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,17 @@ public V1ReplicaSetBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetFluen fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ReplicaSetBuilder(io.kubernetes.client.openapi.models.V1ReplicaSet instance) { - this(instance,false); + this(instance, false); } - public V1ReplicaSetBuilder(io.kubernetes.client.openapi.models.V1ReplicaSet instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ReplicaSetBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSet instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +78,12 @@ public V1ReplicaSetBuilder(io.kubernetes.client.openapi.models.V1ReplicaSet inst this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ReplicaSetFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ReplicaSet build() { V1ReplicaSet buildable = new V1ReplicaSet(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +93,23 @@ public io.kubernetes.client.openapi.models.V1ReplicaSet build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ReplicaSetBuilder that = (V1ReplicaSetBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetConditionBuilder.java index c0e6409f56..56ec02ebbc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ReplicaSetConditionBuilder extends io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ReplicaSetConditionBuilder + extends io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ReplicaSetCondition, + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder> { public V1ReplicaSetConditionBuilder() { this(false); } + public V1ReplicaSetConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1ReplicaSetCondition(), validationEnabled); } - public V1ReplicaSetConditionBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent fluent) { + + public V1ReplicaSetConditionBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent fluent) { this(fluent, false); } - public V1ReplicaSetConditionBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ReplicaSetConditionBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ReplicaSetCondition(), validationEnabled); } - public V1ReplicaSetConditionBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent fluent,io.kubernetes.client.openapi.models.V1ReplicaSetCondition instance) { + + public V1ReplicaSetConditionBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicaSetCondition instance) { this(fluent, instance, false); } - public V1ReplicaSetConditionBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent fluent,io.kubernetes.client.openapi.models.V1ReplicaSetCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ReplicaSetConditionBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicaSetCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +58,18 @@ public V1ReplicaSetConditionBuilder(io.kubernetes.client.openapi.models.V1Replic fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ReplicaSetConditionBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetCondition instance) { - this(instance,false); + + public V1ReplicaSetConditionBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetCondition instance) { + this(instance, false); } - public V1ReplicaSetConditionBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ReplicaSetConditionBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,10 +80,12 @@ public V1ReplicaSetConditionBuilder(io.kubernetes.client.openapi.models.V1Replic this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ReplicaSetCondition build() { V1ReplicaSetCondition buildable = new V1ReplicaSetCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1ReplicaSetCondition build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ReplicaSetConditionBuilder that = (V1ReplicaSetConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetConditionFluent.java index 0bba21c321..69d9a320d8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetConditionFluent.java @@ -1,54 +1,64 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ReplicaSetConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ReplicaSetConditionFluent< + A extends io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetConditionFluentImpl.java index 73f67417e6..c8a8b1c9f9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetConditionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ReplicaSetConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent { + public V1ReplicaSetConditionFluentImpl() {} - /** - * Generated - */ -public class V1ReplicaSetConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent{ - public V1ReplicaSetConditionFluentImpl() { - } - public V1ReplicaSetConditionFluentImpl(io.kubernetes.client.openapi.models.V1ReplicaSetCondition instance) { + public V1ReplicaSetConditionFluentImpl( + io.kubernetes.client.openapi.models.V1ReplicaSetCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,103 +30,119 @@ public V1ReplicaSetConditionFluentImpl(io.kubernetes.client.openapi.models.V1Rep this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ReplicaSetConditionFluentImpl that = (V1ReplicaSetConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetFluent.java index bf6f52eac9..ab5a009cc9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetFluent.java @@ -1,93 +1,144 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ReplicaSetFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ReplicaSetFluent< + A extends io.kubernetes.client.openapi.models.V1ReplicaSetFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ReplicaSetSpec getSpec(); + public io.kubernetes.client.openapi.models.V1ReplicaSetSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1ReplicaSetSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1ReplicaSetSpec item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1ReplicaSetSpec item); + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1ReplicaSetSpec item); - + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1ReplicaSetSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ReplicaSetStatus getStatus(); + public io.kubernetes.client.openapi.models.V1ReplicaSetStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1ReplicaSetStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1ReplicaSetStatus item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1ReplicaSetStatus item); + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ReplicaSetStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1ReplicaSetStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent< + io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent< + io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetFluentImpl.java index e4d4b4a8a4..7d3c5fb079 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1ReplicaSetFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ReplicaSetFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ReplicaSetFluent { + public V1ReplicaSetFluentImpl() {} - /** - * Generated - */ -public class V1ReplicaSetFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ReplicaSetFluent{ - public V1ReplicaSetFluentImpl() { - } public V1ReplicaSetFluentImpl(io.kubernetes.client.openapi.models.V1ReplicaSet instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +29,296 @@ public V1ReplicaSetFluentImpl(io.kubernetes.client.openapi.models.V1ReplicaSet i this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1ReplicaSetSpecBuilder spec; private io.kubernetes.client.openapi.models.V1ReplicaSetStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1ReplicaSetFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1ReplicaSetFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ReplicaSetSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1ReplicaSetSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1ReplicaSetSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1ReplicaSetSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1ReplicaSetSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1ReplicaSetFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1ReplicaSetSpec item) { + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1ReplicaSetSpec item) { return new io.kubernetes.client.openapi.models.V1ReplicaSetFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1ReplicaSetSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1ReplicaSetSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1ReplicaSetSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1ReplicaSetSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ReplicaSetStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1ReplicaSetStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1ReplicaSetStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1ReplicaSetStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1ReplicaSetStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1ReplicaSetFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1ReplicaSetStatus item) { + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1ReplicaSetStatus item) { return new io.kubernetes.client.openapi.models.V1ReplicaSetFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1ReplicaSetStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1ReplicaSetStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ReplicaSetStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1ReplicaSetStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ReplicaSetFluentImpl that = (V1ReplicaSetFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ReplicaSetFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1ReplicaSetFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1ReplicaSetFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1ReplicaSetSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1ReplicaSetSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ReplicaSetSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1ReplicaSetSpecBuilder builder; + public N and() { return (N) V1ReplicaSetFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1ReplicaSetFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1ReplicaSetStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1ReplicaSetStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ReplicaSetStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1ReplicaSetStatusBuilder builder; + public N and() { return (N) V1ReplicaSetFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetListBuilder.java index eee7eaf9aa..26ac4a71be 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ReplicaSetListBuilder extends io.kubernetes.client.openapi.models.V1ReplicaSetListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ReplicaSetListBuilder + extends io.kubernetes.client.openapi.models.V1ReplicaSetListFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicaSetListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ReplicaSetList, + io.kubernetes.client.openapi.models.V1ReplicaSetListBuilder> { public V1ReplicaSetListBuilder() { this(false); } + public V1ReplicaSetListBuilder(java.lang.Boolean validationEnabled) { this(new V1ReplicaSetList(), validationEnabled); } - public V1ReplicaSetListBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetListFluent fluent) { + + public V1ReplicaSetListBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetListFluent fluent) { this(fluent, false); } - public V1ReplicaSetListBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ReplicaSetListBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ReplicaSetList(), validationEnabled); } - public V1ReplicaSetListBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetListFluent fluent,io.kubernetes.client.openapi.models.V1ReplicaSetList instance) { + + public V1ReplicaSetListBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetListFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicaSetList instance) { this(fluent, instance, false); } - public V1ReplicaSetListBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetListFluent fluent,io.kubernetes.client.openapi.models.V1ReplicaSetList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ReplicaSetListBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetListFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicaSetList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1ReplicaSetListBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetL fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ReplicaSetListBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetList instance) { - this(instance,false); + this(instance, false); } - public V1ReplicaSetListBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ReplicaSetListBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1ReplicaSetListBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetL this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ReplicaSetListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ReplicaSetList build() { V1ReplicaSetList buildable = new V1ReplicaSetList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1ReplicaSetList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ReplicaSetListBuilder that = (V1ReplicaSetListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetListFluent.java index 02144d6750..cdb71f9f9d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetListFluent.java @@ -1,95 +1,154 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ReplicaSetListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ReplicaSetListFluent< + A extends io.kubernetes.client.openapi.models.V1ReplicaSetListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSet item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSet item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSet item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSet item); + public A addToItems(io.kubernetes.client.openapi.models.V1ReplicaSet... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1ReplicaSet... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1ReplicaSet buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ReplicaSet buildFirstItem(); + public io.kubernetes.client.openapi.models.V1ReplicaSet buildLastItem(); - public io.kubernetes.client.openapi.models.V1ReplicaSet buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ReplicaSet buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1ReplicaSet... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ReplicaSet item); - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSet item); - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1ReplicaSet item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSet item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ReplicaSetFluent>{ + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ReplicaSetFluent< + io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetListFluentImpl.java index 864cde6fcf..671aa12721 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1ReplicaSetListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ReplicaSetListFluent{ - public V1ReplicaSetListFluentImpl() { - } +/** Generated */ +public class V1ReplicaSetListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ReplicaSetListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ReplicaSetListFluent { + public V1ReplicaSetListFluentImpl() {} + public V1ReplicaSetListFluentImpl(io.kubernetes.client.openapi.models.V1ReplicaSetList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,123 @@ public V1ReplicaSetListFluentImpl(io.kubernetes.client.openapi.models.V1ReplicaS this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSet item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ReplicaSetBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSet item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ReplicaSetBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSet item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ReplicaSetBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSet item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ReplicaSetBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1ReplicaSet... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ReplicaSet item : items) {io.kubernetes.client.openapi.models.V1ReplicaSetBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ReplicaSet item : items) { + io.kubernetes.client.openapi.models.V1ReplicaSetBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ReplicaSet item : items) {io.kubernetes.client.openapi.models.V1ReplicaSetBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ReplicaSet item : items) { + io.kubernetes.client.openapi.models.V1ReplicaSetBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1ReplicaSet... items) { - for (io.kubernetes.client.openapi.models.V1ReplicaSet item : items) {io.kubernetes.client.openapi.models.V1ReplicaSetBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ReplicaSet item : items) { + io.kubernetes.client.openapi.models.V1ReplicaSetBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ReplicaSet item : items) {io.kubernetes.client.openapi.models.V1ReplicaSetBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ReplicaSet item : items) { + io.kubernetes.client.openapi.models.V1ReplicaSetBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +157,275 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1ReplicaSet buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ReplicaSet buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ReplicaSet buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ReplicaSet buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ReplicaSetBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ReplicaSet buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ReplicaSetBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ReplicaSetBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ReplicaSetBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ReplicaSet item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ReplicaSet item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1ReplicaSet... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1ReplicaSet item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1ReplicaSet item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1ReplicaSetListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ReplicaSet item) { - return new io.kubernetes.client.openapi.models.V1ReplicaSetListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1ReplicaSet item) { + return new io.kubernetes.client.openapi.models.V1ReplicaSetListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSet item) { - return new io.kubernetes.client.openapi.models.V1ReplicaSetListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSet item) { + return new io.kubernetes.client.openapi.models.V1ReplicaSetListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1ReplicaSetListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1ReplicaSetListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1ReplicaSetListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ReplicaSetListFluentImpl that = (V1ReplicaSetListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1ReplicaSetFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSet item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1ReplicaSetFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSet item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ReplicaSetBuilder(this); } + io.kubernetes.client.openapi.models.V1ReplicaSetBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ReplicaSetListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1ReplicaSetListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ReplicaSetListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1ReplicaSetListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetSpecBuilder.java index cda23d3517..7db8eee6ca 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ReplicaSetSpecBuilder extends io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ReplicaSetSpecBuilder + extends io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicaSetSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ReplicaSetSpec, + io.kubernetes.client.openapi.models.V1ReplicaSetSpecBuilder> { public V1ReplicaSetSpecBuilder() { this(false); } + public V1ReplicaSetSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1ReplicaSetSpec(), validationEnabled); } - public V1ReplicaSetSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent fluent) { + + public V1ReplicaSetSpecBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent fluent) { this(fluent, false); } - public V1ReplicaSetSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ReplicaSetSpecBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ReplicaSetSpec(), validationEnabled); } - public V1ReplicaSetSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent fluent,io.kubernetes.client.openapi.models.V1ReplicaSetSpec instance) { + + public V1ReplicaSetSpecBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicaSetSpec instance) { this(fluent, instance, false); } - public V1ReplicaSetSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent fluent,io.kubernetes.client.openapi.models.V1ReplicaSetSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ReplicaSetSpecBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicaSetSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMinReadySeconds(instance.getMinReadySeconds()); fluent.withReplicas(instance.getReplicas()); @@ -29,13 +56,17 @@ public V1ReplicaSetSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetS fluent.withTemplate(instance.getTemplate()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ReplicaSetSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetSpec instance) { - this(instance,false); + this(instance, false); } - public V1ReplicaSetSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ReplicaSetSpecBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMinReadySeconds(instance.getMinReadySeconds()); this.withReplicas(instance.getReplicas()); @@ -44,10 +75,12 @@ public V1ReplicaSetSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetS this.withTemplate(instance.getTemplate()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ReplicaSetSpec build() { V1ReplicaSetSpec buildable = new V1ReplicaSetSpec(); buildable.setMinReadySeconds(fluent.getMinReadySeconds()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1ReplicaSetSpec build() { buildable.setTemplate(fluent.getTemplate()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ReplicaSetSpecBuilder that = (V1ReplicaSetSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetSpecFluent.java index 63d3ab608d..111eca3e88 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetSpecFluent.java @@ -1,62 +1,106 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ReplicaSetSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ReplicaSetSpecFluent< + A extends io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getMinReadySeconds(); + public A withMinReadySeconds(java.lang.Integer minReadySeconds); + public java.lang.Boolean hasMinReadySeconds(); + public java.lang.Integer getReplicas(); + public A withReplicas(java.lang.Integer replicas); + public java.lang.Boolean hasReplicas(); - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested editSelector(); - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested + withNewSelector(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested + editSelector(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested + editOrNewSelector(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate(); + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate(); + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template); + public java.lang.Boolean hasTemplate(); - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested withNewTemplate(); - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested editTemplate(); - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested editOrNewTemplate(); - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested + withNewTemplate(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested + withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested + editTemplate(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested + editOrNewTemplate(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested> { public N and(); + public N endSelector(); - } - public interface TemplateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent>{ + + public interface TemplateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent< + io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested> { public N and(); + public N endTemplate(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetSpecFluentImpl.java index b882cc3205..77b9190aa7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetSpecFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1ReplicaSetSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent { + public V1ReplicaSetSpecFluentImpl() {} - /** - * Generated - */ -public class V1ReplicaSetSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent{ - public V1ReplicaSetSpecFluentImpl() { - } public V1ReplicaSetSpecFluentImpl(io.kubernetes.client.openapi.models.V1ReplicaSetSpec instance) { this.withMinReadySeconds(instance.getMinReadySeconds()); @@ -21,142 +27,213 @@ public V1ReplicaSetSpecFluentImpl(io.kubernetes.client.openapi.models.V1ReplicaS this.withSelector(instance.getSelector()); this.withTemplate(instance.getTemplate()); - } + private java.lang.Integer minReadySeconds; private java.lang.Integer replicas; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder selector; private io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder template; + public java.lang.Integer getMinReadySeconds() { return this.minReadySeconds; } + public A withMinReadySeconds(java.lang.Integer minReadySeconds) { - this.minReadySeconds=minReadySeconds; return (A) this; + this.minReadySeconds = minReadySeconds; + return (A) this; } + public java.lang.Boolean hasMinReadySeconds() { return this.minReadySeconds != null; } + public java.lang.Integer getReplicas() { return this.replicas; } + public A withReplicas(java.lang.Integer replicas) { - this.replicas=replicas; return (A) this; + this.replicas = replicas; + return (A) this; } + public java.lang.Boolean hasReplicas() { return this.replicas != null; } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested withNewSelector() { + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested + withNewSelector() { return new io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluentImpl.SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluentImpl.SelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluentImpl.SelectorNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested editSelector() { + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested + editSelector() { return withNewSelectorLike(getSelector()); } - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested + editOrNewSelector() { + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } - + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template) { _visitables.get("template").remove(this.template); - if (template!=null){ this.template= new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); _visitables.get("template").add(this.template);} return (A) this; + if (template != null) { + this.template = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); + _visitables.get("template").add(this.template); + } + return (A) this; } + public java.lang.Boolean hasTemplate() { return this.template != null; } - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested withNewTemplate() { + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested + withNewTemplate() { return new io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluentImpl.TemplateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { - return new io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluentImpl.TemplateNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested + withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + return new io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluentImpl.TemplateNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested editTemplate() { + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested + editTemplate() { return withNewTemplateLike(getTemplate()); } - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested editOrNewTemplate() { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested + editOrNewTemplate() { + return withNewTemplateLike( + getTemplate() != null + ? getTemplate() + : new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + return withNewTemplateLike(getTemplate() != null ? getTemplate() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ReplicaSetSpecFluentImpl that = (V1ReplicaSetSpecFluentImpl) o; - if (minReadySeconds != null ? !minReadySeconds.equals(that.minReadySeconds) :that.minReadySeconds != null) return false; - if (replicas != null ? !replicas.equals(that.replicas) :that.replicas != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; - if (template != null ? !template.equals(that.template) :that.template != null) return false; + if (minReadySeconds != null + ? !minReadySeconds.equals(that.minReadySeconds) + : that.minReadySeconds != null) return false; + if (replicas != null ? !replicas.equals(that.replicas) : that.replicas != null) return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; + if (template != null ? !template.equals(that.template) : that.template != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(minReadySeconds, replicas, selector, template, super.hashCode()); + return java.util.Objects.hash(minReadySeconds, replicas, selector, template, super.hashCode()); } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested> + implements io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.SelectorNested, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1ReplicaSetSpecFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - public class TemplateNestedImpl extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested,io.kubernetes.client.fluent.Nested{ + + public class TemplateNestedImpl + extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested> + implements io.kubernetes.client.openapi.models.V1ReplicaSetSpecFluent.TemplateNested, + io.kubernetes.client.fluent.Nested { TemplateNestedImpl(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this, item); } + TemplateNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder builder; + public N and() { return (N) V1ReplicaSetSpecFluentImpl.this.withTemplate(builder.build()); } + public N endTemplate() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetStatusBuilder.java index 293a1e601c..d0e84662bf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ReplicaSetStatusBuilder extends io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ReplicaSetStatusBuilder + extends io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicaSetStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ReplicaSetStatus, + io.kubernetes.client.openapi.models.V1ReplicaSetStatusBuilder> { public V1ReplicaSetStatusBuilder() { this(false); } + public V1ReplicaSetStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1ReplicaSetStatus(), validationEnabled); } - public V1ReplicaSetStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent fluent) { + + public V1ReplicaSetStatusBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent fluent) { this(fluent, false); } - public V1ReplicaSetStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ReplicaSetStatusBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ReplicaSetStatus(), validationEnabled); } - public V1ReplicaSetStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent fluent,io.kubernetes.client.openapi.models.V1ReplicaSetStatus instance) { + + public V1ReplicaSetStatusBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicaSetStatus instance) { this(fluent, instance, false); } - public V1ReplicaSetStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent fluent,io.kubernetes.client.openapi.models.V1ReplicaSetStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ReplicaSetStatusBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicaSetStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAvailableReplicas(instance.getAvailableReplicas()); fluent.withConditions(instance.getConditions()); @@ -33,13 +60,18 @@ public V1ReplicaSetStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicaSe fluent.withReplicas(instance.getReplicas()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ReplicaSetStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetStatus instance) { - this(instance,false); + + public V1ReplicaSetStatusBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetStatus instance) { + this(instance, false); } - public V1ReplicaSetStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicaSetStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ReplicaSetStatusBuilder( + io.kubernetes.client.openapi.models.V1ReplicaSetStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAvailableReplicas(instance.getAvailableReplicas()); this.withConditions(instance.getConditions()); @@ -52,10 +84,12 @@ public V1ReplicaSetStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicaSe this.withReplicas(instance.getReplicas()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ReplicaSetStatus build() { V1ReplicaSetStatus buildable = new V1ReplicaSetStatus(); buildable.setAvailableReplicas(fluent.getAvailableReplicas()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1ReplicaSetStatus build() { buildable.setReplicas(fluent.getReplicas()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ReplicaSetStatusBuilder that = (V1ReplicaSetStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetStatusFluent.java index e1e5166406..23c80b72b7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetStatusFluent.java @@ -1,73 +1,135 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Long; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ReplicaSetStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ReplicaSetStatusFluent< + A extends io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getAvailableReplicas(); + public A withAvailableReplicas(java.lang.Integer availableReplicas); + public java.lang.Boolean hasAvailableReplicas(); - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSetCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSetCondition item); + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSetCondition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSetCondition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1ReplicaSetCondition... items); - public A addAllToConditions(java.util.Collection items); + + public A addAllToConditions( + java.util.Collection items); + public A removeFromConditions(io.kubernetes.client.openapi.models.V1ReplicaSetCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1ReplicaSetCondition buildCondition(java.lang.Integer index); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetCondition buildCondition( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ReplicaSetCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1ReplicaSetCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1ReplicaSetCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); + + public io.kubernetes.client.openapi.models.V1ReplicaSetCondition buildMatchingCondition( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate); + + public A withConditions( + java.util.List conditions); + public A withConditions(io.kubernetes.client.openapi.models.V1ReplicaSetCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1ReplicaSetCondition item); - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSetCondition item); - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1ReplicaSetCondition item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSetCondition item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder> + predicate); + public java.lang.Integer getFullyLabeledReplicas(); + public A withFullyLabeledReplicas(java.lang.Integer fullyLabeledReplicas); + public java.lang.Boolean hasFullyLabeledReplicas(); + public java.lang.Long getObservedGeneration(); + public A withObservedGeneration(java.lang.Long observedGeneration); + public java.lang.Boolean hasObservedGeneration(); + public java.lang.Integer getReadyReplicas(); + public A withReadyReplicas(java.lang.Integer readyReplicas); + public java.lang.Boolean hasReadyReplicas(); + public java.lang.Integer getReplicas(); + public A withReplicas(java.lang.Integer replicas); + public java.lang.Boolean hasReplicas(); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluent< + io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetStatusFluentImpl.java index 0a0cba5b0e..4762d6bcef 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicaSetStatusFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1ReplicaSetStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent{ - public V1ReplicaSetStatusFluentImpl() { - } - public V1ReplicaSetStatusFluentImpl(io.kubernetes.client.openapi.models.V1ReplicaSetStatus instance) { +/** Generated */ +public class V1ReplicaSetStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent { + public V1ReplicaSetStatusFluentImpl() {} + + public V1ReplicaSetStatusFluentImpl( + io.kubernetes.client.openapi.models.V1ReplicaSetStatus instance) { this.withAvailableReplicas(instance.getAvailableReplicas()); this.withConditions(instance.getConditions()); @@ -32,51 +35,130 @@ public V1ReplicaSetStatusFluentImpl(io.kubernetes.client.openapi.models.V1Replic this.withReadyReplicas(instance.getReadyReplicas()); this.withReplicas(instance.getReplicas()); - } + private java.lang.Integer availableReplicas; - private java.util.ArrayList conditions; + private java.util.ArrayList + conditions; private java.lang.Integer fullyLabeledReplicas; private java.lang.Long observedGeneration; private java.lang.Integer readyReplicas; private java.lang.Integer replicas; + public java.lang.Integer getAvailableReplicas() { return this.availableReplicas; } + public A withAvailableReplicas(java.lang.Integer availableReplicas) { - this.availableReplicas=availableReplicas; return (A) this; + this.availableReplicas = availableReplicas; + return (A) this; } + public java.lang.Boolean hasAvailableReplicas() { return this.availableReplicas != null; } - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSetCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSetCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSetCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSetCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } + public A addToConditions(io.kubernetes.client.openapi.models.V1ReplicaSetCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ReplicaSetCondition item : items) {io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ReplicaSetCondition item : items) { + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ReplicaSetCondition item : items) {io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ReplicaSetCondition item : items) { + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V1ReplicaSetCondition... items) { - for (io.kubernetes.client.openapi.models.V1ReplicaSetCondition item : items) {io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1ReplicaSetCondition... items) { + for (io.kubernetes.client.openapi.models.V1ReplicaSetCondition item : items) { + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ReplicaSetCondition item : items) {io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ReplicaSetCondition item : items) { + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder = each.next(); @@ -85,145 +167,258 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1ReplicaSetCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ReplicaSetCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ReplicaSetCondition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ReplicaSetCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ReplicaSetCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ReplicaSetCondition buildMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ReplicaSetCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ReplicaSetCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } + public A withConditions(io.kubernetes.client.openapi.models.V1ReplicaSetCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1ReplicaSetCondition item :conditions){ this.addToConditions(item);}} return (A) this; + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1ReplicaSetCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1ReplicaSetCondition item) { - return new io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1ReplicaSetCondition item) { + return new io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSetCondition item) { - return new io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSetCondition item) { + return new io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicaSetCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1ReplicaSetConditionFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1ReplicaSetStatusFluent.ConditionsNested, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicaSetCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1ReplicaSetConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ReplicaSetStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1ReplicaSetStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerBuilder.java index 807e483a3f..92652f1932 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ReplicationControllerBuilder extends io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ReplicationControllerBuilder + extends io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ReplicationController, + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder> { public V1ReplicationControllerBuilder() { this(false); } + public V1ReplicationControllerBuilder(java.lang.Boolean validationEnabled) { this(new V1ReplicationController(), validationEnabled); } - public V1ReplicationControllerBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerFluent fluent) { + + public V1ReplicationControllerBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerFluent fluent) { this(fluent, false); } - public V1ReplicationControllerBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ReplicationControllerBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ReplicationController(), validationEnabled); } - public V1ReplicationControllerBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerFluent fluent,io.kubernetes.client.openapi.models.V1ReplicationController instance) { + + public V1ReplicationControllerBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicationController instance) { this(fluent, instance, false); } - public V1ReplicationControllerBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerFluent fluent,io.kubernetes.client.openapi.models.V1ReplicationController instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ReplicationControllerBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicationController instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1ReplicationControllerBuilder(io.kubernetes.client.openapi.models.V1Repl fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ReplicationControllerBuilder(io.kubernetes.client.openapi.models.V1ReplicationController instance) { - this(instance,false); + + public V1ReplicationControllerBuilder( + io.kubernetes.client.openapi.models.V1ReplicationController instance) { + this(instance, false); } - public V1ReplicationControllerBuilder(io.kubernetes.client.openapi.models.V1ReplicationController instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ReplicationControllerBuilder( + io.kubernetes.client.openapi.models.V1ReplicationController instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1ReplicationControllerBuilder(io.kubernetes.client.openapi.models.V1Repl this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ReplicationControllerFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ReplicationController build() { V1ReplicationController buildable = new V1ReplicationController(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1ReplicationController build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ReplicationControllerBuilder that = (V1ReplicationControllerBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerConditionBuilder.java index 108e7f5ce2..c4faec9340 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ReplicationControllerConditionBuilder extends io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ReplicationControllerConditionBuilder + extends io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition, + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder> { public V1ReplicationControllerConditionBuilder() { this(false); } + public V1ReplicationControllerConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1ReplicationControllerCondition(), validationEnabled); } - public V1ReplicationControllerConditionBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent fluent) { + + public V1ReplicationControllerConditionBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent fluent) { this(fluent, false); } - public V1ReplicationControllerConditionBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ReplicationControllerConditionBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ReplicationControllerCondition(), validationEnabled); } - public V1ReplicationControllerConditionBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent fluent,io.kubernetes.client.openapi.models.V1ReplicationControllerCondition instance) { + + public V1ReplicationControllerConditionBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition instance) { this(fluent, instance, false); } - public V1ReplicationControllerConditionBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent fluent,io.kubernetes.client.openapi.models.V1ReplicationControllerCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ReplicationControllerConditionBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +58,18 @@ public V1ReplicationControllerConditionBuilder(io.kubernetes.client.openapi.mode fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ReplicationControllerConditionBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerCondition instance) { - this(instance,false); + + public V1ReplicationControllerConditionBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition instance) { + this(instance, false); } - public V1ReplicationControllerConditionBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ReplicationControllerConditionBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,10 +80,12 @@ public V1ReplicationControllerConditionBuilder(io.kubernetes.client.openapi.mode this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition build() { V1ReplicationControllerCondition buildable = new V1ReplicationControllerCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition buil buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ReplicationControllerConditionBuilder that = (V1ReplicationControllerConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerConditionFluent.java index 762362fcf3..4c2bc23b8a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerConditionFluent.java @@ -1,54 +1,64 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ReplicationControllerConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ReplicationControllerConditionFluent< + A extends io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerConditionFluentImpl.java index 472d19dc93..2c7a8bbb63 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerConditionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ReplicationControllerConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent { + public V1ReplicationControllerConditionFluentImpl() {} - /** - * Generated - */ -public class V1ReplicationControllerConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent{ - public V1ReplicationControllerConditionFluentImpl() { - } - public V1ReplicationControllerConditionFluentImpl(io.kubernetes.client.openapi.models.V1ReplicationControllerCondition instance) { + public V1ReplicationControllerConditionFluentImpl( + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,103 +30,120 @@ public V1ReplicationControllerConditionFluentImpl(io.kubernetes.client.openapi.m this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1ReplicationControllerConditionFluentImpl that = (V1ReplicationControllerConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + V1ReplicationControllerConditionFluentImpl that = + (V1ReplicationControllerConditionFluentImpl) o; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerFluent.java index 108d4db22a..65373508b0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerFluent.java @@ -1,93 +1,151 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ReplicationControllerFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ReplicationControllerFluent< + A extends io.kubernetes.client.openapi.models.V1ReplicationControllerFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ReplicationControllerSpec getSpec(); + public io.kubernetes.client.openapi.models.V1ReplicationControllerSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec item); + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec item); - + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ReplicationControllerStatus getStatus(); + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus item); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent< + io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent< + io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerFluentImpl.java index eeeb6e08f9..5eb1224f86 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1ReplicationControllerFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ReplicationControllerFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ReplicationControllerFluent { + public V1ReplicationControllerFluentImpl() {} - /** - * Generated - */ -public class V1ReplicationControllerFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ReplicationControllerFluent{ - public V1ReplicationControllerFluentImpl() { - } - public V1ReplicationControllerFluentImpl(io.kubernetes.client.openapi.models.V1ReplicationController instance) { + public V1ReplicationControllerFluentImpl( + io.kubernetes.client.openapi.models.V1ReplicationController instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,316 @@ public V1ReplicationControllerFluentImpl(io.kubernetes.client.openapi.models.V1R this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1ReplicationControllerSpecBuilder spec; private io.kubernetes.client.openapi.models.V1ReplicationControllerStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ReplicationControllerSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1ReplicationControllerSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1ReplicationControllerSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1ReplicationControllerSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec item) { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec item) { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl.SpecNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1ReplicationControllerSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1ReplicationControllerSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ReplicationControllerStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus item) { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus item) { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ReplicationControllerFluentImpl that = (V1ReplicationControllerFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1ReplicationControllerFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerSpecBuilder(this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1ReplicationControllerSpecBuilder builder; + public N and() { return (N) V1ReplicationControllerFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1ReplicationControllerFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusBuilder(this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1ReplicationControllerStatusBuilder builder; + public N and() { return (N) V1ReplicationControllerFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerListBuilder.java index d71a4dc4c8..cd8c0fa4e0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ReplicationControllerListBuilder extends io.kubernetes.client.openapi.models.V1ReplicationControllerListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ReplicationControllerListBuilder + extends io.kubernetes.client.openapi.models.V1ReplicationControllerListFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicationControllerListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ReplicationControllerList, + io.kubernetes.client.openapi.models.V1ReplicationControllerListBuilder> { public V1ReplicationControllerListBuilder() { this(false); } + public V1ReplicationControllerListBuilder(java.lang.Boolean validationEnabled) { this(new V1ReplicationControllerList(), validationEnabled); } - public V1ReplicationControllerListBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent fluent) { + + public V1ReplicationControllerListBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent fluent) { this(fluent, false); } - public V1ReplicationControllerListBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ReplicationControllerListBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ReplicationControllerList(), validationEnabled); } - public V1ReplicationControllerListBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent fluent,io.kubernetes.client.openapi.models.V1ReplicationControllerList instance) { + + public V1ReplicationControllerListBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicationControllerList instance) { this(fluent, instance, false); } - public V1ReplicationControllerListBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent fluent,io.kubernetes.client.openapi.models.V1ReplicationControllerList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ReplicationControllerListBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicationControllerList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1ReplicationControllerListBuilder(io.kubernetes.client.openapi.models.V1 fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ReplicationControllerListBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerList instance) { - this(instance,false); + + public V1ReplicationControllerListBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerList instance) { + this(instance, false); } - public V1ReplicationControllerListBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ReplicationControllerListBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1ReplicationControllerListBuilder(io.kubernetes.client.openapi.models.V1 this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ReplicationControllerList build() { V1ReplicationControllerList buildable = new V1ReplicationControllerList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1ReplicationControllerList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ReplicationControllerListBuilder that = (V1ReplicationControllerListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerListFluent.java index 72a0d00688..26bb63f9a2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerListFluent.java @@ -1,95 +1,168 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ReplicationControllerListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ReplicationControllerListFluent< + A extends io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationController item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationController item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicationController item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicationController item); + public A addToItems(io.kubernetes.client.openapi.models.V1ReplicationController... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1ReplicationController... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1ReplicationController buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ReplicationController buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ReplicationController buildFirstItem(); + public io.kubernetes.client.openapi.models.V1ReplicationController buildLastItem(); - public io.kubernetes.client.openapi.models.V1ReplicationController buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1ReplicationController buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1ReplicationController... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ReplicationController item); - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationController item); - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1ReplicationController item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ReplicationController item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ReplicationControllerFluent>{ + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ReplicationControllerFluent< + io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerListFluentImpl.java index 3f9c141635..676bbd30d7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1ReplicationControllerListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent{ - public V1ReplicationControllerListFluentImpl() { - } - public V1ReplicationControllerListFluentImpl(io.kubernetes.client.openapi.models.V1ReplicationControllerList instance) { + +/** Generated */ +public class V1ReplicationControllerListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent { + public V1ReplicationControllerListFluentImpl() {} + + public V1ReplicationControllerListFluentImpl( + io.kubernetes.client.openapi.models.V1ReplicationControllerList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,132 @@ public V1ReplicationControllerListFluentImpl(io.kubernetes.client.openapi.models this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationController item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicationController item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder>(); + } + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationController item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicationController item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder>(); + } + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1ReplicationController... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ReplicationController item : items) {io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ReplicationController item : items) { + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ReplicationController item : items) {io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ReplicationController item : items) { + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1ReplicationController... items) { - for (io.kubernetes.client.openapi.models.V1ReplicationController item : items) {io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ReplicationController item : items) { + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ReplicationController item : items) {io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ReplicationController item : items) { + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder = each.next(); @@ -87,174 +165,292 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1ReplicationController buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ReplicationController buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ReplicationController buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ReplicationController buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ReplicationController buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ReplicationController buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ReplicationController item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ReplicationController item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1ReplicationController... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1ReplicationController item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1ReplicationController item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ReplicationController item) { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1ReplicationController item) { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationController item) { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ReplicationController item) { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ReplicationControllerListFluentImpl that = (V1ReplicationControllerListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationController item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1ReplicationControllerFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ReplicationController item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder(this); } + io.kubernetes.client.openapi.models.V1ReplicationControllerBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ReplicationControllerListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1ReplicationControllerListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ReplicationControllerListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1ReplicationControllerListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerSpecBuilder.java index 613262cba4..da6404389b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ReplicationControllerSpecBuilder extends io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ReplicationControllerSpecBuilder + extends io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicationControllerSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ReplicationControllerSpec, + io.kubernetes.client.openapi.models.V1ReplicationControllerSpecBuilder> { public V1ReplicationControllerSpecBuilder() { this(false); } + public V1ReplicationControllerSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1ReplicationControllerSpec(), validationEnabled); } - public V1ReplicationControllerSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent fluent) { + + public V1ReplicationControllerSpecBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent fluent) { this(fluent, false); } - public V1ReplicationControllerSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ReplicationControllerSpecBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ReplicationControllerSpec(), validationEnabled); } - public V1ReplicationControllerSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent fluent,io.kubernetes.client.openapi.models.V1ReplicationControllerSpec instance) { + + public V1ReplicationControllerSpecBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicationControllerSpec instance) { this(fluent, instance, false); } - public V1ReplicationControllerSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent fluent,io.kubernetes.client.openapi.models.V1ReplicationControllerSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ReplicationControllerSpecBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicationControllerSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMinReadySeconds(instance.getMinReadySeconds()); fluent.withReplicas(instance.getReplicas()); @@ -29,13 +56,18 @@ public V1ReplicationControllerSpecBuilder(io.kubernetes.client.openapi.models.V1 fluent.withTemplate(instance.getTemplate()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ReplicationControllerSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec instance) { - this(instance,false); + + public V1ReplicationControllerSpecBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerSpec instance) { + this(instance, false); } - public V1ReplicationControllerSpecBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ReplicationControllerSpecBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMinReadySeconds(instance.getMinReadySeconds()); this.withReplicas(instance.getReplicas()); @@ -44,10 +76,12 @@ public V1ReplicationControllerSpecBuilder(io.kubernetes.client.openapi.models.V1 this.withTemplate(instance.getTemplate()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ReplicationControllerSpec build() { V1ReplicationControllerSpec buildable = new V1ReplicationControllerSpec(); buildable.setMinReadySeconds(fluent.getMinReadySeconds()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1ReplicationControllerSpec build() { buildable.setTemplate(fluent.getTemplate()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ReplicationControllerSpecBuilder that = (V1ReplicationControllerSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerSpecFluent.java index 6c688db75a..dc6bb19508 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerSpecFluent.java @@ -1,51 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1ReplicationControllerSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ReplicationControllerSpecFluent< + A extends io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getMinReadySeconds(); + public A withMinReadySeconds(java.lang.Integer minReadySeconds); + public java.lang.Boolean hasMinReadySeconds(); + public java.lang.Integer getReplicas(); + public A withReplicas(java.lang.Integer replicas); + public java.lang.Boolean hasReplicas(); - public A addToSelector(java.lang.String key,java.lang.String value); - public A addToSelector(java.util.Map map); + + public A addToSelector(java.lang.String key, java.lang.String value); + + public A addToSelector(java.util.Map map); + public A removeFromSelector(java.lang.String key); - public A removeFromSelector(java.util.Map map); - public java.util.Map getSelector(); - public A withSelector(java.util.Map selector); + + public A removeFromSelector(java.util.Map map); + + public java.util.Map getSelector(); + + public A withSelector(java.util.Map selector); + public java.lang.Boolean hasSelector(); - + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate(); + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate(); + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template); + public java.lang.Boolean hasTemplate(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested withNewTemplate(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); - public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested editTemplate(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested editOrNewTemplate(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); - public interface TemplateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent>{ + + public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested + withNewTemplate(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested + withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested + editTemplate(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested + editOrNewTemplate(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + + public interface TemplateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent< + io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested< + N>> { public N and(); + public N endTemplate(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerSpecFluentImpl.java index a7528127ac..dbefbf59ef 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerSpecFluentImpl.java @@ -1,22 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public class V1ReplicationControllerSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent{ - public V1ReplicationControllerSpecFluentImpl() { - } - public V1ReplicationControllerSpecFluentImpl(io.kubernetes.client.openapi.models.V1ReplicationControllerSpec instance) { +/** Generated */ +public class V1ReplicationControllerSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent { + public V1ReplicationControllerSpecFluentImpl() {} + + public V1ReplicationControllerSpecFluentImpl( + io.kubernetes.client.openapi.models.V1ReplicationControllerSpec instance) { this.withMinReadySeconds(instance.getMinReadySeconds()); this.withReplicas(instance.getReplicas()); @@ -24,117 +28,197 @@ public V1ReplicationControllerSpecFluentImpl(io.kubernetes.client.openapi.models this.withSelector(instance.getSelector()); this.withTemplate(instance.getTemplate()); - } + private java.lang.Integer minReadySeconds; private java.lang.Integer replicas; - private java.util.Map selector; + private java.util.Map selector; private io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder template; + public java.lang.Integer getMinReadySeconds() { return this.minReadySeconds; } + public A withMinReadySeconds(java.lang.Integer minReadySeconds) { - this.minReadySeconds=minReadySeconds; return (A) this; + this.minReadySeconds = minReadySeconds; + return (A) this; } + public java.lang.Boolean hasMinReadySeconds() { return this.minReadySeconds != null; } + public java.lang.Integer getReplicas() { return this.replicas; } + public A withReplicas(java.lang.Integer replicas) { - this.replicas=replicas; return (A) this; + this.replicas = replicas; + return (A) this; } + public java.lang.Boolean hasReplicas() { return this.replicas != null; } - public A addToSelector(java.lang.String key,java.lang.String value) { - if(this.selector == null && key != null && value != null) { this.selector = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.selector.put(key, value);} return (A)this; + + public A addToSelector(java.lang.String key, java.lang.String value) { + if (this.selector == null && key != null && value != null) { + this.selector = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.selector.put(key, value); + } + return (A) this; } - public A addToSelector(java.util.Map map) { - if(this.selector == null && map != null) { this.selector = new java.util.LinkedHashMap(); } - if(map != null) { this.selector.putAll(map);} return (A)this; + + public A addToSelector(java.util.Map map) { + if (this.selector == null && map != null) { + this.selector = new java.util.LinkedHashMap(); + } + if (map != null) { + this.selector.putAll(map); + } + return (A) this; } + public A removeFromSelector(java.lang.String key) { - if(this.selector == null) { return (A) this; } - if(key != null && this.selector != null) {this.selector.remove(key);} return (A)this; + if (this.selector == null) { + return (A) this; + } + if (key != null && this.selector != null) { + this.selector.remove(key); + } + return (A) this; } - public A removeFromSelector(java.util.Map map) { - if(this.selector == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.selector != null){this.selector.remove(key);}}} return (A)this; + + public A removeFromSelector(java.util.Map map) { + if (this.selector == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.selector != null) { + this.selector.remove(key); + } + } + } + return (A) this; } - public java.util.Map getSelector() { + + public java.util.Map getSelector() { return this.selector; } - public A withSelector(java.util.Map selector) { - if (selector == null) { this.selector = null;} else {this.selector = new java.util.LinkedHashMap(selector);} return (A) this; + + public A withSelector(java.util.Map selector) { + if (selector == null) { + this.selector = null; + } else { + this.selector = new java.util.LinkedHashMap(selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template) { _visitables.get("template").remove(this.template); - if (template!=null){ this.template= new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); _visitables.get("template").add(this.template);} return (A) this; + if (template != null) { + this.template = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); + _visitables.get("template").add(this.template); + } + return (A) this; } + public java.lang.Boolean hasTemplate() { return this.template != null; } - public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested withNewTemplate() { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluentImpl.TemplateNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested + withNewTemplate() { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluentImpl + .TemplateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluentImpl.TemplateNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested + withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluentImpl + .TemplateNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested editTemplate() { + + public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested + editTemplate() { return withNewTemplateLike(getTemplate()); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested editOrNewTemplate() { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested + editOrNewTemplate() { + return withNewTemplateLike( + getTemplate() != null + ? getTemplate() + : new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + return withNewTemplateLike(getTemplate() != null ? getTemplate() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ReplicationControllerSpecFluentImpl that = (V1ReplicationControllerSpecFluentImpl) o; - if (minReadySeconds != null ? !minReadySeconds.equals(that.minReadySeconds) :that.minReadySeconds != null) return false; - if (replicas != null ? !replicas.equals(that.replicas) :that.replicas != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; - if (template != null ? !template.equals(that.template) :that.template != null) return false; + if (minReadySeconds != null + ? !minReadySeconds.equals(that.minReadySeconds) + : that.minReadySeconds != null) return false; + if (replicas != null ? !replicas.equals(that.replicas) : that.replicas != null) return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; + if (template != null ? !template.equals(that.template) : that.template != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(minReadySeconds, replicas, selector, template, super.hashCode()); + return java.util.Objects.hash(minReadySeconds, replicas, selector, template, super.hashCode()); } - public class TemplateNestedImpl extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested,io.kubernetes.client.fluent.Nested{ + + public class TemplateNestedImpl + extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent.TemplateNested> + implements io.kubernetes.client.openapi.models.V1ReplicationControllerSpecFluent + .TemplateNested< + N>, + io.kubernetes.client.fluent.Nested { TemplateNestedImpl(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this, item); } + TemplateNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder builder; + public N and() { return (N) V1ReplicationControllerSpecFluentImpl.this.withTemplate(builder.build()); } + public N endTemplate() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerStatusBuilder.java index 67046b37d3..200ade2406 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ReplicationControllerStatusBuilder extends io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ReplicationControllerStatusBuilder + extends io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicationControllerStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ReplicationControllerStatus, + io.kubernetes.client.openapi.models.V1ReplicationControllerStatusBuilder> { public V1ReplicationControllerStatusBuilder() { this(false); } + public V1ReplicationControllerStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1ReplicationControllerStatus(), validationEnabled); } - public V1ReplicationControllerStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent fluent) { + + public V1ReplicationControllerStatusBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent fluent) { this(fluent, false); } - public V1ReplicationControllerStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ReplicationControllerStatusBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ReplicationControllerStatus(), validationEnabled); } - public V1ReplicationControllerStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent fluent,io.kubernetes.client.openapi.models.V1ReplicationControllerStatus instance) { + + public V1ReplicationControllerStatusBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicationControllerStatus instance) { this(fluent, instance, false); } - public V1ReplicationControllerStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent fluent,io.kubernetes.client.openapi.models.V1ReplicationControllerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ReplicationControllerStatusBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ReplicationControllerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAvailableReplicas(instance.getAvailableReplicas()); fluent.withConditions(instance.getConditions()); @@ -33,13 +60,18 @@ public V1ReplicationControllerStatusBuilder(io.kubernetes.client.openapi.models. fluent.withReplicas(instance.getReplicas()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ReplicationControllerStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus instance) { - this(instance,false); + + public V1ReplicationControllerStatusBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerStatus instance) { + this(instance, false); } - public V1ReplicationControllerStatusBuilder(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ReplicationControllerStatusBuilder( + io.kubernetes.client.openapi.models.V1ReplicationControllerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAvailableReplicas(instance.getAvailableReplicas()); this.withConditions(instance.getConditions()); @@ -52,10 +84,12 @@ public V1ReplicationControllerStatusBuilder(io.kubernetes.client.openapi.models. this.withReplicas(instance.getReplicas()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatus build() { V1ReplicationControllerStatus buildable = new V1ReplicationControllerStatus(); buildable.setAvailableReplicas(fluent.getAvailableReplicas()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1ReplicationControllerStatus build() buildable.setReplicas(fluent.getReplicas()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ReplicationControllerStatusBuilder that = (V1ReplicationControllerStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerStatusFluent.java index 3cba3ca6c3..93ad8c02da 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerStatusFluent.java @@ -1,73 +1,152 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Long; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ReplicationControllerStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ReplicationControllerStatusFluent< + A extends io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getAvailableReplicas(); + public A withAvailableReplicas(java.lang.Integer availableReplicas); + public java.lang.Boolean hasAvailableReplicas(); - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item); - public A addToConditions(io.kubernetes.client.openapi.models.V1ReplicationControllerCondition... items); - public A addAllToConditions(java.util.Collection items); - public A removeFromConditions(io.kubernetes.client.openapi.models.V1ReplicationControllerCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item); + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item); + + public A addToConditions( + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition... items); + + public A addAllToConditions( + java.util.Collection + items); + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition... items); + + public A removeAllFromConditions( + java.util.Collection + items); + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder> + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition buildCondition(java.lang.Integer index); + public java.util.List + getConditions(); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition buildCondition( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); - public A withConditions(io.kubernetes.client.openapi.models.V1ReplicationControllerCondition... conditions); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder> + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder> + predicate); + + public A withConditions( + java.util.List + conditions); + + public A withConditions( + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item); - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item); - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + addNewConditionLike( + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder> + predicate); + public java.lang.Integer getFullyLabeledReplicas(); + public A withFullyLabeledReplicas(java.lang.Integer fullyLabeledReplicas); + public java.lang.Boolean hasFullyLabeledReplicas(); + public java.lang.Long getObservedGeneration(); + public A withObservedGeneration(java.lang.Long observedGeneration); + public java.lang.Boolean hasObservedGeneration(); + public java.lang.Integer getReadyReplicas(); + public A withReadyReplicas(java.lang.Integer readyReplicas); + public java.lang.Boolean hasReadyReplicas(); + public java.lang.Integer getReplicas(); + public A withReplicas(java.lang.Integer replicas); + public java.lang.Boolean hasReplicas(); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluent< + io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent + .ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerStatusFluentImpl.java index 6c095bb164..2b4da62287 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ReplicationControllerStatusFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1ReplicationControllerStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent{ - public V1ReplicationControllerStatusFluentImpl() { - } - public V1ReplicationControllerStatusFluentImpl(io.kubernetes.client.openapi.models.V1ReplicationControllerStatus instance) { +/** Generated */ +public class V1ReplicationControllerStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent { + public V1ReplicationControllerStatusFluentImpl() {} + + public V1ReplicationControllerStatusFluentImpl( + io.kubernetes.client.openapi.models.V1ReplicationControllerStatus instance) { this.withAvailableReplicas(instance.getAvailableReplicas()); this.withConditions(instance.getConditions()); @@ -32,198 +35,416 @@ public V1ReplicationControllerStatusFluentImpl(io.kubernetes.client.openapi.mode this.withReadyReplicas(instance.getReadyReplicas()); this.withReplicas(instance.getReplicas()); - } + private java.lang.Integer availableReplicas; - private java.util.ArrayList conditions; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder> + conditions; private java.lang.Integer fullyLabeledReplicas; private java.lang.Long observedGeneration; private java.lang.Integer readyReplicas; private java.lang.Integer replicas; + public java.lang.Integer getAvailableReplicas() { return this.availableReplicas; } + public A withAvailableReplicas(java.lang.Integer availableReplicas) { - this.availableReplicas=availableReplicas; return (A) this; + this.availableReplicas = availableReplicas; + return (A) this; } + public java.lang.Boolean hasAvailableReplicas() { return this.availableReplicas != null; } - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } - public A addToConditions(io.kubernetes.client.openapi.models.V1ReplicationControllerCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item : items) {io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addToConditions( + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition... items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item : items) { + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item : items) {io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection + items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item : items) { + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V1ReplicationControllerCondition... items) { - for (io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item : items) {io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition... items) { + for (io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item : items) { + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item : items) {io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item : items) { + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder> + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator + each = conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions() { + public java.util.List + getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition buildFirstCondition() { + + public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition + buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ReplicationControllerCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List + conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } - public A withConditions(io.kubernetes.client.openapi.models.V1ReplicationControllerCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item :conditions){ this.addToConditions(item);}} return (A) this; + + public A withConditions( + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition... conditions) { + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item) { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + addNewConditionLike( + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item) { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item) { - return new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item) { + return new io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1ReplicationControllerConditionFluentImpl< + io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent.ConditionsNested< + N>> + implements io.kubernetes.client.openapi.models.V1ReplicationControllerStatusFluent + .ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ReplicationControllerCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder( + this, item); } + ConditionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1ReplicationControllerConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ReplicationControllerStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) + V1ReplicationControllerStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceAttributesBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceAttributesBuilder.java index ec509c7572..99d84ab51c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceAttributesBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceAttributesBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ResourceAttributesBuilder extends io.kubernetes.client.openapi.models.V1ResourceAttributesFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ResourceAttributesBuilder + extends io.kubernetes.client.openapi.models.V1ResourceAttributesFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ResourceAttributes, + io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder> { public V1ResourceAttributesBuilder() { this(false); } + public V1ResourceAttributesBuilder(java.lang.Boolean validationEnabled) { this(new V1ResourceAttributes(), validationEnabled); } - public V1ResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1ResourceAttributesFluent fluent) { + + public V1ResourceAttributesBuilder( + io.kubernetes.client.openapi.models.V1ResourceAttributesFluent fluent) { this(fluent, false); } - public V1ResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1ResourceAttributesFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ResourceAttributesBuilder( + io.kubernetes.client.openapi.models.V1ResourceAttributesFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ResourceAttributes(), validationEnabled); } - public V1ResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1ResourceAttributesFluent fluent,io.kubernetes.client.openapi.models.V1ResourceAttributes instance) { + + public V1ResourceAttributesBuilder( + io.kubernetes.client.openapi.models.V1ResourceAttributesFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceAttributes instance) { this(fluent, instance, false); } - public V1ResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1ResourceAttributesFluent fluent,io.kubernetes.client.openapi.models.V1ResourceAttributes instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ResourceAttributesBuilder( + io.kubernetes.client.openapi.models.V1ResourceAttributesFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceAttributes instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withGroup(instance.getGroup()); fluent.withName(instance.getName()); @@ -35,13 +62,18 @@ public V1ResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1Resourc fluent.withVersion(instance.getVersion()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1ResourceAttributes instance) { - this(instance,false); + + public V1ResourceAttributesBuilder( + io.kubernetes.client.openapi.models.V1ResourceAttributes instance) { + this(instance, false); } - public V1ResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1ResourceAttributes instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ResourceAttributesBuilder( + io.kubernetes.client.openapi.models.V1ResourceAttributes instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withGroup(instance.getGroup()); this.withName(instance.getName()); @@ -56,10 +88,12 @@ public V1ResourceAttributesBuilder(io.kubernetes.client.openapi.models.V1Resourc this.withVersion(instance.getVersion()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ResourceAttributesFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ResourceAttributes build() { V1ResourceAttributes buildable = new V1ResourceAttributes(); buildable.setGroup(fluent.getGroup()); @@ -71,18 +105,23 @@ public io.kubernetes.client.openapi.models.V1ResourceAttributes build() { buildable.setVersion(fluent.getVersion()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ResourceAttributesBuilder that = (V1ResourceAttributesBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceAttributesFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceAttributesFluent.java index bead941ff0..61417ec90c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceAttributesFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceAttributesFluent.java @@ -1,77 +1,88 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ResourceAttributesFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ResourceAttributesFluent< + A extends io.kubernetes.client.openapi.models.V1ResourceAttributesFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getGroup(); + public A withGroup(java.lang.String group); + public java.lang.Boolean hasGroup(); - - /** - * Method is deprecated. use withGroup instead. - */ + + /** Method is deprecated. use withGroup instead. */ @java.lang.Deprecated public A withNewGroup(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getNamespace(); + public A withNamespace(java.lang.String namespace); + public java.lang.Boolean hasNamespace(); - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original); + public java.lang.String getResource(); + public A withResource(java.lang.String resource); + public java.lang.Boolean hasResource(); - - /** - * Method is deprecated. use withResource instead. - */ + + /** Method is deprecated. use withResource instead. */ @java.lang.Deprecated public A withNewResource(java.lang.String original); + public java.lang.String getSubresource(); + public A withSubresource(java.lang.String subresource); + public java.lang.Boolean hasSubresource(); - - /** - * Method is deprecated. use withSubresource instead. - */ + + /** Method is deprecated. use withSubresource instead. */ @java.lang.Deprecated public A withNewSubresource(java.lang.String original); + public java.lang.String getVerb(); + public A withVerb(java.lang.String verb); + public java.lang.Boolean hasVerb(); - - /** - * Method is deprecated. use withVerb instead. - */ + + /** Method is deprecated. use withVerb instead. */ @java.lang.Deprecated public A withNewVerb(java.lang.String original); + public java.lang.String getVersion(); + public A withVersion(java.lang.String version); + public java.lang.Boolean hasVersion(); - - /** - * Method is deprecated. use withVersion instead. - */ + + /** Method is deprecated. use withVersion instead. */ @java.lang.Deprecated public A withNewVersion(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceAttributesFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceAttributesFluentImpl.java index 48c204fffc..2c27a395d6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceAttributesFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceAttributesFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ResourceAttributesFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ResourceAttributesFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ResourceAttributesFluent { + public V1ResourceAttributesFluentImpl() {} - /** - * Generated - */ -public class V1ResourceAttributesFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ResourceAttributesFluent{ - public V1ResourceAttributesFluentImpl() { - } - public V1ResourceAttributesFluentImpl(io.kubernetes.client.openapi.models.V1ResourceAttributes instance) { + public V1ResourceAttributesFluentImpl( + io.kubernetes.client.openapi.models.V1ResourceAttributes instance) { this.withGroup(instance.getGroup()); this.withName(instance.getName()); @@ -26,8 +34,8 @@ public V1ResourceAttributesFluentImpl(io.kubernetes.client.openapi.models.V1Reso this.withVerb(instance.getVerb()); this.withVersion(instance.getVersion()); - } + private java.lang.String group; private java.lang.String name; private java.lang.String namespace; @@ -35,140 +43,158 @@ public V1ResourceAttributesFluentImpl(io.kubernetes.client.openapi.models.V1Reso private java.lang.String subresource; private java.lang.String verb; private java.lang.String version; + public java.lang.String getGroup() { return this.group; } + public A withGroup(java.lang.String group) { - this.group=group; return (A) this; + this.group = group; + return (A) this; } + public java.lang.Boolean hasGroup() { return this.group != null; } - - /** - * Method is deprecated. use withGroup instead. - */ + + /** Method is deprecated. use withGroup instead. */ @java.lang.Deprecated public A withNewGroup(java.lang.String original) { - return (A)withGroup(new String(original)); + return (A) withGroup(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getNamespace() { return this.namespace; } + public A withNamespace(java.lang.String namespace) { - this.namespace=namespace; return (A) this; + this.namespace = namespace; + return (A) this; } + public java.lang.Boolean hasNamespace() { return this.namespace != null; } - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original) { - return (A)withNamespace(new String(original)); + return (A) withNamespace(new String(original)); } + public java.lang.String getResource() { return this.resource; } + public A withResource(java.lang.String resource) { - this.resource=resource; return (A) this; + this.resource = resource; + return (A) this; } + public java.lang.Boolean hasResource() { return this.resource != null; } - - /** - * Method is deprecated. use withResource instead. - */ + + /** Method is deprecated. use withResource instead. */ @java.lang.Deprecated public A withNewResource(java.lang.String original) { - return (A)withResource(new String(original)); + return (A) withResource(new String(original)); } + public java.lang.String getSubresource() { return this.subresource; } + public A withSubresource(java.lang.String subresource) { - this.subresource=subresource; return (A) this; + this.subresource = subresource; + return (A) this; } + public java.lang.Boolean hasSubresource() { return this.subresource != null; } - - /** - * Method is deprecated. use withSubresource instead. - */ + + /** Method is deprecated. use withSubresource instead. */ @java.lang.Deprecated public A withNewSubresource(java.lang.String original) { - return (A)withSubresource(new String(original)); + return (A) withSubresource(new String(original)); } + public java.lang.String getVerb() { return this.verb; } + public A withVerb(java.lang.String verb) { - this.verb=verb; return (A) this; + this.verb = verb; + return (A) this; } + public java.lang.Boolean hasVerb() { return this.verb != null; } - - /** - * Method is deprecated. use withVerb instead. - */ + + /** Method is deprecated. use withVerb instead. */ @java.lang.Deprecated public A withNewVerb(java.lang.String original) { - return (A)withVerb(new String(original)); + return (A) withVerb(new String(original)); } + public java.lang.String getVersion() { return this.version; } + public A withVersion(java.lang.String version) { - this.version=version; return (A) this; + this.version = version; + return (A) this; } + public java.lang.Boolean hasVersion() { return this.version != null; } - - /** - * Method is deprecated. use withVersion instead. - */ + + /** Method is deprecated. use withVersion instead. */ @java.lang.Deprecated public A withNewVersion(java.lang.String original) { - return (A)withVersion(new String(original)); + return (A) withVersion(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ResourceAttributesFluentImpl that = (V1ResourceAttributesFluentImpl) o; - if (group != null ? !group.equals(that.group) :that.group != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (namespace != null ? !namespace.equals(that.namespace) :that.namespace != null) return false; - if (resource != null ? !resource.equals(that.resource) :that.resource != null) return false; - if (subresource != null ? !subresource.equals(that.subresource) :that.subresource != null) return false; - if (verb != null ? !verb.equals(that.verb) :that.verb != null) return false; - if (version != null ? !version.equals(that.version) :that.version != null) return false; + if (group != null ? !group.equals(that.group) : that.group != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (namespace != null ? !namespace.equals(that.namespace) : that.namespace != null) + return false; + if (resource != null ? !resource.equals(that.resource) : that.resource != null) return false; + if (subresource != null ? !subresource.equals(that.subresource) : that.subresource != null) + return false; + if (verb != null ? !verb.equals(that.verb) : that.verb != null) return false; + if (version != null ? !version.equals(that.version) : that.version != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(group, name, namespace, resource, subresource, verb, version, super.hashCode()); + return java.util.Objects.hash( + group, name, namespace, resource, subresource, verb, version, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceFieldSelectorBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceFieldSelectorBuilder.java index b4e3f869ba..c72c815d67 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceFieldSelectorBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceFieldSelectorBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ResourceFieldSelectorBuilder extends io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ResourceFieldSelectorBuilder + extends io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ResourceFieldSelector, + io.kubernetes.client.openapi.models.V1ResourceFieldSelectorBuilder> { public V1ResourceFieldSelectorBuilder() { this(false); } + public V1ResourceFieldSelectorBuilder(java.lang.Boolean validationEnabled) { this(new V1ResourceFieldSelector(), validationEnabled); } - public V1ResourceFieldSelectorBuilder(io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent fluent) { + + public V1ResourceFieldSelectorBuilder( + io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent fluent) { this(fluent, false); } - public V1ResourceFieldSelectorBuilder(io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ResourceFieldSelectorBuilder( + io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ResourceFieldSelector(), validationEnabled); } - public V1ResourceFieldSelectorBuilder(io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent fluent,io.kubernetes.client.openapi.models.V1ResourceFieldSelector instance) { + + public V1ResourceFieldSelectorBuilder( + io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceFieldSelector instance) { this(fluent, instance, false); } - public V1ResourceFieldSelectorBuilder(io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent fluent,io.kubernetes.client.openapi.models.V1ResourceFieldSelector instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ResourceFieldSelectorBuilder( + io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceFieldSelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainerName(instance.getContainerName()); fluent.withDivisor(instance.getDivisor()); fluent.withResource(instance.getResource()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ResourceFieldSelectorBuilder(io.kubernetes.client.openapi.models.V1ResourceFieldSelector instance) { - this(instance,false); + + public V1ResourceFieldSelectorBuilder( + io.kubernetes.client.openapi.models.V1ResourceFieldSelector instance) { + this(instance, false); } - public V1ResourceFieldSelectorBuilder(io.kubernetes.client.openapi.models.V1ResourceFieldSelector instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ResourceFieldSelectorBuilder( + io.kubernetes.client.openapi.models.V1ResourceFieldSelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainerName(instance.getContainerName()); this.withDivisor(instance.getDivisor()); this.withResource(instance.getResource()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ResourceFieldSelector build() { V1ResourceFieldSelector buildable = new V1ResourceFieldSelector(); buildable.setContainerName(fluent.getContainerName()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1ResourceFieldSelector build() { buildable.setResource(fluent.getResource()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ResourceFieldSelectorBuilder that = (V1ResourceFieldSelectorBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceFieldSelectorFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceFieldSelectorFluent.java index 1203b087c0..8f536b6a41 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceFieldSelectorFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceFieldSelectorFluent.java @@ -1,37 +1,46 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ResourceFieldSelectorFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ResourceFieldSelectorFluent< + A extends io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getContainerName(); + public A withContainerName(java.lang.String containerName); + public java.lang.Boolean hasContainerName(); - - /** - * Method is deprecated. use withContainerName instead. - */ + + /** Method is deprecated. use withContainerName instead. */ @java.lang.Deprecated public A withNewContainerName(java.lang.String original); + public io.kubernetes.client.custom.Quantity getDivisor(); + public A withDivisor(io.kubernetes.client.custom.Quantity divisor); + public java.lang.Boolean hasDivisor(); + public A withNewDivisor(java.lang.String value); + public java.lang.String getResource(); + public A withResource(java.lang.String resource); + public java.lang.Boolean hasResource(); - - /** - * Method is deprecated. use withResource instead. - */ + + /** Method is deprecated. use withResource instead. */ @java.lang.Deprecated public A withNewResource(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceFieldSelectorFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceFieldSelectorFluentImpl.java index 1d1eb2a3f7..d40dfc1bf9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceFieldSelectorFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceFieldSelectorFluentImpl.java @@ -1,86 +1,107 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1ResourceFieldSelectorFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent{ - public V1ResourceFieldSelectorFluentImpl() { - } - public V1ResourceFieldSelectorFluentImpl(io.kubernetes.client.openapi.models.V1ResourceFieldSelector instance) { + +/** Generated */ +public class V1ResourceFieldSelectorFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ResourceFieldSelectorFluent { + public V1ResourceFieldSelectorFluentImpl() {} + + public V1ResourceFieldSelectorFluentImpl( + io.kubernetes.client.openapi.models.V1ResourceFieldSelector instance) { this.withContainerName(instance.getContainerName()); this.withDivisor(instance.getDivisor()); this.withResource(instance.getResource()); - } + private java.lang.String containerName; private io.kubernetes.client.custom.Quantity divisor; private java.lang.String resource; + public java.lang.String getContainerName() { return this.containerName; } + public A withContainerName(java.lang.String containerName) { - this.containerName=containerName; return (A) this; + this.containerName = containerName; + return (A) this; } + public java.lang.Boolean hasContainerName() { return this.containerName != null; } - - /** - * Method is deprecated. use withContainerName instead. - */ + + /** Method is deprecated. use withContainerName instead. */ @java.lang.Deprecated public A withNewContainerName(java.lang.String original) { - return (A)withContainerName(new String(original)); + return (A) withContainerName(new String(original)); } + public io.kubernetes.client.custom.Quantity getDivisor() { return this.divisor; } + public A withDivisor(io.kubernetes.client.custom.Quantity divisor) { - this.divisor=divisor; return (A) this; + this.divisor = divisor; + return (A) this; } + public java.lang.Boolean hasDivisor() { return this.divisor != null; } + public A withNewDivisor(java.lang.String value) { - return (A)withDivisor(new Quantity(value)); + return (A) withDivisor(new Quantity(value)); } + public java.lang.String getResource() { return this.resource; } + public A withResource(java.lang.String resource) { - this.resource=resource; return (A) this; + this.resource = resource; + return (A) this; } + public java.lang.Boolean hasResource() { return this.resource != null; } - - /** - * Method is deprecated. use withResource instead. - */ + + /** Method is deprecated. use withResource instead. */ @java.lang.Deprecated public A withNewResource(java.lang.String original) { - return (A)withResource(new String(original)); + return (A) withResource(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ResourceFieldSelectorFluentImpl that = (V1ResourceFieldSelectorFluentImpl) o; - if (containerName != null ? !containerName.equals(that.containerName) :that.containerName != null) return false; - if (divisor != null ? !divisor.equals(that.divisor) :that.divisor != null) return false; - if (resource != null ? !resource.equals(that.resource) :that.resource != null) return false; + if (containerName != null + ? !containerName.equals(that.containerName) + : that.containerName != null) return false; + if (divisor != null ? !divisor.equals(that.divisor) : that.divisor != null) return false; + if (resource != null ? !resource.equals(that.resource) : that.resource != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(containerName, divisor, resource, super.hashCode()); + return java.util.Objects.hash(containerName, divisor, resource, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaBuilder.java index 65e2cac393..175d3d6e27 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ResourceQuotaBuilder extends io.kubernetes.client.openapi.models.V1ResourceQuotaFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ResourceQuotaBuilder + extends io.kubernetes.client.openapi.models.V1ResourceQuotaFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ResourceQuota, + io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder> { public V1ResourceQuotaBuilder() { this(false); } + public V1ResourceQuotaBuilder(java.lang.Boolean validationEnabled) { this(new V1ResourceQuota(), validationEnabled); } - public V1ResourceQuotaBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaFluent fluent) { + + public V1ResourceQuotaBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaFluent fluent) { this(fluent, false); } - public V1ResourceQuotaBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ResourceQuotaBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ResourceQuota(), validationEnabled); } - public V1ResourceQuotaBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaFluent fluent,io.kubernetes.client.openapi.models.V1ResourceQuota instance) { + + public V1ResourceQuotaBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceQuota instance) { this(fluent, instance, false); } - public V1ResourceQuotaBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaFluent fluent,io.kubernetes.client.openapi.models.V1ResourceQuota instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ResourceQuotaBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceQuota instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,17 @@ public V1ResourceQuotaBuilder(io.kubernetes.client.openapi.models.V1ResourceQuot fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ResourceQuotaBuilder(io.kubernetes.client.openapi.models.V1ResourceQuota instance) { - this(instance,false); + this(instance, false); } - public V1ResourceQuotaBuilder(io.kubernetes.client.openapi.models.V1ResourceQuota instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ResourceQuotaBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuota instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +79,12 @@ public V1ResourceQuotaBuilder(io.kubernetes.client.openapi.models.V1ResourceQuot this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ResourceQuotaFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ResourceQuota build() { V1ResourceQuota buildable = new V1ResourceQuota(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +94,23 @@ public io.kubernetes.client.openapi.models.V1ResourceQuota build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ResourceQuotaBuilder that = (V1ResourceQuotaBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaFluent.java index 1c2416cd49..4cc1b77a10 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaFluent.java @@ -1,93 +1,146 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ResourceQuotaFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ResourceQuotaFluent< + A extends io.kubernetes.client.openapi.models.V1ResourceQuotaFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceQuotaSpec getSpec(); + public io.kubernetes.client.openapi.models.V1ResourceQuotaSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1ResourceQuotaSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1ResourceQuotaSpec item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1ResourceQuotaSpec item); + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1ResourceQuotaSpec item); - + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1ResourceQuotaSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceQuotaStatus getStatus(); + public io.kubernetes.client.openapi.models.V1ResourceQuotaStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus item); + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent< + io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent< + io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaFluentImpl.java index a165b6b618..468eb2db4f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1ResourceQuotaFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ResourceQuotaFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ResourceQuotaFluent { + public V1ResourceQuotaFluentImpl() {} - /** - * Generated - */ -public class V1ResourceQuotaFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ResourceQuotaFluent{ - public V1ResourceQuotaFluentImpl() { - } public V1ResourceQuotaFluentImpl(io.kubernetes.client.openapi.models.V1ResourceQuota instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +29,300 @@ public V1ResourceQuotaFluentImpl(io.kubernetes.client.openapi.models.V1ResourceQ this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1ResourceQuotaSpecBuilder spec; private io.kubernetes.client.openapi.models.V1ResourceQuotaStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1ResourceQuotaFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1ResourceQuotaFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1ResourceQuotaFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceQuotaSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1ResourceQuotaSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1ResourceQuotaSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1ResourceQuotaSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1ResourceQuotaSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1ResourceQuotaFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1ResourceQuotaSpec item) { + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1ResourceQuotaSpec item) { return new io.kubernetes.client.openapi.models.V1ResourceQuotaFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1ResourceQuotaSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1ResourceQuotaSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1ResourceQuotaSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1ResourceQuotaSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceQuotaStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1ResourceQuotaStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1ResourceQuotaStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1ResourceQuotaStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1ResourceQuotaFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus item) { + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus item) { return new io.kubernetes.client.openapi.models.V1ResourceQuotaFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1ResourceQuotaStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1ResourceQuotaStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ResourceQuotaFluentImpl that = (V1ResourceQuotaFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1ResourceQuotaFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1ResourceQuotaSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1ResourceQuotaSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ResourceQuotaSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1ResourceQuotaSpecBuilder builder; + public N and() { return (N) V1ResourceQuotaFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1ResourceQuotaFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1ResourceQuotaStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ResourceQuotaStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ResourceQuotaStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1ResourceQuotaStatusBuilder builder; + public N and() { return (N) V1ResourceQuotaFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaListBuilder.java index 3f1e050104..2da3769fec 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ResourceQuotaListBuilder extends io.kubernetes.client.openapi.models.V1ResourceQuotaListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ResourceQuotaListBuilder + extends io.kubernetes.client.openapi.models.V1ResourceQuotaListFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceQuotaListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ResourceQuotaList, + io.kubernetes.client.openapi.models.V1ResourceQuotaListBuilder> { public V1ResourceQuotaListBuilder() { this(false); } + public V1ResourceQuotaListBuilder(java.lang.Boolean validationEnabled) { this(new V1ResourceQuotaList(), validationEnabled); } - public V1ResourceQuotaListBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent fluent) { + + public V1ResourceQuotaListBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent fluent) { this(fluent, false); } - public V1ResourceQuotaListBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ResourceQuotaListBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ResourceQuotaList(), validationEnabled); } - public V1ResourceQuotaListBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent fluent,io.kubernetes.client.openapi.models.V1ResourceQuotaList instance) { + + public V1ResourceQuotaListBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceQuotaList instance) { this(fluent, instance, false); } - public V1ResourceQuotaListBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent fluent,io.kubernetes.client.openapi.models.V1ResourceQuotaList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ResourceQuotaListBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceQuotaList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1ResourceQuotaListBuilder(io.kubernetes.client.openapi.models.V1Resource fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ResourceQuotaListBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaList instance) { - this(instance,false); + + public V1ResourceQuotaListBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaList instance) { + this(instance, false); } - public V1ResourceQuotaListBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ResourceQuotaListBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1ResourceQuotaListBuilder(io.kubernetes.client.openapi.models.V1Resource this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ResourceQuotaList build() { V1ResourceQuotaList buildable = new V1ResourceQuotaList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1ResourceQuotaList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ResourceQuotaListBuilder that = (V1ResourceQuotaListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaListFluent.java index a487144a24..07f0c34f42 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaListFluent.java @@ -1,95 +1,158 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ResourceQuotaListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ResourceQuotaListFluent< + A extends io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ResourceQuota item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ResourceQuota item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceQuota item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceQuota item); + public A addToItems(io.kubernetes.client.openapi.models.V1ResourceQuota... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1ResourceQuota... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1ResourceQuota buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ResourceQuota buildFirstItem(); + public io.kubernetes.client.openapi.models.V1ResourceQuota buildLastItem(); - public io.kubernetes.client.openapi.models.V1ResourceQuota buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ResourceQuota buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1ResourceQuota... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ResourceQuota item); - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ResourceQuota item); - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1ResourceQuota item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceQuota item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ResourceQuotaFluent>{ + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ResourceQuotaFluent< + io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaListFluentImpl.java index 90fbbf0b83..480b82e297 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1ResourceQuotaListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent{ - public V1ResourceQuotaListFluentImpl() { - } - public V1ResourceQuotaListFluentImpl(io.kubernetes.client.openapi.models.V1ResourceQuotaList instance) { + +/** Generated */ +public class V1ResourceQuotaListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent { + public V1ResourceQuotaListFluentImpl() {} + + public V1ResourceQuotaListFluentImpl( + io.kubernetes.client.openapi.models.V1ResourceQuotaList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1ResourceQuotaListFluentImpl(io.kubernetes.client.openapi.models.V1Resou this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ResourceQuota item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder = new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceQuota item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder = + new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ResourceQuota item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder = new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceQuota item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder = + new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1ResourceQuota... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ResourceQuota item : items) {io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder = new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ResourceQuota item : items) { + io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder = + new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ResourceQuota item : items) {io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder = new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ResourceQuota item : items) { + io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder = + new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1ResourceQuota... items) { - for (io.kubernetes.client.openapi.models.V1ResourceQuota item : items) {io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder = new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ResourceQuota item : items) { + io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder = + new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ResourceQuota item : items) {io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder = new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ResourceQuota item : items) { + io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder = + new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder = each.next(); @@ -87,174 +159,280 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1ResourceQuota buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ResourceQuota buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ResourceQuota buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ResourceQuota buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ResourceQuota buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ResourceQuota item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ResourceQuota item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1ResourceQuota... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1ResourceQuota item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1ResourceQuota item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1ResourceQuotaListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ResourceQuota item) { - return new io.kubernetes.client.openapi.models.V1ResourceQuotaListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1ResourceQuota item) { + return new io.kubernetes.client.openapi.models.V1ResourceQuotaListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ResourceQuota item) { - return new io.kubernetes.client.openapi.models.V1ResourceQuotaListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceQuota item) { + return new io.kubernetes.client.openapi.models.V1ResourceQuotaListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1ResourceQuotaListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1ResourceQuotaListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1ResourceQuotaListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1ResourceQuotaListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ResourceQuotaListFluentImpl that = (V1ResourceQuotaListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1ResourceQuotaFluentImpl> implements io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ResourceQuota item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1ResourceQuotaFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceQuota item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder(this); } + io.kubernetes.client.openapi.models.V1ResourceQuotaBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ResourceQuotaListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1ResourceQuotaListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ResourceQuotaListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1ResourceQuotaListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaSpecBuilder.java index 9d5587092f..583942b731 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaSpecBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ResourceQuotaSpecBuilder extends io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ResourceQuotaSpecBuilder + extends io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceQuotaSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ResourceQuotaSpec, + io.kubernetes.client.openapi.models.V1ResourceQuotaSpecBuilder> { public V1ResourceQuotaSpecBuilder() { this(false); } + public V1ResourceQuotaSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1ResourceQuotaSpec(), validationEnabled); } - public V1ResourceQuotaSpecBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent fluent) { + + public V1ResourceQuotaSpecBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent fluent) { this(fluent, false); } - public V1ResourceQuotaSpecBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ResourceQuotaSpecBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ResourceQuotaSpec(), validationEnabled); } - public V1ResourceQuotaSpecBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent fluent,io.kubernetes.client.openapi.models.V1ResourceQuotaSpec instance) { + + public V1ResourceQuotaSpecBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceQuotaSpec instance) { this(fluent, instance, false); } - public V1ResourceQuotaSpecBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent fluent,io.kubernetes.client.openapi.models.V1ResourceQuotaSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ResourceQuotaSpecBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceQuotaSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withHard(instance.getHard()); fluent.withScopeSelector(instance.getScopeSelector()); fluent.withScopes(instance.getScopes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ResourceQuotaSpecBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaSpec instance) { - this(instance,false); + + public V1ResourceQuotaSpecBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaSpec instance) { + this(instance, false); } - public V1ResourceQuotaSpecBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ResourceQuotaSpecBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withHard(instance.getHard()); this.withScopeSelector(instance.getScopeSelector()); this.withScopes(instance.getScopes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ResourceQuotaSpec build() { V1ResourceQuotaSpec buildable = new V1ResourceQuotaSpec(); buildable.setHard(fluent.getHard()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1ResourceQuotaSpec build() { buildable.setScopes(fluent.getScopes()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ResourceQuotaSpecBuilder that = (V1ResourceQuotaSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaSpecFluent.java index aab930a952..a20d0ef434 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaSpecFluent.java @@ -1,66 +1,107 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1ResourceQuotaSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToHard(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToHard(java.util.Map map); +/** Generated */ +public interface V1ResourceQuotaSpecFluent< + A extends io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToHard(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToHard(java.util.Map map); + public A removeFromHard(java.lang.String key); - public A removeFromHard(java.util.Map map); - public java.util.Map getHard(); - public A withHard(java.util.Map hard); + + public A removeFromHard( + java.util.Map map); + + public java.util.Map getHard(); + + public A withHard( + java.util.Map hard); + public java.lang.Boolean hasHard(); - + /** * This method has been deprecated, please use method buildScopeSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ScopeSelector getScopeSelector(); + public io.kubernetes.client.openapi.models.V1ScopeSelector buildScopeSelector(); + public A withScopeSelector(io.kubernetes.client.openapi.models.V1ScopeSelector scopeSelector); + public java.lang.Boolean hasScopeSelector(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested withNewScopeSelector(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested withNewScopeSelectorLike(io.kubernetes.client.openapi.models.V1ScopeSelector item); - public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested editScopeSelector(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested editOrNewScopeSelector(); - public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested editOrNewScopeSelectorLike(io.kubernetes.client.openapi.models.V1ScopeSelector item); - public A addToScopes(java.lang.Integer index,java.lang.String item); - public A setToScopes(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested + withNewScopeSelector(); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested + withNewScopeSelectorLike(io.kubernetes.client.openapi.models.V1ScopeSelector item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested + editScopeSelector(); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested + editOrNewScopeSelector(); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested + editOrNewScopeSelectorLike(io.kubernetes.client.openapi.models.V1ScopeSelector item); + + public A addToScopes(java.lang.Integer index, java.lang.String item); + + public A setToScopes(java.lang.Integer index, java.lang.String item); + public A addToScopes(java.lang.String... items); + public A addAllToScopes(java.util.Collection items); + public A removeFromScopes(java.lang.String... items); + public A removeAllFromScopes(java.util.Collection items); + public java.util.List getScopes(); + public java.lang.String getScope(java.lang.Integer index); + public java.lang.String getFirstScope(); + public java.lang.String getLastScope(); - public java.lang.String getMatchingScope(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingScope(java.util.function.Predicate predicate); + + public java.lang.String getMatchingScope( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingScope( + java.util.function.Predicate predicate); + public A withScopes(java.util.List scopes); + public A withScopes(java.lang.String... scopes); + public java.lang.Boolean hasScopes(); + public A addNewScope(java.lang.String original); - public interface ScopeSelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ScopeSelectorFluent>{ + + public interface ScopeSelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ScopeSelectorFluent< + io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested< + N>> { public N and(); + public N endScopeSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaSpecFluentImpl.java index 31da746a25..e121276814 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaSpecFluentImpl.java @@ -1,177 +1,318 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public class V1ResourceQuotaSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent{ - public V1ResourceQuotaSpecFluentImpl() { - } - public V1ResourceQuotaSpecFluentImpl(io.kubernetes.client.openapi.models.V1ResourceQuotaSpec instance) { +/** Generated */ +public class V1ResourceQuotaSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent { + public V1ResourceQuotaSpecFluentImpl() {} + + public V1ResourceQuotaSpecFluentImpl( + io.kubernetes.client.openapi.models.V1ResourceQuotaSpec instance) { this.withHard(instance.getHard()); this.withScopeSelector(instance.getScopeSelector()); this.withScopes(instance.getScopes()); - } - private java.util.Map hard; + + private java.util.Map hard; private io.kubernetes.client.openapi.models.V1ScopeSelectorBuilder scopeSelector; private java.util.List scopes; - public A addToHard(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.hard == null && key != null && value != null) { this.hard = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.hard.put(key, value);} return (A)this; + + public A addToHard(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.hard == null && key != null && value != null) { + this.hard = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.hard.put(key, value); + } + return (A) this; } - public A addToHard(java.util.Map map) { - if(this.hard == null && map != null) { this.hard = new java.util.LinkedHashMap(); } - if(map != null) { this.hard.putAll(map);} return (A)this; + + public A addToHard(java.util.Map map) { + if (this.hard == null && map != null) { + this.hard = new java.util.LinkedHashMap(); + } + if (map != null) { + this.hard.putAll(map); + } + return (A) this; } + public A removeFromHard(java.lang.String key) { - if(this.hard == null) { return (A) this; } - if(key != null && this.hard != null) {this.hard.remove(key);} return (A)this; + if (this.hard == null) { + return (A) this; + } + if (key != null && this.hard != null) { + this.hard.remove(key); + } + return (A) this; } - public A removeFromHard(java.util.Map map) { - if(this.hard == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.hard != null){this.hard.remove(key);}}} return (A)this; + + public A removeFromHard( + java.util.Map map) { + if (this.hard == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.hard != null) { + this.hard.remove(key); + } + } + } + return (A) this; } - public java.util.Map getHard() { + + public java.util.Map getHard() { return this.hard; } - public A withHard(java.util.Map hard) { - if (hard == null) { this.hard = null;} else {this.hard = new java.util.LinkedHashMap(hard);} return (A) this; + + public A withHard( + java.util.Map hard) { + if (hard == null) { + this.hard = null; + } else { + this.hard = new java.util.LinkedHashMap(hard); + } + return (A) this; } + public java.lang.Boolean hasHard() { return this.hard != null; } - + /** * This method has been deprecated, please use method buildScopeSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ScopeSelector getScopeSelector() { - return this.scopeSelector!=null ?this.scopeSelector.build():null; + return this.scopeSelector != null ? this.scopeSelector.build() : null; } + public io.kubernetes.client.openapi.models.V1ScopeSelector buildScopeSelector() { - return this.scopeSelector!=null ?this.scopeSelector.build():null; + return this.scopeSelector != null ? this.scopeSelector.build() : null; } + public A withScopeSelector(io.kubernetes.client.openapi.models.V1ScopeSelector scopeSelector) { _visitables.get("scopeSelector").remove(this.scopeSelector); - if (scopeSelector!=null){ this.scopeSelector= new io.kubernetes.client.openapi.models.V1ScopeSelectorBuilder(scopeSelector); _visitables.get("scopeSelector").add(this.scopeSelector);} return (A) this; + if (scopeSelector != null) { + this.scopeSelector = + new io.kubernetes.client.openapi.models.V1ScopeSelectorBuilder(scopeSelector); + _visitables.get("scopeSelector").add(this.scopeSelector); + } + return (A) this; } + public java.lang.Boolean hasScopeSelector() { return this.scopeSelector != null; } - public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested withNewScopeSelector() { - return new io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluentImpl.ScopeSelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested + withNewScopeSelector() { + return new io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluentImpl + .ScopeSelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested withNewScopeSelectorLike(io.kubernetes.client.openapi.models.V1ScopeSelector item) { - return new io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluentImpl.ScopeSelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested + withNewScopeSelectorLike(io.kubernetes.client.openapi.models.V1ScopeSelector item) { + return new io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluentImpl + .ScopeSelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested editScopeSelector() { + + public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested + editScopeSelector() { return withNewScopeSelectorLike(getScopeSelector()); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested editOrNewScopeSelector() { - return withNewScopeSelectorLike(getScopeSelector() != null ? getScopeSelector(): new io.kubernetes.client.openapi.models.V1ScopeSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested + editOrNewScopeSelector() { + return withNewScopeSelectorLike( + getScopeSelector() != null + ? getScopeSelector() + : new io.kubernetes.client.openapi.models.V1ScopeSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested editOrNewScopeSelectorLike(io.kubernetes.client.openapi.models.V1ScopeSelector item) { - return withNewScopeSelectorLike(getScopeSelector() != null ? getScopeSelector(): item); + + public io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested + editOrNewScopeSelectorLike(io.kubernetes.client.openapi.models.V1ScopeSelector item) { + return withNewScopeSelectorLike(getScopeSelector() != null ? getScopeSelector() : item); } - public A addToScopes(java.lang.Integer index,java.lang.String item) { - if (this.scopes == null) {this.scopes = new java.util.ArrayList();} + + public A addToScopes(java.lang.Integer index, java.lang.String item) { + if (this.scopes == null) { + this.scopes = new java.util.ArrayList(); + } this.scopes.add(index, item); - return (A)this; + return (A) this; } - public A setToScopes(java.lang.Integer index,java.lang.String item) { - if (this.scopes == null) {this.scopes = new java.util.ArrayList();} - this.scopes.set(index, item); return (A)this; + + public A setToScopes(java.lang.Integer index, java.lang.String item) { + if (this.scopes == null) { + this.scopes = new java.util.ArrayList(); + } + this.scopes.set(index, item); + return (A) this; } + public A addToScopes(java.lang.String... items) { - if (this.scopes == null) {this.scopes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.scopes.add(item);} return (A)this; + if (this.scopes == null) { + this.scopes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.scopes.add(item); + } + return (A) this; } + public A addAllToScopes(java.util.Collection items) { - if (this.scopes == null) {this.scopes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.scopes.add(item);} return (A)this; + if (this.scopes == null) { + this.scopes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.scopes.add(item); + } + return (A) this; } + public A removeFromScopes(java.lang.String... items) { - for (java.lang.String item : items) {if (this.scopes!= null){ this.scopes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.scopes != null) { + this.scopes.remove(item); + } + } + return (A) this; } + public A removeAllFromScopes(java.util.Collection items) { - for (java.lang.String item : items) {if (this.scopes!= null){ this.scopes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.scopes != null) { + this.scopes.remove(item); + } + } + return (A) this; } + public java.util.List getScopes() { return this.scopes; } + public java.lang.String getScope(java.lang.Integer index) { return this.scopes.get(index); } + public java.lang.String getFirstScope() { return this.scopes.get(0); } + public java.lang.String getLastScope() { return this.scopes.get(scopes.size() - 1); } - public java.lang.String getMatchingScope(java.util.function.Predicate predicate) { - for (java.lang.String item: scopes) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingScope( + java.util.function.Predicate predicate) { + for (java.lang.String item : scopes) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingScope(java.util.function.Predicate predicate) { - for (java.lang.String item: scopes) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingScope( + java.util.function.Predicate predicate) { + for (java.lang.String item : scopes) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withScopes(java.util.List scopes) { - if (scopes != null) {this.scopes = new java.util.ArrayList(); for (java.lang.String item : scopes){this.addToScopes(item);}} else { this.scopes = null;} return (A) this; + if (scopes != null) { + this.scopes = new java.util.ArrayList(); + for (java.lang.String item : scopes) { + this.addToScopes(item); + } + } else { + this.scopes = null; + } + return (A) this; } + public A withScopes(java.lang.String... scopes) { - if (this.scopes != null) {this.scopes.clear();} - if (scopes != null) {for (java.lang.String item :scopes){ this.addToScopes(item);}} return (A) this; + if (this.scopes != null) { + this.scopes.clear(); + } + if (scopes != null) { + for (java.lang.String item : scopes) { + this.addToScopes(item); + } + } + return (A) this; } + public java.lang.Boolean hasScopes() { return scopes != null && !scopes.isEmpty(); } + public A addNewScope(java.lang.String original) { - return (A)addToScopes(new String(original)); + return (A) addToScopes(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ResourceQuotaSpecFluentImpl that = (V1ResourceQuotaSpecFluentImpl) o; - if (hard != null ? !hard.equals(that.hard) :that.hard != null) return false; - if (scopeSelector != null ? !scopeSelector.equals(that.scopeSelector) :that.scopeSelector != null) return false; - if (scopes != null ? !scopes.equals(that.scopes) :that.scopes != null) return false; + if (hard != null ? !hard.equals(that.hard) : that.hard != null) return false; + if (scopeSelector != null + ? !scopeSelector.equals(that.scopeSelector) + : that.scopeSelector != null) return false; + if (scopes != null ? !scopes.equals(that.scopes) : that.scopes != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(hard, scopeSelector, scopes, super.hashCode()); + return java.util.Objects.hash(hard, scopeSelector, scopes, super.hashCode()); } - public class ScopeSelectorNestedImpl extends io.kubernetes.client.openapi.models.V1ScopeSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested,io.kubernetes.client.fluent.Nested{ + + public class ScopeSelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1ScopeSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested> + implements io.kubernetes.client.openapi.models.V1ResourceQuotaSpecFluent.ScopeSelectorNested< + N>, + io.kubernetes.client.fluent.Nested { ScopeSelectorNestedImpl(io.kubernetes.client.openapi.models.V1ScopeSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1ScopeSelectorBuilder(this, item); } + ScopeSelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ScopeSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1ScopeSelectorBuilder builder; + public N and() { return (N) V1ResourceQuotaSpecFluentImpl.this.withScopeSelector(builder.build()); } + public N endScopeSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaStatusBuilder.java index a61eeb9b32..2869233b27 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaStatusBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ResourceQuotaStatusBuilder extends io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ResourceQuotaStatusBuilder + extends io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceQuotaStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ResourceQuotaStatus, + io.kubernetes.client.openapi.models.V1ResourceQuotaStatusBuilder> { public V1ResourceQuotaStatusBuilder() { this(false); } + public V1ResourceQuotaStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1ResourceQuotaStatus(), validationEnabled); } - public V1ResourceQuotaStatusBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent fluent) { + + public V1ResourceQuotaStatusBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent fluent) { this(fluent, false); } - public V1ResourceQuotaStatusBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ResourceQuotaStatusBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ResourceQuotaStatus(), validationEnabled); } - public V1ResourceQuotaStatusBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent fluent,io.kubernetes.client.openapi.models.V1ResourceQuotaStatus instance) { + + public V1ResourceQuotaStatusBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceQuotaStatus instance) { this(fluent, instance, false); } - public V1ResourceQuotaStatusBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent fluent,io.kubernetes.client.openapi.models.V1ResourceQuotaStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ResourceQuotaStatusBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceQuotaStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withHard(instance.getHard()); fluent.withUsed(instance.getUsed()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ResourceQuotaStatusBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus instance) { - this(instance,false); + + public V1ResourceQuotaStatusBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaStatus instance) { + this(instance, false); } - public V1ResourceQuotaStatusBuilder(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ResourceQuotaStatusBuilder( + io.kubernetes.client.openapi.models.V1ResourceQuotaStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withHard(instance.getHard()); this.withUsed(instance.getUsed()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ResourceQuotaStatus build() { V1ResourceQuotaStatus buildable = new V1ResourceQuotaStatus(); buildable.setHard(fluent.getHard()); buildable.setUsed(fluent.getUsed()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ResourceQuotaStatusBuilder that = (V1ResourceQuotaStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaStatusFluent.java index 2d7ebcf92e..fc79744624 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaStatusFluent.java @@ -1,30 +1,50 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; -import java.util.Map; -import java.util.LinkedHashMap; - - /** - * Generated - */ -public interface V1ResourceQuotaStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToHard(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToHard(java.util.Map map); +/** Generated */ +public interface V1ResourceQuotaStatusFluent< + A extends io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToHard(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToHard(java.util.Map map); + public A removeFromHard(java.lang.String key); - public A removeFromHard(java.util.Map map); - public java.util.Map getHard(); - public A withHard(java.util.Map hard); + + public A removeFromHard( + java.util.Map map); + + public java.util.Map getHard(); + + public A withHard( + java.util.Map hard); + public java.lang.Boolean hasHard(); - public A addToUsed(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToUsed(java.util.Map map); + + public A addToUsed(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToUsed(java.util.Map map); + public A removeFromUsed(java.lang.String key); - public A removeFromUsed(java.util.Map map); - public java.util.Map getUsed(); - public A withUsed(java.util.Map used); + + public A removeFromUsed( + java.util.Map map); + + public java.util.Map getUsed(); + + public A withUsed( + java.util.Map used); + public java.lang.Boolean hasUsed(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaStatusFluentImpl.java index 03b37ab6e5..2a77581088 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceQuotaStatusFluentImpl.java @@ -1,87 +1,170 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.BaseFluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; -import java.util.Map; -import java.util.LinkedHashMap; - - /** - * Generated - */ -public class V1ResourceQuotaStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent{ - public V1ResourceQuotaStatusFluentImpl() { - } - public V1ResourceQuotaStatusFluentImpl(io.kubernetes.client.openapi.models.V1ResourceQuotaStatus instance) { +/** Generated */ +public class V1ResourceQuotaStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ResourceQuotaStatusFluent { + public V1ResourceQuotaStatusFluentImpl() {} + + public V1ResourceQuotaStatusFluentImpl( + io.kubernetes.client.openapi.models.V1ResourceQuotaStatus instance) { this.withHard(instance.getHard()); this.withUsed(instance.getUsed()); - } - private java.util.Map hard; - private java.util.Map used; - public A addToHard(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.hard == null && key != null && value != null) { this.hard = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.hard.put(key, value);} return (A)this; + + private java.util.Map hard; + private java.util.Map used; + + public A addToHard(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.hard == null && key != null && value != null) { + this.hard = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.hard.put(key, value); + } + return (A) this; } - public A addToHard(java.util.Map map) { - if(this.hard == null && map != null) { this.hard = new java.util.LinkedHashMap(); } - if(map != null) { this.hard.putAll(map);} return (A)this; + + public A addToHard(java.util.Map map) { + if (this.hard == null && map != null) { + this.hard = new java.util.LinkedHashMap(); + } + if (map != null) { + this.hard.putAll(map); + } + return (A) this; } + public A removeFromHard(java.lang.String key) { - if(this.hard == null) { return (A) this; } - if(key != null && this.hard != null) {this.hard.remove(key);} return (A)this; + if (this.hard == null) { + return (A) this; + } + if (key != null && this.hard != null) { + this.hard.remove(key); + } + return (A) this; } - public A removeFromHard(java.util.Map map) { - if(this.hard == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.hard != null){this.hard.remove(key);}}} return (A)this; + + public A removeFromHard( + java.util.Map map) { + if (this.hard == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.hard != null) { + this.hard.remove(key); + } + } + } + return (A) this; } - public java.util.Map getHard() { + + public java.util.Map getHard() { return this.hard; } - public A withHard(java.util.Map hard) { - if (hard == null) { this.hard = null;} else {this.hard = new java.util.LinkedHashMap(hard);} return (A) this; + + public A withHard( + java.util.Map hard) { + if (hard == null) { + this.hard = null; + } else { + this.hard = new java.util.LinkedHashMap(hard); + } + return (A) this; } + public java.lang.Boolean hasHard() { return this.hard != null; } - public A addToUsed(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.used == null && key != null && value != null) { this.used = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.used.put(key, value);} return (A)this; + + public A addToUsed(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.used == null && key != null && value != null) { + this.used = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.used.put(key, value); + } + return (A) this; } - public A addToUsed(java.util.Map map) { - if(this.used == null && map != null) { this.used = new java.util.LinkedHashMap(); } - if(map != null) { this.used.putAll(map);} return (A)this; + + public A addToUsed(java.util.Map map) { + if (this.used == null && map != null) { + this.used = new java.util.LinkedHashMap(); + } + if (map != null) { + this.used.putAll(map); + } + return (A) this; } + public A removeFromUsed(java.lang.String key) { - if(this.used == null) { return (A) this; } - if(key != null && this.used != null) {this.used.remove(key);} return (A)this; + if (this.used == null) { + return (A) this; + } + if (key != null && this.used != null) { + this.used.remove(key); + } + return (A) this; } - public A removeFromUsed(java.util.Map map) { - if(this.used == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.used != null){this.used.remove(key);}}} return (A)this; + + public A removeFromUsed( + java.util.Map map) { + if (this.used == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.used != null) { + this.used.remove(key); + } + } + } + return (A) this; } - public java.util.Map getUsed() { + + public java.util.Map getUsed() { return this.used; } - public A withUsed(java.util.Map used) { - if (used == null) { this.used = null;} else {this.used = new java.util.LinkedHashMap(used);} return (A) this; + + public A withUsed( + java.util.Map used) { + if (used == null) { + this.used = null; + } else { + this.used = new java.util.LinkedHashMap(used); + } + return (A) this; } + public java.lang.Boolean hasUsed() { return this.used != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ResourceQuotaStatusFluentImpl that = (V1ResourceQuotaStatusFluentImpl) o; - if (hard != null ? !hard.equals(that.hard) :that.hard != null) return false; - if (used != null ? !used.equals(that.used) :that.used != null) return false; + if (hard != null ? !hard.equals(that.hard) : that.hard != null) return false; + if (used != null ? !used.equals(that.used) : that.used != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(hard, used, super.hashCode()); + return java.util.Objects.hash(hard, used, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRequirementsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRequirementsBuilder.java index d9b152a656..5be2ca8bad 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRequirementsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRequirementsBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ResourceRequirementsBuilder extends io.kubernetes.client.openapi.models.V1ResourceRequirementsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ResourceRequirementsBuilder + extends io.kubernetes.client.openapi.models.V1ResourceRequirementsFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ResourceRequirements, + io.kubernetes.client.openapi.models.V1ResourceRequirementsBuilder> { public V1ResourceRequirementsBuilder() { this(false); } + public V1ResourceRequirementsBuilder(java.lang.Boolean validationEnabled) { this(new V1ResourceRequirements(), validationEnabled); } - public V1ResourceRequirementsBuilder(io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent fluent) { + + public V1ResourceRequirementsBuilder( + io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent fluent) { this(fluent, false); } - public V1ResourceRequirementsBuilder(io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ResourceRequirementsBuilder( + io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ResourceRequirements(), validationEnabled); } - public V1ResourceRequirementsBuilder(io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent fluent,io.kubernetes.client.openapi.models.V1ResourceRequirements instance) { + + public V1ResourceRequirementsBuilder( + io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceRequirements instance) { this(fluent, instance, false); } - public V1ResourceRequirementsBuilder(io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent fluent,io.kubernetes.client.openapi.models.V1ResourceRequirements instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ResourceRequirementsBuilder( + io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceRequirements instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLimits(instance.getLimits()); fluent.withRequests(instance.getRequests()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ResourceRequirementsBuilder(io.kubernetes.client.openapi.models.V1ResourceRequirements instance) { - this(instance,false); + + public V1ResourceRequirementsBuilder( + io.kubernetes.client.openapi.models.V1ResourceRequirements instance) { + this(instance, false); } - public V1ResourceRequirementsBuilder(io.kubernetes.client.openapi.models.V1ResourceRequirements instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ResourceRequirementsBuilder( + io.kubernetes.client.openapi.models.V1ResourceRequirements instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLimits(instance.getLimits()); this.withRequests(instance.getRequests()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ResourceRequirements build() { V1ResourceRequirements buildable = new V1ResourceRequirements(); buildable.setLimits(fluent.getLimits()); buildable.setRequests(fluent.getRequests()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ResourceRequirementsBuilder that = (V1ResourceRequirementsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRequirementsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRequirementsFluent.java index 097d27caa0..7e225b4dfa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRequirementsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRequirementsFluent.java @@ -1,30 +1,50 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; -import java.util.Map; -import java.util.LinkedHashMap; - - /** - * Generated - */ -public interface V1ResourceRequirementsFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToLimits(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToLimits(java.util.Map map); +/** Generated */ +public interface V1ResourceRequirementsFluent< + A extends io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToLimits(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToLimits(java.util.Map map); + public A removeFromLimits(java.lang.String key); - public A removeFromLimits(java.util.Map map); - public java.util.Map getLimits(); - public A withLimits(java.util.Map limits); + + public A removeFromLimits( + java.util.Map map); + + public java.util.Map getLimits(); + + public A withLimits( + java.util.Map limits); + public java.lang.Boolean hasLimits(); - public A addToRequests(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToRequests(java.util.Map map); + + public A addToRequests(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToRequests(java.util.Map map); + public A removeFromRequests(java.lang.String key); - public A removeFromRequests(java.util.Map map); - public java.util.Map getRequests(); - public A withRequests(java.util.Map requests); + + public A removeFromRequests( + java.util.Map map); + + public java.util.Map getRequests(); + + public A withRequests( + java.util.Map requests); + public java.lang.Boolean hasRequests(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRequirementsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRequirementsFluentImpl.java index 255b385b70..d5f0433b53 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRequirementsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRequirementsFluentImpl.java @@ -1,87 +1,171 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.BaseFluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; -import java.util.Map; -import java.util.LinkedHashMap; - - /** - * Generated - */ -public class V1ResourceRequirementsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent{ - public V1ResourceRequirementsFluentImpl() { - } - public V1ResourceRequirementsFluentImpl(io.kubernetes.client.openapi.models.V1ResourceRequirements instance) { +/** Generated */ +public class V1ResourceRequirementsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ResourceRequirementsFluent { + public V1ResourceRequirementsFluentImpl() {} + + public V1ResourceRequirementsFluentImpl( + io.kubernetes.client.openapi.models.V1ResourceRequirements instance) { this.withLimits(instance.getLimits()); this.withRequests(instance.getRequests()); - } - private java.util.Map limits; - private java.util.Map requests; - public A addToLimits(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.limits == null && key != null && value != null) { this.limits = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.limits.put(key, value);} return (A)this; + + private java.util.Map limits; + private java.util.Map requests; + + public A addToLimits(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.limits == null && key != null && value != null) { + this.limits = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.limits.put(key, value); + } + return (A) this; } - public A addToLimits(java.util.Map map) { - if(this.limits == null && map != null) { this.limits = new java.util.LinkedHashMap(); } - if(map != null) { this.limits.putAll(map);} return (A)this; + + public A addToLimits(java.util.Map map) { + if (this.limits == null && map != null) { + this.limits = new java.util.LinkedHashMap(); + } + if (map != null) { + this.limits.putAll(map); + } + return (A) this; } + public A removeFromLimits(java.lang.String key) { - if(this.limits == null) { return (A) this; } - if(key != null && this.limits != null) {this.limits.remove(key);} return (A)this; + if (this.limits == null) { + return (A) this; + } + if (key != null && this.limits != null) { + this.limits.remove(key); + } + return (A) this; } - public A removeFromLimits(java.util.Map map) { - if(this.limits == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.limits != null){this.limits.remove(key);}}} return (A)this; + + public A removeFromLimits( + java.util.Map map) { + if (this.limits == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.limits != null) { + this.limits.remove(key); + } + } + } + return (A) this; } - public java.util.Map getLimits() { + + public java.util.Map getLimits() { return this.limits; } - public A withLimits(java.util.Map limits) { - if (limits == null) { this.limits = null;} else {this.limits = new java.util.LinkedHashMap(limits);} return (A) this; + + public A withLimits( + java.util.Map limits) { + if (limits == null) { + this.limits = null; + } else { + this.limits = new java.util.LinkedHashMap(limits); + } + return (A) this; } + public java.lang.Boolean hasLimits() { return this.limits != null; } - public A addToRequests(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.requests == null && key != null && value != null) { this.requests = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.requests.put(key, value);} return (A)this; + + public A addToRequests(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.requests == null && key != null && value != null) { + this.requests = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.requests.put(key, value); + } + return (A) this; } - public A addToRequests(java.util.Map map) { - if(this.requests == null && map != null) { this.requests = new java.util.LinkedHashMap(); } - if(map != null) { this.requests.putAll(map);} return (A)this; + + public A addToRequests( + java.util.Map map) { + if (this.requests == null && map != null) { + this.requests = new java.util.LinkedHashMap(); + } + if (map != null) { + this.requests.putAll(map); + } + return (A) this; } + public A removeFromRequests(java.lang.String key) { - if(this.requests == null) { return (A) this; } - if(key != null && this.requests != null) {this.requests.remove(key);} return (A)this; + if (this.requests == null) { + return (A) this; + } + if (key != null && this.requests != null) { + this.requests.remove(key); + } + return (A) this; } - public A removeFromRequests(java.util.Map map) { - if(this.requests == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.requests != null){this.requests.remove(key);}}} return (A)this; + + public A removeFromRequests( + java.util.Map map) { + if (this.requests == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.requests != null) { + this.requests.remove(key); + } + } + } + return (A) this; } - public java.util.Map getRequests() { + + public java.util.Map getRequests() { return this.requests; } - public A withRequests(java.util.Map requests) { - if (requests == null) { this.requests = null;} else {this.requests = new java.util.LinkedHashMap(requests);} return (A) this; + + public A withRequests( + java.util.Map requests) { + if (requests == null) { + this.requests = null; + } else { + this.requests = new java.util.LinkedHashMap(requests); + } + return (A) this; } + public java.lang.Boolean hasRequests() { return this.requests != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ResourceRequirementsFluentImpl that = (V1ResourceRequirementsFluentImpl) o; - if (limits != null ? !limits.equals(that.limits) :that.limits != null) return false; - if (requests != null ? !requests.equals(that.requests) :that.requests != null) return false; + if (limits != null ? !limits.equals(that.limits) : that.limits != null) return false; + if (requests != null ? !requests.equals(that.requests) : that.requests != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(limits, requests, super.hashCode()); + return java.util.Objects.hash(limits, requests, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRuleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRuleBuilder.java index b7c869fa1d..d2fb8529b1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRuleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRuleBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ResourceRuleBuilder extends io.kubernetes.client.openapi.models.V1ResourceRuleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ResourceRuleBuilder + extends io.kubernetes.client.openapi.models.V1ResourceRuleFluentImpl< + io.kubernetes.client.openapi.models.V1ResourceRuleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ResourceRule, + io.kubernetes.client.openapi.models.V1ResourceRuleBuilder> { public V1ResourceRuleBuilder() { this(false); } + public V1ResourceRuleBuilder(java.lang.Boolean validationEnabled) { this(new V1ResourceRule(), validationEnabled); } + public V1ResourceRuleBuilder(io.kubernetes.client.openapi.models.V1ResourceRuleFluent fluent) { this(fluent, false); } - public V1ResourceRuleBuilder(io.kubernetes.client.openapi.models.V1ResourceRuleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ResourceRuleBuilder( + io.kubernetes.client.openapi.models.V1ResourceRuleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ResourceRule(), validationEnabled); } - public V1ResourceRuleBuilder(io.kubernetes.client.openapi.models.V1ResourceRuleFluent fluent,io.kubernetes.client.openapi.models.V1ResourceRule instance) { + + public V1ResourceRuleBuilder( + io.kubernetes.client.openapi.models.V1ResourceRuleFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceRule instance) { this(fluent, instance, false); } - public V1ResourceRuleBuilder(io.kubernetes.client.openapi.models.V1ResourceRuleFluent fluent,io.kubernetes.client.openapi.models.V1ResourceRule instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ResourceRuleBuilder( + io.kubernetes.client.openapi.models.V1ResourceRuleFluent fluent, + io.kubernetes.client.openapi.models.V1ResourceRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiGroups(instance.getApiGroups()); fluent.withResourceNames(instance.getResourceNames()); @@ -29,13 +55,17 @@ public V1ResourceRuleBuilder(io.kubernetes.client.openapi.models.V1ResourceRuleF fluent.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ResourceRuleBuilder(io.kubernetes.client.openapi.models.V1ResourceRule instance) { - this(instance,false); + this(instance, false); } - public V1ResourceRuleBuilder(io.kubernetes.client.openapi.models.V1ResourceRule instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ResourceRuleBuilder( + io.kubernetes.client.openapi.models.V1ResourceRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiGroups(instance.getApiGroups()); this.withResourceNames(instance.getResourceNames()); @@ -44,10 +74,12 @@ public V1ResourceRuleBuilder(io.kubernetes.client.openapi.models.V1ResourceRule this.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ResourceRuleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ResourceRule build() { V1ResourceRule buildable = new V1ResourceRule(); buildable.setApiGroups(fluent.getApiGroups()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1ResourceRule build() { buildable.setVerbs(fluent.getVerbs()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ResourceRuleBuilder that = (V1ResourceRuleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRuleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRuleFluent.java index 14d5ff94d2..a3c0687d9e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRuleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRuleFluent.java @@ -1,82 +1,153 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1ResourceRuleFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToApiGroups(java.lang.Integer index,java.lang.String item); - public A setToApiGroups(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1ResourceRuleFluent< + A extends io.kubernetes.client.openapi.models.V1ResourceRuleFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToApiGroups(java.lang.Integer index, java.lang.String item); + + public A setToApiGroups(java.lang.Integer index, java.lang.String item); + public A addToApiGroups(java.lang.String... items); + public A addAllToApiGroups(java.util.Collection items); + public A removeFromApiGroups(java.lang.String... items); + public A removeAllFromApiGroups(java.util.Collection items); + public java.util.List getApiGroups(); + public java.lang.String getApiGroup(java.lang.Integer index); + public java.lang.String getFirstApiGroup(); + public java.lang.String getLastApiGroup(); - public java.lang.String getMatchingApiGroup(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingApiGroup(java.util.function.Predicate predicate); + + public java.lang.String getMatchingApiGroup( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingApiGroup( + java.util.function.Predicate predicate); + public A withApiGroups(java.util.List apiGroups); + public A withApiGroups(java.lang.String... apiGroups); + public java.lang.Boolean hasApiGroups(); + public A addNewApiGroup(java.lang.String original); - public A addToResourceNames(java.lang.Integer index,java.lang.String item); - public A setToResourceNames(java.lang.Integer index,java.lang.String item); + + public A addToResourceNames(java.lang.Integer index, java.lang.String item); + + public A setToResourceNames(java.lang.Integer index, java.lang.String item); + public A addToResourceNames(java.lang.String... items); + public A addAllToResourceNames(java.util.Collection items); + public A removeFromResourceNames(java.lang.String... items); + public A removeAllFromResourceNames(java.util.Collection items); + public java.util.List getResourceNames(); + public java.lang.String getResourceName(java.lang.Integer index); + public java.lang.String getFirstResourceName(); + public java.lang.String getLastResourceName(); - public java.lang.String getMatchingResourceName(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingResourceName(java.util.function.Predicate predicate); + + public java.lang.String getMatchingResourceName( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingResourceName( + java.util.function.Predicate predicate); + public A withResourceNames(java.util.List resourceNames); + public A withResourceNames(java.lang.String... resourceNames); + public java.lang.Boolean hasResourceNames(); + public A addNewResourceName(java.lang.String original); - public A addToResources(java.lang.Integer index,java.lang.String item); - public A setToResources(java.lang.Integer index,java.lang.String item); + + public A addToResources(java.lang.Integer index, java.lang.String item); + + public A setToResources(java.lang.Integer index, java.lang.String item); + public A addToResources(java.lang.String... items); + public A addAllToResources(java.util.Collection items); + public A removeFromResources(java.lang.String... items); + public A removeAllFromResources(java.util.Collection items); + public java.util.List getResources(); + public java.lang.String getResource(java.lang.Integer index); + public java.lang.String getFirstResource(); + public java.lang.String getLastResource(); - public java.lang.String getMatchingResource(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingResource(java.util.function.Predicate predicate); + + public java.lang.String getMatchingResource( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingResource( + java.util.function.Predicate predicate); + public A withResources(java.util.List resources); + public A withResources(java.lang.String... resources); + public java.lang.Boolean hasResources(); + public A addNewResource(java.lang.String original); - public A addToVerbs(java.lang.Integer index,java.lang.String item); - public A setToVerbs(java.lang.Integer index,java.lang.String item); + + public A addToVerbs(java.lang.Integer index, java.lang.String item); + + public A setToVerbs(java.lang.Integer index, java.lang.String item); + public A addToVerbs(java.lang.String... items); + public A addAllToVerbs(java.util.Collection items); + public A removeFromVerbs(java.lang.String... items); + public A removeAllFromVerbs(java.util.Collection items); + public java.util.List getVerbs(); + public java.lang.String getVerb(java.lang.Integer index); + public java.lang.String getFirstVerb(); + public java.lang.String getLastVerb(); + public java.lang.String getMatchingVerb(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate); + public A withVerbs(java.util.List verbs); + public A withVerbs(java.lang.String... verbs); + public java.lang.Boolean hasVerbs(); + public A addNewVerb(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRuleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRuleFluentImpl.java index f2d10a7358..5862741793 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRuleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ResourceRuleFluentImpl.java @@ -1,21 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.ArrayList; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public class V1ResourceRuleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ResourceRuleFluent{ - public V1ResourceRuleFluentImpl() { - } +/** Generated */ +public class V1ResourceRuleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ResourceRuleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ResourceRuleFluent { + public V1ResourceRuleFluentImpl() {} + public V1ResourceRuleFluentImpl(io.kubernetes.client.openapi.models.V1ResourceRule instance) { this.withApiGroups(instance.getApiGroups()); @@ -24,240 +27,517 @@ public V1ResourceRuleFluentImpl(io.kubernetes.client.openapi.models.V1ResourceRu this.withResources(instance.getResources()); this.withVerbs(instance.getVerbs()); - } + private java.util.List apiGroups; private java.util.List resourceNames; private java.util.List resources; private java.util.List verbs; - public A addToApiGroups(java.lang.Integer index,java.lang.String item) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} + + public A addToApiGroups(java.lang.Integer index, java.lang.String item) { + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } this.apiGroups.add(index, item); - return (A)this; + return (A) this; } - public A setToApiGroups(java.lang.Integer index,java.lang.String item) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - this.apiGroups.set(index, item); return (A)this; + + public A setToApiGroups(java.lang.Integer index, java.lang.String item) { + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + this.apiGroups.set(index, item); + return (A) this; } + public A addToApiGroups(java.lang.String... items) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.apiGroups.add(item);} return (A)this; + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.apiGroups.add(item); + } + return (A) this; } + public A addAllToApiGroups(java.util.Collection items) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.apiGroups.add(item);} return (A)this; + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.apiGroups.add(item); + } + return (A) this; } + public A removeFromApiGroups(java.lang.String... items) { - for (java.lang.String item : items) {if (this.apiGroups!= null){ this.apiGroups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.apiGroups != null) { + this.apiGroups.remove(item); + } + } + return (A) this; } + public A removeAllFromApiGroups(java.util.Collection items) { - for (java.lang.String item : items) {if (this.apiGroups!= null){ this.apiGroups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.apiGroups != null) { + this.apiGroups.remove(item); + } + } + return (A) this; } + public java.util.List getApiGroups() { return this.apiGroups; } + public java.lang.String getApiGroup(java.lang.Integer index) { return this.apiGroups.get(index); } + public java.lang.String getFirstApiGroup() { return this.apiGroups.get(0); } + public java.lang.String getLastApiGroup() { return this.apiGroups.get(apiGroups.size() - 1); } - public java.lang.String getMatchingApiGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: apiGroups) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingApiGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : apiGroups) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingApiGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: apiGroups) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingApiGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : apiGroups) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withApiGroups(java.util.List apiGroups) { - if (apiGroups != null) {this.apiGroups = new java.util.ArrayList(); for (java.lang.String item : apiGroups){this.addToApiGroups(item);}} else { this.apiGroups = null;} return (A) this; + if (apiGroups != null) { + this.apiGroups = new java.util.ArrayList(); + for (java.lang.String item : apiGroups) { + this.addToApiGroups(item); + } + } else { + this.apiGroups = null; + } + return (A) this; } + public A withApiGroups(java.lang.String... apiGroups) { - if (this.apiGroups != null) {this.apiGroups.clear();} - if (apiGroups != null) {for (java.lang.String item :apiGroups){ this.addToApiGroups(item);}} return (A) this; + if (this.apiGroups != null) { + this.apiGroups.clear(); + } + if (apiGroups != null) { + for (java.lang.String item : apiGroups) { + this.addToApiGroups(item); + } + } + return (A) this; } + public java.lang.Boolean hasApiGroups() { return apiGroups != null && !apiGroups.isEmpty(); } + public A addNewApiGroup(java.lang.String original) { - return (A)addToApiGroups(new String(original)); + return (A) addToApiGroups(new String(original)); } - public A addToResourceNames(java.lang.Integer index,java.lang.String item) { - if (this.resourceNames == null) {this.resourceNames = new java.util.ArrayList();} + + public A addToResourceNames(java.lang.Integer index, java.lang.String item) { + if (this.resourceNames == null) { + this.resourceNames = new java.util.ArrayList(); + } this.resourceNames.add(index, item); - return (A)this; + return (A) this; } - public A setToResourceNames(java.lang.Integer index,java.lang.String item) { - if (this.resourceNames == null) {this.resourceNames = new java.util.ArrayList();} - this.resourceNames.set(index, item); return (A)this; + + public A setToResourceNames(java.lang.Integer index, java.lang.String item) { + if (this.resourceNames == null) { + this.resourceNames = new java.util.ArrayList(); + } + this.resourceNames.set(index, item); + return (A) this; } + public A addToResourceNames(java.lang.String... items) { - if (this.resourceNames == null) {this.resourceNames = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resourceNames.add(item);} return (A)this; + if (this.resourceNames == null) { + this.resourceNames = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resourceNames.add(item); + } + return (A) this; } + public A addAllToResourceNames(java.util.Collection items) { - if (this.resourceNames == null) {this.resourceNames = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resourceNames.add(item);} return (A)this; + if (this.resourceNames == null) { + this.resourceNames = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resourceNames.add(item); + } + return (A) this; } + public A removeFromResourceNames(java.lang.String... items) { - for (java.lang.String item : items) {if (this.resourceNames!= null){ this.resourceNames.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resourceNames != null) { + this.resourceNames.remove(item); + } + } + return (A) this; } + public A removeAllFromResourceNames(java.util.Collection items) { - for (java.lang.String item : items) {if (this.resourceNames!= null){ this.resourceNames.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resourceNames != null) { + this.resourceNames.remove(item); + } + } + return (A) this; } + public java.util.List getResourceNames() { return this.resourceNames; } + public java.lang.String getResourceName(java.lang.Integer index) { return this.resourceNames.get(index); } + public java.lang.String getFirstResourceName() { return this.resourceNames.get(0); } + public java.lang.String getLastResourceName() { return this.resourceNames.get(resourceNames.size() - 1); } - public java.lang.String getMatchingResourceName(java.util.function.Predicate predicate) { - for (java.lang.String item: resourceNames) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingResourceName( + java.util.function.Predicate predicate) { + for (java.lang.String item : resourceNames) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingResourceName(java.util.function.Predicate predicate) { - for (java.lang.String item: resourceNames) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingResourceName( + java.util.function.Predicate predicate) { + for (java.lang.String item : resourceNames) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withResourceNames(java.util.List resourceNames) { - if (resourceNames != null) {this.resourceNames = new java.util.ArrayList(); for (java.lang.String item : resourceNames){this.addToResourceNames(item);}} else { this.resourceNames = null;} return (A) this; + if (resourceNames != null) { + this.resourceNames = new java.util.ArrayList(); + for (java.lang.String item : resourceNames) { + this.addToResourceNames(item); + } + } else { + this.resourceNames = null; + } + return (A) this; } + public A withResourceNames(java.lang.String... resourceNames) { - if (this.resourceNames != null) {this.resourceNames.clear();} - if (resourceNames != null) {for (java.lang.String item :resourceNames){ this.addToResourceNames(item);}} return (A) this; + if (this.resourceNames != null) { + this.resourceNames.clear(); + } + if (resourceNames != null) { + for (java.lang.String item : resourceNames) { + this.addToResourceNames(item); + } + } + return (A) this; } + public java.lang.Boolean hasResourceNames() { return resourceNames != null && !resourceNames.isEmpty(); } + public A addNewResourceName(java.lang.String original) { - return (A)addToResourceNames(new String(original)); + return (A) addToResourceNames(new String(original)); } - public A addToResources(java.lang.Integer index,java.lang.String item) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} + + public A addToResources(java.lang.Integer index, java.lang.String item) { + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } this.resources.add(index, item); - return (A)this; + return (A) this; } - public A setToResources(java.lang.Integer index,java.lang.String item) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - this.resources.set(index, item); return (A)this; + + public A setToResources(java.lang.Integer index, java.lang.String item) { + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + this.resources.set(index, item); + return (A) this; } + public A addToResources(java.lang.String... items) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resources.add(item);} return (A)this; + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resources.add(item); + } + return (A) this; } + public A addAllToResources(java.util.Collection items) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resources.add(item);} return (A)this; + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resources.add(item); + } + return (A) this; } + public A removeFromResources(java.lang.String... items) { - for (java.lang.String item : items) {if (this.resources!= null){ this.resources.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resources != null) { + this.resources.remove(item); + } + } + return (A) this; } + public A removeAllFromResources(java.util.Collection items) { - for (java.lang.String item : items) {if (this.resources!= null){ this.resources.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resources != null) { + this.resources.remove(item); + } + } + return (A) this; } + public java.util.List getResources() { return this.resources; } + public java.lang.String getResource(java.lang.Integer index) { return this.resources.get(index); } + public java.lang.String getFirstResource() { return this.resources.get(0); } + public java.lang.String getLastResource() { return this.resources.get(resources.size() - 1); } - public java.lang.String getMatchingResource(java.util.function.Predicate predicate) { - for (java.lang.String item: resources) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingResource( + java.util.function.Predicate predicate) { + for (java.lang.String item : resources) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingResource(java.util.function.Predicate predicate) { - for (java.lang.String item: resources) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingResource( + java.util.function.Predicate predicate) { + for (java.lang.String item : resources) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withResources(java.util.List resources) { - if (resources != null) {this.resources = new java.util.ArrayList(); for (java.lang.String item : resources){this.addToResources(item);}} else { this.resources = null;} return (A) this; + if (resources != null) { + this.resources = new java.util.ArrayList(); + for (java.lang.String item : resources) { + this.addToResources(item); + } + } else { + this.resources = null; + } + return (A) this; } + public A withResources(java.lang.String... resources) { - if (this.resources != null) {this.resources.clear();} - if (resources != null) {for (java.lang.String item :resources){ this.addToResources(item);}} return (A) this; + if (this.resources != null) { + this.resources.clear(); + } + if (resources != null) { + for (java.lang.String item : resources) { + this.addToResources(item); + } + } + return (A) this; } + public java.lang.Boolean hasResources() { return resources != null && !resources.isEmpty(); } + public A addNewResource(java.lang.String original) { - return (A)addToResources(new String(original)); + return (A) addToResources(new String(original)); } - public A addToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} + + public A addToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } this.verbs.add(index, item); - return (A)this; + return (A) this; } - public A setToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - this.verbs.set(index, item); return (A)this; + + public A setToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + this.verbs.set(index, item); + return (A) this; } + public A addToVerbs(java.lang.String... items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A addAllToVerbs(java.util.Collection items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A removeFromVerbs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public A removeAllFromVerbs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public java.util.List getVerbs() { return this.verbs; } + public java.lang.String getVerb(java.lang.Integer index) { return this.verbs.get(index); } + public java.lang.String getFirstVerb() { return this.verbs.get(0); } + public java.lang.String getLastVerb() { return this.verbs.get(verbs.size() - 1); } - public java.lang.String getMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withVerbs(java.util.List verbs) { - if (verbs != null) {this.verbs = new java.util.ArrayList(); for (java.lang.String item : verbs){this.addToVerbs(item);}} else { this.verbs = null;} return (A) this; + if (verbs != null) { + this.verbs = new java.util.ArrayList(); + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } else { + this.verbs = null; + } + return (A) this; } + public A withVerbs(java.lang.String... verbs) { - if (this.verbs != null) {this.verbs.clear();} - if (verbs != null) {for (java.lang.String item :verbs){ this.addToVerbs(item);}} return (A) this; + if (this.verbs != null) { + this.verbs.clear(); + } + if (verbs != null) { + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } + return (A) this; } + public java.lang.Boolean hasVerbs() { return verbs != null && !verbs.isEmpty(); } + public A addNewVerb(java.lang.String original) { - return (A)addToVerbs(new String(original)); + return (A) addToVerbs(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ResourceRuleFluentImpl that = (V1ResourceRuleFluentImpl) o; - if (apiGroups != null ? !apiGroups.equals(that.apiGroups) :that.apiGroups != null) return false; - if (resourceNames != null ? !resourceNames.equals(that.resourceNames) :that.resourceNames != null) return false; - if (resources != null ? !resources.equals(that.resources) :that.resources != null) return false; - if (verbs != null ? !verbs.equals(that.verbs) :that.verbs != null) return false; + if (apiGroups != null ? !apiGroups.equals(that.apiGroups) : that.apiGroups != null) + return false; + if (resourceNames != null + ? !resourceNames.equals(that.resourceNames) + : that.resourceNames != null) return false; + if (resources != null ? !resources.equals(that.resources) : that.resources != null) + return false; + if (verbs != null ? !verbs.equals(that.verbs) : that.verbs != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiGroups, resourceNames, resources, verbs, super.hashCode()); + return java.util.Objects.hash(apiGroups, resourceNames, resources, verbs, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingBuilder.java index e8dc1e130a..4de0680e61 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1RoleBindingBuilder extends io.kubernetes.client.openapi.models.V1RoleBindingFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1RoleBindingBuilder + extends io.kubernetes.client.openapi.models.V1RoleBindingFluentImpl< + io.kubernetes.client.openapi.models.V1RoleBindingBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1RoleBinding, + io.kubernetes.client.openapi.models.V1RoleBindingBuilder> { public V1RoleBindingBuilder() { this(false); } + public V1RoleBindingBuilder(java.lang.Boolean validationEnabled) { this(new V1RoleBinding(), validationEnabled); } + public V1RoleBindingBuilder(io.kubernetes.client.openapi.models.V1RoleBindingFluent fluent) { this(fluent, false); } - public V1RoleBindingBuilder(io.kubernetes.client.openapi.models.V1RoleBindingFluent fluent,java.lang.Boolean validationEnabled) { + + public V1RoleBindingBuilder( + io.kubernetes.client.openapi.models.V1RoleBindingFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1RoleBinding(), validationEnabled); } - public V1RoleBindingBuilder(io.kubernetes.client.openapi.models.V1RoleBindingFluent fluent,io.kubernetes.client.openapi.models.V1RoleBinding instance) { + + public V1RoleBindingBuilder( + io.kubernetes.client.openapi.models.V1RoleBindingFluent fluent, + io.kubernetes.client.openapi.models.V1RoleBinding instance) { this(fluent, instance, false); } - public V1RoleBindingBuilder(io.kubernetes.client.openapi.models.V1RoleBindingFluent fluent,io.kubernetes.client.openapi.models.V1RoleBinding instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1RoleBindingBuilder( + io.kubernetes.client.openapi.models.V1RoleBindingFluent fluent, + io.kubernetes.client.openapi.models.V1RoleBinding instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,17 @@ public V1RoleBindingBuilder(io.kubernetes.client.openapi.models.V1RoleBindingFlu fluent.withSubjects(instance.getSubjects()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1RoleBindingBuilder(io.kubernetes.client.openapi.models.V1RoleBinding instance) { - this(instance,false); + this(instance, false); } - public V1RoleBindingBuilder(io.kubernetes.client.openapi.models.V1RoleBinding instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1RoleBindingBuilder( + io.kubernetes.client.openapi.models.V1RoleBinding instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +78,12 @@ public V1RoleBindingBuilder(io.kubernetes.client.openapi.models.V1RoleBinding in this.withSubjects(instance.getSubjects()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1RoleBindingFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1RoleBinding build() { V1RoleBinding buildable = new V1RoleBinding(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +93,23 @@ public io.kubernetes.client.openapi.models.V1RoleBinding build() { buildable.setSubjects(fluent.getSubjects()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1RoleBindingBuilder that = (V1RoleBindingBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingFluent.java index acf533383e..ccce0af7a9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingFluent.java @@ -1,115 +1,190 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1RoleBindingFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1RoleBindingFluent< + A extends io.kubernetes.client.openapi.models.V1RoleBindingFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildRoleRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RoleRef getRoleRef(); + public io.kubernetes.client.openapi.models.V1RoleRef buildRoleRef(); + public A withRoleRef(io.kubernetes.client.openapi.models.V1RoleRef roleRef); + public java.lang.Boolean hasRoleRef(); + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested withNewRoleRef(); - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested withNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested + withNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item); + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested editRoleRef(); - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested editOrNewRoleRef(); - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested editOrNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item); - public A addToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item); - public A setToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested + editOrNewRoleRef(); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested + editOrNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item); + + public A addToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item); + + public A setToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item); + public A addToSubjects(io.kubernetes.client.openapi.models.V1Subject... items); - public A addAllToSubjects(java.util.Collection items); + + public A addAllToSubjects( + java.util.Collection items); + public A removeFromSubjects(io.kubernetes.client.openapi.models.V1Subject... items); - public A removeAllFromSubjects(java.util.Collection items); - public A removeMatchingFromSubjects(java.util.function.Predicate predicate); - + + public A removeAllFromSubjects( + java.util.Collection items); + + public A removeMatchingFromSubjects( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildSubjects instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getSubjects(); + public java.util.List buildSubjects(); + public io.kubernetes.client.openapi.models.V1Subject buildSubject(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Subject buildFirstSubject(); + public io.kubernetes.client.openapi.models.V1Subject buildLastSubject(); - public io.kubernetes.client.openapi.models.V1Subject buildMatchingSubject(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingSubject(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Subject buildMatchingSubject( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingSubject( + java.util.function.Predicate predicate); + public A withSubjects(java.util.List subjects); + public A withSubjects(io.kubernetes.client.openapi.models.V1Subject... subjects); + public java.lang.Boolean hasSubjects(); + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested addNewSubject(); - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested addNewSubjectLike(io.kubernetes.client.openapi.models.V1Subject item); - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested setNewSubjectLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item); - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested editSubject(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested editFirstSubject(); - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested editLastSubject(); - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested editMatchingSubject(java.util.function.Predicate predicate); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested + addNewSubjectLike(io.kubernetes.client.openapi.models.V1Subject item); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested + setNewSubjectLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested editSubject( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested + editFirstSubject(); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested + editLastSubject(); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested + editMatchingSubject( + java.util.function.Predicate + predicate); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface RoleRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1RoleRefFluent>{ + + public interface RoleRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1RoleRefFluent< + io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested> { public N and(); + public N endRoleRef(); - } - public interface SubjectsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SubjectFluent>{ + + public interface SubjectsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SubjectFluent< + io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested> { public N and(); + public N endSubject(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingFluentImpl.java index 3493ef7fc9..ee34a9523c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1RoleBindingFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1RoleBindingFluent{ - public V1RoleBindingFluentImpl() { - } +/** Generated */ +public class V1RoleBindingFluentImpl< + A extends io.kubernetes.client.openapi.models.V1RoleBindingFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1RoleBindingFluent { + public V1RoleBindingFluentImpl() {} + public V1RoleBindingFluentImpl(io.kubernetes.client.openapi.models.V1RoleBinding instance) { this.withApiVersion(instance.getApiVersion()); @@ -30,141 +32,252 @@ public V1RoleBindingFluentImpl(io.kubernetes.client.openapi.models.V1RoleBinding this.withRoleRef(instance.getRoleRef()); this.withSubjects(instance.getSubjects()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1RoleRefBuilder roleRef; private java.util.ArrayList subjects; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1RoleBindingFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1RoleBindingFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildRoleRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RoleRef getRoleRef() { - return this.roleRef!=null ?this.roleRef.build():null; + return this.roleRef != null ? this.roleRef.build() : null; } + public io.kubernetes.client.openapi.models.V1RoleRef buildRoleRef() { - return this.roleRef!=null ?this.roleRef.build():null; + return this.roleRef != null ? this.roleRef.build() : null; } + public A withRoleRef(io.kubernetes.client.openapi.models.V1RoleRef roleRef) { _visitables.get("roleRef").remove(this.roleRef); - if (roleRef!=null){ this.roleRef= new io.kubernetes.client.openapi.models.V1RoleRefBuilder(roleRef); _visitables.get("roleRef").add(this.roleRef);} return (A) this; + if (roleRef != null) { + this.roleRef = new io.kubernetes.client.openapi.models.V1RoleRefBuilder(roleRef); + _visitables.get("roleRef").add(this.roleRef); + } + return (A) this; } + public java.lang.Boolean hasRoleRef() { return this.roleRef != null; } + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested withNewRoleRef() { return new io.kubernetes.client.openapi.models.V1RoleBindingFluentImpl.RoleRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested withNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item) { + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested + withNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item) { return new io.kubernetes.client.openapi.models.V1RoleBindingFluentImpl.RoleRefNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested editRoleRef() { return withNewRoleRefLike(getRoleRef()); } - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested editOrNewRoleRef() { - return withNewRoleRefLike(getRoleRef() != null ? getRoleRef(): new io.kubernetes.client.openapi.models.V1RoleRefBuilder().build()); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested + editOrNewRoleRef() { + return withNewRoleRefLike( + getRoleRef() != null + ? getRoleRef() + : new io.kubernetes.client.openapi.models.V1RoleRefBuilder().build()); } - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested editOrNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item) { - return withNewRoleRefLike(getRoleRef() != null ? getRoleRef(): item); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested + editOrNewRoleRefLike(io.kubernetes.client.openapi.models.V1RoleRef item) { + return withNewRoleRefLike(getRoleRef() != null ? getRoleRef() : item); } - public A addToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(item);_visitables.get("subjects").add(index >= 0 ? index : _visitables.get("subjects").size(), builder);this.subjects.add(index >= 0 ? index : subjects.size(), builder); return (A)this; + + public A addToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item) { + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); + _visitables + .get("subjects") + .add(index >= 0 ? index : _visitables.get("subjects").size(), builder); + this.subjects.add(index >= 0 ? index : subjects.size(), builder); + return (A) this; } - public A setToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); - if (index < 0 || index >= _visitables.get("subjects").size()) { _visitables.get("subjects").add(builder); } else { _visitables.get("subjects").set(index, builder);} - if (index < 0 || index >= subjects.size()) { subjects.add(builder); } else { subjects.set(index, builder);} - return (A)this; + + public A setToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item) { + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); + if (index < 0 || index >= _visitables.get("subjects").size()) { + _visitables.get("subjects").add(builder); + } else { + _visitables.get("subjects").set(index, builder); + } + if (index < 0 || index >= subjects.size()) { + subjects.add(builder); + } else { + subjects.set(index, builder); + } + return (A) this; } + public A addToSubjects(io.kubernetes.client.openapi.models.V1Subject... items) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Subject item : items) {io.kubernetes.client.openapi.models.V1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(item);_visitables.get("subjects").add(builder);this.subjects.add(builder);} return (A)this; + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Subject item : items) { + io.kubernetes.client.openapi.models.V1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); + _visitables.get("subjects").add(builder); + this.subjects.add(builder); + } + return (A) this; } - public A addAllToSubjects(java.util.Collection items) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Subject item : items) {io.kubernetes.client.openapi.models.V1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(item);_visitables.get("subjects").add(builder);this.subjects.add(builder);} return (A)this; + + public A addAllToSubjects( + java.util.Collection items) { + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Subject item : items) { + io.kubernetes.client.openapi.models.V1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); + _visitables.get("subjects").add(builder); + this.subjects.add(builder); + } + return (A) this; } + public A removeFromSubjects(io.kubernetes.client.openapi.models.V1Subject... items) { - for (io.kubernetes.client.openapi.models.V1Subject item : items) {io.kubernetes.client.openapi.models.V1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(item);_visitables.get("subjects").remove(builder);if (this.subjects != null) {this.subjects.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Subject item : items) { + io.kubernetes.client.openapi.models.V1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); + _visitables.get("subjects").remove(builder); + if (this.subjects != null) { + this.subjects.remove(builder); + } + } + return (A) this; } - public A removeAllFromSubjects(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Subject item : items) {io.kubernetes.client.openapi.models.V1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(item);_visitables.get("subjects").remove(builder);if (this.subjects != null) {this.subjects.remove(builder);}} return (A)this; + + public A removeAllFromSubjects( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Subject item : items) { + io.kubernetes.client.openapi.models.V1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1SubjectBuilder(item); + _visitables.get("subjects").remove(builder); + if (this.subjects != null) { + this.subjects.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromSubjects(java.util.function.Predicate predicate) { + + public A removeMatchingFromSubjects( + java.util.function.Predicate + predicate) { if (subjects == null) return (A) this; final Iterator each = subjects.iterator(); final List visitables = _visitables.get("subjects"); @@ -175,140 +288,231 @@ public A removeMatchingFromSubjects(java.util.function.Predicate getSubjects() { return subjects != null ? build(subjects) : null; } + public java.util.List buildSubjects() { return subjects != null ? build(subjects) : null; } + public io.kubernetes.client.openapi.models.V1Subject buildSubject(java.lang.Integer index) { return this.subjects.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Subject buildFirstSubject() { return this.subjects.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Subject buildLastSubject() { return this.subjects.get(subjects.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Subject buildMatchingSubject(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1SubjectBuilder item: subjects) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Subject buildMatchingSubject( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1SubjectBuilder item : subjects) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingSubject(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1SubjectBuilder item: subjects) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingSubject( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1SubjectBuilder item : subjects) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withSubjects(java.util.List subjects) { - if (this.subjects != null) { _visitables.get("subjects").removeAll(this.subjects);} - if (subjects != null) {this.subjects = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Subject item : subjects){this.addToSubjects(item);}} else { this.subjects = null;} return (A) this; + if (this.subjects != null) { + _visitables.get("subjects").removeAll(this.subjects); + } + if (subjects != null) { + this.subjects = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Subject item : subjects) { + this.addToSubjects(item); + } + } else { + this.subjects = null; + } + return (A) this; } + public A withSubjects(io.kubernetes.client.openapi.models.V1Subject... subjects) { - if (this.subjects != null) {this.subjects.clear();} - if (subjects != null) {for (io.kubernetes.client.openapi.models.V1Subject item :subjects){ this.addToSubjects(item);}} return (A) this; + if (this.subjects != null) { + this.subjects.clear(); + } + if (subjects != null) { + for (io.kubernetes.client.openapi.models.V1Subject item : subjects) { + this.addToSubjects(item); + } + } + return (A) this; } + public java.lang.Boolean hasSubjects() { return subjects != null && !subjects.isEmpty(); } + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested addNewSubject() { return new io.kubernetes.client.openapi.models.V1RoleBindingFluentImpl.SubjectsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested addNewSubjectLike(io.kubernetes.client.openapi.models.V1Subject item) { - return new io.kubernetes.client.openapi.models.V1RoleBindingFluentImpl.SubjectsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested + addNewSubjectLike(io.kubernetes.client.openapi.models.V1Subject item) { + return new io.kubernetes.client.openapi.models.V1RoleBindingFluentImpl.SubjectsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested setNewSubjectLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item) { - return new io.kubernetes.client.openapi.models.V1RoleBindingFluentImpl.SubjectsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested + setNewSubjectLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item) { + return new io.kubernetes.client.openapi.models.V1RoleBindingFluentImpl.SubjectsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested editSubject(java.lang.Integer index) { - if (subjects.size() <= index) throw new RuntimeException("Can't edit subjects. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested editSubject( + java.lang.Integer index) { + if (subjects.size() <= index) + throw new RuntimeException("Can't edit subjects. Index exceeds size."); return setNewSubjectLike(index, buildSubject(index)); } - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested editFirstSubject() { - if (subjects.size() == 0) throw new RuntimeException("Can't edit first subjects. The list is empty."); + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested + editFirstSubject() { + if (subjects.size() == 0) + throw new RuntimeException("Can't edit first subjects. The list is empty."); return setNewSubjectLike(0, buildSubject(0)); } - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested editLastSubject() { + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested + editLastSubject() { int index = subjects.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last subjects. The list is empty."); return setNewSubjectLike(index, buildSubject(index)); } - public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested editMatchingSubject(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested + editMatchingSubject( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1RoleBindingFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1RoleBindingFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class RoleRefNestedImpl extends io.kubernetes.client.openapi.models.V1RoleRefFluentImpl> implements io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested,io.kubernetes.client.fluent.Nested{ + + public class RoleRefNestedImpl + extends io.kubernetes.client.openapi.models.V1RoleRefFluentImpl< + io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested> + implements io.kubernetes.client.openapi.models.V1RoleBindingFluent.RoleRefNested, + io.kubernetes.client.fluent.Nested { RoleRefNestedImpl(io.kubernetes.client.openapi.models.V1RoleRef item) { this.builder = new io.kubernetes.client.openapi.models.V1RoleRefBuilder(this, item); } + RoleRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1RoleRefBuilder(this); } + io.kubernetes.client.openapi.models.V1RoleRefBuilder builder; + public N and() { return (N) V1RoleBindingFluentImpl.this.withRoleRef(builder.build()); } + public N endRoleRef() { return and(); } - } - public class SubjectsNestedImpl extends io.kubernetes.client.openapi.models.V1SubjectFluentImpl> implements io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested,io.kubernetes.client.fluent.Nested{ - SubjectsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Subject item) { + + public class SubjectsNestedImpl + extends io.kubernetes.client.openapi.models.V1SubjectFluentImpl< + io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested> + implements io.kubernetes.client.openapi.models.V1RoleBindingFluent.SubjectsNested, + io.kubernetes.client.fluent.Nested { + SubjectsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Subject item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(this, item); } + SubjectsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1SubjectBuilder(this); } + io.kubernetes.client.openapi.models.V1SubjectBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1RoleBindingFluentImpl.this.setToSubjects(index,builder.build()); + return (N) V1RoleBindingFluentImpl.this.setToSubjects(index, builder.build()); } + public N endSubject() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingListBuilder.java index d1ed395c1c..bb6ac6345e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1RoleBindingListBuilder extends io.kubernetes.client.openapi.models.V1RoleBindingListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1RoleBindingListBuilder + extends io.kubernetes.client.openapi.models.V1RoleBindingListFluentImpl< + io.kubernetes.client.openapi.models.V1RoleBindingListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1RoleBindingList, + io.kubernetes.client.openapi.models.V1RoleBindingListBuilder> { public V1RoleBindingListBuilder() { this(false); } + public V1RoleBindingListBuilder(java.lang.Boolean validationEnabled) { this(new V1RoleBindingList(), validationEnabled); } - public V1RoleBindingListBuilder(io.kubernetes.client.openapi.models.V1RoleBindingListFluent fluent) { + + public V1RoleBindingListBuilder( + io.kubernetes.client.openapi.models.V1RoleBindingListFluent fluent) { this(fluent, false); } - public V1RoleBindingListBuilder(io.kubernetes.client.openapi.models.V1RoleBindingListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1RoleBindingListBuilder( + io.kubernetes.client.openapi.models.V1RoleBindingListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1RoleBindingList(), validationEnabled); } - public V1RoleBindingListBuilder(io.kubernetes.client.openapi.models.V1RoleBindingListFluent fluent,io.kubernetes.client.openapi.models.V1RoleBindingList instance) { + + public V1RoleBindingListBuilder( + io.kubernetes.client.openapi.models.V1RoleBindingListFluent fluent, + io.kubernetes.client.openapi.models.V1RoleBindingList instance) { this(fluent, instance, false); } - public V1RoleBindingListBuilder(io.kubernetes.client.openapi.models.V1RoleBindingListFluent fluent,io.kubernetes.client.openapi.models.V1RoleBindingList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1RoleBindingListBuilder( + io.kubernetes.client.openapi.models.V1RoleBindingListFluent fluent, + io.kubernetes.client.openapi.models.V1RoleBindingList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1RoleBindingListBuilder(io.kubernetes.client.openapi.models.V1RoleBindin fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1RoleBindingListBuilder(io.kubernetes.client.openapi.models.V1RoleBindingList instance) { - this(instance,false); + this(instance, false); } - public V1RoleBindingListBuilder(io.kubernetes.client.openapi.models.V1RoleBindingList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1RoleBindingListBuilder( + io.kubernetes.client.openapi.models.V1RoleBindingList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1RoleBindingListBuilder(io.kubernetes.client.openapi.models.V1RoleBindin this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1RoleBindingListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1RoleBindingList build() { V1RoleBindingList buildable = new V1RoleBindingList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1RoleBindingList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1RoleBindingListBuilder that = (V1RoleBindingListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingListFluent.java index 4347ae8151..bc5829e514 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingListFluent.java @@ -1,95 +1,155 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1RoleBindingListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1RoleBindingListFluent< + A extends io.kubernetes.client.openapi.models.V1RoleBindingListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RoleBinding item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RoleBinding item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RoleBinding item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RoleBinding item); + public A addToItems(io.kubernetes.client.openapi.models.V1RoleBinding... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1RoleBinding... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1RoleBinding buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1RoleBinding buildFirstItem(); + public io.kubernetes.client.openapi.models.V1RoleBinding buildLastItem(); - public io.kubernetes.client.openapi.models.V1RoleBinding buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1RoleBinding buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1RoleBinding... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1RoleBinding item); - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RoleBinding item); - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1RoleBinding item); + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RoleBinding item); + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1RoleBindingFluent>{ + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1RoleBindingFluent< + io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingListFluentImpl.java index ae98f0199f..6166930e4c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBindingListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1RoleBindingListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1RoleBindingListFluent{ - public V1RoleBindingListFluentImpl() { - } - public V1RoleBindingListFluentImpl(io.kubernetes.client.openapi.models.V1RoleBindingList instance) { + +/** Generated */ +public class V1RoleBindingListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1RoleBindingListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1RoleBindingListFluent { + public V1RoleBindingListFluentImpl() {} + + public V1RoleBindingListFluentImpl( + io.kubernetes.client.openapi.models.V1RoleBindingList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1RoleBindingListFluentImpl(io.kubernetes.client.openapi.models.V1RoleBin this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RoleBinding item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder = new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RoleBinding item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder = + new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RoleBinding item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder = new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RoleBinding item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder = + new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1RoleBinding... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1RoleBinding item : items) {io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder = new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1RoleBinding item : items) { + io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder = + new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1RoleBinding item : items) {io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder = new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1RoleBinding item : items) { + io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder = + new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1RoleBinding... items) { - for (io.kubernetes.client.openapi.models.V1RoleBinding item : items) {io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder = new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1RoleBinding item : items) { + io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder = + new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1RoleBinding item : items) {io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder = new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1RoleBinding item : items) { + io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder = + new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder = each.next(); @@ -87,174 +159,277 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1RoleBinding buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1RoleBinding buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1RoleBinding buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1RoleBinding buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1RoleBindingBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1RoleBinding buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1RoleBindingBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1RoleBindingBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1RoleBindingBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1RoleBinding item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1RoleBinding item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1RoleBinding... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1RoleBinding item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1RoleBinding item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1RoleBindingListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1RoleBinding item) { - return new io.kubernetes.client.openapi.models.V1RoleBindingListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1RoleBinding item) { + return new io.kubernetes.client.openapi.models.V1RoleBindingListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RoleBinding item) { - return new io.kubernetes.client.openapi.models.V1RoleBindingListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RoleBinding item) { + return new io.kubernetes.client.openapi.models.V1RoleBindingListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1RoleBindingListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1RoleBindingListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1RoleBindingListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1RoleBindingListFluentImpl that = (V1RoleBindingListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1RoleBindingFluentImpl> implements io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RoleBinding item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1RoleBindingFluentImpl< + io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1RoleBindingListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RoleBinding item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1RoleBindingBuilder(this); } + io.kubernetes.client.openapi.models.V1RoleBindingBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1RoleBindingListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1RoleBindingListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1RoleBindingListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1RoleBindingListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBuilder.java index 8b1edeb73b..a49d99f505 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1RoleBuilder extends io.kubernetes.client.openapi.models.V1RoleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1RoleBuilder + extends io.kubernetes.client.openapi.models.V1RoleFluentImpl< + io.kubernetes.client.openapi.models.V1RoleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Role, + io.kubernetes.client.openapi.models.V1RoleBuilder> { public V1RoleBuilder() { this(false); } + public V1RoleBuilder(java.lang.Boolean validationEnabled) { this(new V1Role(), validationEnabled); } + public V1RoleBuilder(io.kubernetes.client.openapi.models.V1RoleFluent fluent) { this(fluent, false); } - public V1RoleBuilder(io.kubernetes.client.openapi.models.V1RoleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1RoleBuilder( + io.kubernetes.client.openapi.models.V1RoleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Role(), validationEnabled); } - public V1RoleBuilder(io.kubernetes.client.openapi.models.V1RoleFluent fluent,io.kubernetes.client.openapi.models.V1Role instance) { + + public V1RoleBuilder( + io.kubernetes.client.openapi.models.V1RoleFluent fluent, + io.kubernetes.client.openapi.models.V1Role instance) { this(fluent, instance, false); } - public V1RoleBuilder(io.kubernetes.client.openapi.models.V1RoleFluent fluent,io.kubernetes.client.openapi.models.V1Role instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1RoleBuilder( + io.kubernetes.client.openapi.models.V1RoleFluent fluent, + io.kubernetes.client.openapi.models.V1Role instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +55,16 @@ public V1RoleBuilder(io.kubernetes.client.openapi.models.V1RoleFluent fluent, fluent.withRules(instance.getRules()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1RoleBuilder(io.kubernetes.client.openapi.models.V1Role instance) { - this(instance,false); + this(instance, false); } - public V1RoleBuilder(io.kubernetes.client.openapi.models.V1Role instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1RoleBuilder( + io.kubernetes.client.openapi.models.V1Role instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +73,12 @@ public V1RoleBuilder(io.kubernetes.client.openapi.models.V1Role instance,java.la this.withRules(instance.getRules()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1RoleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Role build() { V1Role buildable = new V1Role(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +87,23 @@ public io.kubernetes.client.openapi.models.V1Role build() { buildable.setRules(fluent.getRules()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1RoleBuilder that = (V1RoleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleFluent.java index 505e34b0fd..c061ccc882 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleFluent.java @@ -1,95 +1,150 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1RoleFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1RoleFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item); - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item); + + public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public A addToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item); + + public A setToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item); + public A addToRules(io.kubernetes.client.openapi.models.V1PolicyRule... items); - public A addAllToRules(java.util.Collection items); + + public A addAllToRules( + java.util.Collection items); + public A removeFromRules(io.kubernetes.client.openapi.models.V1PolicyRule... items); - public A removeAllFromRules(java.util.Collection items); - public A removeMatchingFromRules(java.util.function.Predicate predicate); - + + public A removeAllFromRules( + java.util.Collection items); + + public A removeMatchingFromRules( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildRules instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getRules(); + public java.util.List buildRules(); + public io.kubernetes.client.openapi.models.V1PolicyRule buildRule(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1PolicyRule buildFirstRule(); + public io.kubernetes.client.openapi.models.V1PolicyRule buildLastRule(); - public io.kubernetes.client.openapi.models.V1PolicyRule buildMatchingRule(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1PolicyRule buildMatchingRule( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate + predicate); + public A withRules(java.util.List rules); + public A withRules(io.kubernetes.client.openapi.models.V1PolicyRule... rules); + public java.lang.Boolean hasRules(); + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested addNewRule(); - public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1PolicyRule item); - public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item); - public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested editRule(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested addNewRuleLike( + io.kubernetes.client.openapi.models.V1PolicyRule item); + + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested setNewRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item); + + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested editRule( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested editFirstRule(); + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested editLastRule(); - public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested editMatchingRule( + java.util.function.Predicate + predicate); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface RulesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PolicyRuleFluent>{ + + public interface RulesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PolicyRuleFluent< + io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested> { public N and(); + public N endRule(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleFluentImpl.java index ee46970e2a..6c7b9ccb6c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleFluentImpl.java @@ -1,25 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1RoleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1RoleFluent{ - public V1RoleFluentImpl() { - } +/** Generated */ +public class V1RoleFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1RoleFluent { + public V1RoleFluentImpl() {} + public V1RoleFluentImpl(io.kubernetes.client.openapi.models.V1Role instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,106 +29,194 @@ public V1RoleFluentImpl(io.kubernetes.client.openapi.models.V1Role instance) { this.withMetadata(instance.getMetadata()); this.withRules(instance.getRules()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private java.util.ArrayList rules; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1RoleFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1RoleFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item);_visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder);this.rules.add(index >= 0 ? index : rules.size(), builder); return (A)this; + + public A addToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); + _visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder); + this.rules.add(index >= 0 ? index : rules.size(), builder); + return (A) this; } - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); - if (index < 0 || index >= _visitables.get("rules").size()) { _visitables.get("rules").add(builder); } else { _visitables.get("rules").set(index, builder);} - if (index < 0 || index >= rules.size()) { rules.add(builder); } else { rules.set(index, builder);} - return (A)this; + + public A setToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); + if (index < 0 || index >= _visitables.get("rules").size()) { + _visitables.get("rules").add(builder); + } else { + _visitables.get("rules").set(index, builder); + } + if (index < 0 || index >= rules.size()) { + rules.add(builder); + } else { + rules.set(index, builder); + } + return (A) this; } + public A addToRules(io.kubernetes.client.openapi.models.V1PolicyRule... items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) {io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + if (this.rules == null) { + this.rules = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) { + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } - public A addAllToRules(java.util.Collection items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) {io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + + public A addAllToRules( + java.util.Collection items) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) { + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } + public A removeFromRules(io.kubernetes.client.openapi.models.V1PolicyRule... items) { - for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) {io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) { + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeAllFromRules(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) {io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + + public A removeAllFromRules( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PolicyRule item : items) { + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromRules(java.util.function.Predicate predicate) { + + public A removeMatchingFromRules( + java.util.function.Predicate + predicate) { if (rules == null) return (A) this; final Iterator each = rules.iterator(); final List visitables = _visitables.get("rules"); @@ -138,123 +227,198 @@ public A removeMatchingFromRules(java.util.function.Predicate getRules() { return rules != null ? build(rules) : null; } + public java.util.List buildRules() { return rules != null ? build(rules) : null; } + public io.kubernetes.client.openapi.models.V1PolicyRule buildRule(java.lang.Integer index) { return this.rules.get(index).build(); } + public io.kubernetes.client.openapi.models.V1PolicyRule buildFirstRule() { return this.rules.get(0).build(); } + public io.kubernetes.client.openapi.models.V1PolicyRule buildLastRule() { return this.rules.get(rules.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PolicyRule buildMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PolicyRuleBuilder item: rules) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PolicyRule buildMatchingRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PolicyRuleBuilder item : rules) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PolicyRuleBuilder item: rules) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1PolicyRuleBuilder item : rules) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withRules(java.util.List rules) { - if (this.rules != null) { _visitables.get("rules").removeAll(this.rules);} - if (rules != null) {this.rules = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PolicyRule item : rules){this.addToRules(item);}} else { this.rules = null;} return (A) this; + if (this.rules != null) { + _visitables.get("rules").removeAll(this.rules); + } + if (rules != null) { + this.rules = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PolicyRule item : rules) { + this.addToRules(item); + } + } else { + this.rules = null; + } + return (A) this; } + public A withRules(io.kubernetes.client.openapi.models.V1PolicyRule... rules) { - if (this.rules != null) {this.rules.clear();} - if (rules != null) {for (io.kubernetes.client.openapi.models.V1PolicyRule item :rules){ this.addToRules(item);}} return (A) this; + if (this.rules != null) { + this.rules.clear(); + } + if (rules != null) { + for (io.kubernetes.client.openapi.models.V1PolicyRule item : rules) { + this.addToRules(item); + } + } + return (A) this; } + public java.lang.Boolean hasRules() { return rules != null && !rules.isEmpty(); } + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested addNewRule() { return new io.kubernetes.client.openapi.models.V1RoleFluentImpl.RulesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1PolicyRule item) { + + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested addNewRuleLike( + io.kubernetes.client.openapi.models.V1PolicyRule item) { return new io.kubernetes.client.openapi.models.V1RoleFluentImpl.RulesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item) { + + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested setNewRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item) { return new io.kubernetes.client.openapi.models.V1RoleFluentImpl.RulesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested editRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested editRule( + java.lang.Integer index) { if (rules.size() <= index) throw new RuntimeException("Can't edit rules. Index exceeds size."); return setNewRuleLike(index, buildRule(index)); } + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested editFirstRule() { if (rules.size() == 0) throw new RuntimeException("Can't edit first rules. The list is empty."); return setNewRuleLike(0, buildRule(0)); } + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested editLastRule() { int index = rules.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last rules. The list is empty."); return setNewRuleLike(index, buildRule(index)); } - public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested editMatchingRule( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1RoleFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1RoleFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class RulesNestedImpl extends io.kubernetes.client.openapi.models.V1PolicyRuleFluentImpl> implements io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested,io.kubernetes.client.fluent.Nested{ - RulesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PolicyRule item) { + + public class RulesNestedImpl + extends io.kubernetes.client.openapi.models.V1PolicyRuleFluentImpl< + io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested> + implements io.kubernetes.client.openapi.models.V1RoleFluent.RulesNested, + io.kubernetes.client.fluent.Nested { + RulesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PolicyRule item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(this, item); } + RulesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PolicyRuleBuilder(this); } + io.kubernetes.client.openapi.models.V1PolicyRuleBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1RoleFluentImpl.this.setToRules(index,builder.build()); + return (N) V1RoleFluentImpl.this.setToRules(index, builder.build()); } + public N endRule() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleListBuilder.java index 1eb5cbbcb7..f262ef47b5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleListBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1RoleListBuilder extends io.kubernetes.client.openapi.models.V1RoleListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1RoleListBuilder + extends io.kubernetes.client.openapi.models.V1RoleListFluentImpl< + io.kubernetes.client.openapi.models.V1RoleListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1RoleList, + io.kubernetes.client.openapi.models.V1RoleListBuilder> { public V1RoleListBuilder() { this(false); } + public V1RoleListBuilder(java.lang.Boolean validationEnabled) { this(new V1RoleList(), validationEnabled); } + public V1RoleListBuilder(io.kubernetes.client.openapi.models.V1RoleListFluent fluent) { this(fluent, false); } - public V1RoleListBuilder(io.kubernetes.client.openapi.models.V1RoleListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1RoleListBuilder( + io.kubernetes.client.openapi.models.V1RoleListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1RoleList(), validationEnabled); } - public V1RoleListBuilder(io.kubernetes.client.openapi.models.V1RoleListFluent fluent,io.kubernetes.client.openapi.models.V1RoleList instance) { + + public V1RoleListBuilder( + io.kubernetes.client.openapi.models.V1RoleListFluent fluent, + io.kubernetes.client.openapi.models.V1RoleList instance) { this(fluent, instance, false); } - public V1RoleListBuilder(io.kubernetes.client.openapi.models.V1RoleListFluent fluent,io.kubernetes.client.openapi.models.V1RoleList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1RoleListBuilder( + io.kubernetes.client.openapi.models.V1RoleListFluent fluent, + io.kubernetes.client.openapi.models.V1RoleList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +55,17 @@ public V1RoleListBuilder(io.kubernetes.client.openapi.models.V1RoleListFluent fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1RoleListBuilder(io.kubernetes.client.openapi.models.V1RoleList instance) { - this(instance,false); + this(instance, false); } - public V1RoleListBuilder(io.kubernetes.client.openapi.models.V1RoleList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1RoleListBuilder( + io.kubernetes.client.openapi.models.V1RoleList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +74,12 @@ public V1RoleListBuilder(io.kubernetes.client.openapi.models.V1RoleList instance this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1RoleListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1RoleList build() { V1RoleList buildable = new V1RoleList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1RoleList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1RoleListBuilder that = (V1RoleListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleListFluent.java index 1a238bbc46..2ebd17d4a5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleListFluent.java @@ -1,95 +1,143 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1RoleListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1RoleListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Role item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Role item); + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Role item); + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Role item); + public A addToItems(io.kubernetes.client.openapi.models.V1Role... items); + public A addAllToItems(java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1Role... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1Role buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Role buildFirstItem(); + public io.kubernetes.client.openapi.models.V1Role buildLastItem(); - public io.kubernetes.client.openapi.models.V1Role buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Role buildMatchingItem( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1Role... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Role item); - public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Role item); - public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Role item); + + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Role item); + + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1RoleFluent>{ + + public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1RoleFluent< + io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleListFluentImpl.java index 70a441e0cd..73ee3734da 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleListFluentImpl.java @@ -1,25 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1RoleListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1RoleListFluent{ - public V1RoleListFluentImpl() { - } +/** Generated */ +public class V1RoleListFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1RoleListFluent { + public V1RoleListFluentImpl() {} + public V1RoleListFluentImpl(io.kubernetes.client.openapi.models.V1RoleList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +29,115 @@ public V1RoleListFluentImpl(io.kubernetes.client.openapi.models.V1RoleList insta this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Role item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1RoleBuilder builder = new io.kubernetes.client.openapi.models.V1RoleBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Role item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1RoleBuilder builder = + new io.kubernetes.client.openapi.models.V1RoleBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Role item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1RoleBuilder builder = new io.kubernetes.client.openapi.models.V1RoleBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Role item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1RoleBuilder builder = + new io.kubernetes.client.openapi.models.V1RoleBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1Role... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Role item : items) {io.kubernetes.client.openapi.models.V1RoleBuilder builder = new io.kubernetes.client.openapi.models.V1RoleBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Role item : items) { + io.kubernetes.client.openapi.models.V1RoleBuilder builder = + new io.kubernetes.client.openapi.models.V1RoleBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Role item : items) {io.kubernetes.client.openapi.models.V1RoleBuilder builder = new io.kubernetes.client.openapi.models.V1RoleBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Role item : items) { + io.kubernetes.client.openapi.models.V1RoleBuilder builder = + new io.kubernetes.client.openapi.models.V1RoleBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1Role... items) { - for (io.kubernetes.client.openapi.models.V1Role item : items) {io.kubernetes.client.openapi.models.V1RoleBuilder builder = new io.kubernetes.client.openapi.models.V1RoleBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Role item : items) { + io.kubernetes.client.openapi.models.V1RoleBuilder builder = + new io.kubernetes.client.openapi.models.V1RoleBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Role item : items) {io.kubernetes.client.openapi.models.V1RoleBuilder builder = new io.kubernetes.client.openapi.models.V1RoleBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Role item : items) { + io.kubernetes.client.openapi.models.V1RoleBuilder builder = + new io.kubernetes.client.openapi.models.V1RoleBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +148,267 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1Role buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Role buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Role buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Role buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1RoleBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Role buildMatchingItem( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1RoleBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1RoleBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1RoleBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Role item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Role item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1Role... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1Role item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1Role item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1RoleListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Role item) { + + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Role item) { return new io.kubernetes.client.openapi.models.V1RoleListFluentImpl.ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Role item) { - return new io.kubernetes.client.openapi.models.V1RoleListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Role item) { + return new io.kubernetes.client.openapi.models.V1RoleListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate) { int index = -1; - for (int i=0;i withNewMetadata() { return new io.kubernetes.client.openapi.models.V1RoleListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + + public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ListMeta item) { return new io.kubernetes.client.openapi.models.V1RoleListFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1RoleListFluentImpl that = (V1RoleListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1RoleFluentImpl> implements io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Role item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1RoleFluentImpl< + io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1RoleListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Role item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1RoleBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1RoleBuilder(this); } + io.kubernetes.client.openapi.models.V1RoleBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1RoleListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1RoleListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1RoleListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1RoleListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleRefBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleRefBuilder.java index 47d778274c..3352d4c6d7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleRefBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleRefBuilder.java @@ -1,49 +1,80 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1RoleRefBuilder extends io.kubernetes.client.openapi.models.V1RoleRefFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1RoleRefBuilder + extends io.kubernetes.client.openapi.models.V1RoleRefFluentImpl< + io.kubernetes.client.openapi.models.V1RoleRefBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1RoleRef, + io.kubernetes.client.openapi.models.V1RoleRefBuilder> { public V1RoleRefBuilder() { this(false); } + public V1RoleRefBuilder(java.lang.Boolean validationEnabled) { this(new V1RoleRef(), validationEnabled); } + public V1RoleRefBuilder(io.kubernetes.client.openapi.models.V1RoleRefFluent fluent) { this(fluent, false); } - public V1RoleRefBuilder(io.kubernetes.client.openapi.models.V1RoleRefFluent fluent,java.lang.Boolean validationEnabled) { + + public V1RoleRefBuilder( + io.kubernetes.client.openapi.models.V1RoleRefFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1RoleRef(), validationEnabled); } - public V1RoleRefBuilder(io.kubernetes.client.openapi.models.V1RoleRefFluent fluent,io.kubernetes.client.openapi.models.V1RoleRef instance) { + + public V1RoleRefBuilder( + io.kubernetes.client.openapi.models.V1RoleRefFluent fluent, + io.kubernetes.client.openapi.models.V1RoleRef instance) { this(fluent, instance, false); } - public V1RoleRefBuilder(io.kubernetes.client.openapi.models.V1RoleRefFluent fluent,io.kubernetes.client.openapi.models.V1RoleRef instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1RoleRefBuilder( + io.kubernetes.client.openapi.models.V1RoleRefFluent fluent, + io.kubernetes.client.openapi.models.V1RoleRef instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiGroup(instance.getApiGroup()); fluent.withKind(instance.getKind()); fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1RoleRefBuilder(io.kubernetes.client.openapi.models.V1RoleRef instance) { - this(instance,false); + this(instance, false); } - public V1RoleRefBuilder(io.kubernetes.client.openapi.models.V1RoleRef instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1RoleRefBuilder( + io.kubernetes.client.openapi.models.V1RoleRef instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiGroup(instance.getApiGroup()); this.withKind(instance.getKind()); this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1RoleRefFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1RoleRef build() { V1RoleRef buildable = new V1RoleRef(); buildable.setApiGroup(fluent.getApiGroup()); @@ -51,18 +82,23 @@ public io.kubernetes.client.openapi.models.V1RoleRef build() { buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1RoleRefBuilder that = (V1RoleRefBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleRefFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleRefFluent.java index f18e7cdac2..70be7ef0b3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleRefFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleRefFluent.java @@ -1,41 +1,47 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1RoleRefFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1RoleRefFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiGroup(); + public A withApiGroup(java.lang.String apiGroup); + public java.lang.Boolean hasApiGroup(); - - /** - * Method is deprecated. use withApiGroup instead. - */ + + /** Method is deprecated. use withApiGroup instead. */ @java.lang.Deprecated public A withNewApiGroup(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleRefFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleRefFluentImpl.java index 71edaef66e..7693aaaa5b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleRefFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RoleRefFluentImpl.java @@ -1,90 +1,103 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1RoleRefFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1RoleRefFluent{ - public V1RoleRefFluentImpl() { - } +/** Generated */ +public class V1RoleRefFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1RoleRefFluent { + public V1RoleRefFluentImpl() {} + public V1RoleRefFluentImpl(io.kubernetes.client.openapi.models.V1RoleRef instance) { this.withApiGroup(instance.getApiGroup()); this.withKind(instance.getKind()); this.withName(instance.getName()); - } + private java.lang.String apiGroup; private java.lang.String kind; private java.lang.String name; + public java.lang.String getApiGroup() { return this.apiGroup; } + public A withApiGroup(java.lang.String apiGroup) { - this.apiGroup=apiGroup; return (A) this; + this.apiGroup = apiGroup; + return (A) this; } + public java.lang.Boolean hasApiGroup() { return this.apiGroup != null; } - - /** - * Method is deprecated. use withApiGroup instead. - */ + + /** Method is deprecated. use withApiGroup instead. */ @java.lang.Deprecated public A withNewApiGroup(java.lang.String original) { - return (A)withApiGroup(new String(original)); + return (A) withApiGroup(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1RoleRefFluentImpl that = (V1RoleRefFluentImpl) o; - if (apiGroup != null ? !apiGroup.equals(that.apiGroup) :that.apiGroup != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (apiGroup != null ? !apiGroup.equals(that.apiGroup) : that.apiGroup != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiGroup, kind, name, super.hashCode()); + return java.util.Objects.hash(apiGroup, kind, name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDaemonSetBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDaemonSetBuilder.java index 040358356a..58dd519814 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDaemonSetBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDaemonSetBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1RollingUpdateDaemonSetBuilder extends io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1RollingUpdateDaemonSetBuilder + extends io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluentImpl< + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet, + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetBuilder> { public V1RollingUpdateDaemonSetBuilder() { this(false); } + public V1RollingUpdateDaemonSetBuilder(java.lang.Boolean validationEnabled) { this(new V1RollingUpdateDaemonSet(), validationEnabled); } - public V1RollingUpdateDaemonSetBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent fluent) { + + public V1RollingUpdateDaemonSetBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent fluent) { this(fluent, false); } - public V1RollingUpdateDaemonSetBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent fluent,java.lang.Boolean validationEnabled) { + + public V1RollingUpdateDaemonSetBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1RollingUpdateDaemonSet(), validationEnabled); } - public V1RollingUpdateDaemonSetBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent fluent,io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet instance) { + + public V1RollingUpdateDaemonSetBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent fluent, + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet instance) { this(fluent, instance, false); } - public V1RollingUpdateDaemonSetBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent fluent,io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1RollingUpdateDaemonSetBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent fluent, + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMaxSurge(instance.getMaxSurge()); fluent.withMaxUnavailable(instance.getMaxUnavailable()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1RollingUpdateDaemonSetBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet instance) { - this(instance,false); + + public V1RollingUpdateDaemonSetBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet instance) { + this(instance, false); } - public V1RollingUpdateDaemonSetBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1RollingUpdateDaemonSetBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMaxSurge(instance.getMaxSurge()); this.withMaxUnavailable(instance.getMaxUnavailable()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet build() { V1RollingUpdateDaemonSet buildable = new V1RollingUpdateDaemonSet(); buildable.setMaxSurge(fluent.getMaxSurge()); buildable.setMaxUnavailable(fluent.getMaxUnavailable()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1RollingUpdateDaemonSetBuilder that = (V1RollingUpdateDaemonSetBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDaemonSetFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDaemonSetFluent.java index ae4677afeb..f6ab33b57d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDaemonSetFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDaemonSetFluent.java @@ -1,24 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.custom.IntOrString; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1RollingUpdateDaemonSetFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1RollingUpdateDaemonSetFluent< + A extends io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent> + extends io.kubernetes.client.fluent.Fluent { public io.kubernetes.client.custom.IntOrString getMaxSurge(); + public A withMaxSurge(io.kubernetes.client.custom.IntOrString maxSurge); + public java.lang.Boolean hasMaxSurge(); + public A withNewMaxSurge(int value); + public A withNewMaxSurge(java.lang.String value); + public io.kubernetes.client.custom.IntOrString getMaxUnavailable(); + public A withMaxUnavailable(io.kubernetes.client.custom.IntOrString maxUnavailable); + public java.lang.Boolean hasMaxUnavailable(); + public A withNewMaxUnavailable(int value); + public A withNewMaxUnavailable(java.lang.String value); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDaemonSetFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDaemonSetFluentImpl.java index 28f2718855..9810855d4d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDaemonSetFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDaemonSetFluentImpl.java @@ -1,65 +1,90 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; import io.kubernetes.client.custom.IntOrString; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1RollingUpdateDaemonSetFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent{ - public V1RollingUpdateDaemonSetFluentImpl() { - } - public V1RollingUpdateDaemonSetFluentImpl(io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet instance) { + +/** Generated */ +public class V1RollingUpdateDaemonSetFluentImpl< + A extends io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSetFluent { + public V1RollingUpdateDaemonSetFluentImpl() {} + + public V1RollingUpdateDaemonSetFluentImpl( + io.kubernetes.client.openapi.models.V1RollingUpdateDaemonSet instance) { this.withMaxSurge(instance.getMaxSurge()); this.withMaxUnavailable(instance.getMaxUnavailable()); - } + private io.kubernetes.client.custom.IntOrString maxSurge; private io.kubernetes.client.custom.IntOrString maxUnavailable; + public io.kubernetes.client.custom.IntOrString getMaxSurge() { return this.maxSurge; } + public A withMaxSurge(io.kubernetes.client.custom.IntOrString maxSurge) { - this.maxSurge=maxSurge; return (A) this; + this.maxSurge = maxSurge; + return (A) this; } + public java.lang.Boolean hasMaxSurge() { return this.maxSurge != null; } + public A withNewMaxSurge(int value) { - return (A)withMaxSurge(new IntOrString(value)); + return (A) withMaxSurge(new IntOrString(value)); } + public A withNewMaxSurge(java.lang.String value) { - return (A)withMaxSurge(new IntOrString(value)); + return (A) withMaxSurge(new IntOrString(value)); } + public io.kubernetes.client.custom.IntOrString getMaxUnavailable() { return this.maxUnavailable; } + public A withMaxUnavailable(io.kubernetes.client.custom.IntOrString maxUnavailable) { - this.maxUnavailable=maxUnavailable; return (A) this; + this.maxUnavailable = maxUnavailable; + return (A) this; } + public java.lang.Boolean hasMaxUnavailable() { return this.maxUnavailable != null; } + public A withNewMaxUnavailable(int value) { - return (A)withMaxUnavailable(new IntOrString(value)); + return (A) withMaxUnavailable(new IntOrString(value)); } + public A withNewMaxUnavailable(java.lang.String value) { - return (A)withMaxUnavailable(new IntOrString(value)); + return (A) withMaxUnavailable(new IntOrString(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1RollingUpdateDaemonSetFluentImpl that = (V1RollingUpdateDaemonSetFluentImpl) o; - if (maxSurge != null ? !maxSurge.equals(that.maxSurge) :that.maxSurge != null) return false; - if (maxUnavailable != null ? !maxUnavailable.equals(that.maxUnavailable) :that.maxUnavailable != null) return false; + if (maxSurge != null ? !maxSurge.equals(that.maxSurge) : that.maxSurge != null) return false; + if (maxUnavailable != null + ? !maxUnavailable.equals(that.maxUnavailable) + : that.maxUnavailable != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(maxSurge, maxUnavailable, super.hashCode()); + return java.util.Objects.hash(maxSurge, maxUnavailable, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDeploymentBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDeploymentBuilder.java index b2cdbbee73..af0ecb7be9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDeploymentBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDeploymentBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1RollingUpdateDeploymentBuilder extends io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1RollingUpdateDeploymentBuilder + extends io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluentImpl< + io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1RollingUpdateDeployment, + io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentBuilder> { public V1RollingUpdateDeploymentBuilder() { this(false); } + public V1RollingUpdateDeploymentBuilder(java.lang.Boolean validationEnabled) { this(new V1RollingUpdateDeployment(), validationEnabled); } - public V1RollingUpdateDeploymentBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent fluent) { + + public V1RollingUpdateDeploymentBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent fluent) { this(fluent, false); } - public V1RollingUpdateDeploymentBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent fluent,java.lang.Boolean validationEnabled) { + + public V1RollingUpdateDeploymentBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1RollingUpdateDeployment(), validationEnabled); } - public V1RollingUpdateDeploymentBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent fluent,io.kubernetes.client.openapi.models.V1RollingUpdateDeployment instance) { + + public V1RollingUpdateDeploymentBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent fluent, + io.kubernetes.client.openapi.models.V1RollingUpdateDeployment instance) { this(fluent, instance, false); } - public V1RollingUpdateDeploymentBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent fluent,io.kubernetes.client.openapi.models.V1RollingUpdateDeployment instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1RollingUpdateDeploymentBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent fluent, + io.kubernetes.client.openapi.models.V1RollingUpdateDeployment instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMaxSurge(instance.getMaxSurge()); fluent.withMaxUnavailable(instance.getMaxUnavailable()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1RollingUpdateDeploymentBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateDeployment instance) { - this(instance,false); + + public V1RollingUpdateDeploymentBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateDeployment instance) { + this(instance, false); } - public V1RollingUpdateDeploymentBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateDeployment instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1RollingUpdateDeploymentBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateDeployment instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMaxSurge(instance.getMaxSurge()); this.withMaxUnavailable(instance.getMaxUnavailable()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1RollingUpdateDeployment build() { V1RollingUpdateDeployment buildable = new V1RollingUpdateDeployment(); buildable.setMaxSurge(fluent.getMaxSurge()); buildable.setMaxUnavailable(fluent.getMaxUnavailable()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1RollingUpdateDeploymentBuilder that = (V1RollingUpdateDeploymentBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDeploymentFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDeploymentFluent.java index 50e973f55d..3284a62433 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDeploymentFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDeploymentFluent.java @@ -1,24 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.custom.IntOrString; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1RollingUpdateDeploymentFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1RollingUpdateDeploymentFluent< + A extends io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent> + extends io.kubernetes.client.fluent.Fluent { public io.kubernetes.client.custom.IntOrString getMaxSurge(); + public A withMaxSurge(io.kubernetes.client.custom.IntOrString maxSurge); + public java.lang.Boolean hasMaxSurge(); + public A withNewMaxSurge(int value); + public A withNewMaxSurge(java.lang.String value); + public io.kubernetes.client.custom.IntOrString getMaxUnavailable(); + public A withMaxUnavailable(io.kubernetes.client.custom.IntOrString maxUnavailable); + public java.lang.Boolean hasMaxUnavailable(); + public A withNewMaxUnavailable(int value); + public A withNewMaxUnavailable(java.lang.String value); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDeploymentFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDeploymentFluentImpl.java index 3aa2c24a27..83c90441fb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDeploymentFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateDeploymentFluentImpl.java @@ -1,65 +1,90 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; import io.kubernetes.client.custom.IntOrString; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1RollingUpdateDeploymentFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent{ - public V1RollingUpdateDeploymentFluentImpl() { - } - public V1RollingUpdateDeploymentFluentImpl(io.kubernetes.client.openapi.models.V1RollingUpdateDeployment instance) { + +/** Generated */ +public class V1RollingUpdateDeploymentFluentImpl< + A extends io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1RollingUpdateDeploymentFluent { + public V1RollingUpdateDeploymentFluentImpl() {} + + public V1RollingUpdateDeploymentFluentImpl( + io.kubernetes.client.openapi.models.V1RollingUpdateDeployment instance) { this.withMaxSurge(instance.getMaxSurge()); this.withMaxUnavailable(instance.getMaxUnavailable()); - } + private io.kubernetes.client.custom.IntOrString maxSurge; private io.kubernetes.client.custom.IntOrString maxUnavailable; + public io.kubernetes.client.custom.IntOrString getMaxSurge() { return this.maxSurge; } + public A withMaxSurge(io.kubernetes.client.custom.IntOrString maxSurge) { - this.maxSurge=maxSurge; return (A) this; + this.maxSurge = maxSurge; + return (A) this; } + public java.lang.Boolean hasMaxSurge() { return this.maxSurge != null; } + public A withNewMaxSurge(int value) { - return (A)withMaxSurge(new IntOrString(value)); + return (A) withMaxSurge(new IntOrString(value)); } + public A withNewMaxSurge(java.lang.String value) { - return (A)withMaxSurge(new IntOrString(value)); + return (A) withMaxSurge(new IntOrString(value)); } + public io.kubernetes.client.custom.IntOrString getMaxUnavailable() { return this.maxUnavailable; } + public A withMaxUnavailable(io.kubernetes.client.custom.IntOrString maxUnavailable) { - this.maxUnavailable=maxUnavailable; return (A) this; + this.maxUnavailable = maxUnavailable; + return (A) this; } + public java.lang.Boolean hasMaxUnavailable() { return this.maxUnavailable != null; } + public A withNewMaxUnavailable(int value) { - return (A)withMaxUnavailable(new IntOrString(value)); + return (A) withMaxUnavailable(new IntOrString(value)); } + public A withNewMaxUnavailable(java.lang.String value) { - return (A)withMaxUnavailable(new IntOrString(value)); + return (A) withMaxUnavailable(new IntOrString(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1RollingUpdateDeploymentFluentImpl that = (V1RollingUpdateDeploymentFluentImpl) o; - if (maxSurge != null ? !maxSurge.equals(that.maxSurge) :that.maxSurge != null) return false; - if (maxUnavailable != null ? !maxUnavailable.equals(that.maxUnavailable) :that.maxUnavailable != null) return false; + if (maxSurge != null ? !maxSurge.equals(that.maxSurge) : that.maxSurge != null) return false; + if (maxUnavailable != null + ? !maxUnavailable.equals(that.maxUnavailable) + : that.maxUnavailable != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(maxSurge, maxUnavailable, super.hashCode()); + return java.util.Objects.hash(maxSurge, maxUnavailable, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateStatefulSetStrategyBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateStatefulSetStrategyBuilder.java index b8ce551bb8..f3efdf879b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateStatefulSetStrategyBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateStatefulSetStrategyBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1RollingUpdateStatefulSetStrategyBuilder extends io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1RollingUpdateStatefulSetStrategyBuilder + extends io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluentImpl< + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy, + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyBuilder> { public V1RollingUpdateStatefulSetStrategyBuilder() { this(false); } + public V1RollingUpdateStatefulSetStrategyBuilder(java.lang.Boolean validationEnabled) { this(new V1RollingUpdateStatefulSetStrategy(), validationEnabled); } - public V1RollingUpdateStatefulSetStrategyBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent fluent) { + + public V1RollingUpdateStatefulSetStrategyBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent fluent) { this(fluent, false); } - public V1RollingUpdateStatefulSetStrategyBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent fluent,java.lang.Boolean validationEnabled) { + + public V1RollingUpdateStatefulSetStrategyBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1RollingUpdateStatefulSetStrategy(), validationEnabled); } - public V1RollingUpdateStatefulSetStrategyBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent fluent,io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy instance) { + + public V1RollingUpdateStatefulSetStrategyBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent fluent, + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy instance) { this(fluent, instance, false); } - public V1RollingUpdateStatefulSetStrategyBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent fluent,io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1RollingUpdateStatefulSetStrategyBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent fluent, + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPartition(instance.getPartition()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1RollingUpdateStatefulSetStrategyBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy instance) { - this(instance,false); + + public V1RollingUpdateStatefulSetStrategyBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy instance) { + this(instance, false); } - public V1RollingUpdateStatefulSetStrategyBuilder(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1RollingUpdateStatefulSetStrategyBuilder( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPartition(instance.getPartition()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy build() { V1RollingUpdateStatefulSetStrategy buildable = new V1RollingUpdateStatefulSetStrategy(); buildable.setPartition(fluent.getPartition()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1RollingUpdateStatefulSetStrategyBuilder that = (V1RollingUpdateStatefulSetStrategyBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateStatefulSetStrategyFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateStatefulSetStrategyFluent.java index 5ebe5cdcd1..fc61ff2cf8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateStatefulSetStrategyFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateStatefulSetStrategyFluent.java @@ -1,17 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1RollingUpdateStatefulSetStrategyFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1RollingUpdateStatefulSetStrategyFluent< + A extends io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getPartition(); + public A withPartition(java.lang.Integer partition); + public java.lang.Boolean hasPartition(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateStatefulSetStrategyFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateStatefulSetStrategyFluentImpl.java index d80fa2cd0e..649401e326 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateStatefulSetStrategyFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RollingUpdateStatefulSetStrategyFluentImpl.java @@ -1,39 +1,55 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1RollingUpdateStatefulSetStrategyFluentImpl< + A extends io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent { + public V1RollingUpdateStatefulSetStrategyFluentImpl() {} - /** - * Generated - */ -public class V1RollingUpdateStatefulSetStrategyFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent{ - public V1RollingUpdateStatefulSetStrategyFluentImpl() { - } - public V1RollingUpdateStatefulSetStrategyFluentImpl(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy instance) { + public V1RollingUpdateStatefulSetStrategyFluentImpl( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy instance) { this.withPartition(instance.getPartition()); - } + private java.lang.Integer partition; + public java.lang.Integer getPartition() { return this.partition; } + public A withPartition(java.lang.Integer partition) { - this.partition=partition; return (A) this; + this.partition = partition; + return (A) this; } + public java.lang.Boolean hasPartition() { return this.partition != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1RollingUpdateStatefulSetStrategyFluentImpl that = (V1RollingUpdateStatefulSetStrategyFluentImpl) o; - if (partition != null ? !partition.equals(that.partition) :that.partition != null) return false; + V1RollingUpdateStatefulSetStrategyFluentImpl that = + (V1RollingUpdateStatefulSetStrategyFluentImpl) o; + if (partition != null ? !partition.equals(that.partition) : that.partition != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(partition, super.hashCode()); + return java.util.Objects.hash(partition, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuleWithOperationsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuleWithOperationsBuilder.java index fb5093bd63..033fedafaf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuleWithOperationsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuleWithOperationsBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1RuleWithOperationsBuilder extends io.kubernetes.client.openapi.models.V1RuleWithOperationsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1RuleWithOperationsBuilder + extends io.kubernetes.client.openapi.models.V1RuleWithOperationsFluentImpl< + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1RuleWithOperations, + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder> { public V1RuleWithOperationsBuilder() { this(false); } + public V1RuleWithOperationsBuilder(java.lang.Boolean validationEnabled) { this(new V1RuleWithOperations(), validationEnabled); } - public V1RuleWithOperationsBuilder(io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent fluent) { + + public V1RuleWithOperationsBuilder( + io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent fluent) { this(fluent, false); } - public V1RuleWithOperationsBuilder(io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1RuleWithOperationsBuilder( + io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1RuleWithOperations(), validationEnabled); } - public V1RuleWithOperationsBuilder(io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent fluent,io.kubernetes.client.openapi.models.V1RuleWithOperations instance) { + + public V1RuleWithOperationsBuilder( + io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent fluent, + io.kubernetes.client.openapi.models.V1RuleWithOperations instance) { this(fluent, instance, false); } - public V1RuleWithOperationsBuilder(io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent fluent,io.kubernetes.client.openapi.models.V1RuleWithOperations instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1RuleWithOperationsBuilder( + io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent fluent, + io.kubernetes.client.openapi.models.V1RuleWithOperations instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiGroups(instance.getApiGroups()); fluent.withApiVersions(instance.getApiVersions()); @@ -31,13 +58,18 @@ public V1RuleWithOperationsBuilder(io.kubernetes.client.openapi.models.V1RuleWit fluent.withScope(instance.getScope()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1RuleWithOperationsBuilder(io.kubernetes.client.openapi.models.V1RuleWithOperations instance) { - this(instance,false); + + public V1RuleWithOperationsBuilder( + io.kubernetes.client.openapi.models.V1RuleWithOperations instance) { + this(instance, false); } - public V1RuleWithOperationsBuilder(io.kubernetes.client.openapi.models.V1RuleWithOperations instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1RuleWithOperationsBuilder( + io.kubernetes.client.openapi.models.V1RuleWithOperations instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiGroups(instance.getApiGroups()); this.withApiVersions(instance.getApiVersions()); @@ -48,10 +80,12 @@ public V1RuleWithOperationsBuilder(io.kubernetes.client.openapi.models.V1RuleWit this.withScope(instance.getScope()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1RuleWithOperations build() { V1RuleWithOperations buildable = new V1RuleWithOperations(); buildable.setApiGroups(fluent.getApiGroups()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1RuleWithOperations build() { buildable.setScope(fluent.getScope()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1RuleWithOperationsBuilder that = (V1RuleWithOperationsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuleWithOperationsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuleWithOperationsFluent.java index ddce75cd44..a1cc73628b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuleWithOperationsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuleWithOperationsFluent.java @@ -1,92 +1,164 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1RuleWithOperationsFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToApiGroups(java.lang.Integer index,java.lang.String item); - public A setToApiGroups(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1RuleWithOperationsFluent< + A extends io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToApiGroups(java.lang.Integer index, java.lang.String item); + + public A setToApiGroups(java.lang.Integer index, java.lang.String item); + public A addToApiGroups(java.lang.String... items); + public A addAllToApiGroups(java.util.Collection items); + public A removeFromApiGroups(java.lang.String... items); + public A removeAllFromApiGroups(java.util.Collection items); + public java.util.List getApiGroups(); + public java.lang.String getApiGroup(java.lang.Integer index); + public java.lang.String getFirstApiGroup(); + public java.lang.String getLastApiGroup(); - public java.lang.String getMatchingApiGroup(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingApiGroup(java.util.function.Predicate predicate); + + public java.lang.String getMatchingApiGroup( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingApiGroup( + java.util.function.Predicate predicate); + public A withApiGroups(java.util.List apiGroups); + public A withApiGroups(java.lang.String... apiGroups); + public java.lang.Boolean hasApiGroups(); + public A addNewApiGroup(java.lang.String original); - public A addToApiVersions(java.lang.Integer index,java.lang.String item); - public A setToApiVersions(java.lang.Integer index,java.lang.String item); + + public A addToApiVersions(java.lang.Integer index, java.lang.String item); + + public A setToApiVersions(java.lang.Integer index, java.lang.String item); + public A addToApiVersions(java.lang.String... items); + public A addAllToApiVersions(java.util.Collection items); + public A removeFromApiVersions(java.lang.String... items); + public A removeAllFromApiVersions(java.util.Collection items); + public java.util.List getApiVersions(); + public java.lang.String getApiVersion(java.lang.Integer index); + public java.lang.String getFirstApiVersion(); + public java.lang.String getLastApiVersion(); - public java.lang.String getMatchingApiVersion(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingApiVersion(java.util.function.Predicate predicate); + + public java.lang.String getMatchingApiVersion( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingApiVersion( + java.util.function.Predicate predicate); + public A withApiVersions(java.util.List apiVersions); + public A withApiVersions(java.lang.String... apiVersions); + public java.lang.Boolean hasApiVersions(); + public A addNewApiVersion(java.lang.String original); - public A addToOperations(java.lang.Integer index,java.lang.String item); - public A setToOperations(java.lang.Integer index,java.lang.String item); + + public A addToOperations(java.lang.Integer index, java.lang.String item); + + public A setToOperations(java.lang.Integer index, java.lang.String item); + public A addToOperations(java.lang.String... items); + public A addAllToOperations(java.util.Collection items); + public A removeFromOperations(java.lang.String... items); + public A removeAllFromOperations(java.util.Collection items); + public java.util.List getOperations(); + public java.lang.String getOperation(java.lang.Integer index); + public java.lang.String getFirstOperation(); + public java.lang.String getLastOperation(); - public java.lang.String getMatchingOperation(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingOperation(java.util.function.Predicate predicate); + + public java.lang.String getMatchingOperation( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingOperation( + java.util.function.Predicate predicate); + public A withOperations(java.util.List operations); + public A withOperations(java.lang.String... operations); + public java.lang.Boolean hasOperations(); + public A addNewOperation(java.lang.String original); - public A addToResources(java.lang.Integer index,java.lang.String item); - public A setToResources(java.lang.Integer index,java.lang.String item); + + public A addToResources(java.lang.Integer index, java.lang.String item); + + public A setToResources(java.lang.Integer index, java.lang.String item); + public A addToResources(java.lang.String... items); + public A addAllToResources(java.util.Collection items); + public A removeFromResources(java.lang.String... items); + public A removeAllFromResources(java.util.Collection items); + public java.util.List getResources(); + public java.lang.String getResource(java.lang.Integer index); + public java.lang.String getFirstResource(); + public java.lang.String getLastResource(); - public java.lang.String getMatchingResource(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingResource(java.util.function.Predicate predicate); + + public java.lang.String getMatchingResource( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingResource( + java.util.function.Predicate predicate); + public A withResources(java.util.List resources); + public A withResources(java.lang.String... resources); + public java.lang.Boolean hasResources(); + public A addNewResource(java.lang.String original); + public java.lang.String getScope(); + public A withScope(java.lang.String scope); + public java.lang.Boolean hasScope(); - - /** - * Method is deprecated. use withScope instead. - */ + + /** Method is deprecated. use withScope instead. */ @java.lang.Deprecated public A withNewScope(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuleWithOperationsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuleWithOperationsFluentImpl.java index 22c505d2a4..ac9f352823 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuleWithOperationsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuleWithOperationsFluentImpl.java @@ -1,23 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1RuleWithOperationsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent{ - public V1RuleWithOperationsFluentImpl() { - } - public V1RuleWithOperationsFluentImpl(io.kubernetes.client.openapi.models.V1RuleWithOperations instance) { +/** Generated */ +public class V1RuleWithOperationsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent { + public V1RuleWithOperationsFluentImpl() {} + + public V1RuleWithOperationsFluentImpl( + io.kubernetes.client.openapi.models.V1RuleWithOperations instance) { this.withApiGroups(instance.getApiGroups()); this.withApiVersions(instance.getApiVersions()); @@ -27,259 +30,539 @@ public V1RuleWithOperationsFluentImpl(io.kubernetes.client.openapi.models.V1Rule this.withResources(instance.getResources()); this.withScope(instance.getScope()); - } + private java.util.List apiGroups; private java.util.List apiVersions; private java.util.List operations; private java.util.List resources; private java.lang.String scope; - public A addToApiGroups(java.lang.Integer index,java.lang.String item) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} + + public A addToApiGroups(java.lang.Integer index, java.lang.String item) { + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } this.apiGroups.add(index, item); - return (A)this; + return (A) this; } - public A setToApiGroups(java.lang.Integer index,java.lang.String item) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - this.apiGroups.set(index, item); return (A)this; + + public A setToApiGroups(java.lang.Integer index, java.lang.String item) { + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + this.apiGroups.set(index, item); + return (A) this; } + public A addToApiGroups(java.lang.String... items) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.apiGroups.add(item);} return (A)this; + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.apiGroups.add(item); + } + return (A) this; } + public A addAllToApiGroups(java.util.Collection items) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.apiGroups.add(item);} return (A)this; + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.apiGroups.add(item); + } + return (A) this; } + public A removeFromApiGroups(java.lang.String... items) { - for (java.lang.String item : items) {if (this.apiGroups!= null){ this.apiGroups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.apiGroups != null) { + this.apiGroups.remove(item); + } + } + return (A) this; } + public A removeAllFromApiGroups(java.util.Collection items) { - for (java.lang.String item : items) {if (this.apiGroups!= null){ this.apiGroups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.apiGroups != null) { + this.apiGroups.remove(item); + } + } + return (A) this; } + public java.util.List getApiGroups() { return this.apiGroups; } + public java.lang.String getApiGroup(java.lang.Integer index) { return this.apiGroups.get(index); } + public java.lang.String getFirstApiGroup() { return this.apiGroups.get(0); } + public java.lang.String getLastApiGroup() { return this.apiGroups.get(apiGroups.size() - 1); } - public java.lang.String getMatchingApiGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: apiGroups) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingApiGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : apiGroups) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingApiGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: apiGroups) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingApiGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : apiGroups) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withApiGroups(java.util.List apiGroups) { - if (apiGroups != null) {this.apiGroups = new java.util.ArrayList(); for (java.lang.String item : apiGroups){this.addToApiGroups(item);}} else { this.apiGroups = null;} return (A) this; + if (apiGroups != null) { + this.apiGroups = new java.util.ArrayList(); + for (java.lang.String item : apiGroups) { + this.addToApiGroups(item); + } + } else { + this.apiGroups = null; + } + return (A) this; } + public A withApiGroups(java.lang.String... apiGroups) { - if (this.apiGroups != null) {this.apiGroups.clear();} - if (apiGroups != null) {for (java.lang.String item :apiGroups){ this.addToApiGroups(item);}} return (A) this; + if (this.apiGroups != null) { + this.apiGroups.clear(); + } + if (apiGroups != null) { + for (java.lang.String item : apiGroups) { + this.addToApiGroups(item); + } + } + return (A) this; } + public java.lang.Boolean hasApiGroups() { return apiGroups != null && !apiGroups.isEmpty(); } + public A addNewApiGroup(java.lang.String original) { - return (A)addToApiGroups(new String(original)); + return (A) addToApiGroups(new String(original)); } - public A addToApiVersions(java.lang.Integer index,java.lang.String item) { - if (this.apiVersions == null) {this.apiVersions = new java.util.ArrayList();} + + public A addToApiVersions(java.lang.Integer index, java.lang.String item) { + if (this.apiVersions == null) { + this.apiVersions = new java.util.ArrayList(); + } this.apiVersions.add(index, item); - return (A)this; + return (A) this; } - public A setToApiVersions(java.lang.Integer index,java.lang.String item) { - if (this.apiVersions == null) {this.apiVersions = new java.util.ArrayList();} - this.apiVersions.set(index, item); return (A)this; + + public A setToApiVersions(java.lang.Integer index, java.lang.String item) { + if (this.apiVersions == null) { + this.apiVersions = new java.util.ArrayList(); + } + this.apiVersions.set(index, item); + return (A) this; } + public A addToApiVersions(java.lang.String... items) { - if (this.apiVersions == null) {this.apiVersions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.apiVersions.add(item);} return (A)this; + if (this.apiVersions == null) { + this.apiVersions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.apiVersions.add(item); + } + return (A) this; } + public A addAllToApiVersions(java.util.Collection items) { - if (this.apiVersions == null) {this.apiVersions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.apiVersions.add(item);} return (A)this; + if (this.apiVersions == null) { + this.apiVersions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.apiVersions.add(item); + } + return (A) this; } + public A removeFromApiVersions(java.lang.String... items) { - for (java.lang.String item : items) {if (this.apiVersions!= null){ this.apiVersions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.apiVersions != null) { + this.apiVersions.remove(item); + } + } + return (A) this; } + public A removeAllFromApiVersions(java.util.Collection items) { - for (java.lang.String item : items) {if (this.apiVersions!= null){ this.apiVersions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.apiVersions != null) { + this.apiVersions.remove(item); + } + } + return (A) this; } + public java.util.List getApiVersions() { return this.apiVersions; } + public java.lang.String getApiVersion(java.lang.Integer index) { return this.apiVersions.get(index); } + public java.lang.String getFirstApiVersion() { return this.apiVersions.get(0); } + public java.lang.String getLastApiVersion() { return this.apiVersions.get(apiVersions.size() - 1); } - public java.lang.String getMatchingApiVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: apiVersions) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingApiVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : apiVersions) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingApiVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: apiVersions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingApiVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : apiVersions) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withApiVersions(java.util.List apiVersions) { - if (apiVersions != null) {this.apiVersions = new java.util.ArrayList(); for (java.lang.String item : apiVersions){this.addToApiVersions(item);}} else { this.apiVersions = null;} return (A) this; + if (apiVersions != null) { + this.apiVersions = new java.util.ArrayList(); + for (java.lang.String item : apiVersions) { + this.addToApiVersions(item); + } + } else { + this.apiVersions = null; + } + return (A) this; } + public A withApiVersions(java.lang.String... apiVersions) { - if (this.apiVersions != null) {this.apiVersions.clear();} - if (apiVersions != null) {for (java.lang.String item :apiVersions){ this.addToApiVersions(item);}} return (A) this; + if (this.apiVersions != null) { + this.apiVersions.clear(); + } + if (apiVersions != null) { + for (java.lang.String item : apiVersions) { + this.addToApiVersions(item); + } + } + return (A) this; } + public java.lang.Boolean hasApiVersions() { return apiVersions != null && !apiVersions.isEmpty(); } + public A addNewApiVersion(java.lang.String original) { - return (A)addToApiVersions(new String(original)); + return (A) addToApiVersions(new String(original)); } - public A addToOperations(java.lang.Integer index,java.lang.String item) { - if (this.operations == null) {this.operations = new java.util.ArrayList();} + + public A addToOperations(java.lang.Integer index, java.lang.String item) { + if (this.operations == null) { + this.operations = new java.util.ArrayList(); + } this.operations.add(index, item); - return (A)this; + return (A) this; } - public A setToOperations(java.lang.Integer index,java.lang.String item) { - if (this.operations == null) {this.operations = new java.util.ArrayList();} - this.operations.set(index, item); return (A)this; + + public A setToOperations(java.lang.Integer index, java.lang.String item) { + if (this.operations == null) { + this.operations = new java.util.ArrayList(); + } + this.operations.set(index, item); + return (A) this; } + public A addToOperations(java.lang.String... items) { - if (this.operations == null) {this.operations = new java.util.ArrayList();} - for (java.lang.String item : items) {this.operations.add(item);} return (A)this; + if (this.operations == null) { + this.operations = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.operations.add(item); + } + return (A) this; } + public A addAllToOperations(java.util.Collection items) { - if (this.operations == null) {this.operations = new java.util.ArrayList();} - for (java.lang.String item : items) {this.operations.add(item);} return (A)this; + if (this.operations == null) { + this.operations = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.operations.add(item); + } + return (A) this; } + public A removeFromOperations(java.lang.String... items) { - for (java.lang.String item : items) {if (this.operations!= null){ this.operations.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.operations != null) { + this.operations.remove(item); + } + } + return (A) this; } + public A removeAllFromOperations(java.util.Collection items) { - for (java.lang.String item : items) {if (this.operations!= null){ this.operations.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.operations != null) { + this.operations.remove(item); + } + } + return (A) this; } + public java.util.List getOperations() { return this.operations; } + public java.lang.String getOperation(java.lang.Integer index) { return this.operations.get(index); } + public java.lang.String getFirstOperation() { return this.operations.get(0); } + public java.lang.String getLastOperation() { return this.operations.get(operations.size() - 1); } - public java.lang.String getMatchingOperation(java.util.function.Predicate predicate) { - for (java.lang.String item: operations) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingOperation( + java.util.function.Predicate predicate) { + for (java.lang.String item : operations) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingOperation(java.util.function.Predicate predicate) { - for (java.lang.String item: operations) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingOperation( + java.util.function.Predicate predicate) { + for (java.lang.String item : operations) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withOperations(java.util.List operations) { - if (operations != null) {this.operations = new java.util.ArrayList(); for (java.lang.String item : operations){this.addToOperations(item);}} else { this.operations = null;} return (A) this; + if (operations != null) { + this.operations = new java.util.ArrayList(); + for (java.lang.String item : operations) { + this.addToOperations(item); + } + } else { + this.operations = null; + } + return (A) this; } + public A withOperations(java.lang.String... operations) { - if (this.operations != null) {this.operations.clear();} - if (operations != null) {for (java.lang.String item :operations){ this.addToOperations(item);}} return (A) this; + if (this.operations != null) { + this.operations.clear(); + } + if (operations != null) { + for (java.lang.String item : operations) { + this.addToOperations(item); + } + } + return (A) this; } + public java.lang.Boolean hasOperations() { return operations != null && !operations.isEmpty(); } + public A addNewOperation(java.lang.String original) { - return (A)addToOperations(new String(original)); + return (A) addToOperations(new String(original)); } - public A addToResources(java.lang.Integer index,java.lang.String item) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} + + public A addToResources(java.lang.Integer index, java.lang.String item) { + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } this.resources.add(index, item); - return (A)this; + return (A) this; } - public A setToResources(java.lang.Integer index,java.lang.String item) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - this.resources.set(index, item); return (A)this; + + public A setToResources(java.lang.Integer index, java.lang.String item) { + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + this.resources.set(index, item); + return (A) this; } + public A addToResources(java.lang.String... items) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resources.add(item);} return (A)this; + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resources.add(item); + } + return (A) this; } + public A addAllToResources(java.util.Collection items) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resources.add(item);} return (A)this; + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resources.add(item); + } + return (A) this; } + public A removeFromResources(java.lang.String... items) { - for (java.lang.String item : items) {if (this.resources!= null){ this.resources.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resources != null) { + this.resources.remove(item); + } + } + return (A) this; } + public A removeAllFromResources(java.util.Collection items) { - for (java.lang.String item : items) {if (this.resources!= null){ this.resources.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resources != null) { + this.resources.remove(item); + } + } + return (A) this; } + public java.util.List getResources() { return this.resources; } + public java.lang.String getResource(java.lang.Integer index) { return this.resources.get(index); } + public java.lang.String getFirstResource() { return this.resources.get(0); } + public java.lang.String getLastResource() { return this.resources.get(resources.size() - 1); } - public java.lang.String getMatchingResource(java.util.function.Predicate predicate) { - for (java.lang.String item: resources) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingResource( + java.util.function.Predicate predicate) { + for (java.lang.String item : resources) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingResource(java.util.function.Predicate predicate) { - for (java.lang.String item: resources) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingResource( + java.util.function.Predicate predicate) { + for (java.lang.String item : resources) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withResources(java.util.List resources) { - if (resources != null) {this.resources = new java.util.ArrayList(); for (java.lang.String item : resources){this.addToResources(item);}} else { this.resources = null;} return (A) this; + if (resources != null) { + this.resources = new java.util.ArrayList(); + for (java.lang.String item : resources) { + this.addToResources(item); + } + } else { + this.resources = null; + } + return (A) this; } + public A withResources(java.lang.String... resources) { - if (this.resources != null) {this.resources.clear();} - if (resources != null) {for (java.lang.String item :resources){ this.addToResources(item);}} return (A) this; + if (this.resources != null) { + this.resources.clear(); + } + if (resources != null) { + for (java.lang.String item : resources) { + this.addToResources(item); + } + } + return (A) this; } + public java.lang.Boolean hasResources() { return resources != null && !resources.isEmpty(); } + public A addNewResource(java.lang.String original) { - return (A)addToResources(new String(original)); + return (A) addToResources(new String(original)); } + public java.lang.String getScope() { return this.scope; } + public A withScope(java.lang.String scope) { - this.scope=scope; return (A) this; + this.scope = scope; + return (A) this; } + public java.lang.Boolean hasScope() { return this.scope != null; } - - /** - * Method is deprecated. use withScope instead. - */ + + /** Method is deprecated. use withScope instead. */ @java.lang.Deprecated public A withNewScope(java.lang.String original) { - return (A)withScope(new String(original)); + return (A) withScope(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1RuleWithOperationsFluentImpl that = (V1RuleWithOperationsFluentImpl) o; - if (apiGroups != null ? !apiGroups.equals(that.apiGroups) :that.apiGroups != null) return false; - if (apiVersions != null ? !apiVersions.equals(that.apiVersions) :that.apiVersions != null) return false; - if (operations != null ? !operations.equals(that.operations) :that.operations != null) return false; - if (resources != null ? !resources.equals(that.resources) :that.resources != null) return false; - if (scope != null ? !scope.equals(that.scope) :that.scope != null) return false; + if (apiGroups != null ? !apiGroups.equals(that.apiGroups) : that.apiGroups != null) + return false; + if (apiVersions != null ? !apiVersions.equals(that.apiVersions) : that.apiVersions != null) + return false; + if (operations != null ? !operations.equals(that.operations) : that.operations != null) + return false; + if (resources != null ? !resources.equals(that.resources) : that.resources != null) + return false; + if (scope != null ? !scope.equals(that.scope) : that.scope != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiGroups, apiVersions, operations, resources, scope, super.hashCode()); + return java.util.Objects.hash( + apiGroups, apiVersions, operations, resources, scope, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassBuilder.java index 1626da3c4c..73e8154d2a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1RuntimeClassBuilder extends io.kubernetes.client.openapi.models.V1RuntimeClassFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1RuntimeClassBuilder + extends io.kubernetes.client.openapi.models.V1RuntimeClassFluentImpl< + io.kubernetes.client.openapi.models.V1RuntimeClassBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1RuntimeClass, + io.kubernetes.client.openapi.models.V1RuntimeClassBuilder> { public V1RuntimeClassBuilder() { this(false); } + public V1RuntimeClassBuilder(java.lang.Boolean validationEnabled) { this(new V1RuntimeClass(), validationEnabled); } + public V1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1RuntimeClassFluent fluent) { this(fluent, false); } - public V1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1RuntimeClassFluent fluent,java.lang.Boolean validationEnabled) { + + public V1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1RuntimeClassFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1RuntimeClass(), validationEnabled); } - public V1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1RuntimeClassFluent fluent,io.kubernetes.client.openapi.models.V1RuntimeClass instance) { + + public V1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1RuntimeClassFluent fluent, + io.kubernetes.client.openapi.models.V1RuntimeClass instance) { this(fluent, instance, false); } - public V1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1RuntimeClassFluent fluent,io.kubernetes.client.openapi.models.V1RuntimeClass instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1RuntimeClassFluent fluent, + io.kubernetes.client.openapi.models.V1RuntimeClass instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withHandler(instance.getHandler()); @@ -33,13 +59,17 @@ public V1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1RuntimeClassF fluent.withScheduling(instance.getScheduling()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1RuntimeClass instance) { - this(instance,false); + this(instance, false); } - public V1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1RuntimeClass instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1RuntimeClass instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withHandler(instance.getHandler()); @@ -52,10 +82,12 @@ public V1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1RuntimeClass this.withScheduling(instance.getScheduling()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1RuntimeClassFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1RuntimeClass build() { V1RuntimeClass buildable = new V1RuntimeClass(); buildable.setApiVersion(fluent.getApiVersion()); @@ -66,18 +98,23 @@ public io.kubernetes.client.openapi.models.V1RuntimeClass build() { buildable.setScheduling(fluent.getScheduling()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1RuntimeClassBuilder that = (V1RuntimeClassBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassFluent.java index 6596f8e3a7..dc1808adeb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassFluent.java @@ -1,102 +1,160 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1RuntimeClassFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1RuntimeClassFluent< + A extends io.kubernetes.client.openapi.models.V1RuntimeClassFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getHandler(); + public A withHandler(java.lang.String handler); + public java.lang.Boolean hasHandler(); - - /** - * Method is deprecated. use withHandler instead. - */ + + /** Method is deprecated. use withHandler instead. */ @java.lang.Deprecated public A withNewHandler(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildOverhead instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Overhead getOverhead(); + public io.kubernetes.client.openapi.models.V1Overhead buildOverhead(); + public A withOverhead(io.kubernetes.client.openapi.models.V1Overhead overhead); + public java.lang.Boolean hasOverhead(); - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested withNewOverhead(); - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested withNewOverheadLike(io.kubernetes.client.openapi.models.V1Overhead item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested + withNewOverhead(); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested + withNewOverheadLike(io.kubernetes.client.openapi.models.V1Overhead item); + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested editOverhead(); - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested editOrNewOverhead(); - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested editOrNewOverheadLike(io.kubernetes.client.openapi.models.V1Overhead item); - + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested + editOrNewOverhead(); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested + editOrNewOverheadLike(io.kubernetes.client.openapi.models.V1Overhead item); + /** * This method has been deprecated, please use method buildScheduling instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Scheduling getScheduling(); + public io.kubernetes.client.openapi.models.V1Scheduling buildScheduling(); + public A withScheduling(io.kubernetes.client.openapi.models.V1Scheduling scheduling); + public java.lang.Boolean hasScheduling(); - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested withNewScheduling(); - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested withNewSchedulingLike(io.kubernetes.client.openapi.models.V1Scheduling item); - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested editScheduling(); - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested editOrNewScheduling(); - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested editOrNewSchedulingLike(io.kubernetes.client.openapi.models.V1Scheduling item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested + withNewScheduling(); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested + withNewSchedulingLike(io.kubernetes.client.openapi.models.V1Scheduling item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested + editScheduling(); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested + editOrNewScheduling(); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested + editOrNewSchedulingLike(io.kubernetes.client.openapi.models.V1Scheduling item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface OverheadNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1OverheadFluent>{ + + public interface OverheadNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1OverheadFluent< + io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested> { public N and(); + public N endOverhead(); - } - public interface SchedulingNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SchedulingFluent>{ + + public interface SchedulingNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SchedulingFluent< + io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested> { public N and(); + public N endScheduling(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassFluentImpl.java index a3d8e5f1db..1227f35f5e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1RuntimeClassFluentImpl< + A extends io.kubernetes.client.openapi.models.V1RuntimeClassFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1RuntimeClassFluent { + public V1RuntimeClassFluentImpl() {} - /** - * Generated - */ -public class V1RuntimeClassFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1RuntimeClassFluent{ - public V1RuntimeClassFluentImpl() { - } public V1RuntimeClassFluentImpl(io.kubernetes.client.openapi.models.V1RuntimeClass instance) { this.withApiVersion(instance.getApiVersion()); @@ -25,229 +31,327 @@ public V1RuntimeClassFluentImpl(io.kubernetes.client.openapi.models.V1RuntimeCla this.withOverhead(instance.getOverhead()); this.withScheduling(instance.getScheduling()); - } + private java.lang.String apiVersion; private java.lang.String handler; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1OverheadBuilder overhead; private io.kubernetes.client.openapi.models.V1SchedulingBuilder scheduling; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getHandler() { return this.handler; } + public A withHandler(java.lang.String handler) { - this.handler=handler; return (A) this; + this.handler = handler; + return (A) this; } + public java.lang.Boolean hasHandler() { return this.handler != null; } - - /** - * Method is deprecated. use withHandler instead. - */ + + /** Method is deprecated. use withHandler instead. */ @java.lang.Deprecated public A withNewHandler(java.lang.String original) { - return (A)withHandler(new String(original)); + return (A) withHandler(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1RuntimeClassFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1RuntimeClassFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1RuntimeClassFluentImpl.MetadataNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildOverhead instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Overhead getOverhead() { - return this.overhead!=null ?this.overhead.build():null; + return this.overhead != null ? this.overhead.build() : null; } + public io.kubernetes.client.openapi.models.V1Overhead buildOverhead() { - return this.overhead!=null ?this.overhead.build():null; + return this.overhead != null ? this.overhead.build() : null; } + public A withOverhead(io.kubernetes.client.openapi.models.V1Overhead overhead) { _visitables.get("overhead").remove(this.overhead); - if (overhead!=null){ this.overhead= new io.kubernetes.client.openapi.models.V1OverheadBuilder(overhead); _visitables.get("overhead").add(this.overhead);} return (A) this; + if (overhead != null) { + this.overhead = new io.kubernetes.client.openapi.models.V1OverheadBuilder(overhead); + _visitables.get("overhead").add(this.overhead); + } + return (A) this; } + public java.lang.Boolean hasOverhead() { return this.overhead != null; } - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested withNewOverhead() { + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested + withNewOverhead() { return new io.kubernetes.client.openapi.models.V1RuntimeClassFluentImpl.OverheadNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested withNewOverheadLike(io.kubernetes.client.openapi.models.V1Overhead item) { - return new io.kubernetes.client.openapi.models.V1RuntimeClassFluentImpl.OverheadNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested + withNewOverheadLike(io.kubernetes.client.openapi.models.V1Overhead item) { + return new io.kubernetes.client.openapi.models.V1RuntimeClassFluentImpl.OverheadNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested editOverhead() { return withNewOverheadLike(getOverhead()); } - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested editOrNewOverhead() { - return withNewOverheadLike(getOverhead() != null ? getOverhead(): new io.kubernetes.client.openapi.models.V1OverheadBuilder().build()); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested + editOrNewOverhead() { + return withNewOverheadLike( + getOverhead() != null + ? getOverhead() + : new io.kubernetes.client.openapi.models.V1OverheadBuilder().build()); } - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested editOrNewOverheadLike(io.kubernetes.client.openapi.models.V1Overhead item) { - return withNewOverheadLike(getOverhead() != null ? getOverhead(): item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested + editOrNewOverheadLike(io.kubernetes.client.openapi.models.V1Overhead item) { + return withNewOverheadLike(getOverhead() != null ? getOverhead() : item); } - + /** * This method has been deprecated, please use method buildScheduling instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Scheduling getScheduling() { - return this.scheduling!=null ?this.scheduling.build():null; + return this.scheduling != null ? this.scheduling.build() : null; } + public io.kubernetes.client.openapi.models.V1Scheduling buildScheduling() { - return this.scheduling!=null ?this.scheduling.build():null; + return this.scheduling != null ? this.scheduling.build() : null; } + public A withScheduling(io.kubernetes.client.openapi.models.V1Scheduling scheduling) { _visitables.get("scheduling").remove(this.scheduling); - if (scheduling!=null){ this.scheduling= new io.kubernetes.client.openapi.models.V1SchedulingBuilder(scheduling); _visitables.get("scheduling").add(this.scheduling);} return (A) this; + if (scheduling != null) { + this.scheduling = new io.kubernetes.client.openapi.models.V1SchedulingBuilder(scheduling); + _visitables.get("scheduling").add(this.scheduling); + } + return (A) this; } + public java.lang.Boolean hasScheduling() { return this.scheduling != null; } - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested withNewScheduling() { + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested + withNewScheduling() { return new io.kubernetes.client.openapi.models.V1RuntimeClassFluentImpl.SchedulingNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested withNewSchedulingLike(io.kubernetes.client.openapi.models.V1Scheduling item) { - return new io.kubernetes.client.openapi.models.V1RuntimeClassFluentImpl.SchedulingNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested + withNewSchedulingLike(io.kubernetes.client.openapi.models.V1Scheduling item) { + return new io.kubernetes.client.openapi.models.V1RuntimeClassFluentImpl.SchedulingNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested editScheduling() { + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested + editScheduling() { return withNewSchedulingLike(getScheduling()); } - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested editOrNewScheduling() { - return withNewSchedulingLike(getScheduling() != null ? getScheduling(): new io.kubernetes.client.openapi.models.V1SchedulingBuilder().build()); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested + editOrNewScheduling() { + return withNewSchedulingLike( + getScheduling() != null + ? getScheduling() + : new io.kubernetes.client.openapi.models.V1SchedulingBuilder().build()); } - public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested editOrNewSchedulingLike(io.kubernetes.client.openapi.models.V1Scheduling item) { - return withNewSchedulingLike(getScheduling() != null ? getScheduling(): item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested + editOrNewSchedulingLike(io.kubernetes.client.openapi.models.V1Scheduling item) { + return withNewSchedulingLike(getScheduling() != null ? getScheduling() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1RuntimeClassFluentImpl that = (V1RuntimeClassFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (handler != null ? !handler.equals(that.handler) :that.handler != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (overhead != null ? !overhead.equals(that.overhead) :that.overhead != null) return false; - if (scheduling != null ? !scheduling.equals(that.scheduling) :that.scheduling != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (handler != null ? !handler.equals(that.handler) : that.handler != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (overhead != null ? !overhead.equals(that.overhead) : that.overhead != null) return false; + if (scheduling != null ? !scheduling.equals(that.scheduling) : that.scheduling != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, handler, kind, metadata, overhead, scheduling, super.hashCode()); + return java.util.Objects.hash( + apiVersion, handler, kind, metadata, overhead, scheduling, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1RuntimeClassFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1RuntimeClassFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class OverheadNestedImpl extends io.kubernetes.client.openapi.models.V1OverheadFluentImpl> implements io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested,io.kubernetes.client.fluent.Nested{ + + public class OverheadNestedImpl + extends io.kubernetes.client.openapi.models.V1OverheadFluentImpl< + io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested> + implements io.kubernetes.client.openapi.models.V1RuntimeClassFluent.OverheadNested, + io.kubernetes.client.fluent.Nested { OverheadNestedImpl(io.kubernetes.client.openapi.models.V1Overhead item) { this.builder = new io.kubernetes.client.openapi.models.V1OverheadBuilder(this, item); } + OverheadNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1OverheadBuilder(this); } + io.kubernetes.client.openapi.models.V1OverheadBuilder builder; + public N and() { return (N) V1RuntimeClassFluentImpl.this.withOverhead(builder.build()); } + public N endOverhead() { return and(); } - } - public class SchedulingNestedImpl extends io.kubernetes.client.openapi.models.V1SchedulingFluentImpl> implements io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested,io.kubernetes.client.fluent.Nested{ + + public class SchedulingNestedImpl + extends io.kubernetes.client.openapi.models.V1SchedulingFluentImpl< + io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested> + implements io.kubernetes.client.openapi.models.V1RuntimeClassFluent.SchedulingNested, + io.kubernetes.client.fluent.Nested { SchedulingNestedImpl(io.kubernetes.client.openapi.models.V1Scheduling item) { this.builder = new io.kubernetes.client.openapi.models.V1SchedulingBuilder(this, item); } + SchedulingNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SchedulingBuilder(this); } + io.kubernetes.client.openapi.models.V1SchedulingBuilder builder; + public N and() { return (N) V1RuntimeClassFluentImpl.this.withScheduling(builder.build()); } + public N endScheduling() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassListBuilder.java index b2dee5ca47..68e3d834ee 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1RuntimeClassListBuilder extends io.kubernetes.client.openapi.models.V1RuntimeClassListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1RuntimeClassListBuilder + extends io.kubernetes.client.openapi.models.V1RuntimeClassListFluentImpl< + io.kubernetes.client.openapi.models.V1RuntimeClassListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1RuntimeClassList, + io.kubernetes.client.openapi.models.V1RuntimeClassListBuilder> { public V1RuntimeClassListBuilder() { this(false); } + public V1RuntimeClassListBuilder(java.lang.Boolean validationEnabled) { this(new V1RuntimeClassList(), validationEnabled); } - public V1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1RuntimeClassListFluent fluent) { + + public V1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1RuntimeClassListFluent fluent) { this(fluent, false); } - public V1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1RuntimeClassListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1RuntimeClassListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1RuntimeClassList(), validationEnabled); } - public V1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1RuntimeClassListFluent fluent,io.kubernetes.client.openapi.models.V1RuntimeClassList instance) { + + public V1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1RuntimeClassListFluent fluent, + io.kubernetes.client.openapi.models.V1RuntimeClassList instance) { this(fluent, instance, false); } - public V1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1RuntimeClassListFluent fluent,io.kubernetes.client.openapi.models.V1RuntimeClassList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1RuntimeClassListFluent fluent, + io.kubernetes.client.openapi.models.V1RuntimeClassList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1RuntimeCl fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1RuntimeClassList instance) { - this(instance,false); + + public V1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1RuntimeClassList instance) { + this(instance, false); } - public V1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1RuntimeClassList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1RuntimeClassList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1RuntimeCl this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1RuntimeClassListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1RuntimeClassList build() { V1RuntimeClassList buildable = new V1RuntimeClassList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1RuntimeClassList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1RuntimeClassListBuilder that = (V1RuntimeClassListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassListFluent.java index 5d27bce39b..015d4dee5c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassListFluent.java @@ -1,95 +1,156 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1RuntimeClassListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1RuntimeClassListFluent< + A extends io.kubernetes.client.openapi.models.V1RuntimeClassListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuntimeClass item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuntimeClass item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuntimeClass item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuntimeClass item); + public A addToItems(io.kubernetes.client.openapi.models.V1RuntimeClass... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1RuntimeClass... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1RuntimeClass buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1RuntimeClass buildFirstItem(); + public io.kubernetes.client.openapi.models.V1RuntimeClass buildLastItem(); - public io.kubernetes.client.openapi.models.V1RuntimeClass buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1RuntimeClass buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1RuntimeClass... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1RuntimeClass item); - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuntimeClass item); - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested editFirstItem(); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1RuntimeClass item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuntimeClass item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested + editFirstItem(); + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1RuntimeClassFluent>{ + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1RuntimeClassFluent< + io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassListFluentImpl.java index 6a3f0ac60b..31196595c5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1RuntimeClassListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1RuntimeClassListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1RuntimeClassListFluent{ - public V1RuntimeClassListFluentImpl() { - } - public V1RuntimeClassListFluentImpl(io.kubernetes.client.openapi.models.V1RuntimeClassList instance) { + +/** Generated */ +public class V1RuntimeClassListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1RuntimeClassListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1RuntimeClassListFluent { + public V1RuntimeClassListFluentImpl() {} + + public V1RuntimeClassListFluentImpl( + io.kubernetes.client.openapi.models.V1RuntimeClassList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1RuntimeClassListFluentImpl(io.kubernetes.client.openapi.models.V1Runtim this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuntimeClass item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuntimeClass item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuntimeClass item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuntimeClass item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1RuntimeClass... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1RuntimeClass item : items) {io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1RuntimeClass item : items) { + io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1RuntimeClass item : items) {io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1RuntimeClass item : items) { + io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1RuntimeClass... items) { - for (io.kubernetes.client.openapi.models.V1RuntimeClass item : items) {io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1RuntimeClass item : items) { + io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1RuntimeClass item : items) {io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1RuntimeClass item : items) { + io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder = each.next(); @@ -87,174 +159,279 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1RuntimeClass buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1RuntimeClass buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1RuntimeClass buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1RuntimeClass buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1RuntimeClassBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1RuntimeClass buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1RuntimeClassBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1RuntimeClassBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1RuntimeClassBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1RuntimeClass item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1RuntimeClass item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1RuntimeClass... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1RuntimeClass item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1RuntimeClass item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1RuntimeClassListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1RuntimeClass item) { - return new io.kubernetes.client.openapi.models.V1RuntimeClassListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1RuntimeClass item) { + return new io.kubernetes.client.openapi.models.V1RuntimeClassListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuntimeClass item) { - return new io.kubernetes.client.openapi.models.V1RuntimeClassListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuntimeClass item) { + return new io.kubernetes.client.openapi.models.V1RuntimeClassListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1RuntimeClassListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1RuntimeClassListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1RuntimeClassListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1RuntimeClassListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1RuntimeClassListFluentImpl that = (V1RuntimeClassListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1RuntimeClassFluentImpl> implements io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuntimeClass item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1RuntimeClassFluentImpl< + io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuntimeClass item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1RuntimeClassBuilder(this); } + io.kubernetes.client.openapi.models.V1RuntimeClassBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1RuntimeClassListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1RuntimeClassListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1RuntimeClassListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1RuntimeClassListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SELinuxOptionsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SELinuxOptionsBuilder.java index 8250d16895..2ecd787627 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SELinuxOptionsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SELinuxOptionsBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SELinuxOptionsBuilder extends io.kubernetes.client.openapi.models.V1SELinuxOptionsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SELinuxOptionsBuilder + extends io.kubernetes.client.openapi.models.V1SELinuxOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SELinuxOptions, + io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder> { public V1SELinuxOptionsBuilder() { this(false); } + public V1SELinuxOptionsBuilder(java.lang.Boolean validationEnabled) { this(new V1SELinuxOptions(), validationEnabled); } - public V1SELinuxOptionsBuilder(io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent fluent) { + + public V1SELinuxOptionsBuilder( + io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent fluent) { this(fluent, false); } - public V1SELinuxOptionsBuilder(io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SELinuxOptionsBuilder( + io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SELinuxOptions(), validationEnabled); } - public V1SELinuxOptionsBuilder(io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent fluent,io.kubernetes.client.openapi.models.V1SELinuxOptions instance) { + + public V1SELinuxOptionsBuilder( + io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1SELinuxOptions instance) { this(fluent, instance, false); } - public V1SELinuxOptionsBuilder(io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent fluent,io.kubernetes.client.openapi.models.V1SELinuxOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SELinuxOptionsBuilder( + io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1SELinuxOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLevel(instance.getLevel()); fluent.withRole(instance.getRole()); @@ -29,13 +56,17 @@ public V1SELinuxOptionsBuilder(io.kubernetes.client.openapi.models.V1SELinuxOpti fluent.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1SELinuxOptionsBuilder(io.kubernetes.client.openapi.models.V1SELinuxOptions instance) { - this(instance,false); + this(instance, false); } - public V1SELinuxOptionsBuilder(io.kubernetes.client.openapi.models.V1SELinuxOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SELinuxOptionsBuilder( + io.kubernetes.client.openapi.models.V1SELinuxOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLevel(instance.getLevel()); this.withRole(instance.getRole()); @@ -44,10 +75,12 @@ public V1SELinuxOptionsBuilder(io.kubernetes.client.openapi.models.V1SELinuxOpti this.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SELinuxOptions build() { V1SELinuxOptions buildable = new V1SELinuxOptions(); buildable.setLevel(fluent.getLevel()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1SELinuxOptions build() { buildable.setUser(fluent.getUser()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SELinuxOptionsBuilder that = (V1SELinuxOptionsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SELinuxOptionsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SELinuxOptionsFluent.java index 0cd15f78aa..30b3c95037 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SELinuxOptionsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SELinuxOptionsFluent.java @@ -1,50 +1,58 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SELinuxOptionsFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SELinuxOptionsFluent< + A extends io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getLevel(); + public A withLevel(java.lang.String level); + public java.lang.Boolean hasLevel(); - - /** - * Method is deprecated. use withLevel instead. - */ + + /** Method is deprecated. use withLevel instead. */ @java.lang.Deprecated public A withNewLevel(java.lang.String original); + public java.lang.String getRole(); + public A withRole(java.lang.String role); + public java.lang.Boolean hasRole(); - - /** - * Method is deprecated. use withRole instead. - */ + + /** Method is deprecated. use withRole instead. */ @java.lang.Deprecated public A withNewRole(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); + public java.lang.String getUser(); + public A withUser(java.lang.String user); + public java.lang.Boolean hasUser(); - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SELinuxOptionsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SELinuxOptionsFluentImpl.java index c2887834fc..38e23cf020 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SELinuxOptionsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SELinuxOptionsFluentImpl.java @@ -1,17 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1SELinuxOptionsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent { + public V1SELinuxOptionsFluentImpl() {} - /** - * Generated - */ -public class V1SELinuxOptionsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent{ - public V1SELinuxOptionsFluentImpl() { - } public V1SELinuxOptionsFluentImpl(io.kubernetes.client.openapi.models.V1SELinuxOptions instance) { this.withLevel(instance.getLevel()); @@ -20,92 +27,101 @@ public V1SELinuxOptionsFluentImpl(io.kubernetes.client.openapi.models.V1SELinuxO this.withType(instance.getType()); this.withUser(instance.getUser()); - } + private java.lang.String level; private java.lang.String role; private java.lang.String type; private java.lang.String user; + public java.lang.String getLevel() { return this.level; } + public A withLevel(java.lang.String level) { - this.level=level; return (A) this; + this.level = level; + return (A) this; } + public java.lang.Boolean hasLevel() { return this.level != null; } - - /** - * Method is deprecated. use withLevel instead. - */ + + /** Method is deprecated. use withLevel instead. */ @java.lang.Deprecated public A withNewLevel(java.lang.String original) { - return (A)withLevel(new String(original)); + return (A) withLevel(new String(original)); } + public java.lang.String getRole() { return this.role; } + public A withRole(java.lang.String role) { - this.role=role; return (A) this; + this.role = role; + return (A) this; } + public java.lang.Boolean hasRole() { return this.role != null; } - - /** - * Method is deprecated. use withRole instead. - */ + + /** Method is deprecated. use withRole instead. */ @java.lang.Deprecated public A withNewRole(java.lang.String original) { - return (A)withRole(new String(original)); + return (A) withRole(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public java.lang.String getUser() { return this.user; } + public A withUser(java.lang.String user) { - this.user=user; return (A) this; + this.user = user; + return (A) this; } + public java.lang.Boolean hasUser() { return this.user != null; } - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original) { - return (A)withUser(new String(original)); + return (A) withUser(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SELinuxOptionsFluentImpl that = (V1SELinuxOptionsFluentImpl) o; - if (level != null ? !level.equals(that.level) :that.level != null) return false; - if (role != null ? !role.equals(that.role) :that.role != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; - if (user != null ? !user.equals(that.user) :that.user != null) return false; + if (level != null ? !level.equals(that.level) : that.level != null) return false; + if (role != null ? !role.equals(that.role) : that.role != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; + if (user != null ? !user.equals(that.user) : that.user != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(level, role, type, user, super.hashCode()); + return java.util.Objects.hash(level, role, type, user, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleBuilder.java index bbe3dbd7e4..137116bf08 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ScaleBuilder extends io.kubernetes.client.openapi.models.V1ScaleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ScaleBuilder + extends io.kubernetes.client.openapi.models.V1ScaleFluentImpl< + io.kubernetes.client.openapi.models.V1ScaleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Scale, + io.kubernetes.client.openapi.models.V1ScaleBuilder> { public V1ScaleBuilder() { this(false); } + public V1ScaleBuilder(java.lang.Boolean validationEnabled) { this(new V1Scale(), validationEnabled); } + public V1ScaleBuilder(io.kubernetes.client.openapi.models.V1ScaleFluent fluent) { this(fluent, false); } - public V1ScaleBuilder(io.kubernetes.client.openapi.models.V1ScaleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ScaleBuilder( + io.kubernetes.client.openapi.models.V1ScaleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Scale(), validationEnabled); } - public V1ScaleBuilder(io.kubernetes.client.openapi.models.V1ScaleFluent fluent,io.kubernetes.client.openapi.models.V1Scale instance) { + + public V1ScaleBuilder( + io.kubernetes.client.openapi.models.V1ScaleFluent fluent, + io.kubernetes.client.openapi.models.V1Scale instance) { this(fluent, instance, false); } - public V1ScaleBuilder(io.kubernetes.client.openapi.models.V1ScaleFluent fluent,io.kubernetes.client.openapi.models.V1Scale instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ScaleBuilder( + io.kubernetes.client.openapi.models.V1ScaleFluent fluent, + io.kubernetes.client.openapi.models.V1Scale instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,16 @@ public V1ScaleBuilder(io.kubernetes.client.openapi.models.V1ScaleFluent fluen fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ScaleBuilder(io.kubernetes.client.openapi.models.V1Scale instance) { - this(instance,false); + this(instance, false); } - public V1ScaleBuilder(io.kubernetes.client.openapi.models.V1Scale instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ScaleBuilder( + io.kubernetes.client.openapi.models.V1Scale instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +77,12 @@ public V1ScaleBuilder(io.kubernetes.client.openapi.models.V1Scale instance,java. this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ScaleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Scale build() { V1Scale buildable = new V1Scale(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +92,23 @@ public io.kubernetes.client.openapi.models.V1Scale build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ScaleBuilder that = (V1ScaleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleFluent.java index b175ebf11f..27b54c4d80 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleFluent.java @@ -1,93 +1,142 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ScaleFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ScaleFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ScaleSpec getSpec(); + public io.kubernetes.client.openapi.models.V1ScaleSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1ScaleSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1ScaleSpec item); + + public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1ScaleSpec item); + public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1ScaleSpec item); - + + public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1ScaleSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ScaleStatus getStatus(); + public io.kubernetes.client.openapi.models.V1ScaleStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1ScaleStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1ScaleStatus item); + + public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1ScaleStatus item); + public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ScaleStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1ScaleStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ScaleSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ScaleSpecFluent< + io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ScaleStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ScaleStatusFluent< + io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleFluentImpl.java index fa8c46444a..913a979783 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1ScaleFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ScaleFluent { + public V1ScaleFluentImpl() {} - /** - * Generated - */ -public class V1ScaleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ScaleFluent{ - public V1ScaleFluentImpl() { - } public V1ScaleFluentImpl(io.kubernetes.client.openapi.models.V1Scale instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +28,294 @@ public V1ScaleFluentImpl(io.kubernetes.client.openapi.models.V1Scale instance) { this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1ScaleSpecBuilder spec; private io.kubernetes.client.openapi.models.V1ScaleStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1ScaleFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1ScaleFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ScaleSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1ScaleSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1ScaleSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1ScaleSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1ScaleSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1ScaleFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1ScaleSpec item) { + + public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1ScaleSpec item) { return new io.kubernetes.client.openapi.models.V1ScaleFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1ScaleSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1ScaleSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1ScaleSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1ScaleSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ScaleStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1ScaleStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1ScaleStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1ScaleStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1ScaleStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1ScaleFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1ScaleStatus item) { + + public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1ScaleStatus item) { return new io.kubernetes.client.openapi.models.V1ScaleFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1ScaleStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1ScaleStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ScaleStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1ScaleStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ScaleFluentImpl that = (V1ScaleFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ScaleFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1ScaleFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1ScaleSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1ScaleSpecFluentImpl< + io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1ScaleFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1ScaleSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1ScaleSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ScaleSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1ScaleSpecBuilder builder; + public N and() { return (N) V1ScaleFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1ScaleStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1ScaleStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1ScaleFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1ScaleStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1ScaleStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ScaleStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1ScaleStatusBuilder builder; + public N and() { return (N) V1ScaleFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOPersistentVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOPersistentVolumeSourceBuilder.java index 7e2c0c3646..7e919b8938 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOPersistentVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOPersistentVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ScaleIOPersistentVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ScaleIOPersistentVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource, + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceBuilder> { public V1ScaleIOPersistentVolumeSourceBuilder() { this(false); } + public V1ScaleIOPersistentVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1ScaleIOPersistentVolumeSource(), validationEnabled); } - public V1ScaleIOPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent fluent) { + + public V1ScaleIOPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent fluent) { this(fluent, false); } - public V1ScaleIOPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ScaleIOPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ScaleIOPersistentVolumeSource(), validationEnabled); } - public V1ScaleIOPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource instance) { + + public V1ScaleIOPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource instance) { this(fluent, instance, false); } - public V1ScaleIOPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ScaleIOPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withGateway(instance.getGateway()); @@ -41,13 +68,18 @@ public V1ScaleIOPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.model fluent.withVolumeName(instance.getVolumeName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ScaleIOPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource instance) { - this(instance,false); + + public V1ScaleIOPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource instance) { + this(instance, false); } - public V1ScaleIOPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ScaleIOPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withGateway(instance.getGateway()); @@ -68,10 +100,12 @@ public V1ScaleIOPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.model this.withVolumeName(instance.getVolumeName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource build() { V1ScaleIOPersistentVolumeSource buildable = new V1ScaleIOPersistentVolumeSource(); buildable.setFsType(fluent.getFsType()); @@ -86,18 +120,23 @@ public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource build buildable.setVolumeName(fluent.getVolumeName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ScaleIOPersistentVolumeSourceBuilder that = (V1ScaleIOPersistentVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOPersistentVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOPersistentVolumeSourceFluent.java index fc4179f1da..3ecd31e53e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOPersistentVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOPersistentVolumeSourceFluent.java @@ -1,104 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ScaleIOPersistentVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ScaleIOPersistentVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.String getGateway(); + public A withGateway(java.lang.String gateway); + public java.lang.Boolean hasGateway(); - - /** - * Method is deprecated. use withGateway instead. - */ + + /** Method is deprecated. use withGateway instead. */ @java.lang.Deprecated public A withNewGateway(java.lang.String original); + public java.lang.String getProtectionDomain(); + public A withProtectionDomain(java.lang.String protectionDomain); + public java.lang.Boolean hasProtectionDomain(); - - /** - * Method is deprecated. use withProtectionDomain instead. - */ + + /** Method is deprecated. use withProtectionDomain instead. */ @java.lang.Deprecated public A withNewProtectionDomain(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1SecretReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); - public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested< + A> + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested< + A> + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + + public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested< + A> + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested< + A> + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested< + A> + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item); + public java.lang.Boolean getSslEnabled(); + public A withSslEnabled(java.lang.Boolean sslEnabled); + public java.lang.Boolean hasSslEnabled(); + public java.lang.String getStorageMode(); + public A withStorageMode(java.lang.String storageMode); + public java.lang.Boolean hasStorageMode(); - - /** - * Method is deprecated. use withStorageMode instead. - */ + + /** Method is deprecated. use withStorageMode instead. */ @java.lang.Deprecated public A withNewStorageMode(java.lang.String original); + public java.lang.String getStoragePool(); + public A withStoragePool(java.lang.String storagePool); + public java.lang.Boolean hasStoragePool(); - - /** - * Method is deprecated. use withStoragePool instead. - */ + + /** Method is deprecated. use withStoragePool instead. */ @java.lang.Deprecated public A withNewStoragePool(java.lang.String original); + public java.lang.String getSystem(); + public A withSystem(java.lang.String system); + public java.lang.Boolean hasSystem(); - - /** - * Method is deprecated. use withSystem instead. - */ + + /** Method is deprecated. use withSystem instead. */ @java.lang.Deprecated public A withNewSystem(java.lang.String original); + public java.lang.String getVolumeName(); + public A withVolumeName(java.lang.String volumeName); + public java.lang.Boolean hasVolumeName(); - - /** - * Method is deprecated. use withVolumeName instead. - */ + + /** Method is deprecated. use withVolumeName instead. */ @java.lang.Deprecated public A withNewVolumeName(java.lang.String original); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretReferenceFluent>{ + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretReferenceFluent< + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent + .SecretRefNested< + N>> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOPersistentVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOPersistentVolumeSourceFluentImpl.java index a8f865a059..5fe5e736f2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOPersistentVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOPersistentVolumeSourceFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1ScaleIOPersistentVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent { + public V1ScaleIOPersistentVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1ScaleIOPersistentVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent{ - public V1ScaleIOPersistentVolumeSourceFluentImpl() { - } - public V1ScaleIOPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource instance) { + public V1ScaleIOPersistentVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSource instance) { this.withFsType(instance.getFsType()); this.withGateway(instance.getGateway()); @@ -33,8 +40,8 @@ public V1ScaleIOPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.mo this.withSystem(instance.getSystem()); this.withVolumeName(instance.getVolumeName()); - } + private java.lang.String fsType; private java.lang.String gateway; private java.lang.String protectionDomain; @@ -45,211 +52,291 @@ public V1ScaleIOPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.mo private java.lang.String storagePool; private java.lang.String system; private java.lang.String volumeName; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.String getGateway() { return this.gateway; } + public A withGateway(java.lang.String gateway) { - this.gateway=gateway; return (A) this; + this.gateway = gateway; + return (A) this; } + public java.lang.Boolean hasGateway() { return this.gateway != null; } - - /** - * Method is deprecated. use withGateway instead. - */ + + /** Method is deprecated. use withGateway instead. */ @java.lang.Deprecated public A withNewGateway(java.lang.String original) { - return (A)withGateway(new String(original)); + return (A) withGateway(new String(original)); } + public java.lang.String getProtectionDomain() { return this.protectionDomain; } + public A withProtectionDomain(java.lang.String protectionDomain) { - this.protectionDomain=protectionDomain; return (A) this; + this.protectionDomain = protectionDomain; + return (A) this; } + public java.lang.Boolean hasProtectionDomain() { return this.protectionDomain != null; } - - /** - * Method is deprecated. use withProtectionDomain instead. - */ + + /** Method is deprecated. use withProtectionDomain instead. */ @java.lang.Deprecated public A withNewProtectionDomain(java.lang.String original) { - return (A)withProtectionDomain(new String(original)); + return (A) withProtectionDomain(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1SecretReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested< + A> + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return new io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested< + A> + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return new io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested< + A> + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested< + A> + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested< + A> + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1SecretReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public java.lang.Boolean getSslEnabled() { return this.sslEnabled; } + public A withSslEnabled(java.lang.Boolean sslEnabled) { - this.sslEnabled=sslEnabled; return (A) this; + this.sslEnabled = sslEnabled; + return (A) this; } + public java.lang.Boolean hasSslEnabled() { return this.sslEnabled != null; } + public java.lang.String getStorageMode() { return this.storageMode; } + public A withStorageMode(java.lang.String storageMode) { - this.storageMode=storageMode; return (A) this; + this.storageMode = storageMode; + return (A) this; } + public java.lang.Boolean hasStorageMode() { return this.storageMode != null; } - - /** - * Method is deprecated. use withStorageMode instead. - */ + + /** Method is deprecated. use withStorageMode instead. */ @java.lang.Deprecated public A withNewStorageMode(java.lang.String original) { - return (A)withStorageMode(new String(original)); + return (A) withStorageMode(new String(original)); } + public java.lang.String getStoragePool() { return this.storagePool; } + public A withStoragePool(java.lang.String storagePool) { - this.storagePool=storagePool; return (A) this; + this.storagePool = storagePool; + return (A) this; } + public java.lang.Boolean hasStoragePool() { return this.storagePool != null; } - - /** - * Method is deprecated. use withStoragePool instead. - */ + + /** Method is deprecated. use withStoragePool instead. */ @java.lang.Deprecated public A withNewStoragePool(java.lang.String original) { - return (A)withStoragePool(new String(original)); + return (A) withStoragePool(new String(original)); } + public java.lang.String getSystem() { return this.system; } + public A withSystem(java.lang.String system) { - this.system=system; return (A) this; + this.system = system; + return (A) this; } + public java.lang.Boolean hasSystem() { return this.system != null; } - - /** - * Method is deprecated. use withSystem instead. - */ + + /** Method is deprecated. use withSystem instead. */ @java.lang.Deprecated public A withNewSystem(java.lang.String original) { - return (A)withSystem(new String(original)); + return (A) withSystem(new String(original)); } + public java.lang.String getVolumeName() { return this.volumeName; } + public A withVolumeName(java.lang.String volumeName) { - this.volumeName=volumeName; return (A) this; + this.volumeName = volumeName; + return (A) this; } + public java.lang.Boolean hasVolumeName() { return this.volumeName != null; } - - /** - * Method is deprecated. use withVolumeName instead. - */ + + /** Method is deprecated. use withVolumeName instead. */ @java.lang.Deprecated public A withNewVolumeName(java.lang.String original) { - return (A)withVolumeName(new String(original)); + return (A) withVolumeName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ScaleIOPersistentVolumeSourceFluentImpl that = (V1ScaleIOPersistentVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (gateway != null ? !gateway.equals(that.gateway) :that.gateway != null) return false; - if (protectionDomain != null ? !protectionDomain.equals(that.protectionDomain) :that.protectionDomain != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; - if (sslEnabled != null ? !sslEnabled.equals(that.sslEnabled) :that.sslEnabled != null) return false; - if (storageMode != null ? !storageMode.equals(that.storageMode) :that.storageMode != null) return false; - if (storagePool != null ? !storagePool.equals(that.storagePool) :that.storagePool != null) return false; - if (system != null ? !system.equals(that.system) :that.system != null) return false; - if (volumeName != null ? !volumeName.equals(that.volumeName) :that.volumeName != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (gateway != null ? !gateway.equals(that.gateway) : that.gateway != null) return false; + if (protectionDomain != null + ? !protectionDomain.equals(that.protectionDomain) + : that.protectionDomain != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; + if (sslEnabled != null ? !sslEnabled.equals(that.sslEnabled) : that.sslEnabled != null) + return false; + if (storageMode != null ? !storageMode.equals(that.storageMode) : that.storageMode != null) + return false; + if (storagePool != null ? !storagePool.equals(that.storagePool) : that.storagePool != null) + return false; + if (system != null ? !system.equals(that.system) : that.system != null) return false; + if (volumeName != null ? !volumeName.equals(that.volumeName) : that.volumeName != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, gateway, protectionDomain, readOnly, secretRef, sslEnabled, storageMode, storagePool, system, volumeName, super.hashCode()); + return java.util.Objects.hash( + fsType, + gateway, + protectionDomain, + readOnly, + secretRef, + sslEnabled, + storageMode, + storagePool, + system, + volumeName, + super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent.SecretRefNested< + N>> + implements io.kubernetes.client.openapi.models.V1ScaleIOPersistentVolumeSourceFluent + .SecretRefNested< + N>, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1SecretReference item) { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretReferenceBuilder builder; + public N and() { return (N) V1ScaleIOPersistentVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOVolumeSourceBuilder.java index e9173641c1..f827263c2e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ScaleIOVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ScaleIOVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource, + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceBuilder> { public V1ScaleIOVolumeSourceBuilder() { this(false); } + public V1ScaleIOVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1ScaleIOVolumeSource(), validationEnabled); } - public V1ScaleIOVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent fluent) { + + public V1ScaleIOVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent fluent) { this(fluent, false); } - public V1ScaleIOVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ScaleIOVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ScaleIOVolumeSource(), validationEnabled); } - public V1ScaleIOVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource instance) { + + public V1ScaleIOVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource instance) { this(fluent, instance, false); } - public V1ScaleIOVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ScaleIOVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withGateway(instance.getGateway()); @@ -41,13 +68,18 @@ public V1ScaleIOVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleI fluent.withVolumeName(instance.getVolumeName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ScaleIOVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource instance) { - this(instance,false); + + public V1ScaleIOVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource instance) { + this(instance, false); } - public V1ScaleIOVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ScaleIOVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withGateway(instance.getGateway()); @@ -68,10 +100,12 @@ public V1ScaleIOVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1ScaleI this.withVolumeName(instance.getVolumeName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource build() { V1ScaleIOVolumeSource buildable = new V1ScaleIOVolumeSource(); buildable.setFsType(fluent.getFsType()); @@ -86,18 +120,23 @@ public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource build() { buildable.setVolumeName(fluent.getVolumeName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ScaleIOVolumeSourceBuilder that = (V1ScaleIOVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOVolumeSourceFluent.java index 659a4207c0..73823ccb6c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOVolumeSourceFluent.java @@ -1,104 +1,138 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ScaleIOVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ScaleIOVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.String getGateway(); + public A withGateway(java.lang.String gateway); + public java.lang.Boolean hasGateway(); - - /** - * Method is deprecated. use withGateway instead. - */ + + /** Method is deprecated. use withGateway instead. */ @java.lang.Deprecated public A withNewGateway(java.lang.String original); + public java.lang.String getProtectionDomain(); + public A withProtectionDomain(java.lang.String protectionDomain); + public java.lang.Boolean hasProtectionDomain(); - - /** - * Method is deprecated. use withProtectionDomain instead. - */ + + /** Method is deprecated. use withProtectionDomain instead. */ @java.lang.Deprecated public A withNewProtectionDomain(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + public java.lang.Boolean getSslEnabled(); + public A withSslEnabled(java.lang.Boolean sslEnabled); + public java.lang.Boolean hasSslEnabled(); + public java.lang.String getStorageMode(); + public A withStorageMode(java.lang.String storageMode); + public java.lang.Boolean hasStorageMode(); - - /** - * Method is deprecated. use withStorageMode instead. - */ + + /** Method is deprecated. use withStorageMode instead. */ @java.lang.Deprecated public A withNewStorageMode(java.lang.String original); + public java.lang.String getStoragePool(); + public A withStoragePool(java.lang.String storagePool); + public java.lang.Boolean hasStoragePool(); - - /** - * Method is deprecated. use withStoragePool instead. - */ + + /** Method is deprecated. use withStoragePool instead. */ @java.lang.Deprecated public A withNewStoragePool(java.lang.String original); + public java.lang.String getSystem(); + public A withSystem(java.lang.String system); + public java.lang.Boolean hasSystem(); - - /** - * Method is deprecated. use withSystem instead. - */ + + /** Method is deprecated. use withSystem instead. */ @java.lang.Deprecated public A withNewSystem(java.lang.String original); + public java.lang.String getVolumeName(); + public A withVolumeName(java.lang.String volumeName); + public java.lang.Boolean hasVolumeName(); - - /** - * Method is deprecated. use withVolumeName instead. - */ + + /** Method is deprecated. use withVolumeName instead. */ @java.lang.Deprecated public A withNewVolumeName(java.lang.String original); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent>{ + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOVolumeSourceFluentImpl.java index f1ec9cb312..0d99f8bc3f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleIOVolumeSourceFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1ScaleIOVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent { + public V1ScaleIOVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1ScaleIOVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent{ - public V1ScaleIOVolumeSourceFluentImpl() { - } - public V1ScaleIOVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource instance) { + public V1ScaleIOVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource instance) { this.withFsType(instance.getFsType()); this.withGateway(instance.getGateway()); @@ -33,8 +40,8 @@ public V1ScaleIOVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1Sca this.withSystem(instance.getSystem()); this.withVolumeName(instance.getVolumeName()); - } + private java.lang.String fsType; private java.lang.String gateway; private java.lang.String protectionDomain; @@ -45,211 +52,285 @@ public V1ScaleIOVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1Sca private java.lang.String storagePool; private java.lang.String system; private java.lang.String volumeName; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.String getGateway() { return this.gateway; } + public A withGateway(java.lang.String gateway) { - this.gateway=gateway; return (A) this; + this.gateway = gateway; + return (A) this; } + public java.lang.Boolean hasGateway() { return this.gateway != null; } - - /** - * Method is deprecated. use withGateway instead. - */ + + /** Method is deprecated. use withGateway instead. */ @java.lang.Deprecated public A withNewGateway(java.lang.String original) { - return (A)withGateway(new String(original)); + return (A) withGateway(new String(original)); } + public java.lang.String getProtectionDomain() { return this.protectionDomain; } + public A withProtectionDomain(java.lang.String protectionDomain) { - this.protectionDomain=protectionDomain; return (A) this; + this.protectionDomain = protectionDomain; + return (A) this; } + public java.lang.Boolean hasProtectionDomain() { return this.protectionDomain != null; } - - /** - * Method is deprecated. use withProtectionDomain instead. - */ + + /** Method is deprecated. use withProtectionDomain instead. */ @java.lang.Deprecated public A withNewProtectionDomain(java.lang.String original) { - return (A)withProtectionDomain(new String(original)); + return (A) withProtectionDomain(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluentImpl + .SecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public java.lang.Boolean getSslEnabled() { return this.sslEnabled; } + public A withSslEnabled(java.lang.Boolean sslEnabled) { - this.sslEnabled=sslEnabled; return (A) this; + this.sslEnabled = sslEnabled; + return (A) this; } + public java.lang.Boolean hasSslEnabled() { return this.sslEnabled != null; } + public java.lang.String getStorageMode() { return this.storageMode; } + public A withStorageMode(java.lang.String storageMode) { - this.storageMode=storageMode; return (A) this; + this.storageMode = storageMode; + return (A) this; } + public java.lang.Boolean hasStorageMode() { return this.storageMode != null; } - - /** - * Method is deprecated. use withStorageMode instead. - */ + + /** Method is deprecated. use withStorageMode instead. */ @java.lang.Deprecated public A withNewStorageMode(java.lang.String original) { - return (A)withStorageMode(new String(original)); + return (A) withStorageMode(new String(original)); } + public java.lang.String getStoragePool() { return this.storagePool; } + public A withStoragePool(java.lang.String storagePool) { - this.storagePool=storagePool; return (A) this; + this.storagePool = storagePool; + return (A) this; } + public java.lang.Boolean hasStoragePool() { return this.storagePool != null; } - - /** - * Method is deprecated. use withStoragePool instead. - */ + + /** Method is deprecated. use withStoragePool instead. */ @java.lang.Deprecated public A withNewStoragePool(java.lang.String original) { - return (A)withStoragePool(new String(original)); + return (A) withStoragePool(new String(original)); } + public java.lang.String getSystem() { return this.system; } + public A withSystem(java.lang.String system) { - this.system=system; return (A) this; + this.system = system; + return (A) this; } + public java.lang.Boolean hasSystem() { return this.system != null; } - - /** - * Method is deprecated. use withSystem instead. - */ + + /** Method is deprecated. use withSystem instead. */ @java.lang.Deprecated public A withNewSystem(java.lang.String original) { - return (A)withSystem(new String(original)); + return (A) withSystem(new String(original)); } + public java.lang.String getVolumeName() { return this.volumeName; } + public A withVolumeName(java.lang.String volumeName) { - this.volumeName=volumeName; return (A) this; + this.volumeName = volumeName; + return (A) this; } + public java.lang.Boolean hasVolumeName() { return this.volumeName != null; } - - /** - * Method is deprecated. use withVolumeName instead. - */ + + /** Method is deprecated. use withVolumeName instead. */ @java.lang.Deprecated public A withNewVolumeName(java.lang.String original) { - return (A)withVolumeName(new String(original)); + return (A) withVolumeName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ScaleIOVolumeSourceFluentImpl that = (V1ScaleIOVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (gateway != null ? !gateway.equals(that.gateway) :that.gateway != null) return false; - if (protectionDomain != null ? !protectionDomain.equals(that.protectionDomain) :that.protectionDomain != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; - if (sslEnabled != null ? !sslEnabled.equals(that.sslEnabled) :that.sslEnabled != null) return false; - if (storageMode != null ? !storageMode.equals(that.storageMode) :that.storageMode != null) return false; - if (storagePool != null ? !storagePool.equals(that.storagePool) :that.storagePool != null) return false; - if (system != null ? !system.equals(that.system) :that.system != null) return false; - if (volumeName != null ? !volumeName.equals(that.volumeName) :that.volumeName != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (gateway != null ? !gateway.equals(that.gateway) : that.gateway != null) return false; + if (protectionDomain != null + ? !protectionDomain.equals(that.protectionDomain) + : that.protectionDomain != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; + if (sslEnabled != null ? !sslEnabled.equals(that.sslEnabled) : that.sslEnabled != null) + return false; + if (storageMode != null ? !storageMode.equals(that.storageMode) : that.storageMode != null) + return false; + if (storagePool != null ? !storagePool.equals(that.storagePool) : that.storagePool != null) + return false; + if (system != null ? !system.equals(that.system) : that.system != null) return false; + if (volumeName != null ? !volumeName.equals(that.volumeName) : that.volumeName != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, gateway, protectionDomain, readOnly, secretRef, sslEnabled, storageMode, storagePool, system, volumeName, super.hashCode()); + return java.util.Objects.hash( + fsType, + gateway, + protectionDomain, + readOnly, + secretRef, + sslEnabled, + storageMode, + storagePool, + system, + volumeName, + super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested> + implements io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent.SecretRefNested, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder; + public N and() { return (N) V1ScaleIOVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleSpecBuilder.java index 9707f02032..9eebfdbb0f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleSpecBuilder.java @@ -1,58 +1,95 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ScaleSpecBuilder extends io.kubernetes.client.openapi.models.V1ScaleSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ScaleSpecBuilder + extends io.kubernetes.client.openapi.models.V1ScaleSpecFluentImpl< + io.kubernetes.client.openapi.models.V1ScaleSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ScaleSpec, + io.kubernetes.client.openapi.models.V1ScaleSpecBuilder> { public V1ScaleSpecBuilder() { this(false); } + public V1ScaleSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1ScaleSpec(), validationEnabled); } + public V1ScaleSpecBuilder(io.kubernetes.client.openapi.models.V1ScaleSpecFluent fluent) { this(fluent, false); } - public V1ScaleSpecBuilder(io.kubernetes.client.openapi.models.V1ScaleSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ScaleSpecBuilder( + io.kubernetes.client.openapi.models.V1ScaleSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ScaleSpec(), validationEnabled); } - public V1ScaleSpecBuilder(io.kubernetes.client.openapi.models.V1ScaleSpecFluent fluent,io.kubernetes.client.openapi.models.V1ScaleSpec instance) { + + public V1ScaleSpecBuilder( + io.kubernetes.client.openapi.models.V1ScaleSpecFluent fluent, + io.kubernetes.client.openapi.models.V1ScaleSpec instance) { this(fluent, instance, false); } - public V1ScaleSpecBuilder(io.kubernetes.client.openapi.models.V1ScaleSpecFluent fluent,io.kubernetes.client.openapi.models.V1ScaleSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ScaleSpecBuilder( + io.kubernetes.client.openapi.models.V1ScaleSpecFluent fluent, + io.kubernetes.client.openapi.models.V1ScaleSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withReplicas(instance.getReplicas()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ScaleSpecBuilder(io.kubernetes.client.openapi.models.V1ScaleSpec instance) { - this(instance,false); + this(instance, false); } - public V1ScaleSpecBuilder(io.kubernetes.client.openapi.models.V1ScaleSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ScaleSpecBuilder( + io.kubernetes.client.openapi.models.V1ScaleSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withReplicas(instance.getReplicas()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ScaleSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ScaleSpec build() { V1ScaleSpec buildable = new V1ScaleSpec(); buildable.setReplicas(fluent.getReplicas()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ScaleSpecBuilder that = (V1ScaleSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleSpecFluent.java index 7718f32b87..ed652caeb6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleSpecFluent.java @@ -1,17 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ScaleSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ScaleSpecFluent< + A extends io.kubernetes.client.openapi.models.V1ScaleSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getReplicas(); + public A withReplicas(java.lang.Integer replicas); + public java.lang.Boolean hasReplicas(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleSpecFluentImpl.java index a5ce661575..e8aff63558 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleSpecFluentImpl.java @@ -1,39 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1ScaleSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ScaleSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ScaleSpecFluent { + public V1ScaleSpecFluentImpl() {} - /** - * Generated - */ -public class V1ScaleSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ScaleSpecFluent{ - public V1ScaleSpecFluentImpl() { - } public V1ScaleSpecFluentImpl(io.kubernetes.client.openapi.models.V1ScaleSpec instance) { this.withReplicas(instance.getReplicas()); - } + private java.lang.Integer replicas; + public java.lang.Integer getReplicas() { return this.replicas; } + public A withReplicas(java.lang.Integer replicas) { - this.replicas=replicas; return (A) this; + this.replicas = replicas; + return (A) this; } + public java.lang.Boolean hasReplicas() { return this.replicas != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ScaleSpecFluentImpl that = (V1ScaleSpecFluentImpl) o; - if (replicas != null ? !replicas.equals(that.replicas) :that.replicas != null) return false; + if (replicas != null ? !replicas.equals(that.replicas) : that.replicas != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(replicas, super.hashCode()); + return java.util.Objects.hash(replicas, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleStatusBuilder.java index 68b1265d9c..22539827d1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleStatusBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ScaleStatusBuilder extends io.kubernetes.client.openapi.models.V1ScaleStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ScaleStatusBuilder + extends io.kubernetes.client.openapi.models.V1ScaleStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ScaleStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ScaleStatus, + io.kubernetes.client.openapi.models.V1ScaleStatusBuilder> { public V1ScaleStatusBuilder() { this(false); } + public V1ScaleStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1ScaleStatus(), validationEnabled); } + public V1ScaleStatusBuilder(io.kubernetes.client.openapi.models.V1ScaleStatusFluent fluent) { this(fluent, false); } - public V1ScaleStatusBuilder(io.kubernetes.client.openapi.models.V1ScaleStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ScaleStatusBuilder( + io.kubernetes.client.openapi.models.V1ScaleStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ScaleStatus(), validationEnabled); } - public V1ScaleStatusBuilder(io.kubernetes.client.openapi.models.V1ScaleStatusFluent fluent,io.kubernetes.client.openapi.models.V1ScaleStatus instance) { + + public V1ScaleStatusBuilder( + io.kubernetes.client.openapi.models.V1ScaleStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ScaleStatus instance) { this(fluent, instance, false); } - public V1ScaleStatusBuilder(io.kubernetes.client.openapi.models.V1ScaleStatusFluent fluent,io.kubernetes.client.openapi.models.V1ScaleStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ScaleStatusBuilder( + io.kubernetes.client.openapi.models.V1ScaleStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ScaleStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withReplicas(instance.getReplicas()); fluent.withSelector(instance.getSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ScaleStatusBuilder(io.kubernetes.client.openapi.models.V1ScaleStatus instance) { - this(instance,false); + this(instance, false); } - public V1ScaleStatusBuilder(io.kubernetes.client.openapi.models.V1ScaleStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ScaleStatusBuilder( + io.kubernetes.client.openapi.models.V1ScaleStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withReplicas(instance.getReplicas()); this.withSelector(instance.getSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ScaleStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ScaleStatus build() { V1ScaleStatus buildable = new V1ScaleStatus(); buildable.setReplicas(fluent.getReplicas()); buildable.setSelector(fluent.getSelector()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ScaleStatusBuilder that = (V1ScaleStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleStatusFluent.java index adc53273cd..3c686ec6d9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleStatusFluent.java @@ -1,27 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ScaleStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ScaleStatusFluent< + A extends io.kubernetes.client.openapi.models.V1ScaleStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getReplicas(); + public A withReplicas(java.lang.Integer replicas); + public java.lang.Boolean hasReplicas(); + public java.lang.String getSelector(); + public A withSelector(java.lang.String selector); + public java.lang.Boolean hasSelector(); - - /** - * Method is deprecated. use withSelector instead. - */ + + /** Method is deprecated. use withSelector instead. */ @java.lang.Deprecated public A withNewSelector(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleStatusFluentImpl.java index a66e472639..9e30ffe518 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScaleStatusFluentImpl.java @@ -1,62 +1,75 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ScaleStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ScaleStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ScaleStatusFluent { + public V1ScaleStatusFluentImpl() {} - /** - * Generated - */ -public class V1ScaleStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ScaleStatusFluent{ - public V1ScaleStatusFluentImpl() { - } public V1ScaleStatusFluentImpl(io.kubernetes.client.openapi.models.V1ScaleStatus instance) { this.withReplicas(instance.getReplicas()); this.withSelector(instance.getSelector()); - } + private java.lang.Integer replicas; private java.lang.String selector; + public java.lang.Integer getReplicas() { return this.replicas; } + public A withReplicas(java.lang.Integer replicas) { - this.replicas=replicas; return (A) this; + this.replicas = replicas; + return (A) this; } + public java.lang.Boolean hasReplicas() { return this.replicas != null; } + public java.lang.String getSelector() { return this.selector; } + public A withSelector(java.lang.String selector) { - this.selector=selector; return (A) this; + this.selector = selector; + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - - /** - * Method is deprecated. use withSelector instead. - */ + + /** Method is deprecated. use withSelector instead. */ @java.lang.Deprecated public A withNewSelector(java.lang.String original) { - return (A)withSelector(new String(original)); + return (A) withSelector(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ScaleStatusFluentImpl that = (V1ScaleStatusFluentImpl) o; - if (replicas != null ? !replicas.equals(that.replicas) :that.replicas != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; + if (replicas != null ? !replicas.equals(that.replicas) : that.replicas != null) return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(replicas, selector, super.hashCode()); + return java.util.Objects.hash(replicas, selector, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SchedulingBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SchedulingBuilder.java index 7200d62a84..b7aaa20cb2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SchedulingBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SchedulingBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SchedulingBuilder extends io.kubernetes.client.openapi.models.V1SchedulingFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SchedulingBuilder + extends io.kubernetes.client.openapi.models.V1SchedulingFluentImpl< + io.kubernetes.client.openapi.models.V1SchedulingBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Scheduling, + io.kubernetes.client.openapi.models.V1SchedulingBuilder> { public V1SchedulingBuilder() { this(false); } + public V1SchedulingBuilder(java.lang.Boolean validationEnabled) { this(new V1Scheduling(), validationEnabled); } + public V1SchedulingBuilder(io.kubernetes.client.openapi.models.V1SchedulingFluent fluent) { this(fluent, false); } - public V1SchedulingBuilder(io.kubernetes.client.openapi.models.V1SchedulingFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1SchedulingFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Scheduling(), validationEnabled); } - public V1SchedulingBuilder(io.kubernetes.client.openapi.models.V1SchedulingFluent fluent,io.kubernetes.client.openapi.models.V1Scheduling instance) { + + public V1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1SchedulingFluent fluent, + io.kubernetes.client.openapi.models.V1Scheduling instance) { this(fluent, instance, false); } - public V1SchedulingBuilder(io.kubernetes.client.openapi.models.V1SchedulingFluent fluent,io.kubernetes.client.openapi.models.V1Scheduling instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1SchedulingFluent fluent, + io.kubernetes.client.openapi.models.V1Scheduling instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNodeSelector(instance.getNodeSelector()); fluent.withTolerations(instance.getTolerations()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1SchedulingBuilder(io.kubernetes.client.openapi.models.V1Scheduling instance) { - this(instance,false); + this(instance, false); } - public V1SchedulingBuilder(io.kubernetes.client.openapi.models.V1Scheduling instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1Scheduling instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNodeSelector(instance.getNodeSelector()); this.withTolerations(instance.getTolerations()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SchedulingFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Scheduling build() { V1Scheduling buildable = new V1Scheduling(); buildable.setNodeSelector(fluent.getNodeSelector()); buildable.setTolerations(fluent.getTolerations()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SchedulingBuilder that = (V1SchedulingBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SchedulingFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SchedulingFluent.java index 32b4021b3a..4576a0e593 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SchedulingFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SchedulingFluent.java @@ -1,66 +1,116 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1SchedulingFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToNodeSelector(java.lang.String key,java.lang.String value); - public A addToNodeSelector(java.util.Map map); +/** Generated */ +public interface V1SchedulingFluent< + A extends io.kubernetes.client.openapi.models.V1SchedulingFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToNodeSelector(java.lang.String key, java.lang.String value); + + public A addToNodeSelector(java.util.Map map); + public A removeFromNodeSelector(java.lang.String key); - public A removeFromNodeSelector(java.util.Map map); - public java.util.Map getNodeSelector(); - public A withNodeSelector(java.util.Map nodeSelector); + + public A removeFromNodeSelector(java.util.Map map); + + public java.util.Map getNodeSelector(); + + public A withNodeSelector(java.util.Map nodeSelector); + public java.lang.Boolean hasNodeSelector(); - public A addToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item); - public A setToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item); + + public A addToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item); + + public A setToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item); + public A addToTolerations(io.kubernetes.client.openapi.models.V1Toleration... items); - public A addAllToTolerations(java.util.Collection items); + + public A addAllToTolerations( + java.util.Collection items); + public A removeFromTolerations(io.kubernetes.client.openapi.models.V1Toleration... items); - public A removeAllFromTolerations(java.util.Collection items); - public A removeMatchingFromTolerations(java.util.function.Predicate predicate); - + + public A removeAllFromTolerations( + java.util.Collection items); + + public A removeMatchingFromTolerations( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildTolerations instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getTolerations(); + public java.util.List buildTolerations(); + public io.kubernetes.client.openapi.models.V1Toleration buildToleration(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Toleration buildFirstToleration(); + public io.kubernetes.client.openapi.models.V1Toleration buildLastToleration(); - public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingToleration(java.util.function.Predicate predicate); - public A withTolerations(java.util.List tolerations); + + public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingToleration( + java.util.function.Predicate + predicate); + + public A withTolerations( + java.util.List tolerations); + public A withTolerations(io.kubernetes.client.openapi.models.V1Toleration... tolerations); + public java.lang.Boolean hasTolerations(); - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested addNewToleration(); - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item); - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested setNewTolerationLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item); - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested editToleration(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested editFirstToleration(); - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested editLastToleration(); - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested editMatchingToleration(java.util.function.Predicate predicate); - public interface TolerationsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TolerationFluent>{ + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested + addNewToleration(); + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested + addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item); + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested + setNewTolerationLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item); + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested editToleration( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested + editFirstToleration(); + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested + editLastToleration(); + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested + editMatchingToleration( + java.util.function.Predicate + predicate); + + public interface TolerationsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TolerationFluent< + io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested> { public N and(); + public N endToleration(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SchedulingFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SchedulingFluentImpl.java index 5ef9b4d6ca..42f5699f7d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SchedulingFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SchedulingFluentImpl.java @@ -1,88 +1,193 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; -import java.util.Map; - /** - * Generated - */ -public class V1SchedulingFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SchedulingFluent{ - public V1SchedulingFluentImpl() { - } +/** Generated */ +public class V1SchedulingFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SchedulingFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SchedulingFluent { + public V1SchedulingFluentImpl() {} + public V1SchedulingFluentImpl(io.kubernetes.client.openapi.models.V1Scheduling instance) { this.withNodeSelector(instance.getNodeSelector()); this.withTolerations(instance.getTolerations()); - } - private java.util.Map nodeSelector; + + private java.util.Map nodeSelector; private java.util.ArrayList tolerations; - public A addToNodeSelector(java.lang.String key,java.lang.String value) { - if(this.nodeSelector == null && key != null && value != null) { this.nodeSelector = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.nodeSelector.put(key, value);} return (A)this; + + public A addToNodeSelector(java.lang.String key, java.lang.String value) { + if (this.nodeSelector == null && key != null && value != null) { + this.nodeSelector = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.nodeSelector.put(key, value); + } + return (A) this; } - public A addToNodeSelector(java.util.Map map) { - if(this.nodeSelector == null && map != null) { this.nodeSelector = new java.util.LinkedHashMap(); } - if(map != null) { this.nodeSelector.putAll(map);} return (A)this; + + public A addToNodeSelector(java.util.Map map) { + if (this.nodeSelector == null && map != null) { + this.nodeSelector = new java.util.LinkedHashMap(); + } + if (map != null) { + this.nodeSelector.putAll(map); + } + return (A) this; } + public A removeFromNodeSelector(java.lang.String key) { - if(this.nodeSelector == null) { return (A) this; } - if(key != null && this.nodeSelector != null) {this.nodeSelector.remove(key);} return (A)this; + if (this.nodeSelector == null) { + return (A) this; + } + if (key != null && this.nodeSelector != null) { + this.nodeSelector.remove(key); + } + return (A) this; } - public A removeFromNodeSelector(java.util.Map map) { - if(this.nodeSelector == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.nodeSelector != null){this.nodeSelector.remove(key);}}} return (A)this; + + public A removeFromNodeSelector(java.util.Map map) { + if (this.nodeSelector == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.nodeSelector != null) { + this.nodeSelector.remove(key); + } + } + } + return (A) this; } - public java.util.Map getNodeSelector() { + + public java.util.Map getNodeSelector() { return this.nodeSelector; } - public A withNodeSelector(java.util.Map nodeSelector) { - if (nodeSelector == null) { this.nodeSelector = null;} else {this.nodeSelector = new java.util.LinkedHashMap(nodeSelector);} return (A) this; + + public A withNodeSelector(java.util.Map nodeSelector) { + if (nodeSelector == null) { + this.nodeSelector = null; + } else { + this.nodeSelector = new java.util.LinkedHashMap(nodeSelector); + } + return (A) this; } + public java.lang.Boolean hasNodeSelector() { return this.nodeSelector != null; } - public A addToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").add(index >= 0 ? index : _visitables.get("tolerations").size(), builder);this.tolerations.add(index >= 0 ? index : tolerations.size(), builder); return (A)this; + + public A addToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables + .get("tolerations") + .add(index >= 0 ? index : _visitables.get("tolerations").size(), builder); + this.tolerations.add(index >= 0 ? index : tolerations.size(), builder); + return (A) this; } - public A setToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); - if (index < 0 || index >= _visitables.get("tolerations").size()) { _visitables.get("tolerations").add(builder); } else { _visitables.get("tolerations").set(index, builder);} - if (index < 0 || index >= tolerations.size()) { tolerations.add(builder); } else { tolerations.set(index, builder);} - return (A)this; + + public A setToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + if (index < 0 || index >= _visitables.get("tolerations").size()) { + _visitables.get("tolerations").add(builder); + } else { + _visitables.get("tolerations").set(index, builder); + } + if (index < 0 || index >= tolerations.size()) { + tolerations.add(builder); + } else { + tolerations.set(index, builder); + } + return (A) this; } + public A addToTolerations(io.kubernetes.client.openapi.models.V1Toleration... items) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").add(builder);this.tolerations.add(builder);} return (A)this; + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").add(builder); + this.tolerations.add(builder); + } + return (A) this; } - public A addAllToTolerations(java.util.Collection items) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").add(builder);this.tolerations.add(builder);} return (A)this; + + public A addAllToTolerations( + java.util.Collection items) { + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").add(builder); + this.tolerations.add(builder); + } + return (A) this; } + public A removeFromTolerations(io.kubernetes.client.openapi.models.V1Toleration... items) { - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").remove(builder);if (this.tolerations != null) {this.tolerations.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").remove(builder); + if (this.tolerations != null) { + this.tolerations.remove(builder); + } + } + return (A) this; } - public A removeAllFromTolerations(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").remove(builder);if (this.tolerations != null) {this.tolerations.remove(builder);}} return (A)this; + + public A removeAllFromTolerations( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").remove(builder); + if (this.tolerations != null) { + this.tolerations.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromTolerations(java.util.function.Predicate predicate) { + + public A removeMatchingFromTolerations( + java.util.function.Predicate + predicate) { if (tolerations == null) return (A) this; - final Iterator each = tolerations.iterator(); + final Iterator each = + tolerations.iterator(); final List visitables = _visitables.get("tolerations"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1TolerationBuilder builder = each.next(); @@ -91,105 +196,183 @@ public A removeMatchingFromTolerations(java.util.function.Predicate getTolerations() { return tolerations != null ? build(tolerations) : null; } + public java.util.List buildTolerations() { return tolerations != null ? build(tolerations) : null; } + public io.kubernetes.client.openapi.models.V1Toleration buildToleration(java.lang.Integer index) { return this.tolerations.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Toleration buildFirstToleration() { return this.tolerations.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Toleration buildLastToleration() { return this.tolerations.get(tolerations.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TolerationBuilder item: tolerations) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1TolerationBuilder item : tolerations) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingToleration(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TolerationBuilder item: tolerations) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingToleration( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1TolerationBuilder item : tolerations) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withTolerations(java.util.List tolerations) { - if (this.tolerations != null) { _visitables.get("tolerations").removeAll(this.tolerations);} - if (tolerations != null) {this.tolerations = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Toleration item : tolerations){this.addToTolerations(item);}} else { this.tolerations = null;} return (A) this; + + public A withTolerations( + java.util.List tolerations) { + if (this.tolerations != null) { + _visitables.get("tolerations").removeAll(this.tolerations); + } + if (tolerations != null) { + this.tolerations = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Toleration item : tolerations) { + this.addToTolerations(item); + } + } else { + this.tolerations = null; + } + return (A) this; } + public A withTolerations(io.kubernetes.client.openapi.models.V1Toleration... tolerations) { - if (this.tolerations != null) {this.tolerations.clear();} - if (tolerations != null) {for (io.kubernetes.client.openapi.models.V1Toleration item :tolerations){ this.addToTolerations(item);}} return (A) this; + if (this.tolerations != null) { + this.tolerations.clear(); + } + if (tolerations != null) { + for (io.kubernetes.client.openapi.models.V1Toleration item : tolerations) { + this.addToTolerations(item); + } + } + return (A) this; } + public java.lang.Boolean hasTolerations() { return tolerations != null && !tolerations.isEmpty(); } - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested addNewToleration() { + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested + addNewToleration() { return new io.kubernetes.client.openapi.models.V1SchedulingFluentImpl.TolerationsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item) { - return new io.kubernetes.client.openapi.models.V1SchedulingFluentImpl.TolerationsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested + addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item) { + return new io.kubernetes.client.openapi.models.V1SchedulingFluentImpl.TolerationsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested setNewTolerationLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { - return new io.kubernetes.client.openapi.models.V1SchedulingFluentImpl.TolerationsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested + setNewTolerationLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { + return new io.kubernetes.client.openapi.models.V1SchedulingFluentImpl.TolerationsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested editToleration(java.lang.Integer index) { - if (tolerations.size() <= index) throw new RuntimeException("Can't edit tolerations. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested editToleration( + java.lang.Integer index) { + if (tolerations.size() <= index) + throw new RuntimeException("Can't edit tolerations. Index exceeds size."); return setNewTolerationLike(index, buildToleration(index)); } - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested editFirstToleration() { - if (tolerations.size() == 0) throw new RuntimeException("Can't edit first tolerations. The list is empty."); + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested + editFirstToleration() { + if (tolerations.size() == 0) + throw new RuntimeException("Can't edit first tolerations. The list is empty."); return setNewTolerationLike(0, buildToleration(0)); } - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested editLastToleration() { + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested + editLastToleration() { int index = tolerations.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last tolerations. The list is empty."); return setNewTolerationLike(index, buildToleration(index)); } - public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested editMatchingToleration(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested + editMatchingToleration( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1TolerationFluentImpl> implements io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested,io.kubernetes.client.fluent.Nested{ - TolerationsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { + + public class TolerationsNestedImpl + extends io.kubernetes.client.openapi.models.V1TolerationFluentImpl< + io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested> + implements io.kubernetes.client.openapi.models.V1SchedulingFluent.TolerationsNested, + io.kubernetes.client.fluent.Nested { + TolerationsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(this, item); } + TolerationsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(this); } + io.kubernetes.client.openapi.models.V1TolerationBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1SchedulingFluentImpl.this.setToTolerations(index,builder.build()); + return (N) V1SchedulingFluentImpl.this.setToTolerations(index, builder.build()); } + public N endToleration() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopeSelectorBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopeSelectorBuilder.java index 42f861c347..e8db1278a8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopeSelectorBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopeSelectorBuilder.java @@ -1,58 +1,96 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ScopeSelectorBuilder extends io.kubernetes.client.openapi.models.V1ScopeSelectorFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ScopeSelectorBuilder + extends io.kubernetes.client.openapi.models.V1ScopeSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1ScopeSelectorBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ScopeSelector, + io.kubernetes.client.openapi.models.V1ScopeSelectorBuilder> { public V1ScopeSelectorBuilder() { this(false); } + public V1ScopeSelectorBuilder(java.lang.Boolean validationEnabled) { this(new V1ScopeSelector(), validationEnabled); } - public V1ScopeSelectorBuilder(io.kubernetes.client.openapi.models.V1ScopeSelectorFluent fluent) { + + public V1ScopeSelectorBuilder( + io.kubernetes.client.openapi.models.V1ScopeSelectorFluent fluent) { this(fluent, false); } - public V1ScopeSelectorBuilder(io.kubernetes.client.openapi.models.V1ScopeSelectorFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ScopeSelectorBuilder( + io.kubernetes.client.openapi.models.V1ScopeSelectorFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ScopeSelector(), validationEnabled); } - public V1ScopeSelectorBuilder(io.kubernetes.client.openapi.models.V1ScopeSelectorFluent fluent,io.kubernetes.client.openapi.models.V1ScopeSelector instance) { + + public V1ScopeSelectorBuilder( + io.kubernetes.client.openapi.models.V1ScopeSelectorFluent fluent, + io.kubernetes.client.openapi.models.V1ScopeSelector instance) { this(fluent, instance, false); } - public V1ScopeSelectorBuilder(io.kubernetes.client.openapi.models.V1ScopeSelectorFluent fluent,io.kubernetes.client.openapi.models.V1ScopeSelector instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ScopeSelectorBuilder( + io.kubernetes.client.openapi.models.V1ScopeSelectorFluent fluent, + io.kubernetes.client.openapi.models.V1ScopeSelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMatchExpressions(instance.getMatchExpressions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ScopeSelectorBuilder(io.kubernetes.client.openapi.models.V1ScopeSelector instance) { - this(instance,false); + this(instance, false); } - public V1ScopeSelectorBuilder(io.kubernetes.client.openapi.models.V1ScopeSelector instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ScopeSelectorBuilder( + io.kubernetes.client.openapi.models.V1ScopeSelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMatchExpressions(instance.getMatchExpressions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ScopeSelectorFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ScopeSelector build() { V1ScopeSelector buildable = new V1ScopeSelector(); buildable.setMatchExpressions(fluent.getMatchExpressions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ScopeSelectorBuilder that = (V1ScopeSelectorBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopeSelectorFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopeSelectorFluent.java index 7ef10cec61..754ced797f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopeSelectorFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopeSelectorFluent.java @@ -1,57 +1,122 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ScopeSelectorFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToMatchExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item); - public A setToMatchExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item); - public A addToMatchExpressions(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement... items); - public A addAllToMatchExpressions(java.util.Collection items); - public A removeFromMatchExpressions(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement... items); - public A removeAllFromMatchExpressions(java.util.Collection items); - public A removeMatchingFromMatchExpressions(java.util.function.Predicate predicate); - +/** Generated */ +public interface V1ScopeSelectorFluent< + A extends io.kubernetes.client.openapi.models.V1ScopeSelectorFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToMatchExpressions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item); + + public A setToMatchExpressions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item); + + public A addToMatchExpressions( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement... items); + + public A addAllToMatchExpressions( + java.util.Collection + items); + + public A removeFromMatchExpressions( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement... items); + + public A removeAllFromMatchExpressions( + java.util.Collection + items); + + public A removeMatchingFromMatchExpressions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder> + predicate); + /** * This method has been deprecated, please use method buildMatchExpressions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getMatchExpressions(); - public java.util.List buildMatchExpressions(); - public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement buildMatchExpression(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement buildFirstMatchExpression(); - public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement buildLastMatchExpression(); - public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement buildMatchingMatchExpression(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMatchExpression(java.util.function.Predicate predicate); - public A withMatchExpressions(java.util.List matchExpressions); - public A withMatchExpressions(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement... matchExpressions); + public java.util.List + getMatchExpressions(); + + public java.util.List + buildMatchExpressions(); + + public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement + buildMatchExpression(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement + buildFirstMatchExpression(); + + public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement + buildLastMatchExpression(); + + public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement + buildMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder> + predicate); + + public java.lang.Boolean hasMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder> + predicate); + + public A withMatchExpressions( + java.util.List + matchExpressions); + + public A withMatchExpressions( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement... matchExpressions); + public java.lang.Boolean hasMatchExpressions(); - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested addNewMatchExpression(); - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested addNewMatchExpressionLike(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item); - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested setNewMatchExpressionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item); - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested editMatchExpression(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested editFirstMatchExpression(); - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested editLastMatchExpression(); - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested editMatchingMatchExpression(java.util.function.Predicate predicate); - public interface MatchExpressionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent>{ + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + addNewMatchExpression(); + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + addNewMatchExpressionLike( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item); + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + setNewMatchExpressionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item); + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + editMatchExpression(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + editFirstMatchExpression(); + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + editLastMatchExpression(); + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + editMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder> + predicate); + + public interface MatchExpressionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent< + io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested> { public N and(); + public N endMatchExpression(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopeSelectorFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopeSelectorFluentImpl.java index 12183ea22e..10ef4c44cd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopeSelectorFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopeSelectorFluentImpl.java @@ -1,163 +1,352 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1ScopeSelectorFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ScopeSelectorFluent{ - public V1ScopeSelectorFluentImpl() { - } +/** Generated */ +public class V1ScopeSelectorFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ScopeSelectorFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ScopeSelectorFluent { + public V1ScopeSelectorFluentImpl() {} + public V1ScopeSelectorFluentImpl(io.kubernetes.client.openapi.models.V1ScopeSelector instance) { this.withMatchExpressions(instance.getMatchExpressions()); - } - private java.util.ArrayList matchExpressions; - public A addToMatchExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item) { - if (this.matchExpressions == null) {this.matchExpressions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(item);_visitables.get("matchExpressions").add(index >= 0 ? index : _visitables.get("matchExpressions").size(), builder);this.matchExpressions.add(index >= 0 ? index : matchExpressions.size(), builder); return (A)this; + + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder> + matchExpressions; + + public A addToMatchExpressions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item) { + if (this.matchExpressions == null) { + this.matchExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder>(); + } + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(item); + _visitables + .get("matchExpressions") + .add(index >= 0 ? index : _visitables.get("matchExpressions").size(), builder); + this.matchExpressions.add(index >= 0 ? index : matchExpressions.size(), builder); + return (A) this; } - public A setToMatchExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item) { - if (this.matchExpressions == null) {this.matchExpressions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(item); - if (index < 0 || index >= _visitables.get("matchExpressions").size()) { _visitables.get("matchExpressions").add(builder); } else { _visitables.get("matchExpressions").set(index, builder);} - if (index < 0 || index >= matchExpressions.size()) { matchExpressions.add(builder); } else { matchExpressions.set(index, builder);} - return (A)this; + + public A setToMatchExpressions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item) { + if (this.matchExpressions == null) { + this.matchExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder>(); + } + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(item); + if (index < 0 || index >= _visitables.get("matchExpressions").size()) { + _visitables.get("matchExpressions").add(builder); + } else { + _visitables.get("matchExpressions").set(index, builder); + } + if (index < 0 || index >= matchExpressions.size()) { + matchExpressions.add(builder); + } else { + matchExpressions.set(index, builder); + } + return (A) this; } - public A addToMatchExpressions(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement... items) { - if (this.matchExpressions == null) {this.matchExpressions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(item);_visitables.get("matchExpressions").add(builder);this.matchExpressions.add(builder);} return (A)this; + + public A addToMatchExpressions( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement... items) { + if (this.matchExpressions == null) { + this.matchExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(item); + _visitables.get("matchExpressions").add(builder); + this.matchExpressions.add(builder); + } + return (A) this; } - public A addAllToMatchExpressions(java.util.Collection items) { - if (this.matchExpressions == null) {this.matchExpressions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(item);_visitables.get("matchExpressions").add(builder);this.matchExpressions.add(builder);} return (A)this; + + public A addAllToMatchExpressions( + java.util.Collection + items) { + if (this.matchExpressions == null) { + this.matchExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(item); + _visitables.get("matchExpressions").add(builder); + this.matchExpressions.add(builder); + } + return (A) this; } - public A removeFromMatchExpressions(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement... items) { - for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(item);_visitables.get("matchExpressions").remove(builder);if (this.matchExpressions != null) {this.matchExpressions.remove(builder);}} return (A)this; + + public A removeFromMatchExpressions( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement... items) { + for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(item); + _visitables.get("matchExpressions").remove(builder); + if (this.matchExpressions != null) { + this.matchExpressions.remove(builder); + } + } + return (A) this; } - public A removeAllFromMatchExpressions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item : items) {io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(item);_visitables.get("matchExpressions").remove(builder);if (this.matchExpressions != null) {this.matchExpressions.remove(builder);}} return (A)this; + + public A removeAllFromMatchExpressions( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item : items) { + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(item); + _visitables.get("matchExpressions").remove(builder); + if (this.matchExpressions != null) { + this.matchExpressions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromMatchExpressions(java.util.function.Predicate predicate) { + + public A removeMatchingFromMatchExpressions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder> + predicate) { if (matchExpressions == null) return (A) this; - final Iterator each = matchExpressions.iterator(); + final Iterator + each = matchExpressions.iterator(); final List visitables = _visitables.get("matchExpressions"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildMatchExpressions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getMatchExpressions() { + public java.util.List + getMatchExpressions() { return matchExpressions != null ? build(matchExpressions) : null; } - public java.util.List buildMatchExpressions() { + + public java.util.List + buildMatchExpressions() { return matchExpressions != null ? build(matchExpressions) : null; } - public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement buildMatchExpression(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement + buildMatchExpression(java.lang.Integer index) { return this.matchExpressions.get(index).build(); } - public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement buildFirstMatchExpression() { + + public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement + buildFirstMatchExpression() { return this.matchExpressions.get(0).build(); } - public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement buildLastMatchExpression() { + + public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement + buildLastMatchExpression() { return this.matchExpressions.get(matchExpressions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement buildMatchingMatchExpression(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder item: matchExpressions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement + buildMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder item : + matchExpressions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingMatchExpression(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder item: matchExpressions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder item : + matchExpressions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withMatchExpressions(java.util.List matchExpressions) { - if (this.matchExpressions != null) { _visitables.get("matchExpressions").removeAll(this.matchExpressions);} - if (matchExpressions != null) {this.matchExpressions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item : matchExpressions){this.addToMatchExpressions(item);}} else { this.matchExpressions = null;} return (A) this; + + public A withMatchExpressions( + java.util.List + matchExpressions) { + if (this.matchExpressions != null) { + _visitables.get("matchExpressions").removeAll(this.matchExpressions); + } + if (matchExpressions != null) { + this.matchExpressions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item : + matchExpressions) { + this.addToMatchExpressions(item); + } + } else { + this.matchExpressions = null; + } + return (A) this; } - public A withMatchExpressions(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement... matchExpressions) { - if (this.matchExpressions != null) {this.matchExpressions.clear();} - if (matchExpressions != null) {for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item :matchExpressions){ this.addToMatchExpressions(item);}} return (A) this; + + public A withMatchExpressions( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement... matchExpressions) { + if (this.matchExpressions != null) { + this.matchExpressions.clear(); + } + if (matchExpressions != null) { + for (io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item : + matchExpressions) { + this.addToMatchExpressions(item); + } + } + return (A) this; } + public java.lang.Boolean hasMatchExpressions() { return matchExpressions != null && !matchExpressions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested addNewMatchExpression() { - return new io.kubernetes.client.openapi.models.V1ScopeSelectorFluentImpl.MatchExpressionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + addNewMatchExpression() { + return new io.kubernetes.client.openapi.models.V1ScopeSelectorFluentImpl + .MatchExpressionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested addNewMatchExpressionLike(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item) { - return new io.kubernetes.client.openapi.models.V1ScopeSelectorFluentImpl.MatchExpressionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + addNewMatchExpressionLike( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item) { + return new io.kubernetes.client.openapi.models.V1ScopeSelectorFluentImpl + .MatchExpressionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested setNewMatchExpressionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item) { - return new io.kubernetes.client.openapi.models.V1ScopeSelectorFluentImpl.MatchExpressionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + setNewMatchExpressionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item) { + return new io.kubernetes.client.openapi.models.V1ScopeSelectorFluentImpl + .MatchExpressionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested editMatchExpression(java.lang.Integer index) { - if (matchExpressions.size() <= index) throw new RuntimeException("Can't edit matchExpressions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + editMatchExpression(java.lang.Integer index) { + if (matchExpressions.size() <= index) + throw new RuntimeException("Can't edit matchExpressions. Index exceeds size."); return setNewMatchExpressionLike(index, buildMatchExpression(index)); } - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested editFirstMatchExpression() { - if (matchExpressions.size() == 0) throw new RuntimeException("Can't edit first matchExpressions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + editFirstMatchExpression() { + if (matchExpressions.size() == 0) + throw new RuntimeException("Can't edit first matchExpressions. The list is empty."); return setNewMatchExpressionLike(0, buildMatchExpression(0)); } - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested editLastMatchExpression() { + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + editLastMatchExpression() { int index = matchExpressions.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last matchExpressions. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last matchExpressions. The list is empty."); return setNewMatchExpressionLike(index, buildMatchExpression(index)); } - public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested editMatchingMatchExpression(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested + editMatchingMatchExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluentImpl> implements io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested,io.kubernetes.client.fluent.Nested{ - MatchExpressionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item) { + + public class MatchExpressionsNestedImpl + extends io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluentImpl< + io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested> + implements io.kubernetes.client.openapi.models.V1ScopeSelectorFluent.MatchExpressionsNested< + N>, + io.kubernetes.client.fluent.Nested { + MatchExpressionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder( + this, item); } + MatchExpressionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder(this); } + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ScopeSelectorFluentImpl.this.setToMatchExpressions(index,builder.build()); + return (N) V1ScopeSelectorFluentImpl.this.setToMatchExpressions(index, builder.build()); } + public N endMatchExpression() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopedResourceSelectorRequirementBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopedResourceSelectorRequirementBuilder.java index fc800677f1..ca6a85f66c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopedResourceSelectorRequirementBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopedResourceSelectorRequirementBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ScopedResourceSelectorRequirementBuilder extends io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ScopedResourceSelectorRequirementBuilder + extends io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluentImpl< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement, + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementBuilder> { public V1ScopedResourceSelectorRequirementBuilder() { this(false); } + public V1ScopedResourceSelectorRequirementBuilder(java.lang.Boolean validationEnabled) { this(new V1ScopedResourceSelectorRequirement(), validationEnabled); } - public V1ScopedResourceSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent fluent) { + + public V1ScopedResourceSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent fluent) { this(fluent, false); } - public V1ScopedResourceSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ScopedResourceSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ScopedResourceSelectorRequirement(), validationEnabled); } - public V1ScopedResourceSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent fluent,io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement instance) { + + public V1ScopedResourceSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent fluent, + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement instance) { this(fluent, instance, false); } - public V1ScopedResourceSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent fluent,io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ScopedResourceSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent fluent, + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withOperator(instance.getOperator()); fluent.withScopeName(instance.getScopeName()); fluent.withValues(instance.getValues()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ScopedResourceSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement instance) { - this(instance,false); + + public V1ScopedResourceSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement instance) { + this(instance, false); } - public V1ScopedResourceSelectorRequirementBuilder(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ScopedResourceSelectorRequirementBuilder( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withOperator(instance.getOperator()); this.withScopeName(instance.getScopeName()); this.withValues(instance.getValues()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement build() { V1ScopedResourceSelectorRequirement buildable = new V1ScopedResourceSelectorRequirement(); buildable.setOperator(fluent.getOperator()); @@ -51,18 +85,24 @@ public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement b buildable.setValues(fluent.getValues()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1ScopedResourceSelectorRequirementBuilder that = (V1ScopedResourceSelectorRequirementBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1ScopedResourceSelectorRequirementBuilder that = + (V1ScopedResourceSelectorRequirementBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopedResourceSelectorRequirementFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopedResourceSelectorRequirementFluent.java index 9c695eb1d3..f4b72a7f9c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopedResourceSelectorRequirementFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopedResourceSelectorRequirementFluent.java @@ -1,40 +1,70 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1ScopedResourceSelectorRequirementFluent> extends io.kubernetes.client.fluent.Fluent{ - public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.OperatorEnum getOperator(); - public A withOperator(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.OperatorEnum operator); +/** Generated */ +public interface V1ScopedResourceSelectorRequirementFluent< + A extends io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent> + extends io.kubernetes.client.fluent.Fluent { + public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.OperatorEnum + getOperator(); + + public A withOperator( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.OperatorEnum + operator); + public java.lang.Boolean hasOperator(); - public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.ScopeNameEnum getScopeName(); - public A withScopeName(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.ScopeNameEnum scopeName); + + public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.ScopeNameEnum + getScopeName(); + + public A withScopeName( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.ScopeNameEnum + scopeName); + public java.lang.Boolean hasScopeName(); - public A addToValues(java.lang.Integer index,java.lang.String item); - public A setToValues(java.lang.Integer index,java.lang.String item); + + public A addToValues(java.lang.Integer index, java.lang.String item); + + public A setToValues(java.lang.Integer index, java.lang.String item); + public A addToValues(java.lang.String... items); + public A addAllToValues(java.util.Collection items); + public A removeFromValues(java.lang.String... items); + public A removeAllFromValues(java.util.Collection items); + public java.util.List getValues(); + public java.lang.String getValue(java.lang.Integer index); + public java.lang.String getFirstValue(); + public java.lang.String getLastValue(); - public java.lang.String getMatchingValue(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingValue(java.util.function.Predicate predicate); + + public java.lang.String getMatchingValue( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingValue( + java.util.function.Predicate predicate); + public A withValues(java.util.List values); + public A withValues(java.lang.String... values); + public java.lang.Boolean hasValues(); + public A addNewValue(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopedResourceSelectorRequirementFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopedResourceSelectorRequirementFluentImpl.java index 3d935d2add..6cd05cf98d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopedResourceSelectorRequirementFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ScopedResourceSelectorRequirementFluentImpl.java @@ -1,115 +1,206 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1ScopedResourceSelectorRequirementFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent{ - public V1ScopedResourceSelectorRequirementFluentImpl() { - } - public V1ScopedResourceSelectorRequirementFluentImpl(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement instance) { +/** Generated */ +public class V1ScopedResourceSelectorRequirementFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirementFluent { + public V1ScopedResourceSelectorRequirementFluentImpl() {} + + public V1ScopedResourceSelectorRequirementFluentImpl( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement instance) { this.withOperator(instance.getOperator()); this.withScopeName(instance.getScopeName()); this.withValues(instance.getValues()); - } - private io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.OperatorEnum operator; - private io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.ScopeNameEnum scopeName; + + private io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.OperatorEnum + operator; + private io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.ScopeNameEnum + scopeName; private java.util.List values; - public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.OperatorEnum getOperator() { + + public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.OperatorEnum + getOperator() { return this.operator; } - public A withOperator(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.OperatorEnum operator) { - this.operator=operator; return (A) this; + + public A withOperator( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.OperatorEnum + operator) { + this.operator = operator; + return (A) this; } + public java.lang.Boolean hasOperator() { return this.operator != null; } - public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.ScopeNameEnum getScopeName() { + + public io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.ScopeNameEnum + getScopeName() { return this.scopeName; } - public A withScopeName(io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.ScopeNameEnum scopeName) { - this.scopeName=scopeName; return (A) this; + + public A withScopeName( + io.kubernetes.client.openapi.models.V1ScopedResourceSelectorRequirement.ScopeNameEnum + scopeName) { + this.scopeName = scopeName; + return (A) this; } + public java.lang.Boolean hasScopeName() { return this.scopeName != null; } - public A addToValues(java.lang.Integer index,java.lang.String item) { - if (this.values == null) {this.values = new java.util.ArrayList();} + + public A addToValues(java.lang.Integer index, java.lang.String item) { + if (this.values == null) { + this.values = new java.util.ArrayList(); + } this.values.add(index, item); - return (A)this; + return (A) this; } - public A setToValues(java.lang.Integer index,java.lang.String item) { - if (this.values == null) {this.values = new java.util.ArrayList();} - this.values.set(index, item); return (A)this; + + public A setToValues(java.lang.Integer index, java.lang.String item) { + if (this.values == null) { + this.values = new java.util.ArrayList(); + } + this.values.set(index, item); + return (A) this; } + public A addToValues(java.lang.String... items) { - if (this.values == null) {this.values = new java.util.ArrayList();} - for (java.lang.String item : items) {this.values.add(item);} return (A)this; + if (this.values == null) { + this.values = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.values.add(item); + } + return (A) this; } + public A addAllToValues(java.util.Collection items) { - if (this.values == null) {this.values = new java.util.ArrayList();} - for (java.lang.String item : items) {this.values.add(item);} return (A)this; + if (this.values == null) { + this.values = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.values.add(item); + } + return (A) this; } + public A removeFromValues(java.lang.String... items) { - for (java.lang.String item : items) {if (this.values!= null){ this.values.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.values != null) { + this.values.remove(item); + } + } + return (A) this; } + public A removeAllFromValues(java.util.Collection items) { - for (java.lang.String item : items) {if (this.values!= null){ this.values.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.values != null) { + this.values.remove(item); + } + } + return (A) this; } + public java.util.List getValues() { return this.values; } + public java.lang.String getValue(java.lang.Integer index) { return this.values.get(index); } + public java.lang.String getFirstValue() { return this.values.get(0); } + public java.lang.String getLastValue() { return this.values.get(values.size() - 1); } - public java.lang.String getMatchingValue(java.util.function.Predicate predicate) { - for (java.lang.String item: values) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingValue( + java.util.function.Predicate predicate) { + for (java.lang.String item : values) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingValue(java.util.function.Predicate predicate) { - for (java.lang.String item: values) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingValue( + java.util.function.Predicate predicate) { + for (java.lang.String item : values) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withValues(java.util.List values) { - if (values != null) {this.values = new java.util.ArrayList(); for (java.lang.String item : values){this.addToValues(item);}} else { this.values = null;} return (A) this; + if (values != null) { + this.values = new java.util.ArrayList(); + for (java.lang.String item : values) { + this.addToValues(item); + } + } else { + this.values = null; + } + return (A) this; } + public A withValues(java.lang.String... values) { - if (this.values != null) {this.values.clear();} - if (values != null) {for (java.lang.String item :values){ this.addToValues(item);}} return (A) this; + if (this.values != null) { + this.values.clear(); + } + if (values != null) { + for (java.lang.String item : values) { + this.addToValues(item); + } + } + return (A) this; } + public java.lang.Boolean hasValues() { return values != null && !values.isEmpty(); } + public A addNewValue(java.lang.String original) { - return (A)addToValues(new String(original)); + return (A) addToValues(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1ScopedResourceSelectorRequirementFluentImpl that = (V1ScopedResourceSelectorRequirementFluentImpl) o; - if (operator != null ? !operator.equals(that.operator) :that.operator != null) return false; - if (scopeName != null ? !scopeName.equals(that.scopeName) :that.scopeName != null) return false; - if (values != null ? !values.equals(that.values) :that.values != null) return false; + V1ScopedResourceSelectorRequirementFluentImpl that = + (V1ScopedResourceSelectorRequirementFluentImpl) o; + if (operator != null ? !operator.equals(that.operator) : that.operator != null) return false; + if (scopeName != null ? !scopeName.equals(that.scopeName) : that.scopeName != null) + return false; + if (values != null ? !values.equals(that.values) : that.values != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(operator, scopeName, values, super.hashCode()); + return java.util.Objects.hash(operator, scopeName, values, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SeccompProfileBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SeccompProfileBuilder.java index b03b47e49b..1fefc2f890 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SeccompProfileBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SeccompProfileBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SeccompProfileBuilder extends io.kubernetes.client.openapi.models.V1SeccompProfileFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SeccompProfileBuilder + extends io.kubernetes.client.openapi.models.V1SeccompProfileFluentImpl< + io.kubernetes.client.openapi.models.V1SeccompProfileBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SeccompProfile, + io.kubernetes.client.openapi.models.V1SeccompProfileBuilder> { public V1SeccompProfileBuilder() { this(false); } + public V1SeccompProfileBuilder(java.lang.Boolean validationEnabled) { this(new V1SeccompProfile(), validationEnabled); } - public V1SeccompProfileBuilder(io.kubernetes.client.openapi.models.V1SeccompProfileFluent fluent) { + + public V1SeccompProfileBuilder( + io.kubernetes.client.openapi.models.V1SeccompProfileFluent fluent) { this(fluent, false); } - public V1SeccompProfileBuilder(io.kubernetes.client.openapi.models.V1SeccompProfileFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SeccompProfileBuilder( + io.kubernetes.client.openapi.models.V1SeccompProfileFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SeccompProfile(), validationEnabled); } - public V1SeccompProfileBuilder(io.kubernetes.client.openapi.models.V1SeccompProfileFluent fluent,io.kubernetes.client.openapi.models.V1SeccompProfile instance) { + + public V1SeccompProfileBuilder( + io.kubernetes.client.openapi.models.V1SeccompProfileFluent fluent, + io.kubernetes.client.openapi.models.V1SeccompProfile instance) { this(fluent, instance, false); } - public V1SeccompProfileBuilder(io.kubernetes.client.openapi.models.V1SeccompProfileFluent fluent,io.kubernetes.client.openapi.models.V1SeccompProfile instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SeccompProfileBuilder( + io.kubernetes.client.openapi.models.V1SeccompProfileFluent fluent, + io.kubernetes.client.openapi.models.V1SeccompProfile instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLocalhostProfile(instance.getLocalhostProfile()); fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1SeccompProfileBuilder(io.kubernetes.client.openapi.models.V1SeccompProfile instance) { - this(instance,false); + this(instance, false); } - public V1SeccompProfileBuilder(io.kubernetes.client.openapi.models.V1SeccompProfile instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SeccompProfileBuilder( + io.kubernetes.client.openapi.models.V1SeccompProfile instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLocalhostProfile(instance.getLocalhostProfile()); this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SeccompProfileFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SeccompProfile build() { V1SeccompProfile buildable = new V1SeccompProfile(); buildable.setLocalhostProfile(fluent.getLocalhostProfile()); buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SeccompProfileBuilder that = (V1SeccompProfileBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SeccompProfileFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SeccompProfileFluent.java index 74e4d2aedc..8d4b113f62 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SeccompProfileFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SeccompProfileFluent.java @@ -1,26 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SeccompProfileFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SeccompProfileFluent< + A extends io.kubernetes.client.openapi.models.V1SeccompProfileFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getLocalhostProfile(); + public A withLocalhostProfile(java.lang.String localhostProfile); + public java.lang.Boolean hasLocalhostProfile(); - - /** - * Method is deprecated. use withLocalhostProfile instead. - */ + + /** Method is deprecated. use withLocalhostProfile instead. */ @java.lang.Deprecated public A withNewLocalhostProfile(java.lang.String original); + public io.kubernetes.client.openapi.models.V1SeccompProfile.TypeEnum getType(); + public A withType(io.kubernetes.client.openapi.models.V1SeccompProfile.TypeEnum type); + public java.lang.Boolean hasType(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SeccompProfileFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SeccompProfileFluentImpl.java index aca238eabe..57d073271b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SeccompProfileFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SeccompProfileFluentImpl.java @@ -1,61 +1,77 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1SeccompProfileFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SeccompProfileFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SeccompProfileFluent { + public V1SeccompProfileFluentImpl() {} - /** - * Generated - */ -public class V1SeccompProfileFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SeccompProfileFluent{ - public V1SeccompProfileFluentImpl() { - } public V1SeccompProfileFluentImpl(io.kubernetes.client.openapi.models.V1SeccompProfile instance) { this.withLocalhostProfile(instance.getLocalhostProfile()); this.withType(instance.getType()); - } + private java.lang.String localhostProfile; private io.kubernetes.client.openapi.models.V1SeccompProfile.TypeEnum type; + public java.lang.String getLocalhostProfile() { return this.localhostProfile; } + public A withLocalhostProfile(java.lang.String localhostProfile) { - this.localhostProfile=localhostProfile; return (A) this; + this.localhostProfile = localhostProfile; + return (A) this; } + public java.lang.Boolean hasLocalhostProfile() { return this.localhostProfile != null; } - - /** - * Method is deprecated. use withLocalhostProfile instead. - */ + + /** Method is deprecated. use withLocalhostProfile instead. */ @java.lang.Deprecated public A withNewLocalhostProfile(java.lang.String original) { - return (A)withLocalhostProfile(new String(original)); + return (A) withLocalhostProfile(new String(original)); } + public io.kubernetes.client.openapi.models.V1SeccompProfile.TypeEnum getType() { return this.type; } + public A withType(io.kubernetes.client.openapi.models.V1SeccompProfile.TypeEnum type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SeccompProfileFluentImpl that = (V1SeccompProfileFluentImpl) o; - if (localhostProfile != null ? !localhostProfile.equals(that.localhostProfile) :that.localhostProfile != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (localhostProfile != null + ? !localhostProfile.equals(that.localhostProfile) + : that.localhostProfile != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(localhostProfile, type, super.hashCode()); + return java.util.Objects.hash(localhostProfile, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretBuilder.java index 5b7e7d71f4..5508d4a1a2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SecretBuilder extends io.kubernetes.client.openapi.models.V1SecretFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SecretBuilder + extends io.kubernetes.client.openapi.models.V1SecretFluentImpl< + io.kubernetes.client.openapi.models.V1SecretBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Secret, + io.kubernetes.client.openapi.models.V1SecretBuilder> { public V1SecretBuilder() { this(false); } + public V1SecretBuilder(java.lang.Boolean validationEnabled) { this(new V1Secret(), validationEnabled); } + public V1SecretBuilder(io.kubernetes.client.openapi.models.V1SecretFluent fluent) { this(fluent, false); } - public V1SecretBuilder(io.kubernetes.client.openapi.models.V1SecretFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SecretBuilder( + io.kubernetes.client.openapi.models.V1SecretFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Secret(), validationEnabled); } - public V1SecretBuilder(io.kubernetes.client.openapi.models.V1SecretFluent fluent,io.kubernetes.client.openapi.models.V1Secret instance) { + + public V1SecretBuilder( + io.kubernetes.client.openapi.models.V1SecretFluent fluent, + io.kubernetes.client.openapi.models.V1Secret instance) { this(fluent, instance, false); } - public V1SecretBuilder(io.kubernetes.client.openapi.models.V1SecretFluent fluent,io.kubernetes.client.openapi.models.V1Secret instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SecretBuilder( + io.kubernetes.client.openapi.models.V1SecretFluent fluent, + io.kubernetes.client.openapi.models.V1Secret instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withData(instance.getData()); @@ -35,13 +61,16 @@ public V1SecretBuilder(io.kubernetes.client.openapi.models.V1SecretFluent flu fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1SecretBuilder(io.kubernetes.client.openapi.models.V1Secret instance) { - this(instance,false); + this(instance, false); } - public V1SecretBuilder(io.kubernetes.client.openapi.models.V1Secret instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SecretBuilder( + io.kubernetes.client.openapi.models.V1Secret instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withData(instance.getData()); @@ -56,10 +85,12 @@ public V1SecretBuilder(io.kubernetes.client.openapi.models.V1Secret instance,jav this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SecretFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Secret build() { V1Secret buildable = new V1Secret(); buildable.setApiVersion(fluent.getApiVersion()); @@ -71,18 +102,23 @@ public io.kubernetes.client.openapi.models.V1Secret build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SecretBuilder that = (V1SecretBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretEnvSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretEnvSourceBuilder.java index c7788c4982..b21e3305e7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretEnvSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretEnvSourceBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SecretEnvSourceBuilder extends io.kubernetes.client.openapi.models.V1SecretEnvSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SecretEnvSourceBuilder + extends io.kubernetes.client.openapi.models.V1SecretEnvSourceFluentImpl< + io.kubernetes.client.openapi.models.V1SecretEnvSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SecretEnvSource, + io.kubernetes.client.openapi.models.V1SecretEnvSourceBuilder> { public V1SecretEnvSourceBuilder() { this(false); } + public V1SecretEnvSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1SecretEnvSource(), validationEnabled); } - public V1SecretEnvSourceBuilder(io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent fluent) { + + public V1SecretEnvSourceBuilder( + io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent fluent) { this(fluent, false); } - public V1SecretEnvSourceBuilder(io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SecretEnvSourceBuilder( + io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SecretEnvSource(), validationEnabled); } - public V1SecretEnvSourceBuilder(io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent fluent,io.kubernetes.client.openapi.models.V1SecretEnvSource instance) { + + public V1SecretEnvSourceBuilder( + io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent fluent, + io.kubernetes.client.openapi.models.V1SecretEnvSource instance) { this(fluent, instance, false); } - public V1SecretEnvSourceBuilder(io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent fluent,io.kubernetes.client.openapi.models.V1SecretEnvSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SecretEnvSourceBuilder( + io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent fluent, + io.kubernetes.client.openapi.models.V1SecretEnvSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1SecretEnvSourceBuilder(io.kubernetes.client.openapi.models.V1SecretEnvSource instance) { - this(instance,false); + this(instance, false); } - public V1SecretEnvSourceBuilder(io.kubernetes.client.openapi.models.V1SecretEnvSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SecretEnvSourceBuilder( + io.kubernetes.client.openapi.models.V1SecretEnvSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SecretEnvSource build() { V1SecretEnvSource buildable = new V1SecretEnvSource(); buildable.setName(fluent.getName()); buildable.setOptional(fluent.getOptional()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SecretEnvSourceBuilder that = (V1SecretEnvSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretEnvSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretEnvSourceFluent.java index 13bb42c7f1..000ff628f4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretEnvSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretEnvSourceFluent.java @@ -1,26 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SecretEnvSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SecretEnvSourceFluent< + A extends io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Boolean getOptional(); + public A withOptional(java.lang.Boolean optional); + public java.lang.Boolean hasOptional(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretEnvSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretEnvSourceFluentImpl.java index 019db41814..8018029733 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretEnvSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretEnvSourceFluentImpl.java @@ -1,61 +1,76 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1SecretEnvSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent { + public V1SecretEnvSourceFluentImpl() {} - /** - * Generated - */ -public class V1SecretEnvSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SecretEnvSourceFluent{ - public V1SecretEnvSourceFluentImpl() { - } - public V1SecretEnvSourceFluentImpl(io.kubernetes.client.openapi.models.V1SecretEnvSource instance) { + public V1SecretEnvSourceFluentImpl( + io.kubernetes.client.openapi.models.V1SecretEnvSource instance) { this.withName(instance.getName()); this.withOptional(instance.getOptional()); - } + private java.lang.String name; private java.lang.Boolean optional; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Boolean getOptional() { return this.optional; } + public A withOptional(java.lang.Boolean optional) { - this.optional=optional; return (A) this; + this.optional = optional; + return (A) this; } + public java.lang.Boolean hasOptional() { return this.optional != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SecretEnvSourceFluentImpl that = (V1SecretEnvSourceFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (optional != null ? !optional.equals(that.optional) :that.optional != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (optional != null ? !optional.equals(that.optional) : that.optional != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, optional, super.hashCode()); + return java.util.Objects.hash(name, optional, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretFluent.java index 4a8edcc86c..d919f6e21f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretFluent.java @@ -1,81 +1,116 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1SecretFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SecretFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToData(java.lang.String key,byte[] value); - public A addToData(java.util.Map map); + + public A addToData(java.lang.String key, byte[] value); + + public A addToData(java.util.Map map); + public A removeFromData(java.lang.String key); - public A removeFromData(java.util.Map map); - public java.util.Map getData(); - public A withData(java.util.Map data); + + public A removeFromData(java.util.Map map); + + public java.util.Map getData(); + + public A withData(java.util.Map data); + public java.lang.Boolean hasData(); + public java.lang.Boolean getImmutable(); + public A withImmutable(java.lang.Boolean immutable); + public java.lang.Boolean hasImmutable(); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public A addToStringData(java.lang.String key,java.lang.String value); - public A addToStringData(java.util.Map map); + + public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public A addToStringData(java.lang.String key, java.lang.String value); + + public A addToStringData(java.util.Map map); + public A removeFromStringData(java.lang.String key); - public A removeFromStringData(java.util.Map map); - public java.util.Map getStringData(); - public A withStringData(java.util.Map stringData); + + public A removeFromStringData(java.util.Map map); + + public java.util.Map getStringData(); + + public A withStringData(java.util.Map stringData); + public java.lang.Boolean hasStringData(); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretFluentImpl.java index f8c111fdd3..3f3e9cf030 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretFluentImpl.java @@ -1,20 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public class V1SecretFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SecretFluent{ - public V1SecretFluentImpl() { - } +/** Generated */ +public class V1SecretFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SecretFluent { + public V1SecretFluentImpl() {} + public V1SecretFluentImpl(io.kubernetes.client.openapi.models.V1Secret instance) { this.withApiVersion(instance.getApiVersion()); @@ -29,190 +32,303 @@ public V1SecretFluentImpl(io.kubernetes.client.openapi.models.V1Secret instance) this.withStringData(instance.getStringData()); this.withType(instance.getType()); - } + private java.lang.String apiVersion; - private java.util.Map data; + private java.util.Map data; private java.lang.Boolean immutable; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; - private java.util.Map stringData; + private java.util.Map stringData; private java.lang.String type; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToData(java.lang.String key,byte[] value) { - if(this.data == null && key != null && value != null) { this.data = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.data.put(key, value);} return (A)this; + + public A addToData(java.lang.String key, byte[] value) { + if (this.data == null && key != null && value != null) { + this.data = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.data.put(key, value); + } + return (A) this; } - public A addToData(java.util.Map map) { - if(this.data == null && map != null) { this.data = new java.util.LinkedHashMap(); } - if(map != null) { this.data.putAll(map);} return (A)this; + + public A addToData(java.util.Map map) { + if (this.data == null && map != null) { + this.data = new java.util.LinkedHashMap(); + } + if (map != null) { + this.data.putAll(map); + } + return (A) this; } + public A removeFromData(java.lang.String key) { - if(this.data == null) { return (A) this; } - if(key != null && this.data != null) {this.data.remove(key);} return (A)this; + if (this.data == null) { + return (A) this; + } + if (key != null && this.data != null) { + this.data.remove(key); + } + return (A) this; } - public A removeFromData(java.util.Map map) { - if(this.data == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.data != null){this.data.remove(key);}}} return (A)this; + + public A removeFromData(java.util.Map map) { + if (this.data == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.data != null) { + this.data.remove(key); + } + } + } + return (A) this; } - public java.util.Map getData() { + + public java.util.Map getData() { return this.data; } - public A withData(java.util.Map data) { - if (data == null) { this.data = null;} else {this.data = new java.util.LinkedHashMap(data);} return (A) this; + + public A withData(java.util.Map data) { + if (data == null) { + this.data = null; + } else { + this.data = new java.util.LinkedHashMap(data); + } + return (A) this; } + public java.lang.Boolean hasData() { return this.data != null; } + public java.lang.Boolean getImmutable() { return this.immutable; } + public A withImmutable(java.lang.Boolean immutable) { - this.immutable=immutable; return (A) this; + this.immutable = immutable; + return (A) this; } + public java.lang.Boolean hasImmutable() { return this.immutable != null; } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1SecretFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1SecretFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - public A addToStringData(java.lang.String key,java.lang.String value) { - if(this.stringData == null && key != null && value != null) { this.stringData = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.stringData.put(key, value);} return (A)this; + + public A addToStringData(java.lang.String key, java.lang.String value) { + if (this.stringData == null && key != null && value != null) { + this.stringData = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.stringData.put(key, value); + } + return (A) this; } - public A addToStringData(java.util.Map map) { - if(this.stringData == null && map != null) { this.stringData = new java.util.LinkedHashMap(); } - if(map != null) { this.stringData.putAll(map);} return (A)this; + + public A addToStringData(java.util.Map map) { + if (this.stringData == null && map != null) { + this.stringData = new java.util.LinkedHashMap(); + } + if (map != null) { + this.stringData.putAll(map); + } + return (A) this; } + public A removeFromStringData(java.lang.String key) { - if(this.stringData == null) { return (A) this; } - if(key != null && this.stringData != null) {this.stringData.remove(key);} return (A)this; + if (this.stringData == null) { + return (A) this; + } + if (key != null && this.stringData != null) { + this.stringData.remove(key); + } + return (A) this; } - public A removeFromStringData(java.util.Map map) { - if(this.stringData == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.stringData != null){this.stringData.remove(key);}}} return (A)this; + + public A removeFromStringData(java.util.Map map) { + if (this.stringData == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.stringData != null) { + this.stringData.remove(key); + } + } + } + return (A) this; } - public java.util.Map getStringData() { + + public java.util.Map getStringData() { return this.stringData; } - public A withStringData(java.util.Map stringData) { - if (stringData == null) { this.stringData = null;} else {this.stringData = new java.util.LinkedHashMap(stringData);} return (A) this; + + public A withStringData(java.util.Map stringData) { + if (stringData == null) { + this.stringData = null; + } else { + this.stringData = new java.util.LinkedHashMap(stringData); + } + return (A) this; } + public java.lang.Boolean hasStringData() { return this.stringData != null; } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SecretFluentImpl that = (V1SecretFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (data != null ? !data.equals(that.data) :that.data != null) return false; - if (immutable != null ? !immutable.equals(that.immutable) :that.immutable != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (stringData != null ? !stringData.equals(that.stringData) :that.stringData != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (data != null ? !data.equals(that.data) : that.data != null) return false; + if (immutable != null ? !immutable.equals(that.immutable) : that.immutable != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (stringData != null ? !stringData.equals(that.stringData) : that.stringData != null) + return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, data, immutable, kind, metadata, stringData, type, super.hashCode()); + return java.util.Objects.hash( + apiVersion, data, immutable, kind, metadata, stringData, type, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1SecretFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1SecretFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretKeySelectorBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretKeySelectorBuilder.java index de262752a0..f48a72e4a4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretKeySelectorBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretKeySelectorBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SecretKeySelectorBuilder extends io.kubernetes.client.openapi.models.V1SecretKeySelectorFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SecretKeySelectorBuilder + extends io.kubernetes.client.openapi.models.V1SecretKeySelectorFluentImpl< + io.kubernetes.client.openapi.models.V1SecretKeySelectorBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SecretKeySelector, + io.kubernetes.client.openapi.models.V1SecretKeySelectorBuilder> { public V1SecretKeySelectorBuilder() { this(false); } + public V1SecretKeySelectorBuilder(java.lang.Boolean validationEnabled) { this(new V1SecretKeySelector(), validationEnabled); } - public V1SecretKeySelectorBuilder(io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent fluent) { + + public V1SecretKeySelectorBuilder( + io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent fluent) { this(fluent, false); } - public V1SecretKeySelectorBuilder(io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SecretKeySelectorBuilder( + io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SecretKeySelector(), validationEnabled); } - public V1SecretKeySelectorBuilder(io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent fluent,io.kubernetes.client.openapi.models.V1SecretKeySelector instance) { + + public V1SecretKeySelectorBuilder( + io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent fluent, + io.kubernetes.client.openapi.models.V1SecretKeySelector instance) { this(fluent, instance, false); } - public V1SecretKeySelectorBuilder(io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent fluent,io.kubernetes.client.openapi.models.V1SecretKeySelector instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SecretKeySelectorBuilder( + io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent fluent, + io.kubernetes.client.openapi.models.V1SecretKeySelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withKey(instance.getKey()); fluent.withName(instance.getName()); fluent.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1SecretKeySelectorBuilder(io.kubernetes.client.openapi.models.V1SecretKeySelector instance) { - this(instance,false); + + public V1SecretKeySelectorBuilder( + io.kubernetes.client.openapi.models.V1SecretKeySelector instance) { + this(instance, false); } - public V1SecretKeySelectorBuilder(io.kubernetes.client.openapi.models.V1SecretKeySelector instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SecretKeySelectorBuilder( + io.kubernetes.client.openapi.models.V1SecretKeySelector instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withKey(instance.getKey()); this.withName(instance.getName()); this.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SecretKeySelector build() { V1SecretKeySelector buildable = new V1SecretKeySelector(); buildable.setKey(fluent.getKey()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1SecretKeySelector build() { buildable.setOptional(fluent.getOptional()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SecretKeySelectorBuilder that = (V1SecretKeySelectorBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretKeySelectorFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretKeySelectorFluent.java index d88f789ad9..27c64de74e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretKeySelectorFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretKeySelectorFluent.java @@ -1,35 +1,44 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SecretKeySelectorFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SecretKeySelectorFluent< + A extends io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getKey(); + public A withKey(java.lang.String key); + public java.lang.Boolean hasKey(); - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Boolean getOptional(); + public A withOptional(java.lang.Boolean optional); + public java.lang.Boolean hasOptional(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretKeySelectorFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretKeySelectorFluentImpl.java index b3a13ca493..84270ce03f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretKeySelectorFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretKeySelectorFluentImpl.java @@ -1,82 +1,99 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1SecretKeySelectorFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent{ - public V1SecretKeySelectorFluentImpl() { - } - public V1SecretKeySelectorFluentImpl(io.kubernetes.client.openapi.models.V1SecretKeySelector instance) { +/** Generated */ +public class V1SecretKeySelectorFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SecretKeySelectorFluent { + public V1SecretKeySelectorFluentImpl() {} + + public V1SecretKeySelectorFluentImpl( + io.kubernetes.client.openapi.models.V1SecretKeySelector instance) { this.withKey(instance.getKey()); this.withName(instance.getName()); this.withOptional(instance.getOptional()); - } + private java.lang.String key; private java.lang.String name; private java.lang.Boolean optional; + public java.lang.String getKey() { return this.key; } + public A withKey(java.lang.String key) { - this.key=key; return (A) this; + this.key = key; + return (A) this; } + public java.lang.Boolean hasKey() { return this.key != null; } - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original) { - return (A)withKey(new String(original)); + return (A) withKey(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Boolean getOptional() { return this.optional; } + public A withOptional(java.lang.Boolean optional) { - this.optional=optional; return (A) this; + this.optional = optional; + return (A) this; } + public java.lang.Boolean hasOptional() { return this.optional != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SecretKeySelectorFluentImpl that = (V1SecretKeySelectorFluentImpl) o; - if (key != null ? !key.equals(that.key) :that.key != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (optional != null ? !optional.equals(that.optional) :that.optional != null) return false; + if (key != null ? !key.equals(that.key) : that.key != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (optional != null ? !optional.equals(that.optional) : that.optional != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(key, name, optional, super.hashCode()); + return java.util.Objects.hash(key, name, optional, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretListBuilder.java index eec6bbb7fb..a6eb2420e6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretListBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SecretListBuilder extends io.kubernetes.client.openapi.models.V1SecretListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SecretListBuilder + extends io.kubernetes.client.openapi.models.V1SecretListFluentImpl< + io.kubernetes.client.openapi.models.V1SecretListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SecretList, + io.kubernetes.client.openapi.models.V1SecretListBuilder> { public V1SecretListBuilder() { this(false); } + public V1SecretListBuilder(java.lang.Boolean validationEnabled) { this(new V1SecretList(), validationEnabled); } + public V1SecretListBuilder(io.kubernetes.client.openapi.models.V1SecretListFluent fluent) { this(fluent, false); } - public V1SecretListBuilder(io.kubernetes.client.openapi.models.V1SecretListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SecretListBuilder( + io.kubernetes.client.openapi.models.V1SecretListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SecretList(), validationEnabled); } - public V1SecretListBuilder(io.kubernetes.client.openapi.models.V1SecretListFluent fluent,io.kubernetes.client.openapi.models.V1SecretList instance) { + + public V1SecretListBuilder( + io.kubernetes.client.openapi.models.V1SecretListFluent fluent, + io.kubernetes.client.openapi.models.V1SecretList instance) { this(fluent, instance, false); } - public V1SecretListBuilder(io.kubernetes.client.openapi.models.V1SecretListFluent fluent,io.kubernetes.client.openapi.models.V1SecretList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SecretListBuilder( + io.kubernetes.client.openapi.models.V1SecretListFluent fluent, + io.kubernetes.client.openapi.models.V1SecretList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +55,17 @@ public V1SecretListBuilder(io.kubernetes.client.openapi.models.V1SecretListFluen fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1SecretListBuilder(io.kubernetes.client.openapi.models.V1SecretList instance) { - this(instance,false); + this(instance, false); } - public V1SecretListBuilder(io.kubernetes.client.openapi.models.V1SecretList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SecretListBuilder( + io.kubernetes.client.openapi.models.V1SecretList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +74,12 @@ public V1SecretListBuilder(io.kubernetes.client.openapi.models.V1SecretList inst this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SecretListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SecretList build() { V1SecretList buildable = new V1SecretList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1SecretList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SecretListBuilder that = (V1SecretListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretListFluent.java index 2e46de10d5..7bad68d311 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretListFluent.java @@ -1,95 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SecretListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SecretListFluent< + A extends io.kubernetes.client.openapi.models.V1SecretListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Secret item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Secret item); + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Secret item); + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Secret item); + public A addToItems(io.kubernetes.client.openapi.models.V1Secret... items); + public A addAllToItems(java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1Secret... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1Secret buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Secret buildFirstItem(); + public io.kubernetes.client.openapi.models.V1Secret buildLastItem(); - public io.kubernetes.client.openapi.models.V1Secret buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Secret buildMatchingItem( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1Secret... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Secret item); - public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Secret item); - public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Secret item); + + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Secret item); + + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretFluent>{ + + public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretFluent< + io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretListFluentImpl.java index 0d3a762ee6..d46056d9a6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1SecretListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SecretListFluent{ - public V1SecretListFluentImpl() { - } +/** Generated */ +public class V1SecretListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SecretListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SecretListFluent { + public V1SecretListFluentImpl() {} + public V1SecretListFluentImpl(io.kubernetes.client.openapi.models.V1SecretList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,115 @@ public V1SecretListFluentImpl(io.kubernetes.client.openapi.models.V1SecretList i this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Secret item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1SecretBuilder builder = new io.kubernetes.client.openapi.models.V1SecretBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Secret item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1SecretBuilder builder = + new io.kubernetes.client.openapi.models.V1SecretBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Secret item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1SecretBuilder builder = new io.kubernetes.client.openapi.models.V1SecretBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Secret item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1SecretBuilder builder = + new io.kubernetes.client.openapi.models.V1SecretBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1Secret... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Secret item : items) {io.kubernetes.client.openapi.models.V1SecretBuilder builder = new io.kubernetes.client.openapi.models.V1SecretBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Secret item : items) { + io.kubernetes.client.openapi.models.V1SecretBuilder builder = + new io.kubernetes.client.openapi.models.V1SecretBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Secret item : items) {io.kubernetes.client.openapi.models.V1SecretBuilder builder = new io.kubernetes.client.openapi.models.V1SecretBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Secret item : items) { + io.kubernetes.client.openapi.models.V1SecretBuilder builder = + new io.kubernetes.client.openapi.models.V1SecretBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1Secret... items) { - for (io.kubernetes.client.openapi.models.V1Secret item : items) {io.kubernetes.client.openapi.models.V1SecretBuilder builder = new io.kubernetes.client.openapi.models.V1SecretBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Secret item : items) { + io.kubernetes.client.openapi.models.V1SecretBuilder builder = + new io.kubernetes.client.openapi.models.V1SecretBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Secret item : items) {io.kubernetes.client.openapi.models.V1SecretBuilder builder = new io.kubernetes.client.openapi.models.V1SecretBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Secret item : items) { + io.kubernetes.client.openapi.models.V1SecretBuilder builder = + new io.kubernetes.client.openapi.models.V1SecretBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +149,268 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1Secret buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Secret buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Secret buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Secret buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1SecretBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Secret buildMatchingItem( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1SecretBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1SecretBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate) { + for (io.kubernetes.client.openapi.models.V1SecretBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Secret item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Secret item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1Secret... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1Secret item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1Secret item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1SecretListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Secret item) { + + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Secret item) { return new io.kubernetes.client.openapi.models.V1SecretListFluentImpl.ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Secret item) { - return new io.kubernetes.client.openapi.models.V1SecretListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Secret item) { + return new io.kubernetes.client.openapi.models.V1SecretListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1SecretListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + + public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { return new io.kubernetes.client.openapi.models.V1SecretListFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SecretListFluentImpl that = (V1SecretListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1SecretFluentImpl> implements io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Secret item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretFluentImpl< + io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1SecretListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Secret item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1SecretBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1SecretBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1SecretListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1SecretListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1SecretListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1SecretListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretProjectionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretProjectionBuilder.java index edde77e905..105665073b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretProjectionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretProjectionBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SecretProjectionBuilder extends io.kubernetes.client.openapi.models.V1SecretProjectionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SecretProjectionBuilder + extends io.kubernetes.client.openapi.models.V1SecretProjectionFluentImpl< + io.kubernetes.client.openapi.models.V1SecretProjectionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SecretProjection, + io.kubernetes.client.openapi.models.V1SecretProjectionBuilder> { public V1SecretProjectionBuilder() { this(false); } + public V1SecretProjectionBuilder(java.lang.Boolean validationEnabled) { this(new V1SecretProjection(), validationEnabled); } - public V1SecretProjectionBuilder(io.kubernetes.client.openapi.models.V1SecretProjectionFluent fluent) { + + public V1SecretProjectionBuilder( + io.kubernetes.client.openapi.models.V1SecretProjectionFluent fluent) { this(fluent, false); } - public V1SecretProjectionBuilder(io.kubernetes.client.openapi.models.V1SecretProjectionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SecretProjectionBuilder( + io.kubernetes.client.openapi.models.V1SecretProjectionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SecretProjection(), validationEnabled); } - public V1SecretProjectionBuilder(io.kubernetes.client.openapi.models.V1SecretProjectionFluent fluent,io.kubernetes.client.openapi.models.V1SecretProjection instance) { + + public V1SecretProjectionBuilder( + io.kubernetes.client.openapi.models.V1SecretProjectionFluent fluent, + io.kubernetes.client.openapi.models.V1SecretProjection instance) { this(fluent, instance, false); } - public V1SecretProjectionBuilder(io.kubernetes.client.openapi.models.V1SecretProjectionFluent fluent,io.kubernetes.client.openapi.models.V1SecretProjection instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SecretProjectionBuilder( + io.kubernetes.client.openapi.models.V1SecretProjectionFluent fluent, + io.kubernetes.client.openapi.models.V1SecretProjection instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withItems(instance.getItems()); fluent.withName(instance.getName()); fluent.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1SecretProjectionBuilder(io.kubernetes.client.openapi.models.V1SecretProjection instance) { - this(instance,false); + + public V1SecretProjectionBuilder( + io.kubernetes.client.openapi.models.V1SecretProjection instance) { + this(instance, false); } - public V1SecretProjectionBuilder(io.kubernetes.client.openapi.models.V1SecretProjection instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SecretProjectionBuilder( + io.kubernetes.client.openapi.models.V1SecretProjection instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withItems(instance.getItems()); this.withName(instance.getName()); this.withOptional(instance.getOptional()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SecretProjectionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SecretProjection build() { V1SecretProjection buildable = new V1SecretProjection(); buildable.setItems(fluent.getItems()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1SecretProjection build() { buildable.setOptional(fluent.getOptional()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SecretProjectionBuilder that = (V1SecretProjectionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretProjectionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretProjectionFluent.java index 61445b3d52..6bcace34e1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretProjectionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretProjectionFluent.java @@ -1,69 +1,114 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SecretProjectionFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item); +/** Generated */ +public interface V1SecretProjectionFluent< + A extends io.kubernetes.client.openapi.models.V1SecretProjectionFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item); + public A addToItems(io.kubernetes.client.openapi.models.V1KeyToPath... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1KeyToPath... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1KeyToPath buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1KeyToPath buildFirstItem(); + public io.kubernetes.client.openapi.models.V1KeyToPath buildLastItem(); - public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1KeyToPath... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item); - public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item); - public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested editFirstItem(); + + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1KeyToPath item); + + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item); + + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested + editFirstItem(); + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Boolean getOptional(); + public A withOptional(java.lang.Boolean optional); + public java.lang.Boolean hasOptional(); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1KeyToPathFluent>{ + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1KeyToPathFluent< + io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested> { public N and(); + public N endItem(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretProjectionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretProjectionFluentImpl.java index bf1de9b90a..d490e86a89 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretProjectionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretProjectionFluentImpl.java @@ -1,62 +1,131 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1SecretProjectionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SecretProjectionFluent{ - public V1SecretProjectionFluentImpl() { - } - public V1SecretProjectionFluentImpl(io.kubernetes.client.openapi.models.V1SecretProjection instance) { +/** Generated */ +public class V1SecretProjectionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SecretProjectionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SecretProjectionFluent { + public V1SecretProjectionFluentImpl() {} + + public V1SecretProjectionFluentImpl( + io.kubernetes.client.openapi.models.V1SecretProjection instance) { this.withItems(instance.getItems()); this.withName(instance.getName()); this.withOptional(instance.getOptional()); - } + private java.util.ArrayList items; private java.lang.String name; private java.lang.Boolean optional; - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1KeyToPath... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1KeyToPath... items) { - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -67,132 +136,208 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1KeyToPath buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1KeyToPath buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1KeyToPath buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1KeyToPath item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1KeyToPath... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1KeyToPath item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1SecretProjectionFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item) { - return new io.kubernetes.client.openapi.models.V1SecretProjectionFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1KeyToPath item) { + return new io.kubernetes.client.openapi.models.V1SecretProjectionFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { - return new io.kubernetes.client.openapi.models.V1SecretProjectionFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { + return new io.kubernetes.client.openapi.models.V1SecretProjectionFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1KeyToPathFluentImpl> implements io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1KeyToPathFluentImpl< + io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1SecretProjectionFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(this); } + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1SecretProjectionFluentImpl.this.setToItems(index,builder.build()); + return (N) V1SecretProjectionFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretReferenceBuilder.java index f75a970b51..7a842ed4c3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretReferenceBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SecretReferenceBuilder extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SecretReferenceBuilder + extends io.kubernetes.client.openapi.models.V1SecretReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1SecretReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SecretReference, + io.kubernetes.client.openapi.models.V1SecretReferenceBuilder> { public V1SecretReferenceBuilder() { this(false); } + public V1SecretReferenceBuilder(java.lang.Boolean validationEnabled) { this(new V1SecretReference(), validationEnabled); } - public V1SecretReferenceBuilder(io.kubernetes.client.openapi.models.V1SecretReferenceFluent fluent) { + + public V1SecretReferenceBuilder( + io.kubernetes.client.openapi.models.V1SecretReferenceFluent fluent) { this(fluent, false); } - public V1SecretReferenceBuilder(io.kubernetes.client.openapi.models.V1SecretReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SecretReferenceBuilder( + io.kubernetes.client.openapi.models.V1SecretReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SecretReference(), validationEnabled); } - public V1SecretReferenceBuilder(io.kubernetes.client.openapi.models.V1SecretReferenceFluent fluent,io.kubernetes.client.openapi.models.V1SecretReference instance) { + + public V1SecretReferenceBuilder( + io.kubernetes.client.openapi.models.V1SecretReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1SecretReference instance) { this(fluent, instance, false); } - public V1SecretReferenceBuilder(io.kubernetes.client.openapi.models.V1SecretReferenceFluent fluent,io.kubernetes.client.openapi.models.V1SecretReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SecretReferenceBuilder( + io.kubernetes.client.openapi.models.V1SecretReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1SecretReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withNamespace(instance.getNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1SecretReferenceBuilder(io.kubernetes.client.openapi.models.V1SecretReference instance) { - this(instance,false); + this(instance, false); } - public V1SecretReferenceBuilder(io.kubernetes.client.openapi.models.V1SecretReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SecretReferenceBuilder( + io.kubernetes.client.openapi.models.V1SecretReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withNamespace(instance.getNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SecretReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SecretReference build() { V1SecretReference buildable = new V1SecretReference(); buildable.setName(fluent.getName()); buildable.setNamespace(fluent.getNamespace()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SecretReferenceBuilder that = (V1SecretReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretReferenceFluent.java index 8026b86c28..190c72a7b5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretReferenceFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SecretReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SecretReferenceFluent< + A extends io.kubernetes.client.openapi.models.V1SecretReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getNamespace(); + public A withNamespace(java.lang.String namespace); + public java.lang.Boolean hasNamespace(); - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretReferenceFluentImpl.java index 2650ed4aed..2e201fe10c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretReferenceFluentImpl.java @@ -1,69 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1SecretReferenceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SecretReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SecretReferenceFluent { + public V1SecretReferenceFluentImpl() {} - /** - * Generated - */ -public class V1SecretReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SecretReferenceFluent{ - public V1SecretReferenceFluentImpl() { - } - public V1SecretReferenceFluentImpl(io.kubernetes.client.openapi.models.V1SecretReference instance) { + public V1SecretReferenceFluentImpl( + io.kubernetes.client.openapi.models.V1SecretReference instance) { this.withName(instance.getName()); this.withNamespace(instance.getNamespace()); - } + private java.lang.String name; private java.lang.String namespace; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getNamespace() { return this.namespace; } + public A withNamespace(java.lang.String namespace) { - this.namespace=namespace; return (A) this; + this.namespace = namespace; + return (A) this; } + public java.lang.Boolean hasNamespace() { return this.namespace != null; } - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original) { - return (A)withNamespace(new String(original)); + return (A) withNamespace(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SecretReferenceFluentImpl that = (V1SecretReferenceFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (namespace != null ? !namespace.equals(that.namespace) :that.namespace != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (namespace != null ? !namespace.equals(that.namespace) : that.namespace != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, namespace, super.hashCode()); + return java.util.Objects.hash(name, namespace, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretVolumeSourceBuilder.java index 32dbe1410f..18b6390565 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SecretVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SecretVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1SecretVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SecretVolumeSource, + io.kubernetes.client.openapi.models.V1SecretVolumeSourceBuilder> { public V1SecretVolumeSourceBuilder() { this(false); } + public V1SecretVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1SecretVolumeSource(), validationEnabled); } - public V1SecretVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent fluent) { + + public V1SecretVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent fluent) { this(fluent, false); } - public V1SecretVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SecretVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SecretVolumeSource(), validationEnabled); } - public V1SecretVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1SecretVolumeSource instance) { + + public V1SecretVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1SecretVolumeSource instance) { this(fluent, instance, false); } - public V1SecretVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1SecretVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SecretVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1SecretVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDefaultMode(instance.getDefaultMode()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1SecretVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1SecretV fluent.withSecretName(instance.getSecretName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1SecretVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1SecretVolumeSource instance) { - this(instance,false); + + public V1SecretVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1SecretVolumeSource instance) { + this(instance, false); } - public V1SecretVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1SecretVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SecretVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1SecretVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDefaultMode(instance.getDefaultMode()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1SecretVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1SecretV this.withSecretName(instance.getSecretName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SecretVolumeSource build() { V1SecretVolumeSource buildable = new V1SecretVolumeSource(); buildable.setDefaultMode(fluent.getDefaultMode()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1SecretVolumeSource build() { buildable.setSecretName(fluent.getSecretName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SecretVolumeSourceBuilder that = (V1SecretVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretVolumeSourceFluent.java index 0618c00cbc..57b363bb97 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretVolumeSourceFluent.java @@ -1,72 +1,121 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SecretVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SecretVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getDefaultMode(); + public A withDefaultMode(java.lang.Integer defaultMode); + public java.lang.Boolean hasDefaultMode(); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item); + public A addToItems(io.kubernetes.client.openapi.models.V1KeyToPath... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1KeyToPath... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1KeyToPath buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1KeyToPath buildFirstItem(); + public io.kubernetes.client.openapi.models.V1KeyToPath buildLastItem(); - public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1KeyToPath... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item); - public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item); - public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item); + + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested + setNewItemLike(java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item); + + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.Boolean getOptional(); + public A withOptional(java.lang.Boolean optional); + public java.lang.Boolean hasOptional(); + public java.lang.String getSecretName(); + public A withSecretName(java.lang.String secretName); + public java.lang.Boolean hasSecretName(); - - /** - * Method is deprecated. use withSecretName instead. - */ + + /** Method is deprecated. use withSecretName instead. */ @java.lang.Deprecated public A withNewSecretName(java.lang.String original); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1KeyToPathFluent>{ + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1KeyToPathFluent< + io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested> { public N and(); + public N endItem(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretVolumeSourceFluentImpl.java index d3db9349c0..e9a85a3472 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecretVolumeSourceFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1SecretVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent{ - public V1SecretVolumeSourceFluentImpl() { - } - public V1SecretVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1SecretVolumeSource instance) { +/** Generated */ +public class V1SecretVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent { + public V1SecretVolumeSourceFluentImpl() {} + + public V1SecretVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1SecretVolumeSource instance) { this.withDefaultMode(instance.getDefaultMode()); this.withItems(instance.getItems()); @@ -28,47 +31,117 @@ public V1SecretVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1Secr this.withOptional(instance.getOptional()); this.withSecretName(instance.getSecretName()); - } + private java.lang.Integer defaultMode; private java.util.ArrayList items; private java.lang.Boolean optional; private java.lang.String secretName; + public java.lang.Integer getDefaultMode() { return this.defaultMode; } + public A withDefaultMode(java.lang.Integer defaultMode) { - this.defaultMode=defaultMode; return (A) this; + this.defaultMode = defaultMode; + return (A) this; } + public java.lang.Boolean hasDefaultMode() { return this.defaultMode != null; } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1KeyToPath... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1KeyToPath... items) { - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) {io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder = + new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -79,133 +152,213 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1KeyToPath buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1KeyToPath buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1KeyToPath buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1KeyToPath buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1KeyToPathBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1KeyToPath item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1KeyToPath... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1KeyToPath item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1KeyToPath item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested addNewItem() { + + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested + addNewItem() { return new io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item) { - return new io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1KeyToPath item) { + return new io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { - return new io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { + return new io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1KeyToPathFluentImpl> implements io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1KeyToPath item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1KeyToPathFluentImpl< + io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1KeyToPath item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1KeyToPathBuilder(this); } + io.kubernetes.client.openapi.models.V1KeyToPathBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1SecretVolumeSourceFluentImpl.this.setToItems(index,builder.build()); + return (N) V1SecretVolumeSourceFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecurityContextBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecurityContextBuilder.java index cdace65984..e565a8a351 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecurityContextBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecurityContextBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SecurityContextBuilder extends io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SecurityContextBuilder + extends io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl< + io.kubernetes.client.openapi.models.V1SecurityContextBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SecurityContext, + io.kubernetes.client.openapi.models.V1SecurityContextBuilder> { public V1SecurityContextBuilder() { this(false); } + public V1SecurityContextBuilder(java.lang.Boolean validationEnabled) { this(new V1SecurityContext(), validationEnabled); } - public V1SecurityContextBuilder(io.kubernetes.client.openapi.models.V1SecurityContextFluent fluent) { + + public V1SecurityContextBuilder( + io.kubernetes.client.openapi.models.V1SecurityContextFluent fluent) { this(fluent, false); } - public V1SecurityContextBuilder(io.kubernetes.client.openapi.models.V1SecurityContextFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SecurityContextBuilder( + io.kubernetes.client.openapi.models.V1SecurityContextFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SecurityContext(), validationEnabled); } - public V1SecurityContextBuilder(io.kubernetes.client.openapi.models.V1SecurityContextFluent fluent,io.kubernetes.client.openapi.models.V1SecurityContext instance) { + + public V1SecurityContextBuilder( + io.kubernetes.client.openapi.models.V1SecurityContextFluent fluent, + io.kubernetes.client.openapi.models.V1SecurityContext instance) { this(fluent, instance, false); } - public V1SecurityContextBuilder(io.kubernetes.client.openapi.models.V1SecurityContextFluent fluent,io.kubernetes.client.openapi.models.V1SecurityContext instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SecurityContextBuilder( + io.kubernetes.client.openapi.models.V1SecurityContextFluent fluent, + io.kubernetes.client.openapi.models.V1SecurityContext instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAllowPrivilegeEscalation(instance.getAllowPrivilegeEscalation()); fluent.withCapabilities(instance.getCapabilities()); @@ -43,13 +70,17 @@ public V1SecurityContextBuilder(io.kubernetes.client.openapi.models.V1SecurityCo fluent.withWindowsOptions(instance.getWindowsOptions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1SecurityContextBuilder(io.kubernetes.client.openapi.models.V1SecurityContext instance) { - this(instance,false); + this(instance, false); } - public V1SecurityContextBuilder(io.kubernetes.client.openapi.models.V1SecurityContext instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SecurityContextBuilder( + io.kubernetes.client.openapi.models.V1SecurityContext instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAllowPrivilegeEscalation(instance.getAllowPrivilegeEscalation()); this.withCapabilities(instance.getCapabilities()); @@ -72,10 +103,12 @@ public V1SecurityContextBuilder(io.kubernetes.client.openapi.models.V1SecurityCo this.withWindowsOptions(instance.getWindowsOptions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SecurityContextFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SecurityContext build() { V1SecurityContext buildable = new V1SecurityContext(); buildable.setAllowPrivilegeEscalation(fluent.getAllowPrivilegeEscalation()); @@ -91,18 +124,23 @@ public io.kubernetes.client.openapi.models.V1SecurityContext build() { buildable.setWindowsOptions(fluent.getWindowsOptions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SecurityContextBuilder that = (V1SecurityContextBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecurityContextFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecurityContextFluent.java index 541292b0c3..c4a961bd94 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecurityContextFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecurityContextFluent.java @@ -1,123 +1,219 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Long; - - /** - * Generated - */ -public interface V1SecurityContextFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SecurityContextFluent< + A extends io.kubernetes.client.openapi.models.V1SecurityContextFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Boolean getAllowPrivilegeEscalation(); + public A withAllowPrivilegeEscalation(java.lang.Boolean allowPrivilegeEscalation); + public java.lang.Boolean hasAllowPrivilegeEscalation(); - + /** * This method has been deprecated, please use method buildCapabilities instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Capabilities getCapabilities(); + public io.kubernetes.client.openapi.models.V1Capabilities buildCapabilities(); + public A withCapabilities(io.kubernetes.client.openapi.models.V1Capabilities capabilities); + public java.lang.Boolean hasCapabilities(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested withNewCapabilities(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested withNewCapabilitiesLike(io.kubernetes.client.openapi.models.V1Capabilities item); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested editCapabilities(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested editOrNewCapabilities(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested editOrNewCapabilitiesLike(io.kubernetes.client.openapi.models.V1Capabilities item); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested + withNewCapabilities(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested + withNewCapabilitiesLike(io.kubernetes.client.openapi.models.V1Capabilities item); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested + editCapabilities(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested + editOrNewCapabilities(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested + editOrNewCapabilitiesLike(io.kubernetes.client.openapi.models.V1Capabilities item); + public java.lang.Boolean getPrivileged(); + public A withPrivileged(java.lang.Boolean privileged); + public java.lang.Boolean hasPrivileged(); + public java.lang.String getProcMount(); + public A withProcMount(java.lang.String procMount); + public java.lang.Boolean hasProcMount(); - - /** - * Method is deprecated. use withProcMount instead. - */ + + /** Method is deprecated. use withProcMount instead. */ @java.lang.Deprecated public A withNewProcMount(java.lang.String original); + public java.lang.Boolean getReadOnlyRootFilesystem(); + public A withReadOnlyRootFilesystem(java.lang.Boolean readOnlyRootFilesystem); + public java.lang.Boolean hasReadOnlyRootFilesystem(); + public java.lang.Long getRunAsGroup(); + public A withRunAsGroup(java.lang.Long runAsGroup); + public java.lang.Boolean hasRunAsGroup(); + public java.lang.Boolean getRunAsNonRoot(); + public A withRunAsNonRoot(java.lang.Boolean runAsNonRoot); + public java.lang.Boolean hasRunAsNonRoot(); + public java.lang.Long getRunAsUser(); + public A withRunAsUser(java.lang.Long runAsUser); + public java.lang.Boolean hasRunAsUser(); - + /** * This method has been deprecated, please use method buildSeLinuxOptions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SELinuxOptions getSeLinuxOptions(); + public io.kubernetes.client.openapi.models.V1SELinuxOptions buildSeLinuxOptions(); + public A withSeLinuxOptions(io.kubernetes.client.openapi.models.V1SELinuxOptions seLinuxOptions); + public java.lang.Boolean hasSeLinuxOptions(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested withNewSeLinuxOptions(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested withNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested editSeLinuxOptions(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested editOrNewSeLinuxOptions(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested editOrNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item); - + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested + withNewSeLinuxOptions(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested + withNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested + editSeLinuxOptions(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested + editOrNewSeLinuxOptions(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested + editOrNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item); + /** * This method has been deprecated, please use method buildSeccompProfile instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SeccompProfile getSeccompProfile(); + public io.kubernetes.client.openapi.models.V1SeccompProfile buildSeccompProfile(); + public A withSeccompProfile(io.kubernetes.client.openapi.models.V1SeccompProfile seccompProfile); + public java.lang.Boolean hasSeccompProfile(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested withNewSeccompProfile(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested withNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested editSeccompProfile(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested editOrNewSeccompProfile(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested editOrNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item); - + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested + withNewSeccompProfile(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested + withNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested + editSeccompProfile(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested + editOrNewSeccompProfile(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested + editOrNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item); + /** * This method has been deprecated, please use method buildWindowsOptions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions getWindowsOptions(); + public io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions buildWindowsOptions(); - public A withWindowsOptions(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions windowsOptions); + + public A withWindowsOptions( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions windowsOptions); + public java.lang.Boolean hasWindowsOptions(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested withNewWindowsOptions(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested withNewWindowsOptionsLike(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested editWindowsOptions(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested editOrNewWindowsOptions(); - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested editOrNewWindowsOptionsLike(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item); - public interface CapabilitiesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CapabilitiesFluent>{ + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested + withNewWindowsOptions(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested + withNewWindowsOptionsLike( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested + editWindowsOptions(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested + editOrNewWindowsOptions(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested + editOrNewWindowsOptionsLike( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item); + + public interface CapabilitiesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CapabilitiesFluent< + io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested> { public N and(); + public N endCapabilities(); - } - public interface SeLinuxOptionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent>{ + + public interface SeLinuxOptionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent< + io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested> { public N and(); + public N endSeLinuxOptions(); - } - public interface SeccompProfileNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SeccompProfileFluent>{ + + public interface SeccompProfileNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SeccompProfileFluent< + io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested> { public N and(); + public N endSeccompProfile(); - } - public interface WindowsOptionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent>{ + + public interface WindowsOptionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent< + io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested> { public N and(); + public N endWindowsOptions(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecurityContextFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecurityContextFluentImpl.java index ab66c13c24..42f396bd6b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecurityContextFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SecurityContextFluentImpl.java @@ -1,20 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Long; -import java.lang.Object; - - /** - * Generated - */ -public class V1SecurityContextFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SecurityContextFluent{ - public V1SecurityContextFluentImpl() { - } - public V1SecurityContextFluentImpl(io.kubernetes.client.openapi.models.V1SecurityContext instance) { +/** Generated */ +public class V1SecurityContextFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SecurityContextFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SecurityContextFluent { + public V1SecurityContextFluentImpl() {} + + public V1SecurityContextFluentImpl( + io.kubernetes.client.openapi.models.V1SecurityContext instance) { this.withAllowPrivilegeEscalation(instance.getAllowPrivilegeEscalation()); this.withCapabilities(instance.getCapabilities()); @@ -36,8 +42,8 @@ public V1SecurityContextFluentImpl(io.kubernetes.client.openapi.models.V1Securit this.withSeccompProfile(instance.getSeccompProfile()); this.withWindowsOptions(instance.getWindowsOptions()); - } + private java.lang.Boolean allowPrivilegeEscalation; private io.kubernetes.client.openapi.models.V1CapabilitiesBuilder capabilities; private java.lang.Boolean privileged; @@ -49,296 +55,491 @@ public V1SecurityContextFluentImpl(io.kubernetes.client.openapi.models.V1Securit private io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder seLinuxOptions; private io.kubernetes.client.openapi.models.V1SeccompProfileBuilder seccompProfile; private io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder windowsOptions; + public java.lang.Boolean getAllowPrivilegeEscalation() { return this.allowPrivilegeEscalation; } + public A withAllowPrivilegeEscalation(java.lang.Boolean allowPrivilegeEscalation) { - this.allowPrivilegeEscalation=allowPrivilegeEscalation; return (A) this; + this.allowPrivilegeEscalation = allowPrivilegeEscalation; + return (A) this; } + public java.lang.Boolean hasAllowPrivilegeEscalation() { return this.allowPrivilegeEscalation != null; } - + /** * This method has been deprecated, please use method buildCapabilities instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1Capabilities getCapabilities() { - return this.capabilities!=null ?this.capabilities.build():null; + return this.capabilities != null ? this.capabilities.build() : null; } + public io.kubernetes.client.openapi.models.V1Capabilities buildCapabilities() { - return this.capabilities!=null ?this.capabilities.build():null; + return this.capabilities != null ? this.capabilities.build() : null; } + public A withCapabilities(io.kubernetes.client.openapi.models.V1Capabilities capabilities) { _visitables.get("capabilities").remove(this.capabilities); - if (capabilities!=null){ this.capabilities= new io.kubernetes.client.openapi.models.V1CapabilitiesBuilder(capabilities); _visitables.get("capabilities").add(this.capabilities);} return (A) this; + if (capabilities != null) { + this.capabilities = + new io.kubernetes.client.openapi.models.V1CapabilitiesBuilder(capabilities); + _visitables.get("capabilities").add(this.capabilities); + } + return (A) this; } + public java.lang.Boolean hasCapabilities() { return this.capabilities != null; } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested withNewCapabilities() { - return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl.CapabilitiesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested + withNewCapabilities() { + return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl + .CapabilitiesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested withNewCapabilitiesLike(io.kubernetes.client.openapi.models.V1Capabilities item) { - return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl.CapabilitiesNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested + withNewCapabilitiesLike(io.kubernetes.client.openapi.models.V1Capabilities item) { + return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl + .CapabilitiesNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested editCapabilities() { + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested + editCapabilities() { return withNewCapabilitiesLike(getCapabilities()); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested editOrNewCapabilities() { - return withNewCapabilitiesLike(getCapabilities() != null ? getCapabilities(): new io.kubernetes.client.openapi.models.V1CapabilitiesBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested + editOrNewCapabilities() { + return withNewCapabilitiesLike( + getCapabilities() != null + ? getCapabilities() + : new io.kubernetes.client.openapi.models.V1CapabilitiesBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested editOrNewCapabilitiesLike(io.kubernetes.client.openapi.models.V1Capabilities item) { - return withNewCapabilitiesLike(getCapabilities() != null ? getCapabilities(): item); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested + editOrNewCapabilitiesLike(io.kubernetes.client.openapi.models.V1Capabilities item) { + return withNewCapabilitiesLike(getCapabilities() != null ? getCapabilities() : item); } + public java.lang.Boolean getPrivileged() { return this.privileged; } + public A withPrivileged(java.lang.Boolean privileged) { - this.privileged=privileged; return (A) this; + this.privileged = privileged; + return (A) this; } + public java.lang.Boolean hasPrivileged() { return this.privileged != null; } + public java.lang.String getProcMount() { return this.procMount; } + public A withProcMount(java.lang.String procMount) { - this.procMount=procMount; return (A) this; + this.procMount = procMount; + return (A) this; } + public java.lang.Boolean hasProcMount() { return this.procMount != null; } - - /** - * Method is deprecated. use withProcMount instead. - */ + + /** Method is deprecated. use withProcMount instead. */ @java.lang.Deprecated public A withNewProcMount(java.lang.String original) { - return (A)withProcMount(new String(original)); + return (A) withProcMount(new String(original)); } + public java.lang.Boolean getReadOnlyRootFilesystem() { return this.readOnlyRootFilesystem; } + public A withReadOnlyRootFilesystem(java.lang.Boolean readOnlyRootFilesystem) { - this.readOnlyRootFilesystem=readOnlyRootFilesystem; return (A) this; + this.readOnlyRootFilesystem = readOnlyRootFilesystem; + return (A) this; } + public java.lang.Boolean hasReadOnlyRootFilesystem() { return this.readOnlyRootFilesystem != null; } + public java.lang.Long getRunAsGroup() { return this.runAsGroup; } + public A withRunAsGroup(java.lang.Long runAsGroup) { - this.runAsGroup=runAsGroup; return (A) this; + this.runAsGroup = runAsGroup; + return (A) this; } + public java.lang.Boolean hasRunAsGroup() { return this.runAsGroup != null; } + public java.lang.Boolean getRunAsNonRoot() { return this.runAsNonRoot; } + public A withRunAsNonRoot(java.lang.Boolean runAsNonRoot) { - this.runAsNonRoot=runAsNonRoot; return (A) this; + this.runAsNonRoot = runAsNonRoot; + return (A) this; } + public java.lang.Boolean hasRunAsNonRoot() { return this.runAsNonRoot != null; } + public java.lang.Long getRunAsUser() { return this.runAsUser; } + public A withRunAsUser(java.lang.Long runAsUser) { - this.runAsUser=runAsUser; return (A) this; + this.runAsUser = runAsUser; + return (A) this; } + public java.lang.Boolean hasRunAsUser() { return this.runAsUser != null; } - + /** * This method has been deprecated, please use method buildSeLinuxOptions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SELinuxOptions getSeLinuxOptions() { - return this.seLinuxOptions!=null ?this.seLinuxOptions.build():null; + return this.seLinuxOptions != null ? this.seLinuxOptions.build() : null; } + public io.kubernetes.client.openapi.models.V1SELinuxOptions buildSeLinuxOptions() { - return this.seLinuxOptions!=null ?this.seLinuxOptions.build():null; + return this.seLinuxOptions != null ? this.seLinuxOptions.build() : null; } + public A withSeLinuxOptions(io.kubernetes.client.openapi.models.V1SELinuxOptions seLinuxOptions) { _visitables.get("seLinuxOptions").remove(this.seLinuxOptions); - if (seLinuxOptions!=null){ this.seLinuxOptions= new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder(seLinuxOptions); _visitables.get("seLinuxOptions").add(this.seLinuxOptions);} return (A) this; + if (seLinuxOptions != null) { + this.seLinuxOptions = + new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder(seLinuxOptions); + _visitables.get("seLinuxOptions").add(this.seLinuxOptions); + } + return (A) this; } + public java.lang.Boolean hasSeLinuxOptions() { return this.seLinuxOptions != null; } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested withNewSeLinuxOptions() { - return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl.SeLinuxOptionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested + withNewSeLinuxOptions() { + return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl + .SeLinuxOptionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested withNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { - return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl.SeLinuxOptionsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested + withNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { + return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl + .SeLinuxOptionsNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested editSeLinuxOptions() { + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested + editSeLinuxOptions() { return withNewSeLinuxOptionsLike(getSeLinuxOptions()); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested editOrNewSeLinuxOptions() { - return withNewSeLinuxOptionsLike(getSeLinuxOptions() != null ? getSeLinuxOptions(): new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested + editOrNewSeLinuxOptions() { + return withNewSeLinuxOptionsLike( + getSeLinuxOptions() != null + ? getSeLinuxOptions() + : new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested editOrNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { - return withNewSeLinuxOptionsLike(getSeLinuxOptions() != null ? getSeLinuxOptions(): item); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested + editOrNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { + return withNewSeLinuxOptionsLike(getSeLinuxOptions() != null ? getSeLinuxOptions() : item); } - + /** * This method has been deprecated, please use method buildSeccompProfile instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SeccompProfile getSeccompProfile() { - return this.seccompProfile!=null ?this.seccompProfile.build():null; + return this.seccompProfile != null ? this.seccompProfile.build() : null; } + public io.kubernetes.client.openapi.models.V1SeccompProfile buildSeccompProfile() { - return this.seccompProfile!=null ?this.seccompProfile.build():null; + return this.seccompProfile != null ? this.seccompProfile.build() : null; } + public A withSeccompProfile(io.kubernetes.client.openapi.models.V1SeccompProfile seccompProfile) { _visitables.get("seccompProfile").remove(this.seccompProfile); - if (seccompProfile!=null){ this.seccompProfile= new io.kubernetes.client.openapi.models.V1SeccompProfileBuilder(seccompProfile); _visitables.get("seccompProfile").add(this.seccompProfile);} return (A) this; + if (seccompProfile != null) { + this.seccompProfile = + new io.kubernetes.client.openapi.models.V1SeccompProfileBuilder(seccompProfile); + _visitables.get("seccompProfile").add(this.seccompProfile); + } + return (A) this; } + public java.lang.Boolean hasSeccompProfile() { return this.seccompProfile != null; } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested withNewSeccompProfile() { - return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl.SeccompProfileNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested + withNewSeccompProfile() { + return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl + .SeccompProfileNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested withNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item) { - return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl.SeccompProfileNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested + withNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item) { + return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl + .SeccompProfileNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested editSeccompProfile() { + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested + editSeccompProfile() { return withNewSeccompProfileLike(getSeccompProfile()); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested editOrNewSeccompProfile() { - return withNewSeccompProfileLike(getSeccompProfile() != null ? getSeccompProfile(): new io.kubernetes.client.openapi.models.V1SeccompProfileBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested + editOrNewSeccompProfile() { + return withNewSeccompProfileLike( + getSeccompProfile() != null + ? getSeccompProfile() + : new io.kubernetes.client.openapi.models.V1SeccompProfileBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested editOrNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item) { - return withNewSeccompProfileLike(getSeccompProfile() != null ? getSeccompProfile(): item); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested + editOrNewSeccompProfileLike(io.kubernetes.client.openapi.models.V1SeccompProfile item) { + return withNewSeccompProfileLike(getSeccompProfile() != null ? getSeccompProfile() : item); } - + /** * This method has been deprecated, please use method buildWindowsOptions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions getWindowsOptions() { - return this.windowsOptions!=null ?this.windowsOptions.build():null; + return this.windowsOptions != null ? this.windowsOptions.build() : null; } + public io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions buildWindowsOptions() { - return this.windowsOptions!=null ?this.windowsOptions.build():null; + return this.windowsOptions != null ? this.windowsOptions.build() : null; } - public A withWindowsOptions(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions windowsOptions) { + + public A withWindowsOptions( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions windowsOptions) { _visitables.get("windowsOptions").remove(this.windowsOptions); - if (windowsOptions!=null){ this.windowsOptions= new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder(windowsOptions); _visitables.get("windowsOptions").add(this.windowsOptions);} return (A) this; + if (windowsOptions != null) { + this.windowsOptions = + new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder( + windowsOptions); + _visitables.get("windowsOptions").add(this.windowsOptions); + } + return (A) this; } + public java.lang.Boolean hasWindowsOptions() { return this.windowsOptions != null; } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested withNewWindowsOptions() { - return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl.WindowsOptionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested + withNewWindowsOptions() { + return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl + .WindowsOptionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested withNewWindowsOptionsLike(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item) { - return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl.WindowsOptionsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested + withNewWindowsOptionsLike( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item) { + return new io.kubernetes.client.openapi.models.V1SecurityContextFluentImpl + .WindowsOptionsNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested editWindowsOptions() { + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested + editWindowsOptions() { return withNewWindowsOptionsLike(getWindowsOptions()); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested editOrNewWindowsOptions() { - return withNewWindowsOptionsLike(getWindowsOptions() != null ? getWindowsOptions(): new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested + editOrNewWindowsOptions() { + return withNewWindowsOptionsLike( + getWindowsOptions() != null + ? getWindowsOptions() + : new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested editOrNewWindowsOptionsLike(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item) { - return withNewWindowsOptionsLike(getWindowsOptions() != null ? getWindowsOptions(): item); + + public io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested + editOrNewWindowsOptionsLike( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item) { + return withNewWindowsOptionsLike(getWindowsOptions() != null ? getWindowsOptions() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SecurityContextFluentImpl that = (V1SecurityContextFluentImpl) o; - if (allowPrivilegeEscalation != null ? !allowPrivilegeEscalation.equals(that.allowPrivilegeEscalation) :that.allowPrivilegeEscalation != null) return false; - if (capabilities != null ? !capabilities.equals(that.capabilities) :that.capabilities != null) return false; - if (privileged != null ? !privileged.equals(that.privileged) :that.privileged != null) return false; - if (procMount != null ? !procMount.equals(that.procMount) :that.procMount != null) return false; - if (readOnlyRootFilesystem != null ? !readOnlyRootFilesystem.equals(that.readOnlyRootFilesystem) :that.readOnlyRootFilesystem != null) return false; - if (runAsGroup != null ? !runAsGroup.equals(that.runAsGroup) :that.runAsGroup != null) return false; - if (runAsNonRoot != null ? !runAsNonRoot.equals(that.runAsNonRoot) :that.runAsNonRoot != null) return false; - if (runAsUser != null ? !runAsUser.equals(that.runAsUser) :that.runAsUser != null) return false; - if (seLinuxOptions != null ? !seLinuxOptions.equals(that.seLinuxOptions) :that.seLinuxOptions != null) return false; - if (seccompProfile != null ? !seccompProfile.equals(that.seccompProfile) :that.seccompProfile != null) return false; - if (windowsOptions != null ? !windowsOptions.equals(that.windowsOptions) :that.windowsOptions != null) return false; + if (allowPrivilegeEscalation != null + ? !allowPrivilegeEscalation.equals(that.allowPrivilegeEscalation) + : that.allowPrivilegeEscalation != null) return false; + if (capabilities != null ? !capabilities.equals(that.capabilities) : that.capabilities != null) + return false; + if (privileged != null ? !privileged.equals(that.privileged) : that.privileged != null) + return false; + if (procMount != null ? !procMount.equals(that.procMount) : that.procMount != null) + return false; + if (readOnlyRootFilesystem != null + ? !readOnlyRootFilesystem.equals(that.readOnlyRootFilesystem) + : that.readOnlyRootFilesystem != null) return false; + if (runAsGroup != null ? !runAsGroup.equals(that.runAsGroup) : that.runAsGroup != null) + return false; + if (runAsNonRoot != null ? !runAsNonRoot.equals(that.runAsNonRoot) : that.runAsNonRoot != null) + return false; + if (runAsUser != null ? !runAsUser.equals(that.runAsUser) : that.runAsUser != null) + return false; + if (seLinuxOptions != null + ? !seLinuxOptions.equals(that.seLinuxOptions) + : that.seLinuxOptions != null) return false; + if (seccompProfile != null + ? !seccompProfile.equals(that.seccompProfile) + : that.seccompProfile != null) return false; + if (windowsOptions != null + ? !windowsOptions.equals(that.windowsOptions) + : that.windowsOptions != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(allowPrivilegeEscalation, capabilities, privileged, procMount, readOnlyRootFilesystem, runAsGroup, runAsNonRoot, runAsUser, seLinuxOptions, seccompProfile, windowsOptions, super.hashCode()); + return java.util.Objects.hash( + allowPrivilegeEscalation, + capabilities, + privileged, + procMount, + readOnlyRootFilesystem, + runAsGroup, + runAsNonRoot, + runAsUser, + seLinuxOptions, + seccompProfile, + windowsOptions, + super.hashCode()); } - public class CapabilitiesNestedImpl extends io.kubernetes.client.openapi.models.V1CapabilitiesFluentImpl> implements io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested,io.kubernetes.client.fluent.Nested{ + + public class CapabilitiesNestedImpl + extends io.kubernetes.client.openapi.models.V1CapabilitiesFluentImpl< + io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested> + implements io.kubernetes.client.openapi.models.V1SecurityContextFluent.CapabilitiesNested, + io.kubernetes.client.fluent.Nested { CapabilitiesNestedImpl(io.kubernetes.client.openapi.models.V1Capabilities item) { this.builder = new io.kubernetes.client.openapi.models.V1CapabilitiesBuilder(this, item); } + CapabilitiesNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1CapabilitiesBuilder(this); } + io.kubernetes.client.openapi.models.V1CapabilitiesBuilder builder; + public N and() { return (N) V1SecurityContextFluentImpl.this.withCapabilities(builder.build()); } + public N endCapabilities() { return and(); } - } - public class SeLinuxOptionsNestedImpl extends io.kubernetes.client.openapi.models.V1SELinuxOptionsFluentImpl> implements io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested,io.kubernetes.client.fluent.Nested{ + + public class SeLinuxOptionsNestedImpl + extends io.kubernetes.client.openapi.models.V1SELinuxOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested> + implements io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeLinuxOptionsNested< + N>, + io.kubernetes.client.fluent.Nested { SeLinuxOptionsNestedImpl(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { this.builder = new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder(this, item); } + SeLinuxOptionsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder(this); } + io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder builder; + public N and() { return (N) V1SecurityContextFluentImpl.this.withSeLinuxOptions(builder.build()); } + public N endSeLinuxOptions() { return and(); } - } - public class SeccompProfileNestedImpl extends io.kubernetes.client.openapi.models.V1SeccompProfileFluentImpl> implements io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested,io.kubernetes.client.fluent.Nested{ + + public class SeccompProfileNestedImpl + extends io.kubernetes.client.openapi.models.V1SeccompProfileFluentImpl< + io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested> + implements io.kubernetes.client.openapi.models.V1SecurityContextFluent.SeccompProfileNested< + N>, + io.kubernetes.client.fluent.Nested { SeccompProfileNestedImpl(io.kubernetes.client.openapi.models.V1SeccompProfile item) { this.builder = new io.kubernetes.client.openapi.models.V1SeccompProfileBuilder(this, item); } + SeccompProfileNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SeccompProfileBuilder(this); } + io.kubernetes.client.openapi.models.V1SeccompProfileBuilder builder; + public N and() { return (N) V1SecurityContextFluentImpl.this.withSeccompProfile(builder.build()); } + public N endSeccompProfile() { return and(); } - } - public class WindowsOptionsNestedImpl extends io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluentImpl> implements io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested,io.kubernetes.client.fluent.Nested{ - WindowsOptionsNestedImpl(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item) { - this.builder = new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder(this, item); + + public class WindowsOptionsNestedImpl + extends io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested> + implements io.kubernetes.client.openapi.models.V1SecurityContextFluent.WindowsOptionsNested< + N>, + io.kubernetes.client.fluent.Nested { + WindowsOptionsNestedImpl( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions item) { + this.builder = + new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder( + this, item); } + WindowsOptionsNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder(this); } + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder builder; + public N and() { return (N) V1SecurityContextFluentImpl.this.withWindowsOptions(builder.build()); } + public N endWindowsOptions() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewBuilder.java index c5af775408..82e0aab728 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SelfSubjectAccessReviewBuilder extends io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SelfSubjectAccessReviewBuilder + extends io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReview, + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewBuilder> { public V1SelfSubjectAccessReviewBuilder() { this(false); } + public V1SelfSubjectAccessReviewBuilder(java.lang.Boolean validationEnabled) { this(new V1SelfSubjectAccessReview(), validationEnabled); } - public V1SelfSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent fluent) { + + public V1SelfSubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent fluent) { this(fluent, false); } - public V1SelfSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SelfSubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SelfSubjectAccessReview(), validationEnabled); } - public V1SelfSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent fluent,io.kubernetes.client.openapi.models.V1SelfSubjectAccessReview instance) { + + public V1SelfSubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent fluent, + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReview instance) { this(fluent, instance, false); } - public V1SelfSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent fluent,io.kubernetes.client.openapi.models.V1SelfSubjectAccessReview instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SelfSubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent fluent, + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReview instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1SelfSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1Se fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1SelfSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReview instance) { - this(instance,false); + + public V1SelfSubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReview instance) { + this(instance, false); } - public V1SelfSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReview instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SelfSubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReview instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1SelfSubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1Se this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReview build() { V1SelfSubjectAccessReview buildable = new V1SelfSubjectAccessReview(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReview build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SelfSubjectAccessReviewBuilder that = (V1SelfSubjectAccessReviewBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewFluent.java index bd96e49133..dfbf4f18e7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewFluent.java @@ -1,93 +1,153 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SelfSubjectAccessReviewFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SelfSubjectAccessReviewFluent< + A extends io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec getSpec(); + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec item); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec item); - + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus getStatus(); + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewFluentImpl.java index 24ae259f15..62a5a2dbb4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1SelfSubjectAccessReviewFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent { + public V1SelfSubjectAccessReviewFluentImpl() {} - /** - * Generated - */ -public class V1SelfSubjectAccessReviewFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent{ - public V1SelfSubjectAccessReviewFluentImpl() { - } - public V1SelfSubjectAccessReviewFluentImpl(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReview instance) { + public V1SelfSubjectAccessReviewFluentImpl( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReview instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,318 @@ public V1SelfSubjectAccessReviewFluentImpl(io.kubernetes.client.openapi.models.V this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecBuilder spec; private io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = + new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec item) { - return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec item) { + return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { - return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { + return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SelfSubjectAccessReviewFluentImpl that = (V1SelfSubjectAccessReviewFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1SelfSubjectAccessReviewFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluentImpl< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecBuilder(this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecBuilder builder; + public N and() { return (N) V1SelfSubjectAccessReviewFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluentImpl< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewFluent.StatusNested< + N>, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder builder; + public N and() { return (N) V1SelfSubjectAccessReviewFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewSpecBuilder.java index 90e1976d71..f1407be3cb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewSpecBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SelfSubjectAccessReviewSpecBuilder extends io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SelfSubjectAccessReviewSpecBuilder + extends io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluentImpl< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec, + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecBuilder> { public V1SelfSubjectAccessReviewSpecBuilder() { this(false); } + public V1SelfSubjectAccessReviewSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1SelfSubjectAccessReviewSpec(), validationEnabled); } - public V1SelfSubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent fluent) { + + public V1SelfSubjectAccessReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent fluent) { this(fluent, false); } - public V1SelfSubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SelfSubjectAccessReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SelfSubjectAccessReviewSpec(), validationEnabled); } - public V1SelfSubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent fluent,io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec instance) { + + public V1SelfSubjectAccessReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent fluent, + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec instance) { this(fluent, instance, false); } - public V1SelfSubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent fluent,io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SelfSubjectAccessReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent fluent, + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNonResourceAttributes(instance.getNonResourceAttributes()); fluent.withResourceAttributes(instance.getResourceAttributes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1SelfSubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec instance) { - this(instance,false); + + public V1SelfSubjectAccessReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec instance) { + this(instance, false); } - public V1SelfSubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SelfSubjectAccessReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNonResourceAttributes(instance.getNonResourceAttributes()); this.withResourceAttributes(instance.getResourceAttributes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec build() { V1SelfSubjectAccessReviewSpec buildable = new V1SelfSubjectAccessReviewSpec(); buildable.setNonResourceAttributes(fluent.getNonResourceAttributes()); buildable.setResourceAttributes(fluent.getResourceAttributes()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SelfSubjectAccessReviewSpecBuilder that = (V1SelfSubjectAccessReviewSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewSpecFluent.java index eba9b5e65a..92887e2852 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewSpecFluent.java @@ -1,55 +1,124 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SelfSubjectAccessReviewSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1SelfSubjectAccessReviewSpecFluent< + A extends io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildNonResourceAttributes instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NonResourceAttributes getNonResourceAttributes(); + public io.kubernetes.client.openapi.models.V1NonResourceAttributes buildNonResourceAttributes(); - public A withNonResourceAttributes(io.kubernetes.client.openapi.models.V1NonResourceAttributes nonResourceAttributes); + + public A withNonResourceAttributes( + io.kubernetes.client.openapi.models.V1NonResourceAttributes nonResourceAttributes); + public java.lang.Boolean hasNonResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.NonResourceAttributesNested withNewNonResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.NonResourceAttributesNested withNewNonResourceAttributesLike(io.kubernetes.client.openapi.models.V1NonResourceAttributes item); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.NonResourceAttributesNested editNonResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.NonResourceAttributesNested editOrNewNonResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.NonResourceAttributesNested editOrNewNonResourceAttributesLike(io.kubernetes.client.openapi.models.V1NonResourceAttributes item); - + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + withNewNonResourceAttributes(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + withNewNonResourceAttributesLike( + io.kubernetes.client.openapi.models.V1NonResourceAttributes item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + editNonResourceAttributes(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + editOrNewNonResourceAttributes(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + editOrNewNonResourceAttributesLike( + io.kubernetes.client.openapi.models.V1NonResourceAttributes item); + /** * This method has been deprecated, please use method buildResourceAttributes instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceAttributes getResourceAttributes(); + public io.kubernetes.client.openapi.models.V1ResourceAttributes buildResourceAttributes(); - public A withResourceAttributes(io.kubernetes.client.openapi.models.V1ResourceAttributes resourceAttributes); + + public A withResourceAttributes( + io.kubernetes.client.openapi.models.V1ResourceAttributes resourceAttributes); + public java.lang.Boolean hasResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.ResourceAttributesNested withNewResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.ResourceAttributesNested withNewResourceAttributesLike(io.kubernetes.client.openapi.models.V1ResourceAttributes item); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.ResourceAttributesNested editResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.ResourceAttributesNested editOrNewResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.ResourceAttributesNested editOrNewResourceAttributesLike(io.kubernetes.client.openapi.models.V1ResourceAttributes item); - public interface NonResourceAttributesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent>{ + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + withNewResourceAttributes(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + withNewResourceAttributesLike(io.kubernetes.client.openapi.models.V1ResourceAttributes item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + editResourceAttributes(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + editOrNewResourceAttributes(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + editOrNewResourceAttributesLike( + io.kubernetes.client.openapi.models.V1ResourceAttributes item); + + public interface NonResourceAttributesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + N>> { public N and(); + public N endNonResourceAttributes(); - } - public interface ResourceAttributesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ResourceAttributesFluent>{ + + public interface ResourceAttributesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ResourceAttributesFluent< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .ResourceAttributesNested< + N>> { public N and(); + public N endResourceAttributes(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewSpecFluentImpl.java index bed7ad096d..05e1fc3e69 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectAccessReviewSpecFluentImpl.java @@ -1,135 +1,253 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1SelfSubjectAccessReviewSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent { + public V1SelfSubjectAccessReviewSpecFluentImpl() {} - /** - * Generated - */ -public class V1SelfSubjectAccessReviewSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent{ - public V1SelfSubjectAccessReviewSpecFluentImpl() { - } - public V1SelfSubjectAccessReviewSpecFluentImpl(io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec instance) { + public V1SelfSubjectAccessReviewSpecFluentImpl( + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpec instance) { this.withNonResourceAttributes(instance.getNonResourceAttributes()); this.withResourceAttributes(instance.getResourceAttributes()); - } + private io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder nonResourceAttributes; private io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder resourceAttributes; - + /** * This method has been deprecated, please use method buildNonResourceAttributes instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NonResourceAttributes getNonResourceAttributes() { - return this.nonResourceAttributes!=null ?this.nonResourceAttributes.build():null; + return this.nonResourceAttributes != null ? this.nonResourceAttributes.build() : null; } + public io.kubernetes.client.openapi.models.V1NonResourceAttributes buildNonResourceAttributes() { - return this.nonResourceAttributes!=null ?this.nonResourceAttributes.build():null; + return this.nonResourceAttributes != null ? this.nonResourceAttributes.build() : null; } - public A withNonResourceAttributes(io.kubernetes.client.openapi.models.V1NonResourceAttributes nonResourceAttributes) { + + public A withNonResourceAttributes( + io.kubernetes.client.openapi.models.V1NonResourceAttributes nonResourceAttributes) { _visitables.get("nonResourceAttributes").remove(this.nonResourceAttributes); - if (nonResourceAttributes!=null){ this.nonResourceAttributes= new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder(nonResourceAttributes); _visitables.get("nonResourceAttributes").add(this.nonResourceAttributes);} return (A) this; + if (nonResourceAttributes != null) { + this.nonResourceAttributes = + new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder( + nonResourceAttributes); + _visitables.get("nonResourceAttributes").add(this.nonResourceAttributes); + } + return (A) this; } + public java.lang.Boolean hasNonResourceAttributes() { return this.nonResourceAttributes != null; } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.NonResourceAttributesNested withNewNonResourceAttributes() { - return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluentImpl.NonResourceAttributesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + withNewNonResourceAttributes() { + return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluentImpl + .NonResourceAttributesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.NonResourceAttributesNested withNewNonResourceAttributesLike(io.kubernetes.client.openapi.models.V1NonResourceAttributes item) { - return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluentImpl.NonResourceAttributesNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + withNewNonResourceAttributesLike( + io.kubernetes.client.openapi.models.V1NonResourceAttributes item) { + return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluentImpl + .NonResourceAttributesNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.NonResourceAttributesNested editNonResourceAttributes() { + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + editNonResourceAttributes() { return withNewNonResourceAttributesLike(getNonResourceAttributes()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.NonResourceAttributesNested editOrNewNonResourceAttributes() { - return withNewNonResourceAttributesLike(getNonResourceAttributes() != null ? getNonResourceAttributes(): new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + editOrNewNonResourceAttributes() { + return withNewNonResourceAttributesLike( + getNonResourceAttributes() != null + ? getNonResourceAttributes() + : new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.NonResourceAttributesNested editOrNewNonResourceAttributesLike(io.kubernetes.client.openapi.models.V1NonResourceAttributes item) { - return withNewNonResourceAttributesLike(getNonResourceAttributes() != null ? getNonResourceAttributes(): item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + editOrNewNonResourceAttributesLike( + io.kubernetes.client.openapi.models.V1NonResourceAttributes item) { + return withNewNonResourceAttributesLike( + getNonResourceAttributes() != null ? getNonResourceAttributes() : item); } - + /** * This method has been deprecated, please use method buildResourceAttributes instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceAttributes getResourceAttributes() { - return this.resourceAttributes!=null ?this.resourceAttributes.build():null; + return this.resourceAttributes != null ? this.resourceAttributes.build() : null; } + public io.kubernetes.client.openapi.models.V1ResourceAttributes buildResourceAttributes() { - return this.resourceAttributes!=null ?this.resourceAttributes.build():null; + return this.resourceAttributes != null ? this.resourceAttributes.build() : null; } - public A withResourceAttributes(io.kubernetes.client.openapi.models.V1ResourceAttributes resourceAttributes) { + + public A withResourceAttributes( + io.kubernetes.client.openapi.models.V1ResourceAttributes resourceAttributes) { _visitables.get("resourceAttributes").remove(this.resourceAttributes); - if (resourceAttributes!=null){ this.resourceAttributes= new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder(resourceAttributes); _visitables.get("resourceAttributes").add(this.resourceAttributes);} return (A) this; + if (resourceAttributes != null) { + this.resourceAttributes = + new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder(resourceAttributes); + _visitables.get("resourceAttributes").add(this.resourceAttributes); + } + return (A) this; } + public java.lang.Boolean hasResourceAttributes() { return this.resourceAttributes != null; } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.ResourceAttributesNested withNewResourceAttributes() { - return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluentImpl.ResourceAttributesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + withNewResourceAttributes() { + return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluentImpl + .ResourceAttributesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.ResourceAttributesNested withNewResourceAttributesLike(io.kubernetes.client.openapi.models.V1ResourceAttributes item) { - return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluentImpl.ResourceAttributesNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + withNewResourceAttributesLike(io.kubernetes.client.openapi.models.V1ResourceAttributes item) { + return new io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluentImpl + .ResourceAttributesNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.ResourceAttributesNested editResourceAttributes() { + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + editResourceAttributes() { return withNewResourceAttributesLike(getResourceAttributes()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.ResourceAttributesNested editOrNewResourceAttributes() { - return withNewResourceAttributesLike(getResourceAttributes() != null ? getResourceAttributes(): new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + editOrNewResourceAttributes() { + return withNewResourceAttributesLike( + getResourceAttributes() != null + ? getResourceAttributes() + : new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.ResourceAttributesNested editOrNewResourceAttributesLike(io.kubernetes.client.openapi.models.V1ResourceAttributes item) { - return withNewResourceAttributesLike(getResourceAttributes() != null ? getResourceAttributes(): item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + editOrNewResourceAttributesLike( + io.kubernetes.client.openapi.models.V1ResourceAttributes item) { + return withNewResourceAttributesLike( + getResourceAttributes() != null ? getResourceAttributes() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SelfSubjectAccessReviewSpecFluentImpl that = (V1SelfSubjectAccessReviewSpecFluentImpl) o; - if (nonResourceAttributes != null ? !nonResourceAttributes.equals(that.nonResourceAttributes) :that.nonResourceAttributes != null) return false; - if (resourceAttributes != null ? !resourceAttributes.equals(that.resourceAttributes) :that.resourceAttributes != null) return false; + if (nonResourceAttributes != null + ? !nonResourceAttributes.equals(that.nonResourceAttributes) + : that.nonResourceAttributes != null) return false; + if (resourceAttributes != null + ? !resourceAttributes.equals(that.resourceAttributes) + : that.resourceAttributes != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(nonResourceAttributes, resourceAttributes, super.hashCode()); + return java.util.Objects.hash(nonResourceAttributes, resourceAttributes, super.hashCode()); } - public class NonResourceAttributesNestedImpl extends io.kubernetes.client.openapi.models.V1NonResourceAttributesFluentImpl> implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.NonResourceAttributesNested,io.kubernetes.client.fluent.Nested{ - NonResourceAttributesNestedImpl(io.kubernetes.client.openapi.models.V1NonResourceAttributes item) { - this.builder = new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder(this, item); + + public class NonResourceAttributesNestedImpl + extends io.kubernetes.client.openapi.models.V1NonResourceAttributesFluentImpl< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + N>> + implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + N>, + io.kubernetes.client.fluent.Nested { + NonResourceAttributesNestedImpl( + io.kubernetes.client.openapi.models.V1NonResourceAttributes item) { + this.builder = + new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder(this, item); } + NonResourceAttributesNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder(this); } + io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder builder; + public N and() { - return (N) V1SelfSubjectAccessReviewSpecFluentImpl.this.withNonResourceAttributes(builder.build()); + return (N) + V1SelfSubjectAccessReviewSpecFluentImpl.this.withNonResourceAttributes(builder.build()); } + public N endNonResourceAttributes() { return and(); } - } - public class ResourceAttributesNestedImpl extends io.kubernetes.client.openapi.models.V1ResourceAttributesFluentImpl> implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent.ResourceAttributesNested,io.kubernetes.client.fluent.Nested{ + + public class ResourceAttributesNestedImpl + extends io.kubernetes.client.openapi.models.V1ResourceAttributesFluentImpl< + io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .ResourceAttributesNested< + N>> + implements io.kubernetes.client.openapi.models.V1SelfSubjectAccessReviewSpecFluent + .ResourceAttributesNested< + N>, + io.kubernetes.client.fluent.Nested { ResourceAttributesNestedImpl(io.kubernetes.client.openapi.models.V1ResourceAttributes item) { - this.builder = new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder(this, item); } + ResourceAttributesNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder(this); } + io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder builder; + public N and() { - return (N) V1SelfSubjectAccessReviewSpecFluentImpl.this.withResourceAttributes(builder.build()); + return (N) + V1SelfSubjectAccessReviewSpecFluentImpl.this.withResourceAttributes(builder.build()); } + public N endResourceAttributes() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewBuilder.java index d78ece29a4..629f3a4d6c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SelfSubjectRulesReviewBuilder extends io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SelfSubjectRulesReviewBuilder + extends io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl< + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReview, + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewBuilder> { public V1SelfSubjectRulesReviewBuilder() { this(false); } + public V1SelfSubjectRulesReviewBuilder(java.lang.Boolean validationEnabled) { this(new V1SelfSubjectRulesReview(), validationEnabled); } - public V1SelfSubjectRulesReviewBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent fluent) { + + public V1SelfSubjectRulesReviewBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent fluent) { this(fluent, false); } - public V1SelfSubjectRulesReviewBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SelfSubjectRulesReviewBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SelfSubjectRulesReview(), validationEnabled); } - public V1SelfSubjectRulesReviewBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent fluent,io.kubernetes.client.openapi.models.V1SelfSubjectRulesReview instance) { + + public V1SelfSubjectRulesReviewBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent fluent, + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReview instance) { this(fluent, instance, false); } - public V1SelfSubjectRulesReviewBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent fluent,io.kubernetes.client.openapi.models.V1SelfSubjectRulesReview instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SelfSubjectRulesReviewBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent fluent, + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReview instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1SelfSubjectRulesReviewBuilder(io.kubernetes.client.openapi.models.V1Sel fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1SelfSubjectRulesReviewBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReview instance) { - this(instance,false); + + public V1SelfSubjectRulesReviewBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReview instance) { + this(instance, false); } - public V1SelfSubjectRulesReviewBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReview instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SelfSubjectRulesReviewBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReview instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1SelfSubjectRulesReviewBuilder(io.kubernetes.client.openapi.models.V1Sel this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReview build() { V1SelfSubjectRulesReview buildable = new V1SelfSubjectRulesReview(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReview build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SelfSubjectRulesReviewBuilder that = (V1SelfSubjectRulesReviewBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewFluent.java index 0c0e42fe77..2a9308407c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewFluent.java @@ -1,93 +1,153 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SelfSubjectRulesReviewFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SelfSubjectRulesReviewFluent< + A extends io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec getSpec(); + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec item); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec item); - + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus getStatus(); + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus item); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent< + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent< + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewFluentImpl.java index b5a5a4eceb..60a35ab405 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1SelfSubjectRulesReviewFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent { + public V1SelfSubjectRulesReviewFluentImpl() {} - /** - * Generated - */ -public class V1SelfSubjectRulesReviewFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent{ - public V1SelfSubjectRulesReviewFluentImpl() { - } - public V1SelfSubjectRulesReviewFluentImpl(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReview instance) { + public V1SelfSubjectRulesReviewFluentImpl( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReview instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,316 @@ public V1SelfSubjectRulesReviewFluentImpl(io.kubernetes.client.openapi.models.V1 this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecBuilder spec; private io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec item) { - return new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec item) { + return new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus item) { - return new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus item) { + return new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SelfSubjectRulesReviewFluentImpl that = (V1SelfSubjectRulesReviewFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1SelfSubjectRulesReviewFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluentImpl< + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecBuilder(this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecBuilder builder; + public N and() { return (N) V1SelfSubjectRulesReviewFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl< + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusBuilder(this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusBuilder builder; + public N and() { return (N) V1SelfSubjectRulesReviewFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewSpecBuilder.java index 67d37bbc74..e1aa179561 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewSpecBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SelfSubjectRulesReviewSpecBuilder extends io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SelfSubjectRulesReviewSpecBuilder + extends io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluentImpl< + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec, + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecBuilder> { public V1SelfSubjectRulesReviewSpecBuilder() { this(false); } + public V1SelfSubjectRulesReviewSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1SelfSubjectRulesReviewSpec(), validationEnabled); } - public V1SelfSubjectRulesReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent fluent) { + + public V1SelfSubjectRulesReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent fluent) { this(fluent, false); } - public V1SelfSubjectRulesReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SelfSubjectRulesReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SelfSubjectRulesReviewSpec(), validationEnabled); } - public V1SelfSubjectRulesReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent fluent,io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec instance) { + + public V1SelfSubjectRulesReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent fluent, + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec instance) { this(fluent, instance, false); } - public V1SelfSubjectRulesReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent fluent,io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SelfSubjectRulesReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent fluent, + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNamespace(instance.getNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1SelfSubjectRulesReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec instance) { - this(instance,false); + + public V1SelfSubjectRulesReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec instance) { + this(instance, false); } - public V1SelfSubjectRulesReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SelfSubjectRulesReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNamespace(instance.getNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec build() { V1SelfSubjectRulesReviewSpec buildable = new V1SelfSubjectRulesReviewSpec(); buildable.setNamespace(fluent.getNamespace()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SelfSubjectRulesReviewSpecBuilder that = (V1SelfSubjectRulesReviewSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewSpecFluent.java index 87f4db6874..a0c8035551 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewSpecFluent.java @@ -1,23 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SelfSubjectRulesReviewSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SelfSubjectRulesReviewSpecFluent< + A extends io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getNamespace(); + public A withNamespace(java.lang.String namespace); + public java.lang.Boolean hasNamespace(); - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewSpecFluentImpl.java index 26bf733d9f..e6a011b755 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SelfSubjectRulesReviewSpecFluentImpl.java @@ -1,48 +1,60 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1SelfSubjectRulesReviewSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent{ - public V1SelfSubjectRulesReviewSpecFluentImpl() { - } - public V1SelfSubjectRulesReviewSpecFluentImpl(io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec instance) { - this.withNamespace(instance.getNamespace()); +/** Generated */ +public class V1SelfSubjectRulesReviewSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpecFluent { + public V1SelfSubjectRulesReviewSpecFluentImpl() {} + public V1SelfSubjectRulesReviewSpecFluentImpl( + io.kubernetes.client.openapi.models.V1SelfSubjectRulesReviewSpec instance) { + this.withNamespace(instance.getNamespace()); } + private java.lang.String namespace; + public java.lang.String getNamespace() { return this.namespace; } + public A withNamespace(java.lang.String namespace) { - this.namespace=namespace; return (A) this; + this.namespace = namespace; + return (A) this; } + public java.lang.Boolean hasNamespace() { return this.namespace != null; } - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original) { - return (A)withNamespace(new String(original)); + return (A) withNamespace(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SelfSubjectRulesReviewSpecFluentImpl that = (V1SelfSubjectRulesReviewSpecFluentImpl) o; - if (namespace != null ? !namespace.equals(that.namespace) :that.namespace != null) return false; + if (namespace != null ? !namespace.equals(that.namespace) : that.namespace != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(namespace, super.hashCode()); + return java.util.Objects.hash(namespace, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServerAddressByClientCIDRBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServerAddressByClientCIDRBuilder.java index aeb1f7c560..88d3a2da45 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServerAddressByClientCIDRBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServerAddressByClientCIDRBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ServerAddressByClientCIDRBuilder extends io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ServerAddressByClientCIDRBuilder + extends io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluentImpl< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRBuilder> { public V1ServerAddressByClientCIDRBuilder() { this(false); } + public V1ServerAddressByClientCIDRBuilder(java.lang.Boolean validationEnabled) { this(new V1ServerAddressByClientCIDR(), validationEnabled); } - public V1ServerAddressByClientCIDRBuilder(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent fluent) { + + public V1ServerAddressByClientCIDRBuilder( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent fluent) { this(fluent, false); } - public V1ServerAddressByClientCIDRBuilder(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ServerAddressByClientCIDRBuilder( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ServerAddressByClientCIDR(), validationEnabled); } - public V1ServerAddressByClientCIDRBuilder(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent fluent,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR instance) { + + public V1ServerAddressByClientCIDRBuilder( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent fluent, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR instance) { this(fluent, instance, false); } - public V1ServerAddressByClientCIDRBuilder(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent fluent,io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ServerAddressByClientCIDRBuilder( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent fluent, + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withClientCIDR(instance.getClientCIDR()); fluent.withServerAddress(instance.getServerAddress()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ServerAddressByClientCIDRBuilder(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR instance) { - this(instance,false); + + public V1ServerAddressByClientCIDRBuilder( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR instance) { + this(instance, false); } - public V1ServerAddressByClientCIDRBuilder(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ServerAddressByClientCIDRBuilder( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withClientCIDR(instance.getClientCIDR()); this.withServerAddress(instance.getServerAddress()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR build() { V1ServerAddressByClientCIDR buildable = new V1ServerAddressByClientCIDR(); buildable.setClientCIDR(fluent.getClientCIDR()); buildable.setServerAddress(fluent.getServerAddress()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ServerAddressByClientCIDRBuilder that = (V1ServerAddressByClientCIDRBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServerAddressByClientCIDRFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServerAddressByClientCIDRFluent.java index 48744be652..8d1c465ce8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServerAddressByClientCIDRFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServerAddressByClientCIDRFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ServerAddressByClientCIDRFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ServerAddressByClientCIDRFluent< + A extends io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getClientCIDR(); + public A withClientCIDR(java.lang.String clientCIDR); + public java.lang.Boolean hasClientCIDR(); - - /** - * Method is deprecated. use withClientCIDR instead. - */ + + /** Method is deprecated. use withClientCIDR instead. */ @java.lang.Deprecated public A withNewClientCIDR(java.lang.String original); + public java.lang.String getServerAddress(); + public A withServerAddress(java.lang.String serverAddress); + public java.lang.Boolean hasServerAddress(); - - /** - * Method is deprecated. use withServerAddress instead. - */ + + /** Method is deprecated. use withServerAddress instead. */ @java.lang.Deprecated public A withNewServerAddress(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServerAddressByClientCIDRFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServerAddressByClientCIDRFluentImpl.java index 72e08a4793..9739a2ab0c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServerAddressByClientCIDRFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServerAddressByClientCIDRFluentImpl.java @@ -1,69 +1,85 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ServerAddressByClientCIDRFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent { + public V1ServerAddressByClientCIDRFluentImpl() {} - /** - * Generated - */ -public class V1ServerAddressByClientCIDRFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDRFluent{ - public V1ServerAddressByClientCIDRFluentImpl() { - } - public V1ServerAddressByClientCIDRFluentImpl(io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR instance) { + public V1ServerAddressByClientCIDRFluentImpl( + io.kubernetes.client.openapi.models.V1ServerAddressByClientCIDR instance) { this.withClientCIDR(instance.getClientCIDR()); this.withServerAddress(instance.getServerAddress()); - } + private java.lang.String clientCIDR; private java.lang.String serverAddress; + public java.lang.String getClientCIDR() { return this.clientCIDR; } + public A withClientCIDR(java.lang.String clientCIDR) { - this.clientCIDR=clientCIDR; return (A) this; + this.clientCIDR = clientCIDR; + return (A) this; } + public java.lang.Boolean hasClientCIDR() { return this.clientCIDR != null; } - - /** - * Method is deprecated. use withClientCIDR instead. - */ + + /** Method is deprecated. use withClientCIDR instead. */ @java.lang.Deprecated public A withNewClientCIDR(java.lang.String original) { - return (A)withClientCIDR(new String(original)); + return (A) withClientCIDR(new String(original)); } + public java.lang.String getServerAddress() { return this.serverAddress; } + public A withServerAddress(java.lang.String serverAddress) { - this.serverAddress=serverAddress; return (A) this; + this.serverAddress = serverAddress; + return (A) this; } + public java.lang.Boolean hasServerAddress() { return this.serverAddress != null; } - - /** - * Method is deprecated. use withServerAddress instead. - */ + + /** Method is deprecated. use withServerAddress instead. */ @java.lang.Deprecated public A withNewServerAddress(java.lang.String original) { - return (A)withServerAddress(new String(original)); + return (A) withServerAddress(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ServerAddressByClientCIDRFluentImpl that = (V1ServerAddressByClientCIDRFluentImpl) o; - if (clientCIDR != null ? !clientCIDR.equals(that.clientCIDR) :that.clientCIDR != null) return false; - if (serverAddress != null ? !serverAddress.equals(that.serverAddress) :that.serverAddress != null) return false; + if (clientCIDR != null ? !clientCIDR.equals(that.clientCIDR) : that.clientCIDR != null) + return false; + if (serverAddress != null + ? !serverAddress.equals(that.serverAddress) + : that.serverAddress != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(clientCIDR, serverAddress, super.hashCode()); + return java.util.Objects.hash(clientCIDR, serverAddress, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountBuilder.java index 7192a5a3dd..ee2529f9ed 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ServiceAccountBuilder extends io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ServiceAccountBuilder + extends io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceAccountBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ServiceAccount, + io.kubernetes.client.openapi.models.V1ServiceAccountBuilder> { public V1ServiceAccountBuilder() { this(false); } + public V1ServiceAccountBuilder(java.lang.Boolean validationEnabled) { this(new V1ServiceAccount(), validationEnabled); } - public V1ServiceAccountBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountFluent fluent) { + + public V1ServiceAccountBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountFluent fluent) { this(fluent, false); } - public V1ServiceAccountBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ServiceAccountBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ServiceAccount(), validationEnabled); } - public V1ServiceAccountBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountFluent fluent,io.kubernetes.client.openapi.models.V1ServiceAccount instance) { + + public V1ServiceAccountBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceAccount instance) { this(fluent, instance, false); } - public V1ServiceAccountBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountFluent fluent,io.kubernetes.client.openapi.models.V1ServiceAccount instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ServiceAccountBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceAccount instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withAutomountServiceAccountToken(instance.getAutomountServiceAccountToken()); @@ -33,13 +60,17 @@ public V1ServiceAccountBuilder(io.kubernetes.client.openapi.models.V1ServiceAcco fluent.withSecrets(instance.getSecrets()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ServiceAccountBuilder(io.kubernetes.client.openapi.models.V1ServiceAccount instance) { - this(instance,false); + this(instance, false); } - public V1ServiceAccountBuilder(io.kubernetes.client.openapi.models.V1ServiceAccount instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ServiceAccountBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccount instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withAutomountServiceAccountToken(instance.getAutomountServiceAccountToken()); @@ -52,10 +83,12 @@ public V1ServiceAccountBuilder(io.kubernetes.client.openapi.models.V1ServiceAcco this.withSecrets(instance.getSecrets()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ServiceAccountFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ServiceAccount build() { V1ServiceAccount buildable = new V1ServiceAccount(); buildable.setApiVersion(fluent.getApiVersion()); @@ -66,18 +99,23 @@ public io.kubernetes.client.openapi.models.V1ServiceAccount build() { buildable.setSecrets(fluent.getSecrets()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ServiceAccountBuilder that = (V1ServiceAccountBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountFluent.java index 9c20d45d5a..a4062f8ba9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountFluent.java @@ -1,133 +1,260 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1ServiceAccountFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ServiceAccountFluent< + A extends io.kubernetes.client.openapi.models.V1ServiceAccountFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.Boolean getAutomountServiceAccountToken(); + public A withAutomountServiceAccountToken(java.lang.Boolean automountServiceAccountToken); + public java.lang.Boolean hasAutomountServiceAccountToken(); - public A addToImagePullSecrets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public A setToImagePullSecrets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public A addToImagePullSecrets(io.kubernetes.client.openapi.models.V1LocalObjectReference... items); - public A addAllToImagePullSecrets(java.util.Collection items); - public A removeFromImagePullSecrets(io.kubernetes.client.openapi.models.V1LocalObjectReference... items); - public A removeAllFromImagePullSecrets(java.util.Collection items); - public A removeMatchingFromImagePullSecrets(java.util.function.Predicate predicate); - + + public A addToImagePullSecrets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public A setToImagePullSecrets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public A addToImagePullSecrets( + io.kubernetes.client.openapi.models.V1LocalObjectReference... items); + + public A addAllToImagePullSecrets( + java.util.Collection items); + + public A removeFromImagePullSecrets( + io.kubernetes.client.openapi.models.V1LocalObjectReference... items); + + public A removeAllFromImagePullSecrets( + java.util.Collection items); + + public A removeMatchingFromImagePullSecrets( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate); + /** * This method has been deprecated, please use method buildImagePullSecrets instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getImagePullSecrets(); - public java.util.List buildImagePullSecrets(); - public io.kubernetes.client.openapi.models.V1LocalObjectReference buildImagePullSecret(java.lang.Integer index); + public java.util.List + getImagePullSecrets(); + + public java.util.List + buildImagePullSecrets(); + + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildImagePullSecret( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildFirstImagePullSecret(); + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildLastImagePullSecret(); - public io.kubernetes.client.openapi.models.V1LocalObjectReference buildMatchingImagePullSecret(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingImagePullSecret(java.util.function.Predicate predicate); - public A withImagePullSecrets(java.util.List imagePullSecrets); - public A withImagePullSecrets(io.kubernetes.client.openapi.models.V1LocalObjectReference... imagePullSecrets); + + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildMatchingImagePullSecret( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate); + + public java.lang.Boolean hasMatchingImagePullSecret( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate); + + public A withImagePullSecrets( + java.util.List imagePullSecrets); + + public A withImagePullSecrets( + io.kubernetes.client.openapi.models.V1LocalObjectReference... imagePullSecrets); + public java.lang.Boolean hasImagePullSecrets(); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested addNewImagePullSecret(); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested addNewImagePullSecretLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested setNewImagePullSecretLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested editImagePullSecret(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested editFirstImagePullSecret(); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested editLastImagePullSecret(); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested editMatchingImagePullSecret(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + addNewImagePullSecret(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + addNewImagePullSecretLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + setNewImagePullSecretLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + editImagePullSecret(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + editFirstImagePullSecret(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + editLastImagePullSecret(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + editMatchingImagePullSecret( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public A addToSecrets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item); - public A setToSecrets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public A addToSecrets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item); + + public A setToSecrets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item); + public A addToSecrets(io.kubernetes.client.openapi.models.V1ObjectReference... items); - public A addAllToSecrets(java.util.Collection items); + + public A addAllToSecrets( + java.util.Collection items); + public A removeFromSecrets(io.kubernetes.client.openapi.models.V1ObjectReference... items); - public A removeAllFromSecrets(java.util.Collection items); - public A removeMatchingFromSecrets(java.util.function.Predicate predicate); - + + public A removeAllFromSecrets( + java.util.Collection items); + + public A removeMatchingFromSecrets( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildSecrets instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getSecrets(); + public java.util.List buildSecrets(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildSecret(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ObjectReference buildFirstSecret(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildLastSecret(); - public io.kubernetes.client.openapi.models.V1ObjectReference buildMatchingSecret(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingSecret(java.util.function.Predicate predicate); - public A withSecrets(java.util.List secrets); + + public io.kubernetes.client.openapi.models.V1ObjectReference buildMatchingSecret( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingSecret( + java.util.function.Predicate + predicate); + + public A withSecrets( + java.util.List secrets); + public A withSecrets(io.kubernetes.client.openapi.models.V1ObjectReference... secrets); + public java.lang.Boolean hasSecrets(); + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested addNewSecret(); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested addNewSecretLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested setNewSecretLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested editSecret(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested editFirstSecret(); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested editLastSecret(); - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested editMatchingSecret(java.util.function.Predicate predicate); - public interface ImagePullSecretsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent>{ + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested + addNewSecretLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested + setNewSecretLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested editSecret( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested + editFirstSecret(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested + editLastSecret(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested + editMatchingSecret( + java.util.function.Predicate + predicate); + + public interface ImagePullSecretsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested< + N>> { public N and(); + public N endImagePullSecret(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SecretsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface SecretsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested> { public N and(); + public N endSecret(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountFluentImpl.java index eca6149840..b92915eaba 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1ServiceAccountFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ServiceAccountFluent{ - public V1ServiceAccountFluentImpl() { - } +/** Generated */ +public class V1ServiceAccountFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ServiceAccountFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ServiceAccountFluent { + public V1ServiceAccountFluentImpl() {} + public V1ServiceAccountFluentImpl(io.kubernetes.client.openapi.models.V1ServiceAccount instance) { this.withApiVersion(instance.getApiVersion()); @@ -32,68 +34,151 @@ public V1ServiceAccountFluentImpl(io.kubernetes.client.openapi.models.V1ServiceA this.withMetadata(instance.getMetadata()); this.withSecrets(instance.getSecrets()); - } + private java.lang.String apiVersion; private java.lang.Boolean automountServiceAccountToken; - private java.util.ArrayList imagePullSecrets; + private java.util.ArrayList + imagePullSecrets; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private java.util.ArrayList secrets; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.Boolean getAutomountServiceAccountToken() { return this.automountServiceAccountToken; } + public A withAutomountServiceAccountToken(java.lang.Boolean automountServiceAccountToken) { - this.automountServiceAccountToken=automountServiceAccountToken; return (A) this; + this.automountServiceAccountToken = automountServiceAccountToken; + return (A) this; } + public java.lang.Boolean hasAutomountServiceAccountToken() { return this.automountServiceAccountToken != null; } - public A addToImagePullSecrets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - if (this.imagePullSecrets == null) {this.imagePullSecrets = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item);_visitables.get("imagePullSecrets").add(index >= 0 ? index : _visitables.get("imagePullSecrets").size(), builder);this.imagePullSecrets.add(index >= 0 ? index : imagePullSecrets.size(), builder); return (A)this; + + public A addToImagePullSecrets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + if (this.imagePullSecrets == null) { + this.imagePullSecrets = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder>(); + } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); + _visitables + .get("imagePullSecrets") + .add(index >= 0 ? index : _visitables.get("imagePullSecrets").size(), builder); + this.imagePullSecrets.add(index >= 0 ? index : imagePullSecrets.size(), builder); + return (A) this; } - public A setToImagePullSecrets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - if (this.imagePullSecrets == null) {this.imagePullSecrets = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); - if (index < 0 || index >= _visitables.get("imagePullSecrets").size()) { _visitables.get("imagePullSecrets").add(builder); } else { _visitables.get("imagePullSecrets").set(index, builder);} - if (index < 0 || index >= imagePullSecrets.size()) { imagePullSecrets.add(builder); } else { imagePullSecrets.set(index, builder);} - return (A)this; + + public A setToImagePullSecrets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + if (this.imagePullSecrets == null) { + this.imagePullSecrets = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder>(); + } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); + if (index < 0 || index >= _visitables.get("imagePullSecrets").size()) { + _visitables.get("imagePullSecrets").add(builder); + } else { + _visitables.get("imagePullSecrets").set(index, builder); + } + if (index < 0 || index >= imagePullSecrets.size()) { + imagePullSecrets.add(builder); + } else { + imagePullSecrets.set(index, builder); + } + return (A) this; } - public A addToImagePullSecrets(io.kubernetes.client.openapi.models.V1LocalObjectReference... items) { - if (this.imagePullSecrets == null) {this.imagePullSecrets = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) {io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item);_visitables.get("imagePullSecrets").add(builder);this.imagePullSecrets.add(builder);} return (A)this; + + public A addToImagePullSecrets( + io.kubernetes.client.openapi.models.V1LocalObjectReference... items) { + if (this.imagePullSecrets == null) { + this.imagePullSecrets = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) { + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); + _visitables.get("imagePullSecrets").add(builder); + this.imagePullSecrets.add(builder); + } + return (A) this; } - public A addAllToImagePullSecrets(java.util.Collection items) { - if (this.imagePullSecrets == null) {this.imagePullSecrets = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) {io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item);_visitables.get("imagePullSecrets").add(builder);this.imagePullSecrets.add(builder);} return (A)this; + + public A addAllToImagePullSecrets( + java.util.Collection items) { + if (this.imagePullSecrets == null) { + this.imagePullSecrets = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) { + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); + _visitables.get("imagePullSecrets").add(builder); + this.imagePullSecrets.add(builder); + } + return (A) this; } - public A removeFromImagePullSecrets(io.kubernetes.client.openapi.models.V1LocalObjectReference... items) { - for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) {io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item);_visitables.get("imagePullSecrets").remove(builder);if (this.imagePullSecrets != null) {this.imagePullSecrets.remove(builder);}} return (A)this; + + public A removeFromImagePullSecrets( + io.kubernetes.client.openapi.models.V1LocalObjectReference... items) { + for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) { + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); + _visitables.get("imagePullSecrets").remove(builder); + if (this.imagePullSecrets != null) { + this.imagePullSecrets.remove(builder); + } + } + return (A) this; } - public A removeAllFromImagePullSecrets(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) {io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item);_visitables.get("imagePullSecrets").remove(builder);if (this.imagePullSecrets != null) {this.imagePullSecrets.remove(builder);}} return (A)this; + + public A removeAllFromImagePullSecrets( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : items) { + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(item); + _visitables.get("imagePullSecrets").remove(builder); + if (this.imagePullSecrets != null) { + this.imagePullSecrets.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromImagePullSecrets(java.util.function.Predicate predicate) { + + public A removeMatchingFromImagePullSecrets( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate) { if (imagePullSecrets == null) return (A) this; - final Iterator each = imagePullSecrets.iterator(); + final Iterator each = + imagePullSecrets.iterator(); final List visitables = _visitables.get("imagePullSecrets"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder = each.next(); @@ -102,155 +187,325 @@ public A removeMatchingFromImagePullSecrets(java.util.function.Predicate getImagePullSecrets() { + public java.util.List + getImagePullSecrets() { return imagePullSecrets != null ? build(imagePullSecrets) : null; } - public java.util.List buildImagePullSecrets() { + + public java.util.List + buildImagePullSecrets() { return imagePullSecrets != null ? build(imagePullSecrets) : null; } - public io.kubernetes.client.openapi.models.V1LocalObjectReference buildImagePullSecret(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildImagePullSecret( + java.lang.Integer index) { return this.imagePullSecrets.get(index).build(); } + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildFirstImagePullSecret() { return this.imagePullSecrets.get(0).build(); } + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildLastImagePullSecret() { return this.imagePullSecrets.get(imagePullSecrets.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1LocalObjectReference buildMatchingImagePullSecret(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder item: imagePullSecrets) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildMatchingImagePullSecret( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder item : + imagePullSecrets) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingImagePullSecret(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder item: imagePullSecrets) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingImagePullSecret( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder item : + imagePullSecrets) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withImagePullSecrets(java.util.List imagePullSecrets) { - if (this.imagePullSecrets != null) { _visitables.get("imagePullSecrets").removeAll(this.imagePullSecrets);} - if (imagePullSecrets != null) {this.imagePullSecrets = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : imagePullSecrets){this.addToImagePullSecrets(item);}} else { this.imagePullSecrets = null;} return (A) this; + + public A withImagePullSecrets( + java.util.List imagePullSecrets) { + if (this.imagePullSecrets != null) { + _visitables.get("imagePullSecrets").removeAll(this.imagePullSecrets); + } + if (imagePullSecrets != null) { + this.imagePullSecrets = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : imagePullSecrets) { + this.addToImagePullSecrets(item); + } + } else { + this.imagePullSecrets = null; + } + return (A) this; } - public A withImagePullSecrets(io.kubernetes.client.openapi.models.V1LocalObjectReference... imagePullSecrets) { - if (this.imagePullSecrets != null) {this.imagePullSecrets.clear();} - if (imagePullSecrets != null) {for (io.kubernetes.client.openapi.models.V1LocalObjectReference item :imagePullSecrets){ this.addToImagePullSecrets(item);}} return (A) this; + + public A withImagePullSecrets( + io.kubernetes.client.openapi.models.V1LocalObjectReference... imagePullSecrets) { + if (this.imagePullSecrets != null) { + this.imagePullSecrets.clear(); + } + if (imagePullSecrets != null) { + for (io.kubernetes.client.openapi.models.V1LocalObjectReference item : imagePullSecrets) { + this.addToImagePullSecrets(item); + } + } + return (A) this; } + public java.lang.Boolean hasImagePullSecrets() { return imagePullSecrets != null && !imagePullSecrets.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested addNewImagePullSecret() { - return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl.ImagePullSecretsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + addNewImagePullSecret() { + return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl + .ImagePullSecretsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested addNewImagePullSecretLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl.ImagePullSecretsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + addNewImagePullSecretLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl + .ImagePullSecretsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested setNewImagePullSecretLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl.ImagePullSecretsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + setNewImagePullSecretLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl + .ImagePullSecretsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested editImagePullSecret(java.lang.Integer index) { - if (imagePullSecrets.size() <= index) throw new RuntimeException("Can't edit imagePullSecrets. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + editImagePullSecret(java.lang.Integer index) { + if (imagePullSecrets.size() <= index) + throw new RuntimeException("Can't edit imagePullSecrets. Index exceeds size."); return setNewImagePullSecretLike(index, buildImagePullSecret(index)); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested editFirstImagePullSecret() { - if (imagePullSecrets.size() == 0) throw new RuntimeException("Can't edit first imagePullSecrets. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + editFirstImagePullSecret() { + if (imagePullSecrets.size() == 0) + throw new RuntimeException("Can't edit first imagePullSecrets. The list is empty."); return setNewImagePullSecretLike(0, buildImagePullSecret(0)); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested editLastImagePullSecret() { + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + editLastImagePullSecret() { int index = imagePullSecrets.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last imagePullSecrets. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last imagePullSecrets. The list is empty."); return setNewImagePullSecretLike(index, buildImagePullSecret(index)); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested editMatchingImagePullSecret(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested + editMatchingImagePullSecret( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - public A addToSecrets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item) { - if (this.secrets == null) {this.secrets = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("secrets").add(index >= 0 ? index : _visitables.get("secrets").size(), builder);this.secrets.add(index >= 0 ? index : secrets.size(), builder); return (A)this; + + public A addToSecrets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item) { + if (this.secrets == null) { + this.secrets = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("secrets").add(index >= 0 ? index : _visitables.get("secrets").size(), builder); + this.secrets.add(index >= 0 ? index : secrets.size(), builder); + return (A) this; } - public A setToSecrets(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item) { - if (this.secrets == null) {this.secrets = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); - if (index < 0 || index >= _visitables.get("secrets").size()) { _visitables.get("secrets").add(builder); } else { _visitables.get("secrets").set(index, builder);} - if (index < 0 || index >= secrets.size()) { secrets.add(builder); } else { secrets.set(index, builder);} - return (A)this; + + public A setToSecrets( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item) { + if (this.secrets == null) { + this.secrets = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + if (index < 0 || index >= _visitables.get("secrets").size()) { + _visitables.get("secrets").add(builder); + } else { + _visitables.get("secrets").set(index, builder); + } + if (index < 0 || index >= secrets.size()) { + secrets.add(builder); + } else { + secrets.set(index, builder); + } + return (A) this; } + public A addToSecrets(io.kubernetes.client.openapi.models.V1ObjectReference... items) { - if (this.secrets == null) {this.secrets = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) {io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("secrets").add(builder);this.secrets.add(builder);} return (A)this; + if (this.secrets == null) { + this.secrets = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) { + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("secrets").add(builder); + this.secrets.add(builder); + } + return (A) this; } - public A addAllToSecrets(java.util.Collection items) { - if (this.secrets == null) {this.secrets = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) {io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("secrets").add(builder);this.secrets.add(builder);} return (A)this; + + public A addAllToSecrets( + java.util.Collection items) { + if (this.secrets == null) { + this.secrets = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) { + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("secrets").add(builder); + this.secrets.add(builder); + } + return (A) this; } + public A removeFromSecrets(io.kubernetes.client.openapi.models.V1ObjectReference... items) { - for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) {io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("secrets").remove(builder);if (this.secrets != null) {this.secrets.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) { + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("secrets").remove(builder); + if (this.secrets != null) { + this.secrets.remove(builder); + } + } + return (A) this; } - public A removeAllFromSecrets(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) {io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("secrets").remove(builder);if (this.secrets != null) {this.secrets.remove(builder);}} return (A)this; + + public A removeAllFromSecrets( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) { + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("secrets").remove(builder); + if (this.secrets != null) { + this.secrets.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromSecrets(java.util.function.Predicate predicate) { + + public A removeMatchingFromSecrets( + java.util.function.Predicate + predicate) { if (secrets == null) return (A) this; - final Iterator each = secrets.iterator(); + final Iterator each = + secrets.iterator(); final List visitables = _visitables.get("secrets"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = each.next(); @@ -259,144 +514,252 @@ public A removeMatchingFromSecrets(java.util.function.Predicate getSecrets() { return secrets != null ? build(secrets) : null; } + public java.util.List buildSecrets() { return secrets != null ? build(secrets) : null; } - public io.kubernetes.client.openapi.models.V1ObjectReference buildSecret(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ObjectReference buildSecret( + java.lang.Integer index) { return this.secrets.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ObjectReference buildFirstSecret() { return this.secrets.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ObjectReference buildLastSecret() { return this.secrets.get(secrets.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ObjectReference buildMatchingSecret(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder item: secrets) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ObjectReference buildMatchingSecret( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder item : secrets) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingSecret(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder item: secrets) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingSecret( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder item : secrets) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withSecrets(java.util.List secrets) { - if (this.secrets != null) { _visitables.get("secrets").removeAll(this.secrets);} - if (secrets != null) {this.secrets = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ObjectReference item : secrets){this.addToSecrets(item);}} else { this.secrets = null;} return (A) this; + + public A withSecrets( + java.util.List secrets) { + if (this.secrets != null) { + _visitables.get("secrets").removeAll(this.secrets); + } + if (secrets != null) { + this.secrets = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ObjectReference item : secrets) { + this.addToSecrets(item); + } + } else { + this.secrets = null; + } + return (A) this; } + public A withSecrets(io.kubernetes.client.openapi.models.V1ObjectReference... secrets) { - if (this.secrets != null) {this.secrets.clear();} - if (secrets != null) {for (io.kubernetes.client.openapi.models.V1ObjectReference item :secrets){ this.addToSecrets(item);}} return (A) this; + if (this.secrets != null) { + this.secrets.clear(); + } + if (secrets != null) { + for (io.kubernetes.client.openapi.models.V1ObjectReference item : secrets) { + this.addToSecrets(item); + } + } + return (A) this; } + public java.lang.Boolean hasSecrets() { return secrets != null && !secrets.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested addNewSecret() { + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested + addNewSecret() { return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl.SecretsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested addNewSecretLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl.SecretsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested + addNewSecretLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl.SecretsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested setNewSecretLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item) { - return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl.SecretsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested + setNewSecretLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item) { + return new io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl.SecretsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested editSecret(java.lang.Integer index) { - if (secrets.size() <= index) throw new RuntimeException("Can't edit secrets. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested editSecret( + java.lang.Integer index) { + if (secrets.size() <= index) + throw new RuntimeException("Can't edit secrets. Index exceeds size."); return setNewSecretLike(index, buildSecret(index)); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested editFirstSecret() { - if (secrets.size() == 0) throw new RuntimeException("Can't edit first secrets. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested + editFirstSecret() { + if (secrets.size() == 0) + throw new RuntimeException("Can't edit first secrets. The list is empty."); return setNewSecretLike(0, buildSecret(0)); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested editLastSecret() { + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested + editLastSecret() { int index = secrets.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last secrets. The list is empty."); return setNewSecretLike(index, buildSecret(index)); } - public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested editMatchingSecret(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested + editMatchingSecret( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested,io.kubernetes.client.fluent.Nested{ - ImagePullSecretsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + + public class ImagePullSecretsNestedImpl + extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested> + implements io.kubernetes.client.openapi.models.V1ServiceAccountFluent.ImagePullSecretsNested< + N>, + io.kubernetes.client.fluent.Nested { + ImagePullSecretsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1LocalObjectReference item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); } + ImagePullSecretsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ServiceAccountFluentImpl.this.setToImagePullSecrets(index,builder.build()); + return (N) V1ServiceAccountFluentImpl.this.setToImagePullSecrets(index, builder.build()); } + public N endImagePullSecret() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ServiceAccountFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1ServiceAccountFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SecretsNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested,io.kubernetes.client.fluent.Nested{ - SecretsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item) { + + public class SecretsNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested> + implements io.kubernetes.client.openapi.models.V1ServiceAccountFluent.SecretsNested, + io.kubernetes.client.fluent.Nested { + SecretsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + SecretsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ServiceAccountFluentImpl.this.setToSecrets(index,builder.build()); + return (N) V1ServiceAccountFluentImpl.this.setToSecrets(index, builder.build()); } + public N endSecret() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountListBuilder.java index 7ef511635f..bfad30004d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ServiceAccountListBuilder extends io.kubernetes.client.openapi.models.V1ServiceAccountListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ServiceAccountListBuilder + extends io.kubernetes.client.openapi.models.V1ServiceAccountListFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceAccountListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ServiceAccountList, + io.kubernetes.client.openapi.models.V1ServiceAccountListBuilder> { public V1ServiceAccountListBuilder() { this(false); } + public V1ServiceAccountListBuilder(java.lang.Boolean validationEnabled) { this(new V1ServiceAccountList(), validationEnabled); } - public V1ServiceAccountListBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountListFluent fluent) { + + public V1ServiceAccountListBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountListFluent fluent) { this(fluent, false); } - public V1ServiceAccountListBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ServiceAccountListBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ServiceAccountList(), validationEnabled); } - public V1ServiceAccountListBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountListFluent fluent,io.kubernetes.client.openapi.models.V1ServiceAccountList instance) { + + public V1ServiceAccountListBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountListFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceAccountList instance) { this(fluent, instance, false); } - public V1ServiceAccountListBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountListFluent fluent,io.kubernetes.client.openapi.models.V1ServiceAccountList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ServiceAccountListBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountListFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceAccountList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1ServiceAccountListBuilder(io.kubernetes.client.openapi.models.V1Service fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ServiceAccountListBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountList instance) { - this(instance,false); + + public V1ServiceAccountListBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountList instance) { + this(instance, false); } - public V1ServiceAccountListBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ServiceAccountListBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1ServiceAccountListBuilder(io.kubernetes.client.openapi.models.V1Service this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ServiceAccountListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ServiceAccountList build() { V1ServiceAccountList buildable = new V1ServiceAccountList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1ServiceAccountList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ServiceAccountListBuilder that = (V1ServiceAccountListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountListFluent.java index 9eb745fe14..9011d36eac 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountListFluent.java @@ -1,95 +1,158 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ServiceAccountListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ServiceAccountListFluent< + A extends io.kubernetes.client.openapi.models.V1ServiceAccountListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServiceAccount item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServiceAccount item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServiceAccount item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServiceAccount item); + public A addToItems(io.kubernetes.client.openapi.models.V1ServiceAccount... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1ServiceAccount... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1ServiceAccount buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ServiceAccount buildFirstItem(); + public io.kubernetes.client.openapi.models.V1ServiceAccount buildLastItem(); - public io.kubernetes.client.openapi.models.V1ServiceAccount buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ServiceAccount buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1ServiceAccount... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ServiceAccount item); - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServiceAccount item); - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1ServiceAccount item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServiceAccount item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ServiceAccountFluent>{ + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ServiceAccountFluent< + io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountListFluentImpl.java index 9d056eb25b..1ad1c0faf4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1ServiceAccountListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ServiceAccountListFluent{ - public V1ServiceAccountListFluentImpl() { - } - public V1ServiceAccountListFluentImpl(io.kubernetes.client.openapi.models.V1ServiceAccountList instance) { + +/** Generated */ +public class V1ServiceAccountListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ServiceAccountListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ServiceAccountListFluent { + public V1ServiceAccountListFluentImpl() {} + + public V1ServiceAccountListFluentImpl( + io.kubernetes.client.openapi.models.V1ServiceAccountList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1ServiceAccountListFluentImpl(io.kubernetes.client.openapi.models.V1Serv this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServiceAccount item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder = new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServiceAccount item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder = + new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServiceAccount item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder = new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServiceAccount item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder = + new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1ServiceAccount... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ServiceAccount item : items) {io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder = new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ServiceAccount item : items) { + io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder = + new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ServiceAccount item : items) {io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder = new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ServiceAccount item : items) { + io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder = + new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1ServiceAccount... items) { - for (io.kubernetes.client.openapi.models.V1ServiceAccount item : items) {io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder = new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ServiceAccount item : items) { + io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder = + new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ServiceAccount item : items) {io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder = new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ServiceAccount item : items) { + io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder = + new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder = each.next(); @@ -87,174 +159,281 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1ServiceAccount buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ServiceAccount buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ServiceAccount buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ServiceAccount buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ServiceAccountBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ServiceAccount buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ServiceAccountBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ServiceAccountBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ServiceAccountBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ServiceAccount item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ServiceAccount item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1ServiceAccount... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1ServiceAccount item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1ServiceAccount item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested addNewItem() { + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested + addNewItem() { return new io.kubernetes.client.openapi.models.V1ServiceAccountListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ServiceAccount item) { - return new io.kubernetes.client.openapi.models.V1ServiceAccountListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1ServiceAccount item) { + return new io.kubernetes.client.openapi.models.V1ServiceAccountListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServiceAccount item) { - return new io.kubernetes.client.openapi.models.V1ServiceAccountListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServiceAccount item) { + return new io.kubernetes.client.openapi.models.V1ServiceAccountListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1ServiceAccountListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1ServiceAccountListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1ServiceAccountListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1ServiceAccountListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ServiceAccountListFluentImpl that = (V1ServiceAccountListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServiceAccount item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1ServiceAccountFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServiceAccount item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ServiceAccountBuilder(this); } + io.kubernetes.client.openapi.models.V1ServiceAccountBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ServiceAccountListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1ServiceAccountListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ServiceAccountListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1ServiceAccountListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountTokenProjectionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountTokenProjectionBuilder.java index 9cfa423006..b611efa4db 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountTokenProjectionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountTokenProjectionBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ServiceAccountTokenProjectionBuilder extends io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ServiceAccountTokenProjectionBuilder + extends io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection, + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionBuilder> { public V1ServiceAccountTokenProjectionBuilder() { this(false); } + public V1ServiceAccountTokenProjectionBuilder(java.lang.Boolean validationEnabled) { this(new V1ServiceAccountTokenProjection(), validationEnabled); } - public V1ServiceAccountTokenProjectionBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent fluent) { + + public V1ServiceAccountTokenProjectionBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent fluent) { this(fluent, false); } - public V1ServiceAccountTokenProjectionBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ServiceAccountTokenProjectionBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ServiceAccountTokenProjection(), validationEnabled); } - public V1ServiceAccountTokenProjectionBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent fluent,io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection instance) { + + public V1ServiceAccountTokenProjectionBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection instance) { this(fluent, instance, false); } - public V1ServiceAccountTokenProjectionBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent fluent,io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ServiceAccountTokenProjectionBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAudience(instance.getAudience()); fluent.withExpirationSeconds(instance.getExpirationSeconds()); fluent.withPath(instance.getPath()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ServiceAccountTokenProjectionBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection instance) { - this(instance,false); + + public V1ServiceAccountTokenProjectionBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection instance) { + this(instance, false); } - public V1ServiceAccountTokenProjectionBuilder(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ServiceAccountTokenProjectionBuilder( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAudience(instance.getAudience()); this.withExpirationSeconds(instance.getExpirationSeconds()); this.withPath(instance.getPath()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection build() { V1ServiceAccountTokenProjection buildable = new V1ServiceAccountTokenProjection(); buildable.setAudience(fluent.getAudience()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection build buildable.setPath(fluent.getPath()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ServiceAccountTokenProjectionBuilder that = (V1ServiceAccountTokenProjectionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountTokenProjectionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountTokenProjectionFluent.java index 54d01626ac..77090445e5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountTokenProjectionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountTokenProjectionFluent.java @@ -1,36 +1,44 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Long; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ServiceAccountTokenProjectionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ServiceAccountTokenProjectionFluent< + A extends io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getAudience(); + public A withAudience(java.lang.String audience); + public java.lang.Boolean hasAudience(); - - /** - * Method is deprecated. use withAudience instead. - */ + + /** Method is deprecated. use withAudience instead. */ @java.lang.Deprecated public A withNewAudience(java.lang.String original); + public java.lang.Long getExpirationSeconds(); + public A withExpirationSeconds(java.lang.Long expirationSeconds); + public java.lang.Boolean hasExpirationSeconds(); + public java.lang.String getPath(); + public A withPath(java.lang.String path); + public java.lang.Boolean hasPath(); - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountTokenProjectionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountTokenProjectionFluentImpl.java index 7a2dac6408..9d33d91b67 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountTokenProjectionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceAccountTokenProjectionFluentImpl.java @@ -1,83 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1ServiceAccountTokenProjectionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent{ - public V1ServiceAccountTokenProjectionFluentImpl() { - } - public V1ServiceAccountTokenProjectionFluentImpl(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection instance) { +/** Generated */ +public class V1ServiceAccountTokenProjectionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent { + public V1ServiceAccountTokenProjectionFluentImpl() {} + + public V1ServiceAccountTokenProjectionFluentImpl( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection instance) { this.withAudience(instance.getAudience()); this.withExpirationSeconds(instance.getExpirationSeconds()); this.withPath(instance.getPath()); - } + private java.lang.String audience; private java.lang.Long expirationSeconds; private java.lang.String path; + public java.lang.String getAudience() { return this.audience; } + public A withAudience(java.lang.String audience) { - this.audience=audience; return (A) this; + this.audience = audience; + return (A) this; } + public java.lang.Boolean hasAudience() { return this.audience != null; } - - /** - * Method is deprecated. use withAudience instead. - */ + + /** Method is deprecated. use withAudience instead. */ @java.lang.Deprecated public A withNewAudience(java.lang.String original) { - return (A)withAudience(new String(original)); + return (A) withAudience(new String(original)); } + public java.lang.Long getExpirationSeconds() { return this.expirationSeconds; } + public A withExpirationSeconds(java.lang.Long expirationSeconds) { - this.expirationSeconds=expirationSeconds; return (A) this; + this.expirationSeconds = expirationSeconds; + return (A) this; } + public java.lang.Boolean hasExpirationSeconds() { return this.expirationSeconds != null; } + public java.lang.String getPath() { return this.path; } + public A withPath(java.lang.String path) { - this.path=path; return (A) this; + this.path = path; + return (A) this; } + public java.lang.Boolean hasPath() { return this.path != null; } - - /** - * Method is deprecated. use withPath instead. - */ + + /** Method is deprecated. use withPath instead. */ @java.lang.Deprecated public A withNewPath(java.lang.String original) { - return (A)withPath(new String(original)); + return (A) withPath(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ServiceAccountTokenProjectionFluentImpl that = (V1ServiceAccountTokenProjectionFluentImpl) o; - if (audience != null ? !audience.equals(that.audience) :that.audience != null) return false; - if (expirationSeconds != null ? !expirationSeconds.equals(that.expirationSeconds) :that.expirationSeconds != null) return false; - if (path != null ? !path.equals(that.path) :that.path != null) return false; + if (audience != null ? !audience.equals(that.audience) : that.audience != null) return false; + if (expirationSeconds != null + ? !expirationSeconds.equals(that.expirationSeconds) + : that.expirationSeconds != null) return false; + if (path != null ? !path.equals(that.path) : that.path != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(audience, expirationSeconds, path, super.hashCode()); + return java.util.Objects.hash(audience, expirationSeconds, path, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBackendPortBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBackendPortBuilder.java index 4b25e7da6f..f97aac9fa7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBackendPortBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBackendPortBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ServiceBackendPortBuilder extends io.kubernetes.client.openapi.models.V1ServiceBackendPortFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ServiceBackendPortBuilder + extends io.kubernetes.client.openapi.models.V1ServiceBackendPortFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceBackendPortBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ServiceBackendPort, + io.kubernetes.client.openapi.models.V1ServiceBackendPortBuilder> { public V1ServiceBackendPortBuilder() { this(false); } + public V1ServiceBackendPortBuilder(java.lang.Boolean validationEnabled) { this(new V1ServiceBackendPort(), validationEnabled); } - public V1ServiceBackendPortBuilder(io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent fluent) { + + public V1ServiceBackendPortBuilder( + io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent fluent) { this(fluent, false); } - public V1ServiceBackendPortBuilder(io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ServiceBackendPortBuilder( + io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ServiceBackendPort(), validationEnabled); } - public V1ServiceBackendPortBuilder(io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent fluent,io.kubernetes.client.openapi.models.V1ServiceBackendPort instance) { + + public V1ServiceBackendPortBuilder( + io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceBackendPort instance) { this(fluent, instance, false); } - public V1ServiceBackendPortBuilder(io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent fluent,io.kubernetes.client.openapi.models.V1ServiceBackendPort instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ServiceBackendPortBuilder( + io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceBackendPort instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withNumber(instance.getNumber()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ServiceBackendPortBuilder(io.kubernetes.client.openapi.models.V1ServiceBackendPort instance) { - this(instance,false); + + public V1ServiceBackendPortBuilder( + io.kubernetes.client.openapi.models.V1ServiceBackendPort instance) { + this(instance, false); } - public V1ServiceBackendPortBuilder(io.kubernetes.client.openapi.models.V1ServiceBackendPort instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ServiceBackendPortBuilder( + io.kubernetes.client.openapi.models.V1ServiceBackendPort instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withNumber(instance.getNumber()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ServiceBackendPort build() { V1ServiceBackendPort buildable = new V1ServiceBackendPort(); buildable.setName(fluent.getName()); buildable.setNumber(fluent.getNumber()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ServiceBackendPortBuilder that = (V1ServiceBackendPortBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBackendPortFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBackendPortFluent.java index f0e36ed9f0..a3343a524d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBackendPortFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBackendPortFluent.java @@ -1,27 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ServiceBackendPortFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ServiceBackendPortFluent< + A extends io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Integer getNumber(); + public A withNumber(java.lang.Integer number); + public java.lang.Boolean hasNumber(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBackendPortFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBackendPortFluentImpl.java index 4ed68fc212..999af0e4a6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBackendPortFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBackendPortFluentImpl.java @@ -1,62 +1,76 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ServiceBackendPortFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent { + public V1ServiceBackendPortFluentImpl() {} - /** - * Generated - */ -public class V1ServiceBackendPortFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ServiceBackendPortFluent{ - public V1ServiceBackendPortFluentImpl() { - } - public V1ServiceBackendPortFluentImpl(io.kubernetes.client.openapi.models.V1ServiceBackendPort instance) { + public V1ServiceBackendPortFluentImpl( + io.kubernetes.client.openapi.models.V1ServiceBackendPort instance) { this.withName(instance.getName()); this.withNumber(instance.getNumber()); - } + private java.lang.String name; private java.lang.Integer number; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Integer getNumber() { return this.number; } + public A withNumber(java.lang.Integer number) { - this.number=number; return (A) this; + this.number = number; + return (A) this; } + public java.lang.Boolean hasNumber() { return this.number != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ServiceBackendPortFluentImpl that = (V1ServiceBackendPortFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (number != null ? !number.equals(that.number) :that.number != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (number != null ? !number.equals(that.number) : that.number != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, number, super.hashCode()); + return java.util.Objects.hash(name, number, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBuilder.java index 85aee31ffa..eab733d61c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ServiceBuilder extends io.kubernetes.client.openapi.models.V1ServiceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ServiceBuilder + extends io.kubernetes.client.openapi.models.V1ServiceFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Service, + io.kubernetes.client.openapi.models.V1ServiceBuilder> { public V1ServiceBuilder() { this(false); } + public V1ServiceBuilder(java.lang.Boolean validationEnabled) { this(new V1Service(), validationEnabled); } + public V1ServiceBuilder(io.kubernetes.client.openapi.models.V1ServiceFluent fluent) { this(fluent, false); } - public V1ServiceBuilder(io.kubernetes.client.openapi.models.V1ServiceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ServiceBuilder( + io.kubernetes.client.openapi.models.V1ServiceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Service(), validationEnabled); } - public V1ServiceBuilder(io.kubernetes.client.openapi.models.V1ServiceFluent fluent,io.kubernetes.client.openapi.models.V1Service instance) { + + public V1ServiceBuilder( + io.kubernetes.client.openapi.models.V1ServiceFluent fluent, + io.kubernetes.client.openapi.models.V1Service instance) { this(fluent, instance, false); } - public V1ServiceBuilder(io.kubernetes.client.openapi.models.V1ServiceFluent fluent,io.kubernetes.client.openapi.models.V1Service instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ServiceBuilder( + io.kubernetes.client.openapi.models.V1ServiceFluent fluent, + io.kubernetes.client.openapi.models.V1Service instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,16 @@ public V1ServiceBuilder(io.kubernetes.client.openapi.models.V1ServiceFluent f fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ServiceBuilder(io.kubernetes.client.openapi.models.V1Service instance) { - this(instance,false); + this(instance, false); } - public V1ServiceBuilder(io.kubernetes.client.openapi.models.V1Service instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ServiceBuilder( + io.kubernetes.client.openapi.models.V1Service instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +77,12 @@ public V1ServiceBuilder(io.kubernetes.client.openapi.models.V1Service instance,j this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ServiceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Service build() { V1Service buildable = new V1Service(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +92,23 @@ public io.kubernetes.client.openapi.models.V1Service build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ServiceBuilder that = (V1ServiceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceFluent.java index 298dc81616..02dce1c2ee 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceFluent.java @@ -1,93 +1,142 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ServiceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ServiceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ServiceSpec getSpec(); + public io.kubernetes.client.openapi.models.V1ServiceSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1ServiceSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1ServiceSpec item); + + public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1ServiceSpec item); + public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1ServiceSpec item); - + + public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1ServiceSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ServiceStatus getStatus(); + public io.kubernetes.client.openapi.models.V1ServiceStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1ServiceStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1ServiceStatus item); + + public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1ServiceStatus item); + public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ServiceStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1ServiceStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ServiceSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ServiceSpecFluent< + io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ServiceStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ServiceStatusFluent< + io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceFluentImpl.java index abc1987fc3..20e1a5f700 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1ServiceFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ServiceFluent { + public V1ServiceFluentImpl() {} - /** - * Generated - */ -public class V1ServiceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ServiceFluent{ - public V1ServiceFluentImpl() { - } public V1ServiceFluentImpl(io.kubernetes.client.openapi.models.V1Service instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +28,294 @@ public V1ServiceFluentImpl(io.kubernetes.client.openapi.models.V1Service instanc this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1ServiceSpecBuilder spec; private io.kubernetes.client.openapi.models.V1ServiceStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1ServiceFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1ServiceFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ServiceSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1ServiceSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1ServiceSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1ServiceSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1ServiceSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1ServiceFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1ServiceSpec item) { + + public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1ServiceSpec item) { return new io.kubernetes.client.openapi.models.V1ServiceFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1ServiceSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1ServiceSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1ServiceSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1ServiceSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ServiceStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1ServiceStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1ServiceStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1ServiceStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1ServiceStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1ServiceFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1ServiceStatus item) { + + public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1ServiceStatus item) { return new io.kubernetes.client.openapi.models.V1ServiceFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1ServiceStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1ServiceStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1ServiceStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1ServiceStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ServiceFluentImpl that = (V1ServiceFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ServiceFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1ServiceFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1ServiceSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1ServiceSpecFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1ServiceFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1ServiceSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1ServiceSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ServiceSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1ServiceSpecBuilder builder; + public N and() { return (N) V1ServiceFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1ServiceStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1ServiceStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1ServiceFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1ServiceStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1ServiceStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ServiceStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1ServiceStatusBuilder builder; + public N and() { return (N) V1ServiceFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceListBuilder.java index d8c0dd8901..2d7ff2548b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceListBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ServiceListBuilder extends io.kubernetes.client.openapi.models.V1ServiceListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ServiceListBuilder + extends io.kubernetes.client.openapi.models.V1ServiceListFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ServiceList, + io.kubernetes.client.openapi.models.V1ServiceListBuilder> { public V1ServiceListBuilder() { this(false); } + public V1ServiceListBuilder(java.lang.Boolean validationEnabled) { this(new V1ServiceList(), validationEnabled); } + public V1ServiceListBuilder(io.kubernetes.client.openapi.models.V1ServiceListFluent fluent) { this(fluent, false); } - public V1ServiceListBuilder(io.kubernetes.client.openapi.models.V1ServiceListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ServiceListBuilder( + io.kubernetes.client.openapi.models.V1ServiceListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ServiceList(), validationEnabled); } - public V1ServiceListBuilder(io.kubernetes.client.openapi.models.V1ServiceListFluent fluent,io.kubernetes.client.openapi.models.V1ServiceList instance) { + + public V1ServiceListBuilder( + io.kubernetes.client.openapi.models.V1ServiceListFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceList instance) { this(fluent, instance, false); } - public V1ServiceListBuilder(io.kubernetes.client.openapi.models.V1ServiceListFluent fluent,io.kubernetes.client.openapi.models.V1ServiceList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ServiceListBuilder( + io.kubernetes.client.openapi.models.V1ServiceListFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +55,17 @@ public V1ServiceListBuilder(io.kubernetes.client.openapi.models.V1ServiceListFlu fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ServiceListBuilder(io.kubernetes.client.openapi.models.V1ServiceList instance) { - this(instance,false); + this(instance, false); } - public V1ServiceListBuilder(io.kubernetes.client.openapi.models.V1ServiceList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ServiceListBuilder( + io.kubernetes.client.openapi.models.V1ServiceList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +74,12 @@ public V1ServiceListBuilder(io.kubernetes.client.openapi.models.V1ServiceList in this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ServiceListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ServiceList build() { V1ServiceList buildable = new V1ServiceList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1ServiceList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ServiceListBuilder that = (V1ServiceListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceListFluent.java index b7318fb480..84e4bfbfbd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceListFluent.java @@ -1,95 +1,146 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ServiceListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ServiceListFluent< + A extends io.kubernetes.client.openapi.models.V1ServiceListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Service item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Service item); + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Service item); + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Service item); + public A addToItems(io.kubernetes.client.openapi.models.V1Service... items); + public A addAllToItems(java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1Service... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1Service buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Service buildFirstItem(); + public io.kubernetes.client.openapi.models.V1Service buildLastItem(); - public io.kubernetes.client.openapi.models.V1Service buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1Service buildMatchingItem( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1Service... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Service item); - public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Service item); - public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Service item); + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Service item); + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ServiceFluent>{ + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ServiceFluent< + io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceListFluentImpl.java index da9faa62a4..12f02be88f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1ServiceListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ServiceListFluent{ - public V1ServiceListFluentImpl() { - } +/** Generated */ +public class V1ServiceListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ServiceListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ServiceListFluent { + public V1ServiceListFluentImpl() {} + public V1ServiceListFluentImpl(io.kubernetes.client.openapi.models.V1ServiceList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,117 @@ public V1ServiceListFluentImpl(io.kubernetes.client.openapi.models.V1ServiceList this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Service item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ServiceBuilder builder = new io.kubernetes.client.openapi.models.V1ServiceBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Service item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ServiceBuilder builder = + new io.kubernetes.client.openapi.models.V1ServiceBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Service item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ServiceBuilder builder = new io.kubernetes.client.openapi.models.V1ServiceBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Service item) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ServiceBuilder builder = + new io.kubernetes.client.openapi.models.V1ServiceBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1Service... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Service item : items) {io.kubernetes.client.openapi.models.V1ServiceBuilder builder = new io.kubernetes.client.openapi.models.V1ServiceBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Service item : items) { + io.kubernetes.client.openapi.models.V1ServiceBuilder builder = + new io.kubernetes.client.openapi.models.V1ServiceBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Service item : items) {io.kubernetes.client.openapi.models.V1ServiceBuilder builder = new io.kubernetes.client.openapi.models.V1ServiceBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Service item : items) { + io.kubernetes.client.openapi.models.V1ServiceBuilder builder = + new io.kubernetes.client.openapi.models.V1ServiceBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1Service... items) { - for (io.kubernetes.client.openapi.models.V1Service item : items) {io.kubernetes.client.openapi.models.V1ServiceBuilder builder = new io.kubernetes.client.openapi.models.V1ServiceBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Service item : items) { + io.kubernetes.client.openapi.models.V1ServiceBuilder builder = + new io.kubernetes.client.openapi.models.V1ServiceBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Service item : items) {io.kubernetes.client.openapi.models.V1ServiceBuilder builder = new io.kubernetes.client.openapi.models.V1ServiceBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Service item : items) { + io.kubernetes.client.openapi.models.V1ServiceBuilder builder = + new io.kubernetes.client.openapi.models.V1ServiceBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +151,272 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1Service buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Service buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Service buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Service buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ServiceBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Service buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ServiceBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ServiceBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ServiceBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Service item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Service item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1Service... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1Service item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1Service item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1ServiceListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1Service item) { - return new io.kubernetes.client.openapi.models.V1ServiceListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1Service item) { + return new io.kubernetes.client.openapi.models.V1ServiceListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Service item) { - return new io.kubernetes.client.openapi.models.V1ServiceListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Service item) { + return new io.kubernetes.client.openapi.models.V1ServiceListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1ServiceListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { return new io.kubernetes.client.openapi.models.V1ServiceListFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ServiceListFluentImpl that = (V1ServiceListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1ServiceFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Service item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1ServiceFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1ServiceListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl(java.lang.Integer index, io.kubernetes.client.openapi.models.V1Service item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ServiceBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ServiceBuilder(this); } + io.kubernetes.client.openapi.models.V1ServiceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ServiceListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1ServiceListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1ServiceListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1ServiceListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServicePortBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServicePortBuilder.java index ee6c6715a7..2ea2eb7fd1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServicePortBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServicePortBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ServicePortBuilder extends io.kubernetes.client.openapi.models.V1ServicePortFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ServicePortBuilder + extends io.kubernetes.client.openapi.models.V1ServicePortFluentImpl< + io.kubernetes.client.openapi.models.V1ServicePortBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ServicePort, + io.kubernetes.client.openapi.models.V1ServicePortBuilder> { public V1ServicePortBuilder() { this(false); } + public V1ServicePortBuilder(java.lang.Boolean validationEnabled) { this(new V1ServicePort(), validationEnabled); } + public V1ServicePortBuilder(io.kubernetes.client.openapi.models.V1ServicePortFluent fluent) { this(fluent, false); } - public V1ServicePortBuilder(io.kubernetes.client.openapi.models.V1ServicePortFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ServicePortBuilder( + io.kubernetes.client.openapi.models.V1ServicePortFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ServicePort(), validationEnabled); } - public V1ServicePortBuilder(io.kubernetes.client.openapi.models.V1ServicePortFluent fluent,io.kubernetes.client.openapi.models.V1ServicePort instance) { + + public V1ServicePortBuilder( + io.kubernetes.client.openapi.models.V1ServicePortFluent fluent, + io.kubernetes.client.openapi.models.V1ServicePort instance) { this(fluent, instance, false); } - public V1ServicePortBuilder(io.kubernetes.client.openapi.models.V1ServicePortFluent fluent,io.kubernetes.client.openapi.models.V1ServicePort instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ServicePortBuilder( + io.kubernetes.client.openapi.models.V1ServicePortFluent fluent, + io.kubernetes.client.openapi.models.V1ServicePort instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAppProtocol(instance.getAppProtocol()); fluent.withName(instance.getName()); @@ -33,13 +59,17 @@ public V1ServicePortBuilder(io.kubernetes.client.openapi.models.V1ServicePortFlu fluent.withTargetPort(instance.getTargetPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ServicePortBuilder(io.kubernetes.client.openapi.models.V1ServicePort instance) { - this(instance,false); + this(instance, false); } - public V1ServicePortBuilder(io.kubernetes.client.openapi.models.V1ServicePort instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ServicePortBuilder( + io.kubernetes.client.openapi.models.V1ServicePort instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAppProtocol(instance.getAppProtocol()); this.withName(instance.getName()); @@ -52,10 +82,12 @@ public V1ServicePortBuilder(io.kubernetes.client.openapi.models.V1ServicePort in this.withTargetPort(instance.getTargetPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ServicePortFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ServicePort build() { V1ServicePort buildable = new V1ServicePort(); buildable.setAppProtocol(fluent.getAppProtocol()); @@ -66,18 +98,23 @@ public io.kubernetes.client.openapi.models.V1ServicePort build() { buildable.setTargetPort(fluent.getTargetPort()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ServicePortBuilder that = (V1ServicePortBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServicePortFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServicePortFluent.java index 6af3aea6d5..2148c996e4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServicePortFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServicePortFluent.java @@ -1,48 +1,66 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.custom.IntOrString; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ServicePortFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ServicePortFluent< + A extends io.kubernetes.client.openapi.models.V1ServicePortFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getAppProtocol(); + public A withAppProtocol(java.lang.String appProtocol); + public java.lang.Boolean hasAppProtocol(); - - /** - * Method is deprecated. use withAppProtocol instead. - */ + + /** Method is deprecated. use withAppProtocol instead. */ @java.lang.Deprecated public A withNewAppProtocol(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Integer getNodePort(); + public A withNodePort(java.lang.Integer nodePort); + public java.lang.Boolean hasNodePort(); + public java.lang.Integer getPort(); + public A withPort(java.lang.Integer port); + public java.lang.Boolean hasPort(); + public io.kubernetes.client.openapi.models.V1ServicePort.ProtocolEnum getProtocol(); + public A withProtocol(io.kubernetes.client.openapi.models.V1ServicePort.ProtocolEnum protocol); + public java.lang.Boolean hasProtocol(); + public io.kubernetes.client.custom.IntOrString getTargetPort(); + public A withTargetPort(io.kubernetes.client.custom.IntOrString targetPort); + public java.lang.Boolean hasTargetPort(); + public A withNewTargetPort(int value); + public A withNewTargetPort(java.lang.String value); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServicePortFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServicePortFluentImpl.java index 2c736a3907..3ab47e699e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServicePortFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServicePortFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; import io.kubernetes.client.custom.IntOrString; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - /** - * Generated - */ -public class V1ServicePortFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ServicePortFluent{ - public V1ServicePortFluentImpl() { - } +/** Generated */ +public class V1ServicePortFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ServicePortFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ServicePortFluent { + public V1ServicePortFluentImpl() {} + public V1ServicePortFluentImpl(io.kubernetes.client.openapi.models.V1ServicePort instance) { this.withAppProtocol(instance.getAppProtocol()); @@ -26,104 +33,130 @@ public V1ServicePortFluentImpl(io.kubernetes.client.openapi.models.V1ServicePort this.withProtocol(instance.getProtocol()); this.withTargetPort(instance.getTargetPort()); - } + private java.lang.String appProtocol; private java.lang.String name; private java.lang.Integer nodePort; private java.lang.Integer port; private io.kubernetes.client.openapi.models.V1ServicePort.ProtocolEnum protocol; private io.kubernetes.client.custom.IntOrString targetPort; + public java.lang.String getAppProtocol() { return this.appProtocol; } + public A withAppProtocol(java.lang.String appProtocol) { - this.appProtocol=appProtocol; return (A) this; + this.appProtocol = appProtocol; + return (A) this; } + public java.lang.Boolean hasAppProtocol() { return this.appProtocol != null; } - - /** - * Method is deprecated. use withAppProtocol instead. - */ + + /** Method is deprecated. use withAppProtocol instead. */ @java.lang.Deprecated public A withNewAppProtocol(java.lang.String original) { - return (A)withAppProtocol(new String(original)); + return (A) withAppProtocol(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Integer getNodePort() { return this.nodePort; } + public A withNodePort(java.lang.Integer nodePort) { - this.nodePort=nodePort; return (A) this; + this.nodePort = nodePort; + return (A) this; } + public java.lang.Boolean hasNodePort() { return this.nodePort != null; } + public java.lang.Integer getPort() { return this.port; } + public A withPort(java.lang.Integer port) { - this.port=port; return (A) this; + this.port = port; + return (A) this; } + public java.lang.Boolean hasPort() { return this.port != null; } + public io.kubernetes.client.openapi.models.V1ServicePort.ProtocolEnum getProtocol() { return this.protocol; } + public A withProtocol(io.kubernetes.client.openapi.models.V1ServicePort.ProtocolEnum protocol) { - this.protocol=protocol; return (A) this; + this.protocol = protocol; + return (A) this; } + public java.lang.Boolean hasProtocol() { return this.protocol != null; } + public io.kubernetes.client.custom.IntOrString getTargetPort() { return this.targetPort; } + public A withTargetPort(io.kubernetes.client.custom.IntOrString targetPort) { - this.targetPort=targetPort; return (A) this; + this.targetPort = targetPort; + return (A) this; } + public java.lang.Boolean hasTargetPort() { return this.targetPort != null; } + public A withNewTargetPort(int value) { - return (A)withTargetPort(new IntOrString(value)); + return (A) withTargetPort(new IntOrString(value)); } + public A withNewTargetPort(java.lang.String value) { - return (A)withTargetPort(new IntOrString(value)); + return (A) withTargetPort(new IntOrString(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ServicePortFluentImpl that = (V1ServicePortFluentImpl) o; - if (appProtocol != null ? !appProtocol.equals(that.appProtocol) :that.appProtocol != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (nodePort != null ? !nodePort.equals(that.nodePort) :that.nodePort != null) return false; - if (port != null ? !port.equals(that.port) :that.port != null) return false; - if (protocol != null ? !protocol.equals(that.protocol) :that.protocol != null) return false; - if (targetPort != null ? !targetPort.equals(that.targetPort) :that.targetPort != null) return false; + if (appProtocol != null ? !appProtocol.equals(that.appProtocol) : that.appProtocol != null) + return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (nodePort != null ? !nodePort.equals(that.nodePort) : that.nodePort != null) return false; + if (port != null ? !port.equals(that.port) : that.port != null) return false; + if (protocol != null ? !protocol.equals(that.protocol) : that.protocol != null) return false; + if (targetPort != null ? !targetPort.equals(that.targetPort) : that.targetPort != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(appProtocol, name, nodePort, port, protocol, targetPort, super.hashCode()); + return java.util.Objects.hash( + appProtocol, name, nodePort, port, protocol, targetPort, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceSpecBuilder.java index 95cf67bc25..439d874cf7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceSpecBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ServiceSpecBuilder extends io.kubernetes.client.openapi.models.V1ServiceSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ServiceSpecBuilder + extends io.kubernetes.client.openapi.models.V1ServiceSpecFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ServiceSpec, + io.kubernetes.client.openapi.models.V1ServiceSpecBuilder> { public V1ServiceSpecBuilder() { this(false); } + public V1ServiceSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1ServiceSpec(), validationEnabled); } + public V1ServiceSpecBuilder(io.kubernetes.client.openapi.models.V1ServiceSpecFluent fluent) { this(fluent, false); } - public V1ServiceSpecBuilder(io.kubernetes.client.openapi.models.V1ServiceSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ServiceSpecBuilder( + io.kubernetes.client.openapi.models.V1ServiceSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ServiceSpec(), validationEnabled); } - public V1ServiceSpecBuilder(io.kubernetes.client.openapi.models.V1ServiceSpecFluent fluent,io.kubernetes.client.openapi.models.V1ServiceSpec instance) { + + public V1ServiceSpecBuilder( + io.kubernetes.client.openapi.models.V1ServiceSpecFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceSpec instance) { this(fluent, instance, false); } - public V1ServiceSpecBuilder(io.kubernetes.client.openapi.models.V1ServiceSpecFluent fluent,io.kubernetes.client.openapi.models.V1ServiceSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ServiceSpecBuilder( + io.kubernetes.client.openapi.models.V1ServiceSpecFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAllocateLoadBalancerNodePorts(instance.getAllocateLoadBalancerNodePorts()); fluent.withClusterIP(instance.getClusterIP()); @@ -59,13 +85,17 @@ public V1ServiceSpecBuilder(io.kubernetes.client.openapi.models.V1ServiceSpecFlu fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ServiceSpecBuilder(io.kubernetes.client.openapi.models.V1ServiceSpec instance) { - this(instance,false); + this(instance, false); } - public V1ServiceSpecBuilder(io.kubernetes.client.openapi.models.V1ServiceSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ServiceSpecBuilder( + io.kubernetes.client.openapi.models.V1ServiceSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAllocateLoadBalancerNodePorts(instance.getAllocateLoadBalancerNodePorts()); this.withClusterIP(instance.getClusterIP()); @@ -104,10 +134,12 @@ public V1ServiceSpecBuilder(io.kubernetes.client.openapi.models.V1ServiceSpec in this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ServiceSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ServiceSpec build() { V1ServiceSpec buildable = new V1ServiceSpec(); buildable.setAllocateLoadBalancerNodePorts(fluent.getAllocateLoadBalancerNodePorts()); @@ -131,18 +163,23 @@ public io.kubernetes.client.openapi.models.V1ServiceSpec build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ServiceSpecBuilder that = (V1ServiceSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceSpecFluent.java index 9091e500bc..e088fba2f7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceSpecFluent.java @@ -1,222 +1,388 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; -import java.util.Map; - - /** - * Generated - */ -public interface V1ServiceSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ServiceSpecFluent< + A extends io.kubernetes.client.openapi.models.V1ServiceSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Boolean getAllocateLoadBalancerNodePorts(); + public A withAllocateLoadBalancerNodePorts(java.lang.Boolean allocateLoadBalancerNodePorts); + public java.lang.Boolean hasAllocateLoadBalancerNodePorts(); + public java.lang.String getClusterIP(); + public A withClusterIP(java.lang.String clusterIP); + public java.lang.Boolean hasClusterIP(); - - /** - * Method is deprecated. use withClusterIP instead. - */ + + /** Method is deprecated. use withClusterIP instead. */ @java.lang.Deprecated public A withNewClusterIP(java.lang.String original); - public A addToClusterIPs(java.lang.Integer index,java.lang.String item); - public A setToClusterIPs(java.lang.Integer index,java.lang.String item); + + public A addToClusterIPs(java.lang.Integer index, java.lang.String item); + + public A setToClusterIPs(java.lang.Integer index, java.lang.String item); + public A addToClusterIPs(java.lang.String... items); + public A addAllToClusterIPs(java.util.Collection items); + public A removeFromClusterIPs(java.lang.String... items); + public A removeAllFromClusterIPs(java.util.Collection items); + public java.util.List getClusterIPs(); + public java.lang.String getClusterIP(java.lang.Integer index); + public java.lang.String getFirstClusterIP(); + public java.lang.String getLastClusterIP(); - public java.lang.String getMatchingClusterIP(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingClusterIP(java.util.function.Predicate predicate); + + public java.lang.String getMatchingClusterIP( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingClusterIP( + java.util.function.Predicate predicate); + public A withClusterIPs(java.util.List clusterIPs); + public A withClusterIPs(java.lang.String... clusterIPs); + public java.lang.Boolean hasClusterIPs(); + public A addNewClusterIP(java.lang.String original); - public A addToExternalIPs(java.lang.Integer index,java.lang.String item); - public A setToExternalIPs(java.lang.Integer index,java.lang.String item); + + public A addToExternalIPs(java.lang.Integer index, java.lang.String item); + + public A setToExternalIPs(java.lang.Integer index, java.lang.String item); + public A addToExternalIPs(java.lang.String... items); + public A addAllToExternalIPs(java.util.Collection items); + public A removeFromExternalIPs(java.lang.String... items); + public A removeAllFromExternalIPs(java.util.Collection items); + public java.util.List getExternalIPs(); + public java.lang.String getExternalIP(java.lang.Integer index); + public java.lang.String getFirstExternalIP(); + public java.lang.String getLastExternalIP(); - public java.lang.String getMatchingExternalIP(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingExternalIP(java.util.function.Predicate predicate); + + public java.lang.String getMatchingExternalIP( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingExternalIP( + java.util.function.Predicate predicate); + public A withExternalIPs(java.util.List externalIPs); + public A withExternalIPs(java.lang.String... externalIPs); + public java.lang.Boolean hasExternalIPs(); + public A addNewExternalIP(java.lang.String original); + public java.lang.String getExternalName(); + public A withExternalName(java.lang.String externalName); + public java.lang.Boolean hasExternalName(); - - /** - * Method is deprecated. use withExternalName instead. - */ + + /** Method is deprecated. use withExternalName instead. */ @java.lang.Deprecated public A withNewExternalName(java.lang.String original); - public io.kubernetes.client.openapi.models.V1ServiceSpec.ExternalTrafficPolicyEnum getExternalTrafficPolicy(); - public A withExternalTrafficPolicy(io.kubernetes.client.openapi.models.V1ServiceSpec.ExternalTrafficPolicyEnum externalTrafficPolicy); + + public io.kubernetes.client.openapi.models.V1ServiceSpec.ExternalTrafficPolicyEnum + getExternalTrafficPolicy(); + + public A withExternalTrafficPolicy( + io.kubernetes.client.openapi.models.V1ServiceSpec.ExternalTrafficPolicyEnum + externalTrafficPolicy); + public java.lang.Boolean hasExternalTrafficPolicy(); + public java.lang.Integer getHealthCheckNodePort(); + public A withHealthCheckNodePort(java.lang.Integer healthCheckNodePort); + public java.lang.Boolean hasHealthCheckNodePort(); + public java.lang.String getInternalTrafficPolicy(); + public A withInternalTrafficPolicy(java.lang.String internalTrafficPolicy); + public java.lang.Boolean hasInternalTrafficPolicy(); - - /** - * Method is deprecated. use withInternalTrafficPolicy instead. - */ + + /** Method is deprecated. use withInternalTrafficPolicy instead. */ @java.lang.Deprecated public A withNewInternalTrafficPolicy(java.lang.String original); - public A addToIpFamilies(java.lang.Integer index,java.lang.String item); - public A setToIpFamilies(java.lang.Integer index,java.lang.String item); + + public A addToIpFamilies(java.lang.Integer index, java.lang.String item); + + public A setToIpFamilies(java.lang.Integer index, java.lang.String item); + public A addToIpFamilies(java.lang.String... items); + public A addAllToIpFamilies(java.util.Collection items); + public A removeFromIpFamilies(java.lang.String... items); + public A removeAllFromIpFamilies(java.util.Collection items); + public java.util.List getIpFamilies(); + public java.lang.String getIpFamily(java.lang.Integer index); + public java.lang.String getFirstIpFamily(); + public java.lang.String getLastIpFamily(); - public java.lang.String getMatchingIpFamily(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingIpFamily(java.util.function.Predicate predicate); + + public java.lang.String getMatchingIpFamily( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingIpFamily( + java.util.function.Predicate predicate); + public A withIpFamilies(java.util.List ipFamilies); + public A withIpFamilies(java.lang.String... ipFamilies); + public java.lang.Boolean hasIpFamilies(); + public A addNewIpFamily(java.lang.String original); + public java.lang.String getIpFamilyPolicy(); + public A withIpFamilyPolicy(java.lang.String ipFamilyPolicy); + public java.lang.Boolean hasIpFamilyPolicy(); - - /** - * Method is deprecated. use withIpFamilyPolicy instead. - */ + + /** Method is deprecated. use withIpFamilyPolicy instead. */ @java.lang.Deprecated public A withNewIpFamilyPolicy(java.lang.String original); + public java.lang.String getLoadBalancerClass(); + public A withLoadBalancerClass(java.lang.String loadBalancerClass); + public java.lang.Boolean hasLoadBalancerClass(); - - /** - * Method is deprecated. use withLoadBalancerClass instead. - */ + + /** Method is deprecated. use withLoadBalancerClass instead. */ @java.lang.Deprecated public A withNewLoadBalancerClass(java.lang.String original); + public java.lang.String getLoadBalancerIP(); + public A withLoadBalancerIP(java.lang.String loadBalancerIP); + public java.lang.Boolean hasLoadBalancerIP(); - - /** - * Method is deprecated. use withLoadBalancerIP instead. - */ + + /** Method is deprecated. use withLoadBalancerIP instead. */ @java.lang.Deprecated public A withNewLoadBalancerIP(java.lang.String original); - public A addToLoadBalancerSourceRanges(java.lang.Integer index,java.lang.String item); - public A setToLoadBalancerSourceRanges(java.lang.Integer index,java.lang.String item); + + public A addToLoadBalancerSourceRanges(java.lang.Integer index, java.lang.String item); + + public A setToLoadBalancerSourceRanges(java.lang.Integer index, java.lang.String item); + public A addToLoadBalancerSourceRanges(java.lang.String... items); + public A addAllToLoadBalancerSourceRanges(java.util.Collection items); + public A removeFromLoadBalancerSourceRanges(java.lang.String... items); + public A removeAllFromLoadBalancerSourceRanges(java.util.Collection items); + public java.util.List getLoadBalancerSourceRanges(); + public java.lang.String getLoadBalancerSourceRange(java.lang.Integer index); + public java.lang.String getFirstLoadBalancerSourceRange(); + public java.lang.String getLastLoadBalancerSourceRange(); - public java.lang.String getMatchingLoadBalancerSourceRange(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingLoadBalancerSourceRange(java.util.function.Predicate predicate); + + public java.lang.String getMatchingLoadBalancerSourceRange( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingLoadBalancerSourceRange( + java.util.function.Predicate predicate); + public A withLoadBalancerSourceRanges(java.util.List loadBalancerSourceRanges); + public A withLoadBalancerSourceRanges(java.lang.String... loadBalancerSourceRanges); + public java.lang.Boolean hasLoadBalancerSourceRanges(); + public A addNewLoadBalancerSourceRange(java.lang.String original); - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServicePort item); - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServicePort item); + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServicePort item); + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServicePort item); + public A addToPorts(io.kubernetes.client.openapi.models.V1ServicePort... items); - public A addAllToPorts(java.util.Collection items); + + public A addAllToPorts( + java.util.Collection items); + public A removeFromPorts(io.kubernetes.client.openapi.models.V1ServicePort... items); - public A removeAllFromPorts(java.util.Collection items); - public A removeMatchingFromPorts(java.util.function.Predicate predicate); - + + public A removeAllFromPorts( + java.util.Collection items); + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildPorts instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getPorts(); + public java.util.List buildPorts(); + public io.kubernetes.client.openapi.models.V1ServicePort buildPort(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ServicePort buildFirstPort(); + public io.kubernetes.client.openapi.models.V1ServicePort buildLastPort(); - public io.kubernetes.client.openapi.models.V1ServicePort buildMatchingPort(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ServicePort buildMatchingPort( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate); + public A withPorts(java.util.List ports); + public A withPorts(io.kubernetes.client.openapi.models.V1ServicePort... ports); + public java.lang.Boolean hasPorts(); + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested addNewPort(); - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1ServicePort item); - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServicePort item); - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested editPort(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested addNewPortLike( + io.kubernetes.client.openapi.models.V1ServicePort item); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServicePort item); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested editPort( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested editFirstPort(); + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested editLastPort(); - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested editMatchingPort( + java.util.function.Predicate + predicate); + public java.lang.Boolean getPublishNotReadyAddresses(); + public A withPublishNotReadyAddresses(java.lang.Boolean publishNotReadyAddresses); + public java.lang.Boolean hasPublishNotReadyAddresses(); - public A addToSelector(java.lang.String key,java.lang.String value); - public A addToSelector(java.util.Map map); + + public A addToSelector(java.lang.String key, java.lang.String value); + + public A addToSelector(java.util.Map map); + public A removeFromSelector(java.lang.String key); - public A removeFromSelector(java.util.Map map); - public java.util.Map getSelector(); - public A withSelector(java.util.Map selector); + + public A removeFromSelector(java.util.Map map); + + public java.util.Map getSelector(); + + public A withSelector(java.util.Map selector); + public java.lang.Boolean hasSelector(); + public io.kubernetes.client.openapi.models.V1ServiceSpec.SessionAffinityEnum getSessionAffinity(); - public A withSessionAffinity(io.kubernetes.client.openapi.models.V1ServiceSpec.SessionAffinityEnum sessionAffinity); + + public A withSessionAffinity( + io.kubernetes.client.openapi.models.V1ServiceSpec.SessionAffinityEnum sessionAffinity); + public java.lang.Boolean hasSessionAffinity(); - + /** * This method has been deprecated, please use method buildSessionAffinityConfig instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SessionAffinityConfig getSessionAffinityConfig(); + public io.kubernetes.client.openapi.models.V1SessionAffinityConfig buildSessionAffinityConfig(); - public A withSessionAffinityConfig(io.kubernetes.client.openapi.models.V1SessionAffinityConfig sessionAffinityConfig); + + public A withSessionAffinityConfig( + io.kubernetes.client.openapi.models.V1SessionAffinityConfig sessionAffinityConfig); + public java.lang.Boolean hasSessionAffinityConfig(); - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested withNewSessionAffinityConfig(); - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested withNewSessionAffinityConfigLike(io.kubernetes.client.openapi.models.V1SessionAffinityConfig item); - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested editSessionAffinityConfig(); - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested editOrNewSessionAffinityConfig(); - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested editOrNewSessionAffinityConfigLike(io.kubernetes.client.openapi.models.V1SessionAffinityConfig item); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested + withNewSessionAffinityConfig(); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested + withNewSessionAffinityConfigLike( + io.kubernetes.client.openapi.models.V1SessionAffinityConfig item); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested + editSessionAffinityConfig(); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested + editOrNewSessionAffinityConfig(); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested + editOrNewSessionAffinityConfigLike( + io.kubernetes.client.openapi.models.V1SessionAffinityConfig item); + public io.kubernetes.client.openapi.models.V1ServiceSpec.TypeEnum getType(); + public A withType(io.kubernetes.client.openapi.models.V1ServiceSpec.TypeEnum type); + public java.lang.Boolean hasType(); - public interface PortsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ServicePortFluent>{ + + public interface PortsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ServicePortFluent< + io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested> { public N and(); + public N endPort(); - } - public interface SessionAffinityConfigNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent>{ + + public interface SessionAffinityConfigNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent< + io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested< + N>> { public N and(); + public N endSessionAffinityConfig(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceSpecFluentImpl.java index 68cae6577f..70e98eadb6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceSpecFluentImpl.java @@ -1,27 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; -import java.util.Map; - - /** - * Generated - */ -public class V1ServiceSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ServiceSpecFluent{ - public V1ServiceSpecFluentImpl() { - } + +/** Generated */ +public class V1ServiceSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ServiceSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ServiceSpecFluent { + public V1ServiceSpecFluentImpl() {} + public V1ServiceSpecFluentImpl(io.kubernetes.client.openapi.models.V1ServiceSpec instance) { this.withAllocateLoadBalancerNodePorts(instance.getAllocateLoadBalancerNodePorts()); @@ -60,14 +60,15 @@ public V1ServiceSpecFluentImpl(io.kubernetes.client.openapi.models.V1ServiceSpec this.withSessionAffinityConfig(instance.getSessionAffinityConfig()); this.withType(instance.getType()); - } + private java.lang.Boolean allocateLoadBalancerNodePorts; private java.lang.String clusterIP; private java.util.List clusterIPs; private java.util.List externalIPs; private java.lang.String externalName; - private io.kubernetes.client.openapi.models.V1ServiceSpec.ExternalTrafficPolicyEnum externalTrafficPolicy; + private io.kubernetes.client.openapi.models.V1ServiceSpec.ExternalTrafficPolicyEnum + externalTrafficPolicy; private java.lang.Integer healthCheckNodePort; private java.lang.String internalTrafficPolicy; private java.util.List ipFamilies; @@ -77,383 +78,749 @@ public V1ServiceSpecFluentImpl(io.kubernetes.client.openapi.models.V1ServiceSpec private java.util.List loadBalancerSourceRanges; private java.util.ArrayList ports; private java.lang.Boolean publishNotReadyAddresses; - private java.util.Map selector; + private java.util.Map selector; private io.kubernetes.client.openapi.models.V1ServiceSpec.SessionAffinityEnum sessionAffinity; private io.kubernetes.client.openapi.models.V1SessionAffinityConfigBuilder sessionAffinityConfig; private io.kubernetes.client.openapi.models.V1ServiceSpec.TypeEnum type; + public java.lang.Boolean getAllocateLoadBalancerNodePorts() { return this.allocateLoadBalancerNodePorts; } + public A withAllocateLoadBalancerNodePorts(java.lang.Boolean allocateLoadBalancerNodePorts) { - this.allocateLoadBalancerNodePorts=allocateLoadBalancerNodePorts; return (A) this; + this.allocateLoadBalancerNodePorts = allocateLoadBalancerNodePorts; + return (A) this; } + public java.lang.Boolean hasAllocateLoadBalancerNodePorts() { return this.allocateLoadBalancerNodePorts != null; } + public java.lang.String getClusterIP() { return this.clusterIP; } + public A withClusterIP(java.lang.String clusterIP) { - this.clusterIP=clusterIP; return (A) this; + this.clusterIP = clusterIP; + return (A) this; } + public java.lang.Boolean hasClusterIP() { return this.clusterIP != null; } - - /** - * Method is deprecated. use withClusterIP instead. - */ + + /** Method is deprecated. use withClusterIP instead. */ @java.lang.Deprecated public A withNewClusterIP(java.lang.String original) { - return (A)withClusterIP(new String(original)); + return (A) withClusterIP(new String(original)); } - public A addToClusterIPs(java.lang.Integer index,java.lang.String item) { - if (this.clusterIPs == null) {this.clusterIPs = new java.util.ArrayList();} + + public A addToClusterIPs(java.lang.Integer index, java.lang.String item) { + if (this.clusterIPs == null) { + this.clusterIPs = new java.util.ArrayList(); + } this.clusterIPs.add(index, item); - return (A)this; + return (A) this; } - public A setToClusterIPs(java.lang.Integer index,java.lang.String item) { - if (this.clusterIPs == null) {this.clusterIPs = new java.util.ArrayList();} - this.clusterIPs.set(index, item); return (A)this; + + public A setToClusterIPs(java.lang.Integer index, java.lang.String item) { + if (this.clusterIPs == null) { + this.clusterIPs = new java.util.ArrayList(); + } + this.clusterIPs.set(index, item); + return (A) this; } + public A addToClusterIPs(java.lang.String... items) { - if (this.clusterIPs == null) {this.clusterIPs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.clusterIPs.add(item);} return (A)this; + if (this.clusterIPs == null) { + this.clusterIPs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.clusterIPs.add(item); + } + return (A) this; } + public A addAllToClusterIPs(java.util.Collection items) { - if (this.clusterIPs == null) {this.clusterIPs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.clusterIPs.add(item);} return (A)this; + if (this.clusterIPs == null) { + this.clusterIPs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.clusterIPs.add(item); + } + return (A) this; } + public A removeFromClusterIPs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.clusterIPs!= null){ this.clusterIPs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.clusterIPs != null) { + this.clusterIPs.remove(item); + } + } + return (A) this; } + public A removeAllFromClusterIPs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.clusterIPs!= null){ this.clusterIPs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.clusterIPs != null) { + this.clusterIPs.remove(item); + } + } + return (A) this; } + public java.util.List getClusterIPs() { return this.clusterIPs; } + public java.lang.String getClusterIP(java.lang.Integer index) { return this.clusterIPs.get(index); } + public java.lang.String getFirstClusterIP() { return this.clusterIPs.get(0); } + public java.lang.String getLastClusterIP() { return this.clusterIPs.get(clusterIPs.size() - 1); } - public java.lang.String getMatchingClusterIP(java.util.function.Predicate predicate) { - for (java.lang.String item: clusterIPs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingClusterIP( + java.util.function.Predicate predicate) { + for (java.lang.String item : clusterIPs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingClusterIP(java.util.function.Predicate predicate) { - for (java.lang.String item: clusterIPs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingClusterIP( + java.util.function.Predicate predicate) { + for (java.lang.String item : clusterIPs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withClusterIPs(java.util.List clusterIPs) { - if (clusterIPs != null) {this.clusterIPs = new java.util.ArrayList(); for (java.lang.String item : clusterIPs){this.addToClusterIPs(item);}} else { this.clusterIPs = null;} return (A) this; + if (clusterIPs != null) { + this.clusterIPs = new java.util.ArrayList(); + for (java.lang.String item : clusterIPs) { + this.addToClusterIPs(item); + } + } else { + this.clusterIPs = null; + } + return (A) this; } + public A withClusterIPs(java.lang.String... clusterIPs) { - if (this.clusterIPs != null) {this.clusterIPs.clear();} - if (clusterIPs != null) {for (java.lang.String item :clusterIPs){ this.addToClusterIPs(item);}} return (A) this; + if (this.clusterIPs != null) { + this.clusterIPs.clear(); + } + if (clusterIPs != null) { + for (java.lang.String item : clusterIPs) { + this.addToClusterIPs(item); + } + } + return (A) this; } + public java.lang.Boolean hasClusterIPs() { return clusterIPs != null && !clusterIPs.isEmpty(); } + public A addNewClusterIP(java.lang.String original) { - return (A)addToClusterIPs(new String(original)); + return (A) addToClusterIPs(new String(original)); } - public A addToExternalIPs(java.lang.Integer index,java.lang.String item) { - if (this.externalIPs == null) {this.externalIPs = new java.util.ArrayList();} + + public A addToExternalIPs(java.lang.Integer index, java.lang.String item) { + if (this.externalIPs == null) { + this.externalIPs = new java.util.ArrayList(); + } this.externalIPs.add(index, item); - return (A)this; + return (A) this; } - public A setToExternalIPs(java.lang.Integer index,java.lang.String item) { - if (this.externalIPs == null) {this.externalIPs = new java.util.ArrayList();} - this.externalIPs.set(index, item); return (A)this; + + public A setToExternalIPs(java.lang.Integer index, java.lang.String item) { + if (this.externalIPs == null) { + this.externalIPs = new java.util.ArrayList(); + } + this.externalIPs.set(index, item); + return (A) this; } + public A addToExternalIPs(java.lang.String... items) { - if (this.externalIPs == null) {this.externalIPs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.externalIPs.add(item);} return (A)this; + if (this.externalIPs == null) { + this.externalIPs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.externalIPs.add(item); + } + return (A) this; } + public A addAllToExternalIPs(java.util.Collection items) { - if (this.externalIPs == null) {this.externalIPs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.externalIPs.add(item);} return (A)this; + if (this.externalIPs == null) { + this.externalIPs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.externalIPs.add(item); + } + return (A) this; } + public A removeFromExternalIPs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.externalIPs!= null){ this.externalIPs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.externalIPs != null) { + this.externalIPs.remove(item); + } + } + return (A) this; } + public A removeAllFromExternalIPs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.externalIPs!= null){ this.externalIPs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.externalIPs != null) { + this.externalIPs.remove(item); + } + } + return (A) this; } + public java.util.List getExternalIPs() { return this.externalIPs; } + public java.lang.String getExternalIP(java.lang.Integer index) { return this.externalIPs.get(index); } + public java.lang.String getFirstExternalIP() { return this.externalIPs.get(0); } + public java.lang.String getLastExternalIP() { return this.externalIPs.get(externalIPs.size() - 1); } - public java.lang.String getMatchingExternalIP(java.util.function.Predicate predicate) { - for (java.lang.String item: externalIPs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingExternalIP( + java.util.function.Predicate predicate) { + for (java.lang.String item : externalIPs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingExternalIP(java.util.function.Predicate predicate) { - for (java.lang.String item: externalIPs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingExternalIP( + java.util.function.Predicate predicate) { + for (java.lang.String item : externalIPs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withExternalIPs(java.util.List externalIPs) { - if (externalIPs != null) {this.externalIPs = new java.util.ArrayList(); for (java.lang.String item : externalIPs){this.addToExternalIPs(item);}} else { this.externalIPs = null;} return (A) this; + if (externalIPs != null) { + this.externalIPs = new java.util.ArrayList(); + for (java.lang.String item : externalIPs) { + this.addToExternalIPs(item); + } + } else { + this.externalIPs = null; + } + return (A) this; } + public A withExternalIPs(java.lang.String... externalIPs) { - if (this.externalIPs != null) {this.externalIPs.clear();} - if (externalIPs != null) {for (java.lang.String item :externalIPs){ this.addToExternalIPs(item);}} return (A) this; + if (this.externalIPs != null) { + this.externalIPs.clear(); + } + if (externalIPs != null) { + for (java.lang.String item : externalIPs) { + this.addToExternalIPs(item); + } + } + return (A) this; } + public java.lang.Boolean hasExternalIPs() { return externalIPs != null && !externalIPs.isEmpty(); } + public A addNewExternalIP(java.lang.String original) { - return (A)addToExternalIPs(new String(original)); + return (A) addToExternalIPs(new String(original)); } + public java.lang.String getExternalName() { return this.externalName; } + public A withExternalName(java.lang.String externalName) { - this.externalName=externalName; return (A) this; + this.externalName = externalName; + return (A) this; } + public java.lang.Boolean hasExternalName() { return this.externalName != null; } - - /** - * Method is deprecated. use withExternalName instead. - */ + + /** Method is deprecated. use withExternalName instead. */ @java.lang.Deprecated public A withNewExternalName(java.lang.String original) { - return (A)withExternalName(new String(original)); + return (A) withExternalName(new String(original)); } - public io.kubernetes.client.openapi.models.V1ServiceSpec.ExternalTrafficPolicyEnum getExternalTrafficPolicy() { + + public io.kubernetes.client.openapi.models.V1ServiceSpec.ExternalTrafficPolicyEnum + getExternalTrafficPolicy() { return this.externalTrafficPolicy; } - public A withExternalTrafficPolicy(io.kubernetes.client.openapi.models.V1ServiceSpec.ExternalTrafficPolicyEnum externalTrafficPolicy) { - this.externalTrafficPolicy=externalTrafficPolicy; return (A) this; + + public A withExternalTrafficPolicy( + io.kubernetes.client.openapi.models.V1ServiceSpec.ExternalTrafficPolicyEnum + externalTrafficPolicy) { + this.externalTrafficPolicy = externalTrafficPolicy; + return (A) this; } + public java.lang.Boolean hasExternalTrafficPolicy() { return this.externalTrafficPolicy != null; } + public java.lang.Integer getHealthCheckNodePort() { return this.healthCheckNodePort; } + public A withHealthCheckNodePort(java.lang.Integer healthCheckNodePort) { - this.healthCheckNodePort=healthCheckNodePort; return (A) this; + this.healthCheckNodePort = healthCheckNodePort; + return (A) this; } + public java.lang.Boolean hasHealthCheckNodePort() { return this.healthCheckNodePort != null; } + public java.lang.String getInternalTrafficPolicy() { return this.internalTrafficPolicy; } + public A withInternalTrafficPolicy(java.lang.String internalTrafficPolicy) { - this.internalTrafficPolicy=internalTrafficPolicy; return (A) this; + this.internalTrafficPolicy = internalTrafficPolicy; + return (A) this; } + public java.lang.Boolean hasInternalTrafficPolicy() { return this.internalTrafficPolicy != null; } - - /** - * Method is deprecated. use withInternalTrafficPolicy instead. - */ + + /** Method is deprecated. use withInternalTrafficPolicy instead. */ @java.lang.Deprecated public A withNewInternalTrafficPolicy(java.lang.String original) { - return (A)withInternalTrafficPolicy(new String(original)); + return (A) withInternalTrafficPolicy(new String(original)); } - public A addToIpFamilies(java.lang.Integer index,java.lang.String item) { - if (this.ipFamilies == null) {this.ipFamilies = new java.util.ArrayList();} + + public A addToIpFamilies(java.lang.Integer index, java.lang.String item) { + if (this.ipFamilies == null) { + this.ipFamilies = new java.util.ArrayList(); + } this.ipFamilies.add(index, item); - return (A)this; + return (A) this; } - public A setToIpFamilies(java.lang.Integer index,java.lang.String item) { - if (this.ipFamilies == null) {this.ipFamilies = new java.util.ArrayList();} - this.ipFamilies.set(index, item); return (A)this; + + public A setToIpFamilies(java.lang.Integer index, java.lang.String item) { + if (this.ipFamilies == null) { + this.ipFamilies = new java.util.ArrayList(); + } + this.ipFamilies.set(index, item); + return (A) this; } + public A addToIpFamilies(java.lang.String... items) { - if (this.ipFamilies == null) {this.ipFamilies = new java.util.ArrayList();} - for (java.lang.String item : items) {this.ipFamilies.add(item);} return (A)this; + if (this.ipFamilies == null) { + this.ipFamilies = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.ipFamilies.add(item); + } + return (A) this; } + public A addAllToIpFamilies(java.util.Collection items) { - if (this.ipFamilies == null) {this.ipFamilies = new java.util.ArrayList();} - for (java.lang.String item : items) {this.ipFamilies.add(item);} return (A)this; + if (this.ipFamilies == null) { + this.ipFamilies = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.ipFamilies.add(item); + } + return (A) this; } + public A removeFromIpFamilies(java.lang.String... items) { - for (java.lang.String item : items) {if (this.ipFamilies!= null){ this.ipFamilies.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.ipFamilies != null) { + this.ipFamilies.remove(item); + } + } + return (A) this; } + public A removeAllFromIpFamilies(java.util.Collection items) { - for (java.lang.String item : items) {if (this.ipFamilies!= null){ this.ipFamilies.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.ipFamilies != null) { + this.ipFamilies.remove(item); + } + } + return (A) this; } + public java.util.List getIpFamilies() { return this.ipFamilies; } + public java.lang.String getIpFamily(java.lang.Integer index) { return this.ipFamilies.get(index); } + public java.lang.String getFirstIpFamily() { return this.ipFamilies.get(0); } + public java.lang.String getLastIpFamily() { return this.ipFamilies.get(ipFamilies.size() - 1); } - public java.lang.String getMatchingIpFamily(java.util.function.Predicate predicate) { - for (java.lang.String item: ipFamilies) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingIpFamily( + java.util.function.Predicate predicate) { + for (java.lang.String item : ipFamilies) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingIpFamily(java.util.function.Predicate predicate) { - for (java.lang.String item: ipFamilies) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingIpFamily( + java.util.function.Predicate predicate) { + for (java.lang.String item : ipFamilies) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withIpFamilies(java.util.List ipFamilies) { - if (ipFamilies != null) {this.ipFamilies = new java.util.ArrayList(); for (java.lang.String item : ipFamilies){this.addToIpFamilies(item);}} else { this.ipFamilies = null;} return (A) this; + if (ipFamilies != null) { + this.ipFamilies = new java.util.ArrayList(); + for (java.lang.String item : ipFamilies) { + this.addToIpFamilies(item); + } + } else { + this.ipFamilies = null; + } + return (A) this; } + public A withIpFamilies(java.lang.String... ipFamilies) { - if (this.ipFamilies != null) {this.ipFamilies.clear();} - if (ipFamilies != null) {for (java.lang.String item :ipFamilies){ this.addToIpFamilies(item);}} return (A) this; + if (this.ipFamilies != null) { + this.ipFamilies.clear(); + } + if (ipFamilies != null) { + for (java.lang.String item : ipFamilies) { + this.addToIpFamilies(item); + } + } + return (A) this; } + public java.lang.Boolean hasIpFamilies() { return ipFamilies != null && !ipFamilies.isEmpty(); } + public A addNewIpFamily(java.lang.String original) { - return (A)addToIpFamilies(new String(original)); + return (A) addToIpFamilies(new String(original)); } + public java.lang.String getIpFamilyPolicy() { return this.ipFamilyPolicy; } + public A withIpFamilyPolicy(java.lang.String ipFamilyPolicy) { - this.ipFamilyPolicy=ipFamilyPolicy; return (A) this; + this.ipFamilyPolicy = ipFamilyPolicy; + return (A) this; } + public java.lang.Boolean hasIpFamilyPolicy() { return this.ipFamilyPolicy != null; } - - /** - * Method is deprecated. use withIpFamilyPolicy instead. - */ + + /** Method is deprecated. use withIpFamilyPolicy instead. */ @java.lang.Deprecated public A withNewIpFamilyPolicy(java.lang.String original) { - return (A)withIpFamilyPolicy(new String(original)); + return (A) withIpFamilyPolicy(new String(original)); } + public java.lang.String getLoadBalancerClass() { return this.loadBalancerClass; } + public A withLoadBalancerClass(java.lang.String loadBalancerClass) { - this.loadBalancerClass=loadBalancerClass; return (A) this; + this.loadBalancerClass = loadBalancerClass; + return (A) this; } + public java.lang.Boolean hasLoadBalancerClass() { return this.loadBalancerClass != null; } - - /** - * Method is deprecated. use withLoadBalancerClass instead. - */ + + /** Method is deprecated. use withLoadBalancerClass instead. */ @java.lang.Deprecated public A withNewLoadBalancerClass(java.lang.String original) { - return (A)withLoadBalancerClass(new String(original)); + return (A) withLoadBalancerClass(new String(original)); } + public java.lang.String getLoadBalancerIP() { return this.loadBalancerIP; } + public A withLoadBalancerIP(java.lang.String loadBalancerIP) { - this.loadBalancerIP=loadBalancerIP; return (A) this; + this.loadBalancerIP = loadBalancerIP; + return (A) this; } + public java.lang.Boolean hasLoadBalancerIP() { return this.loadBalancerIP != null; } - - /** - * Method is deprecated. use withLoadBalancerIP instead. - */ + + /** Method is deprecated. use withLoadBalancerIP instead. */ @java.lang.Deprecated public A withNewLoadBalancerIP(java.lang.String original) { - return (A)withLoadBalancerIP(new String(original)); + return (A) withLoadBalancerIP(new String(original)); } - public A addToLoadBalancerSourceRanges(java.lang.Integer index,java.lang.String item) { - if (this.loadBalancerSourceRanges == null) {this.loadBalancerSourceRanges = new java.util.ArrayList();} + + public A addToLoadBalancerSourceRanges(java.lang.Integer index, java.lang.String item) { + if (this.loadBalancerSourceRanges == null) { + this.loadBalancerSourceRanges = new java.util.ArrayList(); + } this.loadBalancerSourceRanges.add(index, item); - return (A)this; + return (A) this; } - public A setToLoadBalancerSourceRanges(java.lang.Integer index,java.lang.String item) { - if (this.loadBalancerSourceRanges == null) {this.loadBalancerSourceRanges = new java.util.ArrayList();} - this.loadBalancerSourceRanges.set(index, item); return (A)this; + + public A setToLoadBalancerSourceRanges(java.lang.Integer index, java.lang.String item) { + if (this.loadBalancerSourceRanges == null) { + this.loadBalancerSourceRanges = new java.util.ArrayList(); + } + this.loadBalancerSourceRanges.set(index, item); + return (A) this; } + public A addToLoadBalancerSourceRanges(java.lang.String... items) { - if (this.loadBalancerSourceRanges == null) {this.loadBalancerSourceRanges = new java.util.ArrayList();} - for (java.lang.String item : items) {this.loadBalancerSourceRanges.add(item);} return (A)this; + if (this.loadBalancerSourceRanges == null) { + this.loadBalancerSourceRanges = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.loadBalancerSourceRanges.add(item); + } + return (A) this; } + public A addAllToLoadBalancerSourceRanges(java.util.Collection items) { - if (this.loadBalancerSourceRanges == null) {this.loadBalancerSourceRanges = new java.util.ArrayList();} - for (java.lang.String item : items) {this.loadBalancerSourceRanges.add(item);} return (A)this; + if (this.loadBalancerSourceRanges == null) { + this.loadBalancerSourceRanges = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.loadBalancerSourceRanges.add(item); + } + return (A) this; } + public A removeFromLoadBalancerSourceRanges(java.lang.String... items) { - for (java.lang.String item : items) {if (this.loadBalancerSourceRanges!= null){ this.loadBalancerSourceRanges.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.loadBalancerSourceRanges != null) { + this.loadBalancerSourceRanges.remove(item); + } + } + return (A) this; } + public A removeAllFromLoadBalancerSourceRanges(java.util.Collection items) { - for (java.lang.String item : items) {if (this.loadBalancerSourceRanges!= null){ this.loadBalancerSourceRanges.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.loadBalancerSourceRanges != null) { + this.loadBalancerSourceRanges.remove(item); + } + } + return (A) this; } + public java.util.List getLoadBalancerSourceRanges() { return this.loadBalancerSourceRanges; } + public java.lang.String getLoadBalancerSourceRange(java.lang.Integer index) { return this.loadBalancerSourceRanges.get(index); } + public java.lang.String getFirstLoadBalancerSourceRange() { return this.loadBalancerSourceRanges.get(0); } + public java.lang.String getLastLoadBalancerSourceRange() { return this.loadBalancerSourceRanges.get(loadBalancerSourceRanges.size() - 1); } - public java.lang.String getMatchingLoadBalancerSourceRange(java.util.function.Predicate predicate) { - for (java.lang.String item: loadBalancerSourceRanges) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingLoadBalancerSourceRange( + java.util.function.Predicate predicate) { + for (java.lang.String item : loadBalancerSourceRanges) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingLoadBalancerSourceRange(java.util.function.Predicate predicate) { - for (java.lang.String item: loadBalancerSourceRanges) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingLoadBalancerSourceRange( + java.util.function.Predicate predicate) { + for (java.lang.String item : loadBalancerSourceRanges) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withLoadBalancerSourceRanges(java.util.List loadBalancerSourceRanges) { - if (loadBalancerSourceRanges != null) {this.loadBalancerSourceRanges = new java.util.ArrayList(); for (java.lang.String item : loadBalancerSourceRanges){this.addToLoadBalancerSourceRanges(item);}} else { this.loadBalancerSourceRanges = null;} return (A) this; + if (loadBalancerSourceRanges != null) { + this.loadBalancerSourceRanges = new java.util.ArrayList(); + for (java.lang.String item : loadBalancerSourceRanges) { + this.addToLoadBalancerSourceRanges(item); + } + } else { + this.loadBalancerSourceRanges = null; + } + return (A) this; } + public A withLoadBalancerSourceRanges(java.lang.String... loadBalancerSourceRanges) { - if (this.loadBalancerSourceRanges != null) {this.loadBalancerSourceRanges.clear();} - if (loadBalancerSourceRanges != null) {for (java.lang.String item :loadBalancerSourceRanges){ this.addToLoadBalancerSourceRanges(item);}} return (A) this; + if (this.loadBalancerSourceRanges != null) { + this.loadBalancerSourceRanges.clear(); + } + if (loadBalancerSourceRanges != null) { + for (java.lang.String item : loadBalancerSourceRanges) { + this.addToLoadBalancerSourceRanges(item); + } + } + return (A) this; } + public java.lang.Boolean hasLoadBalancerSourceRanges() { return loadBalancerSourceRanges != null && !loadBalancerSourceRanges.isEmpty(); } + public A addNewLoadBalancerSourceRange(java.lang.String original) { - return (A)addToLoadBalancerSourceRanges(new String(original)); + return (A) addToLoadBalancerSourceRanges(new String(original)); } - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServicePort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ServicePortBuilder builder = new io.kubernetes.client.openapi.models.V1ServicePortBuilder(item);_visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder);this.ports.add(index >= 0 ? index : ports.size(), builder); return (A)this; + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServicePort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ServicePortBuilder builder = + new io.kubernetes.client.openapi.models.V1ServicePortBuilder(item); + _visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder); + this.ports.add(index >= 0 ? index : ports.size(), builder); + return (A) this; } - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServicePort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ServicePortBuilder builder = new io.kubernetes.client.openapi.models.V1ServicePortBuilder(item); - if (index < 0 || index >= _visitables.get("ports").size()) { _visitables.get("ports").add(builder); } else { _visitables.get("ports").set(index, builder);} - if (index < 0 || index >= ports.size()) { ports.add(builder); } else { ports.set(index, builder);} - return (A)this; + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServicePort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ServicePortBuilder builder = + new io.kubernetes.client.openapi.models.V1ServicePortBuilder(item); + if (index < 0 || index >= _visitables.get("ports").size()) { + _visitables.get("ports").add(builder); + } else { + _visitables.get("ports").set(index, builder); + } + if (index < 0 || index >= ports.size()) { + ports.add(builder); + } else { + ports.set(index, builder); + } + return (A) this; } + public A addToPorts(io.kubernetes.client.openapi.models.V1ServicePort... items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ServicePort item : items) {io.kubernetes.client.openapi.models.V1ServicePortBuilder builder = new io.kubernetes.client.openapi.models.V1ServicePortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ServicePort item : items) { + io.kubernetes.client.openapi.models.V1ServicePortBuilder builder = + new io.kubernetes.client.openapi.models.V1ServicePortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } - public A addAllToPorts(java.util.Collection items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ServicePort item : items) {io.kubernetes.client.openapi.models.V1ServicePortBuilder builder = new io.kubernetes.client.openapi.models.V1ServicePortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + + public A addAllToPorts( + java.util.Collection items) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ServicePort item : items) { + io.kubernetes.client.openapi.models.V1ServicePortBuilder builder = + new io.kubernetes.client.openapi.models.V1ServicePortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } + public A removeFromPorts(io.kubernetes.client.openapi.models.V1ServicePort... items) { - for (io.kubernetes.client.openapi.models.V1ServicePort item : items) {io.kubernetes.client.openapi.models.V1ServicePortBuilder builder = new io.kubernetes.client.openapi.models.V1ServicePortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ServicePort item : items) { + io.kubernetes.client.openapi.models.V1ServicePortBuilder builder = + new io.kubernetes.client.openapi.models.V1ServicePortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeAllFromPorts(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ServicePort item : items) {io.kubernetes.client.openapi.models.V1ServicePortBuilder builder = new io.kubernetes.client.openapi.models.V1ServicePortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + + public A removeAllFromPorts( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ServicePort item : items) { + io.kubernetes.client.openapi.models.V1ServicePortBuilder builder = + new io.kubernetes.client.openapi.models.V1ServicePortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPorts(java.util.function.Predicate predicate) { + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate) { if (ports == null) return (A) this; - final Iterator each = ports.iterator(); + final Iterator each = + ports.iterator(); final List visitables = _visitables.get("ports"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ServicePortBuilder builder = each.next(); @@ -462,224 +829,430 @@ public A removeMatchingFromPorts(java.util.function.Predicate getPorts() { return ports != null ? build(ports) : null; } + public java.util.List buildPorts() { return ports != null ? build(ports) : null; } + public io.kubernetes.client.openapi.models.V1ServicePort buildPort(java.lang.Integer index) { return this.ports.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ServicePort buildFirstPort() { return this.ports.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ServicePort buildLastPort() { return this.ports.get(ports.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ServicePort buildMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ServicePortBuilder item: ports) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ServicePort buildMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ServicePortBuilder item : ports) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ServicePortBuilder item: ports) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ServicePortBuilder item : ports) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withPorts(java.util.List ports) { - if (this.ports != null) { _visitables.get("ports").removeAll(this.ports);} - if (ports != null) {this.ports = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ServicePort item : ports){this.addToPorts(item);}} else { this.ports = null;} return (A) this; + if (this.ports != null) { + _visitables.get("ports").removeAll(this.ports); + } + if (ports != null) { + this.ports = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ServicePort item : ports) { + this.addToPorts(item); + } + } else { + this.ports = null; + } + return (A) this; } + public A withPorts(io.kubernetes.client.openapi.models.V1ServicePort... ports) { - if (this.ports != null) {this.ports.clear();} - if (ports != null) {for (io.kubernetes.client.openapi.models.V1ServicePort item :ports){ this.addToPorts(item);}} return (A) this; + if (this.ports != null) { + this.ports.clear(); + } + if (ports != null) { + for (io.kubernetes.client.openapi.models.V1ServicePort item : ports) { + this.addToPorts(item); + } + } + return (A) this; } + public java.lang.Boolean hasPorts() { return ports != null && !ports.isEmpty(); } + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested addNewPort() { return new io.kubernetes.client.openapi.models.V1ServiceSpecFluentImpl.PortsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1ServicePort item) { - return new io.kubernetes.client.openapi.models.V1ServiceSpecFluentImpl.PortsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested addNewPortLike( + io.kubernetes.client.openapi.models.V1ServicePort item) { + return new io.kubernetes.client.openapi.models.V1ServiceSpecFluentImpl.PortsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServicePort item) { - return new io.kubernetes.client.openapi.models.V1ServiceSpecFluentImpl.PortsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServicePort item) { + return new io.kubernetes.client.openapi.models.V1ServiceSpecFluentImpl.PortsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested editPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested editPort( + java.lang.Integer index) { if (ports.size() <= index) throw new RuntimeException("Can't edit ports. Index exceeds size."); return setNewPortLike(index, buildPort(index)); } + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested editFirstPort() { if (ports.size() == 0) throw new RuntimeException("Can't edit first ports. The list is empty."); return setNewPortLike(0, buildPort(0)); } + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested editLastPort() { int index = ports.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ports. The list is empty."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested editMatchingPort( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i map) { - if(this.selector == null && map != null) { this.selector = new java.util.LinkedHashMap(); } - if(map != null) { this.selector.putAll(map);} return (A)this; + + public A addToSelector(java.util.Map map) { + if (this.selector == null && map != null) { + this.selector = new java.util.LinkedHashMap(); + } + if (map != null) { + this.selector.putAll(map); + } + return (A) this; } + public A removeFromSelector(java.lang.String key) { - if(this.selector == null) { return (A) this; } - if(key != null && this.selector != null) {this.selector.remove(key);} return (A)this; + if (this.selector == null) { + return (A) this; + } + if (key != null && this.selector != null) { + this.selector.remove(key); + } + return (A) this; } - public A removeFromSelector(java.util.Map map) { - if(this.selector == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.selector != null){this.selector.remove(key);}}} return (A)this; + + public A removeFromSelector(java.util.Map map) { + if (this.selector == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.selector != null) { + this.selector.remove(key); + } + } + } + return (A) this; } - public java.util.Map getSelector() { + + public java.util.Map getSelector() { return this.selector; } - public A withSelector(java.util.Map selector) { - if (selector == null) { this.selector = null;} else {this.selector = new java.util.LinkedHashMap(selector);} return (A) this; + + public A withSelector(java.util.Map selector) { + if (selector == null) { + this.selector = null; + } else { + this.selector = new java.util.LinkedHashMap(selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V1ServiceSpec.SessionAffinityEnum getSessionAffinity() { + + public io.kubernetes.client.openapi.models.V1ServiceSpec.SessionAffinityEnum + getSessionAffinity() { return this.sessionAffinity; } - public A withSessionAffinity(io.kubernetes.client.openapi.models.V1ServiceSpec.SessionAffinityEnum sessionAffinity) { - this.sessionAffinity=sessionAffinity; return (A) this; + + public A withSessionAffinity( + io.kubernetes.client.openapi.models.V1ServiceSpec.SessionAffinityEnum sessionAffinity) { + this.sessionAffinity = sessionAffinity; + return (A) this; } + public java.lang.Boolean hasSessionAffinity() { return this.sessionAffinity != null; } - + /** * This method has been deprecated, please use method buildSessionAffinityConfig instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SessionAffinityConfig getSessionAffinityConfig() { - return this.sessionAffinityConfig!=null ?this.sessionAffinityConfig.build():null; + return this.sessionAffinityConfig != null ? this.sessionAffinityConfig.build() : null; } + public io.kubernetes.client.openapi.models.V1SessionAffinityConfig buildSessionAffinityConfig() { - return this.sessionAffinityConfig!=null ?this.sessionAffinityConfig.build():null; + return this.sessionAffinityConfig != null ? this.sessionAffinityConfig.build() : null; } - public A withSessionAffinityConfig(io.kubernetes.client.openapi.models.V1SessionAffinityConfig sessionAffinityConfig) { + + public A withSessionAffinityConfig( + io.kubernetes.client.openapi.models.V1SessionAffinityConfig sessionAffinityConfig) { _visitables.get("sessionAffinityConfig").remove(this.sessionAffinityConfig); - if (sessionAffinityConfig!=null){ this.sessionAffinityConfig= new io.kubernetes.client.openapi.models.V1SessionAffinityConfigBuilder(sessionAffinityConfig); _visitables.get("sessionAffinityConfig").add(this.sessionAffinityConfig);} return (A) this; + if (sessionAffinityConfig != null) { + this.sessionAffinityConfig = + new io.kubernetes.client.openapi.models.V1SessionAffinityConfigBuilder( + sessionAffinityConfig); + _visitables.get("sessionAffinityConfig").add(this.sessionAffinityConfig); + } + return (A) this; } + public java.lang.Boolean hasSessionAffinityConfig() { return this.sessionAffinityConfig != null; } - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested withNewSessionAffinityConfig() { - return new io.kubernetes.client.openapi.models.V1ServiceSpecFluentImpl.SessionAffinityConfigNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested + withNewSessionAffinityConfig() { + return new io.kubernetes.client.openapi.models.V1ServiceSpecFluentImpl + .SessionAffinityConfigNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested withNewSessionAffinityConfigLike(io.kubernetes.client.openapi.models.V1SessionAffinityConfig item) { - return new io.kubernetes.client.openapi.models.V1ServiceSpecFluentImpl.SessionAffinityConfigNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested + withNewSessionAffinityConfigLike( + io.kubernetes.client.openapi.models.V1SessionAffinityConfig item) { + return new io.kubernetes.client.openapi.models.V1ServiceSpecFluentImpl + .SessionAffinityConfigNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested editSessionAffinityConfig() { + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested + editSessionAffinityConfig() { return withNewSessionAffinityConfigLike(getSessionAffinityConfig()); } - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested editOrNewSessionAffinityConfig() { - return withNewSessionAffinityConfigLike(getSessionAffinityConfig() != null ? getSessionAffinityConfig(): new io.kubernetes.client.openapi.models.V1SessionAffinityConfigBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested + editOrNewSessionAffinityConfig() { + return withNewSessionAffinityConfigLike( + getSessionAffinityConfig() != null + ? getSessionAffinityConfig() + : new io.kubernetes.client.openapi.models.V1SessionAffinityConfigBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested editOrNewSessionAffinityConfigLike(io.kubernetes.client.openapi.models.V1SessionAffinityConfig item) { - return withNewSessionAffinityConfigLike(getSessionAffinityConfig() != null ? getSessionAffinityConfig(): item); + + public io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested + editOrNewSessionAffinityConfigLike( + io.kubernetes.client.openapi.models.V1SessionAffinityConfig item) { + return withNewSessionAffinityConfigLike( + getSessionAffinityConfig() != null ? getSessionAffinityConfig() : item); } + public io.kubernetes.client.openapi.models.V1ServiceSpec.TypeEnum getType() { return this.type; } + public A withType(io.kubernetes.client.openapi.models.V1ServiceSpec.TypeEnum type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ServiceSpecFluentImpl that = (V1ServiceSpecFluentImpl) o; - if (allocateLoadBalancerNodePorts != null ? !allocateLoadBalancerNodePorts.equals(that.allocateLoadBalancerNodePorts) :that.allocateLoadBalancerNodePorts != null) return false; - if (clusterIP != null ? !clusterIP.equals(that.clusterIP) :that.clusterIP != null) return false; - if (clusterIPs != null ? !clusterIPs.equals(that.clusterIPs) :that.clusterIPs != null) return false; - if (externalIPs != null ? !externalIPs.equals(that.externalIPs) :that.externalIPs != null) return false; - if (externalName != null ? !externalName.equals(that.externalName) :that.externalName != null) return false; - if (externalTrafficPolicy != null ? !externalTrafficPolicy.equals(that.externalTrafficPolicy) :that.externalTrafficPolicy != null) return false; - if (healthCheckNodePort != null ? !healthCheckNodePort.equals(that.healthCheckNodePort) :that.healthCheckNodePort != null) return false; - if (internalTrafficPolicy != null ? !internalTrafficPolicy.equals(that.internalTrafficPolicy) :that.internalTrafficPolicy != null) return false; - if (ipFamilies != null ? !ipFamilies.equals(that.ipFamilies) :that.ipFamilies != null) return false; - if (ipFamilyPolicy != null ? !ipFamilyPolicy.equals(that.ipFamilyPolicy) :that.ipFamilyPolicy != null) return false; - if (loadBalancerClass != null ? !loadBalancerClass.equals(that.loadBalancerClass) :that.loadBalancerClass != null) return false; - if (loadBalancerIP != null ? !loadBalancerIP.equals(that.loadBalancerIP) :that.loadBalancerIP != null) return false; - if (loadBalancerSourceRanges != null ? !loadBalancerSourceRanges.equals(that.loadBalancerSourceRanges) :that.loadBalancerSourceRanges != null) return false; - if (ports != null ? !ports.equals(that.ports) :that.ports != null) return false; - if (publishNotReadyAddresses != null ? !publishNotReadyAddresses.equals(that.publishNotReadyAddresses) :that.publishNotReadyAddresses != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; - if (sessionAffinity != null ? !sessionAffinity.equals(that.sessionAffinity) :that.sessionAffinity != null) return false; - if (sessionAffinityConfig != null ? !sessionAffinityConfig.equals(that.sessionAffinityConfig) :that.sessionAffinityConfig != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (allocateLoadBalancerNodePorts != null + ? !allocateLoadBalancerNodePorts.equals(that.allocateLoadBalancerNodePorts) + : that.allocateLoadBalancerNodePorts != null) return false; + if (clusterIP != null ? !clusterIP.equals(that.clusterIP) : that.clusterIP != null) + return false; + if (clusterIPs != null ? !clusterIPs.equals(that.clusterIPs) : that.clusterIPs != null) + return false; + if (externalIPs != null ? !externalIPs.equals(that.externalIPs) : that.externalIPs != null) + return false; + if (externalName != null ? !externalName.equals(that.externalName) : that.externalName != null) + return false; + if (externalTrafficPolicy != null + ? !externalTrafficPolicy.equals(that.externalTrafficPolicy) + : that.externalTrafficPolicy != null) return false; + if (healthCheckNodePort != null + ? !healthCheckNodePort.equals(that.healthCheckNodePort) + : that.healthCheckNodePort != null) return false; + if (internalTrafficPolicy != null + ? !internalTrafficPolicy.equals(that.internalTrafficPolicy) + : that.internalTrafficPolicy != null) return false; + if (ipFamilies != null ? !ipFamilies.equals(that.ipFamilies) : that.ipFamilies != null) + return false; + if (ipFamilyPolicy != null + ? !ipFamilyPolicy.equals(that.ipFamilyPolicy) + : that.ipFamilyPolicy != null) return false; + if (loadBalancerClass != null + ? !loadBalancerClass.equals(that.loadBalancerClass) + : that.loadBalancerClass != null) return false; + if (loadBalancerIP != null + ? !loadBalancerIP.equals(that.loadBalancerIP) + : that.loadBalancerIP != null) return false; + if (loadBalancerSourceRanges != null + ? !loadBalancerSourceRanges.equals(that.loadBalancerSourceRanges) + : that.loadBalancerSourceRanges != null) return false; + if (ports != null ? !ports.equals(that.ports) : that.ports != null) return false; + if (publishNotReadyAddresses != null + ? !publishNotReadyAddresses.equals(that.publishNotReadyAddresses) + : that.publishNotReadyAddresses != null) return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; + if (sessionAffinity != null + ? !sessionAffinity.equals(that.sessionAffinity) + : that.sessionAffinity != null) return false; + if (sessionAffinityConfig != null + ? !sessionAffinityConfig.equals(that.sessionAffinityConfig) + : that.sessionAffinityConfig != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(allocateLoadBalancerNodePorts, clusterIP, clusterIPs, externalIPs, externalName, externalTrafficPolicy, healthCheckNodePort, internalTrafficPolicy, ipFamilies, ipFamilyPolicy, loadBalancerClass, loadBalancerIP, loadBalancerSourceRanges, ports, publishNotReadyAddresses, selector, sessionAffinity, sessionAffinityConfig, type, super.hashCode()); + return java.util.Objects.hash( + allocateLoadBalancerNodePorts, + clusterIP, + clusterIPs, + externalIPs, + externalName, + externalTrafficPolicy, + healthCheckNodePort, + internalTrafficPolicy, + ipFamilies, + ipFamilyPolicy, + loadBalancerClass, + loadBalancerIP, + loadBalancerSourceRanges, + ports, + publishNotReadyAddresses, + selector, + sessionAffinity, + sessionAffinityConfig, + type, + super.hashCode()); } - public class PortsNestedImpl extends io.kubernetes.client.openapi.models.V1ServicePortFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested,io.kubernetes.client.fluent.Nested{ - PortsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ServicePort item) { + + public class PortsNestedImpl + extends io.kubernetes.client.openapi.models.V1ServicePortFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested> + implements io.kubernetes.client.openapi.models.V1ServiceSpecFluent.PortsNested, + io.kubernetes.client.fluent.Nested { + PortsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ServicePort item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ServicePortBuilder(this, item); } + PortsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ServicePortBuilder(this); } + io.kubernetes.client.openapi.models.V1ServicePortBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ServiceSpecFluentImpl.this.setToPorts(index,builder.build()); + return (N) V1ServiceSpecFluentImpl.this.setToPorts(index, builder.build()); } + public N endPort() { return and(); } - } - public class SessionAffinityConfigNestedImpl extends io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested,io.kubernetes.client.fluent.Nested{ - SessionAffinityConfigNestedImpl(io.kubernetes.client.openapi.models.V1SessionAffinityConfig item) { - this.builder = new io.kubernetes.client.openapi.models.V1SessionAffinityConfigBuilder(this, item); + + public class SessionAffinityConfigNestedImpl + extends io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceSpecFluent.SessionAffinityConfigNested> + implements io.kubernetes.client.openapi.models.V1ServiceSpecFluent + .SessionAffinityConfigNested< + N>, + io.kubernetes.client.fluent.Nested { + SessionAffinityConfigNestedImpl( + io.kubernetes.client.openapi.models.V1SessionAffinityConfig item) { + this.builder = + new io.kubernetes.client.openapi.models.V1SessionAffinityConfigBuilder(this, item); } + SessionAffinityConfigNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SessionAffinityConfigBuilder(this); } + io.kubernetes.client.openapi.models.V1SessionAffinityConfigBuilder builder; + public N and() { return (N) V1ServiceSpecFluentImpl.this.withSessionAffinityConfig(builder.build()); } + public N endSessionAffinityConfig() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceStatusBuilder.java index 32288ed7a1..cbf683f5ca 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceStatusBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ServiceStatusBuilder extends io.kubernetes.client.openapi.models.V1ServiceStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ServiceStatusBuilder + extends io.kubernetes.client.openapi.models.V1ServiceStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ServiceStatus, + io.kubernetes.client.openapi.models.V1ServiceStatusBuilder> { public V1ServiceStatusBuilder() { this(false); } + public V1ServiceStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1ServiceStatus(), validationEnabled); } - public V1ServiceStatusBuilder(io.kubernetes.client.openapi.models.V1ServiceStatusFluent fluent) { + + public V1ServiceStatusBuilder( + io.kubernetes.client.openapi.models.V1ServiceStatusFluent fluent) { this(fluent, false); } - public V1ServiceStatusBuilder(io.kubernetes.client.openapi.models.V1ServiceStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ServiceStatusBuilder( + io.kubernetes.client.openapi.models.V1ServiceStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ServiceStatus(), validationEnabled); } - public V1ServiceStatusBuilder(io.kubernetes.client.openapi.models.V1ServiceStatusFluent fluent,io.kubernetes.client.openapi.models.V1ServiceStatus instance) { + + public V1ServiceStatusBuilder( + io.kubernetes.client.openapi.models.V1ServiceStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceStatus instance) { this(fluent, instance, false); } - public V1ServiceStatusBuilder(io.kubernetes.client.openapi.models.V1ServiceStatusFluent fluent,io.kubernetes.client.openapi.models.V1ServiceStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ServiceStatusBuilder( + io.kubernetes.client.openapi.models.V1ServiceStatusFluent fluent, + io.kubernetes.client.openapi.models.V1ServiceStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditions(instance.getConditions()); fluent.withLoadBalancer(instance.getLoadBalancer()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ServiceStatusBuilder(io.kubernetes.client.openapi.models.V1ServiceStatus instance) { - this(instance,false); + this(instance, false); } - public V1ServiceStatusBuilder(io.kubernetes.client.openapi.models.V1ServiceStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ServiceStatusBuilder( + io.kubernetes.client.openapi.models.V1ServiceStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditions(instance.getConditions()); this.withLoadBalancer(instance.getLoadBalancer()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ServiceStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ServiceStatus build() { V1ServiceStatus buildable = new V1ServiceStatus(); buildable.setConditions(fluent.getConditions()); buildable.setLoadBalancer(fluent.getLoadBalancer()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ServiceStatusBuilder that = (V1ServiceStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceStatusFluent.java index e7b91675e1..a312f7ca08 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceStatusFluent.java @@ -1,77 +1,140 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ServiceStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item); +/** Generated */ +public interface V1ServiceStatusFluent< + A extends io.kubernetes.client.openapi.models.V1ServiceStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1Condition... items); - public A addAllToConditions(java.util.Collection items); + + public A addAllToConditions( + java.util.Collection items); + public A removeFromConditions(io.kubernetes.client.openapi.models.V1Condition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getConditions(); + public java.util.List buildConditions(); + public io.kubernetes.client.openapi.models.V1Condition buildCondition(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Condition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1Condition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1Condition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); + + public io.kubernetes.client.openapi.models.V1Condition buildMatchingCondition( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate); + + public A withConditions( + java.util.List conditions); + public A withConditions(io.kubernetes.client.openapi.models.V1Condition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1Condition item); - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item); - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1Condition item); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildLoadBalancer instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LoadBalancerStatus getLoadBalancer(); + public io.kubernetes.client.openapi.models.V1LoadBalancerStatus buildLoadBalancer(); + public A withLoadBalancer(io.kubernetes.client.openapi.models.V1LoadBalancerStatus loadBalancer); + public java.lang.Boolean hasLoadBalancer(); - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested withNewLoadBalancer(); - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested withNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item); - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested editLoadBalancer(); - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested editOrNewLoadBalancer(); - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested editOrNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ConditionFluent>{ + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested + withNewLoadBalancer(); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested + withNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested + editLoadBalancer(); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested + editOrNewLoadBalancer(); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested + editOrNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item); + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ConditionFluent< + io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested> { public N and(); + public N endCondition(); - } - public interface LoadBalancerNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent>{ + + public interface LoadBalancerNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluent< + io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested> { public N and(); + public N endLoadBalancer(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceStatusFluentImpl.java index 9c2d95d609..ecd73ee3f3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ServiceStatusFluentImpl.java @@ -1,60 +1,132 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1ServiceStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ServiceStatusFluent{ - public V1ServiceStatusFluentImpl() { - } +/** Generated */ +public class V1ServiceStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ServiceStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ServiceStatusFluent { + public V1ServiceStatusFluentImpl() {} + public V1ServiceStatusFluentImpl(io.kubernetes.client.openapi.models.V1ServiceStatus instance) { this.withConditions(instance.getConditions()); this.withLoadBalancer(instance.getLoadBalancer()); - } + private java.util.ArrayList conditions; private io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder loadBalancer; - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } + public A addToConditions(io.kubernetes.client.openapi.models.V1Condition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Condition item : items) {io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Condition item : items) { + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Condition item : items) {io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Condition item : items) { + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } + public A removeFromConditions(io.kubernetes.client.openapi.models.V1Condition... items) { - for (io.kubernetes.client.openapi.models.V1Condition item : items) {io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Condition item : items) { + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Condition item : items) {io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Condition item : items) { + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ConditionBuilder builder = each.next(); @@ -63,155 +135,266 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { return conditions != null ? build(conditions) : null; } + public java.util.List buildConditions() { return conditions != null ? build(conditions) : null; } + public io.kubernetes.client.openapi.models.V1Condition buildCondition(java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Condition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Condition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Condition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Condition buildMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Condition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Condition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } + public A withConditions(io.kubernetes.client.openapi.models.V1Condition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1Condition item :conditions){ this.addToConditions(item);}} return (A) this; + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1Condition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested addNewCondition() { + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + addNewCondition() { return new io.kubernetes.client.openapi.models.V1ServiceStatusFluentImpl.ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1Condition item) { - return new io.kubernetes.client.openapi.models.V1ServiceStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1Condition item) { + return new io.kubernetes.client.openapi.models.V1ServiceStatusFluentImpl.ConditionsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item) { - return new io.kubernetes.client.openapi.models.V1ServiceStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item) { + return new io.kubernetes.client.openapi.models.V1ServiceStatusFluentImpl.ConditionsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewLoadBalancer() { - return new io.kubernetes.client.openapi.models.V1ServiceStatusFluentImpl.LoadBalancerNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested + withNewLoadBalancer() { + return new io.kubernetes.client.openapi.models.V1ServiceStatusFluentImpl + .LoadBalancerNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested withNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item) { - return new io.kubernetes.client.openapi.models.V1ServiceStatusFluentImpl.LoadBalancerNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested + withNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item) { + return new io.kubernetes.client.openapi.models.V1ServiceStatusFluentImpl.LoadBalancerNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested editLoadBalancer() { + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested + editLoadBalancer() { return withNewLoadBalancerLike(getLoadBalancer()); } - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested editOrNewLoadBalancer() { - return withNewLoadBalancerLike(getLoadBalancer() != null ? getLoadBalancer(): new io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested + editOrNewLoadBalancer() { + return withNewLoadBalancerLike( + getLoadBalancer() != null + ? getLoadBalancer() + : new io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested editOrNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item) { - return withNewLoadBalancerLike(getLoadBalancer() != null ? getLoadBalancer(): item); + + public io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested + editOrNewLoadBalancerLike(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item) { + return withNewLoadBalancerLike(getLoadBalancer() != null ? getLoadBalancer() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ServiceStatusFluentImpl that = (V1ServiceStatusFluentImpl) o; - if (conditions != null ? !conditions.equals(that.conditions) :that.conditions != null) return false; - if (loadBalancer != null ? !loadBalancer.equals(that.loadBalancer) :that.loadBalancer != null) return false; + if (conditions != null ? !conditions.equals(that.conditions) : that.conditions != null) + return false; + if (loadBalancer != null ? !loadBalancer.equals(that.loadBalancer) : that.loadBalancer != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(conditions, loadBalancer, super.hashCode()); + return java.util.Objects.hash(conditions, loadBalancer, super.hashCode()); } - public class ConditionsNestedImpl extends io.kubernetes.client.openapi.models.V1ConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1ConditionFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1ServiceStatusFluent.ConditionsNested, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1ConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ServiceStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1ServiceStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - public class LoadBalancerNestedImpl extends io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested,io.kubernetes.client.fluent.Nested{ + + public class LoadBalancerNestedImpl + extends io.kubernetes.client.openapi.models.V1LoadBalancerStatusFluentImpl< + io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested> + implements io.kubernetes.client.openapi.models.V1ServiceStatusFluent.LoadBalancerNested, + io.kubernetes.client.fluent.Nested { LoadBalancerNestedImpl(io.kubernetes.client.openapi.models.V1LoadBalancerStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder(this, item); } + LoadBalancerNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1LoadBalancerStatusBuilder builder; + public N and() { return (N) V1ServiceStatusFluentImpl.this.withLoadBalancer(builder.build()); } + public N endLoadBalancer() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SessionAffinityConfigBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SessionAffinityConfigBuilder.java index 3498f262d4..5b64b05b20 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SessionAffinityConfigBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SessionAffinityConfigBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SessionAffinityConfigBuilder extends io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SessionAffinityConfigBuilder + extends io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluentImpl< + io.kubernetes.client.openapi.models.V1SessionAffinityConfigBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SessionAffinityConfig, + io.kubernetes.client.openapi.models.V1SessionAffinityConfigBuilder> { public V1SessionAffinityConfigBuilder() { this(false); } + public V1SessionAffinityConfigBuilder(java.lang.Boolean validationEnabled) { this(new V1SessionAffinityConfig(), validationEnabled); } - public V1SessionAffinityConfigBuilder(io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent fluent) { + + public V1SessionAffinityConfigBuilder( + io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent fluent) { this(fluent, false); } - public V1SessionAffinityConfigBuilder(io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SessionAffinityConfigBuilder( + io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SessionAffinityConfig(), validationEnabled); } - public V1SessionAffinityConfigBuilder(io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent fluent,io.kubernetes.client.openapi.models.V1SessionAffinityConfig instance) { + + public V1SessionAffinityConfigBuilder( + io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent fluent, + io.kubernetes.client.openapi.models.V1SessionAffinityConfig instance) { this(fluent, instance, false); } - public V1SessionAffinityConfigBuilder(io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent fluent,io.kubernetes.client.openapi.models.V1SessionAffinityConfig instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SessionAffinityConfigBuilder( + io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent fluent, + io.kubernetes.client.openapi.models.V1SessionAffinityConfig instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withClientIP(instance.getClientIP()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1SessionAffinityConfigBuilder(io.kubernetes.client.openapi.models.V1SessionAffinityConfig instance) { - this(instance,false); + + public V1SessionAffinityConfigBuilder( + io.kubernetes.client.openapi.models.V1SessionAffinityConfig instance) { + this(instance, false); } - public V1SessionAffinityConfigBuilder(io.kubernetes.client.openapi.models.V1SessionAffinityConfig instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SessionAffinityConfigBuilder( + io.kubernetes.client.openapi.models.V1SessionAffinityConfig instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withClientIP(instance.getClientIP()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SessionAffinityConfig build() { V1SessionAffinityConfig buildable = new V1SessionAffinityConfig(); buildable.setClientIP(fluent.getClientIP()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SessionAffinityConfigBuilder that = (V1SessionAffinityConfigBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SessionAffinityConfigFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SessionAffinityConfigFluent.java index 3c3bd7eee1..9dba0c698f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SessionAffinityConfigFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SessionAffinityConfigFluent.java @@ -1,35 +1,57 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SessionAffinityConfigFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1SessionAffinityConfigFluent< + A extends io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildClientIP instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ClientIPConfig getClientIP(); + public io.kubernetes.client.openapi.models.V1ClientIPConfig buildClientIP(); + public A withClientIP(io.kubernetes.client.openapi.models.V1ClientIPConfig clientIP); + public java.lang.Boolean hasClientIP(); - public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested withNewClientIP(); - public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested withNewClientIPLike(io.kubernetes.client.openapi.models.V1ClientIPConfig item); - public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested editClientIP(); - public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested editOrNewClientIP(); - public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested editOrNewClientIPLike(io.kubernetes.client.openapi.models.V1ClientIPConfig item); - public interface ClientIPNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ClientIPConfigFluent>{ + + public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested + withNewClientIP(); + + public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested + withNewClientIPLike(io.kubernetes.client.openapi.models.V1ClientIPConfig item); + + public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested + editClientIP(); + + public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested + editOrNewClientIP(); + + public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested + editOrNewClientIPLike(io.kubernetes.client.openapi.models.V1ClientIPConfig item); + + public interface ClientIPNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ClientIPConfigFluent< + io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested> { public N and(); + public N endClientIP(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SessionAffinityConfigFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SessionAffinityConfigFluentImpl.java index bf11756597..0f0b58af49 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SessionAffinityConfigFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SessionAffinityConfigFluentImpl.java @@ -1,81 +1,122 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1SessionAffinityConfigFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent{ - public V1SessionAffinityConfigFluentImpl() { - } - public V1SessionAffinityConfigFluentImpl(io.kubernetes.client.openapi.models.V1SessionAffinityConfig instance) { - this.withClientIP(instance.getClientIP()); +/** Generated */ +public class V1SessionAffinityConfigFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent { + public V1SessionAffinityConfigFluentImpl() {} + public V1SessionAffinityConfigFluentImpl( + io.kubernetes.client.openapi.models.V1SessionAffinityConfig instance) { + this.withClientIP(instance.getClientIP()); } + private io.kubernetes.client.openapi.models.V1ClientIPConfigBuilder clientIP; - + /** * This method has been deprecated, please use method buildClientIP instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ClientIPConfig getClientIP() { - return this.clientIP!=null ?this.clientIP.build():null; + return this.clientIP != null ? this.clientIP.build() : null; } + public io.kubernetes.client.openapi.models.V1ClientIPConfig buildClientIP() { - return this.clientIP!=null ?this.clientIP.build():null; + return this.clientIP != null ? this.clientIP.build() : null; } + public A withClientIP(io.kubernetes.client.openapi.models.V1ClientIPConfig clientIP) { _visitables.get("clientIP").remove(this.clientIP); - if (clientIP!=null){ this.clientIP= new io.kubernetes.client.openapi.models.V1ClientIPConfigBuilder(clientIP); _visitables.get("clientIP").add(this.clientIP);} return (A) this; + if (clientIP != null) { + this.clientIP = new io.kubernetes.client.openapi.models.V1ClientIPConfigBuilder(clientIP); + _visitables.get("clientIP").add(this.clientIP); + } + return (A) this; } + public java.lang.Boolean hasClientIP() { return this.clientIP != null; } - public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested withNewClientIP() { - return new io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluentImpl.ClientIPNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested + withNewClientIP() { + return new io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluentImpl + .ClientIPNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested withNewClientIPLike(io.kubernetes.client.openapi.models.V1ClientIPConfig item) { - return new io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluentImpl.ClientIPNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested + withNewClientIPLike(io.kubernetes.client.openapi.models.V1ClientIPConfig item) { + return new io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluentImpl + .ClientIPNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested editClientIP() { + + public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested + editClientIP() { return withNewClientIPLike(getClientIP()); } - public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested editOrNewClientIP() { - return withNewClientIPLike(getClientIP() != null ? getClientIP(): new io.kubernetes.client.openapi.models.V1ClientIPConfigBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested + editOrNewClientIP() { + return withNewClientIPLike( + getClientIP() != null + ? getClientIP() + : new io.kubernetes.client.openapi.models.V1ClientIPConfigBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested editOrNewClientIPLike(io.kubernetes.client.openapi.models.V1ClientIPConfig item) { - return withNewClientIPLike(getClientIP() != null ? getClientIP(): item); + + public io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested + editOrNewClientIPLike(io.kubernetes.client.openapi.models.V1ClientIPConfig item) { + return withNewClientIPLike(getClientIP() != null ? getClientIP() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SessionAffinityConfigFluentImpl that = (V1SessionAffinityConfigFluentImpl) o; - if (clientIP != null ? !clientIP.equals(that.clientIP) :that.clientIP != null) return false; + if (clientIP != null ? !clientIP.equals(that.clientIP) : that.clientIP != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(clientIP, super.hashCode()); + return java.util.Objects.hash(clientIP, super.hashCode()); } - public class ClientIPNestedImpl extends io.kubernetes.client.openapi.models.V1ClientIPConfigFluentImpl> implements io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested,io.kubernetes.client.fluent.Nested{ + + public class ClientIPNestedImpl + extends io.kubernetes.client.openapi.models.V1ClientIPConfigFluentImpl< + io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested> + implements io.kubernetes.client.openapi.models.V1SessionAffinityConfigFluent.ClientIPNested< + N>, + io.kubernetes.client.fluent.Nested { ClientIPNestedImpl(io.kubernetes.client.openapi.models.V1ClientIPConfig item) { this.builder = new io.kubernetes.client.openapi.models.V1ClientIPConfigBuilder(this, item); } + ClientIPNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ClientIPConfigBuilder(this); } + io.kubernetes.client.openapi.models.V1ClientIPConfigBuilder builder; + public N and() { return (N) V1SessionAffinityConfigFluentImpl.this.withClientIP(builder.build()); } + public N endClientIP() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetBuilder.java index ee3d9b9010..51245bc311 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StatefulSetBuilder extends io.kubernetes.client.openapi.models.V1StatefulSetFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StatefulSetBuilder + extends io.kubernetes.client.openapi.models.V1StatefulSetFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1StatefulSet, + io.kubernetes.client.openapi.models.V1StatefulSetBuilder> { public V1StatefulSetBuilder() { this(false); } + public V1StatefulSetBuilder(java.lang.Boolean validationEnabled) { this(new V1StatefulSet(), validationEnabled); } + public V1StatefulSetBuilder(io.kubernetes.client.openapi.models.V1StatefulSetFluent fluent) { this(fluent, false); } - public V1StatefulSetBuilder(io.kubernetes.client.openapi.models.V1StatefulSetFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StatefulSetBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1StatefulSet(), validationEnabled); } - public V1StatefulSetBuilder(io.kubernetes.client.openapi.models.V1StatefulSetFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSet instance) { + + public V1StatefulSetBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetFluent fluent, + io.kubernetes.client.openapi.models.V1StatefulSet instance) { this(fluent, instance, false); } - public V1StatefulSetBuilder(io.kubernetes.client.openapi.models.V1StatefulSetFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSet instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StatefulSetBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetFluent fluent, + io.kubernetes.client.openapi.models.V1StatefulSet instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,17 @@ public V1StatefulSetBuilder(io.kubernetes.client.openapi.models.V1StatefulSetFlu fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1StatefulSetBuilder(io.kubernetes.client.openapi.models.V1StatefulSet instance) { - this(instance,false); + this(instance, false); } - public V1StatefulSetBuilder(io.kubernetes.client.openapi.models.V1StatefulSet instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StatefulSetBuilder( + io.kubernetes.client.openapi.models.V1StatefulSet instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +78,12 @@ public V1StatefulSetBuilder(io.kubernetes.client.openapi.models.V1StatefulSet in this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1StatefulSetFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1StatefulSet build() { V1StatefulSet buildable = new V1StatefulSet(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +93,23 @@ public io.kubernetes.client.openapi.models.V1StatefulSet build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1StatefulSetBuilder that = (V1StatefulSetBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetConditionBuilder.java index 6ded8f5be1..017af10d93 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StatefulSetConditionBuilder extends io.kubernetes.client.openapi.models.V1StatefulSetConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StatefulSetConditionBuilder + extends io.kubernetes.client.openapi.models.V1StatefulSetConditionFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1StatefulSetCondition, + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder> { public V1StatefulSetConditionBuilder() { this(false); } + public V1StatefulSetConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1StatefulSetCondition(), validationEnabled); } - public V1StatefulSetConditionBuilder(io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent fluent) { + + public V1StatefulSetConditionBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent fluent) { this(fluent, false); } - public V1StatefulSetConditionBuilder(io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StatefulSetConditionBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1StatefulSetCondition(), validationEnabled); } - public V1StatefulSetConditionBuilder(io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSetCondition instance) { + + public V1StatefulSetConditionBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent fluent, + io.kubernetes.client.openapi.models.V1StatefulSetCondition instance) { this(fluent, instance, false); } - public V1StatefulSetConditionBuilder(io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSetCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StatefulSetConditionBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent fluent, + io.kubernetes.client.openapi.models.V1StatefulSetCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +58,18 @@ public V1StatefulSetConditionBuilder(io.kubernetes.client.openapi.models.V1State fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1StatefulSetConditionBuilder(io.kubernetes.client.openapi.models.V1StatefulSetCondition instance) { - this(instance,false); + + public V1StatefulSetConditionBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetCondition instance) { + this(instance, false); } - public V1StatefulSetConditionBuilder(io.kubernetes.client.openapi.models.V1StatefulSetCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StatefulSetConditionBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,10 +80,12 @@ public V1StatefulSetConditionBuilder(io.kubernetes.client.openapi.models.V1State this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1StatefulSetCondition build() { V1StatefulSetCondition buildable = new V1StatefulSetCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1StatefulSetCondition build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1StatefulSetConditionBuilder that = (V1StatefulSetConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetConditionFluent.java index bbf0bba19d..93c6314421 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetConditionFluent.java @@ -1,54 +1,64 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1StatefulSetConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1StatefulSetConditionFluent< + A extends io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetConditionFluentImpl.java index 8edc7f36b4..cbb0ea1175 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetConditionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1StatefulSetConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent { + public V1StatefulSetConditionFluentImpl() {} - /** - * Generated - */ -public class V1StatefulSetConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent{ - public V1StatefulSetConditionFluentImpl() { - } - public V1StatefulSetConditionFluentImpl(io.kubernetes.client.openapi.models.V1StatefulSetCondition instance) { + public V1StatefulSetConditionFluentImpl( + io.kubernetes.client.openapi.models.V1StatefulSetCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,103 +30,119 @@ public V1StatefulSetConditionFluentImpl(io.kubernetes.client.openapi.models.V1St this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1StatefulSetConditionFluentImpl that = (V1StatefulSetConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetFluent.java index 94236bc571..880bd261b2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetFluent.java @@ -1,93 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1StatefulSetFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1StatefulSetFluent< + A extends io.kubernetes.client.openapi.models.V1StatefulSetFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1StatefulSetSpec getSpec(); + public io.kubernetes.client.openapi.models.V1StatefulSetSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1StatefulSetSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1StatefulSetSpec item); + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1StatefulSetSpec item); + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1StatefulSetSpec item); - + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1StatefulSetSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1StatefulSetStatus getStatus(); + public io.kubernetes.client.openapi.models.V1StatefulSetStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1StatefulSetStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1StatefulSetStatus item); + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1StatefulSetStatus item); + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1StatefulSetStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1StatefulSetStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent< + io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent< + io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetFluentImpl.java index 065d2966a9..68bc07c9ff 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1StatefulSetFluentImpl< + A extends io.kubernetes.client.openapi.models.V1StatefulSetFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1StatefulSetFluent { + public V1StatefulSetFluentImpl() {} - /** - * Generated - */ -public class V1StatefulSetFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StatefulSetFluent{ - public V1StatefulSetFluentImpl() { - } public V1StatefulSetFluentImpl(io.kubernetes.client.openapi.models.V1StatefulSet instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +29,296 @@ public V1StatefulSetFluentImpl(io.kubernetes.client.openapi.models.V1StatefulSet this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1StatefulSetSpecBuilder spec; private io.kubernetes.client.openapi.models.V1StatefulSetStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1StatefulSetFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1StatefulSetFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1StatefulSetSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1StatefulSetSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1StatefulSetSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1StatefulSetSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1StatefulSetSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1StatefulSetFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1StatefulSetSpec item) { + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1StatefulSetSpec item) { return new io.kubernetes.client.openapi.models.V1StatefulSetFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1StatefulSetSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1StatefulSetSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1StatefulSetSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1StatefulSetSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1StatefulSetStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1StatefulSetStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1StatefulSetStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1StatefulSetStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1StatefulSetStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1StatefulSetFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1StatefulSetStatus item) { + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1StatefulSetStatus item) { return new io.kubernetes.client.openapi.models.V1StatefulSetFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1StatefulSetStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1StatefulSetStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1StatefulSetStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1StatefulSetStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1StatefulSetFluentImpl that = (V1StatefulSetFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1StatefulSetFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1StatefulSetFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1StatefulSetFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1StatefulSetSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1StatefulSetSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1StatefulSetSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1StatefulSetSpecBuilder builder; + public N and() { return (N) V1StatefulSetFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1StatefulSetStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1StatefulSetStatusFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1StatefulSetFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1StatefulSetStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1StatefulSetStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1StatefulSetStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1StatefulSetStatusBuilder builder; + public N and() { return (N) V1StatefulSetFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetListBuilder.java index 327ea66ebe..250208d902 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StatefulSetListBuilder extends io.kubernetes.client.openapi.models.V1StatefulSetListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StatefulSetListBuilder + extends io.kubernetes.client.openapi.models.V1StatefulSetListFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1StatefulSetList, + io.kubernetes.client.openapi.models.V1StatefulSetListBuilder> { public V1StatefulSetListBuilder() { this(false); } + public V1StatefulSetListBuilder(java.lang.Boolean validationEnabled) { this(new V1StatefulSetList(), validationEnabled); } - public V1StatefulSetListBuilder(io.kubernetes.client.openapi.models.V1StatefulSetListFluent fluent) { + + public V1StatefulSetListBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetListFluent fluent) { this(fluent, false); } - public V1StatefulSetListBuilder(io.kubernetes.client.openapi.models.V1StatefulSetListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StatefulSetListBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1StatefulSetList(), validationEnabled); } - public V1StatefulSetListBuilder(io.kubernetes.client.openapi.models.V1StatefulSetListFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSetList instance) { + + public V1StatefulSetListBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetListFluent fluent, + io.kubernetes.client.openapi.models.V1StatefulSetList instance) { this(fluent, instance, false); } - public V1StatefulSetListBuilder(io.kubernetes.client.openapi.models.V1StatefulSetListFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSetList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StatefulSetListBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetListFluent fluent, + io.kubernetes.client.openapi.models.V1StatefulSetList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1StatefulSetListBuilder(io.kubernetes.client.openapi.models.V1StatefulSe fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1StatefulSetListBuilder(io.kubernetes.client.openapi.models.V1StatefulSetList instance) { - this(instance,false); + this(instance, false); } - public V1StatefulSetListBuilder(io.kubernetes.client.openapi.models.V1StatefulSetList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StatefulSetListBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1StatefulSetListBuilder(io.kubernetes.client.openapi.models.V1StatefulSe this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1StatefulSetListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1StatefulSetList build() { V1StatefulSetList buildable = new V1StatefulSetList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1StatefulSetList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1StatefulSetListBuilder that = (V1StatefulSetListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetListFluent.java index ddff2a1468..7698a8ab0b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetListFluent.java @@ -1,95 +1,155 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1StatefulSetListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1StatefulSetListFluent< + A extends io.kubernetes.client.openapi.models.V1StatefulSetListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSet item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSet item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatefulSet item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatefulSet item); + public A addToItems(io.kubernetes.client.openapi.models.V1StatefulSet... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1StatefulSet... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1StatefulSet buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1StatefulSet buildFirstItem(); + public io.kubernetes.client.openapi.models.V1StatefulSet buildLastItem(); - public io.kubernetes.client.openapi.models.V1StatefulSet buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1StatefulSet buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1StatefulSet... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1StatefulSet item); - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSet item); - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1StatefulSet item); + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatefulSet item); + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1StatefulSetFluent>{ + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1StatefulSetFluent< + io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetListFluentImpl.java index 6942207195..e89e5b2724 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1StatefulSetListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StatefulSetListFluent{ - public V1StatefulSetListFluentImpl() { - } - public V1StatefulSetListFluentImpl(io.kubernetes.client.openapi.models.V1StatefulSetList instance) { + +/** Generated */ +public class V1StatefulSetListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1StatefulSetListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1StatefulSetListFluent { + public V1StatefulSetListFluentImpl() {} + + public V1StatefulSetListFluentImpl( + io.kubernetes.client.openapi.models.V1StatefulSetList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1StatefulSetListFluentImpl(io.kubernetes.client.openapi.models.V1Statefu this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSet item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder = new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatefulSet item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder = + new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSet item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder = new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatefulSet item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder = + new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1StatefulSet... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1StatefulSet item : items) {io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder = new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1StatefulSet item : items) { + io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder = + new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1StatefulSet item : items) {io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder = new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1StatefulSet item : items) { + io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder = + new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1StatefulSet... items) { - for (io.kubernetes.client.openapi.models.V1StatefulSet item : items) {io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder = new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1StatefulSet item : items) { + io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder = + new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1StatefulSet item : items) {io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder = new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1StatefulSet item : items) { + io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder = + new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder = each.next(); @@ -87,174 +159,277 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1StatefulSet buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1StatefulSet buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1StatefulSet buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1StatefulSet buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1StatefulSetBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1StatefulSet buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1StatefulSetBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1StatefulSetBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1StatefulSetBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1StatefulSet item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1StatefulSet item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1StatefulSet... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1StatefulSet item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1StatefulSet item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1StatefulSetListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1StatefulSet item) { - return new io.kubernetes.client.openapi.models.V1StatefulSetListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1StatefulSet item) { + return new io.kubernetes.client.openapi.models.V1StatefulSetListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSet item) { - return new io.kubernetes.client.openapi.models.V1StatefulSetListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatefulSet item) { + return new io.kubernetes.client.openapi.models.V1StatefulSetListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1StatefulSetListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1StatefulSetListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1StatefulSetListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1StatefulSetListFluentImpl that = (V1StatefulSetListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1StatefulSetFluentImpl> implements io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSet item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1StatefulSetFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1StatefulSetListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatefulSet item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1StatefulSetBuilder(this); } + io.kubernetes.client.openapi.models.V1StatefulSetBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1StatefulSetListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1StatefulSetListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1StatefulSetListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1StatefulSetListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder.java index e3dbdf7d46..dce729067c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder.java @@ -1,63 +1,118 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder extends io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder + extends io.kubernetes.client.openapi.models + .V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl< + io.kubernetes.client.openapi.models + .V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy, + io.kubernetes.client.openapi.models + .V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder> { public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder() { this(false); } - public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder(java.lang.Boolean validationEnabled) { + + public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder( + java.lang.Boolean validationEnabled) { this(new V1StatefulSetPersistentVolumeClaimRetentionPolicy(), validationEnabled); } - public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent fluent) { + + public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent + fluent) { this(fluent, false); } - public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent + fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1StatefulSetPersistentVolumeClaimRetentionPolicy(), validationEnabled); } - public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy instance) { + + public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent + fluent, + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + instance) { this(fluent, instance, false); } - public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent + fluent, + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withWhenDeleted(instance.getWhenDeleted()); fluent.withWhenScaled(instance.getWhenScaled()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy instance) { - this(instance,false); + + public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + instance) { + this(instance, false); } - public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withWhenDeleted(instance.getWhenDeleted()); this.withWhenScaled(instance.getWhenScaled()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent fluent; + + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent + fluent; java.lang.Boolean validationEnabled; - public io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy build() { - V1StatefulSetPersistentVolumeClaimRetentionPolicy buildable = new V1StatefulSetPersistentVolumeClaimRetentionPolicy(); + + public io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + build() { + V1StatefulSetPersistentVolumeClaimRetentionPolicy buildable = + new V1StatefulSetPersistentVolumeClaimRetentionPolicy(); buildable.setWhenDeleted(fluent.getWhenDeleted()); buildable.setWhenScaled(fluent.getWhenScaled()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder that = (V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder that = + (V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent.java index 6f989ed2c8..c780ce6281 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent.java @@ -1,32 +1,41 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent< + A extends + io.kubernetes.client.openapi.models + .V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent< + A>> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getWhenDeleted(); + public A withWhenDeleted(java.lang.String whenDeleted); + public java.lang.Boolean hasWhenDeleted(); - - /** - * Method is deprecated. use withWhenDeleted instead. - */ + + /** Method is deprecated. use withWhenDeleted instead. */ @java.lang.Deprecated public A withNewWhenDeleted(java.lang.String original); + public java.lang.String getWhenScaled(); + public A withWhenScaled(java.lang.String whenScaled); + public java.lang.Boolean hasWhenScaled(); - - /** - * Method is deprecated. use withWhenScaled instead. - */ + + /** Method is deprecated. use withWhenScaled instead. */ @java.lang.Deprecated public A withNewWhenScaled(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl.java index 204ce06d4a..3f98a8106f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl.java @@ -1,69 +1,91 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl< + A extends + io.kubernetes.client.openapi.models + .V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent< + A>> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models + .V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent< + A> { + public V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl() {} - /** - * Generated - */ -public class V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent{ - public V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl() { - } - public V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy instance) { + public V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + instance) { this.withWhenDeleted(instance.getWhenDeleted()); this.withWhenScaled(instance.getWhenScaled()); - } + private java.lang.String whenDeleted; private java.lang.String whenScaled; + public java.lang.String getWhenDeleted() { return this.whenDeleted; } + public A withWhenDeleted(java.lang.String whenDeleted) { - this.whenDeleted=whenDeleted; return (A) this; + this.whenDeleted = whenDeleted; + return (A) this; } + public java.lang.Boolean hasWhenDeleted() { return this.whenDeleted != null; } - - /** - * Method is deprecated. use withWhenDeleted instead. - */ + + /** Method is deprecated. use withWhenDeleted instead. */ @java.lang.Deprecated public A withNewWhenDeleted(java.lang.String original) { - return (A)withWhenDeleted(new String(original)); + return (A) withWhenDeleted(new String(original)); } + public java.lang.String getWhenScaled() { return this.whenScaled; } + public A withWhenScaled(java.lang.String whenScaled) { - this.whenScaled=whenScaled; return (A) this; + this.whenScaled = whenScaled; + return (A) this; } + public java.lang.Boolean hasWhenScaled() { return this.whenScaled != null; } - - /** - * Method is deprecated. use withWhenScaled instead. - */ + + /** Method is deprecated. use withWhenScaled instead. */ @java.lang.Deprecated public A withNewWhenScaled(java.lang.String original) { - return (A)withWhenScaled(new String(original)); + return (A) withWhenScaled(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl that = (V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl) o; - if (whenDeleted != null ? !whenDeleted.equals(that.whenDeleted) :that.whenDeleted != null) return false; - if (whenScaled != null ? !whenScaled.equals(that.whenScaled) :that.whenScaled != null) return false; + V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl that = + (V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl) o; + if (whenDeleted != null ? !whenDeleted.equals(that.whenDeleted) : that.whenDeleted != null) + return false; + if (whenScaled != null ? !whenScaled.equals(that.whenScaled) : that.whenScaled != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(whenDeleted, whenScaled, super.hashCode()); + return java.util.Objects.hash(whenDeleted, whenScaled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetSpecBuilder.java index cfca3e1d32..d29bdf660b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetSpecBuilder.java @@ -1,29 +1,57 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StatefulSetSpecBuilder extends io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StatefulSetSpecBuilder + extends io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1StatefulSetSpec, + io.kubernetes.client.openapi.models.V1StatefulSetSpecBuilder> { public V1StatefulSetSpecBuilder() { this(false); } + public V1StatefulSetSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1StatefulSetSpec(), validationEnabled); } - public V1StatefulSetSpecBuilder(io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent fluent) { + + public V1StatefulSetSpecBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent fluent) { this(fluent, false); } - public V1StatefulSetSpecBuilder(io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StatefulSetSpecBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1StatefulSetSpec(), validationEnabled); } - public V1StatefulSetSpecBuilder(io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSetSpec instance) { + + public V1StatefulSetSpecBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent fluent, + io.kubernetes.client.openapi.models.V1StatefulSetSpec instance) { this(fluent, instance, false); } - public V1StatefulSetSpecBuilder(io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSetSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StatefulSetSpecBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent fluent, + io.kubernetes.client.openapi.models.V1StatefulSetSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMinReadySeconds(instance.getMinReadySeconds()); - fluent.withPersistentVolumeClaimRetentionPolicy(instance.getPersistentVolumeClaimRetentionPolicy()); + fluent.withPersistentVolumeClaimRetentionPolicy( + instance.getPersistentVolumeClaimRetentionPolicy()); fluent.withPodManagementPolicy(instance.getPodManagementPolicy()); @@ -41,16 +69,21 @@ public V1StatefulSetSpecBuilder(io.kubernetes.client.openapi.models.V1StatefulSe fluent.withVolumeClaimTemplates(instance.getVolumeClaimTemplates()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1StatefulSetSpecBuilder(io.kubernetes.client.openapi.models.V1StatefulSetSpec instance) { - this(instance,false); + this(instance, false); } - public V1StatefulSetSpecBuilder(io.kubernetes.client.openapi.models.V1StatefulSetSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StatefulSetSpecBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMinReadySeconds(instance.getMinReadySeconds()); - this.withPersistentVolumeClaimRetentionPolicy(instance.getPersistentVolumeClaimRetentionPolicy()); + this.withPersistentVolumeClaimRetentionPolicy( + instance.getPersistentVolumeClaimRetentionPolicy()); this.withPodManagementPolicy(instance.getPodManagementPolicy()); @@ -68,14 +101,17 @@ public V1StatefulSetSpecBuilder(io.kubernetes.client.openapi.models.V1StatefulSe this.withVolumeClaimTemplates(instance.getVolumeClaimTemplates()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1StatefulSetSpec build() { V1StatefulSetSpec buildable = new V1StatefulSetSpec(); buildable.setMinReadySeconds(fluent.getMinReadySeconds()); - buildable.setPersistentVolumeClaimRetentionPolicy(fluent.getPersistentVolumeClaimRetentionPolicy()); + buildable.setPersistentVolumeClaimRetentionPolicy( + fluent.getPersistentVolumeClaimRetentionPolicy()); buildable.setPodManagementPolicy(fluent.getPodManagementPolicy()); buildable.setReplicas(fluent.getReplicas()); buildable.setRevisionHistoryLimit(fluent.getRevisionHistoryLimit()); @@ -86,18 +122,23 @@ public io.kubernetes.client.openapi.models.V1StatefulSetSpec build() { buildable.setVolumeClaimTemplates(fluent.getVolumeClaimTemplates()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1StatefulSetSpecBuilder that = (V1StatefulSetSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetSpecFluent.java index 11dfe3ecdf..5aa012e83e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetSpecFluent.java @@ -1,158 +1,333 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1StatefulSetSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1StatefulSetSpecFluent< + A extends io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getMinReadySeconds(); + public A withMinReadySeconds(java.lang.Integer minReadySeconds); + public java.lang.Boolean hasMinReadySeconds(); - + /** - * This method has been deprecated, please use method buildPersistentVolumeClaimRetentionPolicy instead. + * This method has been deprecated, please use method buildPersistentVolumeClaimRetentionPolicy + * instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy getPersistentVolumeClaimRetentionPolicy(); - public io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy buildPersistentVolumeClaimRetentionPolicy(); - public A withPersistentVolumeClaimRetentionPolicy(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy persistentVolumeClaimRetentionPolicy); + public io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + getPersistentVolumeClaimRetentionPolicy(); + + public io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + buildPersistentVolumeClaimRetentionPolicy(); + + public A withPersistentVolumeClaimRetentionPolicy( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + persistentVolumeClaimRetentionPolicy); + public java.lang.Boolean hasPersistentVolumeClaimRetentionPolicy(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.PersistentVolumeClaimRetentionPolicyNested withNewPersistentVolumeClaimRetentionPolicy(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.PersistentVolumeClaimRetentionPolicyNested withNewPersistentVolumeClaimRetentionPolicyLike(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy item); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.PersistentVolumeClaimRetentionPolicyNested editPersistentVolumeClaimRetentionPolicy(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.PersistentVolumeClaimRetentionPolicyNested editOrNewPersistentVolumeClaimRetentionPolicy(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.PersistentVolumeClaimRetentionPolicyNested editOrNewPersistentVolumeClaimRetentionPolicyLike(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy item); - public io.kubernetes.client.openapi.models.V1StatefulSetSpec.PodManagementPolicyEnum getPodManagementPolicy(); - public A withPodManagementPolicy(io.kubernetes.client.openapi.models.V1StatefulSetSpec.PodManagementPolicyEnum podManagementPolicy); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .PersistentVolumeClaimRetentionPolicyNested< + A> + withNewPersistentVolumeClaimRetentionPolicy(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .PersistentVolumeClaimRetentionPolicyNested< + A> + withNewPersistentVolumeClaimRetentionPolicyLike( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .PersistentVolumeClaimRetentionPolicyNested< + A> + editPersistentVolumeClaimRetentionPolicy(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .PersistentVolumeClaimRetentionPolicyNested< + A> + editOrNewPersistentVolumeClaimRetentionPolicy(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .PersistentVolumeClaimRetentionPolicyNested< + A> + editOrNewPersistentVolumeClaimRetentionPolicyLike( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpec.PodManagementPolicyEnum + getPodManagementPolicy(); + + public A withPodManagementPolicy( + io.kubernetes.client.openapi.models.V1StatefulSetSpec.PodManagementPolicyEnum + podManagementPolicy); + public java.lang.Boolean hasPodManagementPolicy(); + public java.lang.Integer getReplicas(); + public A withReplicas(java.lang.Integer replicas); + public java.lang.Boolean hasReplicas(); + public java.lang.Integer getRevisionHistoryLimit(); + public A withRevisionHistoryLimit(java.lang.Integer revisionHistoryLimit); + public java.lang.Boolean hasRevisionHistoryLimit(); - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested editSelector(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested + withNewSelector(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested + editSelector(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested + editOrNewSelector(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + public java.lang.String getServiceName(); + public A withServiceName(java.lang.String serviceName); + public java.lang.Boolean hasServiceName(); - - /** - * Method is deprecated. use withServiceName instead. - */ + + /** Method is deprecated. use withServiceName instead. */ @java.lang.Deprecated public A withNewServiceName(java.lang.String original); - + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate(); + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate(); + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template); + public java.lang.Boolean hasTemplate(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested withNewTemplate(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested editTemplate(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested editOrNewTemplate(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); - + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested + withNewTemplate(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested + withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested + editTemplate(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested + editOrNewTemplate(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item); + /** * This method has been deprecated, please use method buildUpdateStrategy instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy getUpdateStrategy(); + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy buildUpdateStrategy(); - public A withUpdateStrategy(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy updateStrategy); + + public A withUpdateStrategy( + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy updateStrategy); + public java.lang.Boolean hasUpdateStrategy(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested withNewUpdateStrategy(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested withNewUpdateStrategyLike(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy item); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested editUpdateStrategy(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested editOrNewUpdateStrategy(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested editOrNewUpdateStrategyLike(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy item); - public A addToVolumeClaimTemplates(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); - public A setToVolumeClaimTemplates(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); - public A addToVolumeClaimTemplates(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items); - public A addAllToVolumeClaimTemplates(java.util.Collection items); - public A removeFromVolumeClaimTemplates(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items); - public A removeAllFromVolumeClaimTemplates(java.util.Collection items); - public A removeMatchingFromVolumeClaimTemplates(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested + withNewUpdateStrategy(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested + withNewUpdateStrategyLike( + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested + editUpdateStrategy(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested + editOrNewUpdateStrategy(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested + editOrNewUpdateStrategyLike( + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy item); + + public A addToVolumeClaimTemplates( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); + + public A setToVolumeClaimTemplates( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); + + public A addToVolumeClaimTemplates( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items); + + public A addAllToVolumeClaimTemplates( + java.util.Collection items); + + public A removeFromVolumeClaimTemplates( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items); + + public A removeAllFromVolumeClaimTemplates( + java.util.Collection items); + + public A removeMatchingFromVolumeClaimTemplates( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate); + /** * This method has been deprecated, please use method buildVolumeClaimTemplates instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getVolumeClaimTemplates(); - public java.util.List buildVolumeClaimTemplates(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildVolumeClaimTemplate(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildFirstVolumeClaimTemplate(); + public java.util.List + getVolumeClaimTemplates(); + + public java.util.List + buildVolumeClaimTemplates(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildVolumeClaimTemplate( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim + buildFirstVolumeClaimTemplate(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildLastVolumeClaimTemplate(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildMatchingVolumeClaimTemplate(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVolumeClaimTemplate(java.util.function.Predicate predicate); - public A withVolumeClaimTemplates(java.util.List volumeClaimTemplates); - public A withVolumeClaimTemplates(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... volumeClaimTemplates); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim + buildMatchingVolumeClaimTemplate( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate); + + public java.lang.Boolean hasMatchingVolumeClaimTemplate( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate); + + public A withVolumeClaimTemplates( + java.util.List + volumeClaimTemplates); + + public A withVolumeClaimTemplates( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... volumeClaimTemplates); + public java.lang.Boolean hasVolumeClaimTemplates(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested addNewVolumeClaimTemplate(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested addNewVolumeClaimTemplateLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested setNewVolumeClaimTemplateLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested editVolumeClaimTemplate(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested editFirstVolumeClaimTemplate(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested editLastVolumeClaimTemplate(); - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested editMatchingVolumeClaimTemplate(java.util.function.Predicate predicate); - public interface PersistentVolumeClaimRetentionPolicyNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent>{ + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + addNewVolumeClaimTemplate(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + addNewVolumeClaimTemplateLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + setNewVolumeClaimTemplateLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + editVolumeClaimTemplate(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + editFirstVolumeClaimTemplate(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + editLastVolumeClaimTemplate(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + editMatchingVolumeClaimTemplate( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate); + + public interface PersistentVolumeClaimRetentionPolicyNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models + .V1StatefulSetPersistentVolumeClaimRetentionPolicyFluent< + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .PersistentVolumeClaimRetentionPolicyNested< + N>> { public N and(); + public N endPersistentVolumeClaimRetentionPolicy(); - } - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested> { public N and(); + public N endSelector(); - } - public interface TemplateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent>{ + + public interface TemplateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodTemplateSpecFluent< + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested> { public N and(); + public N endTemplate(); - } - public interface UpdateStrategyNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent>{ + + public interface UpdateStrategyNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent< + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested> { public N and(); + public N endUpdateStrategy(); - } - public interface VolumeClaimTemplatesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent>{ + + public interface VolumeClaimTemplatesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluent< + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .VolumeClaimTemplatesNested< + N>> { public N and(); + public N endVolumeClaimTemplate(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetSpecFluentImpl.java index 1c332836e7..28a8968555 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetSpecFluentImpl.java @@ -1,29 +1,33 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1StatefulSetSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent{ - public V1StatefulSetSpecFluentImpl() { - } - public V1StatefulSetSpecFluentImpl(io.kubernetes.client.openapi.models.V1StatefulSetSpec instance) { + +/** Generated */ +public class V1StatefulSetSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent { + public V1StatefulSetSpecFluentImpl() {} + + public V1StatefulSetSpecFluentImpl( + io.kubernetes.client.openapi.models.V1StatefulSetSpec instance) { this.withMinReadySeconds(instance.getMinReadySeconds()); - this.withPersistentVolumeClaimRetentionPolicy(instance.getPersistentVolumeClaimRetentionPolicy()); + this.withPersistentVolumeClaimRetentionPolicy( + instance.getPersistentVolumeClaimRetentionPolicy()); this.withPodManagementPolicy(instance.getPodManagementPolicy()); @@ -40,235 +44,467 @@ public V1StatefulSetSpecFluentImpl(io.kubernetes.client.openapi.models.V1Statefu this.withUpdateStrategy(instance.getUpdateStrategy()); this.withVolumeClaimTemplates(instance.getVolumeClaimTemplates()); - } + private java.lang.Integer minReadySeconds; - private io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder persistentVolumeClaimRetentionPolicy; - private io.kubernetes.client.openapi.models.V1StatefulSetSpec.PodManagementPolicyEnum podManagementPolicy; + private io.kubernetes.client.openapi.models + .V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder + persistentVolumeClaimRetentionPolicy; + private io.kubernetes.client.openapi.models.V1StatefulSetSpec.PodManagementPolicyEnum + podManagementPolicy; private java.lang.Integer replicas; private java.lang.Integer revisionHistoryLimit; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder selector; private java.lang.String serviceName; private io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder template; private io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyBuilder updateStrategy; - private java.util.ArrayList volumeClaimTemplates; + private java.util.ArrayList + volumeClaimTemplates; + public java.lang.Integer getMinReadySeconds() { return this.minReadySeconds; } + public A withMinReadySeconds(java.lang.Integer minReadySeconds) { - this.minReadySeconds=minReadySeconds; return (A) this; + this.minReadySeconds = minReadySeconds; + return (A) this; } + public java.lang.Boolean hasMinReadySeconds() { return this.minReadySeconds != null; } - + /** - * This method has been deprecated, please use method buildPersistentVolumeClaimRetentionPolicy instead. + * This method has been deprecated, please use method buildPersistentVolumeClaimRetentionPolicy + * instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy getPersistentVolumeClaimRetentionPolicy() { - return this.persistentVolumeClaimRetentionPolicy!=null ?this.persistentVolumeClaimRetentionPolicy.build():null; + public io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + getPersistentVolumeClaimRetentionPolicy() { + return this.persistentVolumeClaimRetentionPolicy != null + ? this.persistentVolumeClaimRetentionPolicy.build() + : null; } - public io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy buildPersistentVolumeClaimRetentionPolicy() { - return this.persistentVolumeClaimRetentionPolicy!=null ?this.persistentVolumeClaimRetentionPolicy.build():null; + + public io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + buildPersistentVolumeClaimRetentionPolicy() { + return this.persistentVolumeClaimRetentionPolicy != null + ? this.persistentVolumeClaimRetentionPolicy.build() + : null; } - public A withPersistentVolumeClaimRetentionPolicy(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy persistentVolumeClaimRetentionPolicy) { - _visitables.get("persistentVolumeClaimRetentionPolicy").remove(this.persistentVolumeClaimRetentionPolicy); - if (persistentVolumeClaimRetentionPolicy!=null){ this.persistentVolumeClaimRetentionPolicy= new io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder(persistentVolumeClaimRetentionPolicy); _visitables.get("persistentVolumeClaimRetentionPolicy").add(this.persistentVolumeClaimRetentionPolicy);} return (A) this; + + public A withPersistentVolumeClaimRetentionPolicy( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + persistentVolumeClaimRetentionPolicy) { + _visitables + .get("persistentVolumeClaimRetentionPolicy") + .remove(this.persistentVolumeClaimRetentionPolicy); + if (persistentVolumeClaimRetentionPolicy != null) { + this.persistentVolumeClaimRetentionPolicy = + new io.kubernetes.client.openapi.models + .V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder( + persistentVolumeClaimRetentionPolicy); + _visitables + .get("persistentVolumeClaimRetentionPolicy") + .add(this.persistentVolumeClaimRetentionPolicy); + } + return (A) this; } + public java.lang.Boolean hasPersistentVolumeClaimRetentionPolicy() { return this.persistentVolumeClaimRetentionPolicy != null; } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.PersistentVolumeClaimRetentionPolicyNested withNewPersistentVolumeClaimRetentionPolicy() { - return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl.PersistentVolumeClaimRetentionPolicyNestedImpl(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .PersistentVolumeClaimRetentionPolicyNested< + A> + withNewPersistentVolumeClaimRetentionPolicy() { + return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl + .PersistentVolumeClaimRetentionPolicyNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.PersistentVolumeClaimRetentionPolicyNested withNewPersistentVolumeClaimRetentionPolicyLike(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy item) { - return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl.PersistentVolumeClaimRetentionPolicyNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .PersistentVolumeClaimRetentionPolicyNested< + A> + withNewPersistentVolumeClaimRetentionPolicyLike( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + item) { + return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl + .PersistentVolumeClaimRetentionPolicyNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.PersistentVolumeClaimRetentionPolicyNested editPersistentVolumeClaimRetentionPolicy() { - return withNewPersistentVolumeClaimRetentionPolicyLike(getPersistentVolumeClaimRetentionPolicy()); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .PersistentVolumeClaimRetentionPolicyNested< + A> + editPersistentVolumeClaimRetentionPolicy() { + return withNewPersistentVolumeClaimRetentionPolicyLike( + getPersistentVolumeClaimRetentionPolicy()); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.PersistentVolumeClaimRetentionPolicyNested editOrNewPersistentVolumeClaimRetentionPolicy() { - return withNewPersistentVolumeClaimRetentionPolicyLike(getPersistentVolumeClaimRetentionPolicy() != null ? getPersistentVolumeClaimRetentionPolicy(): new io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder().build()); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .PersistentVolumeClaimRetentionPolicyNested< + A> + editOrNewPersistentVolumeClaimRetentionPolicy() { + return withNewPersistentVolumeClaimRetentionPolicyLike( + getPersistentVolumeClaimRetentionPolicy() != null + ? getPersistentVolumeClaimRetentionPolicy() + : new io.kubernetes.client.openapi.models + .V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.PersistentVolumeClaimRetentionPolicyNested editOrNewPersistentVolumeClaimRetentionPolicyLike(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy item) { - return withNewPersistentVolumeClaimRetentionPolicyLike(getPersistentVolumeClaimRetentionPolicy() != null ? getPersistentVolumeClaimRetentionPolicy(): item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .PersistentVolumeClaimRetentionPolicyNested< + A> + editOrNewPersistentVolumeClaimRetentionPolicyLike( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + item) { + return withNewPersistentVolumeClaimRetentionPolicyLike( + getPersistentVolumeClaimRetentionPolicy() != null + ? getPersistentVolumeClaimRetentionPolicy() + : item); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpec.PodManagementPolicyEnum getPodManagementPolicy() { + + public io.kubernetes.client.openapi.models.V1StatefulSetSpec.PodManagementPolicyEnum + getPodManagementPolicy() { return this.podManagementPolicy; } - public A withPodManagementPolicy(io.kubernetes.client.openapi.models.V1StatefulSetSpec.PodManagementPolicyEnum podManagementPolicy) { - this.podManagementPolicy=podManagementPolicy; return (A) this; + + public A withPodManagementPolicy( + io.kubernetes.client.openapi.models.V1StatefulSetSpec.PodManagementPolicyEnum + podManagementPolicy) { + this.podManagementPolicy = podManagementPolicy; + return (A) this; } + public java.lang.Boolean hasPodManagementPolicy() { return this.podManagementPolicy != null; } + public java.lang.Integer getReplicas() { return this.replicas; } + public A withReplicas(java.lang.Integer replicas) { - this.replicas=replicas; return (A) this; + this.replicas = replicas; + return (A) this; } + public java.lang.Boolean hasReplicas() { return this.replicas != null; } + public java.lang.Integer getRevisionHistoryLimit() { return this.revisionHistoryLimit; } + public A withRevisionHistoryLimit(java.lang.Integer revisionHistoryLimit) { - this.revisionHistoryLimit=revisionHistoryLimit; return (A) this; + this.revisionHistoryLimit = revisionHistoryLimit; + return (A) this; } + public java.lang.Boolean hasRevisionHistoryLimit() { return this.revisionHistoryLimit != null; } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested withNewSelector() { + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested + withNewSelector() { return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl.SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl.SelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl.SelectorNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested editSelector() { + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested + editSelector() { return withNewSelectorLike(getSelector()); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested + editOrNewSelector() { + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } + public java.lang.String getServiceName() { return this.serviceName; } + public A withServiceName(java.lang.String serviceName) { - this.serviceName=serviceName; return (A) this; + this.serviceName = serviceName; + return (A) this; } + public java.lang.Boolean hasServiceName() { return this.serviceName != null; } - - /** - * Method is deprecated. use withServiceName instead. - */ + + /** Method is deprecated. use withServiceName instead. */ @java.lang.Deprecated public A withNewServiceName(java.lang.String original) { - return (A)withServiceName(new String(original)); + return (A) withServiceName(new String(original)); } - + /** * This method has been deprecated, please use method buildTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodTemplateSpec getTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public io.kubernetes.client.openapi.models.V1PodTemplateSpec buildTemplate() { - return this.template!=null ?this.template.build():null; + return this.template != null ? this.template.build() : null; } + public A withTemplate(io.kubernetes.client.openapi.models.V1PodTemplateSpec template) { _visitables.get("template").remove(this.template); - if (template!=null){ this.template= new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); _visitables.get("template").add(this.template);} return (A) this; + if (template != null) { + this.template = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(template); + _visitables.get("template").add(this.template); + } + return (A) this; } + public java.lang.Boolean hasTemplate() { return this.template != null; } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested withNewTemplate() { + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested + withNewTemplate() { return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl.TemplateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { - return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl.TemplateNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested + withNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl.TemplateNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested editTemplate() { + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested + editTemplate() { return withNewTemplateLike(getTemplate()); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested editOrNewTemplate() { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested + editOrNewTemplate() { + return withNewTemplateLike( + getTemplate() != null + ? getTemplate() + : new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { - return withNewTemplateLike(getTemplate() != null ? getTemplate(): item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested + editOrNewTemplateLike(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { + return withNewTemplateLike(getTemplate() != null ? getTemplate() : item); } - + /** * This method has been deprecated, please use method buildUpdateStrategy instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy getUpdateStrategy() { - return this.updateStrategy!=null ?this.updateStrategy.build():null; + return this.updateStrategy != null ? this.updateStrategy.build() : null; } + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy buildUpdateStrategy() { - return this.updateStrategy!=null ?this.updateStrategy.build():null; + return this.updateStrategy != null ? this.updateStrategy.build() : null; } - public A withUpdateStrategy(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy updateStrategy) { + + public A withUpdateStrategy( + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy updateStrategy) { _visitables.get("updateStrategy").remove(this.updateStrategy); - if (updateStrategy!=null){ this.updateStrategy= new io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyBuilder(updateStrategy); _visitables.get("updateStrategy").add(this.updateStrategy);} return (A) this; + if (updateStrategy != null) { + this.updateStrategy = + new io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyBuilder( + updateStrategy); + _visitables.get("updateStrategy").add(this.updateStrategy); + } + return (A) this; } + public java.lang.Boolean hasUpdateStrategy() { return this.updateStrategy != null; } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested withNewUpdateStrategy() { - return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl.UpdateStrategyNestedImpl(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested + withNewUpdateStrategy() { + return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl + .UpdateStrategyNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested withNewUpdateStrategyLike(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy item) { - return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl.UpdateStrategyNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested + withNewUpdateStrategyLike( + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy item) { + return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl + .UpdateStrategyNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested editUpdateStrategy() { + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested + editUpdateStrategy() { return withNewUpdateStrategyLike(getUpdateStrategy()); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested editOrNewUpdateStrategy() { - return withNewUpdateStrategyLike(getUpdateStrategy() != null ? getUpdateStrategy(): new io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyBuilder().build()); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested + editOrNewUpdateStrategy() { + return withNewUpdateStrategyLike( + getUpdateStrategy() != null + ? getUpdateStrategy() + : new io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyBuilder().build()); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested editOrNewUpdateStrategyLike(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy item) { - return withNewUpdateStrategyLike(getUpdateStrategy() != null ? getUpdateStrategy(): item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested + editOrNewUpdateStrategyLike( + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy item) { + return withNewUpdateStrategyLike(getUpdateStrategy() != null ? getUpdateStrategy() : item); } - public A addToVolumeClaimTemplates(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { - if (this.volumeClaimTemplates == null) {this.volumeClaimTemplates = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item);_visitables.get("volumeClaimTemplates").add(index >= 0 ? index : _visitables.get("volumeClaimTemplates").size(), builder);this.volumeClaimTemplates.add(index >= 0 ? index : volumeClaimTemplates.size(), builder); return (A)this; + + public A addToVolumeClaimTemplates( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { + if (this.volumeClaimTemplates == null) { + this.volumeClaimTemplates = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder>(); + } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); + _visitables + .get("volumeClaimTemplates") + .add(index >= 0 ? index : _visitables.get("volumeClaimTemplates").size(), builder); + this.volumeClaimTemplates.add(index >= 0 ? index : volumeClaimTemplates.size(), builder); + return (A) this; } - public A setToVolumeClaimTemplates(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { - if (this.volumeClaimTemplates == null) {this.volumeClaimTemplates = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); - if (index < 0 || index >= _visitables.get("volumeClaimTemplates").size()) { _visitables.get("volumeClaimTemplates").add(builder); } else { _visitables.get("volumeClaimTemplates").set(index, builder);} - if (index < 0 || index >= volumeClaimTemplates.size()) { volumeClaimTemplates.add(builder); } else { volumeClaimTemplates.set(index, builder);} - return (A)this; + + public A setToVolumeClaimTemplates( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { + if (this.volumeClaimTemplates == null) { + this.volumeClaimTemplates = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder>(); + } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); + if (index < 0 || index >= _visitables.get("volumeClaimTemplates").size()) { + _visitables.get("volumeClaimTemplates").add(builder); + } else { + _visitables.get("volumeClaimTemplates").set(index, builder); + } + if (index < 0 || index >= volumeClaimTemplates.size()) { + volumeClaimTemplates.add(builder); + } else { + volumeClaimTemplates.set(index, builder); + } + return (A) this; } - public A addToVolumeClaimTemplates(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items) { - if (this.volumeClaimTemplates == null) {this.volumeClaimTemplates = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item);_visitables.get("volumeClaimTemplates").add(builder);this.volumeClaimTemplates.add(builder);} return (A)this; + + public A addToVolumeClaimTemplates( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items) { + if (this.volumeClaimTemplates == null) { + this.volumeClaimTemplates = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); + _visitables.get("volumeClaimTemplates").add(builder); + this.volumeClaimTemplates.add(builder); + } + return (A) this; } - public A addAllToVolumeClaimTemplates(java.util.Collection items) { - if (this.volumeClaimTemplates == null) {this.volumeClaimTemplates = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item);_visitables.get("volumeClaimTemplates").add(builder);this.volumeClaimTemplates.add(builder);} return (A)this; + + public A addAllToVolumeClaimTemplates( + java.util.Collection items) { + if (this.volumeClaimTemplates == null) { + this.volumeClaimTemplates = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); + _visitables.get("volumeClaimTemplates").add(builder); + this.volumeClaimTemplates.add(builder); + } + return (A) this; } - public A removeFromVolumeClaimTemplates(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item);_visitables.get("volumeClaimTemplates").remove(builder);if (this.volumeClaimTemplates != null) {this.volumeClaimTemplates.remove(builder);}} return (A)this; + + public A removeFromVolumeClaimTemplates( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... items) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); + _visitables.get("volumeClaimTemplates").remove(builder); + if (this.volumeClaimTemplates != null) { + this.volumeClaimTemplates.remove(builder); + } + } + return (A) this; } - public A removeAllFromVolumeClaimTemplates(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) {io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item);_visitables.get("volumeClaimTemplates").remove(builder);if (this.volumeClaimTemplates != null) {this.volumeClaimTemplates.remove(builder);}} return (A)this; + + public A removeAllFromVolumeClaimTemplates( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : items) { + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(item); + _visitables.get("volumeClaimTemplates").remove(builder); + if (this.volumeClaimTemplates != null) { + this.volumeClaimTemplates.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromVolumeClaimTemplates(java.util.function.Predicate predicate) { + + public A removeMatchingFromVolumeClaimTemplates( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate) { if (volumeClaimTemplates == null) return (A) this; - final Iterator each = volumeClaimTemplates.iterator(); + final Iterator each = + volumeClaimTemplates.iterator(); final List visitables = _visitables.get("volumeClaimTemplates"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder = each.next(); @@ -277,177 +513,349 @@ public A removeMatchingFromVolumeClaimTemplates(java.util.function.Predicate getVolumeClaimTemplates() { + public java.util.List + getVolumeClaimTemplates() { return volumeClaimTemplates != null ? build(volumeClaimTemplates) : null; } - public java.util.List buildVolumeClaimTemplates() { + + public java.util.List + buildVolumeClaimTemplates() { return volumeClaimTemplates != null ? build(volumeClaimTemplates) : null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildVolumeClaimTemplate(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildVolumeClaimTemplate( + java.lang.Integer index) { return this.volumeClaimTemplates.get(index).build(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildFirstVolumeClaimTemplate() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim + buildFirstVolumeClaimTemplate() { return this.volumeClaimTemplates.get(0).build(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildLastVolumeClaimTemplate() { + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim + buildLastVolumeClaimTemplate() { return this.volumeClaimTemplates.get(volumeClaimTemplates.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim buildMatchingVolumeClaimTemplate(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder item: volumeClaimTemplates) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaim + buildMatchingVolumeClaimTemplate( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder item : + volumeClaimTemplates) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingVolumeClaimTemplate(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder item: volumeClaimTemplates) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVolumeClaimTemplate( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder item : + volumeClaimTemplates) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withVolumeClaimTemplates(java.util.List volumeClaimTemplates) { - if (this.volumeClaimTemplates != null) { _visitables.get("volumeClaimTemplates").removeAll(this.volumeClaimTemplates);} - if (volumeClaimTemplates != null) {this.volumeClaimTemplates = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : volumeClaimTemplates){this.addToVolumeClaimTemplates(item);}} else { this.volumeClaimTemplates = null;} return (A) this; + + public A withVolumeClaimTemplates( + java.util.List + volumeClaimTemplates) { + if (this.volumeClaimTemplates != null) { + _visitables.get("volumeClaimTemplates").removeAll(this.volumeClaimTemplates); + } + if (volumeClaimTemplates != null) { + this.volumeClaimTemplates = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : + volumeClaimTemplates) { + this.addToVolumeClaimTemplates(item); + } + } else { + this.volumeClaimTemplates = null; + } + return (A) this; } - public A withVolumeClaimTemplates(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... volumeClaimTemplates) { - if (this.volumeClaimTemplates != null) {this.volumeClaimTemplates.clear();} - if (volumeClaimTemplates != null) {for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item :volumeClaimTemplates){ this.addToVolumeClaimTemplates(item);}} return (A) this; + + public A withVolumeClaimTemplates( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim... volumeClaimTemplates) { + if (this.volumeClaimTemplates != null) { + this.volumeClaimTemplates.clear(); + } + if (volumeClaimTemplates != null) { + for (io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item : + volumeClaimTemplates) { + this.addToVolumeClaimTemplates(item); + } + } + return (A) this; } + public java.lang.Boolean hasVolumeClaimTemplates() { return volumeClaimTemplates != null && !volumeClaimTemplates.isEmpty(); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested addNewVolumeClaimTemplate() { - return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl.VolumeClaimTemplatesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + addNewVolumeClaimTemplate() { + return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl + .VolumeClaimTemplatesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested addNewVolumeClaimTemplateLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { - return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl.VolumeClaimTemplatesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + addNewVolumeClaimTemplateLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { + return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl + .VolumeClaimTemplatesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested setNewVolumeClaimTemplateLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { - return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl.VolumeClaimTemplatesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + setNewVolumeClaimTemplateLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { + return new io.kubernetes.client.openapi.models.V1StatefulSetSpecFluentImpl + .VolumeClaimTemplatesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested editVolumeClaimTemplate(java.lang.Integer index) { - if (volumeClaimTemplates.size() <= index) throw new RuntimeException("Can't edit volumeClaimTemplates. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + editVolumeClaimTemplate(java.lang.Integer index) { + if (volumeClaimTemplates.size() <= index) + throw new RuntimeException("Can't edit volumeClaimTemplates. Index exceeds size."); return setNewVolumeClaimTemplateLike(index, buildVolumeClaimTemplate(index)); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested editFirstVolumeClaimTemplate() { - if (volumeClaimTemplates.size() == 0) throw new RuntimeException("Can't edit first volumeClaimTemplates. The list is empty."); + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + editFirstVolumeClaimTemplate() { + if (volumeClaimTemplates.size() == 0) + throw new RuntimeException("Can't edit first volumeClaimTemplates. The list is empty."); return setNewVolumeClaimTemplateLike(0, buildVolumeClaimTemplate(0)); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested editLastVolumeClaimTemplate() { + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + editLastVolumeClaimTemplate() { int index = volumeClaimTemplates.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last volumeClaimTemplates. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last volumeClaimTemplates. The list is empty."); return setNewVolumeClaimTemplateLike(index, buildVolumeClaimTemplate(index)); } - public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested editMatchingVolumeClaimTemplate(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested + editMatchingVolumeClaimTemplate( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl> implements io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.PersistentVolumeClaimRetentionPolicyNested,io.kubernetes.client.fluent.Nested{ - PersistentVolumeClaimRetentionPolicyNestedImpl(io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy item) { - this.builder = new io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder(this, item); + + public class PersistentVolumeClaimRetentionPolicyNestedImpl + extends io.kubernetes.client.openapi.models + .V1StatefulSetPersistentVolumeClaimRetentionPolicyFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .PersistentVolumeClaimRetentionPolicyNested< + N>> + implements io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .PersistentVolumeClaimRetentionPolicyNested< + N>, + io.kubernetes.client.fluent.Nested { + PersistentVolumeClaimRetentionPolicyNestedImpl( + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicy + item) { + this.builder = + new io.kubernetes.client.openapi.models + .V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder(this, item); } + PersistentVolumeClaimRetentionPolicyNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models + .V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder(this); } - io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder builder; + + io.kubernetes.client.openapi.models.V1StatefulSetPersistentVolumeClaimRetentionPolicyBuilder + builder; + public N and() { - return (N) V1StatefulSetSpecFluentImpl.this.withPersistentVolumeClaimRetentionPolicy(builder.build()); + return (N) + V1StatefulSetSpecFluentImpl.this.withPersistentVolumeClaimRetentionPolicy( + builder.build()); } + public N endPersistentVolumeClaimRetentionPolicy() { return and(); } - } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested> + implements io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.SelectorNested, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1StatefulSetSpecFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - public class TemplateNestedImpl extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested,io.kubernetes.client.fluent.Nested{ + + public class TemplateNestedImpl + extends io.kubernetes.client.openapi.models.V1PodTemplateSpecFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested> + implements io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.TemplateNested, + io.kubernetes.client.fluent.Nested { TemplateNestedImpl(io.kubernetes.client.openapi.models.V1PodTemplateSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this, item); } + TemplateNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PodTemplateSpecBuilder builder; + public N and() { return (N) V1StatefulSetSpecFluentImpl.this.withTemplate(builder.build()); } + public N endTemplate() { return and(); } - } - public class UpdateStrategyNestedImpl extends io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluentImpl> implements io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested,io.kubernetes.client.fluent.Nested{ + + public class UpdateStrategyNestedImpl + extends io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested> + implements io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.UpdateStrategyNested< + N>, + io.kubernetes.client.fluent.Nested { UpdateStrategyNestedImpl(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy item) { - this.builder = new io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyBuilder(this, item); } + UpdateStrategyNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyBuilder(this); } + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyBuilder builder; + public N and() { return (N) V1StatefulSetSpecFluentImpl.this.withUpdateStrategy(builder.build()); } + public N endUpdateStrategy() { return and(); } - } - public class VolumeClaimTemplatesNestedImpl extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl> implements io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested,io.kubernetes.client.fluent.Nested{ - VolumeClaimTemplatesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { + + public class VolumeClaimTemplatesNestedImpl + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent.VolumeClaimTemplatesNested> + implements io.kubernetes.client.openapi.models.V1StatefulSetSpecFluent + .VolumeClaimTemplatesNested< + N>, + io.kubernetes.client.fluent.Nested { + VolumeClaimTemplatesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1PersistentVolumeClaim item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(this, item); } + VolumeClaimTemplatesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder(this); } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1StatefulSetSpecFluentImpl.this.setToVolumeClaimTemplates(index,builder.build()); + return (N) V1StatefulSetSpecFluentImpl.this.setToVolumeClaimTemplates(index, builder.build()); } + public N endVolumeClaimTemplate() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetStatusBuilder.java index 634cd78e40..b406407db3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StatefulSetStatusBuilder extends io.kubernetes.client.openapi.models.V1StatefulSetStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StatefulSetStatusBuilder + extends io.kubernetes.client.openapi.models.V1StatefulSetStatusFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1StatefulSetStatus, + io.kubernetes.client.openapi.models.V1StatefulSetStatusBuilder> { public V1StatefulSetStatusBuilder() { this(false); } + public V1StatefulSetStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1StatefulSetStatus(), validationEnabled); } - public V1StatefulSetStatusBuilder(io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent fluent) { + + public V1StatefulSetStatusBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent fluent) { this(fluent, false); } - public V1StatefulSetStatusBuilder(io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StatefulSetStatusBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1StatefulSetStatus(), validationEnabled); } - public V1StatefulSetStatusBuilder(io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSetStatus instance) { + + public V1StatefulSetStatusBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent fluent, + io.kubernetes.client.openapi.models.V1StatefulSetStatus instance) { this(fluent, instance, false); } - public V1StatefulSetStatusBuilder(io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSetStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StatefulSetStatusBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent fluent, + io.kubernetes.client.openapi.models.V1StatefulSetStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAvailableReplicas(instance.getAvailableReplicas()); fluent.withCollisionCount(instance.getCollisionCount()); @@ -41,13 +68,18 @@ public V1StatefulSetStatusBuilder(io.kubernetes.client.openapi.models.V1Stateful fluent.withUpdatedReplicas(instance.getUpdatedReplicas()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1StatefulSetStatusBuilder(io.kubernetes.client.openapi.models.V1StatefulSetStatus instance) { - this(instance,false); + + public V1StatefulSetStatusBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetStatus instance) { + this(instance, false); } - public V1StatefulSetStatusBuilder(io.kubernetes.client.openapi.models.V1StatefulSetStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StatefulSetStatusBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAvailableReplicas(instance.getAvailableReplicas()); this.withCollisionCount(instance.getCollisionCount()); @@ -68,10 +100,12 @@ public V1StatefulSetStatusBuilder(io.kubernetes.client.openapi.models.V1Stateful this.withUpdatedReplicas(instance.getUpdatedReplicas()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1StatefulSetStatus build() { V1StatefulSetStatus buildable = new V1StatefulSetStatus(); buildable.setAvailableReplicas(fluent.getAvailableReplicas()); @@ -86,18 +120,23 @@ public io.kubernetes.client.openapi.models.V1StatefulSetStatus build() { buildable.setUpdatedReplicas(fluent.getUpdatedReplicas()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1StatefulSetStatusBuilder that = (V1StatefulSetStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetStatusFluent.java index 689eb6dd1d..b0bbb9ed4b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetStatusFluent.java @@ -1,97 +1,171 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Long; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1StatefulSetStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1StatefulSetStatusFluent< + A extends io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getAvailableReplicas(); + public A withAvailableReplicas(java.lang.Integer availableReplicas); + public java.lang.Boolean hasAvailableReplicas(); + public java.lang.Integer getCollisionCount(); + public A withCollisionCount(java.lang.Integer collisionCount); + public java.lang.Boolean hasCollisionCount(); - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSetCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSetCondition item); + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatefulSetCondition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatefulSetCondition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1StatefulSetCondition... items); - public A addAllToConditions(java.util.Collection items); - public A removeFromConditions(io.kubernetes.client.openapi.models.V1StatefulSetCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A addAllToConditions( + java.util.Collection items); + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1StatefulSetCondition... items); + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder> + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1StatefulSetCondition buildCondition(java.lang.Integer index); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V1StatefulSetCondition buildCondition( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1StatefulSetCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1StatefulSetCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1StatefulSetCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); + + public io.kubernetes.client.openapi.models.V1StatefulSetCondition buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder> + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder> + predicate); + + public A withConditions( + java.util.List conditions); + public A withConditions(io.kubernetes.client.openapi.models.V1StatefulSetCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1StatefulSetCondition item); - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSetCondition item); - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1StatefulSetCondition item); + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatefulSetCondition item); + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder> + predicate); + public java.lang.Integer getCurrentReplicas(); + public A withCurrentReplicas(java.lang.Integer currentReplicas); + public java.lang.Boolean hasCurrentReplicas(); + public java.lang.String getCurrentRevision(); + public A withCurrentRevision(java.lang.String currentRevision); + public java.lang.Boolean hasCurrentRevision(); - - /** - * Method is deprecated. use withCurrentRevision instead. - */ + + /** Method is deprecated. use withCurrentRevision instead. */ @java.lang.Deprecated public A withNewCurrentRevision(java.lang.String original); + public java.lang.Long getObservedGeneration(); + public A withObservedGeneration(java.lang.Long observedGeneration); + public java.lang.Boolean hasObservedGeneration(); + public java.lang.Integer getReadyReplicas(); + public A withReadyReplicas(java.lang.Integer readyReplicas); + public java.lang.Boolean hasReadyReplicas(); + public java.lang.Integer getReplicas(); + public A withReplicas(java.lang.Integer replicas); + public java.lang.Boolean hasReplicas(); + public java.lang.String getUpdateRevision(); + public A withUpdateRevision(java.lang.String updateRevision); + public java.lang.Boolean hasUpdateRevision(); - - /** - * Method is deprecated. use withUpdateRevision instead. - */ + + /** Method is deprecated. use withUpdateRevision instead. */ @java.lang.Deprecated public A withNewUpdateRevision(java.lang.String original); + public java.lang.Integer getUpdatedReplicas(); + public A withUpdatedReplicas(java.lang.Integer updatedReplicas); + public java.lang.Boolean hasUpdatedReplicas(); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1StatefulSetConditionFluent< + io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetStatusFluentImpl.java index 1daa2d3037..92a5ab9e10 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetStatusFluentImpl.java @@ -1,27 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1StatefulSetStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent{ - public V1StatefulSetStatusFluentImpl() { - } - public V1StatefulSetStatusFluentImpl(io.kubernetes.client.openapi.models.V1StatefulSetStatus instance) { +/** Generated */ +public class V1StatefulSetStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent { + public V1StatefulSetStatusFluentImpl() {} + + public V1StatefulSetStatusFluentImpl( + io.kubernetes.client.openapi.models.V1StatefulSetStatus instance) { this.withAvailableReplicas(instance.getAvailableReplicas()); this.withCollisionCount(instance.getCollisionCount()); @@ -41,11 +43,12 @@ public V1StatefulSetStatusFluentImpl(io.kubernetes.client.openapi.models.V1State this.withUpdateRevision(instance.getUpdateRevision()); this.withUpdatedReplicas(instance.getUpdatedReplicas()); - } + private java.lang.Integer availableReplicas; private java.lang.Integer collisionCount; - private java.util.ArrayList conditions; + private java.util.ArrayList + conditions; private java.lang.Integer currentReplicas; private java.lang.String currentRevision; private java.lang.Long observedGeneration; @@ -53,52 +56,135 @@ public V1StatefulSetStatusFluentImpl(io.kubernetes.client.openapi.models.V1State private java.lang.Integer replicas; private java.lang.String updateRevision; private java.lang.Integer updatedReplicas; + public java.lang.Integer getAvailableReplicas() { return this.availableReplicas; } + public A withAvailableReplicas(java.lang.Integer availableReplicas) { - this.availableReplicas=availableReplicas; return (A) this; + this.availableReplicas = availableReplicas; + return (A) this; } + public java.lang.Boolean hasAvailableReplicas() { return this.availableReplicas != null; } + public java.lang.Integer getCollisionCount() { return this.collisionCount; } + public A withCollisionCount(java.lang.Integer collisionCount) { - this.collisionCount=collisionCount; return (A) this; + this.collisionCount = collisionCount; + return (A) this; } + public java.lang.Boolean hasCollisionCount() { return this.collisionCount != null; } - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSetCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatefulSetCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSetCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatefulSetCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } + public A addToConditions(io.kubernetes.client.openapi.models.V1StatefulSetCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1StatefulSetCondition item : items) {io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1StatefulSetCondition item : items) { + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1StatefulSetCondition item : items) {io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1StatefulSetCondition item : items) { + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V1StatefulSetCondition... items) { - for (io.kubernetes.client.openapi.models.V1StatefulSetCondition item : items) {io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1StatefulSetCondition... items) { + for (io.kubernetes.client.openapi.models.V1StatefulSetCondition item : items) { + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1StatefulSetCondition item : items) {io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder = new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1StatefulSetCondition item : items) { + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder> + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder = each.next(); @@ -107,192 +193,330 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { + public java.util.List + getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1StatefulSetCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1StatefulSetCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1StatefulSetCondition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1StatefulSetCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1StatefulSetCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1StatefulSetCondition buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1StatefulSetCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1StatefulSetCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } - public A withConditions(io.kubernetes.client.openapi.models.V1StatefulSetCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1StatefulSetCondition item :conditions){ this.addToConditions(item);}} return (A) this; + + public A withConditions( + io.kubernetes.client.openapi.models.V1StatefulSetCondition... conditions) { + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1StatefulSetCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1StatefulSetStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1StatefulSetStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1StatefulSetCondition item) { - return new io.kubernetes.client.openapi.models.V1StatefulSetStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1StatefulSetCondition item) { + return new io.kubernetes.client.openapi.models.V1StatefulSetStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSetCondition item) { - return new io.kubernetes.client.openapi.models.V1StatefulSetStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1StatefulSetCondition item) { + return new io.kubernetes.client.openapi.models.V1StatefulSetStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1StatefulSetConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatefulSetCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1StatefulSetConditionFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1StatefulSetStatusFluent.ConditionsNested, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatefulSetCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1StatefulSetConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1StatefulSetStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1StatefulSetStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetUpdateStrategyBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetUpdateStrategyBuilder.java index b9a5ac3bb1..9fa1627b56 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetUpdateStrategyBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetUpdateStrategyBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StatefulSetUpdateStrategyBuilder extends io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StatefulSetUpdateStrategyBuilder + extends io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy, + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyBuilder> { public V1StatefulSetUpdateStrategyBuilder() { this(false); } + public V1StatefulSetUpdateStrategyBuilder(java.lang.Boolean validationEnabled) { this(new V1StatefulSetUpdateStrategy(), validationEnabled); } - public V1StatefulSetUpdateStrategyBuilder(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent fluent) { + + public V1StatefulSetUpdateStrategyBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent fluent) { this(fluent, false); } - public V1StatefulSetUpdateStrategyBuilder(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StatefulSetUpdateStrategyBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1StatefulSetUpdateStrategy(), validationEnabled); } - public V1StatefulSetUpdateStrategyBuilder(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy instance) { + + public V1StatefulSetUpdateStrategyBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent fluent, + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy instance) { this(fluent, instance, false); } - public V1StatefulSetUpdateStrategyBuilder(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent fluent,io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StatefulSetUpdateStrategyBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent fluent, + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withRollingUpdate(instance.getRollingUpdate()); fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1StatefulSetUpdateStrategyBuilder(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy instance) { - this(instance,false); + + public V1StatefulSetUpdateStrategyBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy instance) { + this(instance, false); } - public V1StatefulSetUpdateStrategyBuilder(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StatefulSetUpdateStrategyBuilder( + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withRollingUpdate(instance.getRollingUpdate()); this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy build() { V1StatefulSetUpdateStrategy buildable = new V1StatefulSetUpdateStrategy(); buildable.setRollingUpdate(fluent.getRollingUpdate()); buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1StatefulSetUpdateStrategyBuilder that = (V1StatefulSetUpdateStrategyBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetUpdateStrategyFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetUpdateStrategyFluent.java index f909e4927a..343b9351cb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetUpdateStrategyFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetUpdateStrategyFluent.java @@ -1,38 +1,74 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1StatefulSetUpdateStrategyFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1StatefulSetUpdateStrategyFluent< + A extends io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildRollingUpdate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy getRollingUpdate(); - public io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy buildRollingUpdate(); - public A withRollingUpdate(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy rollingUpdate); + + public io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy + buildRollingUpdate(); + + public A withRollingUpdate( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy rollingUpdate); + public java.lang.Boolean hasRollingUpdate(); - public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested withNewRollingUpdate(); - public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested withNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy item); - public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested editRollingUpdate(); - public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested editOrNewRollingUpdate(); - public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested editOrNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy item); + + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested< + A> + withNewRollingUpdate(); + + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested< + A> + withNewRollingUpdateLike( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy item); + + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested< + A> + editRollingUpdate(); + + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested< + A> + editOrNewRollingUpdate(); + + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested< + A> + editOrNewRollingUpdateLike( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy item); + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy.TypeEnum getType(); + public A withType(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy.TypeEnum type); + public java.lang.Boolean hasType(); - public interface RollingUpdateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent>{ + + public interface RollingUpdateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluent< + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent + .RollingUpdateNested< + N>> { public N and(); + public N endRollingUpdate(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetUpdateStrategyFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetUpdateStrategyFluentImpl.java index de3d8505cd..f5f377be63 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetUpdateStrategyFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatefulSetUpdateStrategyFluentImpl.java @@ -1,94 +1,160 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1StatefulSetUpdateStrategyFluentImpl< + A extends io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent { + public V1StatefulSetUpdateStrategyFluentImpl() {} - /** - * Generated - */ -public class V1StatefulSetUpdateStrategyFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent{ - public V1StatefulSetUpdateStrategyFluentImpl() { - } - public V1StatefulSetUpdateStrategyFluentImpl(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy instance) { + public V1StatefulSetUpdateStrategyFluentImpl( + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy instance) { this.withRollingUpdate(instance.getRollingUpdate()); this.withType(instance.getType()); - } - private io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyBuilder rollingUpdate; + + private io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyBuilder + rollingUpdate; private io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy.TypeEnum type; - + /** * This method has been deprecated, please use method buildRollingUpdate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy getRollingUpdate() { - return this.rollingUpdate!=null ?this.rollingUpdate.build():null; + return this.rollingUpdate != null ? this.rollingUpdate.build() : null; } - public io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy buildRollingUpdate() { - return this.rollingUpdate!=null ?this.rollingUpdate.build():null; + + public io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy + buildRollingUpdate() { + return this.rollingUpdate != null ? this.rollingUpdate.build() : null; } - public A withRollingUpdate(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy rollingUpdate) { + + public A withRollingUpdate( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy rollingUpdate) { _visitables.get("rollingUpdate").remove(this.rollingUpdate); - if (rollingUpdate!=null){ this.rollingUpdate= new io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyBuilder(rollingUpdate); _visitables.get("rollingUpdate").add(this.rollingUpdate);} return (A) this; + if (rollingUpdate != null) { + this.rollingUpdate = + new io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyBuilder( + rollingUpdate); + _visitables.get("rollingUpdate").add(this.rollingUpdate); + } + return (A) this; } + public java.lang.Boolean hasRollingUpdate() { return this.rollingUpdate != null; } - public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested withNewRollingUpdate() { - return new io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluentImpl.RollingUpdateNestedImpl(); + + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested< + A> + withNewRollingUpdate() { + return new io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluentImpl + .RollingUpdateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested withNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy item) { - return new io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluentImpl.RollingUpdateNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested< + A> + withNewRollingUpdateLike( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy item) { + return new io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluentImpl + .RollingUpdateNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested editRollingUpdate() { + + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested< + A> + editRollingUpdate() { return withNewRollingUpdateLike(getRollingUpdate()); } - public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested editOrNewRollingUpdate() { - return withNewRollingUpdateLike(getRollingUpdate() != null ? getRollingUpdate(): new io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyBuilder().build()); + + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested< + A> + editOrNewRollingUpdate() { + return withNewRollingUpdateLike( + getRollingUpdate() != null + ? getRollingUpdate() + : new io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested editOrNewRollingUpdateLike(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy item) { - return withNewRollingUpdateLike(getRollingUpdate() != null ? getRollingUpdate(): item); + + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested< + A> + editOrNewRollingUpdateLike( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy item) { + return withNewRollingUpdateLike(getRollingUpdate() != null ? getRollingUpdate() : item); } + public io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy.TypeEnum getType() { return this.type; } + public A withType(io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategy.TypeEnum type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1StatefulSetUpdateStrategyFluentImpl that = (V1StatefulSetUpdateStrategyFluentImpl) o; - if (rollingUpdate != null ? !rollingUpdate.equals(that.rollingUpdate) :that.rollingUpdate != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (rollingUpdate != null + ? !rollingUpdate.equals(that.rollingUpdate) + : that.rollingUpdate != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(rollingUpdate, type, super.hashCode()); + return java.util.Objects.hash(rollingUpdate, type, super.hashCode()); } - public class RollingUpdateNestedImpl extends io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluentImpl> implements io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested,io.kubernetes.client.fluent.Nested{ - RollingUpdateNestedImpl(io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy item) { - this.builder = new io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyBuilder(this, item); + + public class RollingUpdateNestedImpl + extends io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyFluentImpl< + io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent.RollingUpdateNested< + N>> + implements io.kubernetes.client.openapi.models.V1StatefulSetUpdateStrategyFluent + .RollingUpdateNested< + N>, + io.kubernetes.client.fluent.Nested { + RollingUpdateNestedImpl( + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategy item) { + this.builder = + new io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyBuilder( + this, item); } + RollingUpdateNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyBuilder(this); } + io.kubernetes.client.openapi.models.V1RollingUpdateStatefulSetStrategyBuilder builder; + public N and() { return (N) V1StatefulSetUpdateStrategyFluentImpl.this.withRollingUpdate(builder.build()); } + public N endRollingUpdate() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusBuilder.java index 693815fcbb..1f0b9a1c61 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StatusBuilder extends io.kubernetes.client.openapi.models.V1StatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StatusBuilder + extends io.kubernetes.client.openapi.models.V1StatusFluentImpl< + io.kubernetes.client.openapi.models.V1StatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Status, + io.kubernetes.client.openapi.models.V1StatusBuilder> { public V1StatusBuilder() { this(false); } + public V1StatusBuilder(java.lang.Boolean validationEnabled) { this(new V1Status(), validationEnabled); } + public V1StatusBuilder(io.kubernetes.client.openapi.models.V1StatusFluent fluent) { this(fluent, false); } - public V1StatusBuilder(io.kubernetes.client.openapi.models.V1StatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StatusBuilder( + io.kubernetes.client.openapi.models.V1StatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Status(), validationEnabled); } - public V1StatusBuilder(io.kubernetes.client.openapi.models.V1StatusFluent fluent,io.kubernetes.client.openapi.models.V1Status instance) { + + public V1StatusBuilder( + io.kubernetes.client.openapi.models.V1StatusFluent fluent, + io.kubernetes.client.openapi.models.V1Status instance) { this(fluent, instance, false); } - public V1StatusBuilder(io.kubernetes.client.openapi.models.V1StatusFluent fluent,io.kubernetes.client.openapi.models.V1Status instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StatusBuilder( + io.kubernetes.client.openapi.models.V1StatusFluent fluent, + io.kubernetes.client.openapi.models.V1Status instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withCode(instance.getCode()); @@ -37,13 +63,16 @@ public V1StatusBuilder(io.kubernetes.client.openapi.models.V1StatusFluent flu fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1StatusBuilder(io.kubernetes.client.openapi.models.V1Status instance) { - this(instance,false); + this(instance, false); } - public V1StatusBuilder(io.kubernetes.client.openapi.models.V1Status instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StatusBuilder( + io.kubernetes.client.openapi.models.V1Status instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withCode(instance.getCode()); @@ -60,10 +89,12 @@ public V1StatusBuilder(io.kubernetes.client.openapi.models.V1Status instance,jav this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1StatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Status build() { V1Status buildable = new V1Status(); buildable.setApiVersion(fluent.getApiVersion()); @@ -76,18 +107,23 @@ public io.kubernetes.client.openapi.models.V1Status build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1StatusBuilder that = (V1StatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusCauseBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusCauseBuilder.java index 837b2c1586..51754aee4a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusCauseBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusCauseBuilder.java @@ -1,49 +1,81 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StatusCauseBuilder extends io.kubernetes.client.openapi.models.V1StatusCauseFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StatusCauseBuilder + extends io.kubernetes.client.openapi.models.V1StatusCauseFluentImpl< + io.kubernetes.client.openapi.models.V1StatusCauseBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1StatusCause, + io.kubernetes.client.openapi.models.V1StatusCauseBuilder> { public V1StatusCauseBuilder() { this(false); } + public V1StatusCauseBuilder(java.lang.Boolean validationEnabled) { this(new V1StatusCause(), validationEnabled); } + public V1StatusCauseBuilder(io.kubernetes.client.openapi.models.V1StatusCauseFluent fluent) { this(fluent, false); } - public V1StatusCauseBuilder(io.kubernetes.client.openapi.models.V1StatusCauseFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StatusCauseBuilder( + io.kubernetes.client.openapi.models.V1StatusCauseFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1StatusCause(), validationEnabled); } - public V1StatusCauseBuilder(io.kubernetes.client.openapi.models.V1StatusCauseFluent fluent,io.kubernetes.client.openapi.models.V1StatusCause instance) { + + public V1StatusCauseBuilder( + io.kubernetes.client.openapi.models.V1StatusCauseFluent fluent, + io.kubernetes.client.openapi.models.V1StatusCause instance) { this(fluent, instance, false); } - public V1StatusCauseBuilder(io.kubernetes.client.openapi.models.V1StatusCauseFluent fluent,io.kubernetes.client.openapi.models.V1StatusCause instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StatusCauseBuilder( + io.kubernetes.client.openapi.models.V1StatusCauseFluent fluent, + io.kubernetes.client.openapi.models.V1StatusCause instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withField(instance.getField()); fluent.withMessage(instance.getMessage()); fluent.withReason(instance.getReason()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1StatusCauseBuilder(io.kubernetes.client.openapi.models.V1StatusCause instance) { - this(instance,false); + this(instance, false); } - public V1StatusCauseBuilder(io.kubernetes.client.openapi.models.V1StatusCause instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StatusCauseBuilder( + io.kubernetes.client.openapi.models.V1StatusCause instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withField(instance.getField()); this.withMessage(instance.getMessage()); this.withReason(instance.getReason()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1StatusCauseFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1StatusCause build() { V1StatusCause buildable = new V1StatusCause(); buildable.setField(fluent.getField()); @@ -51,18 +83,23 @@ public io.kubernetes.client.openapi.models.V1StatusCause build() { buildable.setReason(fluent.getReason()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1StatusCauseBuilder that = (V1StatusCauseBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusCauseFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusCauseFluent.java index 112d350089..798b17024b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusCauseFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusCauseFluent.java @@ -1,41 +1,48 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1StatusCauseFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1StatusCauseFluent< + A extends io.kubernetes.client.openapi.models.V1StatusCauseFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getField(); + public A withField(java.lang.String field); + public java.lang.Boolean hasField(); - - /** - * Method is deprecated. use withField instead. - */ + + /** Method is deprecated. use withField instead. */ @java.lang.Deprecated public A withNewField(java.lang.String original); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusCauseFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusCauseFluentImpl.java index 5a1e2083fc..fd26238896 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusCauseFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusCauseFluentImpl.java @@ -1,90 +1,104 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1StatusCauseFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StatusCauseFluent{ - public V1StatusCauseFluentImpl() { - } +/** Generated */ +public class V1StatusCauseFluentImpl< + A extends io.kubernetes.client.openapi.models.V1StatusCauseFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1StatusCauseFluent { + public V1StatusCauseFluentImpl() {} + public V1StatusCauseFluentImpl(io.kubernetes.client.openapi.models.V1StatusCause instance) { this.withField(instance.getField()); this.withMessage(instance.getMessage()); this.withReason(instance.getReason()); - } + private java.lang.String field; private java.lang.String message; private java.lang.String reason; + public java.lang.String getField() { return this.field; } + public A withField(java.lang.String field) { - this.field=field; return (A) this; + this.field = field; + return (A) this; } + public java.lang.Boolean hasField() { return this.field != null; } - - /** - * Method is deprecated. use withField instead. - */ + + /** Method is deprecated. use withField instead. */ @java.lang.Deprecated public A withNewField(java.lang.String original) { - return (A)withField(new String(original)); + return (A) withField(new String(original)); } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1StatusCauseFluentImpl that = (V1StatusCauseFluentImpl) o; - if (field != null ? !field.equals(that.field) :that.field != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; + if (field != null ? !field.equals(that.field) : that.field != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(field, message, reason, super.hashCode()); + return java.util.Objects.hash(field, message, reason, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusDetailsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusDetailsBuilder.java index 66e20bc414..f8467630b2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusDetailsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusDetailsBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StatusDetailsBuilder extends io.kubernetes.client.openapi.models.V1StatusDetailsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StatusDetailsBuilder + extends io.kubernetes.client.openapi.models.V1StatusDetailsFluentImpl< + io.kubernetes.client.openapi.models.V1StatusDetailsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1StatusDetails, + io.kubernetes.client.openapi.models.V1StatusDetailsBuilder> { public V1StatusDetailsBuilder() { this(false); } + public V1StatusDetailsBuilder(java.lang.Boolean validationEnabled) { this(new V1StatusDetails(), validationEnabled); } - public V1StatusDetailsBuilder(io.kubernetes.client.openapi.models.V1StatusDetailsFluent fluent) { + + public V1StatusDetailsBuilder( + io.kubernetes.client.openapi.models.V1StatusDetailsFluent fluent) { this(fluent, false); } - public V1StatusDetailsBuilder(io.kubernetes.client.openapi.models.V1StatusDetailsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StatusDetailsBuilder( + io.kubernetes.client.openapi.models.V1StatusDetailsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1StatusDetails(), validationEnabled); } - public V1StatusDetailsBuilder(io.kubernetes.client.openapi.models.V1StatusDetailsFluent fluent,io.kubernetes.client.openapi.models.V1StatusDetails instance) { + + public V1StatusDetailsBuilder( + io.kubernetes.client.openapi.models.V1StatusDetailsFluent fluent, + io.kubernetes.client.openapi.models.V1StatusDetails instance) { this(fluent, instance, false); } - public V1StatusDetailsBuilder(io.kubernetes.client.openapi.models.V1StatusDetailsFluent fluent,io.kubernetes.client.openapi.models.V1StatusDetails instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StatusDetailsBuilder( + io.kubernetes.client.openapi.models.V1StatusDetailsFluent fluent, + io.kubernetes.client.openapi.models.V1StatusDetails instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCauses(instance.getCauses()); fluent.withGroup(instance.getGroup()); @@ -33,13 +60,17 @@ public V1StatusDetailsBuilder(io.kubernetes.client.openapi.models.V1StatusDetail fluent.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1StatusDetailsBuilder(io.kubernetes.client.openapi.models.V1StatusDetails instance) { - this(instance,false); + this(instance, false); } - public V1StatusDetailsBuilder(io.kubernetes.client.openapi.models.V1StatusDetails instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StatusDetailsBuilder( + io.kubernetes.client.openapi.models.V1StatusDetails instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCauses(instance.getCauses()); this.withGroup(instance.getGroup()); @@ -52,10 +83,12 @@ public V1StatusDetailsBuilder(io.kubernetes.client.openapi.models.V1StatusDetail this.withUid(instance.getUid()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1StatusDetailsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1StatusDetails build() { V1StatusDetails buildable = new V1StatusDetails(); buildable.setCauses(fluent.getCauses()); @@ -66,18 +99,23 @@ public io.kubernetes.client.openapi.models.V1StatusDetails build() { buildable.setUid(fluent.getUid()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1StatusDetailsBuilder that = (V1StatusDetailsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusDetailsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusDetailsFluent.java index 3e025a5825..9d440814eb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusDetailsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusDetailsFluent.java @@ -1,96 +1,143 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1StatusDetailsFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToCauses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatusCause item); - public A setToCauses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatusCause item); +/** Generated */ +public interface V1StatusDetailsFluent< + A extends io.kubernetes.client.openapi.models.V1StatusDetailsFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToCauses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatusCause item); + + public A setToCauses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatusCause item); + public A addToCauses(io.kubernetes.client.openapi.models.V1StatusCause... items); - public A addAllToCauses(java.util.Collection items); + + public A addAllToCauses( + java.util.Collection items); + public A removeFromCauses(io.kubernetes.client.openapi.models.V1StatusCause... items); - public A removeAllFromCauses(java.util.Collection items); - public A removeMatchingFromCauses(java.util.function.Predicate predicate); - + + public A removeAllFromCauses( + java.util.Collection items); + + public A removeMatchingFromCauses( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildCauses instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getCauses(); + public java.util.List buildCauses(); + public io.kubernetes.client.openapi.models.V1StatusCause buildCause(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1StatusCause buildFirstCause(); + public io.kubernetes.client.openapi.models.V1StatusCause buildLastCause(); - public io.kubernetes.client.openapi.models.V1StatusCause buildMatchingCause(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCause(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1StatusCause buildMatchingCause( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCause( + java.util.function.Predicate + predicate); + public A withCauses(java.util.List causes); + public A withCauses(io.kubernetes.client.openapi.models.V1StatusCause... causes); + public java.lang.Boolean hasCauses(); + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested addNewCause(); - public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested addNewCauseLike(io.kubernetes.client.openapi.models.V1StatusCause item); - public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested setNewCauseLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatusCause item); - public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested editCause(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested addNewCauseLike( + io.kubernetes.client.openapi.models.V1StatusCause item); + + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested setNewCauseLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatusCause item); + + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested editCause( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested editFirstCause(); + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested editLastCause(); - public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested editMatchingCause(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested + editMatchingCause( + java.util.function.Predicate + predicate); + public java.lang.String getGroup(); + public A withGroup(java.lang.String group); + public java.lang.Boolean hasGroup(); - - /** - * Method is deprecated. use withGroup instead. - */ + + /** Method is deprecated. use withGroup instead. */ @java.lang.Deprecated public A withNewGroup(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Integer getRetryAfterSeconds(); + public A withRetryAfterSeconds(java.lang.Integer retryAfterSeconds); + public java.lang.Boolean hasRetryAfterSeconds(); + public java.lang.String getUid(); + public A withUid(java.lang.String uid); + public java.lang.Boolean hasUid(); - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original); - public interface CausesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1StatusCauseFluent>{ + + public interface CausesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1StatusCauseFluent< + io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested> { public N and(); + public N endCause(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusDetailsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusDetailsFluentImpl.java index c1888425c0..845d492460 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusDetailsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusDetailsFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1StatusDetailsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StatusDetailsFluent{ - public V1StatusDetailsFluentImpl() { - } +/** Generated */ +public class V1StatusDetailsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1StatusDetailsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1StatusDetailsFluent { + public V1StatusDetailsFluentImpl() {} + public V1StatusDetailsFluentImpl(io.kubernetes.client.openapi.models.V1StatusDetails instance) { this.withCauses(instance.getCauses()); @@ -32,42 +34,109 @@ public V1StatusDetailsFluentImpl(io.kubernetes.client.openapi.models.V1StatusDet this.withRetryAfterSeconds(instance.getRetryAfterSeconds()); this.withUid(instance.getUid()); - } + private java.util.ArrayList causes; private java.lang.String group; private java.lang.String kind; private java.lang.String name; private java.lang.Integer retryAfterSeconds; private java.lang.String uid; - public A addToCauses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatusCause item) { - if (this.causes == null) {this.causes = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder = new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(item);_visitables.get("causes").add(index >= 0 ? index : _visitables.get("causes").size(), builder);this.causes.add(index >= 0 ? index : causes.size(), builder); return (A)this; + + public A addToCauses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatusCause item) { + if (this.causes == null) { + this.causes = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder = + new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(item); + _visitables.get("causes").add(index >= 0 ? index : _visitables.get("causes").size(), builder); + this.causes.add(index >= 0 ? index : causes.size(), builder); + return (A) this; } - public A setToCauses(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatusCause item) { - if (this.causes == null) {this.causes = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder = new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(item); - if (index < 0 || index >= _visitables.get("causes").size()) { _visitables.get("causes").add(builder); } else { _visitables.get("causes").set(index, builder);} - if (index < 0 || index >= causes.size()) { causes.add(builder); } else { causes.set(index, builder);} - return (A)this; + + public A setToCauses( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatusCause item) { + if (this.causes == null) { + this.causes = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder = + new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(item); + if (index < 0 || index >= _visitables.get("causes").size()) { + _visitables.get("causes").add(builder); + } else { + _visitables.get("causes").set(index, builder); + } + if (index < 0 || index >= causes.size()) { + causes.add(builder); + } else { + causes.set(index, builder); + } + return (A) this; } + public A addToCauses(io.kubernetes.client.openapi.models.V1StatusCause... items) { - if (this.causes == null) {this.causes = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1StatusCause item : items) {io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder = new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(item);_visitables.get("causes").add(builder);this.causes.add(builder);} return (A)this; + if (this.causes == null) { + this.causes = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1StatusCause item : items) { + io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder = + new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(item); + _visitables.get("causes").add(builder); + this.causes.add(builder); + } + return (A) this; } - public A addAllToCauses(java.util.Collection items) { - if (this.causes == null) {this.causes = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1StatusCause item : items) {io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder = new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(item);_visitables.get("causes").add(builder);this.causes.add(builder);} return (A)this; + + public A addAllToCauses( + java.util.Collection items) { + if (this.causes == null) { + this.causes = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1StatusCause item : items) { + io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder = + new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(item); + _visitables.get("causes").add(builder); + this.causes.add(builder); + } + return (A) this; } + public A removeFromCauses(io.kubernetes.client.openapi.models.V1StatusCause... items) { - for (io.kubernetes.client.openapi.models.V1StatusCause item : items) {io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder = new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(item);_visitables.get("causes").remove(builder);if (this.causes != null) {this.causes.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1StatusCause item : items) { + io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder = + new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(item); + _visitables.get("causes").remove(builder); + if (this.causes != null) { + this.causes.remove(builder); + } + } + return (A) this; } - public A removeAllFromCauses(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1StatusCause item : items) {io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder = new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(item);_visitables.get("causes").remove(builder);if (this.causes != null) {this.causes.remove(builder);}} return (A)this; + + public A removeAllFromCauses( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1StatusCause item : items) { + io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder = + new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(item); + _visitables.get("causes").remove(builder); + if (this.causes != null) { + this.causes.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromCauses(java.util.function.Predicate predicate) { + + public A removeMatchingFromCauses( + java.util.function.Predicate + predicate) { if (causes == null) return (A) this; - final Iterator each = causes.iterator(); + final Iterator each = + causes.iterator(); final List visitables = _visitables.get("causes"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder = each.next(); @@ -76,186 +145,273 @@ public A removeMatchingFromCauses(java.util.function.Predicate getCauses() { return causes != null ? build(causes) : null; } + public java.util.List buildCauses() { return causes != null ? build(causes) : null; } + public io.kubernetes.client.openapi.models.V1StatusCause buildCause(java.lang.Integer index) { return this.causes.get(index).build(); } + public io.kubernetes.client.openapi.models.V1StatusCause buildFirstCause() { return this.causes.get(0).build(); } + public io.kubernetes.client.openapi.models.V1StatusCause buildLastCause() { return this.causes.get(causes.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1StatusCause buildMatchingCause(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1StatusCauseBuilder item: causes) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1StatusCause buildMatchingCause( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1StatusCauseBuilder item : causes) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCause(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1StatusCauseBuilder item: causes) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCause( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1StatusCauseBuilder item : causes) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withCauses(java.util.List causes) { - if (this.causes != null) { _visitables.get("causes").removeAll(this.causes);} - if (causes != null) {this.causes = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1StatusCause item : causes){this.addToCauses(item);}} else { this.causes = null;} return (A) this; + if (this.causes != null) { + _visitables.get("causes").removeAll(this.causes); + } + if (causes != null) { + this.causes = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1StatusCause item : causes) { + this.addToCauses(item); + } + } else { + this.causes = null; + } + return (A) this; } + public A withCauses(io.kubernetes.client.openapi.models.V1StatusCause... causes) { - if (this.causes != null) {this.causes.clear();} - if (causes != null) {for (io.kubernetes.client.openapi.models.V1StatusCause item :causes){ this.addToCauses(item);}} return (A) this; + if (this.causes != null) { + this.causes.clear(); + } + if (causes != null) { + for (io.kubernetes.client.openapi.models.V1StatusCause item : causes) { + this.addToCauses(item); + } + } + return (A) this; } + public java.lang.Boolean hasCauses() { return causes != null && !causes.isEmpty(); } + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested addNewCause() { return new io.kubernetes.client.openapi.models.V1StatusDetailsFluentImpl.CausesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested addNewCauseLike(io.kubernetes.client.openapi.models.V1StatusCause item) { - return new io.kubernetes.client.openapi.models.V1StatusDetailsFluentImpl.CausesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested addNewCauseLike( + io.kubernetes.client.openapi.models.V1StatusCause item) { + return new io.kubernetes.client.openapi.models.V1StatusDetailsFluentImpl.CausesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested setNewCauseLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatusCause item) { - return new io.kubernetes.client.openapi.models.V1StatusDetailsFluentImpl.CausesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested setNewCauseLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatusCause item) { + return new io.kubernetes.client.openapi.models.V1StatusDetailsFluentImpl.CausesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested editCause(java.lang.Integer index) { - if (causes.size() <= index) throw new RuntimeException("Can't edit causes. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested editCause( + java.lang.Integer index) { + if (causes.size() <= index) + throw new RuntimeException("Can't edit causes. Index exceeds size."); return setNewCauseLike(index, buildCause(index)); } - public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested editFirstCause() { - if (causes.size() == 0) throw new RuntimeException("Can't edit first causes. The list is empty."); + + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested + editFirstCause() { + if (causes.size() == 0) + throw new RuntimeException("Can't edit first causes. The list is empty."); return setNewCauseLike(0, buildCause(0)); } + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested editLastCause() { int index = causes.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last causes. The list is empty."); return setNewCauseLike(index, buildCause(index)); } - public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested editMatchingCause(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested + editMatchingCause( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1StatusCauseFluentImpl> implements io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested,io.kubernetes.client.fluent.Nested{ - CausesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StatusCause item) { + + public class CausesNestedImpl + extends io.kubernetes.client.openapi.models.V1StatusCauseFluentImpl< + io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested> + implements io.kubernetes.client.openapi.models.V1StatusDetailsFluent.CausesNested, + io.kubernetes.client.fluent.Nested { + CausesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StatusCause item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(this, item); } + CausesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1StatusCauseBuilder(this); } + io.kubernetes.client.openapi.models.V1StatusCauseBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1StatusDetailsFluentImpl.this.setToCauses(index,builder.build()); + return (N) V1StatusDetailsFluentImpl.this.setToCauses(index, builder.build()); } + public N endCause() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusFluent.java index da55ddc8b0..b533e110b8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusFluent.java @@ -1,104 +1,143 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1StatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1StatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.Integer getCode(); + public A withCode(java.lang.Integer code); + public java.lang.Boolean hasCode(); - + /** * This method has been deprecated, please use method buildDetails instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1StatusDetails getDetails(); + public io.kubernetes.client.openapi.models.V1StatusDetails buildDetails(); + public A withDetails(io.kubernetes.client.openapi.models.V1StatusDetails details); + public java.lang.Boolean hasDetails(); + public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested withNewDetails(); - public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested withNewDetailsLike(io.kubernetes.client.openapi.models.V1StatusDetails item); + + public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested withNewDetailsLike( + io.kubernetes.client.openapi.models.V1StatusDetails item); + public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested editDetails(); + public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested editOrNewDetails(); - public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested editOrNewDetailsLike(io.kubernetes.client.openapi.models.V1StatusDetails item); + + public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested editOrNewDetailsLike( + io.kubernetes.client.openapi.models.V1StatusDetails item); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ListMeta item); + public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested editMetadata(); + public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ListMeta item); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); - public interface DetailsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1StatusDetailsFluent>{ + + public interface DetailsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1StatusDetailsFluent< + io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested> { public N and(); + public N endDetails(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusFluentImpl.java index 7e44c30d51..08d0888673 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StatusFluentImpl.java @@ -1,19 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1StatusFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1StatusFluent { + public V1StatusFluentImpl() {} - /** - * Generated - */ -public class V1StatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StatusFluent{ - public V1StatusFluentImpl() { - } public V1StatusFluentImpl(io.kubernetes.client.openapi.models.V1Status instance) { this.withApiVersion(instance.getApiVersion()); @@ -30,8 +34,8 @@ public V1StatusFluentImpl(io.kubernetes.client.openapi.models.V1Status instance) this.withReason(instance.getReason()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.Integer code; private io.kubernetes.client.openapi.models.V1StatusDetailsBuilder details; @@ -40,216 +44,285 @@ public V1StatusFluentImpl(io.kubernetes.client.openapi.models.V1Status instance) private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; private java.lang.String reason; private java.lang.String status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.Integer getCode() { return this.code; } + public A withCode(java.lang.Integer code) { - this.code=code; return (A) this; + this.code = code; + return (A) this; } + public java.lang.Boolean hasCode() { return this.code != null; } - + /** * This method has been deprecated, please use method buildDetails instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1StatusDetails getDetails() { - return this.details!=null ?this.details.build():null; + return this.details != null ? this.details.build() : null; } + public io.kubernetes.client.openapi.models.V1StatusDetails buildDetails() { - return this.details!=null ?this.details.build():null; + return this.details != null ? this.details.build() : null; } + public A withDetails(io.kubernetes.client.openapi.models.V1StatusDetails details) { _visitables.get("details").remove(this.details); - if (details!=null){ this.details= new io.kubernetes.client.openapi.models.V1StatusDetailsBuilder(details); _visitables.get("details").add(this.details);} return (A) this; + if (details != null) { + this.details = new io.kubernetes.client.openapi.models.V1StatusDetailsBuilder(details); + _visitables.get("details").add(this.details); + } + return (A) this; } + public java.lang.Boolean hasDetails() { return this.details != null; } + public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested withNewDetails() { return new io.kubernetes.client.openapi.models.V1StatusFluentImpl.DetailsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested withNewDetailsLike(io.kubernetes.client.openapi.models.V1StatusDetails item) { + + public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested withNewDetailsLike( + io.kubernetes.client.openapi.models.V1StatusDetails item) { return new io.kubernetes.client.openapi.models.V1StatusFluentImpl.DetailsNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested editDetails() { return withNewDetailsLike(getDetails()); } + public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested editOrNewDetails() { - return withNewDetailsLike(getDetails() != null ? getDetails(): new io.kubernetes.client.openapi.models.V1StatusDetailsBuilder().build()); + return withNewDetailsLike( + getDetails() != null + ? getDetails() + : new io.kubernetes.client.openapi.models.V1StatusDetailsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested editOrNewDetailsLike(io.kubernetes.client.openapi.models.V1StatusDetails item) { - return withNewDetailsLike(getDetails() != null ? getDetails(): item); + + public io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested editOrNewDetailsLike( + io.kubernetes.client.openapi.models.V1StatusDetails item) { + return withNewDetailsLike(getDetails() != null ? getDetails() : item); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ListMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } + public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested withNewMetadata() { return new io.kubernetes.client.openapi.models.V1StatusFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + + public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested withNewMetadataLike( + io.kubernetes.client.openapi.models.V1ListMeta item) { return new io.kubernetes.client.openapi.models.V1StatusFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } + public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested editOrNewMetadataLike( + io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1StatusFluentImpl that = (V1StatusFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (code != null ? !code.equals(that.code) :that.code != null) return false; - if (details != null ? !details.equals(that.details) :that.details != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (code != null ? !code.equals(that.code) : that.code != null) return false; + if (details != null ? !details.equals(that.details) : that.details != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, code, details, kind, message, metadata, reason, status, super.hashCode()); + return java.util.Objects.hash( + apiVersion, code, details, kind, message, metadata, reason, status, super.hashCode()); } - public class DetailsNestedImpl extends io.kubernetes.client.openapi.models.V1StatusDetailsFluentImpl> implements io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested,io.kubernetes.client.fluent.Nested{ + + public class DetailsNestedImpl + extends io.kubernetes.client.openapi.models.V1StatusDetailsFluentImpl< + io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested> + implements io.kubernetes.client.openapi.models.V1StatusFluent.DetailsNested, + io.kubernetes.client.fluent.Nested { DetailsNestedImpl(io.kubernetes.client.openapi.models.V1StatusDetails item) { this.builder = new io.kubernetes.client.openapi.models.V1StatusDetailsBuilder(this, item); } + DetailsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1StatusDetailsBuilder(this); } + io.kubernetes.client.openapi.models.V1StatusDetailsBuilder builder; + public N and() { return (N) V1StatusFluentImpl.this.withDetails(builder.build()); } + public N endDetails() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1StatusFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1StatusFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassBuilder.java index 5763db95c6..d114cd9d93 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StorageClassBuilder extends io.kubernetes.client.openapi.models.V1StorageClassFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StorageClassBuilder + extends io.kubernetes.client.openapi.models.V1StorageClassFluentImpl< + io.kubernetes.client.openapi.models.V1StorageClassBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1StorageClass, + io.kubernetes.client.openapi.models.V1StorageClassBuilder> { public V1StorageClassBuilder() { this(false); } + public V1StorageClassBuilder(java.lang.Boolean validationEnabled) { this(new V1StorageClass(), validationEnabled); } + public V1StorageClassBuilder(io.kubernetes.client.openapi.models.V1StorageClassFluent fluent) { this(fluent, false); } - public V1StorageClassBuilder(io.kubernetes.client.openapi.models.V1StorageClassFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StorageClassBuilder( + io.kubernetes.client.openapi.models.V1StorageClassFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1StorageClass(), validationEnabled); } - public V1StorageClassBuilder(io.kubernetes.client.openapi.models.V1StorageClassFluent fluent,io.kubernetes.client.openapi.models.V1StorageClass instance) { + + public V1StorageClassBuilder( + io.kubernetes.client.openapi.models.V1StorageClassFluent fluent, + io.kubernetes.client.openapi.models.V1StorageClass instance) { this(fluent, instance, false); } - public V1StorageClassBuilder(io.kubernetes.client.openapi.models.V1StorageClassFluent fluent,io.kubernetes.client.openapi.models.V1StorageClass instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StorageClassBuilder( + io.kubernetes.client.openapi.models.V1StorageClassFluent fluent, + io.kubernetes.client.openapi.models.V1StorageClass instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAllowVolumeExpansion(instance.getAllowVolumeExpansion()); fluent.withAllowedTopologies(instance.getAllowedTopologies()); @@ -41,13 +67,17 @@ public V1StorageClassBuilder(io.kubernetes.client.openapi.models.V1StorageClassF fluent.withVolumeBindingMode(instance.getVolumeBindingMode()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1StorageClassBuilder(io.kubernetes.client.openapi.models.V1StorageClass instance) { - this(instance,false); + this(instance, false); } - public V1StorageClassBuilder(io.kubernetes.client.openapi.models.V1StorageClass instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StorageClassBuilder( + io.kubernetes.client.openapi.models.V1StorageClass instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAllowVolumeExpansion(instance.getAllowVolumeExpansion()); this.withAllowedTopologies(instance.getAllowedTopologies()); @@ -68,10 +98,12 @@ public V1StorageClassBuilder(io.kubernetes.client.openapi.models.V1StorageClass this.withVolumeBindingMode(instance.getVolumeBindingMode()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1StorageClassFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1StorageClass build() { V1StorageClass buildable = new V1StorageClass(); buildable.setAllowVolumeExpansion(fluent.getAllowVolumeExpansion()); @@ -86,18 +118,23 @@ public io.kubernetes.client.openapi.models.V1StorageClass build() { buildable.setVolumeBindingMode(fluent.getVolumeBindingMode()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1StorageClassBuilder that = (V1StorageClassBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassFluent.java index 92c6e70fc1..457fef8846 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassFluent.java @@ -1,150 +1,253 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; -import java.util.Map; - - /** - * Generated - */ -public interface V1StorageClassFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1StorageClassFluent< + A extends io.kubernetes.client.openapi.models.V1StorageClassFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Boolean getAllowVolumeExpansion(); + public A withAllowVolumeExpansion(java.lang.Boolean allowVolumeExpansion); + public java.lang.Boolean hasAllowVolumeExpansion(); - public A addToAllowedTopologies(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorTerm item); - public A setToAllowedTopologies(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorTerm item); - public A addToAllowedTopologies(io.kubernetes.client.openapi.models.V1TopologySelectorTerm... items); - public A addAllToAllowedTopologies(java.util.Collection items); - public A removeFromAllowedTopologies(io.kubernetes.client.openapi.models.V1TopologySelectorTerm... items); - public A removeAllFromAllowedTopologies(java.util.Collection items); - public A removeMatchingFromAllowedTopologies(java.util.function.Predicate predicate); - + + public A addToAllowedTopologies( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1TopologySelectorTerm item); + + public A setToAllowedTopologies( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1TopologySelectorTerm item); + + public A addToAllowedTopologies( + io.kubernetes.client.openapi.models.V1TopologySelectorTerm... items); + + public A addAllToAllowedTopologies( + java.util.Collection items); + + public A removeFromAllowedTopologies( + io.kubernetes.client.openapi.models.V1TopologySelectorTerm... items); + + public A removeAllFromAllowedTopologies( + java.util.Collection items); + + public A removeMatchingFromAllowedTopologies( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder> + predicate); + /** * This method has been deprecated, please use method buildAllowedTopologies instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getAllowedTopologies(); - public java.util.List buildAllowedTopologies(); - public io.kubernetes.client.openapi.models.V1TopologySelectorTerm buildAllowedTopology(java.lang.Integer index); + public java.util.List + getAllowedTopologies(); + + public java.util.List + buildAllowedTopologies(); + + public io.kubernetes.client.openapi.models.V1TopologySelectorTerm buildAllowedTopology( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1TopologySelectorTerm buildFirstAllowedTopology(); + public io.kubernetes.client.openapi.models.V1TopologySelectorTerm buildLastAllowedTopology(); - public io.kubernetes.client.openapi.models.V1TopologySelectorTerm buildMatchingAllowedTopology(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAllowedTopology(java.util.function.Predicate predicate); - public A withAllowedTopologies(java.util.List allowedTopologies); - public A withAllowedTopologies(io.kubernetes.client.openapi.models.V1TopologySelectorTerm... allowedTopologies); + + public io.kubernetes.client.openapi.models.V1TopologySelectorTerm buildMatchingAllowedTopology( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder> + predicate); + + public java.lang.Boolean hasMatchingAllowedTopology( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder> + predicate); + + public A withAllowedTopologies( + java.util.List allowedTopologies); + + public A withAllowedTopologies( + io.kubernetes.client.openapi.models.V1TopologySelectorTerm... allowedTopologies); + public java.lang.Boolean hasAllowedTopologies(); - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested addNewAllowedTopology(); - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested addNewAllowedTopologyLike(io.kubernetes.client.openapi.models.V1TopologySelectorTerm item); - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested setNewAllowedTopologyLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorTerm item); - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested editAllowedTopology(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested editFirstAllowedTopology(); - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested editLastAllowedTopology(); - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested editMatchingAllowedTopology(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + addNewAllowedTopology(); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + addNewAllowedTopologyLike(io.kubernetes.client.openapi.models.V1TopologySelectorTerm item); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + setNewAllowedTopologyLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1TopologySelectorTerm item); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + editAllowedTopology(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + editFirstAllowedTopology(); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + editLastAllowedTopology(); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + editMatchingAllowedTopology( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder> + predicate); + public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public A addToMountOptions(java.lang.Integer index,java.lang.String item); - public A setToMountOptions(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public A addToMountOptions(java.lang.Integer index, java.lang.String item); + + public A setToMountOptions(java.lang.Integer index, java.lang.String item); + public A addToMountOptions(java.lang.String... items); + public A addAllToMountOptions(java.util.Collection items); + public A removeFromMountOptions(java.lang.String... items); + public A removeAllFromMountOptions(java.util.Collection items); + public java.util.List getMountOptions(); + public java.lang.String getMountOption(java.lang.Integer index); + public java.lang.String getFirstMountOption(); + public java.lang.String getLastMountOption(); - public java.lang.String getMatchingMountOption(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMountOption(java.util.function.Predicate predicate); + + public java.lang.String getMatchingMountOption( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingMountOption( + java.util.function.Predicate predicate); + public A withMountOptions(java.util.List mountOptions); + public A withMountOptions(java.lang.String... mountOptions); + public java.lang.Boolean hasMountOptions(); + public A addNewMountOption(java.lang.String original); - public A addToParameters(java.lang.String key,java.lang.String value); - public A addToParameters(java.util.Map map); + + public A addToParameters(java.lang.String key, java.lang.String value); + + public A addToParameters(java.util.Map map); + public A removeFromParameters(java.lang.String key); - public A removeFromParameters(java.util.Map map); - public java.util.Map getParameters(); - public A withParameters(java.util.Map parameters); + + public A removeFromParameters(java.util.Map map); + + public java.util.Map getParameters(); + + public A withParameters(java.util.Map parameters); + public java.lang.Boolean hasParameters(); + public java.lang.String getProvisioner(); + public A withProvisioner(java.lang.String provisioner); + public java.lang.Boolean hasProvisioner(); - - /** - * Method is deprecated. use withProvisioner instead. - */ + + /** Method is deprecated. use withProvisioner instead. */ @java.lang.Deprecated public A withNewProvisioner(java.lang.String original); + public java.lang.String getReclaimPolicy(); + public A withReclaimPolicy(java.lang.String reclaimPolicy); + public java.lang.Boolean hasReclaimPolicy(); - - /** - * Method is deprecated. use withReclaimPolicy instead. - */ + + /** Method is deprecated. use withReclaimPolicy instead. */ @java.lang.Deprecated public A withNewReclaimPolicy(java.lang.String original); + public java.lang.String getVolumeBindingMode(); + public A withVolumeBindingMode(java.lang.String volumeBindingMode); + public java.lang.Boolean hasVolumeBindingMode(); - - /** - * Method is deprecated. use withVolumeBindingMode instead. - */ + + /** Method is deprecated. use withVolumeBindingMode instead. */ @java.lang.Deprecated public A withNewVolumeBindingMode(java.lang.String original); - public interface AllowedTopologiesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent>{ + + public interface AllowedTopologiesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent< + io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested> { public N and(); + public N endAllowedTopology(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassFluentImpl.java index 752f141255..e92346ae66 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassFluentImpl.java @@ -1,27 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; -import java.util.Map; - - /** - * Generated - */ -public class V1StorageClassFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StorageClassFluent{ - public V1StorageClassFluentImpl() { - } + +/** Generated */ +public class V1StorageClassFluentImpl< + A extends io.kubernetes.client.openapi.models.V1StorageClassFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1StorageClassFluent { + public V1StorageClassFluentImpl() {} + public V1StorageClassFluentImpl(io.kubernetes.client.openapi.models.V1StorageClass instance) { this.withAllowVolumeExpansion(instance.getAllowVolumeExpansion()); @@ -42,55 +42,136 @@ public V1StorageClassFluentImpl(io.kubernetes.client.openapi.models.V1StorageCla this.withReclaimPolicy(instance.getReclaimPolicy()); this.withVolumeBindingMode(instance.getVolumeBindingMode()); - } + private java.lang.Boolean allowVolumeExpansion; - private java.util.ArrayList allowedTopologies; + private java.util.ArrayList + allowedTopologies; private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private java.util.List mountOptions; - private java.util.Map parameters; + private java.util.Map parameters; private java.lang.String provisioner; private java.lang.String reclaimPolicy; private java.lang.String volumeBindingMode; + public java.lang.Boolean getAllowVolumeExpansion() { return this.allowVolumeExpansion; } + public A withAllowVolumeExpansion(java.lang.Boolean allowVolumeExpansion) { - this.allowVolumeExpansion=allowVolumeExpansion; return (A) this; + this.allowVolumeExpansion = allowVolumeExpansion; + return (A) this; } + public java.lang.Boolean hasAllowVolumeExpansion() { return this.allowVolumeExpansion != null; } - public A addToAllowedTopologies(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorTerm item) { - if (this.allowedTopologies == null) {this.allowedTopologies = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(item);_visitables.get("allowedTopologies").add(index >= 0 ? index : _visitables.get("allowedTopologies").size(), builder);this.allowedTopologies.add(index >= 0 ? index : allowedTopologies.size(), builder); return (A)this; + + public A addToAllowedTopologies( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1TopologySelectorTerm item) { + if (this.allowedTopologies == null) { + this.allowedTopologies = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder>(); + } + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(item); + _visitables + .get("allowedTopologies") + .add(index >= 0 ? index : _visitables.get("allowedTopologies").size(), builder); + this.allowedTopologies.add(index >= 0 ? index : allowedTopologies.size(), builder); + return (A) this; } - public A setToAllowedTopologies(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorTerm item) { - if (this.allowedTopologies == null) {this.allowedTopologies = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(item); - if (index < 0 || index >= _visitables.get("allowedTopologies").size()) { _visitables.get("allowedTopologies").add(builder); } else { _visitables.get("allowedTopologies").set(index, builder);} - if (index < 0 || index >= allowedTopologies.size()) { allowedTopologies.add(builder); } else { allowedTopologies.set(index, builder);} - return (A)this; + + public A setToAllowedTopologies( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1TopologySelectorTerm item) { + if (this.allowedTopologies == null) { + this.allowedTopologies = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder>(); + } + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(item); + if (index < 0 || index >= _visitables.get("allowedTopologies").size()) { + _visitables.get("allowedTopologies").add(builder); + } else { + _visitables.get("allowedTopologies").set(index, builder); + } + if (index < 0 || index >= allowedTopologies.size()) { + allowedTopologies.add(builder); + } else { + allowedTopologies.set(index, builder); + } + return (A) this; } - public A addToAllowedTopologies(io.kubernetes.client.openapi.models.V1TopologySelectorTerm... items) { - if (this.allowedTopologies == null) {this.allowedTopologies = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1TopologySelectorTerm item : items) {io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(item);_visitables.get("allowedTopologies").add(builder);this.allowedTopologies.add(builder);} return (A)this; + + public A addToAllowedTopologies( + io.kubernetes.client.openapi.models.V1TopologySelectorTerm... items) { + if (this.allowedTopologies == null) { + this.allowedTopologies = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1TopologySelectorTerm item : items) { + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(item); + _visitables.get("allowedTopologies").add(builder); + this.allowedTopologies.add(builder); + } + return (A) this; } - public A addAllToAllowedTopologies(java.util.Collection items) { - if (this.allowedTopologies == null) {this.allowedTopologies = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1TopologySelectorTerm item : items) {io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(item);_visitables.get("allowedTopologies").add(builder);this.allowedTopologies.add(builder);} return (A)this; + + public A addAllToAllowedTopologies( + java.util.Collection items) { + if (this.allowedTopologies == null) { + this.allowedTopologies = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1TopologySelectorTerm item : items) { + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(item); + _visitables.get("allowedTopologies").add(builder); + this.allowedTopologies.add(builder); + } + return (A) this; } - public A removeFromAllowedTopologies(io.kubernetes.client.openapi.models.V1TopologySelectorTerm... items) { - for (io.kubernetes.client.openapi.models.V1TopologySelectorTerm item : items) {io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(item);_visitables.get("allowedTopologies").remove(builder);if (this.allowedTopologies != null) {this.allowedTopologies.remove(builder);}} return (A)this; + + public A removeFromAllowedTopologies( + io.kubernetes.client.openapi.models.V1TopologySelectorTerm... items) { + for (io.kubernetes.client.openapi.models.V1TopologySelectorTerm item : items) { + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(item); + _visitables.get("allowedTopologies").remove(builder); + if (this.allowedTopologies != null) { + this.allowedTopologies.remove(builder); + } + } + return (A) this; } - public A removeAllFromAllowedTopologies(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1TopologySelectorTerm item : items) {io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(item);_visitables.get("allowedTopologies").remove(builder);if (this.allowedTopologies != null) {this.allowedTopologies.remove(builder);}} return (A)this; + + public A removeAllFromAllowedTopologies( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1TopologySelectorTerm item : items) { + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(item); + _visitables.get("allowedTopologies").remove(builder); + if (this.allowedTopologies != null) { + this.allowedTopologies.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromAllowedTopologies(java.util.function.Predicate predicate) { + + public A removeMatchingFromAllowedTopologies( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder> + predicate) { if (allowedTopologies == null) return (A) this; - final Iterator each = allowedTopologies.iterator(); + final Iterator each = + allowedTopologies.iterator(); final List visitables = _visitables.get("allowedTopologies"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder = each.next(); @@ -99,327 +180,585 @@ public A removeMatchingFromAllowedTopologies(java.util.function.Predicate getAllowedTopologies() { + public java.util.List + getAllowedTopologies() { return allowedTopologies != null ? build(allowedTopologies) : null; } - public java.util.List buildAllowedTopologies() { + + public java.util.List + buildAllowedTopologies() { return allowedTopologies != null ? build(allowedTopologies) : null; } - public io.kubernetes.client.openapi.models.V1TopologySelectorTerm buildAllowedTopology(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1TopologySelectorTerm buildAllowedTopology( + java.lang.Integer index) { return this.allowedTopologies.get(index).build(); } + public io.kubernetes.client.openapi.models.V1TopologySelectorTerm buildFirstAllowedTopology() { return this.allowedTopologies.get(0).build(); } + public io.kubernetes.client.openapi.models.V1TopologySelectorTerm buildLastAllowedTopology() { return this.allowedTopologies.get(allowedTopologies.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1TopologySelectorTerm buildMatchingAllowedTopology(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder item: allowedTopologies) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1TopologySelectorTerm buildMatchingAllowedTopology( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder item : + allowedTopologies) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingAllowedTopology(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder item: allowedTopologies) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAllowedTopology( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder item : + allowedTopologies) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withAllowedTopologies(java.util.List allowedTopologies) { - if (this.allowedTopologies != null) { _visitables.get("allowedTopologies").removeAll(this.allowedTopologies);} - if (allowedTopologies != null) {this.allowedTopologies = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1TopologySelectorTerm item : allowedTopologies){this.addToAllowedTopologies(item);}} else { this.allowedTopologies = null;} return (A) this; + + public A withAllowedTopologies( + java.util.List + allowedTopologies) { + if (this.allowedTopologies != null) { + _visitables.get("allowedTopologies").removeAll(this.allowedTopologies); + } + if (allowedTopologies != null) { + this.allowedTopologies = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1TopologySelectorTerm item : allowedTopologies) { + this.addToAllowedTopologies(item); + } + } else { + this.allowedTopologies = null; + } + return (A) this; } - public A withAllowedTopologies(io.kubernetes.client.openapi.models.V1TopologySelectorTerm... allowedTopologies) { - if (this.allowedTopologies != null) {this.allowedTopologies.clear();} - if (allowedTopologies != null) {for (io.kubernetes.client.openapi.models.V1TopologySelectorTerm item :allowedTopologies){ this.addToAllowedTopologies(item);}} return (A) this; + + public A withAllowedTopologies( + io.kubernetes.client.openapi.models.V1TopologySelectorTerm... allowedTopologies) { + if (this.allowedTopologies != null) { + this.allowedTopologies.clear(); + } + if (allowedTopologies != null) { + for (io.kubernetes.client.openapi.models.V1TopologySelectorTerm item : allowedTopologies) { + this.addToAllowedTopologies(item); + } + } + return (A) this; } + public java.lang.Boolean hasAllowedTopologies() { return allowedTopologies != null && !allowedTopologies.isEmpty(); } - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested addNewAllowedTopology() { - return new io.kubernetes.client.openapi.models.V1StorageClassFluentImpl.AllowedTopologiesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + addNewAllowedTopology() { + return new io.kubernetes.client.openapi.models.V1StorageClassFluentImpl + .AllowedTopologiesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested addNewAllowedTopologyLike(io.kubernetes.client.openapi.models.V1TopologySelectorTerm item) { - return new io.kubernetes.client.openapi.models.V1StorageClassFluentImpl.AllowedTopologiesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + addNewAllowedTopologyLike(io.kubernetes.client.openapi.models.V1TopologySelectorTerm item) { + return new io.kubernetes.client.openapi.models.V1StorageClassFluentImpl + .AllowedTopologiesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested setNewAllowedTopologyLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorTerm item) { - return new io.kubernetes.client.openapi.models.V1StorageClassFluentImpl.AllowedTopologiesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + setNewAllowedTopologyLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1TopologySelectorTerm item) { + return new io.kubernetes.client.openapi.models.V1StorageClassFluentImpl + .AllowedTopologiesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested editAllowedTopology(java.lang.Integer index) { - if (allowedTopologies.size() <= index) throw new RuntimeException("Can't edit allowedTopologies. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + editAllowedTopology(java.lang.Integer index) { + if (allowedTopologies.size() <= index) + throw new RuntimeException("Can't edit allowedTopologies. Index exceeds size."); return setNewAllowedTopologyLike(index, buildAllowedTopology(index)); } - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested editFirstAllowedTopology() { - if (allowedTopologies.size() == 0) throw new RuntimeException("Can't edit first allowedTopologies. The list is empty."); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + editFirstAllowedTopology() { + if (allowedTopologies.size() == 0) + throw new RuntimeException("Can't edit first allowedTopologies. The list is empty."); return setNewAllowedTopologyLike(0, buildAllowedTopology(0)); } - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested editLastAllowedTopology() { + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + editLastAllowedTopology() { int index = allowedTopologies.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last allowedTopologies. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last allowedTopologies. The list is empty."); return setNewAllowedTopologyLike(index, buildAllowedTopology(index)); } - public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested editMatchingAllowedTopology(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested + editMatchingAllowedTopology( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1StorageClassFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1StorageClassFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1StorageClassFluentImpl.MetadataNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - public A addToMountOptions(java.lang.Integer index,java.lang.String item) { - if (this.mountOptions == null) {this.mountOptions = new java.util.ArrayList();} + + public A addToMountOptions(java.lang.Integer index, java.lang.String item) { + if (this.mountOptions == null) { + this.mountOptions = new java.util.ArrayList(); + } this.mountOptions.add(index, item); - return (A)this; + return (A) this; } - public A setToMountOptions(java.lang.Integer index,java.lang.String item) { - if (this.mountOptions == null) {this.mountOptions = new java.util.ArrayList();} - this.mountOptions.set(index, item); return (A)this; + + public A setToMountOptions(java.lang.Integer index, java.lang.String item) { + if (this.mountOptions == null) { + this.mountOptions = new java.util.ArrayList(); + } + this.mountOptions.set(index, item); + return (A) this; } + public A addToMountOptions(java.lang.String... items) { - if (this.mountOptions == null) {this.mountOptions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.mountOptions.add(item);} return (A)this; + if (this.mountOptions == null) { + this.mountOptions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.mountOptions.add(item); + } + return (A) this; } + public A addAllToMountOptions(java.util.Collection items) { - if (this.mountOptions == null) {this.mountOptions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.mountOptions.add(item);} return (A)this; + if (this.mountOptions == null) { + this.mountOptions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.mountOptions.add(item); + } + return (A) this; } + public A removeFromMountOptions(java.lang.String... items) { - for (java.lang.String item : items) {if (this.mountOptions!= null){ this.mountOptions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.mountOptions != null) { + this.mountOptions.remove(item); + } + } + return (A) this; } + public A removeAllFromMountOptions(java.util.Collection items) { - for (java.lang.String item : items) {if (this.mountOptions!= null){ this.mountOptions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.mountOptions != null) { + this.mountOptions.remove(item); + } + } + return (A) this; } + public java.util.List getMountOptions() { return this.mountOptions; } + public java.lang.String getMountOption(java.lang.Integer index) { return this.mountOptions.get(index); } + public java.lang.String getFirstMountOption() { return this.mountOptions.get(0); } + public java.lang.String getLastMountOption() { return this.mountOptions.get(mountOptions.size() - 1); } - public java.lang.String getMatchingMountOption(java.util.function.Predicate predicate) { - for (java.lang.String item: mountOptions) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingMountOption( + java.util.function.Predicate predicate) { + for (java.lang.String item : mountOptions) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingMountOption(java.util.function.Predicate predicate) { - for (java.lang.String item: mountOptions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMountOption( + java.util.function.Predicate predicate) { + for (java.lang.String item : mountOptions) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withMountOptions(java.util.List mountOptions) { - if (mountOptions != null) {this.mountOptions = new java.util.ArrayList(); for (java.lang.String item : mountOptions){this.addToMountOptions(item);}} else { this.mountOptions = null;} return (A) this; + if (mountOptions != null) { + this.mountOptions = new java.util.ArrayList(); + for (java.lang.String item : mountOptions) { + this.addToMountOptions(item); + } + } else { + this.mountOptions = null; + } + return (A) this; } + public A withMountOptions(java.lang.String... mountOptions) { - if (this.mountOptions != null) {this.mountOptions.clear();} - if (mountOptions != null) {for (java.lang.String item :mountOptions){ this.addToMountOptions(item);}} return (A) this; + if (this.mountOptions != null) { + this.mountOptions.clear(); + } + if (mountOptions != null) { + for (java.lang.String item : mountOptions) { + this.addToMountOptions(item); + } + } + return (A) this; } + public java.lang.Boolean hasMountOptions() { return mountOptions != null && !mountOptions.isEmpty(); } + public A addNewMountOption(java.lang.String original) { - return (A)addToMountOptions(new String(original)); + return (A) addToMountOptions(new String(original)); } - public A addToParameters(java.lang.String key,java.lang.String value) { - if(this.parameters == null && key != null && value != null) { this.parameters = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.parameters.put(key, value);} return (A)this; + + public A addToParameters(java.lang.String key, java.lang.String value) { + if (this.parameters == null && key != null && value != null) { + this.parameters = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.parameters.put(key, value); + } + return (A) this; } - public A addToParameters(java.util.Map map) { - if(this.parameters == null && map != null) { this.parameters = new java.util.LinkedHashMap(); } - if(map != null) { this.parameters.putAll(map);} return (A)this; + + public A addToParameters(java.util.Map map) { + if (this.parameters == null && map != null) { + this.parameters = new java.util.LinkedHashMap(); + } + if (map != null) { + this.parameters.putAll(map); + } + return (A) this; } + public A removeFromParameters(java.lang.String key) { - if(this.parameters == null) { return (A) this; } - if(key != null && this.parameters != null) {this.parameters.remove(key);} return (A)this; + if (this.parameters == null) { + return (A) this; + } + if (key != null && this.parameters != null) { + this.parameters.remove(key); + } + return (A) this; } - public A removeFromParameters(java.util.Map map) { - if(this.parameters == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.parameters != null){this.parameters.remove(key);}}} return (A)this; + + public A removeFromParameters(java.util.Map map) { + if (this.parameters == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.parameters != null) { + this.parameters.remove(key); + } + } + } + return (A) this; } - public java.util.Map getParameters() { + + public java.util.Map getParameters() { return this.parameters; } - public A withParameters(java.util.Map parameters) { - if (parameters == null) { this.parameters = null;} else {this.parameters = new java.util.LinkedHashMap(parameters);} return (A) this; + + public A withParameters(java.util.Map parameters) { + if (parameters == null) { + this.parameters = null; + } else { + this.parameters = new java.util.LinkedHashMap(parameters); + } + return (A) this; } + public java.lang.Boolean hasParameters() { return this.parameters != null; } + public java.lang.String getProvisioner() { return this.provisioner; } + public A withProvisioner(java.lang.String provisioner) { - this.provisioner=provisioner; return (A) this; + this.provisioner = provisioner; + return (A) this; } + public java.lang.Boolean hasProvisioner() { return this.provisioner != null; } - - /** - * Method is deprecated. use withProvisioner instead. - */ + + /** Method is deprecated. use withProvisioner instead. */ @java.lang.Deprecated public A withNewProvisioner(java.lang.String original) { - return (A)withProvisioner(new String(original)); + return (A) withProvisioner(new String(original)); } + public java.lang.String getReclaimPolicy() { return this.reclaimPolicy; } + public A withReclaimPolicy(java.lang.String reclaimPolicy) { - this.reclaimPolicy=reclaimPolicy; return (A) this; + this.reclaimPolicy = reclaimPolicy; + return (A) this; } + public java.lang.Boolean hasReclaimPolicy() { return this.reclaimPolicy != null; } - - /** - * Method is deprecated. use withReclaimPolicy instead. - */ + + /** Method is deprecated. use withReclaimPolicy instead. */ @java.lang.Deprecated public A withNewReclaimPolicy(java.lang.String original) { - return (A)withReclaimPolicy(new String(original)); + return (A) withReclaimPolicy(new String(original)); } + public java.lang.String getVolumeBindingMode() { return this.volumeBindingMode; } + public A withVolumeBindingMode(java.lang.String volumeBindingMode) { - this.volumeBindingMode=volumeBindingMode; return (A) this; + this.volumeBindingMode = volumeBindingMode; + return (A) this; } + public java.lang.Boolean hasVolumeBindingMode() { return this.volumeBindingMode != null; } - - /** - * Method is deprecated. use withVolumeBindingMode instead. - */ + + /** Method is deprecated. use withVolumeBindingMode instead. */ @java.lang.Deprecated public A withNewVolumeBindingMode(java.lang.String original) { - return (A)withVolumeBindingMode(new String(original)); + return (A) withVolumeBindingMode(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1StorageClassFluentImpl that = (V1StorageClassFluentImpl) o; - if (allowVolumeExpansion != null ? !allowVolumeExpansion.equals(that.allowVolumeExpansion) :that.allowVolumeExpansion != null) return false; - if (allowedTopologies != null ? !allowedTopologies.equals(that.allowedTopologies) :that.allowedTopologies != null) return false; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (mountOptions != null ? !mountOptions.equals(that.mountOptions) :that.mountOptions != null) return false; - if (parameters != null ? !parameters.equals(that.parameters) :that.parameters != null) return false; - if (provisioner != null ? !provisioner.equals(that.provisioner) :that.provisioner != null) return false; - if (reclaimPolicy != null ? !reclaimPolicy.equals(that.reclaimPolicy) :that.reclaimPolicy != null) return false; - if (volumeBindingMode != null ? !volumeBindingMode.equals(that.volumeBindingMode) :that.volumeBindingMode != null) return false; + if (allowVolumeExpansion != null + ? !allowVolumeExpansion.equals(that.allowVolumeExpansion) + : that.allowVolumeExpansion != null) return false; + if (allowedTopologies != null + ? !allowedTopologies.equals(that.allowedTopologies) + : that.allowedTopologies != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (mountOptions != null ? !mountOptions.equals(that.mountOptions) : that.mountOptions != null) + return false; + if (parameters != null ? !parameters.equals(that.parameters) : that.parameters != null) + return false; + if (provisioner != null ? !provisioner.equals(that.provisioner) : that.provisioner != null) + return false; + if (reclaimPolicy != null + ? !reclaimPolicy.equals(that.reclaimPolicy) + : that.reclaimPolicy != null) return false; + if (volumeBindingMode != null + ? !volumeBindingMode.equals(that.volumeBindingMode) + : that.volumeBindingMode != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(allowVolumeExpansion, allowedTopologies, apiVersion, kind, metadata, mountOptions, parameters, provisioner, reclaimPolicy, volumeBindingMode, super.hashCode()); + return java.util.Objects.hash( + allowVolumeExpansion, + allowedTopologies, + apiVersion, + kind, + metadata, + mountOptions, + parameters, + provisioner, + reclaimPolicy, + volumeBindingMode, + super.hashCode()); } - public class AllowedTopologiesNestedImpl extends io.kubernetes.client.openapi.models.V1TopologySelectorTermFluentImpl> implements io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested,io.kubernetes.client.fluent.Nested{ - AllowedTopologiesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorTerm item) { + + public class AllowedTopologiesNestedImpl + extends io.kubernetes.client.openapi.models.V1TopologySelectorTermFluentImpl< + io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested> + implements io.kubernetes.client.openapi.models.V1StorageClassFluent.AllowedTopologiesNested< + N>, + io.kubernetes.client.fluent.Nested { + AllowedTopologiesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1TopologySelectorTerm item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(this, item); } + AllowedTopologiesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder(this); } + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1StorageClassFluentImpl.this.setToAllowedTopologies(index,builder.build()); + return (N) V1StorageClassFluentImpl.this.setToAllowedTopologies(index, builder.build()); } + public N endAllowedTopology() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1StorageClassFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1StorageClassFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassListBuilder.java index c71a9ed40d..3bb77e4f47 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StorageClassListBuilder extends io.kubernetes.client.openapi.models.V1StorageClassListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StorageClassListBuilder + extends io.kubernetes.client.openapi.models.V1StorageClassListFluentImpl< + io.kubernetes.client.openapi.models.V1StorageClassListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1StorageClassList, + io.kubernetes.client.openapi.models.V1StorageClassListBuilder> { public V1StorageClassListBuilder() { this(false); } + public V1StorageClassListBuilder(java.lang.Boolean validationEnabled) { this(new V1StorageClassList(), validationEnabled); } - public V1StorageClassListBuilder(io.kubernetes.client.openapi.models.V1StorageClassListFluent fluent) { + + public V1StorageClassListBuilder( + io.kubernetes.client.openapi.models.V1StorageClassListFluent fluent) { this(fluent, false); } - public V1StorageClassListBuilder(io.kubernetes.client.openapi.models.V1StorageClassListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StorageClassListBuilder( + io.kubernetes.client.openapi.models.V1StorageClassListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1StorageClassList(), validationEnabled); } - public V1StorageClassListBuilder(io.kubernetes.client.openapi.models.V1StorageClassListFluent fluent,io.kubernetes.client.openapi.models.V1StorageClassList instance) { + + public V1StorageClassListBuilder( + io.kubernetes.client.openapi.models.V1StorageClassListFluent fluent, + io.kubernetes.client.openapi.models.V1StorageClassList instance) { this(fluent, instance, false); } - public V1StorageClassListBuilder(io.kubernetes.client.openapi.models.V1StorageClassListFluent fluent,io.kubernetes.client.openapi.models.V1StorageClassList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StorageClassListBuilder( + io.kubernetes.client.openapi.models.V1StorageClassListFluent fluent, + io.kubernetes.client.openapi.models.V1StorageClassList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1StorageClassListBuilder(io.kubernetes.client.openapi.models.V1StorageCl fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1StorageClassListBuilder(io.kubernetes.client.openapi.models.V1StorageClassList instance) { - this(instance,false); + + public V1StorageClassListBuilder( + io.kubernetes.client.openapi.models.V1StorageClassList instance) { + this(instance, false); } - public V1StorageClassListBuilder(io.kubernetes.client.openapi.models.V1StorageClassList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StorageClassListBuilder( + io.kubernetes.client.openapi.models.V1StorageClassList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1StorageClassListBuilder(io.kubernetes.client.openapi.models.V1StorageCl this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1StorageClassListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1StorageClassList build() { V1StorageClassList buildable = new V1StorageClassList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1StorageClassList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1StorageClassListBuilder that = (V1StorageClassListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassListFluent.java index 4ff56ada12..3ca4726191 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassListFluent.java @@ -1,95 +1,156 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1StorageClassListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1StorageClassListFluent< + A extends io.kubernetes.client.openapi.models.V1StorageClassListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StorageClass item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StorageClass item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StorageClass item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StorageClass item); + public A addToItems(io.kubernetes.client.openapi.models.V1StorageClass... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1StorageClass... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1StorageClass buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1StorageClass buildFirstItem(); + public io.kubernetes.client.openapi.models.V1StorageClass buildLastItem(); - public io.kubernetes.client.openapi.models.V1StorageClass buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1StorageClass buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1StorageClass... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1StorageClass item); - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StorageClass item); - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested editFirstItem(); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1StorageClass item); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StorageClass item); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested + editFirstItem(); + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1StorageClassFluent>{ + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1StorageClassFluent< + io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassListFluentImpl.java index 40e8ad7385..5686b47464 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageClassListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1StorageClassListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StorageClassListFluent{ - public V1StorageClassListFluentImpl() { - } - public V1StorageClassListFluentImpl(io.kubernetes.client.openapi.models.V1StorageClassList instance) { + +/** Generated */ +public class V1StorageClassListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1StorageClassListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1StorageClassListFluent { + public V1StorageClassListFluentImpl() {} + + public V1StorageClassListFluentImpl( + io.kubernetes.client.openapi.models.V1StorageClassList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1StorageClassListFluentImpl(io.kubernetes.client.openapi.models.V1Storag this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StorageClass item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1StorageClassBuilder builder = new io.kubernetes.client.openapi.models.V1StorageClassBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StorageClass item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1StorageClassBuilder builder = + new io.kubernetes.client.openapi.models.V1StorageClassBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StorageClass item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1StorageClassBuilder builder = new io.kubernetes.client.openapi.models.V1StorageClassBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StorageClass item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1StorageClassBuilder builder = + new io.kubernetes.client.openapi.models.V1StorageClassBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1StorageClass... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1StorageClass item : items) {io.kubernetes.client.openapi.models.V1StorageClassBuilder builder = new io.kubernetes.client.openapi.models.V1StorageClassBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1StorageClass item : items) { + io.kubernetes.client.openapi.models.V1StorageClassBuilder builder = + new io.kubernetes.client.openapi.models.V1StorageClassBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1StorageClass item : items) {io.kubernetes.client.openapi.models.V1StorageClassBuilder builder = new io.kubernetes.client.openapi.models.V1StorageClassBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1StorageClass item : items) { + io.kubernetes.client.openapi.models.V1StorageClassBuilder builder = + new io.kubernetes.client.openapi.models.V1StorageClassBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1StorageClass... items) { - for (io.kubernetes.client.openapi.models.V1StorageClass item : items) {io.kubernetes.client.openapi.models.V1StorageClassBuilder builder = new io.kubernetes.client.openapi.models.V1StorageClassBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1StorageClass item : items) { + io.kubernetes.client.openapi.models.V1StorageClassBuilder builder = + new io.kubernetes.client.openapi.models.V1StorageClassBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1StorageClass item : items) {io.kubernetes.client.openapi.models.V1StorageClassBuilder builder = new io.kubernetes.client.openapi.models.V1StorageClassBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1StorageClass item : items) { + io.kubernetes.client.openapi.models.V1StorageClassBuilder builder = + new io.kubernetes.client.openapi.models.V1StorageClassBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1StorageClassBuilder builder = each.next(); @@ -87,174 +159,279 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1StorageClass buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1StorageClass buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1StorageClass buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1StorageClass buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1StorageClassBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1StorageClass buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1StorageClassBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1StorageClassBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1StorageClassBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1StorageClass item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1StorageClass item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1StorageClass... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1StorageClass item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1StorageClass item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1StorageClassListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1StorageClass item) { - return new io.kubernetes.client.openapi.models.V1StorageClassListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1StorageClass item) { + return new io.kubernetes.client.openapi.models.V1StorageClassListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StorageClass item) { - return new io.kubernetes.client.openapi.models.V1StorageClassListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StorageClass item) { + return new io.kubernetes.client.openapi.models.V1StorageClassListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1StorageClassListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1StorageClassListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1StorageClassListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1StorageClassListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1StorageClassListFluentImpl that = (V1StorageClassListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1StorageClassFluentImpl> implements io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1StorageClass item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1StorageClassFluentImpl< + io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1StorageClassListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1StorageClass item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1StorageClassBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1StorageClassBuilder(this); } + io.kubernetes.client.openapi.models.V1StorageClassBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1StorageClassListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1StorageClassListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1StorageClassListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1StorageClassListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSPersistentVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSPersistentVolumeSourceBuilder.java index e53f9a60cf..3e961f59d8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSPersistentVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSPersistentVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StorageOSPersistentVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StorageOSPersistentVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource, + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceBuilder> { public V1StorageOSPersistentVolumeSourceBuilder() { this(false); } + public V1StorageOSPersistentVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1StorageOSPersistentVolumeSource(), validationEnabled); } - public V1StorageOSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent fluent) { + + public V1StorageOSPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent fluent) { this(fluent, false); } - public V1StorageOSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StorageOSPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1StorageOSPersistentVolumeSource(), validationEnabled); } - public V1StorageOSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource instance) { + + public V1StorageOSPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource instance) { this(fluent, instance, false); } - public V1StorageOSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StorageOSPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withReadOnly(instance.getReadOnly()); @@ -31,13 +58,18 @@ public V1StorageOSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.mod fluent.withVolumeNamespace(instance.getVolumeNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1StorageOSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource instance) { - this(instance,false); + + public V1StorageOSPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource instance) { + this(instance, false); } - public V1StorageOSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StorageOSPersistentVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withReadOnly(instance.getReadOnly()); @@ -48,10 +80,12 @@ public V1StorageOSPersistentVolumeSourceBuilder(io.kubernetes.client.openapi.mod this.withVolumeNamespace(instance.getVolumeNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource build() { V1StorageOSPersistentVolumeSource buildable = new V1StorageOSPersistentVolumeSource(); buildable.setFsType(fluent.getFsType()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource bui buildable.setVolumeNamespace(fluent.getVolumeNamespace()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1StorageOSPersistentVolumeSourceBuilder that = (V1StorageOSPersistentVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSPersistentVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSPersistentVolumeSourceFluent.java index 261ba491ca..289e6e2e17 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSPersistentVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSPersistentVolumeSourceFluent.java @@ -1,65 +1,104 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1StorageOSPersistentVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1StorageOSPersistentVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1ObjectReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent + .SecretRefNested< + A> + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent + .SecretRefNested< + A> + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent + .SecretRefNested< + A> + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent + .SecretRefNested< + A> + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent + .SecretRefNested< + A> + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + public java.lang.String getVolumeName(); + public A withVolumeName(java.lang.String volumeName); + public java.lang.Boolean hasVolumeName(); - - /** - * Method is deprecated. use withVolumeName instead. - */ + + /** Method is deprecated. use withVolumeName instead. */ @java.lang.Deprecated public A withNewVolumeName(java.lang.String original); + public java.lang.String getVolumeNamespace(); + public A withVolumeNamespace(java.lang.String volumeNamespace); + public java.lang.Boolean hasVolumeNamespace(); - - /** - * Method is deprecated. use withVolumeNamespace instead. - */ + + /** Method is deprecated. use withVolumeNamespace instead. */ @java.lang.Deprecated public A withNewVolumeNamespace(java.lang.String original); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent + .SecretRefNested< + N>> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSPersistentVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSPersistentVolumeSourceFluentImpl.java index c9694101c4..90d4197843 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSPersistentVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSPersistentVolumeSourceFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1StorageOSPersistentVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent { + public V1StorageOSPersistentVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1StorageOSPersistentVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent{ - public V1StorageOSPersistentVolumeSourceFluentImpl() { - } - public V1StorageOSPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource instance) { + public V1StorageOSPersistentVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSource instance) { this.withFsType(instance.getFsType()); this.withReadOnly(instance.getReadOnly()); @@ -23,136 +30,198 @@ public V1StorageOSPersistentVolumeSourceFluentImpl(io.kubernetes.client.openapi. this.withVolumeName(instance.getVolumeName()); this.withVolumeNamespace(instance.getVolumeNamespace()); - } + private java.lang.String fsType; private java.lang.Boolean readOnly; private io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder secretRef; private java.lang.String volumeName; private java.lang.String volumeNamespace; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1ObjectReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent + .SecretRefNested< + A> + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return new io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent + .SecretRefNested< + A> + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return new io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluentImpl + .SecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent + .SecretRefNested< + A> + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent + .SecretRefNested< + A> + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent + .SecretRefNested< + A> + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public java.lang.String getVolumeName() { return this.volumeName; } + public A withVolumeName(java.lang.String volumeName) { - this.volumeName=volumeName; return (A) this; + this.volumeName = volumeName; + return (A) this; } + public java.lang.Boolean hasVolumeName() { return this.volumeName != null; } - - /** - * Method is deprecated. use withVolumeName instead. - */ + + /** Method is deprecated. use withVolumeName instead. */ @java.lang.Deprecated public A withNewVolumeName(java.lang.String original) { - return (A)withVolumeName(new String(original)); + return (A) withVolumeName(new String(original)); } + public java.lang.String getVolumeNamespace() { return this.volumeNamespace; } + public A withVolumeNamespace(java.lang.String volumeNamespace) { - this.volumeNamespace=volumeNamespace; return (A) this; + this.volumeNamespace = volumeNamespace; + return (A) this; } + public java.lang.Boolean hasVolumeNamespace() { return this.volumeNamespace != null; } - - /** - * Method is deprecated. use withVolumeNamespace instead. - */ + + /** Method is deprecated. use withVolumeNamespace instead. */ @java.lang.Deprecated public A withNewVolumeNamespace(java.lang.String original) { - return (A)withVolumeNamespace(new String(original)); + return (A) withVolumeNamespace(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1StorageOSPersistentVolumeSourceFluentImpl that = (V1StorageOSPersistentVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; - if (volumeName != null ? !volumeName.equals(that.volumeName) :that.volumeName != null) return false; - if (volumeNamespace != null ? !volumeNamespace.equals(that.volumeNamespace) :that.volumeNamespace != null) return false; + V1StorageOSPersistentVolumeSourceFluentImpl that = + (V1StorageOSPersistentVolumeSourceFluentImpl) o; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; + if (volumeName != null ? !volumeName.equals(that.volumeName) : that.volumeName != null) + return false; + if (volumeNamespace != null + ? !volumeNamespace.equals(that.volumeNamespace) + : that.volumeNamespace != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, readOnly, secretRef, volumeName, volumeNamespace, super.hashCode()); + return java.util.Objects.hash( + fsType, readOnly, secretRef, volumeName, volumeNamespace, super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent + .SecretRefNested< + N>> + implements io.kubernetes.client.openapi.models.V1StorageOSPersistentVolumeSourceFluent + .SecretRefNested< + N>, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1ObjectReference item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; + public N and() { return (N) V1StorageOSPersistentVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSVolumeSourceBuilder.java index a72ef3716e..465a267029 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1StorageOSVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1StorageOSVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1StorageOSVolumeSource, + io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceBuilder> { public V1StorageOSVolumeSourceBuilder() { this(false); } + public V1StorageOSVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1StorageOSVolumeSource(), validationEnabled); } - public V1StorageOSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent fluent) { + + public V1StorageOSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent fluent) { this(fluent, false); } - public V1StorageOSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1StorageOSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1StorageOSVolumeSource(), validationEnabled); } - public V1StorageOSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1StorageOSVolumeSource instance) { + + public V1StorageOSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1StorageOSVolumeSource instance) { this(fluent, instance, false); } - public V1StorageOSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1StorageOSVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1StorageOSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1StorageOSVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withReadOnly(instance.getReadOnly()); @@ -31,13 +58,18 @@ public V1StorageOSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1Stor fluent.withVolumeNamespace(instance.getVolumeNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1StorageOSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1StorageOSVolumeSource instance) { - this(instance,false); + + public V1StorageOSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1StorageOSVolumeSource instance) { + this(instance, false); } - public V1StorageOSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1StorageOSVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1StorageOSVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1StorageOSVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withReadOnly(instance.getReadOnly()); @@ -48,10 +80,12 @@ public V1StorageOSVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1Stor this.withVolumeNamespace(instance.getVolumeNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1StorageOSVolumeSource build() { V1StorageOSVolumeSource buildable = new V1StorageOSVolumeSource(); buildable.setFsType(fluent.getFsType()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1StorageOSVolumeSource build() { buildable.setVolumeNamespace(fluent.getVolumeNamespace()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1StorageOSVolumeSourceBuilder that = (V1StorageOSVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSVolumeSourceFluent.java index 0abd1c1543..f744316195 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSVolumeSourceFluent.java @@ -1,65 +1,93 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1StorageOSVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1StorageOSVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef(); + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef(); + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef); + public java.lang.Boolean hasSecretRef(); - public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested withNewSecretRef(); - public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); - public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested editSecretRef(); - public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested editOrNewSecretRef(); - public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested + withNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + + public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested + editSecretRef(); + + public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested + editOrNewSecretRef(); + + public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item); + public java.lang.String getVolumeName(); + public A withVolumeName(java.lang.String volumeName); + public java.lang.Boolean hasVolumeName(); - - /** - * Method is deprecated. use withVolumeName instead. - */ + + /** Method is deprecated. use withVolumeName instead. */ @java.lang.Deprecated public A withNewVolumeName(java.lang.String original); + public java.lang.String getVolumeNamespace(); + public A withVolumeNamespace(java.lang.String volumeNamespace); + public java.lang.Boolean hasVolumeNamespace(); - - /** - * Method is deprecated. use withVolumeNamespace instead. - */ + + /** Method is deprecated. use withVolumeNamespace instead. */ @java.lang.Deprecated public A withNewVolumeNamespace(java.lang.String original); - public interface SecretRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent>{ + + public interface SecretRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested< + N>> { public N and(); + public N endSecretRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSVolumeSourceFluentImpl.java index 215cf9a0e8..5f9b8cba9a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1StorageOSVolumeSourceFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1StorageOSVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent { + public V1StorageOSVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1StorageOSVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent{ - public V1StorageOSVolumeSourceFluentImpl() { - } - public V1StorageOSVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1StorageOSVolumeSource instance) { + public V1StorageOSVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1StorageOSVolumeSource instance) { this.withFsType(instance.getFsType()); this.withReadOnly(instance.getReadOnly()); @@ -23,136 +30,186 @@ public V1StorageOSVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1S this.withVolumeName(instance.getVolumeName()); this.withVolumeNamespace(instance.getVolumeNamespace()); - } + private java.lang.String fsType; private java.lang.Boolean readOnly; private io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder secretRef; private java.lang.String volumeName; private java.lang.String volumeNamespace; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } - + /** * This method has been deprecated, please use method buildSecretRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LocalObjectReference getSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public io.kubernetes.client.openapi.models.V1LocalObjectReference buildSecretRef() { - return this.secretRef!=null ?this.secretRef.build():null; + return this.secretRef != null ? this.secretRef.build() : null; } + public A withSecretRef(io.kubernetes.client.openapi.models.V1LocalObjectReference secretRef) { _visitables.get("secretRef").remove(this.secretRef); - if (secretRef!=null){ this.secretRef= new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); _visitables.get("secretRef").add(this.secretRef);} return (A) this; + if (secretRef != null) { + this.secretRef = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(secretRef); + _visitables.get("secretRef").add(this.secretRef); + } + return (A) this; } + public java.lang.Boolean hasSecretRef() { return this.secretRef != null; } - public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested withNewSecretRef() { - return new io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluentImpl.SecretRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested + withNewSecretRef() { + return new io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluentImpl + .SecretRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return new io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluentImpl.SecretRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested + withNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return new io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluentImpl + .SecretRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested editSecretRef() { + + public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested + editSecretRef() { return withNewSecretRefLike(getSecretRef()); } - public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested editOrNewSecretRef() { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested + editOrNewSecretRef() { + return withNewSecretRefLike( + getSecretRef() != null + ? getSecretRef() + : new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - return withNewSecretRefLike(getSecretRef() != null ? getSecretRef(): item); + + public io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested + editOrNewSecretRefLike(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { + return withNewSecretRefLike(getSecretRef() != null ? getSecretRef() : item); } + public java.lang.String getVolumeName() { return this.volumeName; } + public A withVolumeName(java.lang.String volumeName) { - this.volumeName=volumeName; return (A) this; + this.volumeName = volumeName; + return (A) this; } + public java.lang.Boolean hasVolumeName() { return this.volumeName != null; } - - /** - * Method is deprecated. use withVolumeName instead. - */ + + /** Method is deprecated. use withVolumeName instead. */ @java.lang.Deprecated public A withNewVolumeName(java.lang.String original) { - return (A)withVolumeName(new String(original)); + return (A) withVolumeName(new String(original)); } + public java.lang.String getVolumeNamespace() { return this.volumeNamespace; } + public A withVolumeNamespace(java.lang.String volumeNamespace) { - this.volumeNamespace=volumeNamespace; return (A) this; + this.volumeNamespace = volumeNamespace; + return (A) this; } + public java.lang.Boolean hasVolumeNamespace() { return this.volumeNamespace != null; } - - /** - * Method is deprecated. use withVolumeNamespace instead. - */ + + /** Method is deprecated. use withVolumeNamespace instead. */ @java.lang.Deprecated public A withNewVolumeNamespace(java.lang.String original) { - return (A)withVolumeNamespace(new String(original)); + return (A) withVolumeNamespace(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1StorageOSVolumeSourceFluentImpl that = (V1StorageOSVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (secretRef != null ? !secretRef.equals(that.secretRef) :that.secretRef != null) return false; - if (volumeName != null ? !volumeName.equals(that.volumeName) :that.volumeName != null) return false; - if (volumeNamespace != null ? !volumeNamespace.equals(that.volumeNamespace) :that.volumeNamespace != null) return false; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (secretRef != null ? !secretRef.equals(that.secretRef) : that.secretRef != null) + return false; + if (volumeName != null ? !volumeName.equals(that.volumeName) : that.volumeName != null) + return false; + if (volumeNamespace != null + ? !volumeNamespace.equals(that.volumeNamespace) + : that.volumeNamespace != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, readOnly, secretRef, volumeName, volumeNamespace, super.hashCode()); + return java.util.Objects.hash( + fsType, readOnly, secretRef, volumeName, volumeNamespace, super.hashCode()); } - public class SecretRefNestedImpl extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested,io.kubernetes.client.fluent.Nested{ + + public class SecretRefNestedImpl + extends io.kubernetes.client.openapi.models.V1LocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested> + implements io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent.SecretRefNested< + N>, + io.kubernetes.client.fluent.Nested { SecretRefNestedImpl(io.kubernetes.client.openapi.models.V1LocalObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this, item); } + SecretRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1LocalObjectReferenceBuilder builder; + public N and() { return (N) V1StorageOSVolumeSourceFluentImpl.this.withSecretRef(builder.build()); } + public N endSecretRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewBuilder.java index 2183ecbf5c..a1545e1efc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SubjectAccessReviewBuilder extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SubjectAccessReviewBuilder + extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluentImpl< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SubjectAccessReview, + io.kubernetes.client.openapi.models.V1SubjectAccessReviewBuilder> { public V1SubjectAccessReviewBuilder() { this(false); } + public V1SubjectAccessReviewBuilder(java.lang.Boolean validationEnabled) { this(new V1SubjectAccessReview(), validationEnabled); } - public V1SubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent fluent) { + + public V1SubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent fluent) { this(fluent, false); } - public V1SubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SubjectAccessReview(), validationEnabled); } - public V1SubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent fluent,io.kubernetes.client.openapi.models.V1SubjectAccessReview instance) { + + public V1SubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent fluent, + io.kubernetes.client.openapi.models.V1SubjectAccessReview instance) { this(fluent, instance, false); } - public V1SubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent fluent,io.kubernetes.client.openapi.models.V1SubjectAccessReview instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent fluent, + io.kubernetes.client.openapi.models.V1SubjectAccessReview instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1SubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1Subjec fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1SubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReview instance) { - this(instance,false); + + public V1SubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReview instance) { + this(instance, false); } - public V1SubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReview instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SubjectAccessReviewBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReview instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1SubjectAccessReviewBuilder(io.kubernetes.client.openapi.models.V1Subjec this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SubjectAccessReview build() { V1SubjectAccessReview buildable = new V1SubjectAccessReview(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1SubjectAccessReview build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SubjectAccessReviewBuilder that = (V1SubjectAccessReviewBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewFluent.java index fbe435a0c3..8f499b6dc5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewFluent.java @@ -1,93 +1,151 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SubjectAccessReviewFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SubjectAccessReviewFluent< + A extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec getSpec(); + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item); + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item); - + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus getStatus(); + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewFluentImpl.java index 31b2293690..63672ea487 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1SubjectAccessReviewFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent { + public V1SubjectAccessReviewFluentImpl() {} - /** - * Generated - */ -public class V1SubjectAccessReviewFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent{ - public V1SubjectAccessReviewFluentImpl() { - } - public V1SubjectAccessReviewFluentImpl(io.kubernetes.client.openapi.models.V1SubjectAccessReview instance) { + public V1SubjectAccessReviewFluentImpl( + io.kubernetes.client.openapi.models.V1SubjectAccessReview instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,311 @@ public V1SubjectAccessReviewFluentImpl(io.kubernetes.client.openapi.models.V1Sub this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder spec; private io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested withNewSpec() { + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested + withNewSpec() { return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item) { - return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item) { + return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluentImpl.SpecNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { - return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { + return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluentImpl.StatusNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SubjectAccessReviewFluentImpl that = (V1SubjectAccessReviewFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1SubjectAccessReviewFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder builder; + public N and() { return (N) V1SubjectAccessReviewFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluentImpl< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder builder; + public N and() { return (N) V1SubjectAccessReviewFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewSpecBuilder.java index 22fcd61cb8..a510b4ecb0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SubjectAccessReviewSpecBuilder extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SubjectAccessReviewSpecBuilder + extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec, + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecBuilder> { public V1SubjectAccessReviewSpecBuilder() { this(false); } + public V1SubjectAccessReviewSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1SubjectAccessReviewSpec(), validationEnabled); } - public V1SubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent fluent) { + + public V1SubjectAccessReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent fluent) { this(fluent, false); } - public V1SubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SubjectAccessReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SubjectAccessReviewSpec(), validationEnabled); } - public V1SubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent fluent,io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec instance) { + + public V1SubjectAccessReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent fluent, + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec instance) { this(fluent, instance, false); } - public V1SubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent fluent,io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SubjectAccessReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent fluent, + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withExtra(instance.getExtra()); fluent.withGroups(instance.getGroups()); @@ -33,13 +60,18 @@ public V1SubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1Su fluent.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1SubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec instance) { - this(instance,false); + + public V1SubjectAccessReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec instance) { + this(instance, false); } - public V1SubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SubjectAccessReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withExtra(instance.getExtra()); this.withGroups(instance.getGroups()); @@ -52,10 +84,12 @@ public V1SubjectAccessReviewSpecBuilder(io.kubernetes.client.openapi.models.V1Su this.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec build() { V1SubjectAccessReviewSpec buildable = new V1SubjectAccessReviewSpec(); buildable.setExtra(fluent.getExtra()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec build() { buildable.setUser(fluent.getUser()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SubjectAccessReviewSpecBuilder that = (V1SubjectAccessReviewSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewSpecFluent.java index adfb8f80f2..230352da2e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewSpecFluent.java @@ -1,103 +1,192 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1SubjectAccessReviewSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToExtra(java.lang.String key,java.util.List value); - public A addToExtra(java.util.Map> map); +/** Generated */ +public interface V1SubjectAccessReviewSpecFluent< + A extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToExtra(java.lang.String key, java.util.List value); + + public A addToExtra(java.util.Map> map); + public A removeFromExtra(java.lang.String key); - public A removeFromExtra(java.util.Map> map); - public java.util.Map> getExtra(); - public A withExtra(java.util.Map> extra); + + public A removeFromExtra(java.util.Map> map); + + public java.util.Map> getExtra(); + + public A withExtra( + java.util.Map> extra); + public java.lang.Boolean hasExtra(); - public A addToGroups(java.lang.Integer index,java.lang.String item); - public A setToGroups(java.lang.Integer index,java.lang.String item); + + public A addToGroups(java.lang.Integer index, java.lang.String item); + + public A setToGroups(java.lang.Integer index, java.lang.String item); + public A addToGroups(java.lang.String... items); + public A addAllToGroups(java.util.Collection items); + public A removeFromGroups(java.lang.String... items); + public A removeAllFromGroups(java.util.Collection items); + public java.util.List getGroups(); + public java.lang.String getGroup(java.lang.Integer index); + public java.lang.String getFirstGroup(); + public java.lang.String getLastGroup(); - public java.lang.String getMatchingGroup(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingGroup(java.util.function.Predicate predicate); + + public java.lang.String getMatchingGroup( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingGroup( + java.util.function.Predicate predicate); + public A withGroups(java.util.List groups); + public A withGroups(java.lang.String... groups); + public java.lang.Boolean hasGroups(); + public A addNewGroup(java.lang.String original); - + /** * This method has been deprecated, please use method buildNonResourceAttributes instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NonResourceAttributes getNonResourceAttributes(); + public io.kubernetes.client.openapi.models.V1NonResourceAttributes buildNonResourceAttributes(); - public A withNonResourceAttributes(io.kubernetes.client.openapi.models.V1NonResourceAttributes nonResourceAttributes); + + public A withNonResourceAttributes( + io.kubernetes.client.openapi.models.V1NonResourceAttributes nonResourceAttributes); + public java.lang.Boolean hasNonResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.NonResourceAttributesNested withNewNonResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.NonResourceAttributesNested withNewNonResourceAttributesLike(io.kubernetes.client.openapi.models.V1NonResourceAttributes item); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.NonResourceAttributesNested editNonResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.NonResourceAttributesNested editOrNewNonResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.NonResourceAttributesNested editOrNewNonResourceAttributesLike(io.kubernetes.client.openapi.models.V1NonResourceAttributes item); - + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + withNewNonResourceAttributes(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + withNewNonResourceAttributesLike( + io.kubernetes.client.openapi.models.V1NonResourceAttributes item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + editNonResourceAttributes(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + editOrNewNonResourceAttributes(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + editOrNewNonResourceAttributesLike( + io.kubernetes.client.openapi.models.V1NonResourceAttributes item); + /** * This method has been deprecated, please use method buildResourceAttributes instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceAttributes getResourceAttributes(); + public io.kubernetes.client.openapi.models.V1ResourceAttributes buildResourceAttributes(); - public A withResourceAttributes(io.kubernetes.client.openapi.models.V1ResourceAttributes resourceAttributes); + + public A withResourceAttributes( + io.kubernetes.client.openapi.models.V1ResourceAttributes resourceAttributes); + public java.lang.Boolean hasResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.ResourceAttributesNested withNewResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.ResourceAttributesNested withNewResourceAttributesLike(io.kubernetes.client.openapi.models.V1ResourceAttributes item); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.ResourceAttributesNested editResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.ResourceAttributesNested editOrNewResourceAttributes(); - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.ResourceAttributesNested editOrNewResourceAttributesLike(io.kubernetes.client.openapi.models.V1ResourceAttributes item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + withNewResourceAttributes(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + withNewResourceAttributesLike(io.kubernetes.client.openapi.models.V1ResourceAttributes item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + editResourceAttributes(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + editOrNewResourceAttributes(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + editOrNewResourceAttributesLike( + io.kubernetes.client.openapi.models.V1ResourceAttributes item); + public java.lang.String getUid(); + public A withUid(java.lang.String uid); + public java.lang.Boolean hasUid(); - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original); + public java.lang.String getUser(); + public A withUser(java.lang.String user); + public java.lang.Boolean hasUser(); - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original); - public interface NonResourceAttributesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent>{ + + public interface NonResourceAttributesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NonResourceAttributesFluent< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + N>> { public N and(); + public N endNonResourceAttributes(); - } - public interface ResourceAttributesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ResourceAttributesFluent>{ + + public interface ResourceAttributesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ResourceAttributesFluent< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .ResourceAttributesNested< + N>> { public N and(); + public N endResourceAttributes(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewSpecFluentImpl.java index 832ed4e2e5..1a3c8a72ab 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewSpecFluentImpl.java @@ -1,26 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; -import java.util.Map; - - /** - * Generated - */ -public class V1SubjectAccessReviewSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent{ - public V1SubjectAccessReviewSpecFluentImpl() { - } - public V1SubjectAccessReviewSpecFluentImpl(io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec instance) { +/** Generated */ +public class V1SubjectAccessReviewSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent { + public V1SubjectAccessReviewSpecFluentImpl() {} + + public V1SubjectAccessReviewSpecFluentImpl( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpec instance) { this.withExtra(instance.getExtra()); this.withGroups(instance.getGroups()); @@ -32,241 +32,460 @@ public V1SubjectAccessReviewSpecFluentImpl(io.kubernetes.client.openapi.models.V this.withUid(instance.getUid()); this.withUser(instance.getUser()); - } - private java.util.Map> extra; + + private java.util.Map> extra; private java.util.List groups; private io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder nonResourceAttributes; private io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder resourceAttributes; private java.lang.String uid; private java.lang.String user; - public A addToExtra(java.lang.String key,java.util.List value) { - if(this.extra == null && key != null && value != null) { this.extra = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.extra.put(key, value);} return (A)this; + + public A addToExtra(java.lang.String key, java.util.List value) { + if (this.extra == null && key != null && value != null) { + this.extra = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.extra.put(key, value); + } + return (A) this; } - public A addToExtra(java.util.Map> map) { - if(this.extra == null && map != null) { this.extra = new java.util.LinkedHashMap(); } - if(map != null) { this.extra.putAll(map);} return (A)this; + + public A addToExtra(java.util.Map> map) { + if (this.extra == null && map != null) { + this.extra = new java.util.LinkedHashMap(); + } + if (map != null) { + this.extra.putAll(map); + } + return (A) this; } + public A removeFromExtra(java.lang.String key) { - if(this.extra == null) { return (A) this; } - if(key != null && this.extra != null) {this.extra.remove(key);} return (A)this; + if (this.extra == null) { + return (A) this; + } + if (key != null && this.extra != null) { + this.extra.remove(key); + } + return (A) this; } - public A removeFromExtra(java.util.Map> map) { - if(this.extra == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.extra != null){this.extra.remove(key);}}} return (A)this; + + public A removeFromExtra(java.util.Map> map) { + if (this.extra == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.extra != null) { + this.extra.remove(key); + } + } + } + return (A) this; } - public java.util.Map> getExtra() { + + public java.util.Map> getExtra() { return this.extra; } - public A withExtra(java.util.Map> extra) { - if (extra == null) { this.extra = null;} else {this.extra = new java.util.LinkedHashMap(extra);} return (A) this; + + public A withExtra( + java.util.Map> extra) { + if (extra == null) { + this.extra = null; + } else { + this.extra = new java.util.LinkedHashMap(extra); + } + return (A) this; } + public java.lang.Boolean hasExtra() { return this.extra != null; } - public A addToGroups(java.lang.Integer index,java.lang.String item) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} + + public A addToGroups(java.lang.Integer index, java.lang.String item) { + if (this.groups == null) { + this.groups = new java.util.ArrayList(); + } this.groups.add(index, item); - return (A)this; + return (A) this; } - public A setToGroups(java.lang.Integer index,java.lang.String item) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} - this.groups.set(index, item); return (A)this; + + public A setToGroups(java.lang.Integer index, java.lang.String item) { + if (this.groups == null) { + this.groups = new java.util.ArrayList(); + } + this.groups.set(index, item); + return (A) this; } + public A addToGroups(java.lang.String... items) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.groups.add(item);} return (A)this; + if (this.groups == null) { + this.groups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.groups.add(item); + } + return (A) this; } + public A addAllToGroups(java.util.Collection items) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.groups.add(item);} return (A)this; + if (this.groups == null) { + this.groups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.groups.add(item); + } + return (A) this; } + public A removeFromGroups(java.lang.String... items) { - for (java.lang.String item : items) {if (this.groups!= null){ this.groups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.groups != null) { + this.groups.remove(item); + } + } + return (A) this; } + public A removeAllFromGroups(java.util.Collection items) { - for (java.lang.String item : items) {if (this.groups!= null){ this.groups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.groups != null) { + this.groups.remove(item); + } + } + return (A) this; } + public java.util.List getGroups() { return this.groups; } + public java.lang.String getGroup(java.lang.Integer index) { return this.groups.get(index); } + public java.lang.String getFirstGroup() { return this.groups.get(0); } + public java.lang.String getLastGroup() { return this.groups.get(groups.size() - 1); } - public java.lang.String getMatchingGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: groups) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : groups) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: groups) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : groups) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withGroups(java.util.List groups) { - if (groups != null) {this.groups = new java.util.ArrayList(); for (java.lang.String item : groups){this.addToGroups(item);}} else { this.groups = null;} return (A) this; + if (groups != null) { + this.groups = new java.util.ArrayList(); + for (java.lang.String item : groups) { + this.addToGroups(item); + } + } else { + this.groups = null; + } + return (A) this; } + public A withGroups(java.lang.String... groups) { - if (this.groups != null) {this.groups.clear();} - if (groups != null) {for (java.lang.String item :groups){ this.addToGroups(item);}} return (A) this; + if (this.groups != null) { + this.groups.clear(); + } + if (groups != null) { + for (java.lang.String item : groups) { + this.addToGroups(item); + } + } + return (A) this; } + public java.lang.Boolean hasGroups() { return groups != null && !groups.isEmpty(); } + public A addNewGroup(java.lang.String original) { - return (A)addToGroups(new String(original)); + return (A) addToGroups(new String(original)); } - + /** * This method has been deprecated, please use method buildNonResourceAttributes instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NonResourceAttributes getNonResourceAttributes() { - return this.nonResourceAttributes!=null ?this.nonResourceAttributes.build():null; + return this.nonResourceAttributes != null ? this.nonResourceAttributes.build() : null; } + public io.kubernetes.client.openapi.models.V1NonResourceAttributes buildNonResourceAttributes() { - return this.nonResourceAttributes!=null ?this.nonResourceAttributes.build():null; + return this.nonResourceAttributes != null ? this.nonResourceAttributes.build() : null; } - public A withNonResourceAttributes(io.kubernetes.client.openapi.models.V1NonResourceAttributes nonResourceAttributes) { + + public A withNonResourceAttributes( + io.kubernetes.client.openapi.models.V1NonResourceAttributes nonResourceAttributes) { _visitables.get("nonResourceAttributes").remove(this.nonResourceAttributes); - if (nonResourceAttributes!=null){ this.nonResourceAttributes= new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder(nonResourceAttributes); _visitables.get("nonResourceAttributes").add(this.nonResourceAttributes);} return (A) this; + if (nonResourceAttributes != null) { + this.nonResourceAttributes = + new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder( + nonResourceAttributes); + _visitables.get("nonResourceAttributes").add(this.nonResourceAttributes); + } + return (A) this; } + public java.lang.Boolean hasNonResourceAttributes() { return this.nonResourceAttributes != null; } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.NonResourceAttributesNested withNewNonResourceAttributes() { - return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl.NonResourceAttributesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + withNewNonResourceAttributes() { + return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl + .NonResourceAttributesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.NonResourceAttributesNested withNewNonResourceAttributesLike(io.kubernetes.client.openapi.models.V1NonResourceAttributes item) { - return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl.NonResourceAttributesNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + withNewNonResourceAttributesLike( + io.kubernetes.client.openapi.models.V1NonResourceAttributes item) { + return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl + .NonResourceAttributesNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.NonResourceAttributesNested editNonResourceAttributes() { + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + editNonResourceAttributes() { return withNewNonResourceAttributesLike(getNonResourceAttributes()); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.NonResourceAttributesNested editOrNewNonResourceAttributes() { - return withNewNonResourceAttributesLike(getNonResourceAttributes() != null ? getNonResourceAttributes(): new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + editOrNewNonResourceAttributes() { + return withNewNonResourceAttributesLike( + getNonResourceAttributes() != null + ? getNonResourceAttributes() + : new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.NonResourceAttributesNested editOrNewNonResourceAttributesLike(io.kubernetes.client.openapi.models.V1NonResourceAttributes item) { - return withNewNonResourceAttributesLike(getNonResourceAttributes() != null ? getNonResourceAttributes(): item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + A> + editOrNewNonResourceAttributesLike( + io.kubernetes.client.openapi.models.V1NonResourceAttributes item) { + return withNewNonResourceAttributesLike( + getNonResourceAttributes() != null ? getNonResourceAttributes() : item); } - + /** * This method has been deprecated, please use method buildResourceAttributes instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ResourceAttributes getResourceAttributes() { - return this.resourceAttributes!=null ?this.resourceAttributes.build():null; + return this.resourceAttributes != null ? this.resourceAttributes.build() : null; } + public io.kubernetes.client.openapi.models.V1ResourceAttributes buildResourceAttributes() { - return this.resourceAttributes!=null ?this.resourceAttributes.build():null; + return this.resourceAttributes != null ? this.resourceAttributes.build() : null; } - public A withResourceAttributes(io.kubernetes.client.openapi.models.V1ResourceAttributes resourceAttributes) { + + public A withResourceAttributes( + io.kubernetes.client.openapi.models.V1ResourceAttributes resourceAttributes) { _visitables.get("resourceAttributes").remove(this.resourceAttributes); - if (resourceAttributes!=null){ this.resourceAttributes= new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder(resourceAttributes); _visitables.get("resourceAttributes").add(this.resourceAttributes);} return (A) this; + if (resourceAttributes != null) { + this.resourceAttributes = + new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder(resourceAttributes); + _visitables.get("resourceAttributes").add(this.resourceAttributes); + } + return (A) this; } + public java.lang.Boolean hasResourceAttributes() { return this.resourceAttributes != null; } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.ResourceAttributesNested withNewResourceAttributes() { - return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl.ResourceAttributesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + withNewResourceAttributes() { + return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl + .ResourceAttributesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.ResourceAttributesNested withNewResourceAttributesLike(io.kubernetes.client.openapi.models.V1ResourceAttributes item) { - return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl.ResourceAttributesNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + withNewResourceAttributesLike(io.kubernetes.client.openapi.models.V1ResourceAttributes item) { + return new io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluentImpl + .ResourceAttributesNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.ResourceAttributesNested editResourceAttributes() { + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + editResourceAttributes() { return withNewResourceAttributesLike(getResourceAttributes()); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.ResourceAttributesNested editOrNewResourceAttributes() { - return withNewResourceAttributesLike(getResourceAttributes() != null ? getResourceAttributes(): new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder().build()); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + editOrNewResourceAttributes() { + return withNewResourceAttributesLike( + getResourceAttributes() != null + ? getResourceAttributes() + : new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder().build()); } - public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.ResourceAttributesNested editOrNewResourceAttributesLike(io.kubernetes.client.openapi.models.V1ResourceAttributes item) { - return withNewResourceAttributesLike(getResourceAttributes() != null ? getResourceAttributes(): item); + + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .ResourceAttributesNested< + A> + editOrNewResourceAttributesLike( + io.kubernetes.client.openapi.models.V1ResourceAttributes item) { + return withNewResourceAttributesLike( + getResourceAttributes() != null ? getResourceAttributes() : item); } + public java.lang.String getUid() { return this.uid; } + public A withUid(java.lang.String uid) { - this.uid=uid; return (A) this; + this.uid = uid; + return (A) this; } + public java.lang.Boolean hasUid() { return this.uid != null; } - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original) { - return (A)withUid(new String(original)); + return (A) withUid(new String(original)); } + public java.lang.String getUser() { return this.user; } + public A withUser(java.lang.String user) { - this.user=user; return (A) this; + this.user = user; + return (A) this; } + public java.lang.Boolean hasUser() { return this.user != null; } - - /** - * Method is deprecated. use withUser instead. - */ + + /** Method is deprecated. use withUser instead. */ @java.lang.Deprecated public A withNewUser(java.lang.String original) { - return (A)withUser(new String(original)); + return (A) withUser(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SubjectAccessReviewSpecFluentImpl that = (V1SubjectAccessReviewSpecFluentImpl) o; - if (extra != null ? !extra.equals(that.extra) :that.extra != null) return false; - if (groups != null ? !groups.equals(that.groups) :that.groups != null) return false; - if (nonResourceAttributes != null ? !nonResourceAttributes.equals(that.nonResourceAttributes) :that.nonResourceAttributes != null) return false; - if (resourceAttributes != null ? !resourceAttributes.equals(that.resourceAttributes) :that.resourceAttributes != null) return false; - if (uid != null ? !uid.equals(that.uid) :that.uid != null) return false; - if (user != null ? !user.equals(that.user) :that.user != null) return false; + if (extra != null ? !extra.equals(that.extra) : that.extra != null) return false; + if (groups != null ? !groups.equals(that.groups) : that.groups != null) return false; + if (nonResourceAttributes != null + ? !nonResourceAttributes.equals(that.nonResourceAttributes) + : that.nonResourceAttributes != null) return false; + if (resourceAttributes != null + ? !resourceAttributes.equals(that.resourceAttributes) + : that.resourceAttributes != null) return false; + if (uid != null ? !uid.equals(that.uid) : that.uid != null) return false; + if (user != null ? !user.equals(that.user) : that.user != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(extra, groups, nonResourceAttributes, resourceAttributes, uid, user, super.hashCode()); + return java.util.Objects.hash( + extra, groups, nonResourceAttributes, resourceAttributes, uid, user, super.hashCode()); } - public class NonResourceAttributesNestedImpl extends io.kubernetes.client.openapi.models.V1NonResourceAttributesFluentImpl> implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.NonResourceAttributesNested,io.kubernetes.client.fluent.Nested{ - NonResourceAttributesNestedImpl(io.kubernetes.client.openapi.models.V1NonResourceAttributes item) { - this.builder = new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder(this, item); + + public class NonResourceAttributesNestedImpl + extends io.kubernetes.client.openapi.models.V1NonResourceAttributesFluentImpl< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + N>> + implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .NonResourceAttributesNested< + N>, + io.kubernetes.client.fluent.Nested { + NonResourceAttributesNestedImpl( + io.kubernetes.client.openapi.models.V1NonResourceAttributes item) { + this.builder = + new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder(this, item); } + NonResourceAttributesNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder(this); } + io.kubernetes.client.openapi.models.V1NonResourceAttributesBuilder builder; + public N and() { - return (N) V1SubjectAccessReviewSpecFluentImpl.this.withNonResourceAttributes(builder.build()); + return (N) + V1SubjectAccessReviewSpecFluentImpl.this.withNonResourceAttributes(builder.build()); } + public N endNonResourceAttributes() { return and(); } - } - public class ResourceAttributesNestedImpl extends io.kubernetes.client.openapi.models.V1ResourceAttributesFluentImpl> implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent.ResourceAttributesNested,io.kubernetes.client.fluent.Nested{ + + public class ResourceAttributesNestedImpl + extends io.kubernetes.client.openapi.models.V1ResourceAttributesFluentImpl< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .ResourceAttributesNested< + N>> + implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewSpecFluent + .ResourceAttributesNested< + N>, + io.kubernetes.client.fluent.Nested { ResourceAttributesNestedImpl(io.kubernetes.client.openapi.models.V1ResourceAttributes item) { - this.builder = new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder(this, item); } + ResourceAttributesNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder(this); } + io.kubernetes.client.openapi.models.V1ResourceAttributesBuilder builder; + public N and() { return (N) V1SubjectAccessReviewSpecFluentImpl.this.withResourceAttributes(builder.build()); } + public N endResourceAttributes() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewStatusBuilder.java index 9cb2cf2d79..b67241d879 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SubjectAccessReviewStatusBuilder extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SubjectAccessReviewStatusBuilder + extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluentImpl< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus, + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusBuilder> { public V1SubjectAccessReviewStatusBuilder() { this(false); } + public V1SubjectAccessReviewStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1SubjectAccessReviewStatus(), validationEnabled); } - public V1SubjectAccessReviewStatusBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent fluent) { + + public V1SubjectAccessReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent fluent) { this(fluent, false); } - public V1SubjectAccessReviewStatusBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SubjectAccessReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SubjectAccessReviewStatus(), validationEnabled); } - public V1SubjectAccessReviewStatusBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent fluent,io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus instance) { + + public V1SubjectAccessReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent fluent, + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus instance) { this(fluent, instance, false); } - public V1SubjectAccessReviewStatusBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent fluent,io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SubjectAccessReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent fluent, + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAllowed(instance.getAllowed()); fluent.withDenied(instance.getDenied()); @@ -29,13 +56,18 @@ public V1SubjectAccessReviewStatusBuilder(io.kubernetes.client.openapi.models.V1 fluent.withReason(instance.getReason()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1SubjectAccessReviewStatusBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus instance) { - this(instance,false); + + public V1SubjectAccessReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus instance) { + this(instance, false); } - public V1SubjectAccessReviewStatusBuilder(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SubjectAccessReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAllowed(instance.getAllowed()); this.withDenied(instance.getDenied()); @@ -44,10 +76,12 @@ public V1SubjectAccessReviewStatusBuilder(io.kubernetes.client.openapi.models.V1 this.withReason(instance.getReason()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus build() { V1SubjectAccessReviewStatus buildable = new V1SubjectAccessReviewStatus(); buildable.setAllowed(fluent.getAllowed()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus build() { buildable.setReason(fluent.getReason()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SubjectAccessReviewStatusBuilder that = (V1SubjectAccessReviewStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewStatusFluent.java index 4f5a3af670..f819a539fa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewStatusFluent.java @@ -1,38 +1,50 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SubjectAccessReviewStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SubjectAccessReviewStatusFluent< + A extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Boolean getAllowed(); + public A withAllowed(java.lang.Boolean allowed); + public java.lang.Boolean hasAllowed(); + public java.lang.Boolean getDenied(); + public A withDenied(java.lang.Boolean denied); + public java.lang.Boolean hasDenied(); + public java.lang.String getEvaluationError(); + public A withEvaluationError(java.lang.String evaluationError); + public java.lang.Boolean hasEvaluationError(); - - /** - * Method is deprecated. use withEvaluationError instead. - */ + + /** Method is deprecated. use withEvaluationError instead. */ @java.lang.Deprecated public A withNewEvaluationError(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewStatusFluentImpl.java index adea01f003..54d0ab465c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectAccessReviewStatusFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1SubjectAccessReviewStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent { + public V1SubjectAccessReviewStatusFluentImpl() {} - /** - * Generated - */ -public class V1SubjectAccessReviewStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatusFluent{ - public V1SubjectAccessReviewStatusFluentImpl() { - } - public V1SubjectAccessReviewStatusFluentImpl(io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus instance) { + public V1SubjectAccessReviewStatusFluentImpl( + io.kubernetes.client.openapi.models.V1SubjectAccessReviewStatus instance) { this.withAllowed(instance.getAllowed()); this.withDenied(instance.getDenied()); @@ -20,76 +28,91 @@ public V1SubjectAccessReviewStatusFluentImpl(io.kubernetes.client.openapi.models this.withEvaluationError(instance.getEvaluationError()); this.withReason(instance.getReason()); - } + private java.lang.Boolean allowed; private java.lang.Boolean denied; private java.lang.String evaluationError; private java.lang.String reason; + public java.lang.Boolean getAllowed() { return this.allowed; } + public A withAllowed(java.lang.Boolean allowed) { - this.allowed=allowed; return (A) this; + this.allowed = allowed; + return (A) this; } + public java.lang.Boolean hasAllowed() { return this.allowed != null; } + public java.lang.Boolean getDenied() { return this.denied; } + public A withDenied(java.lang.Boolean denied) { - this.denied=denied; return (A) this; + this.denied = denied; + return (A) this; } + public java.lang.Boolean hasDenied() { return this.denied != null; } + public java.lang.String getEvaluationError() { return this.evaluationError; } + public A withEvaluationError(java.lang.String evaluationError) { - this.evaluationError=evaluationError; return (A) this; + this.evaluationError = evaluationError; + return (A) this; } + public java.lang.Boolean hasEvaluationError() { return this.evaluationError != null; } - - /** - * Method is deprecated. use withEvaluationError instead. - */ + + /** Method is deprecated. use withEvaluationError instead. */ @java.lang.Deprecated public A withNewEvaluationError(java.lang.String original) { - return (A)withEvaluationError(new String(original)); + return (A) withEvaluationError(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SubjectAccessReviewStatusFluentImpl that = (V1SubjectAccessReviewStatusFluentImpl) o; - if (allowed != null ? !allowed.equals(that.allowed) :that.allowed != null) return false; - if (denied != null ? !denied.equals(that.denied) :that.denied != null) return false; - if (evaluationError != null ? !evaluationError.equals(that.evaluationError) :that.evaluationError != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; + if (allowed != null ? !allowed.equals(that.allowed) : that.allowed != null) return false; + if (denied != null ? !denied.equals(that.denied) : that.denied != null) return false; + if (evaluationError != null + ? !evaluationError.equals(that.evaluationError) + : that.evaluationError != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(allowed, denied, evaluationError, reason, super.hashCode()); + return java.util.Objects.hash(allowed, denied, evaluationError, reason, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectBuilder.java index e6580eadab..c5207daeef 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SubjectBuilder extends io.kubernetes.client.openapi.models.V1SubjectFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SubjectBuilder + extends io.kubernetes.client.openapi.models.V1SubjectFluentImpl< + io.kubernetes.client.openapi.models.V1SubjectBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Subject, + io.kubernetes.client.openapi.models.V1SubjectBuilder> { public V1SubjectBuilder() { this(false); } + public V1SubjectBuilder(java.lang.Boolean validationEnabled) { this(new V1Subject(), validationEnabled); } + public V1SubjectBuilder(io.kubernetes.client.openapi.models.V1SubjectFluent fluent) { this(fluent, false); } - public V1SubjectBuilder(io.kubernetes.client.openapi.models.V1SubjectFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SubjectBuilder( + io.kubernetes.client.openapi.models.V1SubjectFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Subject(), validationEnabled); } - public V1SubjectBuilder(io.kubernetes.client.openapi.models.V1SubjectFluent fluent,io.kubernetes.client.openapi.models.V1Subject instance) { + + public V1SubjectBuilder( + io.kubernetes.client.openapi.models.V1SubjectFluent fluent, + io.kubernetes.client.openapi.models.V1Subject instance) { this(fluent, instance, false); } - public V1SubjectBuilder(io.kubernetes.client.openapi.models.V1SubjectFluent fluent,io.kubernetes.client.openapi.models.V1Subject instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SubjectBuilder( + io.kubernetes.client.openapi.models.V1SubjectFluent fluent, + io.kubernetes.client.openapi.models.V1Subject instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiGroup(instance.getApiGroup()); fluent.withKind(instance.getKind()); @@ -29,13 +55,16 @@ public V1SubjectBuilder(io.kubernetes.client.openapi.models.V1SubjectFluent f fluent.withNamespace(instance.getNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1SubjectBuilder(io.kubernetes.client.openapi.models.V1Subject instance) { - this(instance,false); + this(instance, false); } - public V1SubjectBuilder(io.kubernetes.client.openapi.models.V1Subject instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SubjectBuilder( + io.kubernetes.client.openapi.models.V1Subject instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiGroup(instance.getApiGroup()); this.withKind(instance.getKind()); @@ -44,10 +73,12 @@ public V1SubjectBuilder(io.kubernetes.client.openapi.models.V1Subject instance,j this.withNamespace(instance.getNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SubjectFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Subject build() { V1Subject buildable = new V1Subject(); buildable.setApiGroup(fluent.getApiGroup()); @@ -56,18 +87,23 @@ public io.kubernetes.client.openapi.models.V1Subject build() { buildable.setNamespace(fluent.getNamespace()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SubjectBuilder that = (V1SubjectBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectFluent.java index d6c3192324..1a42a64339 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectFluent.java @@ -1,50 +1,57 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SubjectFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SubjectFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiGroup(); + public A withApiGroup(java.lang.String apiGroup); + public java.lang.Boolean hasApiGroup(); - - /** - * Method is deprecated. use withApiGroup instead. - */ + + /** Method is deprecated. use withApiGroup instead. */ @java.lang.Deprecated public A withNewApiGroup(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getNamespace(); + public A withNamespace(java.lang.String namespace); + public java.lang.Boolean hasNamespace(); - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectFluentImpl.java index cf7fbba497..d7ccb258f3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectFluentImpl.java @@ -1,17 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1SubjectFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SubjectFluent { + public V1SubjectFluentImpl() {} - /** - * Generated - */ -public class V1SubjectFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SubjectFluent{ - public V1SubjectFluentImpl() { - } public V1SubjectFluentImpl(io.kubernetes.client.openapi.models.V1Subject instance) { this.withApiGroup(instance.getApiGroup()); @@ -20,92 +26,102 @@ public V1SubjectFluentImpl(io.kubernetes.client.openapi.models.V1Subject instanc this.withName(instance.getName()); this.withNamespace(instance.getNamespace()); - } + private java.lang.String apiGroup; private java.lang.String kind; private java.lang.String name; private java.lang.String namespace; + public java.lang.String getApiGroup() { return this.apiGroup; } + public A withApiGroup(java.lang.String apiGroup) { - this.apiGroup=apiGroup; return (A) this; + this.apiGroup = apiGroup; + return (A) this; } + public java.lang.Boolean hasApiGroup() { return this.apiGroup != null; } - - /** - * Method is deprecated. use withApiGroup instead. - */ + + /** Method is deprecated. use withApiGroup instead. */ @java.lang.Deprecated public A withNewApiGroup(java.lang.String original) { - return (A)withApiGroup(new String(original)); + return (A) withApiGroup(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getNamespace() { return this.namespace; } + public A withNamespace(java.lang.String namespace) { - this.namespace=namespace; return (A) this; + this.namespace = namespace; + return (A) this; } + public java.lang.Boolean hasNamespace() { return this.namespace != null; } - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original) { - return (A)withNamespace(new String(original)); + return (A) withNamespace(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SubjectFluentImpl that = (V1SubjectFluentImpl) o; - if (apiGroup != null ? !apiGroup.equals(that.apiGroup) :that.apiGroup != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (namespace != null ? !namespace.equals(that.namespace) :that.namespace != null) return false; + if (apiGroup != null ? !apiGroup.equals(that.apiGroup) : that.apiGroup != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (namespace != null ? !namespace.equals(that.namespace) : that.namespace != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiGroup, kind, name, namespace, super.hashCode()); + return java.util.Objects.hash(apiGroup, kind, name, namespace, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectRulesReviewStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectRulesReviewStatusBuilder.java index 99ac5bf100..07dc837c4d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectRulesReviewStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectRulesReviewStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SubjectRulesReviewStatusBuilder extends io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SubjectRulesReviewStatusBuilder + extends io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl< + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus, + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusBuilder> { public V1SubjectRulesReviewStatusBuilder() { this(false); } + public V1SubjectRulesReviewStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1SubjectRulesReviewStatus(), validationEnabled); } - public V1SubjectRulesReviewStatusBuilder(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent fluent) { + + public V1SubjectRulesReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent fluent) { this(fluent, false); } - public V1SubjectRulesReviewStatusBuilder(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SubjectRulesReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1SubjectRulesReviewStatus(), validationEnabled); } - public V1SubjectRulesReviewStatusBuilder(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent fluent,io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus instance) { + + public V1SubjectRulesReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent fluent, + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus instance) { this(fluent, instance, false); } - public V1SubjectRulesReviewStatusBuilder(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent fluent,io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SubjectRulesReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent fluent, + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withEvaluationError(instance.getEvaluationError()); fluent.withIncomplete(instance.getIncomplete()); @@ -29,13 +56,18 @@ public V1SubjectRulesReviewStatusBuilder(io.kubernetes.client.openapi.models.V1S fluent.withResourceRules(instance.getResourceRules()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1SubjectRulesReviewStatusBuilder(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus instance) { - this(instance,false); + + public V1SubjectRulesReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus instance) { + this(instance, false); } - public V1SubjectRulesReviewStatusBuilder(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SubjectRulesReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withEvaluationError(instance.getEvaluationError()); this.withIncomplete(instance.getIncomplete()); @@ -44,10 +76,12 @@ public V1SubjectRulesReviewStatusBuilder(io.kubernetes.client.openapi.models.V1S this.withResourceRules(instance.getResourceRules()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus build() { V1SubjectRulesReviewStatus buildable = new V1SubjectRulesReviewStatus(); buildable.setEvaluationError(fluent.getEvaluationError()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus build() { buildable.setResourceRules(fluent.getResourceRules()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SubjectRulesReviewStatusBuilder that = (V1SubjectRulesReviewStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectRulesReviewStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectRulesReviewStatusFluent.java index fbfb602512..72c054ca72 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectRulesReviewStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectRulesReviewStatusFluent.java @@ -1,104 +1,226 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SubjectRulesReviewStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SubjectRulesReviewStatusFluent< + A extends io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getEvaluationError(); + public A withEvaluationError(java.lang.String evaluationError); + public java.lang.Boolean hasEvaluationError(); - - /** - * Method is deprecated. use withEvaluationError instead. - */ + + /** Method is deprecated. use withEvaluationError instead. */ @java.lang.Deprecated public A withNewEvaluationError(java.lang.String original); + public java.lang.Boolean getIncomplete(); + public A withIncomplete(java.lang.Boolean incomplete); + public java.lang.Boolean hasIncomplete(); - public A addToNonResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NonResourceRule item); - public A setToNonResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NonResourceRule item); + + public A addToNonResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NonResourceRule item); + + public A setToNonResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NonResourceRule item); + public A addToNonResourceRules(io.kubernetes.client.openapi.models.V1NonResourceRule... items); - public A addAllToNonResourceRules(java.util.Collection items); - public A removeFromNonResourceRules(io.kubernetes.client.openapi.models.V1NonResourceRule... items); - public A removeAllFromNonResourceRules(java.util.Collection items); - public A removeMatchingFromNonResourceRules(java.util.function.Predicate predicate); - + + public A addAllToNonResourceRules( + java.util.Collection items); + + public A removeFromNonResourceRules( + io.kubernetes.client.openapi.models.V1NonResourceRule... items); + + public A removeAllFromNonResourceRules( + java.util.Collection items); + + public A removeMatchingFromNonResourceRules( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildNonResourceRules instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getNonResourceRules(); - public java.util.List buildNonResourceRules(); - public io.kubernetes.client.openapi.models.V1NonResourceRule buildNonResourceRule(java.lang.Integer index); + public java.util.List + getNonResourceRules(); + + public java.util.List + buildNonResourceRules(); + + public io.kubernetes.client.openapi.models.V1NonResourceRule buildNonResourceRule( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1NonResourceRule buildFirstNonResourceRule(); + public io.kubernetes.client.openapi.models.V1NonResourceRule buildLastNonResourceRule(); - public io.kubernetes.client.openapi.models.V1NonResourceRule buildMatchingNonResourceRule(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingNonResourceRule(java.util.function.Predicate predicate); - public A withNonResourceRules(java.util.List nonResourceRules); - public A withNonResourceRules(io.kubernetes.client.openapi.models.V1NonResourceRule... nonResourceRules); + + public io.kubernetes.client.openapi.models.V1NonResourceRule buildMatchingNonResourceRule( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingNonResourceRule( + java.util.function.Predicate + predicate); + + public A withNonResourceRules( + java.util.List nonResourceRules); + + public A withNonResourceRules( + io.kubernetes.client.openapi.models.V1NonResourceRule... nonResourceRules); + public java.lang.Boolean hasNonResourceRules(); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested addNewNonResourceRule(); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested addNewNonResourceRuleLike(io.kubernetes.client.openapi.models.V1NonResourceRule item); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested setNewNonResourceRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NonResourceRule item); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested editNonResourceRule(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested editFirstNonResourceRule(); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested editLastNonResourceRule(); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested editMatchingNonResourceRule(java.util.function.Predicate predicate); - public A addToResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ResourceRule item); - public A setToResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ResourceRule item); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + addNewNonResourceRule(); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + addNewNonResourceRuleLike(io.kubernetes.client.openapi.models.V1NonResourceRule item); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + setNewNonResourceRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NonResourceRule item); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + editNonResourceRule(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + editFirstNonResourceRule(); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + editLastNonResourceRule(); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + editMatchingNonResourceRule( + java.util.function.Predicate + predicate); + + public A addToResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceRule item); + + public A setToResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceRule item); + public A addToResourceRules(io.kubernetes.client.openapi.models.V1ResourceRule... items); - public A addAllToResourceRules(java.util.Collection items); + + public A addAllToResourceRules( + java.util.Collection items); + public A removeFromResourceRules(io.kubernetes.client.openapi.models.V1ResourceRule... items); - public A removeAllFromResourceRules(java.util.Collection items); - public A removeMatchingFromResourceRules(java.util.function.Predicate predicate); - + + public A removeAllFromResourceRules( + java.util.Collection items); + + public A removeMatchingFromResourceRules( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildResourceRules instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getResourceRules(); + public java.util.List buildResourceRules(); - public io.kubernetes.client.openapi.models.V1ResourceRule buildResourceRule(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ResourceRule buildResourceRule( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ResourceRule buildFirstResourceRule(); + public io.kubernetes.client.openapi.models.V1ResourceRule buildLastResourceRule(); - public io.kubernetes.client.openapi.models.V1ResourceRule buildMatchingResourceRule(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingResourceRule(java.util.function.Predicate predicate); - public A withResourceRules(java.util.List resourceRules); + + public io.kubernetes.client.openapi.models.V1ResourceRule buildMatchingResourceRule( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingResourceRule( + java.util.function.Predicate + predicate); + + public A withResourceRules( + java.util.List resourceRules); + public A withResourceRules(io.kubernetes.client.openapi.models.V1ResourceRule... resourceRules); + public java.lang.Boolean hasResourceRules(); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested addNewResourceRule(); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested addNewResourceRuleLike(io.kubernetes.client.openapi.models.V1ResourceRule item); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested setNewResourceRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ResourceRule item); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested editResourceRule(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested editFirstResourceRule(); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested editLastResourceRule(); - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested editMatchingResourceRule(java.util.function.Predicate predicate); - public interface NonResourceRulesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NonResourceRuleFluent>{ + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + addNewResourceRule(); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + addNewResourceRuleLike(io.kubernetes.client.openapi.models.V1ResourceRule item); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + setNewResourceRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceRule item); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + editResourceRule(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + editFirstResourceRule(); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + editLastResourceRule(); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + editMatchingResourceRule( + java.util.function.Predicate + predicate); + + public interface NonResourceRulesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NonResourceRuleFluent< + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + N>> { public N and(); + public N endNonResourceRule(); - } - public interface ResourceRulesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ResourceRuleFluent>{ + + public interface ResourceRulesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ResourceRuleFluent< + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .ResourceRulesNested< + N>> { public N and(); + public N endResourceRule(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectRulesReviewStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectRulesReviewStatusFluentImpl.java index 35a86e8cd1..ca94aa1cb0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectRulesReviewStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SubjectRulesReviewStatusFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1SubjectRulesReviewStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent{ - public V1SubjectRulesReviewStatusFluentImpl() { - } - public V1SubjectRulesReviewStatusFluentImpl(io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus instance) { + +/** Generated */ +public class V1SubjectRulesReviewStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent { + public V1SubjectRulesReviewStatusFluentImpl() {} + + public V1SubjectRulesReviewStatusFluentImpl( + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatus instance) { this.withEvaluationError(instance.getEvaluationError()); this.withIncomplete(instance.getIncomplete()); @@ -28,66 +31,144 @@ public V1SubjectRulesReviewStatusFluentImpl(io.kubernetes.client.openapi.models. this.withNonResourceRules(instance.getNonResourceRules()); this.withResourceRules(instance.getResourceRules()); - } + private java.lang.String evaluationError; private java.lang.Boolean incomplete; - private java.util.ArrayList nonResourceRules; - private java.util.ArrayList resourceRules; + private java.util.ArrayList + nonResourceRules; + private java.util.ArrayList + resourceRules; + public java.lang.String getEvaluationError() { return this.evaluationError; } + public A withEvaluationError(java.lang.String evaluationError) { - this.evaluationError=evaluationError; return (A) this; + this.evaluationError = evaluationError; + return (A) this; } + public java.lang.Boolean hasEvaluationError() { return this.evaluationError != null; } - - /** - * Method is deprecated. use withEvaluationError instead. - */ + + /** Method is deprecated. use withEvaluationError instead. */ @java.lang.Deprecated public A withNewEvaluationError(java.lang.String original) { - return (A)withEvaluationError(new String(original)); + return (A) withEvaluationError(new String(original)); } + public java.lang.Boolean getIncomplete() { return this.incomplete; } + public A withIncomplete(java.lang.Boolean incomplete) { - this.incomplete=incomplete; return (A) this; + this.incomplete = incomplete; + return (A) this; } + public java.lang.Boolean hasIncomplete() { return this.incomplete != null; } - public A addToNonResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NonResourceRule item) { - if (this.nonResourceRules == null) {this.nonResourceRules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(item);_visitables.get("nonResourceRules").add(index >= 0 ? index : _visitables.get("nonResourceRules").size(), builder);this.nonResourceRules.add(index >= 0 ? index : nonResourceRules.size(), builder); return (A)this; + + public A addToNonResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NonResourceRule item) { + if (this.nonResourceRules == null) { + this.nonResourceRules = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(item); + _visitables + .get("nonResourceRules") + .add(index >= 0 ? index : _visitables.get("nonResourceRules").size(), builder); + this.nonResourceRules.add(index >= 0 ? index : nonResourceRules.size(), builder); + return (A) this; } - public A setToNonResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NonResourceRule item) { - if (this.nonResourceRules == null) {this.nonResourceRules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(item); - if (index < 0 || index >= _visitables.get("nonResourceRules").size()) { _visitables.get("nonResourceRules").add(builder); } else { _visitables.get("nonResourceRules").set(index, builder);} - if (index < 0 || index >= nonResourceRules.size()) { nonResourceRules.add(builder); } else { nonResourceRules.set(index, builder);} - return (A)this; + + public A setToNonResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NonResourceRule item) { + if (this.nonResourceRules == null) { + this.nonResourceRules = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(item); + if (index < 0 || index >= _visitables.get("nonResourceRules").size()) { + _visitables.get("nonResourceRules").add(builder); + } else { + _visitables.get("nonResourceRules").set(index, builder); + } + if (index < 0 || index >= nonResourceRules.size()) { + nonResourceRules.add(builder); + } else { + nonResourceRules.set(index, builder); + } + return (A) this; } + public A addToNonResourceRules(io.kubernetes.client.openapi.models.V1NonResourceRule... items) { - if (this.nonResourceRules == null) {this.nonResourceRules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NonResourceRule item : items) {io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(item);_visitables.get("nonResourceRules").add(builder);this.nonResourceRules.add(builder);} return (A)this; + if (this.nonResourceRules == null) { + this.nonResourceRules = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NonResourceRule item : items) { + io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(item); + _visitables.get("nonResourceRules").add(builder); + this.nonResourceRules.add(builder); + } + return (A) this; } - public A addAllToNonResourceRules(java.util.Collection items) { - if (this.nonResourceRules == null) {this.nonResourceRules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1NonResourceRule item : items) {io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(item);_visitables.get("nonResourceRules").add(builder);this.nonResourceRules.add(builder);} return (A)this; + + public A addAllToNonResourceRules( + java.util.Collection items) { + if (this.nonResourceRules == null) { + this.nonResourceRules = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1NonResourceRule item : items) { + io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(item); + _visitables.get("nonResourceRules").add(builder); + this.nonResourceRules.add(builder); + } + return (A) this; } - public A removeFromNonResourceRules(io.kubernetes.client.openapi.models.V1NonResourceRule... items) { - for (io.kubernetes.client.openapi.models.V1NonResourceRule item : items) {io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(item);_visitables.get("nonResourceRules").remove(builder);if (this.nonResourceRules != null) {this.nonResourceRules.remove(builder);}} return (A)this; + + public A removeFromNonResourceRules( + io.kubernetes.client.openapi.models.V1NonResourceRule... items) { + for (io.kubernetes.client.openapi.models.V1NonResourceRule item : items) { + io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(item); + _visitables.get("nonResourceRules").remove(builder); + if (this.nonResourceRules != null) { + this.nonResourceRules.remove(builder); + } + } + return (A) this; } - public A removeAllFromNonResourceRules(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1NonResourceRule item : items) {io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder = new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(item);_visitables.get("nonResourceRules").remove(builder);if (this.nonResourceRules != null) {this.nonResourceRules.remove(builder);}} return (A)this; + + public A removeAllFromNonResourceRules( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1NonResourceRule item : items) { + io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(item); + _visitables.get("nonResourceRules").remove(builder); + if (this.nonResourceRules != null) { + this.nonResourceRules.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromNonResourceRules(java.util.function.Predicate predicate) { + + public A removeMatchingFromNonResourceRules( + java.util.function.Predicate + predicate) { if (nonResourceRules == null) return (A) this; - final Iterator each = nonResourceRules.iterator(); + final Iterator each = + nonResourceRules.iterator(); final List visitables = _visitables.get("nonResourceRules"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder = each.next(); @@ -96,104 +177,260 @@ public A removeMatchingFromNonResourceRules(java.util.function.Predicate getNonResourceRules() { + public java.util.List + getNonResourceRules() { return nonResourceRules != null ? build(nonResourceRules) : null; } - public java.util.List buildNonResourceRules() { + + public java.util.List + buildNonResourceRules() { return nonResourceRules != null ? build(nonResourceRules) : null; } - public io.kubernetes.client.openapi.models.V1NonResourceRule buildNonResourceRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1NonResourceRule buildNonResourceRule( + java.lang.Integer index) { return this.nonResourceRules.get(index).build(); } + public io.kubernetes.client.openapi.models.V1NonResourceRule buildFirstNonResourceRule() { return this.nonResourceRules.get(0).build(); } + public io.kubernetes.client.openapi.models.V1NonResourceRule buildLastNonResourceRule() { return this.nonResourceRules.get(nonResourceRules.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1NonResourceRule buildMatchingNonResourceRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder item: nonResourceRules) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1NonResourceRule buildMatchingNonResourceRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder item : nonResourceRules) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingNonResourceRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder item: nonResourceRules) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingNonResourceRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder item : nonResourceRules) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withNonResourceRules(java.util.List nonResourceRules) { - if (this.nonResourceRules != null) { _visitables.get("nonResourceRules").removeAll(this.nonResourceRules);} - if (nonResourceRules != null) {this.nonResourceRules = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1NonResourceRule item : nonResourceRules){this.addToNonResourceRules(item);}} else { this.nonResourceRules = null;} return (A) this; + + public A withNonResourceRules( + java.util.List nonResourceRules) { + if (this.nonResourceRules != null) { + _visitables.get("nonResourceRules").removeAll(this.nonResourceRules); + } + if (nonResourceRules != null) { + this.nonResourceRules = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1NonResourceRule item : nonResourceRules) { + this.addToNonResourceRules(item); + } + } else { + this.nonResourceRules = null; + } + return (A) this; } - public A withNonResourceRules(io.kubernetes.client.openapi.models.V1NonResourceRule... nonResourceRules) { - if (this.nonResourceRules != null) {this.nonResourceRules.clear();} - if (nonResourceRules != null) {for (io.kubernetes.client.openapi.models.V1NonResourceRule item :nonResourceRules){ this.addToNonResourceRules(item);}} return (A) this; + + public A withNonResourceRules( + io.kubernetes.client.openapi.models.V1NonResourceRule... nonResourceRules) { + if (this.nonResourceRules != null) { + this.nonResourceRules.clear(); + } + if (nonResourceRules != null) { + for (io.kubernetes.client.openapi.models.V1NonResourceRule item : nonResourceRules) { + this.addToNonResourceRules(item); + } + } + return (A) this; } + public java.lang.Boolean hasNonResourceRules() { return nonResourceRules != null && !nonResourceRules.isEmpty(); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested addNewNonResourceRule() { - return new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl.NonResourceRulesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + addNewNonResourceRule() { + return new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl + .NonResourceRulesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested addNewNonResourceRuleLike(io.kubernetes.client.openapi.models.V1NonResourceRule item) { - return new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl.NonResourceRulesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + addNewNonResourceRuleLike(io.kubernetes.client.openapi.models.V1NonResourceRule item) { + return new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl + .NonResourceRulesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested setNewNonResourceRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NonResourceRule item) { - return new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl.NonResourceRulesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + setNewNonResourceRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NonResourceRule item) { + return new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl + .NonResourceRulesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested editNonResourceRule(java.lang.Integer index) { - if (nonResourceRules.size() <= index) throw new RuntimeException("Can't edit nonResourceRules. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + editNonResourceRule(java.lang.Integer index) { + if (nonResourceRules.size() <= index) + throw new RuntimeException("Can't edit nonResourceRules. Index exceeds size."); return setNewNonResourceRuleLike(index, buildNonResourceRule(index)); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested editFirstNonResourceRule() { - if (nonResourceRules.size() == 0) throw new RuntimeException("Can't edit first nonResourceRules. The list is empty."); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + editFirstNonResourceRule() { + if (nonResourceRules.size() == 0) + throw new RuntimeException("Can't edit first nonResourceRules. The list is empty."); return setNewNonResourceRuleLike(0, buildNonResourceRule(0)); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested editLastNonResourceRule() { + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + editLastNonResourceRule() { int index = nonResourceRules.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last nonResourceRules. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last nonResourceRules. The list is empty."); return setNewNonResourceRuleLike(index, buildNonResourceRule(index)); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested editMatchingNonResourceRule(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + A> + editMatchingNonResourceRule( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder = new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(item);_visitables.get("resourceRules").add(index >= 0 ? index : _visitables.get("resourceRules").size(), builder);this.resourceRules.add(index >= 0 ? index : resourceRules.size(), builder); return (A)this; + + public A addToResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceRule item) { + if (this.resourceRules == null) { + this.resourceRules = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(item); + _visitables + .get("resourceRules") + .add(index >= 0 ? index : _visitables.get("resourceRules").size(), builder); + this.resourceRules.add(index >= 0 ? index : resourceRules.size(), builder); + return (A) this; } - public A setToResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ResourceRule item) { - if (this.resourceRules == null) {this.resourceRules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder = new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(item); - if (index < 0 || index >= _visitables.get("resourceRules").size()) { _visitables.get("resourceRules").add(builder); } else { _visitables.get("resourceRules").set(index, builder);} - if (index < 0 || index >= resourceRules.size()) { resourceRules.add(builder); } else { resourceRules.set(index, builder);} - return (A)this; + + public A setToResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceRule item) { + if (this.resourceRules == null) { + this.resourceRules = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(item); + if (index < 0 || index >= _visitables.get("resourceRules").size()) { + _visitables.get("resourceRules").add(builder); + } else { + _visitables.get("resourceRules").set(index, builder); + } + if (index < 0 || index >= resourceRules.size()) { + resourceRules.add(builder); + } else { + resourceRules.set(index, builder); + } + return (A) this; } + public A addToResourceRules(io.kubernetes.client.openapi.models.V1ResourceRule... items) { - if (this.resourceRules == null) {this.resourceRules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ResourceRule item : items) {io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder = new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(item);_visitables.get("resourceRules").add(builder);this.resourceRules.add(builder);} return (A)this; + if (this.resourceRules == null) { + this.resourceRules = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ResourceRule item : items) { + io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(item); + _visitables.get("resourceRules").add(builder); + this.resourceRules.add(builder); + } + return (A) this; } - public A addAllToResourceRules(java.util.Collection items) { - if (this.resourceRules == null) {this.resourceRules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ResourceRule item : items) {io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder = new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(item);_visitables.get("resourceRules").add(builder);this.resourceRules.add(builder);} return (A)this; + + public A addAllToResourceRules( + java.util.Collection items) { + if (this.resourceRules == null) { + this.resourceRules = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ResourceRule item : items) { + io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(item); + _visitables.get("resourceRules").add(builder); + this.resourceRules.add(builder); + } + return (A) this; } + public A removeFromResourceRules(io.kubernetes.client.openapi.models.V1ResourceRule... items) { - for (io.kubernetes.client.openapi.models.V1ResourceRule item : items) {io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder = new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(item);_visitables.get("resourceRules").remove(builder);if (this.resourceRules != null) {this.resourceRules.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ResourceRule item : items) { + io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(item); + _visitables.get("resourceRules").remove(builder); + if (this.resourceRules != null) { + this.resourceRules.remove(builder); + } + } + return (A) this; } - public A removeAllFromResourceRules(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ResourceRule item : items) {io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder = new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(item);_visitables.get("resourceRules").remove(builder);if (this.resourceRules != null) {this.resourceRules.remove(builder);}} return (A)this; + + public A removeAllFromResourceRules( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ResourceRule item : items) { + io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(item); + _visitables.get("resourceRules").remove(builder); + if (this.resourceRules != null) { + this.resourceRules.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromResourceRules(java.util.function.Predicate predicate) { + + public A removeMatchingFromResourceRules( + java.util.function.Predicate + predicate) { if (resourceRules == null) return (A) this; - final Iterator each = resourceRules.iterator(); + final Iterator each = + resourceRules.iterator(); final List visitables = _visitables.get("resourceRules"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder = each.next(); @@ -202,126 +439,230 @@ public A removeMatchingFromResourceRules(java.util.function.Predicate getResourceRules() { return resourceRules != null ? build(resourceRules) : null; } + public java.util.List buildResourceRules() { return resourceRules != null ? build(resourceRules) : null; } - public io.kubernetes.client.openapi.models.V1ResourceRule buildResourceRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ResourceRule buildResourceRule( + java.lang.Integer index) { return this.resourceRules.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ResourceRule buildFirstResourceRule() { return this.resourceRules.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ResourceRule buildLastResourceRule() { return this.resourceRules.get(resourceRules.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ResourceRule buildMatchingResourceRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ResourceRuleBuilder item: resourceRules) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ResourceRule buildMatchingResourceRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ResourceRuleBuilder item : resourceRules) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingResourceRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ResourceRuleBuilder item: resourceRules) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingResourceRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ResourceRuleBuilder item : resourceRules) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withResourceRules(java.util.List resourceRules) { - if (this.resourceRules != null) { _visitables.get("resourceRules").removeAll(this.resourceRules);} - if (resourceRules != null) {this.resourceRules = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ResourceRule item : resourceRules){this.addToResourceRules(item);}} else { this.resourceRules = null;} return (A) this; + + public A withResourceRules( + java.util.List resourceRules) { + if (this.resourceRules != null) { + _visitables.get("resourceRules").removeAll(this.resourceRules); + } + if (resourceRules != null) { + this.resourceRules = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ResourceRule item : resourceRules) { + this.addToResourceRules(item); + } + } else { + this.resourceRules = null; + } + return (A) this; } + public A withResourceRules(io.kubernetes.client.openapi.models.V1ResourceRule... resourceRules) { - if (this.resourceRules != null) {this.resourceRules.clear();} - if (resourceRules != null) {for (io.kubernetes.client.openapi.models.V1ResourceRule item :resourceRules){ this.addToResourceRules(item);}} return (A) this; + if (this.resourceRules != null) { + this.resourceRules.clear(); + } + if (resourceRules != null) { + for (io.kubernetes.client.openapi.models.V1ResourceRule item : resourceRules) { + this.addToResourceRules(item); + } + } + return (A) this; } + public java.lang.Boolean hasResourceRules() { return resourceRules != null && !resourceRules.isEmpty(); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested addNewResourceRule() { - return new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl.ResourceRulesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + addNewResourceRule() { + return new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl + .ResourceRulesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested addNewResourceRuleLike(io.kubernetes.client.openapi.models.V1ResourceRule item) { - return new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl.ResourceRulesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + addNewResourceRuleLike(io.kubernetes.client.openapi.models.V1ResourceRule item) { + return new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl + .ResourceRulesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested setNewResourceRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ResourceRule item) { - return new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl.ResourceRulesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + setNewResourceRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceRule item) { + return new io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluentImpl + .ResourceRulesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested editResourceRule(java.lang.Integer index) { - if (resourceRules.size() <= index) throw new RuntimeException("Can't edit resourceRules. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + editResourceRule(java.lang.Integer index) { + if (resourceRules.size() <= index) + throw new RuntimeException("Can't edit resourceRules. Index exceeds size."); return setNewResourceRuleLike(index, buildResourceRule(index)); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested editFirstResourceRule() { - if (resourceRules.size() == 0) throw new RuntimeException("Can't edit first resourceRules. The list is empty."); + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + editFirstResourceRule() { + if (resourceRules.size() == 0) + throw new RuntimeException("Can't edit first resourceRules. The list is empty."); return setNewResourceRuleLike(0, buildResourceRule(0)); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested editLastResourceRule() { + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + editLastResourceRule() { int index = resourceRules.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last resourceRules. The list is empty."); return setNewResourceRuleLike(index, buildResourceRule(index)); } - public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested editMatchingResourceRule(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested + editMatchingResourceRule( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1NonResourceRuleFluentImpl> implements io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.NonResourceRulesNested,io.kubernetes.client.fluent.Nested{ - NonResourceRulesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1NonResourceRule item) { + + public class NonResourceRulesNestedImpl + extends io.kubernetes.client.openapi.models.V1NonResourceRuleFluentImpl< + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + N>> + implements io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .NonResourceRulesNested< + N>, + io.kubernetes.client.fluent.Nested { + NonResourceRulesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1NonResourceRule item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(this, item); } + NonResourceRulesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder(this); } + io.kubernetes.client.openapi.models.V1NonResourceRuleBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1SubjectRulesReviewStatusFluentImpl.this.setToNonResourceRules(index,builder.build()); + return (N) + V1SubjectRulesReviewStatusFluentImpl.this.setToNonResourceRules(index, builder.build()); } + public N endNonResourceRule() { return and(); } - } - public class ResourceRulesNestedImpl extends io.kubernetes.client.openapi.models.V1ResourceRuleFluentImpl> implements io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested,io.kubernetes.client.fluent.Nested{ - ResourceRulesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ResourceRule item) { + + public class ResourceRulesNestedImpl + extends io.kubernetes.client.openapi.models.V1ResourceRuleFluentImpl< + io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent.ResourceRulesNested< + N>> + implements io.kubernetes.client.openapi.models.V1SubjectRulesReviewStatusFluent + .ResourceRulesNested< + N>, + io.kubernetes.client.fluent.Nested { + ResourceRulesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ResourceRule item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(this, item); } + ResourceRulesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ResourceRuleBuilder(this); } + io.kubernetes.client.openapi.models.V1ResourceRuleBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1SubjectRulesReviewStatusFluentImpl.this.setToResourceRules(index,builder.build()); + return (N) + V1SubjectRulesReviewStatusFluentImpl.this.setToResourceRules(index, builder.build()); } + public N endResourceRule() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SysctlBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SysctlBuilder.java index 399b513afa..7e36900b21 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SysctlBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SysctlBuilder.java @@ -1,63 +1,99 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1SysctlBuilder extends io.kubernetes.client.openapi.models.V1SysctlFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1SysctlBuilder + extends io.kubernetes.client.openapi.models.V1SysctlFluentImpl< + io.kubernetes.client.openapi.models.V1SysctlBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Sysctl, + io.kubernetes.client.openapi.models.V1SysctlBuilder> { public V1SysctlBuilder() { this(false); } + public V1SysctlBuilder(java.lang.Boolean validationEnabled) { this(new V1Sysctl(), validationEnabled); } + public V1SysctlBuilder(io.kubernetes.client.openapi.models.V1SysctlFluent fluent) { this(fluent, false); } - public V1SysctlBuilder(io.kubernetes.client.openapi.models.V1SysctlFluent fluent,java.lang.Boolean validationEnabled) { + + public V1SysctlBuilder( + io.kubernetes.client.openapi.models.V1SysctlFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Sysctl(), validationEnabled); } - public V1SysctlBuilder(io.kubernetes.client.openapi.models.V1SysctlFluent fluent,io.kubernetes.client.openapi.models.V1Sysctl instance) { + + public V1SysctlBuilder( + io.kubernetes.client.openapi.models.V1SysctlFluent fluent, + io.kubernetes.client.openapi.models.V1Sysctl instance) { this(fluent, instance, false); } - public V1SysctlBuilder(io.kubernetes.client.openapi.models.V1SysctlFluent fluent,io.kubernetes.client.openapi.models.V1Sysctl instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1SysctlBuilder( + io.kubernetes.client.openapi.models.V1SysctlFluent fluent, + io.kubernetes.client.openapi.models.V1Sysctl instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1SysctlBuilder(io.kubernetes.client.openapi.models.V1Sysctl instance) { - this(instance,false); + this(instance, false); } - public V1SysctlBuilder(io.kubernetes.client.openapi.models.V1Sysctl instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1SysctlBuilder( + io.kubernetes.client.openapi.models.V1Sysctl instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1SysctlFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Sysctl build() { V1Sysctl buildable = new V1Sysctl(); buildable.setName(fluent.getName()); buildable.setValue(fluent.getValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1SysctlBuilder that = (V1SysctlBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SysctlFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SysctlFluent.java index 52c6cf6c62..0f4ec5bb27 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SysctlFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SysctlFluent.java @@ -1,32 +1,37 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1SysctlFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1SysctlFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getValue(); + public A withValue(java.lang.String value); + public java.lang.Boolean hasValue(); - - /** - * Method is deprecated. use withValue instead. - */ + + /** Method is deprecated. use withValue instead. */ @java.lang.Deprecated public A withNewValue(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SysctlFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SysctlFluentImpl.java index 3355fb26eb..35c4a73a42 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SysctlFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1SysctlFluentImpl.java @@ -1,69 +1,80 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1SysctlFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1SysctlFluent { + public V1SysctlFluentImpl() {} - /** - * Generated - */ -public class V1SysctlFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1SysctlFluent{ - public V1SysctlFluentImpl() { - } public V1SysctlFluentImpl(io.kubernetes.client.openapi.models.V1Sysctl instance) { this.withName(instance.getName()); this.withValue(instance.getValue()); - } + private java.lang.String name; private java.lang.String value; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getValue() { return this.value; } + public A withValue(java.lang.String value) { - this.value=value; return (A) this; + this.value = value; + return (A) this; } + public java.lang.Boolean hasValue() { return this.value != null; } - - /** - * Method is deprecated. use withValue instead. - */ + + /** Method is deprecated. use withValue instead. */ @java.lang.Deprecated public A withNewValue(java.lang.String original) { - return (A)withValue(new String(original)); + return (A) withValue(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1SysctlFluentImpl that = (V1SysctlFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (value != null ? !value.equals(that.value) :that.value != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (value != null ? !value.equals(that.value) : that.value != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, value, super.hashCode()); + return java.util.Objects.hash(name, value, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TCPSocketActionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TCPSocketActionBuilder.java index 39c83e45eb..238f3d7f63 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TCPSocketActionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TCPSocketActionBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1TCPSocketActionBuilder extends io.kubernetes.client.openapi.models.V1TCPSocketActionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1TCPSocketActionBuilder + extends io.kubernetes.client.openapi.models.V1TCPSocketActionFluentImpl< + io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1TCPSocketAction, + io.kubernetes.client.openapi.models.V1TCPSocketActionBuilder> { public V1TCPSocketActionBuilder() { this(false); } + public V1TCPSocketActionBuilder(java.lang.Boolean validationEnabled) { this(new V1TCPSocketAction(), validationEnabled); } - public V1TCPSocketActionBuilder(io.kubernetes.client.openapi.models.V1TCPSocketActionFluent fluent) { + + public V1TCPSocketActionBuilder( + io.kubernetes.client.openapi.models.V1TCPSocketActionFluent fluent) { this(fluent, false); } - public V1TCPSocketActionBuilder(io.kubernetes.client.openapi.models.V1TCPSocketActionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1TCPSocketActionBuilder( + io.kubernetes.client.openapi.models.V1TCPSocketActionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1TCPSocketAction(), validationEnabled); } - public V1TCPSocketActionBuilder(io.kubernetes.client.openapi.models.V1TCPSocketActionFluent fluent,io.kubernetes.client.openapi.models.V1TCPSocketAction instance) { + + public V1TCPSocketActionBuilder( + io.kubernetes.client.openapi.models.V1TCPSocketActionFluent fluent, + io.kubernetes.client.openapi.models.V1TCPSocketAction instance) { this(fluent, instance, false); } - public V1TCPSocketActionBuilder(io.kubernetes.client.openapi.models.V1TCPSocketActionFluent fluent,io.kubernetes.client.openapi.models.V1TCPSocketAction instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1TCPSocketActionBuilder( + io.kubernetes.client.openapi.models.V1TCPSocketActionFluent fluent, + io.kubernetes.client.openapi.models.V1TCPSocketAction instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withHost(instance.getHost()); fluent.withPort(instance.getPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1TCPSocketActionBuilder(io.kubernetes.client.openapi.models.V1TCPSocketAction instance) { - this(instance,false); + this(instance, false); } - public V1TCPSocketActionBuilder(io.kubernetes.client.openapi.models.V1TCPSocketAction instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1TCPSocketActionBuilder( + io.kubernetes.client.openapi.models.V1TCPSocketAction instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withHost(instance.getHost()); this.withPort(instance.getPort()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1TCPSocketActionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1TCPSocketAction build() { V1TCPSocketAction buildable = new V1TCPSocketAction(); buildable.setHost(fluent.getHost()); buildable.setPort(fluent.getPort()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1TCPSocketActionBuilder that = (V1TCPSocketActionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TCPSocketActionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TCPSocketActionFluent.java index 10c57ddc3c..be2d5b93af 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TCPSocketActionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TCPSocketActionFluent.java @@ -1,29 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.custom.IntOrString; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1TCPSocketActionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1TCPSocketActionFluent< + A extends io.kubernetes.client.openapi.models.V1TCPSocketActionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getHost(); + public A withHost(java.lang.String host); + public java.lang.Boolean hasHost(); - - /** - * Method is deprecated. use withHost instead. - */ + + /** Method is deprecated. use withHost instead. */ @java.lang.Deprecated public A withNewHost(java.lang.String original); + public io.kubernetes.client.custom.IntOrString getPort(); + public A withPort(io.kubernetes.client.custom.IntOrString port); + public java.lang.Boolean hasPort(); + public A withNewPort(int value); + public A withNewPort(java.lang.String value); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TCPSocketActionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TCPSocketActionFluentImpl.java index d7865ac25e..045aa58c7f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TCPSocketActionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TCPSocketActionFluentImpl.java @@ -1,68 +1,86 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; import io.kubernetes.client.custom.IntOrString; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1TCPSocketActionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1TCPSocketActionFluent{ - public V1TCPSocketActionFluentImpl() { - } - public V1TCPSocketActionFluentImpl(io.kubernetes.client.openapi.models.V1TCPSocketAction instance) { + +/** Generated */ +public class V1TCPSocketActionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1TCPSocketActionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1TCPSocketActionFluent { + public V1TCPSocketActionFluentImpl() {} + + public V1TCPSocketActionFluentImpl( + io.kubernetes.client.openapi.models.V1TCPSocketAction instance) { this.withHost(instance.getHost()); this.withPort(instance.getPort()); - } + private java.lang.String host; private io.kubernetes.client.custom.IntOrString port; + public java.lang.String getHost() { return this.host; } + public A withHost(java.lang.String host) { - this.host=host; return (A) this; + this.host = host; + return (A) this; } + public java.lang.Boolean hasHost() { return this.host != null; } - - /** - * Method is deprecated. use withHost instead. - */ + + /** Method is deprecated. use withHost instead. */ @java.lang.Deprecated public A withNewHost(java.lang.String original) { - return (A)withHost(new String(original)); + return (A) withHost(new String(original)); } + public io.kubernetes.client.custom.IntOrString getPort() { return this.port; } + public A withPort(io.kubernetes.client.custom.IntOrString port) { - this.port=port; return (A) this; + this.port = port; + return (A) this; } + public java.lang.Boolean hasPort() { return this.port != null; } + public A withNewPort(int value) { - return (A)withPort(new IntOrString(value)); + return (A) withPort(new IntOrString(value)); } + public A withNewPort(java.lang.String value) { - return (A)withPort(new IntOrString(value)); + return (A) withPort(new IntOrString(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1TCPSocketActionFluentImpl that = (V1TCPSocketActionFluentImpl) o; - if (host != null ? !host.equals(that.host) :that.host != null) return false; - if (port != null ? !port.equals(that.port) :that.port != null) return false; + if (host != null ? !host.equals(that.host) : that.host != null) return false; + if (port != null ? !port.equals(that.port) : that.port != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(host, port, super.hashCode()); + return java.util.Objects.hash(host, port, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TaintBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TaintBuilder.java index 1e8bc550bb..0b0b9b4f1e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TaintBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TaintBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1TaintBuilder extends io.kubernetes.client.openapi.models.V1TaintFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1TaintBuilder + extends io.kubernetes.client.openapi.models.V1TaintFluentImpl< + io.kubernetes.client.openapi.models.V1TaintBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Taint, + io.kubernetes.client.openapi.models.V1TaintBuilder> { public V1TaintBuilder() { this(false); } + public V1TaintBuilder(java.lang.Boolean validationEnabled) { this(new V1Taint(), validationEnabled); } + public V1TaintBuilder(io.kubernetes.client.openapi.models.V1TaintFluent fluent) { this(fluent, false); } - public V1TaintBuilder(io.kubernetes.client.openapi.models.V1TaintFluent fluent,java.lang.Boolean validationEnabled) { + + public V1TaintBuilder( + io.kubernetes.client.openapi.models.V1TaintFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Taint(), validationEnabled); } - public V1TaintBuilder(io.kubernetes.client.openapi.models.V1TaintFluent fluent,io.kubernetes.client.openapi.models.V1Taint instance) { + + public V1TaintBuilder( + io.kubernetes.client.openapi.models.V1TaintFluent fluent, + io.kubernetes.client.openapi.models.V1Taint instance) { this(fluent, instance, false); } - public V1TaintBuilder(io.kubernetes.client.openapi.models.V1TaintFluent fluent,io.kubernetes.client.openapi.models.V1Taint instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1TaintBuilder( + io.kubernetes.client.openapi.models.V1TaintFluent fluent, + io.kubernetes.client.openapi.models.V1Taint instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withEffect(instance.getEffect()); fluent.withKey(instance.getKey()); @@ -29,13 +55,16 @@ public V1TaintBuilder(io.kubernetes.client.openapi.models.V1TaintFluent fluen fluent.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1TaintBuilder(io.kubernetes.client.openapi.models.V1Taint instance) { - this(instance,false); + this(instance, false); } - public V1TaintBuilder(io.kubernetes.client.openapi.models.V1Taint instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1TaintBuilder( + io.kubernetes.client.openapi.models.V1Taint instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withEffect(instance.getEffect()); this.withKey(instance.getKey()); @@ -44,10 +73,12 @@ public V1TaintBuilder(io.kubernetes.client.openapi.models.V1Taint instance,java. this.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1TaintFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Taint build() { V1Taint buildable = new V1Taint(); buildable.setEffect(fluent.getEffect()); @@ -56,18 +87,23 @@ public io.kubernetes.client.openapi.models.V1Taint build() { buildable.setValue(fluent.getValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1TaintBuilder that = (V1TaintBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TaintFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TaintFluent.java index dada2be857..cde29edfd2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TaintFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TaintFluent.java @@ -1,39 +1,49 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1TaintFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1TaintFluent> + extends io.kubernetes.client.fluent.Fluent { public io.kubernetes.client.openapi.models.V1Taint.EffectEnum getEffect(); + public A withEffect(io.kubernetes.client.openapi.models.V1Taint.EffectEnum effect); + public java.lang.Boolean hasEffect(); + public java.lang.String getKey(); + public A withKey(java.lang.String key); + public java.lang.Boolean hasKey(); - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original); + public java.time.OffsetDateTime getTimeAdded(); + public A withTimeAdded(java.time.OffsetDateTime timeAdded); + public java.lang.Boolean hasTimeAdded(); + public java.lang.String getValue(); + public A withValue(java.lang.String value); + public java.lang.Boolean hasValue(); - - /** - * Method is deprecated. use withValue instead. - */ + + /** Method is deprecated. use withValue instead. */ @java.lang.Deprecated public A withNewValue(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TaintFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TaintFluentImpl.java index 6488d241b2..dda4d90be3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TaintFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TaintFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1TaintFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1TaintFluent { + public V1TaintFluentImpl() {} - /** - * Generated - */ -public class V1TaintFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1TaintFluent{ - public V1TaintFluentImpl() { - } public V1TaintFluentImpl(io.kubernetes.client.openapi.models.V1Taint instance) { this.withEffect(instance.getEffect()); @@ -21,76 +26,90 @@ public V1TaintFluentImpl(io.kubernetes.client.openapi.models.V1Taint instance) { this.withTimeAdded(instance.getTimeAdded()); this.withValue(instance.getValue()); - } + private io.kubernetes.client.openapi.models.V1Taint.EffectEnum effect; private java.lang.String key; private java.time.OffsetDateTime timeAdded; private java.lang.String value; + public io.kubernetes.client.openapi.models.V1Taint.EffectEnum getEffect() { return this.effect; } + public A withEffect(io.kubernetes.client.openapi.models.V1Taint.EffectEnum effect) { - this.effect=effect; return (A) this; + this.effect = effect; + return (A) this; } + public java.lang.Boolean hasEffect() { return this.effect != null; } + public java.lang.String getKey() { return this.key; } + public A withKey(java.lang.String key) { - this.key=key; return (A) this; + this.key = key; + return (A) this; } + public java.lang.Boolean hasKey() { return this.key != null; } - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original) { - return (A)withKey(new String(original)); + return (A) withKey(new String(original)); } + public java.time.OffsetDateTime getTimeAdded() { return this.timeAdded; } + public A withTimeAdded(java.time.OffsetDateTime timeAdded) { - this.timeAdded=timeAdded; return (A) this; + this.timeAdded = timeAdded; + return (A) this; } + public java.lang.Boolean hasTimeAdded() { return this.timeAdded != null; } + public java.lang.String getValue() { return this.value; } + public A withValue(java.lang.String value) { - this.value=value; return (A) this; + this.value = value; + return (A) this; } + public java.lang.Boolean hasValue() { return this.value != null; } - - /** - * Method is deprecated. use withValue instead. - */ + + /** Method is deprecated. use withValue instead. */ @java.lang.Deprecated public A withNewValue(java.lang.String original) { - return (A)withValue(new String(original)); + return (A) withValue(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1TaintFluentImpl that = (V1TaintFluentImpl) o; - if (effect != null ? !effect.equals(that.effect) :that.effect != null) return false; - if (key != null ? !key.equals(that.key) :that.key != null) return false; - if (timeAdded != null ? !timeAdded.equals(that.timeAdded) :that.timeAdded != null) return false; - if (value != null ? !value.equals(that.value) :that.value != null) return false; + if (effect != null ? !effect.equals(that.effect) : that.effect != null) return false; + if (key != null ? !key.equals(that.key) : that.key != null) return false; + if (timeAdded != null ? !timeAdded.equals(that.timeAdded) : that.timeAdded != null) + return false; + if (value != null ? !value.equals(that.value) : that.value != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(effect, key, timeAdded, value, super.hashCode()); + return java.util.Objects.hash(effect, key, timeAdded, value, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestSpecBuilder.java index 2f50f47f6a..de6c005cf1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestSpecBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1TokenRequestSpecBuilder extends io.kubernetes.client.openapi.models.V1TokenRequestSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1TokenRequestSpecBuilder + extends io.kubernetes.client.openapi.models.V1TokenRequestSpecFluentImpl< + io.kubernetes.client.openapi.models.V1TokenRequestSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1TokenRequestSpec, + io.kubernetes.client.openapi.models.V1TokenRequestSpecBuilder> { public V1TokenRequestSpecBuilder() { this(false); } + public V1TokenRequestSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1TokenRequestSpec(), validationEnabled); } - public V1TokenRequestSpecBuilder(io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent fluent) { + + public V1TokenRequestSpecBuilder( + io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent fluent) { this(fluent, false); } - public V1TokenRequestSpecBuilder(io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1TokenRequestSpecBuilder( + io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1TokenRequestSpec(), validationEnabled); } - public V1TokenRequestSpecBuilder(io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent fluent,io.kubernetes.client.openapi.models.V1TokenRequestSpec instance) { + + public V1TokenRequestSpecBuilder( + io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent fluent, + io.kubernetes.client.openapi.models.V1TokenRequestSpec instance) { this(fluent, instance, false); } - public V1TokenRequestSpecBuilder(io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent fluent,io.kubernetes.client.openapi.models.V1TokenRequestSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1TokenRequestSpecBuilder( + io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent fluent, + io.kubernetes.client.openapi.models.V1TokenRequestSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAudiences(instance.getAudiences()); fluent.withBoundObjectRef(instance.getBoundObjectRef()); fluent.withExpirationSeconds(instance.getExpirationSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1TokenRequestSpecBuilder(io.kubernetes.client.openapi.models.V1TokenRequestSpec instance) { - this(instance,false); + + public V1TokenRequestSpecBuilder( + io.kubernetes.client.openapi.models.V1TokenRequestSpec instance) { + this(instance, false); } - public V1TokenRequestSpecBuilder(io.kubernetes.client.openapi.models.V1TokenRequestSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1TokenRequestSpecBuilder( + io.kubernetes.client.openapi.models.V1TokenRequestSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAudiences(instance.getAudiences()); this.withBoundObjectRef(instance.getBoundObjectRef()); this.withExpirationSeconds(instance.getExpirationSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1TokenRequestSpec build() { V1TokenRequestSpec buildable = new V1TokenRequestSpec(); buildable.setAudiences(fluent.getAudiences()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1TokenRequestSpec build() { buildable.setExpirationSeconds(fluent.getExpirationSeconds()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1TokenRequestSpecBuilder that = (V1TokenRequestSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestSpecFluent.java index 991e318c5f..67e2df4931 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestSpecFluent.java @@ -1,60 +1,98 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Long; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1TokenRequestSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAudiences(java.lang.Integer index,java.lang.String item); - public A setToAudiences(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1TokenRequestSpecFluent< + A extends io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAudiences(java.lang.Integer index, java.lang.String item); + + public A setToAudiences(java.lang.Integer index, java.lang.String item); + public A addToAudiences(java.lang.String... items); + public A addAllToAudiences(java.util.Collection items); + public A removeFromAudiences(java.lang.String... items); + public A removeAllFromAudiences(java.util.Collection items); + public java.util.List getAudiences(); + public java.lang.String getAudience(java.lang.Integer index); + public java.lang.String getFirstAudience(); + public java.lang.String getLastAudience(); - public java.lang.String getMatchingAudience(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAudience(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAudience( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAudience( + java.util.function.Predicate predicate); + public A withAudiences(java.util.List audiences); + public A withAudiences(java.lang.String... audiences); + public java.lang.Boolean hasAudiences(); + public A addNewAudience(java.lang.String original); - + /** * This method has been deprecated, please use method buildBoundObjectRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1BoundObjectReference getBoundObjectRef(); + public io.kubernetes.client.openapi.models.V1BoundObjectReference buildBoundObjectRef(); - public A withBoundObjectRef(io.kubernetes.client.openapi.models.V1BoundObjectReference boundObjectRef); + + public A withBoundObjectRef( + io.kubernetes.client.openapi.models.V1BoundObjectReference boundObjectRef); + public java.lang.Boolean hasBoundObjectRef(); - public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested withNewBoundObjectRef(); - public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested withNewBoundObjectRefLike(io.kubernetes.client.openapi.models.V1BoundObjectReference item); - public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested editBoundObjectRef(); - public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested editOrNewBoundObjectRef(); - public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested editOrNewBoundObjectRefLike(io.kubernetes.client.openapi.models.V1BoundObjectReference item); + + public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested + withNewBoundObjectRef(); + + public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested + withNewBoundObjectRefLike(io.kubernetes.client.openapi.models.V1BoundObjectReference item); + + public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested + editBoundObjectRef(); + + public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested + editOrNewBoundObjectRef(); + + public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested + editOrNewBoundObjectRefLike(io.kubernetes.client.openapi.models.V1BoundObjectReference item); + public java.lang.Long getExpirationSeconds(); + public A withExpirationSeconds(java.lang.Long expirationSeconds); + public java.lang.Boolean hasExpirationSeconds(); - public interface BoundObjectRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent>{ + + public interface BoundObjectRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested< + N>> { public N and(); + public N endBoundObjectRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestSpecFluentImpl.java index 55d176a2a2..10f9a39784 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestSpecFluentImpl.java @@ -1,159 +1,273 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1TokenRequestSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent{ - public V1TokenRequestSpecFluentImpl() { - } - public V1TokenRequestSpecFluentImpl(io.kubernetes.client.openapi.models.V1TokenRequestSpec instance) { +/** Generated */ +public class V1TokenRequestSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent { + public V1TokenRequestSpecFluentImpl() {} + + public V1TokenRequestSpecFluentImpl( + io.kubernetes.client.openapi.models.V1TokenRequestSpec instance) { this.withAudiences(instance.getAudiences()); this.withBoundObjectRef(instance.getBoundObjectRef()); this.withExpirationSeconds(instance.getExpirationSeconds()); - } + private java.util.List audiences; private io.kubernetes.client.openapi.models.V1BoundObjectReferenceBuilder boundObjectRef; private java.lang.Long expirationSeconds; - public A addToAudiences(java.lang.Integer index,java.lang.String item) { - if (this.audiences == null) {this.audiences = new java.util.ArrayList();} + + public A addToAudiences(java.lang.Integer index, java.lang.String item) { + if (this.audiences == null) { + this.audiences = new java.util.ArrayList(); + } this.audiences.add(index, item); - return (A)this; + return (A) this; } - public A setToAudiences(java.lang.Integer index,java.lang.String item) { - if (this.audiences == null) {this.audiences = new java.util.ArrayList();} - this.audiences.set(index, item); return (A)this; + + public A setToAudiences(java.lang.Integer index, java.lang.String item) { + if (this.audiences == null) { + this.audiences = new java.util.ArrayList(); + } + this.audiences.set(index, item); + return (A) this; } + public A addToAudiences(java.lang.String... items) { - if (this.audiences == null) {this.audiences = new java.util.ArrayList();} - for (java.lang.String item : items) {this.audiences.add(item);} return (A)this; + if (this.audiences == null) { + this.audiences = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.audiences.add(item); + } + return (A) this; } + public A addAllToAudiences(java.util.Collection items) { - if (this.audiences == null) {this.audiences = new java.util.ArrayList();} - for (java.lang.String item : items) {this.audiences.add(item);} return (A)this; + if (this.audiences == null) { + this.audiences = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.audiences.add(item); + } + return (A) this; } + public A removeFromAudiences(java.lang.String... items) { - for (java.lang.String item : items) {if (this.audiences!= null){ this.audiences.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.audiences != null) { + this.audiences.remove(item); + } + } + return (A) this; } + public A removeAllFromAudiences(java.util.Collection items) { - for (java.lang.String item : items) {if (this.audiences!= null){ this.audiences.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.audiences != null) { + this.audiences.remove(item); + } + } + return (A) this; } + public java.util.List getAudiences() { return this.audiences; } + public java.lang.String getAudience(java.lang.Integer index) { return this.audiences.get(index); } + public java.lang.String getFirstAudience() { return this.audiences.get(0); } + public java.lang.String getLastAudience() { return this.audiences.get(audiences.size() - 1); } - public java.lang.String getMatchingAudience(java.util.function.Predicate predicate) { - for (java.lang.String item: audiences) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAudience( + java.util.function.Predicate predicate) { + for (java.lang.String item : audiences) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAudience(java.util.function.Predicate predicate) { - for (java.lang.String item: audiences) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAudience( + java.util.function.Predicate predicate) { + for (java.lang.String item : audiences) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAudiences(java.util.List audiences) { - if (audiences != null) {this.audiences = new java.util.ArrayList(); for (java.lang.String item : audiences){this.addToAudiences(item);}} else { this.audiences = null;} return (A) this; + if (audiences != null) { + this.audiences = new java.util.ArrayList(); + for (java.lang.String item : audiences) { + this.addToAudiences(item); + } + } else { + this.audiences = null; + } + return (A) this; } + public A withAudiences(java.lang.String... audiences) { - if (this.audiences != null) {this.audiences.clear();} - if (audiences != null) {for (java.lang.String item :audiences){ this.addToAudiences(item);}} return (A) this; + if (this.audiences != null) { + this.audiences.clear(); + } + if (audiences != null) { + for (java.lang.String item : audiences) { + this.addToAudiences(item); + } + } + return (A) this; } + public java.lang.Boolean hasAudiences() { return audiences != null && !audiences.isEmpty(); } + public A addNewAudience(java.lang.String original) { - return (A)addToAudiences(new String(original)); + return (A) addToAudiences(new String(original)); } - + /** * This method has been deprecated, please use method buildBoundObjectRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1BoundObjectReference getBoundObjectRef() { - return this.boundObjectRef!=null ?this.boundObjectRef.build():null; + return this.boundObjectRef != null ? this.boundObjectRef.build() : null; } + public io.kubernetes.client.openapi.models.V1BoundObjectReference buildBoundObjectRef() { - return this.boundObjectRef!=null ?this.boundObjectRef.build():null; + return this.boundObjectRef != null ? this.boundObjectRef.build() : null; } - public A withBoundObjectRef(io.kubernetes.client.openapi.models.V1BoundObjectReference boundObjectRef) { + + public A withBoundObjectRef( + io.kubernetes.client.openapi.models.V1BoundObjectReference boundObjectRef) { _visitables.get("boundObjectRef").remove(this.boundObjectRef); - if (boundObjectRef!=null){ this.boundObjectRef= new io.kubernetes.client.openapi.models.V1BoundObjectReferenceBuilder(boundObjectRef); _visitables.get("boundObjectRef").add(this.boundObjectRef);} return (A) this; + if (boundObjectRef != null) { + this.boundObjectRef = + new io.kubernetes.client.openapi.models.V1BoundObjectReferenceBuilder(boundObjectRef); + _visitables.get("boundObjectRef").add(this.boundObjectRef); + } + return (A) this; } + public java.lang.Boolean hasBoundObjectRef() { return this.boundObjectRef != null; } - public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested withNewBoundObjectRef() { - return new io.kubernetes.client.openapi.models.V1TokenRequestSpecFluentImpl.BoundObjectRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested + withNewBoundObjectRef() { + return new io.kubernetes.client.openapi.models.V1TokenRequestSpecFluentImpl + .BoundObjectRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested withNewBoundObjectRefLike(io.kubernetes.client.openapi.models.V1BoundObjectReference item) { - return new io.kubernetes.client.openapi.models.V1TokenRequestSpecFluentImpl.BoundObjectRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested + withNewBoundObjectRefLike(io.kubernetes.client.openapi.models.V1BoundObjectReference item) { + return new io.kubernetes.client.openapi.models.V1TokenRequestSpecFluentImpl + .BoundObjectRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested editBoundObjectRef() { + + public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested + editBoundObjectRef() { return withNewBoundObjectRefLike(getBoundObjectRef()); } - public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested editOrNewBoundObjectRef() { - return withNewBoundObjectRefLike(getBoundObjectRef() != null ? getBoundObjectRef(): new io.kubernetes.client.openapi.models.V1BoundObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested + editOrNewBoundObjectRef() { + return withNewBoundObjectRefLike( + getBoundObjectRef() != null + ? getBoundObjectRef() + : new io.kubernetes.client.openapi.models.V1BoundObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested editOrNewBoundObjectRefLike(io.kubernetes.client.openapi.models.V1BoundObjectReference item) { - return withNewBoundObjectRefLike(getBoundObjectRef() != null ? getBoundObjectRef(): item); + + public io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested + editOrNewBoundObjectRefLike(io.kubernetes.client.openapi.models.V1BoundObjectReference item) { + return withNewBoundObjectRefLike(getBoundObjectRef() != null ? getBoundObjectRef() : item); } + public java.lang.Long getExpirationSeconds() { return this.expirationSeconds; } + public A withExpirationSeconds(java.lang.Long expirationSeconds) { - this.expirationSeconds=expirationSeconds; return (A) this; + this.expirationSeconds = expirationSeconds; + return (A) this; } + public java.lang.Boolean hasExpirationSeconds() { return this.expirationSeconds != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1TokenRequestSpecFluentImpl that = (V1TokenRequestSpecFluentImpl) o; - if (audiences != null ? !audiences.equals(that.audiences) :that.audiences != null) return false; - if (boundObjectRef != null ? !boundObjectRef.equals(that.boundObjectRef) :that.boundObjectRef != null) return false; - if (expirationSeconds != null ? !expirationSeconds.equals(that.expirationSeconds) :that.expirationSeconds != null) return false; + if (audiences != null ? !audiences.equals(that.audiences) : that.audiences != null) + return false; + if (boundObjectRef != null + ? !boundObjectRef.equals(that.boundObjectRef) + : that.boundObjectRef != null) return false; + if (expirationSeconds != null + ? !expirationSeconds.equals(that.expirationSeconds) + : that.expirationSeconds != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(audiences, boundObjectRef, expirationSeconds, super.hashCode()); + return java.util.Objects.hash(audiences, boundObjectRef, expirationSeconds, super.hashCode()); } - public class BoundObjectRefNestedImpl extends io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested,io.kubernetes.client.fluent.Nested{ + + public class BoundObjectRefNestedImpl + extends io.kubernetes.client.openapi.models.V1BoundObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested> + implements io.kubernetes.client.openapi.models.V1TokenRequestSpecFluent.BoundObjectRefNested< + N>, + io.kubernetes.client.fluent.Nested { BoundObjectRefNestedImpl(io.kubernetes.client.openapi.models.V1BoundObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1BoundObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1BoundObjectReferenceBuilder(this, item); } + BoundObjectRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1BoundObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1BoundObjectReferenceBuilder builder; + public N and() { return (N) V1TokenRequestSpecFluentImpl.this.withBoundObjectRef(builder.build()); } + public N endBoundObjectRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestStatusBuilder.java index e23c117929..2322939055 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestStatusBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1TokenRequestStatusBuilder extends io.kubernetes.client.openapi.models.V1TokenRequestStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1TokenRequestStatusBuilder + extends io.kubernetes.client.openapi.models.V1TokenRequestStatusFluentImpl< + io.kubernetes.client.openapi.models.V1TokenRequestStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1TokenRequestStatus, + io.kubernetes.client.openapi.models.V1TokenRequestStatusBuilder> { public V1TokenRequestStatusBuilder() { this(false); } + public V1TokenRequestStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1TokenRequestStatus(), validationEnabled); } - public V1TokenRequestStatusBuilder(io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent fluent) { + + public V1TokenRequestStatusBuilder( + io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent fluent) { this(fluent, false); } - public V1TokenRequestStatusBuilder(io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1TokenRequestStatusBuilder( + io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1TokenRequestStatus(), validationEnabled); } - public V1TokenRequestStatusBuilder(io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent fluent,io.kubernetes.client.openapi.models.V1TokenRequestStatus instance) { + + public V1TokenRequestStatusBuilder( + io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent fluent, + io.kubernetes.client.openapi.models.V1TokenRequestStatus instance) { this(fluent, instance, false); } - public V1TokenRequestStatusBuilder(io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent fluent,io.kubernetes.client.openapi.models.V1TokenRequestStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1TokenRequestStatusBuilder( + io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent fluent, + io.kubernetes.client.openapi.models.V1TokenRequestStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withExpirationTimestamp(instance.getExpirationTimestamp()); fluent.withToken(instance.getToken()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1TokenRequestStatusBuilder(io.kubernetes.client.openapi.models.V1TokenRequestStatus instance) { - this(instance,false); + + public V1TokenRequestStatusBuilder( + io.kubernetes.client.openapi.models.V1TokenRequestStatus instance) { + this(instance, false); } - public V1TokenRequestStatusBuilder(io.kubernetes.client.openapi.models.V1TokenRequestStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1TokenRequestStatusBuilder( + io.kubernetes.client.openapi.models.V1TokenRequestStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withExpirationTimestamp(instance.getExpirationTimestamp()); this.withToken(instance.getToken()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1TokenRequestStatus build() { V1TokenRequestStatus buildable = new V1TokenRequestStatus(); buildable.setExpirationTimestamp(fluent.getExpirationTimestamp()); buildable.setToken(fluent.getToken()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1TokenRequestStatusBuilder that = (V1TokenRequestStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestStatusFluent.java index 6f48a33162..99c6739057 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestStatusFluent.java @@ -1,27 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1TokenRequestStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1TokenRequestStatusFluent< + A extends io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getExpirationTimestamp(); + public A withExpirationTimestamp(java.time.OffsetDateTime expirationTimestamp); + public java.lang.Boolean hasExpirationTimestamp(); + public java.lang.String getToken(); + public A withToken(java.lang.String token); + public java.lang.Boolean hasToken(); - - /** - * Method is deprecated. use withToken instead. - */ + + /** Method is deprecated. use withToken instead. */ @java.lang.Deprecated public A withNewToken(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestStatusFluentImpl.java index c60ee0900c..a197bb6af1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenRequestStatusFluentImpl.java @@ -1,62 +1,78 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1TokenRequestStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent { + public V1TokenRequestStatusFluentImpl() {} - /** - * Generated - */ -public class V1TokenRequestStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1TokenRequestStatusFluent{ - public V1TokenRequestStatusFluentImpl() { - } - public V1TokenRequestStatusFluentImpl(io.kubernetes.client.openapi.models.V1TokenRequestStatus instance) { + public V1TokenRequestStatusFluentImpl( + io.kubernetes.client.openapi.models.V1TokenRequestStatus instance) { this.withExpirationTimestamp(instance.getExpirationTimestamp()); this.withToken(instance.getToken()); - } + private java.time.OffsetDateTime expirationTimestamp; private java.lang.String token; + public java.time.OffsetDateTime getExpirationTimestamp() { return this.expirationTimestamp; } + public A withExpirationTimestamp(java.time.OffsetDateTime expirationTimestamp) { - this.expirationTimestamp=expirationTimestamp; return (A) this; + this.expirationTimestamp = expirationTimestamp; + return (A) this; } + public java.lang.Boolean hasExpirationTimestamp() { return this.expirationTimestamp != null; } + public java.lang.String getToken() { return this.token; } + public A withToken(java.lang.String token) { - this.token=token; return (A) this; + this.token = token; + return (A) this; } + public java.lang.Boolean hasToken() { return this.token != null; } - - /** - * Method is deprecated. use withToken instead. - */ + + /** Method is deprecated. use withToken instead. */ @java.lang.Deprecated public A withNewToken(java.lang.String original) { - return (A)withToken(new String(original)); + return (A) withToken(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1TokenRequestStatusFluentImpl that = (V1TokenRequestStatusFluentImpl) o; - if (expirationTimestamp != null ? !expirationTimestamp.equals(that.expirationTimestamp) :that.expirationTimestamp != null) return false; - if (token != null ? !token.equals(that.token) :that.token != null) return false; + if (expirationTimestamp != null + ? !expirationTimestamp.equals(that.expirationTimestamp) + : that.expirationTimestamp != null) return false; + if (token != null ? !token.equals(that.token) : that.token != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(expirationTimestamp, token, super.hashCode()); + return java.util.Objects.hash(expirationTimestamp, token, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewBuilder.java index 4583c0096d..cca3c118a9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1TokenReviewBuilder extends io.kubernetes.client.openapi.models.V1TokenReviewFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1TokenReviewBuilder + extends io.kubernetes.client.openapi.models.V1TokenReviewFluentImpl< + io.kubernetes.client.openapi.models.V1TokenReviewBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1TokenReview, + io.kubernetes.client.openapi.models.V1TokenReviewBuilder> { public V1TokenReviewBuilder() { this(false); } + public V1TokenReviewBuilder(java.lang.Boolean validationEnabled) { this(new V1TokenReview(), validationEnabled); } + public V1TokenReviewBuilder(io.kubernetes.client.openapi.models.V1TokenReviewFluent fluent) { this(fluent, false); } - public V1TokenReviewBuilder(io.kubernetes.client.openapi.models.V1TokenReviewFluent fluent,java.lang.Boolean validationEnabled) { + + public V1TokenReviewBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1TokenReview(), validationEnabled); } - public V1TokenReviewBuilder(io.kubernetes.client.openapi.models.V1TokenReviewFluent fluent,io.kubernetes.client.openapi.models.V1TokenReview instance) { + + public V1TokenReviewBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewFluent fluent, + io.kubernetes.client.openapi.models.V1TokenReview instance) { this(fluent, instance, false); } - public V1TokenReviewBuilder(io.kubernetes.client.openapi.models.V1TokenReviewFluent fluent,io.kubernetes.client.openapi.models.V1TokenReview instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1TokenReviewBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewFluent fluent, + io.kubernetes.client.openapi.models.V1TokenReview instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,17 @@ public V1TokenReviewBuilder(io.kubernetes.client.openapi.models.V1TokenReviewFlu fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1TokenReviewBuilder(io.kubernetes.client.openapi.models.V1TokenReview instance) { - this(instance,false); + this(instance, false); } - public V1TokenReviewBuilder(io.kubernetes.client.openapi.models.V1TokenReview instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1TokenReviewBuilder( + io.kubernetes.client.openapi.models.V1TokenReview instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +78,12 @@ public V1TokenReviewBuilder(io.kubernetes.client.openapi.models.V1TokenReview in this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1TokenReviewFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1TokenReview build() { V1TokenReview buildable = new V1TokenReview(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +93,23 @@ public io.kubernetes.client.openapi.models.V1TokenReview build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1TokenReviewBuilder that = (V1TokenReviewBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewFluent.java index 1c8d541024..1f998444d1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewFluent.java @@ -1,93 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1TokenReviewFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1TokenReviewFluent< + A extends io.kubernetes.client.openapi.models.V1TokenReviewFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TokenReviewSpec getSpec(); + public io.kubernetes.client.openapi.models.V1TokenReviewSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1TokenReviewSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1TokenReviewSpec item); + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1TokenReviewSpec item); + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1TokenReviewSpec item); - + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1TokenReviewSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TokenReviewStatus getStatus(); + public io.kubernetes.client.openapi.models.V1TokenReviewStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1TokenReviewStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1TokenReviewStatus item); + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1TokenReviewStatus item); + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1TokenReviewStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1TokenReviewStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent< + io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent< + io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewFluentImpl.java index 0d9bced4fa..d731243cdf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1TokenReviewFluentImpl< + A extends io.kubernetes.client.openapi.models.V1TokenReviewFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1TokenReviewFluent { + public V1TokenReviewFluentImpl() {} - /** - * Generated - */ -public class V1TokenReviewFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1TokenReviewFluent{ - public V1TokenReviewFluentImpl() { - } public V1TokenReviewFluentImpl(io.kubernetes.client.openapi.models.V1TokenReview instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +29,296 @@ public V1TokenReviewFluentImpl(io.kubernetes.client.openapi.models.V1TokenReview this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1TokenReviewSpecBuilder spec; private io.kubernetes.client.openapi.models.V1TokenReviewStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1TokenReviewFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1TokenReviewFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TokenReviewSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1TokenReviewSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1TokenReviewSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1TokenReviewSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1TokenReviewSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1TokenReviewFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1TokenReviewSpec item) { + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1TokenReviewSpec item) { return new io.kubernetes.client.openapi.models.V1TokenReviewFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1TokenReviewSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1TokenReviewSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1TokenReviewSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1TokenReviewSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1TokenReviewStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1TokenReviewStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1TokenReviewStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1TokenReviewStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1TokenReviewStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1TokenReviewFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1TokenReviewStatus item) { + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1TokenReviewStatus item) { return new io.kubernetes.client.openapi.models.V1TokenReviewFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1TokenReviewStatusBuilder().build()); + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1TokenReviewStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1TokenReviewStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1TokenReviewStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1TokenReviewFluentImpl that = (V1TokenReviewFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1TokenReviewFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1TokenReviewFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1TokenReviewSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1TokenReviewSpecFluentImpl< + io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1TokenReviewFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1TokenReviewSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1TokenReviewSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1TokenReviewSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1TokenReviewSpecBuilder builder; + public N and() { return (N) V1TokenReviewFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1TokenReviewStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1TokenReviewStatusFluentImpl< + io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1TokenReviewFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1TokenReviewStatus item) { this.builder = new io.kubernetes.client.openapi.models.V1TokenReviewStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1TokenReviewStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1TokenReviewStatusBuilder builder; + public N and() { return (N) V1TokenReviewFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewSpecBuilder.java index 2e61ef3cd0..eabae5f61f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewSpecBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1TokenReviewSpecBuilder extends io.kubernetes.client.openapi.models.V1TokenReviewSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1TokenReviewSpecBuilder + extends io.kubernetes.client.openapi.models.V1TokenReviewSpecFluentImpl< + io.kubernetes.client.openapi.models.V1TokenReviewSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1TokenReviewSpec, + io.kubernetes.client.openapi.models.V1TokenReviewSpecBuilder> { public V1TokenReviewSpecBuilder() { this(false); } + public V1TokenReviewSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1TokenReviewSpec(), validationEnabled); } - public V1TokenReviewSpecBuilder(io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent fluent) { + + public V1TokenReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent fluent) { this(fluent, false); } - public V1TokenReviewSpecBuilder(io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1TokenReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1TokenReviewSpec(), validationEnabled); } - public V1TokenReviewSpecBuilder(io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent fluent,io.kubernetes.client.openapi.models.V1TokenReviewSpec instance) { + + public V1TokenReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent fluent, + io.kubernetes.client.openapi.models.V1TokenReviewSpec instance) { this(fluent, instance, false); } - public V1TokenReviewSpecBuilder(io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent fluent,io.kubernetes.client.openapi.models.V1TokenReviewSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1TokenReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent fluent, + io.kubernetes.client.openapi.models.V1TokenReviewSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAudiences(instance.getAudiences()); fluent.withToken(instance.getToken()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1TokenReviewSpecBuilder(io.kubernetes.client.openapi.models.V1TokenReviewSpec instance) { - this(instance,false); + this(instance, false); } - public V1TokenReviewSpecBuilder(io.kubernetes.client.openapi.models.V1TokenReviewSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1TokenReviewSpecBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAudiences(instance.getAudiences()); this.withToken(instance.getToken()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1TokenReviewSpec build() { V1TokenReviewSpec buildable = new V1TokenReviewSpec(); buildable.setAudiences(fluent.getAudiences()); buildable.setToken(fluent.getToken()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1TokenReviewSpecBuilder that = (V1TokenReviewSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewSpecFluent.java index 4dffbd61ad..e3905a50bb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewSpecFluent.java @@ -1,44 +1,62 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1TokenReviewSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAudiences(java.lang.Integer index,java.lang.String item); - public A setToAudiences(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1TokenReviewSpecFluent< + A extends io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAudiences(java.lang.Integer index, java.lang.String item); + + public A setToAudiences(java.lang.Integer index, java.lang.String item); + public A addToAudiences(java.lang.String... items); + public A addAllToAudiences(java.util.Collection items); + public A removeFromAudiences(java.lang.String... items); + public A removeAllFromAudiences(java.util.Collection items); + public java.util.List getAudiences(); + public java.lang.String getAudience(java.lang.Integer index); + public java.lang.String getFirstAudience(); + public java.lang.String getLastAudience(); - public java.lang.String getMatchingAudience(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAudience(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAudience( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAudience( + java.util.function.Predicate predicate); + public A withAudiences(java.util.List audiences); + public A withAudiences(java.lang.String... audiences); + public java.lang.Boolean hasAudiences(); + public A addNewAudience(java.lang.String original); + public java.lang.String getToken(); + public A withToken(java.lang.String token); + public java.lang.Boolean hasToken(); - - /** - * Method is deprecated. use withToken instead. - */ + + /** Method is deprecated. use withToken instead. */ @java.lang.Deprecated public A withNewToken(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewSpecFluentImpl.java index 027d029382..73815b0a46 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewSpecFluentImpl.java @@ -1,111 +1,186 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1TokenReviewSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent{ - public V1TokenReviewSpecFluentImpl() { - } - public V1TokenReviewSpecFluentImpl(io.kubernetes.client.openapi.models.V1TokenReviewSpec instance) { +/** Generated */ +public class V1TokenReviewSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1TokenReviewSpecFluent { + public V1TokenReviewSpecFluentImpl() {} + + public V1TokenReviewSpecFluentImpl( + io.kubernetes.client.openapi.models.V1TokenReviewSpec instance) { this.withAudiences(instance.getAudiences()); this.withToken(instance.getToken()); - } + private java.util.List audiences; private java.lang.String token; - public A addToAudiences(java.lang.Integer index,java.lang.String item) { - if (this.audiences == null) {this.audiences = new java.util.ArrayList();} + + public A addToAudiences(java.lang.Integer index, java.lang.String item) { + if (this.audiences == null) { + this.audiences = new java.util.ArrayList(); + } this.audiences.add(index, item); - return (A)this; + return (A) this; } - public A setToAudiences(java.lang.Integer index,java.lang.String item) { - if (this.audiences == null) {this.audiences = new java.util.ArrayList();} - this.audiences.set(index, item); return (A)this; + + public A setToAudiences(java.lang.Integer index, java.lang.String item) { + if (this.audiences == null) { + this.audiences = new java.util.ArrayList(); + } + this.audiences.set(index, item); + return (A) this; } + public A addToAudiences(java.lang.String... items) { - if (this.audiences == null) {this.audiences = new java.util.ArrayList();} - for (java.lang.String item : items) {this.audiences.add(item);} return (A)this; + if (this.audiences == null) { + this.audiences = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.audiences.add(item); + } + return (A) this; } + public A addAllToAudiences(java.util.Collection items) { - if (this.audiences == null) {this.audiences = new java.util.ArrayList();} - for (java.lang.String item : items) {this.audiences.add(item);} return (A)this; + if (this.audiences == null) { + this.audiences = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.audiences.add(item); + } + return (A) this; } + public A removeFromAudiences(java.lang.String... items) { - for (java.lang.String item : items) {if (this.audiences!= null){ this.audiences.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.audiences != null) { + this.audiences.remove(item); + } + } + return (A) this; } + public A removeAllFromAudiences(java.util.Collection items) { - for (java.lang.String item : items) {if (this.audiences!= null){ this.audiences.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.audiences != null) { + this.audiences.remove(item); + } + } + return (A) this; } + public java.util.List getAudiences() { return this.audiences; } + public java.lang.String getAudience(java.lang.Integer index) { return this.audiences.get(index); } + public java.lang.String getFirstAudience() { return this.audiences.get(0); } + public java.lang.String getLastAudience() { return this.audiences.get(audiences.size() - 1); } - public java.lang.String getMatchingAudience(java.util.function.Predicate predicate) { - for (java.lang.String item: audiences) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAudience( + java.util.function.Predicate predicate) { + for (java.lang.String item : audiences) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAudience(java.util.function.Predicate predicate) { - for (java.lang.String item: audiences) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAudience( + java.util.function.Predicate predicate) { + for (java.lang.String item : audiences) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAudiences(java.util.List audiences) { - if (audiences != null) {this.audiences = new java.util.ArrayList(); for (java.lang.String item : audiences){this.addToAudiences(item);}} else { this.audiences = null;} return (A) this; + if (audiences != null) { + this.audiences = new java.util.ArrayList(); + for (java.lang.String item : audiences) { + this.addToAudiences(item); + } + } else { + this.audiences = null; + } + return (A) this; } + public A withAudiences(java.lang.String... audiences) { - if (this.audiences != null) {this.audiences.clear();} - if (audiences != null) {for (java.lang.String item :audiences){ this.addToAudiences(item);}} return (A) this; + if (this.audiences != null) { + this.audiences.clear(); + } + if (audiences != null) { + for (java.lang.String item : audiences) { + this.addToAudiences(item); + } + } + return (A) this; } + public java.lang.Boolean hasAudiences() { return audiences != null && !audiences.isEmpty(); } + public A addNewAudience(java.lang.String original) { - return (A)addToAudiences(new String(original)); + return (A) addToAudiences(new String(original)); } + public java.lang.String getToken() { return this.token; } + public A withToken(java.lang.String token) { - this.token=token; return (A) this; + this.token = token; + return (A) this; } + public java.lang.Boolean hasToken() { return this.token != null; } - - /** - * Method is deprecated. use withToken instead. - */ + + /** Method is deprecated. use withToken instead. */ @java.lang.Deprecated public A withNewToken(java.lang.String original) { - return (A)withToken(new String(original)); + return (A) withToken(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1TokenReviewSpecFluentImpl that = (V1TokenReviewSpecFluentImpl) o; - if (audiences != null ? !audiences.equals(that.audiences) :that.audiences != null) return false; - if (token != null ? !token.equals(that.token) :that.token != null) return false; + if (audiences != null ? !audiences.equals(that.audiences) : that.audiences != null) + return false; + if (token != null ? !token.equals(that.token) : that.token != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(audiences, token, super.hashCode()); + return java.util.Objects.hash(audiences, token, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewStatusBuilder.java index bc809e9565..4f7c5ffff1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1TokenReviewStatusBuilder extends io.kubernetes.client.openapi.models.V1TokenReviewStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1TokenReviewStatusBuilder + extends io.kubernetes.client.openapi.models.V1TokenReviewStatusFluentImpl< + io.kubernetes.client.openapi.models.V1TokenReviewStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1TokenReviewStatus, + io.kubernetes.client.openapi.models.V1TokenReviewStatusBuilder> { public V1TokenReviewStatusBuilder() { this(false); } + public V1TokenReviewStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1TokenReviewStatus(), validationEnabled); } - public V1TokenReviewStatusBuilder(io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent fluent) { + + public V1TokenReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent fluent) { this(fluent, false); } - public V1TokenReviewStatusBuilder(io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1TokenReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1TokenReviewStatus(), validationEnabled); } - public V1TokenReviewStatusBuilder(io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent fluent,io.kubernetes.client.openapi.models.V1TokenReviewStatus instance) { + + public V1TokenReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent fluent, + io.kubernetes.client.openapi.models.V1TokenReviewStatus instance) { this(fluent, instance, false); } - public V1TokenReviewStatusBuilder(io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent fluent,io.kubernetes.client.openapi.models.V1TokenReviewStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1TokenReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent fluent, + io.kubernetes.client.openapi.models.V1TokenReviewStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAudiences(instance.getAudiences()); fluent.withAuthenticated(instance.getAuthenticated()); @@ -29,13 +56,18 @@ public V1TokenReviewStatusBuilder(io.kubernetes.client.openapi.models.V1TokenRev fluent.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1TokenReviewStatusBuilder(io.kubernetes.client.openapi.models.V1TokenReviewStatus instance) { - this(instance,false); + + public V1TokenReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewStatus instance) { + this(instance, false); } - public V1TokenReviewStatusBuilder(io.kubernetes.client.openapi.models.V1TokenReviewStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1TokenReviewStatusBuilder( + io.kubernetes.client.openapi.models.V1TokenReviewStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAudiences(instance.getAudiences()); this.withAuthenticated(instance.getAuthenticated()); @@ -44,10 +76,12 @@ public V1TokenReviewStatusBuilder(io.kubernetes.client.openapi.models.V1TokenRev this.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1TokenReviewStatus build() { V1TokenReviewStatus buildable = new V1TokenReviewStatus(); buildable.setAudiences(fluent.getAudiences()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1TokenReviewStatus build() { buildable.setUser(fluent.getUser()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1TokenReviewStatusBuilder that = (V1TokenReviewStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewStatusFluent.java index 649211e9ee..4c666d3d16 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewStatusFluent.java @@ -1,68 +1,104 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1TokenReviewStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAudiences(java.lang.Integer index,java.lang.String item); - public A setToAudiences(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1TokenReviewStatusFluent< + A extends io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAudiences(java.lang.Integer index, java.lang.String item); + + public A setToAudiences(java.lang.Integer index, java.lang.String item); + public A addToAudiences(java.lang.String... items); + public A addAllToAudiences(java.util.Collection items); + public A removeFromAudiences(java.lang.String... items); + public A removeAllFromAudiences(java.util.Collection items); + public java.util.List getAudiences(); + public java.lang.String getAudience(java.lang.Integer index); + public java.lang.String getFirstAudience(); + public java.lang.String getLastAudience(); - public java.lang.String getMatchingAudience(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAudience(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAudience( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAudience( + java.util.function.Predicate predicate); + public A withAudiences(java.util.List audiences); + public A withAudiences(java.lang.String... audiences); + public java.lang.Boolean hasAudiences(); + public A addNewAudience(java.lang.String original); + public java.lang.Boolean getAuthenticated(); + public A withAuthenticated(java.lang.Boolean authenticated); + public java.lang.Boolean hasAuthenticated(); + public java.lang.String getError(); + public A withError(java.lang.String error); + public java.lang.Boolean hasError(); - - /** - * Method is deprecated. use withError instead. - */ + + /** Method is deprecated. use withError instead. */ @java.lang.Deprecated public A withNewError(java.lang.String original); - + /** * This method has been deprecated, please use method buildUser instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1UserInfo getUser(); + public io.kubernetes.client.openapi.models.V1UserInfo buildUser(); + public A withUser(io.kubernetes.client.openapi.models.V1UserInfo user); + public java.lang.Boolean hasUser(); + public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested withNewUser(); - public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested withNewUserLike(io.kubernetes.client.openapi.models.V1UserInfo item); + + public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested + withNewUserLike(io.kubernetes.client.openapi.models.V1UserInfo item); + public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested editUser(); - public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested editOrNewUser(); - public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested editOrNewUserLike(io.kubernetes.client.openapi.models.V1UserInfo item); - public interface UserNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1UserInfoFluent>{ + + public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested + editOrNewUser(); + + public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested + editOrNewUserLike(io.kubernetes.client.openapi.models.V1UserInfo item); + + public interface UserNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1UserInfoFluent< + io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested> { public N and(); + public N endUser(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewStatusFluentImpl.java index d4ab516ce5..81a355512b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TokenReviewStatusFluentImpl.java @@ -1,24 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1TokenReviewStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent{ - public V1TokenReviewStatusFluentImpl() { - } - public V1TokenReviewStatusFluentImpl(io.kubernetes.client.openapi.models.V1TokenReviewStatus instance) { +/** Generated */ +public class V1TokenReviewStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent { + public V1TokenReviewStatusFluentImpl() {} + + public V1TokenReviewStatusFluentImpl( + io.kubernetes.client.openapi.models.V1TokenReviewStatus instance) { this.withAudiences(instance.getAudiences()); this.withAuthenticated(instance.getAuthenticated()); @@ -26,154 +28,260 @@ public V1TokenReviewStatusFluentImpl(io.kubernetes.client.openapi.models.V1Token this.withError(instance.getError()); this.withUser(instance.getUser()); - } + private java.util.List audiences; private java.lang.Boolean authenticated; private java.lang.String error; private io.kubernetes.client.openapi.models.V1UserInfoBuilder user; - public A addToAudiences(java.lang.Integer index,java.lang.String item) { - if (this.audiences == null) {this.audiences = new java.util.ArrayList();} + + public A addToAudiences(java.lang.Integer index, java.lang.String item) { + if (this.audiences == null) { + this.audiences = new java.util.ArrayList(); + } this.audiences.add(index, item); - return (A)this; + return (A) this; } - public A setToAudiences(java.lang.Integer index,java.lang.String item) { - if (this.audiences == null) {this.audiences = new java.util.ArrayList();} - this.audiences.set(index, item); return (A)this; + + public A setToAudiences(java.lang.Integer index, java.lang.String item) { + if (this.audiences == null) { + this.audiences = new java.util.ArrayList(); + } + this.audiences.set(index, item); + return (A) this; } + public A addToAudiences(java.lang.String... items) { - if (this.audiences == null) {this.audiences = new java.util.ArrayList();} - for (java.lang.String item : items) {this.audiences.add(item);} return (A)this; + if (this.audiences == null) { + this.audiences = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.audiences.add(item); + } + return (A) this; } + public A addAllToAudiences(java.util.Collection items) { - if (this.audiences == null) {this.audiences = new java.util.ArrayList();} - for (java.lang.String item : items) {this.audiences.add(item);} return (A)this; + if (this.audiences == null) { + this.audiences = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.audiences.add(item); + } + return (A) this; } + public A removeFromAudiences(java.lang.String... items) { - for (java.lang.String item : items) {if (this.audiences!= null){ this.audiences.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.audiences != null) { + this.audiences.remove(item); + } + } + return (A) this; } + public A removeAllFromAudiences(java.util.Collection items) { - for (java.lang.String item : items) {if (this.audiences!= null){ this.audiences.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.audiences != null) { + this.audiences.remove(item); + } + } + return (A) this; } + public java.util.List getAudiences() { return this.audiences; } + public java.lang.String getAudience(java.lang.Integer index) { return this.audiences.get(index); } + public java.lang.String getFirstAudience() { return this.audiences.get(0); } + public java.lang.String getLastAudience() { return this.audiences.get(audiences.size() - 1); } - public java.lang.String getMatchingAudience(java.util.function.Predicate predicate) { - for (java.lang.String item: audiences) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAudience( + java.util.function.Predicate predicate) { + for (java.lang.String item : audiences) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAudience(java.util.function.Predicate predicate) { - for (java.lang.String item: audiences) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAudience( + java.util.function.Predicate predicate) { + for (java.lang.String item : audiences) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAudiences(java.util.List audiences) { - if (audiences != null) {this.audiences = new java.util.ArrayList(); for (java.lang.String item : audiences){this.addToAudiences(item);}} else { this.audiences = null;} return (A) this; + if (audiences != null) { + this.audiences = new java.util.ArrayList(); + for (java.lang.String item : audiences) { + this.addToAudiences(item); + } + } else { + this.audiences = null; + } + return (A) this; } + public A withAudiences(java.lang.String... audiences) { - if (this.audiences != null) {this.audiences.clear();} - if (audiences != null) {for (java.lang.String item :audiences){ this.addToAudiences(item);}} return (A) this; + if (this.audiences != null) { + this.audiences.clear(); + } + if (audiences != null) { + for (java.lang.String item : audiences) { + this.addToAudiences(item); + } + } + return (A) this; } + public java.lang.Boolean hasAudiences() { return audiences != null && !audiences.isEmpty(); } + public A addNewAudience(java.lang.String original) { - return (A)addToAudiences(new String(original)); + return (A) addToAudiences(new String(original)); } + public java.lang.Boolean getAuthenticated() { return this.authenticated; } + public A withAuthenticated(java.lang.Boolean authenticated) { - this.authenticated=authenticated; return (A) this; + this.authenticated = authenticated; + return (A) this; } + public java.lang.Boolean hasAuthenticated() { return this.authenticated != null; } + public java.lang.String getError() { return this.error; } + public A withError(java.lang.String error) { - this.error=error; return (A) this; + this.error = error; + return (A) this; } + public java.lang.Boolean hasError() { return this.error != null; } - - /** - * Method is deprecated. use withError instead. - */ + + /** Method is deprecated. use withError instead. */ @java.lang.Deprecated public A withNewError(java.lang.String original) { - return (A)withError(new String(original)); + return (A) withError(new String(original)); } - + /** * This method has been deprecated, please use method buildUser instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1UserInfo getUser() { - return this.user!=null ?this.user.build():null; + return this.user != null ? this.user.build() : null; } + public io.kubernetes.client.openapi.models.V1UserInfo buildUser() { - return this.user!=null ?this.user.build():null; + return this.user != null ? this.user.build() : null; } + public A withUser(io.kubernetes.client.openapi.models.V1UserInfo user) { _visitables.get("user").remove(this.user); - if (user!=null){ this.user= new io.kubernetes.client.openapi.models.V1UserInfoBuilder(user); _visitables.get("user").add(this.user);} return (A) this; + if (user != null) { + this.user = new io.kubernetes.client.openapi.models.V1UserInfoBuilder(user); + _visitables.get("user").add(this.user); + } + return (A) this; } + public java.lang.Boolean hasUser() { return this.user != null; } + public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested withNewUser() { return new io.kubernetes.client.openapi.models.V1TokenReviewStatusFluentImpl.UserNestedImpl(); } - public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested withNewUserLike(io.kubernetes.client.openapi.models.V1UserInfo item) { - return new io.kubernetes.client.openapi.models.V1TokenReviewStatusFluentImpl.UserNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested + withNewUserLike(io.kubernetes.client.openapi.models.V1UserInfo item) { + return new io.kubernetes.client.openapi.models.V1TokenReviewStatusFluentImpl.UserNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested editUser() { return withNewUserLike(getUser()); } - public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested editOrNewUser() { - return withNewUserLike(getUser() != null ? getUser(): new io.kubernetes.client.openapi.models.V1UserInfoBuilder().build()); + + public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested + editOrNewUser() { + return withNewUserLike( + getUser() != null + ? getUser() + : new io.kubernetes.client.openapi.models.V1UserInfoBuilder().build()); } - public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested editOrNewUserLike(io.kubernetes.client.openapi.models.V1UserInfo item) { - return withNewUserLike(getUser() != null ? getUser(): item); + + public io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested + editOrNewUserLike(io.kubernetes.client.openapi.models.V1UserInfo item) { + return withNewUserLike(getUser() != null ? getUser() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1TokenReviewStatusFluentImpl that = (V1TokenReviewStatusFluentImpl) o; - if (audiences != null ? !audiences.equals(that.audiences) :that.audiences != null) return false; - if (authenticated != null ? !authenticated.equals(that.authenticated) :that.authenticated != null) return false; - if (error != null ? !error.equals(that.error) :that.error != null) return false; - if (user != null ? !user.equals(that.user) :that.user != null) return false; + if (audiences != null ? !audiences.equals(that.audiences) : that.audiences != null) + return false; + if (authenticated != null + ? !authenticated.equals(that.authenticated) + : that.authenticated != null) return false; + if (error != null ? !error.equals(that.error) : that.error != null) return false; + if (user != null ? !user.equals(that.user) : that.user != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(audiences, authenticated, error, user, super.hashCode()); + return java.util.Objects.hash(audiences, authenticated, error, user, super.hashCode()); } - public class UserNestedImpl extends io.kubernetes.client.openapi.models.V1UserInfoFluentImpl> implements io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested,io.kubernetes.client.fluent.Nested{ + + public class UserNestedImpl + extends io.kubernetes.client.openapi.models.V1UserInfoFluentImpl< + io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested> + implements io.kubernetes.client.openapi.models.V1TokenReviewStatusFluent.UserNested, + io.kubernetes.client.fluent.Nested { UserNestedImpl(io.kubernetes.client.openapi.models.V1UserInfo item) { this.builder = new io.kubernetes.client.openapi.models.V1UserInfoBuilder(this, item); } + UserNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1UserInfoBuilder(this); } + io.kubernetes.client.openapi.models.V1UserInfoBuilder builder; + public N and() { return (N) V1TokenReviewStatusFluentImpl.this.withUser(builder.build()); } + public N endUser() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TolerationBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TolerationBuilder.java index 71b28cf5ba..44d8a691f3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TolerationBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TolerationBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1TolerationBuilder extends io.kubernetes.client.openapi.models.V1TolerationFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1TolerationBuilder + extends io.kubernetes.client.openapi.models.V1TolerationFluentImpl< + io.kubernetes.client.openapi.models.V1TolerationBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Toleration, + io.kubernetes.client.openapi.models.V1TolerationBuilder> { public V1TolerationBuilder() { this(false); } + public V1TolerationBuilder(java.lang.Boolean validationEnabled) { this(new V1Toleration(), validationEnabled); } + public V1TolerationBuilder(io.kubernetes.client.openapi.models.V1TolerationFluent fluent) { this(fluent, false); } - public V1TolerationBuilder(io.kubernetes.client.openapi.models.V1TolerationFluent fluent,java.lang.Boolean validationEnabled) { + + public V1TolerationBuilder( + io.kubernetes.client.openapi.models.V1TolerationFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Toleration(), validationEnabled); } - public V1TolerationBuilder(io.kubernetes.client.openapi.models.V1TolerationFluent fluent,io.kubernetes.client.openapi.models.V1Toleration instance) { + + public V1TolerationBuilder( + io.kubernetes.client.openapi.models.V1TolerationFluent fluent, + io.kubernetes.client.openapi.models.V1Toleration instance) { this(fluent, instance, false); } - public V1TolerationBuilder(io.kubernetes.client.openapi.models.V1TolerationFluent fluent,io.kubernetes.client.openapi.models.V1Toleration instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1TolerationBuilder( + io.kubernetes.client.openapi.models.V1TolerationFluent fluent, + io.kubernetes.client.openapi.models.V1Toleration instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withEffect(instance.getEffect()); fluent.withKey(instance.getKey()); @@ -31,13 +57,17 @@ public V1TolerationBuilder(io.kubernetes.client.openapi.models.V1TolerationFluen fluent.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1TolerationBuilder(io.kubernetes.client.openapi.models.V1Toleration instance) { - this(instance,false); + this(instance, false); } - public V1TolerationBuilder(io.kubernetes.client.openapi.models.V1Toleration instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1TolerationBuilder( + io.kubernetes.client.openapi.models.V1Toleration instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withEffect(instance.getEffect()); this.withKey(instance.getKey()); @@ -48,10 +78,12 @@ public V1TolerationBuilder(io.kubernetes.client.openapi.models.V1Toleration inst this.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1TolerationFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Toleration build() { V1Toleration buildable = new V1Toleration(); buildable.setEffect(fluent.getEffect()); @@ -61,18 +93,23 @@ public io.kubernetes.client.openapi.models.V1Toleration build() { buildable.setValue(fluent.getValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1TolerationBuilder that = (V1TolerationBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TolerationFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TolerationFluent.java index 3912fdf349..db88dbac0f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TolerationFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TolerationFluent.java @@ -1,42 +1,56 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Long; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1TolerationFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1TolerationFluent< + A extends io.kubernetes.client.openapi.models.V1TolerationFluent> + extends io.kubernetes.client.fluent.Fluent { public io.kubernetes.client.openapi.models.V1Toleration.EffectEnum getEffect(); + public A withEffect(io.kubernetes.client.openapi.models.V1Toleration.EffectEnum effect); + public java.lang.Boolean hasEffect(); + public java.lang.String getKey(); + public A withKey(java.lang.String key); + public java.lang.Boolean hasKey(); - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original); + public io.kubernetes.client.openapi.models.V1Toleration.OperatorEnum getOperator(); + public A withOperator(io.kubernetes.client.openapi.models.V1Toleration.OperatorEnum operator); + public java.lang.Boolean hasOperator(); + public java.lang.Long getTolerationSeconds(); + public A withTolerationSeconds(java.lang.Long tolerationSeconds); + public java.lang.Boolean hasTolerationSeconds(); + public java.lang.String getValue(); + public A withValue(java.lang.String value); + public java.lang.Boolean hasValue(); - - /** - * Method is deprecated. use withValue instead. - */ + + /** Method is deprecated. use withValue instead. */ @java.lang.Deprecated public A withNewValue(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TolerationFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TolerationFluentImpl.java index 384d008c13..5219db5040 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TolerationFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TolerationFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1TolerationFluentImpl< + A extends io.kubernetes.client.openapi.models.V1TolerationFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1TolerationFluent { + public V1TolerationFluentImpl() {} - /** - * Generated - */ -public class V1TolerationFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1TolerationFluent{ - public V1TolerationFluentImpl() { - } public V1TolerationFluentImpl(io.kubernetes.client.openapi.models.V1Toleration instance) { this.withEffect(instance.getEffect()); @@ -23,87 +29,107 @@ public V1TolerationFluentImpl(io.kubernetes.client.openapi.models.V1Toleration i this.withTolerationSeconds(instance.getTolerationSeconds()); this.withValue(instance.getValue()); - } + private io.kubernetes.client.openapi.models.V1Toleration.EffectEnum effect; private java.lang.String key; private io.kubernetes.client.openapi.models.V1Toleration.OperatorEnum operator; private java.lang.Long tolerationSeconds; private java.lang.String value; + public io.kubernetes.client.openapi.models.V1Toleration.EffectEnum getEffect() { return this.effect; } + public A withEffect(io.kubernetes.client.openapi.models.V1Toleration.EffectEnum effect) { - this.effect=effect; return (A) this; + this.effect = effect; + return (A) this; } + public java.lang.Boolean hasEffect() { return this.effect != null; } + public java.lang.String getKey() { return this.key; } + public A withKey(java.lang.String key) { - this.key=key; return (A) this; + this.key = key; + return (A) this; } + public java.lang.Boolean hasKey() { return this.key != null; } - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original) { - return (A)withKey(new String(original)); + return (A) withKey(new String(original)); } + public io.kubernetes.client.openapi.models.V1Toleration.OperatorEnum getOperator() { return this.operator; } + public A withOperator(io.kubernetes.client.openapi.models.V1Toleration.OperatorEnum operator) { - this.operator=operator; return (A) this; + this.operator = operator; + return (A) this; } + public java.lang.Boolean hasOperator() { return this.operator != null; } + public java.lang.Long getTolerationSeconds() { return this.tolerationSeconds; } + public A withTolerationSeconds(java.lang.Long tolerationSeconds) { - this.tolerationSeconds=tolerationSeconds; return (A) this; + this.tolerationSeconds = tolerationSeconds; + return (A) this; } + public java.lang.Boolean hasTolerationSeconds() { return this.tolerationSeconds != null; } + public java.lang.String getValue() { return this.value; } + public A withValue(java.lang.String value) { - this.value=value; return (A) this; + this.value = value; + return (A) this; } + public java.lang.Boolean hasValue() { return this.value != null; } - - /** - * Method is deprecated. use withValue instead. - */ + + /** Method is deprecated. use withValue instead. */ @java.lang.Deprecated public A withNewValue(java.lang.String original) { - return (A)withValue(new String(original)); + return (A) withValue(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1TolerationFluentImpl that = (V1TolerationFluentImpl) o; - if (effect != null ? !effect.equals(that.effect) :that.effect != null) return false; - if (key != null ? !key.equals(that.key) :that.key != null) return false; - if (operator != null ? !operator.equals(that.operator) :that.operator != null) return false; - if (tolerationSeconds != null ? !tolerationSeconds.equals(that.tolerationSeconds) :that.tolerationSeconds != null) return false; - if (value != null ? !value.equals(that.value) :that.value != null) return false; + if (effect != null ? !effect.equals(that.effect) : that.effect != null) return false; + if (key != null ? !key.equals(that.key) : that.key != null) return false; + if (operator != null ? !operator.equals(that.operator) : that.operator != null) return false; + if (tolerationSeconds != null + ? !tolerationSeconds.equals(that.tolerationSeconds) + : that.tolerationSeconds != null) return false; + if (value != null ? !value.equals(that.value) : that.value != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(effect, key, operator, tolerationSeconds, value, super.hashCode()); + return java.util.Objects.hash( + effect, key, operator, tolerationSeconds, value, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorLabelRequirementBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorLabelRequirementBuilder.java index 919acc95f5..e3a4877b97 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorLabelRequirementBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorLabelRequirementBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1TopologySelectorLabelRequirementBuilder extends io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1TopologySelectorLabelRequirementBuilder + extends io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluentImpl< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement, + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder> { public V1TopologySelectorLabelRequirementBuilder() { this(false); } + public V1TopologySelectorLabelRequirementBuilder(java.lang.Boolean validationEnabled) { this(new V1TopologySelectorLabelRequirement(), validationEnabled); } - public V1TopologySelectorLabelRequirementBuilder(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent fluent) { + + public V1TopologySelectorLabelRequirementBuilder( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent fluent) { this(fluent, false); } - public V1TopologySelectorLabelRequirementBuilder(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent fluent,java.lang.Boolean validationEnabled) { + + public V1TopologySelectorLabelRequirementBuilder( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1TopologySelectorLabelRequirement(), validationEnabled); } - public V1TopologySelectorLabelRequirementBuilder(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent fluent,io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement instance) { + + public V1TopologySelectorLabelRequirementBuilder( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent fluent, + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement instance) { this(fluent, instance, false); } - public V1TopologySelectorLabelRequirementBuilder(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent fluent,io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1TopologySelectorLabelRequirementBuilder( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent fluent, + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withKey(instance.getKey()); fluent.withValues(instance.getValues()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1TopologySelectorLabelRequirementBuilder(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement instance) { - this(instance,false); + + public V1TopologySelectorLabelRequirementBuilder( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement instance) { + this(instance, false); } - public V1TopologySelectorLabelRequirementBuilder(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1TopologySelectorLabelRequirementBuilder( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withKey(instance.getKey()); this.withValues(instance.getValues()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement build() { V1TopologySelectorLabelRequirement buildable = new V1TopologySelectorLabelRequirement(); buildable.setKey(fluent.getKey()); buildable.setValues(fluent.getValues()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1TopologySelectorLabelRequirementBuilder that = (V1TopologySelectorLabelRequirementBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorLabelRequirementFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorLabelRequirementFluent.java index f3cd770a7c..6098242355 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorLabelRequirementFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorLabelRequirementFluent.java @@ -1,44 +1,62 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1TopologySelectorLabelRequirementFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1TopologySelectorLabelRequirementFluent< + A extends io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getKey(); + public A withKey(java.lang.String key); + public java.lang.Boolean hasKey(); - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original); - public A addToValues(java.lang.Integer index,java.lang.String item); - public A setToValues(java.lang.Integer index,java.lang.String item); + + public A addToValues(java.lang.Integer index, java.lang.String item); + + public A setToValues(java.lang.Integer index, java.lang.String item); + public A addToValues(java.lang.String... items); + public A addAllToValues(java.util.Collection items); + public A removeFromValues(java.lang.String... items); + public A removeAllFromValues(java.util.Collection items); + public java.util.List getValues(); + public java.lang.String getValue(java.lang.Integer index); + public java.lang.String getFirstValue(); + public java.lang.String getLastValue(); - public java.lang.String getMatchingValue(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingValue(java.util.function.Predicate predicate); + + public java.lang.String getMatchingValue( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingValue( + java.util.function.Predicate predicate); + public A withValues(java.util.List values); + public A withValues(java.lang.String... values); + public java.lang.Boolean hasValues(); + public A addNewValue(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorLabelRequirementFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorLabelRequirementFluentImpl.java index c124519107..3d76192a45 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorLabelRequirementFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorLabelRequirementFluentImpl.java @@ -1,111 +1,186 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1TopologySelectorLabelRequirementFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent{ - public V1TopologySelectorLabelRequirementFluentImpl() { - } - public V1TopologySelectorLabelRequirementFluentImpl(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement instance) { +/** Generated */ +public class V1TopologySelectorLabelRequirementFluentImpl< + A extends io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent { + public V1TopologySelectorLabelRequirementFluentImpl() {} + + public V1TopologySelectorLabelRequirementFluentImpl( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement instance) { this.withKey(instance.getKey()); this.withValues(instance.getValues()); - } + private java.lang.String key; private java.util.List values; + public java.lang.String getKey() { return this.key; } + public A withKey(java.lang.String key) { - this.key=key; return (A) this; + this.key = key; + return (A) this; } + public java.lang.Boolean hasKey() { return this.key != null; } - - /** - * Method is deprecated. use withKey instead. - */ + + /** Method is deprecated. use withKey instead. */ @java.lang.Deprecated public A withNewKey(java.lang.String original) { - return (A)withKey(new String(original)); + return (A) withKey(new String(original)); } - public A addToValues(java.lang.Integer index,java.lang.String item) { - if (this.values == null) {this.values = new java.util.ArrayList();} + + public A addToValues(java.lang.Integer index, java.lang.String item) { + if (this.values == null) { + this.values = new java.util.ArrayList(); + } this.values.add(index, item); - return (A)this; + return (A) this; } - public A setToValues(java.lang.Integer index,java.lang.String item) { - if (this.values == null) {this.values = new java.util.ArrayList();} - this.values.set(index, item); return (A)this; + + public A setToValues(java.lang.Integer index, java.lang.String item) { + if (this.values == null) { + this.values = new java.util.ArrayList(); + } + this.values.set(index, item); + return (A) this; } + public A addToValues(java.lang.String... items) { - if (this.values == null) {this.values = new java.util.ArrayList();} - for (java.lang.String item : items) {this.values.add(item);} return (A)this; + if (this.values == null) { + this.values = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.values.add(item); + } + return (A) this; } + public A addAllToValues(java.util.Collection items) { - if (this.values == null) {this.values = new java.util.ArrayList();} - for (java.lang.String item : items) {this.values.add(item);} return (A)this; + if (this.values == null) { + this.values = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.values.add(item); + } + return (A) this; } + public A removeFromValues(java.lang.String... items) { - for (java.lang.String item : items) {if (this.values!= null){ this.values.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.values != null) { + this.values.remove(item); + } + } + return (A) this; } + public A removeAllFromValues(java.util.Collection items) { - for (java.lang.String item : items) {if (this.values!= null){ this.values.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.values != null) { + this.values.remove(item); + } + } + return (A) this; } + public java.util.List getValues() { return this.values; } + public java.lang.String getValue(java.lang.Integer index) { return this.values.get(index); } + public java.lang.String getFirstValue() { return this.values.get(0); } + public java.lang.String getLastValue() { return this.values.get(values.size() - 1); } - public java.lang.String getMatchingValue(java.util.function.Predicate predicate) { - for (java.lang.String item: values) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingValue( + java.util.function.Predicate predicate) { + for (java.lang.String item : values) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingValue(java.util.function.Predicate predicate) { - for (java.lang.String item: values) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingValue( + java.util.function.Predicate predicate) { + for (java.lang.String item : values) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withValues(java.util.List values) { - if (values != null) {this.values = new java.util.ArrayList(); for (java.lang.String item : values){this.addToValues(item);}} else { this.values = null;} return (A) this; + if (values != null) { + this.values = new java.util.ArrayList(); + for (java.lang.String item : values) { + this.addToValues(item); + } + } else { + this.values = null; + } + return (A) this; } + public A withValues(java.lang.String... values) { - if (this.values != null) {this.values.clear();} - if (values != null) {for (java.lang.String item :values){ this.addToValues(item);}} return (A) this; + if (this.values != null) { + this.values.clear(); + } + if (values != null) { + for (java.lang.String item : values) { + this.addToValues(item); + } + } + return (A) this; } + public java.lang.Boolean hasValues() { return values != null && !values.isEmpty(); } + public A addNewValue(java.lang.String original) { - return (A)addToValues(new String(original)); + return (A) addToValues(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1TopologySelectorLabelRequirementFluentImpl that = (V1TopologySelectorLabelRequirementFluentImpl) o; - if (key != null ? !key.equals(that.key) :that.key != null) return false; - if (values != null ? !values.equals(that.values) :that.values != null) return false; + V1TopologySelectorLabelRequirementFluentImpl that = + (V1TopologySelectorLabelRequirementFluentImpl) o; + if (key != null ? !key.equals(that.key) : that.key != null) return false; + if (values != null ? !values.equals(that.values) : that.values != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(key, values, super.hashCode()); + return java.util.Objects.hash(key, values, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorTermBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorTermBuilder.java index 2d9d1443c2..0af98d24a2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorTermBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorTermBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1TopologySelectorTermBuilder extends io.kubernetes.client.openapi.models.V1TopologySelectorTermFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1TopologySelectorTermBuilder + extends io.kubernetes.client.openapi.models.V1TopologySelectorTermFluentImpl< + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1TopologySelectorTerm, + io.kubernetes.client.openapi.models.V1TopologySelectorTermBuilder> { public V1TopologySelectorTermBuilder() { this(false); } + public V1TopologySelectorTermBuilder(java.lang.Boolean validationEnabled) { this(new V1TopologySelectorTerm(), validationEnabled); } - public V1TopologySelectorTermBuilder(io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent fluent) { + + public V1TopologySelectorTermBuilder( + io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent fluent) { this(fluent, false); } - public V1TopologySelectorTermBuilder(io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent fluent,java.lang.Boolean validationEnabled) { + + public V1TopologySelectorTermBuilder( + io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1TopologySelectorTerm(), validationEnabled); } - public V1TopologySelectorTermBuilder(io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent fluent,io.kubernetes.client.openapi.models.V1TopologySelectorTerm instance) { + + public V1TopologySelectorTermBuilder( + io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent fluent, + io.kubernetes.client.openapi.models.V1TopologySelectorTerm instance) { this(fluent, instance, false); } - public V1TopologySelectorTermBuilder(io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent fluent,io.kubernetes.client.openapi.models.V1TopologySelectorTerm instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1TopologySelectorTermBuilder( + io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent fluent, + io.kubernetes.client.openapi.models.V1TopologySelectorTerm instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMatchLabelExpressions(instance.getMatchLabelExpressions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1TopologySelectorTermBuilder(io.kubernetes.client.openapi.models.V1TopologySelectorTerm instance) { - this(instance,false); + + public V1TopologySelectorTermBuilder( + io.kubernetes.client.openapi.models.V1TopologySelectorTerm instance) { + this(instance, false); } - public V1TopologySelectorTermBuilder(io.kubernetes.client.openapi.models.V1TopologySelectorTerm instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1TopologySelectorTermBuilder( + io.kubernetes.client.openapi.models.V1TopologySelectorTerm instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMatchLabelExpressions(instance.getMatchLabelExpressions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1TopologySelectorTerm build() { V1TopologySelectorTerm buildable = new V1TopologySelectorTerm(); buildable.setMatchLabelExpressions(fluent.getMatchLabelExpressions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1TopologySelectorTermBuilder that = (V1TopologySelectorTermBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorTermFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorTermFluent.java index 38170e3ccf..3dbab4862c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorTermFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorTermFluent.java @@ -1,57 +1,139 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1TopologySelectorTermFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToMatchLabelExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item); - public A setToMatchLabelExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item); - public A addToMatchLabelExpressions(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement... items); - public A addAllToMatchLabelExpressions(java.util.Collection items); - public A removeFromMatchLabelExpressions(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement... items); - public A removeAllFromMatchLabelExpressions(java.util.Collection items); - public A removeMatchingFromMatchLabelExpressions(java.util.function.Predicate predicate); - +/** Generated */ +public interface V1TopologySelectorTermFluent< + A extends io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToMatchLabelExpressions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item); + + public A setToMatchLabelExpressions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item); + + public A addToMatchLabelExpressions( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement... items); + + public A addAllToMatchLabelExpressions( + java.util.Collection + items); + + public A removeFromMatchLabelExpressions( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement... items); + + public A removeAllFromMatchLabelExpressions( + java.util.Collection + items); + + public A removeMatchingFromMatchLabelExpressions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder> + predicate); + /** * This method has been deprecated, please use method buildMatchLabelExpressions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getMatchLabelExpressions(); - public java.util.List buildMatchLabelExpressions(); - public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement buildMatchLabelExpression(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement buildFirstMatchLabelExpression(); - public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement buildLastMatchLabelExpression(); - public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement buildMatchingMatchLabelExpression(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMatchLabelExpression(java.util.function.Predicate predicate); - public A withMatchLabelExpressions(java.util.List matchLabelExpressions); - public A withMatchLabelExpressions(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement... matchLabelExpressions); + public java.util.List + getMatchLabelExpressions(); + + public java.util.List + buildMatchLabelExpressions(); + + public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement + buildMatchLabelExpression(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement + buildFirstMatchLabelExpression(); + + public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement + buildLastMatchLabelExpression(); + + public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement + buildMatchingMatchLabelExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder> + predicate); + + public java.lang.Boolean hasMatchingMatchLabelExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder> + predicate); + + public A withMatchLabelExpressions( + java.util.List + matchLabelExpressions); + + public A withMatchLabelExpressions( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement... + matchLabelExpressions); + public java.lang.Boolean hasMatchLabelExpressions(); - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested addNewMatchLabelExpression(); - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested addNewMatchLabelExpressionLike(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item); - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested setNewMatchLabelExpressionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item); - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested editMatchLabelExpression(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested editFirstMatchLabelExpression(); - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested editLastMatchLabelExpression(); - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested editMatchingMatchLabelExpression(java.util.function.Predicate predicate); - public interface MatchLabelExpressionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent>{ + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + addNewMatchLabelExpression(); + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + addNewMatchLabelExpressionLike( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item); + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + setNewMatchLabelExpressionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item); + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + editMatchLabelExpression(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + editFirstMatchLabelExpression(); + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + editLastMatchLabelExpression(); + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + editMatchingMatchLabelExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder> + predicate); + + public interface MatchLabelExpressionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluent< + io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + N>> { public N and(); + public N endMatchLabelExpression(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorTermFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorTermFluentImpl.java index 8a222ef91c..13d04b8407 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorTermFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySelectorTermFluentImpl.java @@ -1,163 +1,372 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1TopologySelectorTermFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent{ - public V1TopologySelectorTermFluentImpl() { - } - public V1TopologySelectorTermFluentImpl(io.kubernetes.client.openapi.models.V1TopologySelectorTerm instance) { - this.withMatchLabelExpressions(instance.getMatchLabelExpressions()); +/** Generated */ +public class V1TopologySelectorTermFluentImpl< + A extends io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent { + public V1TopologySelectorTermFluentImpl() {} + public V1TopologySelectorTermFluentImpl( + io.kubernetes.client.openapi.models.V1TopologySelectorTerm instance) { + this.withMatchLabelExpressions(instance.getMatchLabelExpressions()); } - private java.util.ArrayList matchLabelExpressions; - public A addToMatchLabelExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item) { - if (this.matchLabelExpressions == null) {this.matchLabelExpressions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(item);_visitables.get("matchLabelExpressions").add(index >= 0 ? index : _visitables.get("matchLabelExpressions").size(), builder);this.matchLabelExpressions.add(index >= 0 ? index : matchLabelExpressions.size(), builder); return (A)this; + + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder> + matchLabelExpressions; + + public A addToMatchLabelExpressions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item) { + if (this.matchLabelExpressions == null) { + this.matchLabelExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder>(); + } + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(item); + _visitables + .get("matchLabelExpressions") + .add(index >= 0 ? index : _visitables.get("matchLabelExpressions").size(), builder); + this.matchLabelExpressions.add(index >= 0 ? index : matchLabelExpressions.size(), builder); + return (A) this; } - public A setToMatchLabelExpressions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item) { - if (this.matchLabelExpressions == null) {this.matchLabelExpressions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(item); - if (index < 0 || index >= _visitables.get("matchLabelExpressions").size()) { _visitables.get("matchLabelExpressions").add(builder); } else { _visitables.get("matchLabelExpressions").set(index, builder);} - if (index < 0 || index >= matchLabelExpressions.size()) { matchLabelExpressions.add(builder); } else { matchLabelExpressions.set(index, builder);} - return (A)this; + + public A setToMatchLabelExpressions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item) { + if (this.matchLabelExpressions == null) { + this.matchLabelExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder>(); + } + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(item); + if (index < 0 || index >= _visitables.get("matchLabelExpressions").size()) { + _visitables.get("matchLabelExpressions").add(builder); + } else { + _visitables.get("matchLabelExpressions").set(index, builder); + } + if (index < 0 || index >= matchLabelExpressions.size()) { + matchLabelExpressions.add(builder); + } else { + matchLabelExpressions.set(index, builder); + } + return (A) this; } - public A addToMatchLabelExpressions(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement... items) { - if (this.matchLabelExpressions == null) {this.matchLabelExpressions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item : items) {io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(item);_visitables.get("matchLabelExpressions").add(builder);this.matchLabelExpressions.add(builder);} return (A)this; + + public A addToMatchLabelExpressions( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement... items) { + if (this.matchLabelExpressions == null) { + this.matchLabelExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item : items) { + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(item); + _visitables.get("matchLabelExpressions").add(builder); + this.matchLabelExpressions.add(builder); + } + return (A) this; } - public A addAllToMatchLabelExpressions(java.util.Collection items) { - if (this.matchLabelExpressions == null) {this.matchLabelExpressions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item : items) {io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(item);_visitables.get("matchLabelExpressions").add(builder);this.matchLabelExpressions.add(builder);} return (A)this; + + public A addAllToMatchLabelExpressions( + java.util.Collection + items) { + if (this.matchLabelExpressions == null) { + this.matchLabelExpressions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item : items) { + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(item); + _visitables.get("matchLabelExpressions").add(builder); + this.matchLabelExpressions.add(builder); + } + return (A) this; } - public A removeFromMatchLabelExpressions(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement... items) { - for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item : items) {io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(item);_visitables.get("matchLabelExpressions").remove(builder);if (this.matchLabelExpressions != null) {this.matchLabelExpressions.remove(builder);}} return (A)this; + + public A removeFromMatchLabelExpressions( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement... items) { + for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item : items) { + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(item); + _visitables.get("matchLabelExpressions").remove(builder); + if (this.matchLabelExpressions != null) { + this.matchLabelExpressions.remove(builder); + } + } + return (A) this; } - public A removeAllFromMatchLabelExpressions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item : items) {io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(item);_visitables.get("matchLabelExpressions").remove(builder);if (this.matchLabelExpressions != null) {this.matchLabelExpressions.remove(builder);}} return (A)this; + + public A removeAllFromMatchLabelExpressions( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item : items) { + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(item); + _visitables.get("matchLabelExpressions").remove(builder); + if (this.matchLabelExpressions != null) { + this.matchLabelExpressions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromMatchLabelExpressions(java.util.function.Predicate predicate) { + + public A removeMatchingFromMatchLabelExpressions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder> + predicate) { if (matchLabelExpressions == null) return (A) this; - final Iterator each = matchLabelExpressions.iterator(); + final Iterator + each = matchLabelExpressions.iterator(); final List visitables = _visitables.get("matchLabelExpressions"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildMatchLabelExpressions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getMatchLabelExpressions() { + public java.util.List + getMatchLabelExpressions() { return matchLabelExpressions != null ? build(matchLabelExpressions) : null; } - public java.util.List buildMatchLabelExpressions() { + + public java.util.List + buildMatchLabelExpressions() { return matchLabelExpressions != null ? build(matchLabelExpressions) : null; } - public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement buildMatchLabelExpression(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement + buildMatchLabelExpression(java.lang.Integer index) { return this.matchLabelExpressions.get(index).build(); } - public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement buildFirstMatchLabelExpression() { + + public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement + buildFirstMatchLabelExpression() { return this.matchLabelExpressions.get(0).build(); } - public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement buildLastMatchLabelExpression() { + + public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement + buildLastMatchLabelExpression() { return this.matchLabelExpressions.get(matchLabelExpressions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement buildMatchingMatchLabelExpression(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder item: matchLabelExpressions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement + buildMatchingMatchLabelExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder item : + matchLabelExpressions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingMatchLabelExpression(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder item: matchLabelExpressions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMatchLabelExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder item : + matchLabelExpressions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withMatchLabelExpressions(java.util.List matchLabelExpressions) { - if (this.matchLabelExpressions != null) { _visitables.get("matchLabelExpressions").removeAll(this.matchLabelExpressions);} - if (matchLabelExpressions != null) {this.matchLabelExpressions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item : matchLabelExpressions){this.addToMatchLabelExpressions(item);}} else { this.matchLabelExpressions = null;} return (A) this; + + public A withMatchLabelExpressions( + java.util.List + matchLabelExpressions) { + if (this.matchLabelExpressions != null) { + _visitables.get("matchLabelExpressions").removeAll(this.matchLabelExpressions); + } + if (matchLabelExpressions != null) { + this.matchLabelExpressions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item : + matchLabelExpressions) { + this.addToMatchLabelExpressions(item); + } + } else { + this.matchLabelExpressions = null; + } + return (A) this; } - public A withMatchLabelExpressions(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement... matchLabelExpressions) { - if (this.matchLabelExpressions != null) {this.matchLabelExpressions.clear();} - if (matchLabelExpressions != null) {for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item :matchLabelExpressions){ this.addToMatchLabelExpressions(item);}} return (A) this; + + public A withMatchLabelExpressions( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement... + matchLabelExpressions) { + if (this.matchLabelExpressions != null) { + this.matchLabelExpressions.clear(); + } + if (matchLabelExpressions != null) { + for (io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item : + matchLabelExpressions) { + this.addToMatchLabelExpressions(item); + } + } + return (A) this; } + public java.lang.Boolean hasMatchLabelExpressions() { return matchLabelExpressions != null && !matchLabelExpressions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested addNewMatchLabelExpression() { - return new io.kubernetes.client.openapi.models.V1TopologySelectorTermFluentImpl.MatchLabelExpressionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + addNewMatchLabelExpression() { + return new io.kubernetes.client.openapi.models.V1TopologySelectorTermFluentImpl + .MatchLabelExpressionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested addNewMatchLabelExpressionLike(io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item) { - return new io.kubernetes.client.openapi.models.V1TopologySelectorTermFluentImpl.MatchLabelExpressionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + addNewMatchLabelExpressionLike( + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item) { + return new io.kubernetes.client.openapi.models.V1TopologySelectorTermFluentImpl + .MatchLabelExpressionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested setNewMatchLabelExpressionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item) { - return new io.kubernetes.client.openapi.models.V1TopologySelectorTermFluentImpl.MatchLabelExpressionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + setNewMatchLabelExpressionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item) { + return new io.kubernetes.client.openapi.models.V1TopologySelectorTermFluentImpl + .MatchLabelExpressionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested editMatchLabelExpression(java.lang.Integer index) { - if (matchLabelExpressions.size() <= index) throw new RuntimeException("Can't edit matchLabelExpressions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + editMatchLabelExpression(java.lang.Integer index) { + if (matchLabelExpressions.size() <= index) + throw new RuntimeException("Can't edit matchLabelExpressions. Index exceeds size."); return setNewMatchLabelExpressionLike(index, buildMatchLabelExpression(index)); } - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested editFirstMatchLabelExpression() { - if (matchLabelExpressions.size() == 0) throw new RuntimeException("Can't edit first matchLabelExpressions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + editFirstMatchLabelExpression() { + if (matchLabelExpressions.size() == 0) + throw new RuntimeException("Can't edit first matchLabelExpressions. The list is empty."); return setNewMatchLabelExpressionLike(0, buildMatchLabelExpression(0)); } - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested editLastMatchLabelExpression() { + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + editLastMatchLabelExpression() { int index = matchLabelExpressions.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last matchLabelExpressions. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last matchLabelExpressions. The list is empty."); return setNewMatchLabelExpressionLike(index, buildMatchLabelExpression(index)); } - public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested editMatchingMatchLabelExpression(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + A> + editMatchingMatchLabelExpression( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluentImpl> implements io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent.MatchLabelExpressionsNested,io.kubernetes.client.fluent.Nested{ - MatchLabelExpressionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item) { + + public class MatchLabelExpressionsNestedImpl + extends io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementFluentImpl< + io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + N>> + implements io.kubernetes.client.openapi.models.V1TopologySelectorTermFluent + .MatchLabelExpressionsNested< + N>, + io.kubernetes.client.fluent.Nested { + MatchLabelExpressionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirement item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder( + this, item); } + MatchLabelExpressionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder(this); } + io.kubernetes.client.openapi.models.V1TopologySelectorLabelRequirementBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1TopologySelectorTermFluentImpl.this.setToMatchLabelExpressions(index,builder.build()); + return (N) + V1TopologySelectorTermFluentImpl.this.setToMatchLabelExpressions(index, builder.build()); } + public N endMatchLabelExpression() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySpreadConstraintBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySpreadConstraintBuilder.java index 0751007ac2..2890f6e307 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySpreadConstraintBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySpreadConstraintBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1TopologySpreadConstraintBuilder extends io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1TopologySpreadConstraintBuilder + extends io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluentImpl< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint, + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintBuilder> { public V1TopologySpreadConstraintBuilder() { this(false); } + public V1TopologySpreadConstraintBuilder(java.lang.Boolean validationEnabled) { this(new V1TopologySpreadConstraint(), validationEnabled); } - public V1TopologySpreadConstraintBuilder(io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent fluent) { + + public V1TopologySpreadConstraintBuilder( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent fluent) { this(fluent, false); } - public V1TopologySpreadConstraintBuilder(io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent fluent,java.lang.Boolean validationEnabled) { + + public V1TopologySpreadConstraintBuilder( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1TopologySpreadConstraint(), validationEnabled); } - public V1TopologySpreadConstraintBuilder(io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent fluent,io.kubernetes.client.openapi.models.V1TopologySpreadConstraint instance) { + + public V1TopologySpreadConstraintBuilder( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent fluent, + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint instance) { this(fluent, instance, false); } - public V1TopologySpreadConstraintBuilder(io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent fluent,io.kubernetes.client.openapi.models.V1TopologySpreadConstraint instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1TopologySpreadConstraintBuilder( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent fluent, + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLabelSelector(instance.getLabelSelector()); fluent.withMaxSkew(instance.getMaxSkew()); @@ -29,13 +56,18 @@ public V1TopologySpreadConstraintBuilder(io.kubernetes.client.openapi.models.V1T fluent.withWhenUnsatisfiable(instance.getWhenUnsatisfiable()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1TopologySpreadConstraintBuilder(io.kubernetes.client.openapi.models.V1TopologySpreadConstraint instance) { - this(instance,false); + + public V1TopologySpreadConstraintBuilder( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint instance) { + this(instance, false); } - public V1TopologySpreadConstraintBuilder(io.kubernetes.client.openapi.models.V1TopologySpreadConstraint instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1TopologySpreadConstraintBuilder( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLabelSelector(instance.getLabelSelector()); this.withMaxSkew(instance.getMaxSkew()); @@ -44,10 +76,12 @@ public V1TopologySpreadConstraintBuilder(io.kubernetes.client.openapi.models.V1T this.withWhenUnsatisfiable(instance.getWhenUnsatisfiable()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint build() { V1TopologySpreadConstraint buildable = new V1TopologySpreadConstraint(); buildable.setLabelSelector(fluent.getLabelSelector()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint build() { buildable.setWhenUnsatisfiable(fluent.getWhenUnsatisfiable()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1TopologySpreadConstraintBuilder that = (V1TopologySpreadConstraintBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySpreadConstraintFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySpreadConstraintFluent.java index e2c2a163a5..5943015598 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySpreadConstraintFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySpreadConstraintFluent.java @@ -1,51 +1,84 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1TopologySpreadConstraintFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1TopologySpreadConstraintFluent< + A extends io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildLabelSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getLabelSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildLabelSelector(); + public A withLabelSelector(io.kubernetes.client.openapi.models.V1LabelSelector labelSelector); + public java.lang.Boolean hasLabelSelector(); - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested withNewLabelSelector(); - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested withNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested editLabelSelector(); - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested editOrNewLabelSelector(); - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested editOrNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested + withNewLabelSelector(); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested + withNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested + editLabelSelector(); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested + editOrNewLabelSelector(); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested + editOrNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + public java.lang.Integer getMaxSkew(); + public A withMaxSkew(java.lang.Integer maxSkew); + public java.lang.Boolean hasMaxSkew(); + public java.lang.String getTopologyKey(); + public A withTopologyKey(java.lang.String topologyKey); + public java.lang.Boolean hasTopologyKey(); - - /** - * Method is deprecated. use withTopologyKey instead. - */ + + /** Method is deprecated. use withTopologyKey instead. */ @java.lang.Deprecated public A withNewTopologyKey(java.lang.String original); - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint.WhenUnsatisfiableEnum getWhenUnsatisfiable(); - public A withWhenUnsatisfiable(io.kubernetes.client.openapi.models.V1TopologySpreadConstraint.WhenUnsatisfiableEnum whenUnsatisfiable); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint.WhenUnsatisfiableEnum + getWhenUnsatisfiable(); + + public A withWhenUnsatisfiable( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint.WhenUnsatisfiableEnum + whenUnsatisfiable); + public java.lang.Boolean hasWhenUnsatisfiable(); - public interface LabelSelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface LabelSelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent + .LabelSelectorNested< + N>> { public N and(); + public N endLabelSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySpreadConstraintFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySpreadConstraintFluentImpl.java index 82f6d77b28..475e200ba7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySpreadConstraintFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TopologySpreadConstraintFluentImpl.java @@ -1,20 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1TopologySpreadConstraintFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent{ - public V1TopologySpreadConstraintFluentImpl() { - } - public V1TopologySpreadConstraintFluentImpl(io.kubernetes.client.openapi.models.V1TopologySpreadConstraint instance) { +/** Generated */ +public class V1TopologySpreadConstraintFluentImpl< + A extends io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent { + public V1TopologySpreadConstraintFluentImpl() {} + + public V1TopologySpreadConstraintFluentImpl( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint instance) { this.withLabelSelector(instance.getLabelSelector()); this.withMaxSkew(instance.getMaxSkew()); @@ -22,109 +28,165 @@ public V1TopologySpreadConstraintFluentImpl(io.kubernetes.client.openapi.models. this.withTopologyKey(instance.getTopologyKey()); this.withWhenUnsatisfiable(instance.getWhenUnsatisfiable()); - } + private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder labelSelector; private java.lang.Integer maxSkew; private java.lang.String topologyKey; - private io.kubernetes.client.openapi.models.V1TopologySpreadConstraint.WhenUnsatisfiableEnum whenUnsatisfiable; - + private io.kubernetes.client.openapi.models.V1TopologySpreadConstraint.WhenUnsatisfiableEnum + whenUnsatisfiable; + /** * This method has been deprecated, please use method buildLabelSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getLabelSelector() { - return this.labelSelector!=null ?this.labelSelector.build():null; + return this.labelSelector != null ? this.labelSelector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildLabelSelector() { - return this.labelSelector!=null ?this.labelSelector.build():null; + return this.labelSelector != null ? this.labelSelector.build() : null; } + public A withLabelSelector(io.kubernetes.client.openapi.models.V1LabelSelector labelSelector) { _visitables.get("labelSelector").remove(this.labelSelector); - if (labelSelector!=null){ this.labelSelector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(labelSelector); _visitables.get("labelSelector").add(this.labelSelector);} return (A) this; + if (labelSelector != null) { + this.labelSelector = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(labelSelector); + _visitables.get("labelSelector").add(this.labelSelector); + } + return (A) this; } + public java.lang.Boolean hasLabelSelector() { return this.labelSelector != null; } - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested withNewLabelSelector() { - return new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluentImpl.LabelSelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested + withNewLabelSelector() { + return new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluentImpl + .LabelSelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested withNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluentImpl.LabelSelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested + withNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluentImpl + .LabelSelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested editLabelSelector() { + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested + editLabelSelector() { return withNewLabelSelectorLike(getLabelSelector()); } - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested editOrNewLabelSelector() { - return withNewLabelSelectorLike(getLabelSelector() != null ? getLabelSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested + editOrNewLabelSelector() { + return withNewLabelSelectorLike( + getLabelSelector() != null + ? getLabelSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested editOrNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewLabelSelectorLike(getLabelSelector() != null ? getLabelSelector(): item); + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested + editOrNewLabelSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewLabelSelectorLike(getLabelSelector() != null ? getLabelSelector() : item); } + public java.lang.Integer getMaxSkew() { return this.maxSkew; } + public A withMaxSkew(java.lang.Integer maxSkew) { - this.maxSkew=maxSkew; return (A) this; + this.maxSkew = maxSkew; + return (A) this; } + public java.lang.Boolean hasMaxSkew() { return this.maxSkew != null; } + public java.lang.String getTopologyKey() { return this.topologyKey; } + public A withTopologyKey(java.lang.String topologyKey) { - this.topologyKey=topologyKey; return (A) this; + this.topologyKey = topologyKey; + return (A) this; } + public java.lang.Boolean hasTopologyKey() { return this.topologyKey != null; } - - /** - * Method is deprecated. use withTopologyKey instead. - */ + + /** Method is deprecated. use withTopologyKey instead. */ @java.lang.Deprecated public A withNewTopologyKey(java.lang.String original) { - return (A)withTopologyKey(new String(original)); + return (A) withTopologyKey(new String(original)); } - public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint.WhenUnsatisfiableEnum getWhenUnsatisfiable() { + + public io.kubernetes.client.openapi.models.V1TopologySpreadConstraint.WhenUnsatisfiableEnum + getWhenUnsatisfiable() { return this.whenUnsatisfiable; } - public A withWhenUnsatisfiable(io.kubernetes.client.openapi.models.V1TopologySpreadConstraint.WhenUnsatisfiableEnum whenUnsatisfiable) { - this.whenUnsatisfiable=whenUnsatisfiable; return (A) this; + + public A withWhenUnsatisfiable( + io.kubernetes.client.openapi.models.V1TopologySpreadConstraint.WhenUnsatisfiableEnum + whenUnsatisfiable) { + this.whenUnsatisfiable = whenUnsatisfiable; + return (A) this; } + public java.lang.Boolean hasWhenUnsatisfiable() { return this.whenUnsatisfiable != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1TopologySpreadConstraintFluentImpl that = (V1TopologySpreadConstraintFluentImpl) o; - if (labelSelector != null ? !labelSelector.equals(that.labelSelector) :that.labelSelector != null) return false; - if (maxSkew != null ? !maxSkew.equals(that.maxSkew) :that.maxSkew != null) return false; - if (topologyKey != null ? !topologyKey.equals(that.topologyKey) :that.topologyKey != null) return false; - if (whenUnsatisfiable != null ? !whenUnsatisfiable.equals(that.whenUnsatisfiable) :that.whenUnsatisfiable != null) return false; + if (labelSelector != null + ? !labelSelector.equals(that.labelSelector) + : that.labelSelector != null) return false; + if (maxSkew != null ? !maxSkew.equals(that.maxSkew) : that.maxSkew != null) return false; + if (topologyKey != null ? !topologyKey.equals(that.topologyKey) : that.topologyKey != null) + return false; + if (whenUnsatisfiable != null + ? !whenUnsatisfiable.equals(that.whenUnsatisfiable) + : that.whenUnsatisfiable != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(labelSelector, maxSkew, topologyKey, whenUnsatisfiable, super.hashCode()); + return java.util.Objects.hash( + labelSelector, maxSkew, topologyKey, whenUnsatisfiable, super.hashCode()); } - public class LabelSelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested,io.kubernetes.client.fluent.Nested{ + + public class LabelSelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent.LabelSelectorNested< + N>> + implements io.kubernetes.client.openapi.models.V1TopologySpreadConstraintFluent + .LabelSelectorNested< + N>, + io.kubernetes.client.fluent.Nested { LabelSelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + LabelSelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1TopologySpreadConstraintFluentImpl.this.withLabelSelector(builder.build()); } + public N endLabelSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TypedLocalObjectReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TypedLocalObjectReferenceBuilder.java index cbfa76b9c7..36c7a789a0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TypedLocalObjectReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TypedLocalObjectReferenceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1TypedLocalObjectReferenceBuilder extends io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1TypedLocalObjectReferenceBuilder + extends io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference, + io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceBuilder> { public V1TypedLocalObjectReferenceBuilder() { this(false); } + public V1TypedLocalObjectReferenceBuilder(java.lang.Boolean validationEnabled) { this(new V1TypedLocalObjectReference(), validationEnabled); } - public V1TypedLocalObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent fluent) { + + public V1TypedLocalObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent fluent) { this(fluent, false); } - public V1TypedLocalObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1TypedLocalObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1TypedLocalObjectReference(), validationEnabled); } - public V1TypedLocalObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V1TypedLocalObjectReference instance) { + + public V1TypedLocalObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference instance) { this(fluent, instance, false); } - public V1TypedLocalObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V1TypedLocalObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1TypedLocalObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiGroup(instance.getApiGroup()); fluent.withKind(instance.getKind()); fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1TypedLocalObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference instance) { - this(instance,false); + + public V1TypedLocalObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference instance) { + this(instance, false); } - public V1TypedLocalObjectReferenceBuilder(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1TypedLocalObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiGroup(instance.getApiGroup()); this.withKind(instance.getKind()); this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference build() { V1TypedLocalObjectReference buildable = new V1TypedLocalObjectReference(); buildable.setApiGroup(fluent.getApiGroup()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1TypedLocalObjectReference build() { buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1TypedLocalObjectReferenceBuilder that = (V1TypedLocalObjectReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TypedLocalObjectReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TypedLocalObjectReferenceFluent.java index b13754b652..f8b6aa7d9c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TypedLocalObjectReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TypedLocalObjectReferenceFluent.java @@ -1,41 +1,48 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1TypedLocalObjectReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1TypedLocalObjectReferenceFluent< + A extends io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiGroup(); + public A withApiGroup(java.lang.String apiGroup); + public java.lang.Boolean hasApiGroup(); - - /** - * Method is deprecated. use withApiGroup instead. - */ + + /** Method is deprecated. use withApiGroup instead. */ @java.lang.Deprecated public A withNewApiGroup(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TypedLocalObjectReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TypedLocalObjectReferenceFluentImpl.java index 42993a3e35..295f008880 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TypedLocalObjectReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1TypedLocalObjectReferenceFluentImpl.java @@ -1,90 +1,105 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1TypedLocalObjectReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent{ - public V1TypedLocalObjectReferenceFluentImpl() { - } - public V1TypedLocalObjectReferenceFluentImpl(io.kubernetes.client.openapi.models.V1TypedLocalObjectReference instance) { +/** Generated */ +public class V1TypedLocalObjectReferenceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1TypedLocalObjectReferenceFluent { + public V1TypedLocalObjectReferenceFluentImpl() {} + + public V1TypedLocalObjectReferenceFluentImpl( + io.kubernetes.client.openapi.models.V1TypedLocalObjectReference instance) { this.withApiGroup(instance.getApiGroup()); this.withKind(instance.getKind()); this.withName(instance.getName()); - } + private java.lang.String apiGroup; private java.lang.String kind; private java.lang.String name; + public java.lang.String getApiGroup() { return this.apiGroup; } + public A withApiGroup(java.lang.String apiGroup) { - this.apiGroup=apiGroup; return (A) this; + this.apiGroup = apiGroup; + return (A) this; } + public java.lang.Boolean hasApiGroup() { return this.apiGroup != null; } - - /** - * Method is deprecated. use withApiGroup instead. - */ + + /** Method is deprecated. use withApiGroup instead. */ @java.lang.Deprecated public A withNewApiGroup(java.lang.String original) { - return (A)withApiGroup(new String(original)); + return (A) withApiGroup(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1TypedLocalObjectReferenceFluentImpl that = (V1TypedLocalObjectReferenceFluentImpl) o; - if (apiGroup != null ? !apiGroup.equals(that.apiGroup) :that.apiGroup != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (apiGroup != null ? !apiGroup.equals(that.apiGroup) : that.apiGroup != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiGroup, kind, name, super.hashCode()); + return java.util.Objects.hash(apiGroup, kind, name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UncountedTerminatedPodsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UncountedTerminatedPodsBuilder.java index eefb3bb3cc..53f6cfd22b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UncountedTerminatedPodsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UncountedTerminatedPodsBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1UncountedTerminatedPodsBuilder extends io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1UncountedTerminatedPodsBuilder + extends io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluentImpl< + io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1UncountedTerminatedPods, + io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsBuilder> { public V1UncountedTerminatedPodsBuilder() { this(false); } + public V1UncountedTerminatedPodsBuilder(java.lang.Boolean validationEnabled) { this(new V1UncountedTerminatedPods(), validationEnabled); } - public V1UncountedTerminatedPodsBuilder(io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent fluent) { + + public V1UncountedTerminatedPodsBuilder( + io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent fluent) { this(fluent, false); } - public V1UncountedTerminatedPodsBuilder(io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1UncountedTerminatedPodsBuilder( + io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1UncountedTerminatedPods(), validationEnabled); } - public V1UncountedTerminatedPodsBuilder(io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent fluent,io.kubernetes.client.openapi.models.V1UncountedTerminatedPods instance) { + + public V1UncountedTerminatedPodsBuilder( + io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent fluent, + io.kubernetes.client.openapi.models.V1UncountedTerminatedPods instance) { this(fluent, instance, false); } - public V1UncountedTerminatedPodsBuilder(io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent fluent,io.kubernetes.client.openapi.models.V1UncountedTerminatedPods instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1UncountedTerminatedPodsBuilder( + io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent fluent, + io.kubernetes.client.openapi.models.V1UncountedTerminatedPods instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFailed(instance.getFailed()); fluent.withSucceeded(instance.getSucceeded()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1UncountedTerminatedPodsBuilder(io.kubernetes.client.openapi.models.V1UncountedTerminatedPods instance) { - this(instance,false); + + public V1UncountedTerminatedPodsBuilder( + io.kubernetes.client.openapi.models.V1UncountedTerminatedPods instance) { + this(instance, false); } - public V1UncountedTerminatedPodsBuilder(io.kubernetes.client.openapi.models.V1UncountedTerminatedPods instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1UncountedTerminatedPodsBuilder( + io.kubernetes.client.openapi.models.V1UncountedTerminatedPods instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFailed(instance.getFailed()); this.withSucceeded(instance.getSucceeded()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1UncountedTerminatedPods build() { V1UncountedTerminatedPods buildable = new V1UncountedTerminatedPods(); buildable.setFailed(fluent.getFailed()); buildable.setSucceeded(fluent.getSucceeded()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1UncountedTerminatedPodsBuilder that = (V1UncountedTerminatedPodsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UncountedTerminatedPodsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UncountedTerminatedPodsFluent.java index 89a74023b3..3d34ba367e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UncountedTerminatedPodsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UncountedTerminatedPodsFluent.java @@ -1,50 +1,86 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1UncountedTerminatedPodsFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToFailed(java.lang.Integer index,java.lang.String item); - public A setToFailed(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1UncountedTerminatedPodsFluent< + A extends io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToFailed(java.lang.Integer index, java.lang.String item); + + public A setToFailed(java.lang.Integer index, java.lang.String item); + public A addToFailed(java.lang.String... items); + public A addAllToFailed(java.util.Collection items); + public A removeFromFailed(java.lang.String... items); + public A removeAllFromFailed(java.util.Collection items); + public java.util.List getFailed(); + public java.lang.String getFailed(java.lang.Integer index); + public java.lang.String getFirstFailed(); + public java.lang.String getLastFailed(); - public java.lang.String getMatchingFailed(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingFailed(java.util.function.Predicate predicate); + + public java.lang.String getMatchingFailed( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingFailed( + java.util.function.Predicate predicate); + public A withFailed(java.util.List failed); + public A withFailed(java.lang.String... failed); + public java.lang.Boolean hasFailed(); + public A addNewFailed(java.lang.String original); - public A addToSucceeded(java.lang.Integer index,java.lang.String item); - public A setToSucceeded(java.lang.Integer index,java.lang.String item); + + public A addToSucceeded(java.lang.Integer index, java.lang.String item); + + public A setToSucceeded(java.lang.Integer index, java.lang.String item); + public A addToSucceeded(java.lang.String... items); + public A addAllToSucceeded(java.util.Collection items); + public A removeFromSucceeded(java.lang.String... items); + public A removeAllFromSucceeded(java.util.Collection items); + public java.util.List getSucceeded(); + public java.lang.String getSucceeded(java.lang.Integer index); + public java.lang.String getFirstSucceeded(); + public java.lang.String getLastSucceeded(); - public java.lang.String getMatchingSucceeded(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingSucceeded(java.util.function.Predicate predicate); + + public java.lang.String getMatchingSucceeded( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingSucceeded( + java.util.function.Predicate predicate); + public A withSucceeded(java.util.List succeeded); + public A withSucceeded(java.lang.String... succeeded); + public java.lang.Boolean hasSucceeded(); + public A addNewSucceeded(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UncountedTerminatedPodsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UncountedTerminatedPodsFluentImpl.java index 2d16c38259..de6005ee24 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UncountedTerminatedPodsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UncountedTerminatedPodsFluentImpl.java @@ -1,147 +1,289 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.ArrayList; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public class V1UncountedTerminatedPodsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent{ - public V1UncountedTerminatedPodsFluentImpl() { - } - public V1UncountedTerminatedPodsFluentImpl(io.kubernetes.client.openapi.models.V1UncountedTerminatedPods instance) { +/** Generated */ +public class V1UncountedTerminatedPodsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1UncountedTerminatedPodsFluent { + public V1UncountedTerminatedPodsFluentImpl() {} + + public V1UncountedTerminatedPodsFluentImpl( + io.kubernetes.client.openapi.models.V1UncountedTerminatedPods instance) { this.withFailed(instance.getFailed()); this.withSucceeded(instance.getSucceeded()); - } + private java.util.List failed; private java.util.List succeeded; - public A addToFailed(java.lang.Integer index,java.lang.String item) { - if (this.failed == null) {this.failed = new java.util.ArrayList();} + + public A addToFailed(java.lang.Integer index, java.lang.String item) { + if (this.failed == null) { + this.failed = new java.util.ArrayList(); + } this.failed.add(index, item); - return (A)this; + return (A) this; } - public A setToFailed(java.lang.Integer index,java.lang.String item) { - if (this.failed == null) {this.failed = new java.util.ArrayList();} - this.failed.set(index, item); return (A)this; + + public A setToFailed(java.lang.Integer index, java.lang.String item) { + if (this.failed == null) { + this.failed = new java.util.ArrayList(); + } + this.failed.set(index, item); + return (A) this; } + public A addToFailed(java.lang.String... items) { - if (this.failed == null) {this.failed = new java.util.ArrayList();} - for (java.lang.String item : items) {this.failed.add(item);} return (A)this; + if (this.failed == null) { + this.failed = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.failed.add(item); + } + return (A) this; } + public A addAllToFailed(java.util.Collection items) { - if (this.failed == null) {this.failed = new java.util.ArrayList();} - for (java.lang.String item : items) {this.failed.add(item);} return (A)this; + if (this.failed == null) { + this.failed = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.failed.add(item); + } + return (A) this; } + public A removeFromFailed(java.lang.String... items) { - for (java.lang.String item : items) {if (this.failed!= null){ this.failed.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.failed != null) { + this.failed.remove(item); + } + } + return (A) this; } + public A removeAllFromFailed(java.util.Collection items) { - for (java.lang.String item : items) {if (this.failed!= null){ this.failed.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.failed != null) { + this.failed.remove(item); + } + } + return (A) this; } + public java.util.List getFailed() { return this.failed; } + public java.lang.String getFailed(java.lang.Integer index) { return this.failed.get(index); } + public java.lang.String getFirstFailed() { return this.failed.get(0); } + public java.lang.String getLastFailed() { return this.failed.get(failed.size() - 1); } - public java.lang.String getMatchingFailed(java.util.function.Predicate predicate) { - for (java.lang.String item: failed) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingFailed( + java.util.function.Predicate predicate) { + for (java.lang.String item : failed) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingFailed(java.util.function.Predicate predicate) { - for (java.lang.String item: failed) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingFailed( + java.util.function.Predicate predicate) { + for (java.lang.String item : failed) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withFailed(java.util.List failed) { - if (failed != null) {this.failed = new java.util.ArrayList(); for (java.lang.String item : failed){this.addToFailed(item);}} else { this.failed = null;} return (A) this; + if (failed != null) { + this.failed = new java.util.ArrayList(); + for (java.lang.String item : failed) { + this.addToFailed(item); + } + } else { + this.failed = null; + } + return (A) this; } + public A withFailed(java.lang.String... failed) { - if (this.failed != null) {this.failed.clear();} - if (failed != null) {for (java.lang.String item :failed){ this.addToFailed(item);}} return (A) this; + if (this.failed != null) { + this.failed.clear(); + } + if (failed != null) { + for (java.lang.String item : failed) { + this.addToFailed(item); + } + } + return (A) this; } + public java.lang.Boolean hasFailed() { return failed != null && !failed.isEmpty(); } + public A addNewFailed(java.lang.String original) { - return (A)addToFailed(new String(original)); + return (A) addToFailed(new String(original)); } - public A addToSucceeded(java.lang.Integer index,java.lang.String item) { - if (this.succeeded == null) {this.succeeded = new java.util.ArrayList();} + + public A addToSucceeded(java.lang.Integer index, java.lang.String item) { + if (this.succeeded == null) { + this.succeeded = new java.util.ArrayList(); + } this.succeeded.add(index, item); - return (A)this; + return (A) this; } - public A setToSucceeded(java.lang.Integer index,java.lang.String item) { - if (this.succeeded == null) {this.succeeded = new java.util.ArrayList();} - this.succeeded.set(index, item); return (A)this; + + public A setToSucceeded(java.lang.Integer index, java.lang.String item) { + if (this.succeeded == null) { + this.succeeded = new java.util.ArrayList(); + } + this.succeeded.set(index, item); + return (A) this; } + public A addToSucceeded(java.lang.String... items) { - if (this.succeeded == null) {this.succeeded = new java.util.ArrayList();} - for (java.lang.String item : items) {this.succeeded.add(item);} return (A)this; + if (this.succeeded == null) { + this.succeeded = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.succeeded.add(item); + } + return (A) this; } + public A addAllToSucceeded(java.util.Collection items) { - if (this.succeeded == null) {this.succeeded = new java.util.ArrayList();} - for (java.lang.String item : items) {this.succeeded.add(item);} return (A)this; + if (this.succeeded == null) { + this.succeeded = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.succeeded.add(item); + } + return (A) this; } + public A removeFromSucceeded(java.lang.String... items) { - for (java.lang.String item : items) {if (this.succeeded!= null){ this.succeeded.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.succeeded != null) { + this.succeeded.remove(item); + } + } + return (A) this; } + public A removeAllFromSucceeded(java.util.Collection items) { - for (java.lang.String item : items) {if (this.succeeded!= null){ this.succeeded.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.succeeded != null) { + this.succeeded.remove(item); + } + } + return (A) this; } + public java.util.List getSucceeded() { return this.succeeded; } + public java.lang.String getSucceeded(java.lang.Integer index) { return this.succeeded.get(index); } + public java.lang.String getFirstSucceeded() { return this.succeeded.get(0); } + public java.lang.String getLastSucceeded() { return this.succeeded.get(succeeded.size() - 1); } - public java.lang.String getMatchingSucceeded(java.util.function.Predicate predicate) { - for (java.lang.String item: succeeded) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingSucceeded( + java.util.function.Predicate predicate) { + for (java.lang.String item : succeeded) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingSucceeded(java.util.function.Predicate predicate) { - for (java.lang.String item: succeeded) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingSucceeded( + java.util.function.Predicate predicate) { + for (java.lang.String item : succeeded) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withSucceeded(java.util.List succeeded) { - if (succeeded != null) {this.succeeded = new java.util.ArrayList(); for (java.lang.String item : succeeded){this.addToSucceeded(item);}} else { this.succeeded = null;} return (A) this; + if (succeeded != null) { + this.succeeded = new java.util.ArrayList(); + for (java.lang.String item : succeeded) { + this.addToSucceeded(item); + } + } else { + this.succeeded = null; + } + return (A) this; } + public A withSucceeded(java.lang.String... succeeded) { - if (this.succeeded != null) {this.succeeded.clear();} - if (succeeded != null) {for (java.lang.String item :succeeded){ this.addToSucceeded(item);}} return (A) this; + if (this.succeeded != null) { + this.succeeded.clear(); + } + if (succeeded != null) { + for (java.lang.String item : succeeded) { + this.addToSucceeded(item); + } + } + return (A) this; } + public java.lang.Boolean hasSucceeded() { return succeeded != null && !succeeded.isEmpty(); } + public A addNewSucceeded(java.lang.String original) { - return (A)addToSucceeded(new String(original)); + return (A) addToSucceeded(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1UncountedTerminatedPodsFluentImpl that = (V1UncountedTerminatedPodsFluentImpl) o; - if (failed != null ? !failed.equals(that.failed) :that.failed != null) return false; - if (succeeded != null ? !succeeded.equals(that.succeeded) :that.succeeded != null) return false; + if (failed != null ? !failed.equals(that.failed) : that.failed != null) return false; + if (succeeded != null ? !succeeded.equals(that.succeeded) : that.succeeded != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(failed, succeeded, super.hashCode()); + return java.util.Objects.hash(failed, succeeded, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UserInfoBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UserInfoBuilder.java index 12ab2f35ea..ef6ceae0b0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UserInfoBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UserInfoBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1UserInfoBuilder extends io.kubernetes.client.openapi.models.V1UserInfoFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1UserInfoBuilder + extends io.kubernetes.client.openapi.models.V1UserInfoFluentImpl< + io.kubernetes.client.openapi.models.V1UserInfoBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1UserInfo, + io.kubernetes.client.openapi.models.V1UserInfoBuilder> { public V1UserInfoBuilder() { this(false); } + public V1UserInfoBuilder(java.lang.Boolean validationEnabled) { this(new V1UserInfo(), validationEnabled); } + public V1UserInfoBuilder(io.kubernetes.client.openapi.models.V1UserInfoFluent fluent) { this(fluent, false); } - public V1UserInfoBuilder(io.kubernetes.client.openapi.models.V1UserInfoFluent fluent,java.lang.Boolean validationEnabled) { + + public V1UserInfoBuilder( + io.kubernetes.client.openapi.models.V1UserInfoFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1UserInfo(), validationEnabled); } - public V1UserInfoBuilder(io.kubernetes.client.openapi.models.V1UserInfoFluent fluent,io.kubernetes.client.openapi.models.V1UserInfo instance) { + + public V1UserInfoBuilder( + io.kubernetes.client.openapi.models.V1UserInfoFluent fluent, + io.kubernetes.client.openapi.models.V1UserInfo instance) { this(fluent, instance, false); } - public V1UserInfoBuilder(io.kubernetes.client.openapi.models.V1UserInfoFluent fluent,io.kubernetes.client.openapi.models.V1UserInfo instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1UserInfoBuilder( + io.kubernetes.client.openapi.models.V1UserInfoFluent fluent, + io.kubernetes.client.openapi.models.V1UserInfo instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withExtra(instance.getExtra()); fluent.withGroups(instance.getGroups()); @@ -29,13 +55,17 @@ public V1UserInfoBuilder(io.kubernetes.client.openapi.models.V1UserInfoFluent fluent.withUsername(instance.getUsername()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1UserInfoBuilder(io.kubernetes.client.openapi.models.V1UserInfo instance) { - this(instance,false); + this(instance, false); } - public V1UserInfoBuilder(io.kubernetes.client.openapi.models.V1UserInfo instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1UserInfoBuilder( + io.kubernetes.client.openapi.models.V1UserInfo instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withExtra(instance.getExtra()); this.withGroups(instance.getGroups()); @@ -44,10 +74,12 @@ public V1UserInfoBuilder(io.kubernetes.client.openapi.models.V1UserInfo instance this.withUsername(instance.getUsername()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1UserInfoFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1UserInfo build() { V1UserInfo buildable = new V1UserInfo(); buildable.setExtra(fluent.getExtra()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1UserInfo build() { buildable.setUsername(fluent.getUsername()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1UserInfoBuilder that = (V1UserInfoBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UserInfoFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UserInfoFluent.java index 9dd9e92351..d3e5246c2c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UserInfoFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UserInfoFluent.java @@ -1,62 +1,86 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1UserInfoFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToExtra(java.lang.String key,java.util.List value); - public A addToExtra(java.util.Map> map); +/** Generated */ +public interface V1UserInfoFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToExtra(java.lang.String key, java.util.List value); + + public A addToExtra(java.util.Map> map); + public A removeFromExtra(java.lang.String key); - public A removeFromExtra(java.util.Map> map); - public java.util.Map> getExtra(); - public A withExtra(java.util.Map> extra); + + public A removeFromExtra(java.util.Map> map); + + public java.util.Map> getExtra(); + + public A withExtra( + java.util.Map> extra); + public java.lang.Boolean hasExtra(); - public A addToGroups(java.lang.Integer index,java.lang.String item); - public A setToGroups(java.lang.Integer index,java.lang.String item); + + public A addToGroups(java.lang.Integer index, java.lang.String item); + + public A setToGroups(java.lang.Integer index, java.lang.String item); + public A addToGroups(java.lang.String... items); + public A addAllToGroups(java.util.Collection items); + public A removeFromGroups(java.lang.String... items); + public A removeAllFromGroups(java.util.Collection items); + public java.util.List getGroups(); + public java.lang.String getGroup(java.lang.Integer index); + public java.lang.String getFirstGroup(); + public java.lang.String getLastGroup(); - public java.lang.String getMatchingGroup(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingGroup(java.util.function.Predicate predicate); + + public java.lang.String getMatchingGroup( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingGroup( + java.util.function.Predicate predicate); + public A withGroups(java.util.List groups); + public A withGroups(java.lang.String... groups); + public java.lang.Boolean hasGroups(); + public A addNewGroup(java.lang.String original); + public java.lang.String getUid(); + public A withUid(java.lang.String uid); + public java.lang.Boolean hasUid(); - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original); + public java.lang.String getUsername(); + public A withUsername(java.lang.String username); + public java.lang.Boolean hasUsername(); - - /** - * Method is deprecated. use withUsername instead. - */ + + /** Method is deprecated. use withUsername instead. */ @java.lang.Deprecated public A withNewUsername(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UserInfoFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UserInfoFluentImpl.java index 58ea370b74..396605c167 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UserInfoFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1UserInfoFluentImpl.java @@ -1,24 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public class V1UserInfoFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1UserInfoFluent{ - public V1UserInfoFluentImpl() { - } +/** Generated */ +public class V1UserInfoFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1UserInfoFluent { + public V1UserInfoFluentImpl() {} + public V1UserInfoFluentImpl(io.kubernetes.client.openapi.models.V1UserInfo instance) { this.withExtra(instance.getExtra()); @@ -27,137 +26,247 @@ public V1UserInfoFluentImpl(io.kubernetes.client.openapi.models.V1UserInfo insta this.withUid(instance.getUid()); this.withUsername(instance.getUsername()); - } - private java.util.Map> extra; + + private java.util.Map> extra; private java.util.List groups; private java.lang.String uid; private java.lang.String username; - public A addToExtra(java.lang.String key,java.util.List value) { - if(this.extra == null && key != null && value != null) { this.extra = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.extra.put(key, value);} return (A)this; + + public A addToExtra(java.lang.String key, java.util.List value) { + if (this.extra == null && key != null && value != null) { + this.extra = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.extra.put(key, value); + } + return (A) this; } - public A addToExtra(java.util.Map> map) { - if(this.extra == null && map != null) { this.extra = new java.util.LinkedHashMap(); } - if(map != null) { this.extra.putAll(map);} return (A)this; + + public A addToExtra(java.util.Map> map) { + if (this.extra == null && map != null) { + this.extra = new java.util.LinkedHashMap(); + } + if (map != null) { + this.extra.putAll(map); + } + return (A) this; } + public A removeFromExtra(java.lang.String key) { - if(this.extra == null) { return (A) this; } - if(key != null && this.extra != null) {this.extra.remove(key);} return (A)this; + if (this.extra == null) { + return (A) this; + } + if (key != null && this.extra != null) { + this.extra.remove(key); + } + return (A) this; } - public A removeFromExtra(java.util.Map> map) { - if(this.extra == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.extra != null){this.extra.remove(key);}}} return (A)this; + + public A removeFromExtra(java.util.Map> map) { + if (this.extra == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.extra != null) { + this.extra.remove(key); + } + } + } + return (A) this; } - public java.util.Map> getExtra() { + + public java.util.Map> getExtra() { return this.extra; } - public A withExtra(java.util.Map> extra) { - if (extra == null) { this.extra = null;} else {this.extra = new java.util.LinkedHashMap(extra);} return (A) this; + + public A withExtra( + java.util.Map> extra) { + if (extra == null) { + this.extra = null; + } else { + this.extra = new java.util.LinkedHashMap(extra); + } + return (A) this; } + public java.lang.Boolean hasExtra() { return this.extra != null; } - public A addToGroups(java.lang.Integer index,java.lang.String item) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} + + public A addToGroups(java.lang.Integer index, java.lang.String item) { + if (this.groups == null) { + this.groups = new java.util.ArrayList(); + } this.groups.add(index, item); - return (A)this; + return (A) this; } - public A setToGroups(java.lang.Integer index,java.lang.String item) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} - this.groups.set(index, item); return (A)this; + + public A setToGroups(java.lang.Integer index, java.lang.String item) { + if (this.groups == null) { + this.groups = new java.util.ArrayList(); + } + this.groups.set(index, item); + return (A) this; } + public A addToGroups(java.lang.String... items) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.groups.add(item);} return (A)this; + if (this.groups == null) { + this.groups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.groups.add(item); + } + return (A) this; } + public A addAllToGroups(java.util.Collection items) { - if (this.groups == null) {this.groups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.groups.add(item);} return (A)this; + if (this.groups == null) { + this.groups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.groups.add(item); + } + return (A) this; } + public A removeFromGroups(java.lang.String... items) { - for (java.lang.String item : items) {if (this.groups!= null){ this.groups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.groups != null) { + this.groups.remove(item); + } + } + return (A) this; } + public A removeAllFromGroups(java.util.Collection items) { - for (java.lang.String item : items) {if (this.groups!= null){ this.groups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.groups != null) { + this.groups.remove(item); + } + } + return (A) this; } + public java.util.List getGroups() { return this.groups; } + public java.lang.String getGroup(java.lang.Integer index) { return this.groups.get(index); } + public java.lang.String getFirstGroup() { return this.groups.get(0); } + public java.lang.String getLastGroup() { return this.groups.get(groups.size() - 1); } - public java.lang.String getMatchingGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: groups) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : groups) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: groups) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : groups) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withGroups(java.util.List groups) { - if (groups != null) {this.groups = new java.util.ArrayList(); for (java.lang.String item : groups){this.addToGroups(item);}} else { this.groups = null;} return (A) this; + if (groups != null) { + this.groups = new java.util.ArrayList(); + for (java.lang.String item : groups) { + this.addToGroups(item); + } + } else { + this.groups = null; + } + return (A) this; } + public A withGroups(java.lang.String... groups) { - if (this.groups != null) {this.groups.clear();} - if (groups != null) {for (java.lang.String item :groups){ this.addToGroups(item);}} return (A) this; + if (this.groups != null) { + this.groups.clear(); + } + if (groups != null) { + for (java.lang.String item : groups) { + this.addToGroups(item); + } + } + return (A) this; } + public java.lang.Boolean hasGroups() { return groups != null && !groups.isEmpty(); } + public A addNewGroup(java.lang.String original) { - return (A)addToGroups(new String(original)); + return (A) addToGroups(new String(original)); } + public java.lang.String getUid() { return this.uid; } + public A withUid(java.lang.String uid) { - this.uid=uid; return (A) this; + this.uid = uid; + return (A) this; } + public java.lang.Boolean hasUid() { return this.uid != null; } - - /** - * Method is deprecated. use withUid instead. - */ + + /** Method is deprecated. use withUid instead. */ @java.lang.Deprecated public A withNewUid(java.lang.String original) { - return (A)withUid(new String(original)); + return (A) withUid(new String(original)); } + public java.lang.String getUsername() { return this.username; } + public A withUsername(java.lang.String username) { - this.username=username; return (A) this; + this.username = username; + return (A) this; } + public java.lang.Boolean hasUsername() { return this.username != null; } - - /** - * Method is deprecated. use withUsername instead. - */ + + /** Method is deprecated. use withUsername instead. */ @java.lang.Deprecated public A withNewUsername(java.lang.String original) { - return (A)withUsername(new String(original)); + return (A) withUsername(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1UserInfoFluentImpl that = (V1UserInfoFluentImpl) o; - if (extra != null ? !extra.equals(that.extra) :that.extra != null) return false; - if (groups != null ? !groups.equals(that.groups) :that.groups != null) return false; - if (uid != null ? !uid.equals(that.uid) :that.uid != null) return false; - if (username != null ? !username.equals(that.username) :that.username != null) return false; + if (extra != null ? !extra.equals(that.extra) : that.extra != null) return false; + if (groups != null ? !groups.equals(that.groups) : that.groups != null) return false; + if (uid != null ? !uid.equals(that.uid) : that.uid != null) return false; + if (username != null ? !username.equals(that.username) : that.username != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(extra, groups, uid, username, super.hashCode()); + return java.util.Objects.hash(extra, groups, uid, username, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookBuilder.java index d931981edf..329611ca72 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ValidatingWebhookBuilder extends io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ValidatingWebhookBuilder + extends io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl< + io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ValidatingWebhook, + io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder> { public V1ValidatingWebhookBuilder() { this(false); } + public V1ValidatingWebhookBuilder(java.lang.Boolean validationEnabled) { this(new V1ValidatingWebhook(), validationEnabled); } - public V1ValidatingWebhookBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent fluent) { + + public V1ValidatingWebhookBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent fluent) { this(fluent, false); } - public V1ValidatingWebhookBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ValidatingWebhookBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ValidatingWebhook(), validationEnabled); } - public V1ValidatingWebhookBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent fluent,io.kubernetes.client.openapi.models.V1ValidatingWebhook instance) { + + public V1ValidatingWebhookBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent fluent, + io.kubernetes.client.openapi.models.V1ValidatingWebhook instance) { this(fluent, instance, false); } - public V1ValidatingWebhookBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent fluent,io.kubernetes.client.openapi.models.V1ValidatingWebhook instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ValidatingWebhookBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent fluent, + io.kubernetes.client.openapi.models.V1ValidatingWebhook instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAdmissionReviewVersions(instance.getAdmissionReviewVersions()); fluent.withClientConfig(instance.getClientConfig()); @@ -41,13 +68,18 @@ public V1ValidatingWebhookBuilder(io.kubernetes.client.openapi.models.V1Validati fluent.withTimeoutSeconds(instance.getTimeoutSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ValidatingWebhookBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhook instance) { - this(instance,false); + + public V1ValidatingWebhookBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhook instance) { + this(instance, false); } - public V1ValidatingWebhookBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhook instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ValidatingWebhookBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhook instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAdmissionReviewVersions(instance.getAdmissionReviewVersions()); this.withClientConfig(instance.getClientConfig()); @@ -68,10 +100,12 @@ public V1ValidatingWebhookBuilder(io.kubernetes.client.openapi.models.V1Validati this.withTimeoutSeconds(instance.getTimeoutSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ValidatingWebhook build() { V1ValidatingWebhook buildable = new V1ValidatingWebhook(); buildable.setAdmissionReviewVersions(fluent.getAdmissionReviewVersions()); @@ -86,18 +120,23 @@ public io.kubernetes.client.openapi.models.V1ValidatingWebhook build() { buildable.setTimeoutSeconds(fluent.getTimeoutSeconds()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ValidatingWebhookBuilder that = (V1ValidatingWebhookBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationBuilder.java index d57e3ab29b..1d99a55fed 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ValidatingWebhookConfigurationBuilder extends io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ValidatingWebhookConfigurationBuilder + extends io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder> { public V1ValidatingWebhookConfigurationBuilder() { this(false); } + public V1ValidatingWebhookConfigurationBuilder(java.lang.Boolean validationEnabled) { this(new V1ValidatingWebhookConfiguration(), validationEnabled); } - public V1ValidatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent fluent) { + + public V1ValidatingWebhookConfigurationBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent fluent) { this(fluent, false); } - public V1ValidatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ValidatingWebhookConfigurationBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ValidatingWebhookConfiguration(), validationEnabled); } - public V1ValidatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration instance) { + + public V1ValidatingWebhookConfigurationBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration instance) { this(fluent, instance, false); } - public V1ValidatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ValidatingWebhookConfigurationBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +56,18 @@ public V1ValidatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.mode fluent.withWebhooks(instance.getWebhooks()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ValidatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration instance) { - this(instance,false); + + public V1ValidatingWebhookConfigurationBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration instance) { + this(instance, false); } - public V1ValidatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ValidatingWebhookConfigurationBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +76,12 @@ public V1ValidatingWebhookConfigurationBuilder(io.kubernetes.client.openapi.mode this.withWebhooks(instance.getWebhooks()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration build() { V1ValidatingWebhookConfiguration buildable = new V1ValidatingWebhookConfiguration(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration buil buildable.setWebhooks(fluent.getWebhooks()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ValidatingWebhookConfigurationBuilder that = (V1ValidatingWebhookConfigurationBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationFluent.java index c1dc32a98e..6eeabdb09e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationFluent.java @@ -1,95 +1,178 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ValidatingWebhookConfigurationFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ValidatingWebhookConfigurationFluent< + A extends io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public A addToWebhooks(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhook item); - public A setToWebhooks(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhook item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested< + A> + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested< + A> + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested< + A> + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public A addToWebhooks( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ValidatingWebhook item); + + public A setToWebhooks( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ValidatingWebhook item); + public A addToWebhooks(io.kubernetes.client.openapi.models.V1ValidatingWebhook... items); - public A addAllToWebhooks(java.util.Collection items); + + public A addAllToWebhooks( + java.util.Collection items); + public A removeFromWebhooks(io.kubernetes.client.openapi.models.V1ValidatingWebhook... items); - public A removeAllFromWebhooks(java.util.Collection items); - public A removeMatchingFromWebhooks(java.util.function.Predicate predicate); - + + public A removeAllFromWebhooks( + java.util.Collection items); + + public A removeMatchingFromWebhooks( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildWebhooks instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getWebhooks(); + public java.util.List buildWebhooks(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhook buildWebhook(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhook buildWebhook( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ValidatingWebhook buildFirstWebhook(); + public io.kubernetes.client.openapi.models.V1ValidatingWebhook buildLastWebhook(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhook buildMatchingWebhook(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingWebhook(java.util.function.Predicate predicate); - public A withWebhooks(java.util.List webhooks); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhook buildMatchingWebhook( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingWebhook( + java.util.function.Predicate + predicate); + + public A withWebhooks( + java.util.List webhooks); + public A withWebhooks(io.kubernetes.client.openapi.models.V1ValidatingWebhook... webhooks); + public java.lang.Boolean hasWebhooks(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested addNewWebhook(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested addNewWebhookLike(io.kubernetes.client.openapi.models.V1ValidatingWebhook item); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested setNewWebhookLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhook item); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested editWebhook(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested editFirstWebhook(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested editLastWebhook(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested editMatchingWebhook(java.util.function.Predicate predicate); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + addNewWebhook(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + addNewWebhookLike(io.kubernetes.client.openapi.models.V1ValidatingWebhook item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + setNewWebhookLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ValidatingWebhook item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + editWebhook(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + editFirstWebhook(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + editLastWebhook(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + editMatchingWebhook( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder> + predicate); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface WebhooksNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent>{ + + public interface WebhooksNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent + .WebhooksNested< + N>> { public N and(); + public N endWebhook(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationFluentImpl.java index 37a456e88d..6937292ca4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1ValidatingWebhookConfigurationFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent{ - public V1ValidatingWebhookConfigurationFluentImpl() { - } - public V1ValidatingWebhookConfigurationFluentImpl(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration instance) { + +/** Generated */ +public class V1ValidatingWebhookConfigurationFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent { + public V1ValidatingWebhookConfigurationFluentImpl() {} + + public V1ValidatingWebhookConfigurationFluentImpl( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -28,108 +31,210 @@ public V1ValidatingWebhookConfigurationFluentImpl(io.kubernetes.client.openapi.m this.withMetadata(instance.getMetadata()); this.withWebhooks(instance.getWebhooks()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; - private java.util.ArrayList webhooks; + private java.util.ArrayList + webhooks; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested< + A> + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested< + A> + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested< + A> + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - public A addToWebhooks(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhook item) { - if (this.webhooks == null) {this.webhooks = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(item);_visitables.get("webhooks").add(index >= 0 ? index : _visitables.get("webhooks").size(), builder);this.webhooks.add(index >= 0 ? index : webhooks.size(), builder); return (A)this; + + public A addToWebhooks( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ValidatingWebhook item) { + if (this.webhooks == null) { + this.webhooks = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(item); + _visitables + .get("webhooks") + .add(index >= 0 ? index : _visitables.get("webhooks").size(), builder); + this.webhooks.add(index >= 0 ? index : webhooks.size(), builder); + return (A) this; } - public A setToWebhooks(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhook item) { - if (this.webhooks == null) {this.webhooks = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(item); - if (index < 0 || index >= _visitables.get("webhooks").size()) { _visitables.get("webhooks").add(builder); } else { _visitables.get("webhooks").set(index, builder);} - if (index < 0 || index >= webhooks.size()) { webhooks.add(builder); } else { webhooks.set(index, builder);} - return (A)this; + + public A setToWebhooks( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ValidatingWebhook item) { + if (this.webhooks == null) { + this.webhooks = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(item); + if (index < 0 || index >= _visitables.get("webhooks").size()) { + _visitables.get("webhooks").add(builder); + } else { + _visitables.get("webhooks").set(index, builder); + } + if (index < 0 || index >= webhooks.size()) { + webhooks.add(builder); + } else { + webhooks.set(index, builder); + } + return (A) this; } + public A addToWebhooks(io.kubernetes.client.openapi.models.V1ValidatingWebhook... items) { - if (this.webhooks == null) {this.webhooks = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ValidatingWebhook item : items) {io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(item);_visitables.get("webhooks").add(builder);this.webhooks.add(builder);} return (A)this; + if (this.webhooks == null) { + this.webhooks = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ValidatingWebhook item : items) { + io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(item); + _visitables.get("webhooks").add(builder); + this.webhooks.add(builder); + } + return (A) this; } - public A addAllToWebhooks(java.util.Collection items) { - if (this.webhooks == null) {this.webhooks = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ValidatingWebhook item : items) {io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(item);_visitables.get("webhooks").add(builder);this.webhooks.add(builder);} return (A)this; + + public A addAllToWebhooks( + java.util.Collection items) { + if (this.webhooks == null) { + this.webhooks = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ValidatingWebhook item : items) { + io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(item); + _visitables.get("webhooks").add(builder); + this.webhooks.add(builder); + } + return (A) this; } + public A removeFromWebhooks(io.kubernetes.client.openapi.models.V1ValidatingWebhook... items) { - for (io.kubernetes.client.openapi.models.V1ValidatingWebhook item : items) {io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(item);_visitables.get("webhooks").remove(builder);if (this.webhooks != null) {this.webhooks.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ValidatingWebhook item : items) { + io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(item); + _visitables.get("webhooks").remove(builder); + if (this.webhooks != null) { + this.webhooks.remove(builder); + } + } + return (A) this; } - public A removeAllFromWebhooks(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ValidatingWebhook item : items) {io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(item);_visitables.get("webhooks").remove(builder);if (this.webhooks != null) {this.webhooks.remove(builder);}} return (A)this; + + public A removeAllFromWebhooks( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ValidatingWebhook item : items) { + io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(item); + _visitables.get("webhooks").remove(builder); + if (this.webhooks != null) { + this.webhooks.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromWebhooks(java.util.function.Predicate predicate) { + + public A removeMatchingFromWebhooks( + java.util.function.Predicate + predicate) { if (webhooks == null) return (A) this; - final Iterator each = webhooks.iterator(); + final Iterator each = + webhooks.iterator(); final List visitables = _visitables.get("webhooks"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder = each.next(); @@ -138,123 +243,226 @@ public A removeMatchingFromWebhooks(java.util.function.Predicate getWebhooks() { return webhooks != null ? build(webhooks) : null; } + public java.util.List buildWebhooks() { return webhooks != null ? build(webhooks) : null; } - public io.kubernetes.client.openapi.models.V1ValidatingWebhook buildWebhook(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhook buildWebhook( + java.lang.Integer index) { return this.webhooks.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ValidatingWebhook buildFirstWebhook() { return this.webhooks.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ValidatingWebhook buildLastWebhook() { return this.webhooks.get(webhooks.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhook buildMatchingWebhook(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder item: webhooks) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ValidatingWebhook buildMatchingWebhook( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder item : webhooks) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingWebhook(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder item: webhooks) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingWebhook( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder item : webhooks) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withWebhooks(java.util.List webhooks) { - if (this.webhooks != null) { _visitables.get("webhooks").removeAll(this.webhooks);} - if (webhooks != null) {this.webhooks = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ValidatingWebhook item : webhooks){this.addToWebhooks(item);}} else { this.webhooks = null;} return (A) this; + + public A withWebhooks( + java.util.List webhooks) { + if (this.webhooks != null) { + _visitables.get("webhooks").removeAll(this.webhooks); + } + if (webhooks != null) { + this.webhooks = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ValidatingWebhook item : webhooks) { + this.addToWebhooks(item); + } + } else { + this.webhooks = null; + } + return (A) this; } + public A withWebhooks(io.kubernetes.client.openapi.models.V1ValidatingWebhook... webhooks) { - if (this.webhooks != null) {this.webhooks.clear();} - if (webhooks != null) {for (io.kubernetes.client.openapi.models.V1ValidatingWebhook item :webhooks){ this.addToWebhooks(item);}} return (A) this; + if (this.webhooks != null) { + this.webhooks.clear(); + } + if (webhooks != null) { + for (io.kubernetes.client.openapi.models.V1ValidatingWebhook item : webhooks) { + this.addToWebhooks(item); + } + } + return (A) this; } + public java.lang.Boolean hasWebhooks() { return webhooks != null && !webhooks.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested addNewWebhook() { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl.WebhooksNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + addNewWebhook() { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl + .WebhooksNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested addNewWebhookLike(io.kubernetes.client.openapi.models.V1ValidatingWebhook item) { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl.WebhooksNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + addNewWebhookLike(io.kubernetes.client.openapi.models.V1ValidatingWebhook item) { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl + .WebhooksNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested setNewWebhookLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhook item) { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl.WebhooksNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + setNewWebhookLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ValidatingWebhook item) { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl + .WebhooksNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested editWebhook(java.lang.Integer index) { - if (webhooks.size() <= index) throw new RuntimeException("Can't edit webhooks. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + editWebhook(java.lang.Integer index) { + if (webhooks.size() <= index) + throw new RuntimeException("Can't edit webhooks. Index exceeds size."); return setNewWebhookLike(index, buildWebhook(index)); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested editFirstWebhook() { - if (webhooks.size() == 0) throw new RuntimeException("Can't edit first webhooks. The list is empty."); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + editFirstWebhook() { + if (webhooks.size() == 0) + throw new RuntimeException("Can't edit first webhooks. The list is empty."); return setNewWebhookLike(0, buildWebhook(0)); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested editLastWebhook() { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + editLastWebhook() { int index = webhooks.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last webhooks. The list is empty."); return setNewWebhookLike(index, buildWebhook(index)); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested editMatchingWebhook(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + A> + editMatchingWebhook( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1ValidatingWebhookConfigurationFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class WebhooksNestedImpl extends io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl> implements io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested,io.kubernetes.client.fluent.Nested{ - WebhooksNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhook item) { + + public class WebhooksNestedImpl + extends io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent.WebhooksNested< + N>> + implements io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent + .WebhooksNested< + N>, + io.kubernetes.client.fluent.Nested { + WebhooksNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ValidatingWebhook item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(this, item); } + WebhooksNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder(this); } + io.kubernetes.client.openapi.models.V1ValidatingWebhookBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ValidatingWebhookConfigurationFluentImpl.this.setToWebhooks(index,builder.build()); + return (N) + V1ValidatingWebhookConfigurationFluentImpl.this.setToWebhooks(index, builder.build()); } + public N endWebhook() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationListBuilder.java index b0f6ca2244..b15603cad4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ValidatingWebhookConfigurationListBuilder extends io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ValidatingWebhookConfigurationListBuilder + extends io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluentImpl< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationList, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListBuilder> { public V1ValidatingWebhookConfigurationListBuilder() { this(false); } + public V1ValidatingWebhookConfigurationListBuilder(java.lang.Boolean validationEnabled) { this(new V1ValidatingWebhookConfigurationList(), validationEnabled); } - public V1ValidatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent fluent) { + + public V1ValidatingWebhookConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent fluent) { this(fluent, false); } - public V1ValidatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ValidatingWebhookConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ValidatingWebhookConfigurationList(), validationEnabled); } - public V1ValidatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent fluent,io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationList instance) { + + public V1ValidatingWebhookConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent fluent, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationList instance) { this(fluent, instance, false); } - public V1ValidatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent fluent,io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ValidatingWebhookConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent fluent, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1ValidatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi. fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1ValidatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationList instance) { - this(instance,false); + + public V1ValidatingWebhookConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationList instance) { + this(instance, false); } - public V1ValidatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ValidatingWebhookConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1ValidatingWebhookConfigurationListBuilder(io.kubernetes.client.openapi. this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationList build() { V1ValidatingWebhookConfigurationList buildable = new V1ValidatingWebhookConfigurationList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,24 @@ public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationList buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1ValidatingWebhookConfigurationListBuilder that = (V1ValidatingWebhookConfigurationListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1ValidatingWebhookConfigurationListBuilder that = + (V1ValidatingWebhookConfigurationListBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationListFluent.java index 1526164298..addcd9ca35 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationListFluent.java @@ -1,95 +1,195 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ValidatingWebhookConfigurationListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ValidatingWebhookConfigurationListFluent< + A extends io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item); - public A addToItems(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration... items); - public A addAllToItems(java.util.Collection items); - public A removeFromItems(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item); + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item); + + public A addToItems( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration... items); + + public A addAllToItems( + java.util.Collection + items); + + public A removeFromItems( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration... items); + + public A removeAllFromItems( + java.util.Collection + items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getItems(); - public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration buildItem(java.lang.Integer index); + public java.util.List + getItems(); + + public java.util.List + buildItems(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration buildFirstItem(); + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration buildLastItem(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + addNewItem(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + addNewItemLike(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + editLastItem(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent>{ + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .MetadataNested< + A> + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .MetadataNested< + A> + editMetadata(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluent< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationListFluentImpl.java index 7ddbcffeaf..c7827841d5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookConfigurationListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1ValidatingWebhookConfigurationListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent{ - public V1ValidatingWebhookConfigurationListFluentImpl() { - } - public V1ValidatingWebhookConfigurationListFluentImpl(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationList instance) { + +/** Generated */ +public class V1ValidatingWebhookConfigurationListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent { + public V1ValidatingWebhookConfigurationListFluentImpl() {} + + public V1ValidatingWebhookConfigurationListFluentImpl( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,233 +31,464 @@ public V1ValidatingWebhookConfigurationListFluentImpl(io.kubernetes.client.opena this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder> + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder>(); + } + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder>(); + } + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } - public A addToItems(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item : items) {io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addToItems( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration... items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item : items) { + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item : items) {io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection + items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item : items) { + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A removeFromItems(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration... items) { - for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item : items) {io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeFromItems( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration... items) { + for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item : items) { + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item : items) {io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item : items) { + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator + each = items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getItems() { + public java.util.List + getItems() { return items != null ? build(items) : null; } - public java.util.List buildItems() { + + public java.util.List + buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } - public A withItems(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item :items){ this.addToItems(item);}} return (A) this; + + public A withItems( + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration... items) { + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + addNewItem() { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item) { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + addNewItemLike(io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item) { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item) { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item) { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested< + A> + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .MetadataNested< + A> + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .MetadataNested< + A> + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1ValidatingWebhookConfigurationListFluentImpl that = (V1ValidatingWebhookConfigurationListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + V1ValidatingWebhookConfigurationListFluentImpl that = + (V1ValidatingWebhookConfigurationListFluentImpl) o; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl> implements io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .ItemsNested< + N>> + implements io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfiguration item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder( + this, item); } + ItemsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder(this); } + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ValidatingWebhookConfigurationListFluentImpl.this.setToItems(index,builder.build()); + return (N) + V1ValidatingWebhookConfigurationListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V1ValidatingWebhookConfigurationListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1ValidatingWebhookConfigurationListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookFluent.java index d23c32e277..b42e1b12b2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookFluent.java @@ -1,172 +1,305 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1ValidatingWebhookFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAdmissionReviewVersions(java.lang.Integer index,java.lang.String item); - public A setToAdmissionReviewVersions(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1ValidatingWebhookFluent< + A extends io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAdmissionReviewVersions(java.lang.Integer index, java.lang.String item); + + public A setToAdmissionReviewVersions(java.lang.Integer index, java.lang.String item); + public A addToAdmissionReviewVersions(java.lang.String... items); + public A addAllToAdmissionReviewVersions(java.util.Collection items); + public A removeFromAdmissionReviewVersions(java.lang.String... items); + public A removeAllFromAdmissionReviewVersions(java.util.Collection items); + public java.util.List getAdmissionReviewVersions(); + public java.lang.String getAdmissionReviewVersion(java.lang.Integer index); + public java.lang.String getFirstAdmissionReviewVersion(); + public java.lang.String getLastAdmissionReviewVersion(); - public java.lang.String getMatchingAdmissionReviewVersion(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAdmissionReviewVersion(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAdmissionReviewVersion( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAdmissionReviewVersion( + java.util.function.Predicate predicate); + public A withAdmissionReviewVersions(java.util.List admissionReviewVersions); + public A withAdmissionReviewVersions(java.lang.String... admissionReviewVersions); + public java.lang.Boolean hasAdmissionReviewVersions(); + public A addNewAdmissionReviewVersion(java.lang.String original); - + /** * This method has been deprecated, please use method buildClientConfig instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig getClientConfig(); - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig buildClientConfig(); - public A withClientConfig(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig clientConfig); + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig + getClientConfig(); + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig + buildClientConfig(); + + public A withClientConfig( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig clientConfig); + public java.lang.Boolean hasClientConfig(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested withNewClientConfig(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested withNewClientConfigLike(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested editClientConfig(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested editOrNewClientConfig(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested editOrNewClientConfigLike(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested + withNewClientConfig(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested + withNewClientConfigLike( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested + editClientConfig(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested + editOrNewClientConfig(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested + editOrNewClientConfigLike( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item); + public java.lang.String getFailurePolicy(); + public A withFailurePolicy(java.lang.String failurePolicy); + public java.lang.Boolean hasFailurePolicy(); - - /** - * Method is deprecated. use withFailurePolicy instead. - */ + + /** Method is deprecated. use withFailurePolicy instead. */ @java.lang.Deprecated public A withNewFailurePolicy(java.lang.String original); + public java.lang.String getMatchPolicy(); + public A withMatchPolicy(java.lang.String matchPolicy); + public java.lang.Boolean hasMatchPolicy(); - - /** - * Method is deprecated. use withMatchPolicy instead. - */ + + /** Method is deprecated. use withMatchPolicy instead. */ @java.lang.Deprecated public A withNewMatchPolicy(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - + /** * This method has been deprecated, please use method buildNamespaceSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getNamespaceSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildNamespaceSelector(); - public A withNamespaceSelector(io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector); + + public A withNamespaceSelector( + io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector); + public java.lang.Boolean hasNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested withNewNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested editNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested editOrNewNamespaceSelector(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested + withNewNamespaceSelector(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested + withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested + editNamespaceSelector(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested + editOrNewNamespaceSelector(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested + editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + /** * This method has been deprecated, please use method buildObjectSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getObjectSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildObjectSelector(); + public A withObjectSelector(io.kubernetes.client.openapi.models.V1LabelSelector objectSelector); + public java.lang.Boolean hasObjectSelector(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested withNewObjectSelector(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested withNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested editObjectSelector(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested editOrNewObjectSelector(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested editOrNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item); - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested + withNewObjectSelector(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested + withNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested + editObjectSelector(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested + editOrNewObjectSelector(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested + editOrNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public A addToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item); + + public A setToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item); + public A addToRules(io.kubernetes.client.openapi.models.V1RuleWithOperations... items); - public A addAllToRules(java.util.Collection items); + + public A addAllToRules( + java.util.Collection items); + public A removeFromRules(io.kubernetes.client.openapi.models.V1RuleWithOperations... items); - public A removeAllFromRules(java.util.Collection items); - public A removeMatchingFromRules(java.util.function.Predicate predicate); - + + public A removeAllFromRules( + java.util.Collection items); + + public A removeMatchingFromRules( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildRules instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getRules(); + public java.util.List buildRules(); - public io.kubernetes.client.openapi.models.V1RuleWithOperations buildRule(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildRule( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildFirstRule(); + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildLastRule(); - public io.kubernetes.client.openapi.models.V1RuleWithOperations buildMatchingRule(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate); - public A withRules(java.util.List rules); + + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildMatchingRule( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate + predicate); + + public A withRules( + java.util.List rules); + public A withRules(io.kubernetes.client.openapi.models.V1RuleWithOperations... rules); + public java.lang.Boolean hasRules(); + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested addNewRule(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1RuleWithOperations item); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested editRule(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested editFirstRule(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested editLastRule(); - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested + addNewRuleLike(io.kubernetes.client.openapi.models.V1RuleWithOperations item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested + setNewRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested editRule( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested + editFirstRule(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested + editLastRule(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested + editMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder> + predicate); + public java.lang.String getSideEffects(); + public A withSideEffects(java.lang.String sideEffects); + public java.lang.Boolean hasSideEffects(); - - /** - * Method is deprecated. use withSideEffects instead. - */ + + /** Method is deprecated. use withSideEffects instead. */ @java.lang.Deprecated public A withNewSideEffects(java.lang.String original); + public java.lang.Integer getTimeoutSeconds(); + public A withTimeoutSeconds(java.lang.Integer timeoutSeconds); + public java.lang.Boolean hasTimeoutSeconds(); - public interface ClientConfigNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent>{ + + public interface ClientConfigNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluent< + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested> { public N and(); + public N endClientConfig(); - } - public interface NamespaceSelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface NamespaceSelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested< + N>> { public N and(); + public N endNamespaceSelector(); - } - public interface ObjectSelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface ObjectSelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested< + N>> { public N and(); + public N endObjectSelector(); - } - public interface RulesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent>{ + + public interface RulesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1RuleWithOperationsFluent< + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested> { public N and(); + public N endRule(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookFluentImpl.java index 4cfecf811f..5771d3e14e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidatingWebhookFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1ValidatingWebhookFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent{ - public V1ValidatingWebhookFluentImpl() { - } - public V1ValidatingWebhookFluentImpl(io.kubernetes.client.openapi.models.V1ValidatingWebhook instance) { + +/** Generated */ +public class V1ValidatingWebhookFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent { + public V1ValidatingWebhookFluentImpl() {} + + public V1ValidatingWebhookFluentImpl( + io.kubernetes.client.openapi.models.V1ValidatingWebhook instance) { this.withAdmissionReviewVersions(instance.getAdmissionReviewVersions()); this.withClientConfig(instance.getClientConfig()); @@ -40,253 +43,482 @@ public V1ValidatingWebhookFluentImpl(io.kubernetes.client.openapi.models.V1Valid this.withSideEffects(instance.getSideEffects()); this.withTimeoutSeconds(instance.getTimeoutSeconds()); - } + private java.util.List admissionReviewVersions; - private io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder clientConfig; + private io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder + clientConfig; private java.lang.String failurePolicy; private java.lang.String matchPolicy; private java.lang.String name; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder namespaceSelector; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder objectSelector; - private java.util.ArrayList rules; + private java.util.ArrayList + rules; private java.lang.String sideEffects; private java.lang.Integer timeoutSeconds; - public A addToAdmissionReviewVersions(java.lang.Integer index,java.lang.String item) { - if (this.admissionReviewVersions == null) {this.admissionReviewVersions = new java.util.ArrayList();} + + public A addToAdmissionReviewVersions(java.lang.Integer index, java.lang.String item) { + if (this.admissionReviewVersions == null) { + this.admissionReviewVersions = new java.util.ArrayList(); + } this.admissionReviewVersions.add(index, item); - return (A)this; + return (A) this; } - public A setToAdmissionReviewVersions(java.lang.Integer index,java.lang.String item) { - if (this.admissionReviewVersions == null) {this.admissionReviewVersions = new java.util.ArrayList();} - this.admissionReviewVersions.set(index, item); return (A)this; + + public A setToAdmissionReviewVersions(java.lang.Integer index, java.lang.String item) { + if (this.admissionReviewVersions == null) { + this.admissionReviewVersions = new java.util.ArrayList(); + } + this.admissionReviewVersions.set(index, item); + return (A) this; } + public A addToAdmissionReviewVersions(java.lang.String... items) { - if (this.admissionReviewVersions == null) {this.admissionReviewVersions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.admissionReviewVersions.add(item);} return (A)this; + if (this.admissionReviewVersions == null) { + this.admissionReviewVersions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.admissionReviewVersions.add(item); + } + return (A) this; } + public A addAllToAdmissionReviewVersions(java.util.Collection items) { - if (this.admissionReviewVersions == null) {this.admissionReviewVersions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.admissionReviewVersions.add(item);} return (A)this; + if (this.admissionReviewVersions == null) { + this.admissionReviewVersions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.admissionReviewVersions.add(item); + } + return (A) this; } + public A removeFromAdmissionReviewVersions(java.lang.String... items) { - for (java.lang.String item : items) {if (this.admissionReviewVersions!= null){ this.admissionReviewVersions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.admissionReviewVersions != null) { + this.admissionReviewVersions.remove(item); + } + } + return (A) this; } + public A removeAllFromAdmissionReviewVersions(java.util.Collection items) { - for (java.lang.String item : items) {if (this.admissionReviewVersions!= null){ this.admissionReviewVersions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.admissionReviewVersions != null) { + this.admissionReviewVersions.remove(item); + } + } + return (A) this; } + public java.util.List getAdmissionReviewVersions() { return this.admissionReviewVersions; } + public java.lang.String getAdmissionReviewVersion(java.lang.Integer index) { return this.admissionReviewVersions.get(index); } + public java.lang.String getFirstAdmissionReviewVersion() { return this.admissionReviewVersions.get(0); } + public java.lang.String getLastAdmissionReviewVersion() { return this.admissionReviewVersions.get(admissionReviewVersions.size() - 1); } - public java.lang.String getMatchingAdmissionReviewVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: admissionReviewVersions) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAdmissionReviewVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : admissionReviewVersions) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAdmissionReviewVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: admissionReviewVersions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAdmissionReviewVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : admissionReviewVersions) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAdmissionReviewVersions(java.util.List admissionReviewVersions) { - if (admissionReviewVersions != null) {this.admissionReviewVersions = new java.util.ArrayList(); for (java.lang.String item : admissionReviewVersions){this.addToAdmissionReviewVersions(item);}} else { this.admissionReviewVersions = null;} return (A) this; + if (admissionReviewVersions != null) { + this.admissionReviewVersions = new java.util.ArrayList(); + for (java.lang.String item : admissionReviewVersions) { + this.addToAdmissionReviewVersions(item); + } + } else { + this.admissionReviewVersions = null; + } + return (A) this; } + public A withAdmissionReviewVersions(java.lang.String... admissionReviewVersions) { - if (this.admissionReviewVersions != null) {this.admissionReviewVersions.clear();} - if (admissionReviewVersions != null) {for (java.lang.String item :admissionReviewVersions){ this.addToAdmissionReviewVersions(item);}} return (A) this; + if (this.admissionReviewVersions != null) { + this.admissionReviewVersions.clear(); + } + if (admissionReviewVersions != null) { + for (java.lang.String item : admissionReviewVersions) { + this.addToAdmissionReviewVersions(item); + } + } + return (A) this; } + public java.lang.Boolean hasAdmissionReviewVersions() { return admissionReviewVersions != null && !admissionReviewVersions.isEmpty(); } + public A addNewAdmissionReviewVersion(java.lang.String original) { - return (A)addToAdmissionReviewVersions(new String(original)); + return (A) addToAdmissionReviewVersions(new String(original)); } - + /** * This method has been deprecated, please use method buildClientConfig instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig getClientConfig() { - return this.clientConfig!=null ?this.clientConfig.build():null; + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig + getClientConfig() { + return this.clientConfig != null ? this.clientConfig.build() : null; } - public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig buildClientConfig() { - return this.clientConfig!=null ?this.clientConfig.build():null; + + public io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig + buildClientConfig() { + return this.clientConfig != null ? this.clientConfig.build() : null; } - public A withClientConfig(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig clientConfig) { + + public A withClientConfig( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig clientConfig) { _visitables.get("clientConfig").remove(this.clientConfig); - if (clientConfig!=null){ this.clientConfig= new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder(clientConfig); _visitables.get("clientConfig").add(this.clientConfig);} return (A) this; + if (clientConfig != null) { + this.clientConfig = + new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder( + clientConfig); + _visitables.get("clientConfig").add(this.clientConfig); + } + return (A) this; } + public java.lang.Boolean hasClientConfig() { return this.clientConfig != null; } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested withNewClientConfig() { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl.ClientConfigNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested + withNewClientConfig() { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl + .ClientConfigNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested withNewClientConfigLike(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item) { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl.ClientConfigNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested + withNewClientConfigLike( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item) { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl + .ClientConfigNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested editClientConfig() { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested + editClientConfig() { return withNewClientConfigLike(getClientConfig()); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested editOrNewClientConfig() { - return withNewClientConfigLike(getClientConfig() != null ? getClientConfig(): new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested + editOrNewClientConfig() { + return withNewClientConfigLike( + getClientConfig() != null + ? getClientConfig() + : new io.kubernetes.client.openapi.models + .AdmissionregistrationV1WebhookClientConfigBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested editOrNewClientConfigLike(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item) { - return withNewClientConfigLike(getClientConfig() != null ? getClientConfig(): item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested + editOrNewClientConfigLike( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item) { + return withNewClientConfigLike(getClientConfig() != null ? getClientConfig() : item); } + public java.lang.String getFailurePolicy() { return this.failurePolicy; } + public A withFailurePolicy(java.lang.String failurePolicy) { - this.failurePolicy=failurePolicy; return (A) this; + this.failurePolicy = failurePolicy; + return (A) this; } + public java.lang.Boolean hasFailurePolicy() { return this.failurePolicy != null; } - - /** - * Method is deprecated. use withFailurePolicy instead. - */ + + /** Method is deprecated. use withFailurePolicy instead. */ @java.lang.Deprecated public A withNewFailurePolicy(java.lang.String original) { - return (A)withFailurePolicy(new String(original)); + return (A) withFailurePolicy(new String(original)); } + public java.lang.String getMatchPolicy() { return this.matchPolicy; } + public A withMatchPolicy(java.lang.String matchPolicy) { - this.matchPolicy=matchPolicy; return (A) this; + this.matchPolicy = matchPolicy; + return (A) this; } + public java.lang.Boolean hasMatchPolicy() { return this.matchPolicy != null; } - - /** - * Method is deprecated. use withMatchPolicy instead. - */ + + /** Method is deprecated. use withMatchPolicy instead. */ @java.lang.Deprecated public A withNewMatchPolicy(java.lang.String original) { - return (A)withMatchPolicy(new String(original)); + return (A) withMatchPolicy(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } - + /** * This method has been deprecated, please use method buildNamespaceSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getNamespaceSelector() { - return this.namespaceSelector!=null ?this.namespaceSelector.build():null; + return this.namespaceSelector != null ? this.namespaceSelector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildNamespaceSelector() { - return this.namespaceSelector!=null ?this.namespaceSelector.build():null; + return this.namespaceSelector != null ? this.namespaceSelector.build() : null; } - public A withNamespaceSelector(io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector) { + + public A withNamespaceSelector( + io.kubernetes.client.openapi.models.V1LabelSelector namespaceSelector) { _visitables.get("namespaceSelector").remove(this.namespaceSelector); - if (namespaceSelector!=null){ this.namespaceSelector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(namespaceSelector); _visitables.get("namespaceSelector").add(this.namespaceSelector);} return (A) this; + if (namespaceSelector != null) { + this.namespaceSelector = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(namespaceSelector); + _visitables.get("namespaceSelector").add(this.namespaceSelector); + } + return (A) this; } + public java.lang.Boolean hasNamespaceSelector() { return this.namespaceSelector != null; } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested withNewNamespaceSelector() { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl.NamespaceSelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested + withNewNamespaceSelector() { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl + .NamespaceSelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl.NamespaceSelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested + withNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl + .NamespaceSelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested editNamespaceSelector() { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested + editNamespaceSelector() { return withNewNamespaceSelectorLike(getNamespaceSelector()); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested editOrNewNamespaceSelector() { - return withNewNamespaceSelectorLike(getNamespaceSelector() != null ? getNamespaceSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested + editOrNewNamespaceSelector() { + return withNewNamespaceSelectorLike( + getNamespaceSelector() != null + ? getNamespaceSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewNamespaceSelectorLike(getNamespaceSelector() != null ? getNamespaceSelector(): item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested + editOrNewNamespaceSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewNamespaceSelectorLike( + getNamespaceSelector() != null ? getNamespaceSelector() : item); } - + /** * This method has been deprecated, please use method buildObjectSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getObjectSelector() { - return this.objectSelector!=null ?this.objectSelector.build():null; + return this.objectSelector != null ? this.objectSelector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildObjectSelector() { - return this.objectSelector!=null ?this.objectSelector.build():null; + return this.objectSelector != null ? this.objectSelector.build() : null; } + public A withObjectSelector(io.kubernetes.client.openapi.models.V1LabelSelector objectSelector) { _visitables.get("objectSelector").remove(this.objectSelector); - if (objectSelector!=null){ this.objectSelector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(objectSelector); _visitables.get("objectSelector").add(this.objectSelector);} return (A) this; + if (objectSelector != null) { + this.objectSelector = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(objectSelector); + _visitables.get("objectSelector").add(this.objectSelector); + } + return (A) this; } + public java.lang.Boolean hasObjectSelector() { return this.objectSelector != null; } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested withNewObjectSelector() { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl.ObjectSelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested + withNewObjectSelector() { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl + .ObjectSelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested withNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl.ObjectSelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested + withNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl + .ObjectSelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested editObjectSelector() { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested + editObjectSelector() { return withNewObjectSelectorLike(getObjectSelector()); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested editOrNewObjectSelector() { - return withNewObjectSelectorLike(getObjectSelector() != null ? getObjectSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested + editOrNewObjectSelector() { + return withNewObjectSelectorLike( + getObjectSelector() != null + ? getObjectSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested editOrNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewObjectSelectorLike(getObjectSelector() != null ? getObjectSelector(): item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested + editOrNewObjectSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewObjectSelectorLike(getObjectSelector() != null ? getObjectSelector() : item); } - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item);_visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder);this.rules.add(index >= 0 ? index : rules.size(), builder); return (A)this; + + public A addToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder>(); + } + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); + _visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder); + this.rules.add(index >= 0 ? index : rules.size(), builder); + return (A) this; } - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); - if (index < 0 || index >= _visitables.get("rules").size()) { _visitables.get("rules").add(builder); } else { _visitables.get("rules").set(index, builder);} - if (index < 0 || index >= rules.size()) { rules.add(builder); } else { rules.set(index, builder);} - return (A)this; + + public A setToRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder>(); + } + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); + if (index < 0 || index >= _visitables.get("rules").size()) { + _visitables.get("rules").add(builder); + } else { + _visitables.get("rules").set(index, builder); + } + if (index < 0 || index >= rules.size()) { + rules.add(builder); + } else { + rules.set(index, builder); + } + return (A) this; } + public A addToRules(io.kubernetes.client.openapi.models.V1RuleWithOperations... items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) {io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) { + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } - public A addAllToRules(java.util.Collection items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) {io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + + public A addAllToRules( + java.util.Collection items) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) { + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } + public A removeFromRules(io.kubernetes.client.openapi.models.V1RuleWithOperations... items) { - for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) {io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) { + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeAllFromRules(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) {io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + + public A removeAllFromRules( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : items) { + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromRules(java.util.function.Predicate predicate) { + + public A removeMatchingFromRules( + java.util.function.Predicate + predicate) { if (rules == null) return (A) this; - final Iterator each = rules.iterator(); + final Iterator each = + rules.iterator(); final List visitables = _visitables.get("rules"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder = each.next(); @@ -295,187 +527,327 @@ public A removeMatchingFromRules(java.util.function.Predicate getRules() { return rules != null ? build(rules) : null; } + public java.util.List buildRules() { return rules != null ? build(rules) : null; } - public io.kubernetes.client.openapi.models.V1RuleWithOperations buildRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildRule( + java.lang.Integer index) { return this.rules.get(index).build(); } + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildFirstRule() { return this.rules.get(0).build(); } + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildLastRule() { return this.rules.get(rules.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1RuleWithOperations buildMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder item: rules) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1RuleWithOperations buildMatchingRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder item : rules) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder item: rules) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder item : rules) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withRules(java.util.List rules) { - if (this.rules != null) { _visitables.get("rules").removeAll(this.rules);} - if (rules != null) {this.rules = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : rules){this.addToRules(item);}} else { this.rules = null;} return (A) this; + + public A withRules( + java.util.List rules) { + if (this.rules != null) { + _visitables.get("rules").removeAll(this.rules); + } + if (rules != null) { + this.rules = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : rules) { + this.addToRules(item); + } + } else { + this.rules = null; + } + return (A) this; } + public A withRules(io.kubernetes.client.openapi.models.V1RuleWithOperations... rules) { - if (this.rules != null) {this.rules.clear();} - if (rules != null) {for (io.kubernetes.client.openapi.models.V1RuleWithOperations item :rules){ this.addToRules(item);}} return (A) this; + if (this.rules != null) { + this.rules.clear(); + } + if (rules != null) { + for (io.kubernetes.client.openapi.models.V1RuleWithOperations item : rules) { + this.addToRules(item); + } + } + return (A) this; } + public java.lang.Boolean hasRules() { return rules != null && !rules.isEmpty(); } + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested addNewRule() { return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl.RulesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1RuleWithOperations item) { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl.RulesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested + addNewRuleLike(io.kubernetes.client.openapi.models.V1RuleWithOperations item) { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl.RulesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item) { - return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl.RulesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested + setNewRuleLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item) { + return new io.kubernetes.client.openapi.models.V1ValidatingWebhookFluentImpl.RulesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested editRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested editRule( + java.lang.Integer index) { if (rules.size() <= index) throw new RuntimeException("Can't edit rules. Index exceeds size."); return setNewRuleLike(index, buildRule(index)); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested editFirstRule() { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested + editFirstRule() { if (rules.size() == 0) throw new RuntimeException("Can't edit first rules. The list is empty."); return setNewRuleLike(0, buildRule(0)); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested editLastRule() { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested + editLastRule() { int index = rules.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last rules. The list is empty."); return setNewRuleLike(index, buildRule(index)); } - public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested + editMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigFluentImpl> implements io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested,io.kubernetes.client.fluent.Nested{ - ClientConfigNestedImpl(io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item) { - this.builder = new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder(this, item); + + public class ClientConfigNestedImpl + extends io.kubernetes.client.openapi.models + .AdmissionregistrationV1WebhookClientConfigFluentImpl< + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested> + implements io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ClientConfigNested< + N>, + io.kubernetes.client.fluent.Nested { + ClientConfigNestedImpl( + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfig item) { + this.builder = + new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder( + this, item); } + ClientConfigNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder( + this); } + io.kubernetes.client.openapi.models.AdmissionregistrationV1WebhookClientConfigBuilder builder; + public N and() { return (N) V1ValidatingWebhookFluentImpl.this.withClientConfig(builder.build()); } + public N endClientConfig() { return and(); } - } - public class NamespaceSelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested,io.kubernetes.client.fluent.Nested{ + + public class NamespaceSelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.NamespaceSelectorNested> + implements io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent + .NamespaceSelectorNested< + N>, + io.kubernetes.client.fluent.Nested { NamespaceSelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + NamespaceSelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1ValidatingWebhookFluentImpl.this.withNamespaceSelector(builder.build()); } + public N endNamespaceSelector() { return and(); } - } - public class ObjectSelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested,io.kubernetes.client.fluent.Nested{ + + public class ObjectSelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested> + implements io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.ObjectSelectorNested< + N>, + io.kubernetes.client.fluent.Nested { ObjectSelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + ObjectSelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1ValidatingWebhookFluentImpl.this.withObjectSelector(builder.build()); } + public N endObjectSelector() { return and(); } - } - public class RulesNestedImpl extends io.kubernetes.client.openapi.models.V1RuleWithOperationsFluentImpl> implements io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested,io.kubernetes.client.fluent.Nested{ - RulesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1RuleWithOperations item) { + + public class RulesNestedImpl + extends io.kubernetes.client.openapi.models.V1RuleWithOperationsFluentImpl< + io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested> + implements io.kubernetes.client.openapi.models.V1ValidatingWebhookFluent.RulesNested, + io.kubernetes.client.fluent.Nested { + RulesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1RuleWithOperations item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(this, item); } + RulesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder(this); } + io.kubernetes.client.openapi.models.V1RuleWithOperationsBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1ValidatingWebhookFluentImpl.this.setToRules(index,builder.build()); + return (N) V1ValidatingWebhookFluentImpl.this.setToRules(index, builder.build()); } + public N endRule() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidationRuleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidationRuleBuilder.java index 38145b72e1..95ae7b23c2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidationRuleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidationRuleBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1ValidationRuleBuilder extends io.kubernetes.client.openapi.models.V1ValidationRuleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1ValidationRuleBuilder + extends io.kubernetes.client.openapi.models.V1ValidationRuleFluentImpl< + io.kubernetes.client.openapi.models.V1ValidationRuleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1ValidationRule, + io.kubernetes.client.openapi.models.V1ValidationRuleBuilder> { public V1ValidationRuleBuilder() { this(false); } + public V1ValidationRuleBuilder(java.lang.Boolean validationEnabled) { this(new V1ValidationRule(), validationEnabled); } - public V1ValidationRuleBuilder(io.kubernetes.client.openapi.models.V1ValidationRuleFluent fluent) { + + public V1ValidationRuleBuilder( + io.kubernetes.client.openapi.models.V1ValidationRuleFluent fluent) { this(fluent, false); } - public V1ValidationRuleBuilder(io.kubernetes.client.openapi.models.V1ValidationRuleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1ValidationRuleBuilder( + io.kubernetes.client.openapi.models.V1ValidationRuleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1ValidationRule(), validationEnabled); } - public V1ValidationRuleBuilder(io.kubernetes.client.openapi.models.V1ValidationRuleFluent fluent,io.kubernetes.client.openapi.models.V1ValidationRule instance) { + + public V1ValidationRuleBuilder( + io.kubernetes.client.openapi.models.V1ValidationRuleFluent fluent, + io.kubernetes.client.openapi.models.V1ValidationRule instance) { this(fluent, instance, false); } - public V1ValidationRuleBuilder(io.kubernetes.client.openapi.models.V1ValidationRuleFluent fluent,io.kubernetes.client.openapi.models.V1ValidationRule instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1ValidationRuleBuilder( + io.kubernetes.client.openapi.models.V1ValidationRuleFluent fluent, + io.kubernetes.client.openapi.models.V1ValidationRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMessage(instance.getMessage()); fluent.withRule(instance.getRule()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1ValidationRuleBuilder(io.kubernetes.client.openapi.models.V1ValidationRule instance) { - this(instance,false); + this(instance, false); } - public V1ValidationRuleBuilder(io.kubernetes.client.openapi.models.V1ValidationRule instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1ValidationRuleBuilder( + io.kubernetes.client.openapi.models.V1ValidationRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMessage(instance.getMessage()); this.withRule(instance.getRule()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1ValidationRuleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1ValidationRule build() { V1ValidationRule buildable = new V1ValidationRule(); buildable.setMessage(fluent.getMessage()); buildable.setRule(fluent.getRule()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1ValidationRuleBuilder that = (V1ValidationRuleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidationRuleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidationRuleFluent.java index 3d2f62eb01..1d206736fe 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidationRuleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidationRuleFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1ValidationRuleFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1ValidationRuleFluent< + A extends io.kubernetes.client.openapi.models.V1ValidationRuleFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getRule(); + public A withRule(java.lang.String rule); + public java.lang.Boolean hasRule(); - - /** - * Method is deprecated. use withRule instead. - */ + + /** Method is deprecated. use withRule instead. */ @java.lang.Deprecated public A withNewRule(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidationRuleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidationRuleFluentImpl.java index f8786c43ff..b9b6477bbc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidationRuleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1ValidationRuleFluentImpl.java @@ -1,69 +1,81 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1ValidationRuleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1ValidationRuleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1ValidationRuleFluent { + public V1ValidationRuleFluentImpl() {} - /** - * Generated - */ -public class V1ValidationRuleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1ValidationRuleFluent{ - public V1ValidationRuleFluentImpl() { - } public V1ValidationRuleFluentImpl(io.kubernetes.client.openapi.models.V1ValidationRule instance) { this.withMessage(instance.getMessage()); this.withRule(instance.getRule()); - } + private java.lang.String message; private java.lang.String rule; + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getRule() { return this.rule; } + public A withRule(java.lang.String rule) { - this.rule=rule; return (A) this; + this.rule = rule; + return (A) this; } + public java.lang.Boolean hasRule() { return this.rule != null; } - - /** - * Method is deprecated. use withRule instead. - */ + + /** Method is deprecated. use withRule instead. */ @java.lang.Deprecated public A withNewRule(java.lang.String original) { - return (A)withRule(new String(original)); + return (A) withRule(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1ValidationRuleFluentImpl that = (V1ValidationRuleFluentImpl) o; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (rule != null ? !rule.equals(that.rule) :that.rule != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (rule != null ? !rule.equals(that.rule) : that.rule != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(message, rule, super.hashCode()); + return java.util.Objects.hash(message, rule, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentBuilder.java index b01c7c13dd..27c130f69a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1VolumeAttachmentBuilder extends io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1VolumeAttachmentBuilder + extends io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1VolumeAttachment, + io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder> { public V1VolumeAttachmentBuilder() { this(false); } + public V1VolumeAttachmentBuilder(java.lang.Boolean validationEnabled) { this(new V1VolumeAttachment(), validationEnabled); } - public V1VolumeAttachmentBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent fluent) { + + public V1VolumeAttachmentBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent fluent) { this(fluent, false); } - public V1VolumeAttachmentBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent fluent,java.lang.Boolean validationEnabled) { + + public V1VolumeAttachmentBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1VolumeAttachment(), validationEnabled); } - public V1VolumeAttachmentBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent fluent,io.kubernetes.client.openapi.models.V1VolumeAttachment instance) { + + public V1VolumeAttachmentBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeAttachment instance) { this(fluent, instance, false); } - public V1VolumeAttachmentBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent fluent,io.kubernetes.client.openapi.models.V1VolumeAttachment instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1VolumeAttachmentBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeAttachment instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1VolumeAttachmentBuilder(io.kubernetes.client.openapi.models.V1VolumeAtt fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1VolumeAttachmentBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachment instance) { - this(instance,false); + + public V1VolumeAttachmentBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachment instance) { + this(instance, false); } - public V1VolumeAttachmentBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachment instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1VolumeAttachmentBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachment instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1VolumeAttachmentBuilder(io.kubernetes.client.openapi.models.V1VolumeAtt this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1VolumeAttachment build() { V1VolumeAttachment buildable = new V1VolumeAttachment(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1VolumeAttachment build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1VolumeAttachmentBuilder that = (V1VolumeAttachmentBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentFluent.java index 8dde4bd645..d96f9545a0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentFluent.java @@ -1,93 +1,148 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1VolumeAttachmentFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1VolumeAttachmentFluent< + A extends io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec getSpec(); + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec item); + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec item); - + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus getStatus(); + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus item); + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent< + io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent< + io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentFluentImpl.java index 90018253f5..53597fd6f5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1VolumeAttachmentFluentImpl< + A extends io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent { + public V1VolumeAttachmentFluentImpl() {} - /** - * Generated - */ -public class V1VolumeAttachmentFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent{ - public V1VolumeAttachmentFluentImpl() { - } - public V1VolumeAttachmentFluentImpl(io.kubernetes.client.openapi.models.V1VolumeAttachment instance) { + public V1VolumeAttachmentFluentImpl( + io.kubernetes.client.openapi.models.V1VolumeAttachment instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,306 @@ public V1VolumeAttachmentFluentImpl(io.kubernetes.client.openapi.models.V1Volume this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecBuilder spec; private io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec item) { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec item) { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl.SpecNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested withNewStatus() { + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested + withNewStatus() { return new io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus item) { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus item) { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl.StatusNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1VolumeAttachmentFluentImpl that = (V1VolumeAttachmentFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1VolumeAttachmentFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecBuilder builder; + public N and() { return (N) V1VolumeAttachmentFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusBuilder builder; + public N and() { return (N) V1VolumeAttachmentFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentListBuilder.java index 017608063f..5e6ef430c9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1VolumeAttachmentListBuilder extends io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1VolumeAttachmentListBuilder + extends io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1VolumeAttachmentList, + io.kubernetes.client.openapi.models.V1VolumeAttachmentListBuilder> { public V1VolumeAttachmentListBuilder() { this(false); } + public V1VolumeAttachmentListBuilder(java.lang.Boolean validationEnabled) { this(new V1VolumeAttachmentList(), validationEnabled); } - public V1VolumeAttachmentListBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent fluent) { + + public V1VolumeAttachmentListBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent fluent) { this(fluent, false); } - public V1VolumeAttachmentListBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1VolumeAttachmentListBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1VolumeAttachmentList(), validationEnabled); } - public V1VolumeAttachmentListBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent fluent,io.kubernetes.client.openapi.models.V1VolumeAttachmentList instance) { + + public V1VolumeAttachmentListBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeAttachmentList instance) { this(fluent, instance, false); } - public V1VolumeAttachmentListBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent fluent,io.kubernetes.client.openapi.models.V1VolumeAttachmentList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1VolumeAttachmentListBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeAttachmentList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1VolumeAttachmentListBuilder(io.kubernetes.client.openapi.models.V1Volum fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1VolumeAttachmentListBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentList instance) { - this(instance,false); + + public V1VolumeAttachmentListBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentList instance) { + this(instance, false); } - public V1VolumeAttachmentListBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1VolumeAttachmentListBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1VolumeAttachmentListBuilder(io.kubernetes.client.openapi.models.V1Volum this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1VolumeAttachmentList build() { V1VolumeAttachmentList buildable = new V1VolumeAttachmentList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1VolumeAttachmentList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1VolumeAttachmentListBuilder that = (V1VolumeAttachmentListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentListFluent.java index 23daaa5545..7b8b5f486b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentListFluent.java @@ -1,95 +1,160 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1VolumeAttachmentListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1VolumeAttachmentListFluent< + A extends io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeAttachment item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeAttachment item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeAttachment item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeAttachment item); + public A addToItems(io.kubernetes.client.openapi.models.V1VolumeAttachment... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1VolumeAttachment... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1VolumeAttachment buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1VolumeAttachment buildFirstItem(); + public io.kubernetes.client.openapi.models.V1VolumeAttachment buildLastItem(); - public io.kubernetes.client.openapi.models.V1VolumeAttachment buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1VolumeAttachment buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1VolumeAttachment... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1VolumeAttachment item); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeAttachment item); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1VolumeAttachment item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeAttachment item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent>{ + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeAttachmentFluent< + io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentListFluentImpl.java index 44ac50dc29..834dded776 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1VolumeAttachmentListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent{ - public V1VolumeAttachmentListFluentImpl() { - } - public V1VolumeAttachmentListFluentImpl(io.kubernetes.client.openapi.models.V1VolumeAttachmentList instance) { + +/** Generated */ +public class V1VolumeAttachmentListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent { + public V1VolumeAttachmentListFluentImpl() {} + + public V1VolumeAttachmentListFluentImpl( + io.kubernetes.client.openapi.models.V1VolumeAttachmentList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1VolumeAttachmentListFluentImpl(io.kubernetes.client.openapi.models.V1Vo this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeAttachment item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeAttachment item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeAttachment item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeAttachment item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1VolumeAttachment... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1VolumeAttachment item : items) {io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1VolumeAttachment item : items) { + io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1VolumeAttachment item : items) {io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1VolumeAttachment item : items) { + io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1VolumeAttachment... items) { - for (io.kubernetes.client.openapi.models.V1VolumeAttachment item : items) {io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1VolumeAttachment item : items) { + io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1VolumeAttachment item : items) {io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1VolumeAttachment item : items) { + io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder = + new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder = each.next(); @@ -87,174 +159,283 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1VolumeAttachment buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1VolumeAttachment buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1VolumeAttachment buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1VolumeAttachment buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1VolumeAttachment buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1VolumeAttachment item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1VolumeAttachment item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1VolumeAttachment... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1VolumeAttachment item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1VolumeAttachment item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1VolumeAttachment item) { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1VolumeAttachment item) { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeAttachment item) { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeAttachment item) { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1VolumeAttachmentListFluentImpl that = (V1VolumeAttachmentListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1VolumeAttachment item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeAttachmentFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1VolumeAttachment item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeAttachmentBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1VolumeAttachmentListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1VolumeAttachmentListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1VolumeAttachmentListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSourceBuilder.java index ed1cb9e66e..1bb8fdfeb8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1VolumeAttachmentSourceBuilder extends io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1VolumeAttachmentSourceBuilder + extends io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1VolumeAttachmentSource, + io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceBuilder> { public V1VolumeAttachmentSourceBuilder() { this(false); } + public V1VolumeAttachmentSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1VolumeAttachmentSource(), validationEnabled); } - public V1VolumeAttachmentSourceBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent fluent) { + + public V1VolumeAttachmentSourceBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent fluent) { this(fluent, false); } - public V1VolumeAttachmentSourceBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1VolumeAttachmentSourceBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1VolumeAttachmentSource(), validationEnabled); } - public V1VolumeAttachmentSourceBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent fluent,io.kubernetes.client.openapi.models.V1VolumeAttachmentSource instance) { + + public V1VolumeAttachmentSourceBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeAttachmentSource instance) { this(fluent, instance, false); } - public V1VolumeAttachmentSourceBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent fluent,io.kubernetes.client.openapi.models.V1VolumeAttachmentSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1VolumeAttachmentSourceBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeAttachmentSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withInlineVolumeSpec(instance.getInlineVolumeSpec()); fluent.withPersistentVolumeName(instance.getPersistentVolumeName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1VolumeAttachmentSourceBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource instance) { - this(instance,false); + + public V1VolumeAttachmentSourceBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSource instance) { + this(instance, false); } - public V1VolumeAttachmentSourceBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1VolumeAttachmentSourceBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withInlineVolumeSpec(instance.getInlineVolumeSpec()); this.withPersistentVolumeName(instance.getPersistentVolumeName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSource build() { V1VolumeAttachmentSource buildable = new V1VolumeAttachmentSource(); buildable.setInlineVolumeSpec(fluent.getInlineVolumeSpec()); buildable.setPersistentVolumeName(fluent.getPersistentVolumeName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1VolumeAttachmentSourceBuilder that = (V1VolumeAttachmentSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSourceFluent.java index c408c5ec83..60d9894eb8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSourceFluent.java @@ -1,44 +1,76 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1VolumeAttachmentSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1VolumeAttachmentSourceFluent< + A extends io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildInlineVolumeSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec getInlineVolumeSpec(); + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec buildInlineVolumeSpec(); - public A withInlineVolumeSpec(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec inlineVolumeSpec); + + public A withInlineVolumeSpec( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec inlineVolumeSpec); + public java.lang.Boolean hasInlineVolumeSpec(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested withNewInlineVolumeSpec(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested withNewInlineVolumeSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested editInlineVolumeSpec(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested editOrNewInlineVolumeSpec(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested editOrNewInlineVolumeSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested< + A> + withNewInlineVolumeSpec(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested< + A> + withNewInlineVolumeSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested< + A> + editInlineVolumeSpec(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested< + A> + editOrNewInlineVolumeSpec(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested< + A> + editOrNewInlineVolumeSpecLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item); + public java.lang.String getPersistentVolumeName(); + public A withPersistentVolumeName(java.lang.String persistentVolumeName); + public java.lang.Boolean hasPersistentVolumeName(); - - /** - * Method is deprecated. use withPersistentVolumeName instead. - */ + + /** Method is deprecated. use withPersistentVolumeName instead. */ @java.lang.Deprecated public A withNewPersistentVolumeName(java.lang.String original); - public interface InlineVolumeSpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent>{ + + public interface InlineVolumeSpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluent< + io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent + .InlineVolumeSpecNested< + N>> { public N and(); + public N endInlineVolumeSpec(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSourceFluentImpl.java index c6c7f2a4ca..05b7e6b42c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSourceFluentImpl.java @@ -1,103 +1,161 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1VolumeAttachmentSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent { + public V1VolumeAttachmentSourceFluentImpl() {} - /** - * Generated - */ -public class V1VolumeAttachmentSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent{ - public V1VolumeAttachmentSourceFluentImpl() { - } - public V1VolumeAttachmentSourceFluentImpl(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource instance) { + public V1VolumeAttachmentSourceFluentImpl( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSource instance) { this.withInlineVolumeSpec(instance.getInlineVolumeSpec()); this.withPersistentVolumeName(instance.getPersistentVolumeName()); - } + private io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder inlineVolumeSpec; private java.lang.String persistentVolumeName; - + /** * This method has been deprecated, please use method buildInlineVolumeSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec getInlineVolumeSpec() { - return this.inlineVolumeSpec!=null ?this.inlineVolumeSpec.build():null; + return this.inlineVolumeSpec != null ? this.inlineVolumeSpec.build() : null; } + public io.kubernetes.client.openapi.models.V1PersistentVolumeSpec buildInlineVolumeSpec() { - return this.inlineVolumeSpec!=null ?this.inlineVolumeSpec.build():null; + return this.inlineVolumeSpec != null ? this.inlineVolumeSpec.build() : null; } - public A withInlineVolumeSpec(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec inlineVolumeSpec) { + + public A withInlineVolumeSpec( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec inlineVolumeSpec) { _visitables.get("inlineVolumeSpec").remove(this.inlineVolumeSpec); - if (inlineVolumeSpec!=null){ this.inlineVolumeSpec= new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder(inlineVolumeSpec); _visitables.get("inlineVolumeSpec").add(this.inlineVolumeSpec);} return (A) this; + if (inlineVolumeSpec != null) { + this.inlineVolumeSpec = + new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder(inlineVolumeSpec); + _visitables.get("inlineVolumeSpec").add(this.inlineVolumeSpec); + } + return (A) this; } + public java.lang.Boolean hasInlineVolumeSpec() { return this.inlineVolumeSpec != null; } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested withNewInlineVolumeSpec() { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluentImpl.InlineVolumeSpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested< + A> + withNewInlineVolumeSpec() { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluentImpl + .InlineVolumeSpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested withNewInlineVolumeSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item) { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluentImpl.InlineVolumeSpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested< + A> + withNewInlineVolumeSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item) { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluentImpl + .InlineVolumeSpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested editInlineVolumeSpec() { + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested< + A> + editInlineVolumeSpec() { return withNewInlineVolumeSpecLike(getInlineVolumeSpec()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested editOrNewInlineVolumeSpec() { - return withNewInlineVolumeSpecLike(getInlineVolumeSpec() != null ? getInlineVolumeSpec(): new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested< + A> + editOrNewInlineVolumeSpec() { + return withNewInlineVolumeSpecLike( + getInlineVolumeSpec() != null + ? getInlineVolumeSpec() + : new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested editOrNewInlineVolumeSpecLike(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item) { - return withNewInlineVolumeSpecLike(getInlineVolumeSpec() != null ? getInlineVolumeSpec(): item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested< + A> + editOrNewInlineVolumeSpecLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item) { + return withNewInlineVolumeSpecLike( + getInlineVolumeSpec() != null ? getInlineVolumeSpec() : item); } + public java.lang.String getPersistentVolumeName() { return this.persistentVolumeName; } + public A withPersistentVolumeName(java.lang.String persistentVolumeName) { - this.persistentVolumeName=persistentVolumeName; return (A) this; + this.persistentVolumeName = persistentVolumeName; + return (A) this; } + public java.lang.Boolean hasPersistentVolumeName() { return this.persistentVolumeName != null; } - - /** - * Method is deprecated. use withPersistentVolumeName instead. - */ + + /** Method is deprecated. use withPersistentVolumeName instead. */ @java.lang.Deprecated public A withNewPersistentVolumeName(java.lang.String original) { - return (A)withPersistentVolumeName(new String(original)); + return (A) withPersistentVolumeName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1VolumeAttachmentSourceFluentImpl that = (V1VolumeAttachmentSourceFluentImpl) o; - if (inlineVolumeSpec != null ? !inlineVolumeSpec.equals(that.inlineVolumeSpec) :that.inlineVolumeSpec != null) return false; - if (persistentVolumeName != null ? !persistentVolumeName.equals(that.persistentVolumeName) :that.persistentVolumeName != null) return false; + if (inlineVolumeSpec != null + ? !inlineVolumeSpec.equals(that.inlineVolumeSpec) + : that.inlineVolumeSpec != null) return false; + if (persistentVolumeName != null + ? !persistentVolumeName.equals(that.persistentVolumeName) + : that.persistentVolumeName != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(inlineVolumeSpec, persistentVolumeName, super.hashCode()); + return java.util.Objects.hash(inlineVolumeSpec, persistentVolumeName, super.hashCode()); } - public class InlineVolumeSpecNestedImpl extends io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested,io.kubernetes.client.fluent.Nested{ + + public class InlineVolumeSpecNestedImpl + extends io.kubernetes.client.openapi.models.V1PersistentVolumeSpecFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent.InlineVolumeSpecNested< + N>> + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent + .InlineVolumeSpecNested< + N>, + io.kubernetes.client.fluent.Nested { InlineVolumeSpecNestedImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder(this, item); } + InlineVolumeSpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1PersistentVolumeSpecBuilder builder; + public N and() { return (N) V1VolumeAttachmentSourceFluentImpl.this.withInlineVolumeSpec(builder.build()); } + public N endInlineVolumeSpec() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSpecBuilder.java index af686cfb14..2a710620f8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSpecBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1VolumeAttachmentSpecBuilder extends io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1VolumeAttachmentSpecBuilder + extends io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec, + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecBuilder> { public V1VolumeAttachmentSpecBuilder() { this(false); } + public V1VolumeAttachmentSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1VolumeAttachmentSpec(), validationEnabled); } - public V1VolumeAttachmentSpecBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent fluent) { + + public V1VolumeAttachmentSpecBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent fluent) { this(fluent, false); } - public V1VolumeAttachmentSpecBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1VolumeAttachmentSpecBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1VolumeAttachmentSpec(), validationEnabled); } - public V1VolumeAttachmentSpecBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent fluent,io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec instance) { + + public V1VolumeAttachmentSpecBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec instance) { this(fluent, instance, false); } - public V1VolumeAttachmentSpecBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent fluent,io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1VolumeAttachmentSpecBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAttacher(instance.getAttacher()); fluent.withNodeName(instance.getNodeName()); fluent.withSource(instance.getSource()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1VolumeAttachmentSpecBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec instance) { - this(instance,false); + + public V1VolumeAttachmentSpecBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec instance) { + this(instance, false); } - public V1VolumeAttachmentSpecBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1VolumeAttachmentSpecBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAttacher(instance.getAttacher()); this.withNodeName(instance.getNodeName()); this.withSource(instance.getSource()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec build() { V1VolumeAttachmentSpec buildable = new V1VolumeAttachmentSpec(); buildable.setAttacher(fluent.getAttacher()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec build() { buildable.setSource(fluent.getSource()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1VolumeAttachmentSpecBuilder that = (V1VolumeAttachmentSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSpecFluent.java index 5bfd81cedb..ca984f05c2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSpecFluent.java @@ -1,53 +1,76 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1VolumeAttachmentSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1VolumeAttachmentSpecFluent< + A extends io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getAttacher(); + public A withAttacher(java.lang.String attacher); + public java.lang.Boolean hasAttacher(); - - /** - * Method is deprecated. use withAttacher instead. - */ + + /** Method is deprecated. use withAttacher instead. */ @java.lang.Deprecated public A withNewAttacher(java.lang.String original); + public java.lang.String getNodeName(); + public A withNodeName(java.lang.String nodeName); + public java.lang.Boolean hasNodeName(); - - /** - * Method is deprecated. use withNodeName instead. - */ + + /** Method is deprecated. use withNodeName instead. */ @java.lang.Deprecated public A withNewNodeName(java.lang.String original); - + /** * This method has been deprecated, please use method buildSource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeAttachmentSource getSource(); + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSource buildSource(); + public A withSource(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource source); + public java.lang.Boolean hasSource(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested withNewSource(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested withNewSourceLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource item); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested editSource(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested editOrNewSource(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested editOrNewSourceLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource item); - public interface SourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent>{ + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested + withNewSource(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested + withNewSourceLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested + editSource(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested + editOrNewSource(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested + editOrNewSourceLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource item); + + public interface SourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested> { public N and(); + public N endSource(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSpecFluentImpl.java index ef8efb4c33..24281c22be 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentSpecFluentImpl.java @@ -1,124 +1,168 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1VolumeAttachmentSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent { + public V1VolumeAttachmentSpecFluentImpl() {} - /** - * Generated - */ -public class V1VolumeAttachmentSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent{ - public V1VolumeAttachmentSpecFluentImpl() { - } - public V1VolumeAttachmentSpecFluentImpl(io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec instance) { + public V1VolumeAttachmentSpecFluentImpl( + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpec instance) { this.withAttacher(instance.getAttacher()); this.withNodeName(instance.getNodeName()); this.withSource(instance.getSource()); - } + private java.lang.String attacher; private java.lang.String nodeName; private io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceBuilder source; + public java.lang.String getAttacher() { return this.attacher; } + public A withAttacher(java.lang.String attacher) { - this.attacher=attacher; return (A) this; + this.attacher = attacher; + return (A) this; } + public java.lang.Boolean hasAttacher() { return this.attacher != null; } - - /** - * Method is deprecated. use withAttacher instead. - */ + + /** Method is deprecated. use withAttacher instead. */ @java.lang.Deprecated public A withNewAttacher(java.lang.String original) { - return (A)withAttacher(new String(original)); + return (A) withAttacher(new String(original)); } + public java.lang.String getNodeName() { return this.nodeName; } + public A withNodeName(java.lang.String nodeName) { - this.nodeName=nodeName; return (A) this; + this.nodeName = nodeName; + return (A) this; } + public java.lang.Boolean hasNodeName() { return this.nodeName != null; } - - /** - * Method is deprecated. use withNodeName instead. - */ + + /** Method is deprecated. use withNodeName instead. */ @java.lang.Deprecated public A withNewNodeName(java.lang.String original) { - return (A)withNodeName(new String(original)); + return (A) withNodeName(new String(original)); } - + /** * This method has been deprecated, please use method buildSource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeAttachmentSource getSource() { - return this.source!=null ?this.source.build():null; + return this.source != null ? this.source.build() : null; } + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSource buildSource() { - return this.source!=null ?this.source.build():null; + return this.source != null ? this.source.build() : null; } + public A withSource(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource source) { _visitables.get("source").remove(this.source); - if (source!=null){ this.source= new io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceBuilder(source); _visitables.get("source").add(this.source);} return (A) this; + if (source != null) { + this.source = new io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceBuilder(source); + _visitables.get("source").add(this.source); + } + return (A) this; } + public java.lang.Boolean hasSource() { return this.source != null; } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested withNewSource() { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluentImpl.SourceNestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested + withNewSource() { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluentImpl + .SourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested withNewSourceLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource item) { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluentImpl.SourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested + withNewSourceLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource item) { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluentImpl + .SourceNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested editSource() { + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested + editSource() { return withNewSourceLike(getSource()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested editOrNewSource() { - return withNewSourceLike(getSource() != null ? getSource(): new io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested + editOrNewSource() { + return withNewSourceLike( + getSource() != null + ? getSource() + : new io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested editOrNewSourceLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource item) { - return withNewSourceLike(getSource() != null ? getSource(): item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested + editOrNewSourceLike(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource item) { + return withNewSourceLike(getSource() != null ? getSource() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1VolumeAttachmentSpecFluentImpl that = (V1VolumeAttachmentSpecFluentImpl) o; - if (attacher != null ? !attacher.equals(that.attacher) :that.attacher != null) return false; - if (nodeName != null ? !nodeName.equals(that.nodeName) :that.nodeName != null) return false; - if (source != null ? !source.equals(that.source) :that.source != null) return false; + if (attacher != null ? !attacher.equals(that.attacher) : that.attacher != null) return false; + if (nodeName != null ? !nodeName.equals(that.nodeName) : that.nodeName != null) return false; + if (source != null ? !source.equals(that.source) : that.source != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(attacher, nodeName, source, super.hashCode()); + return java.util.Objects.hash(attacher, nodeName, source, super.hashCode()); } - public class SourceNestedImpl extends io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested,io.kubernetes.client.fluent.Nested{ + + public class SourceNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested> + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentSpecFluent.SourceNested, + io.kubernetes.client.fluent.Nested { SourceNestedImpl(io.kubernetes.client.openapi.models.V1VolumeAttachmentSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceBuilder(this, item); } + SourceNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeAttachmentSourceBuilder builder; + public N and() { return (N) V1VolumeAttachmentSpecFluentImpl.this.withSource(builder.build()); } + public N endSource() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentStatusBuilder.java index 8853448185..f1e3fd2a6d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1VolumeAttachmentStatusBuilder extends io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1VolumeAttachmentStatusBuilder + extends io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus, + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusBuilder> { public V1VolumeAttachmentStatusBuilder() { this(false); } + public V1VolumeAttachmentStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1VolumeAttachmentStatus(), validationEnabled); } - public V1VolumeAttachmentStatusBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent fluent) { + + public V1VolumeAttachmentStatusBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent fluent) { this(fluent, false); } - public V1VolumeAttachmentStatusBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1VolumeAttachmentStatusBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1VolumeAttachmentStatus(), validationEnabled); } - public V1VolumeAttachmentStatusBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent fluent,io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus instance) { + + public V1VolumeAttachmentStatusBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus instance) { this(fluent, instance, false); } - public V1VolumeAttachmentStatusBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent fluent,io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1VolumeAttachmentStatusBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAttachError(instance.getAttachError()); fluent.withAttached(instance.getAttached()); @@ -29,13 +56,18 @@ public V1VolumeAttachmentStatusBuilder(io.kubernetes.client.openapi.models.V1Vol fluent.withDetachError(instance.getDetachError()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1VolumeAttachmentStatusBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus instance) { - this(instance,false); + + public V1VolumeAttachmentStatusBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus instance) { + this(instance, false); } - public V1VolumeAttachmentStatusBuilder(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1VolumeAttachmentStatusBuilder( + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAttachError(instance.getAttachError()); this.withAttached(instance.getAttached()); @@ -44,10 +76,12 @@ public V1VolumeAttachmentStatusBuilder(io.kubernetes.client.openapi.models.V1Vol this.withDetachError(instance.getDetachError()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus build() { V1VolumeAttachmentStatus buildable = new V1VolumeAttachmentStatus(); buildable.setAttachError(fluent.getAttachError()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus build() { buildable.setDetachError(fluent.getDetachError()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1VolumeAttachmentStatusBuilder that = (V1VolumeAttachmentStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentStatusFluent.java index c9604d1b7d..1a047d73db 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentStatusFluent.java @@ -1,67 +1,118 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1VolumeAttachmentStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1VolumeAttachmentStatusFluent< + A extends io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildAttachError instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeError getAttachError(); + public io.kubernetes.client.openapi.models.V1VolumeError buildAttachError(); + public A withAttachError(io.kubernetes.client.openapi.models.V1VolumeError attachError); + public java.lang.Boolean hasAttachError(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested withNewAttachError(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested withNewAttachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested editAttachError(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested editOrNewAttachError(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested editOrNewAttachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested + withNewAttachError(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested + withNewAttachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested + editAttachError(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested + editOrNewAttachError(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested + editOrNewAttachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item); + public java.lang.Boolean getAttached(); + public A withAttached(java.lang.Boolean attached); + public java.lang.Boolean hasAttached(); - public A addToAttachmentMetadata(java.lang.String key,java.lang.String value); - public A addToAttachmentMetadata(java.util.Map map); + + public A addToAttachmentMetadata(java.lang.String key, java.lang.String value); + + public A addToAttachmentMetadata(java.util.Map map); + public A removeFromAttachmentMetadata(java.lang.String key); - public A removeFromAttachmentMetadata(java.util.Map map); - public java.util.Map getAttachmentMetadata(); - public A withAttachmentMetadata(java.util.Map attachmentMetadata); + + public A removeFromAttachmentMetadata(java.util.Map map); + + public java.util.Map getAttachmentMetadata(); + + public A withAttachmentMetadata( + java.util.Map attachmentMetadata); + public java.lang.Boolean hasAttachmentMetadata(); - + /** * This method has been deprecated, please use method buildDetachError instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeError getDetachError(); + public io.kubernetes.client.openapi.models.V1VolumeError buildDetachError(); + public A withDetachError(io.kubernetes.client.openapi.models.V1VolumeError detachError); + public java.lang.Boolean hasDetachError(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested withNewDetachError(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested withNewDetachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested editDetachError(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested editOrNewDetachError(); - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested editOrNewDetachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item); - public interface AttachErrorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeErrorFluent>{ + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested + withNewDetachError(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested + withNewDetachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested + editDetachError(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested + editOrNewDetachError(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested + editOrNewDetachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item); + + public interface AttachErrorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeErrorFluent< + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested< + N>> { public N and(); + public N endAttachError(); - } - public interface DetachErrorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VolumeErrorFluent>{ + + public interface DetachErrorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VolumeErrorFluent< + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested< + N>> { public N and(); + public N endDetachError(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentStatusFluentImpl.java index 64e48d8ca6..cab25d88ed 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeAttachmentStatusFluentImpl.java @@ -1,21 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.util.LinkedHashMap; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public class V1VolumeAttachmentStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent{ - public V1VolumeAttachmentStatusFluentImpl() { - } - public V1VolumeAttachmentStatusFluentImpl(io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus instance) { +/** Generated */ +public class V1VolumeAttachmentStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent { + public V1VolumeAttachmentStatusFluentImpl() {} + + public V1VolumeAttachmentStatusFluentImpl( + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatus instance) { this.withAttachError(instance.getAttachError()); this.withAttached(instance.getAttached()); @@ -23,158 +28,271 @@ public V1VolumeAttachmentStatusFluentImpl(io.kubernetes.client.openapi.models.V1 this.withAttachmentMetadata(instance.getAttachmentMetadata()); this.withDetachError(instance.getDetachError()); - } + private io.kubernetes.client.openapi.models.V1VolumeErrorBuilder attachError; private java.lang.Boolean attached; - private java.util.Map attachmentMetadata; + private java.util.Map attachmentMetadata; private io.kubernetes.client.openapi.models.V1VolumeErrorBuilder detachError; - + /** * This method has been deprecated, please use method buildAttachError instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeError getAttachError() { - return this.attachError!=null ?this.attachError.build():null; + return this.attachError != null ? this.attachError.build() : null; } + public io.kubernetes.client.openapi.models.V1VolumeError buildAttachError() { - return this.attachError!=null ?this.attachError.build():null; + return this.attachError != null ? this.attachError.build() : null; } + public A withAttachError(io.kubernetes.client.openapi.models.V1VolumeError attachError) { _visitables.get("attachError").remove(this.attachError); - if (attachError!=null){ this.attachError= new io.kubernetes.client.openapi.models.V1VolumeErrorBuilder(attachError); _visitables.get("attachError").add(this.attachError);} return (A) this; + if (attachError != null) { + this.attachError = new io.kubernetes.client.openapi.models.V1VolumeErrorBuilder(attachError); + _visitables.get("attachError").add(this.attachError); + } + return (A) this; } + public java.lang.Boolean hasAttachError() { return this.attachError != null; } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested withNewAttachError() { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluentImpl.AttachErrorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested + withNewAttachError() { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluentImpl + .AttachErrorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested withNewAttachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item) { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluentImpl.AttachErrorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested + withNewAttachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item) { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluentImpl + .AttachErrorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested editAttachError() { + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested + editAttachError() { return withNewAttachErrorLike(getAttachError()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested editOrNewAttachError() { - return withNewAttachErrorLike(getAttachError() != null ? getAttachError(): new io.kubernetes.client.openapi.models.V1VolumeErrorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested + editOrNewAttachError() { + return withNewAttachErrorLike( + getAttachError() != null + ? getAttachError() + : new io.kubernetes.client.openapi.models.V1VolumeErrorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested editOrNewAttachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item) { - return withNewAttachErrorLike(getAttachError() != null ? getAttachError(): item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested + editOrNewAttachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item) { + return withNewAttachErrorLike(getAttachError() != null ? getAttachError() : item); } + public java.lang.Boolean getAttached() { return this.attached; } + public A withAttached(java.lang.Boolean attached) { - this.attached=attached; return (A) this; + this.attached = attached; + return (A) this; } + public java.lang.Boolean hasAttached() { return this.attached != null; } - public A addToAttachmentMetadata(java.lang.String key,java.lang.String value) { - if(this.attachmentMetadata == null && key != null && value != null) { this.attachmentMetadata = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.attachmentMetadata.put(key, value);} return (A)this; + + public A addToAttachmentMetadata(java.lang.String key, java.lang.String value) { + if (this.attachmentMetadata == null && key != null && value != null) { + this.attachmentMetadata = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.attachmentMetadata.put(key, value); + } + return (A) this; } - public A addToAttachmentMetadata(java.util.Map map) { - if(this.attachmentMetadata == null && map != null) { this.attachmentMetadata = new java.util.LinkedHashMap(); } - if(map != null) { this.attachmentMetadata.putAll(map);} return (A)this; + + public A addToAttachmentMetadata(java.util.Map map) { + if (this.attachmentMetadata == null && map != null) { + this.attachmentMetadata = new java.util.LinkedHashMap(); + } + if (map != null) { + this.attachmentMetadata.putAll(map); + } + return (A) this; } + public A removeFromAttachmentMetadata(java.lang.String key) { - if(this.attachmentMetadata == null) { return (A) this; } - if(key != null && this.attachmentMetadata != null) {this.attachmentMetadata.remove(key);} return (A)this; + if (this.attachmentMetadata == null) { + return (A) this; + } + if (key != null && this.attachmentMetadata != null) { + this.attachmentMetadata.remove(key); + } + return (A) this; } - public A removeFromAttachmentMetadata(java.util.Map map) { - if(this.attachmentMetadata == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.attachmentMetadata != null){this.attachmentMetadata.remove(key);}}} return (A)this; + + public A removeFromAttachmentMetadata(java.util.Map map) { + if (this.attachmentMetadata == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.attachmentMetadata != null) { + this.attachmentMetadata.remove(key); + } + } + } + return (A) this; } - public java.util.Map getAttachmentMetadata() { + + public java.util.Map getAttachmentMetadata() { return this.attachmentMetadata; } - public A withAttachmentMetadata(java.util.Map attachmentMetadata) { - if (attachmentMetadata == null) { this.attachmentMetadata = null;} else {this.attachmentMetadata = new java.util.LinkedHashMap(attachmentMetadata);} return (A) this; + + public A withAttachmentMetadata( + java.util.Map attachmentMetadata) { + if (attachmentMetadata == null) { + this.attachmentMetadata = null; + } else { + this.attachmentMetadata = new java.util.LinkedHashMap(attachmentMetadata); + } + return (A) this; } + public java.lang.Boolean hasAttachmentMetadata() { return this.attachmentMetadata != null; } - + /** * This method has been deprecated, please use method buildDetachError instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VolumeError getDetachError() { - return this.detachError!=null ?this.detachError.build():null; + return this.detachError != null ? this.detachError.build() : null; } + public io.kubernetes.client.openapi.models.V1VolumeError buildDetachError() { - return this.detachError!=null ?this.detachError.build():null; + return this.detachError != null ? this.detachError.build() : null; } + public A withDetachError(io.kubernetes.client.openapi.models.V1VolumeError detachError) { _visitables.get("detachError").remove(this.detachError); - if (detachError!=null){ this.detachError= new io.kubernetes.client.openapi.models.V1VolumeErrorBuilder(detachError); _visitables.get("detachError").add(this.detachError);} return (A) this; + if (detachError != null) { + this.detachError = new io.kubernetes.client.openapi.models.V1VolumeErrorBuilder(detachError); + _visitables.get("detachError").add(this.detachError); + } + return (A) this; } + public java.lang.Boolean hasDetachError() { return this.detachError != null; } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested withNewDetachError() { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluentImpl.DetachErrorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested + withNewDetachError() { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluentImpl + .DetachErrorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested withNewDetachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item) { - return new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluentImpl.DetachErrorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested + withNewDetachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item) { + return new io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluentImpl + .DetachErrorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested editDetachError() { + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested + editDetachError() { return withNewDetachErrorLike(getDetachError()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested editOrNewDetachError() { - return withNewDetachErrorLike(getDetachError() != null ? getDetachError(): new io.kubernetes.client.openapi.models.V1VolumeErrorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested + editOrNewDetachError() { + return withNewDetachErrorLike( + getDetachError() != null + ? getDetachError() + : new io.kubernetes.client.openapi.models.V1VolumeErrorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested editOrNewDetachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item) { - return withNewDetachErrorLike(getDetachError() != null ? getDetachError(): item); + + public io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested + editOrNewDetachErrorLike(io.kubernetes.client.openapi.models.V1VolumeError item) { + return withNewDetachErrorLike(getDetachError() != null ? getDetachError() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1VolumeAttachmentStatusFluentImpl that = (V1VolumeAttachmentStatusFluentImpl) o; - if (attachError != null ? !attachError.equals(that.attachError) :that.attachError != null) return false; - if (attached != null ? !attached.equals(that.attached) :that.attached != null) return false; - if (attachmentMetadata != null ? !attachmentMetadata.equals(that.attachmentMetadata) :that.attachmentMetadata != null) return false; - if (detachError != null ? !detachError.equals(that.detachError) :that.detachError != null) return false; + if (attachError != null ? !attachError.equals(that.attachError) : that.attachError != null) + return false; + if (attached != null ? !attached.equals(that.attached) : that.attached != null) return false; + if (attachmentMetadata != null + ? !attachmentMetadata.equals(that.attachmentMetadata) + : that.attachmentMetadata != null) return false; + if (detachError != null ? !detachError.equals(that.detachError) : that.detachError != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(attachError, attached, attachmentMetadata, detachError, super.hashCode()); + return java.util.Objects.hash( + attachError, attached, attachmentMetadata, detachError, super.hashCode()); } - public class AttachErrorNestedImpl extends io.kubernetes.client.openapi.models.V1VolumeErrorFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested,io.kubernetes.client.fluent.Nested{ + + public class AttachErrorNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeErrorFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.AttachErrorNested> + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent + .AttachErrorNested< + N>, + io.kubernetes.client.fluent.Nested { AttachErrorNestedImpl(io.kubernetes.client.openapi.models.V1VolumeError item) { this.builder = new io.kubernetes.client.openapi.models.V1VolumeErrorBuilder(this, item); } + AttachErrorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1VolumeErrorBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeErrorBuilder builder; + public N and() { return (N) V1VolumeAttachmentStatusFluentImpl.this.withAttachError(builder.build()); } + public N endAttachError() { return and(); } - } - public class DetachErrorNestedImpl extends io.kubernetes.client.openapi.models.V1VolumeErrorFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested,io.kubernetes.client.fluent.Nested{ + + public class DetachErrorNestedImpl + extends io.kubernetes.client.openapi.models.V1VolumeErrorFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent.DetachErrorNested> + implements io.kubernetes.client.openapi.models.V1VolumeAttachmentStatusFluent + .DetachErrorNested< + N>, + io.kubernetes.client.fluent.Nested { DetachErrorNestedImpl(io.kubernetes.client.openapi.models.V1VolumeError item) { this.builder = new io.kubernetes.client.openapi.models.V1VolumeErrorBuilder(this, item); } + DetachErrorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1VolumeErrorBuilder(this); } + io.kubernetes.client.openapi.models.V1VolumeErrorBuilder builder; + public N and() { return (N) V1VolumeAttachmentStatusFluentImpl.this.withDetachError(builder.build()); } + public N endDetachError() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeBuilder.java index 3dc62cce99..73e78381e7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1VolumeBuilder extends io.kubernetes.client.openapi.models.V1VolumeFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1VolumeBuilder + extends io.kubernetes.client.openapi.models.V1VolumeFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1Volume, + io.kubernetes.client.openapi.models.V1VolumeBuilder> { public V1VolumeBuilder() { this(false); } + public V1VolumeBuilder(java.lang.Boolean validationEnabled) { this(new V1Volume(), validationEnabled); } + public V1VolumeBuilder(io.kubernetes.client.openapi.models.V1VolumeFluent fluent) { this(fluent, false); } - public V1VolumeBuilder(io.kubernetes.client.openapi.models.V1VolumeFluent fluent,java.lang.Boolean validationEnabled) { + + public V1VolumeBuilder( + io.kubernetes.client.openapi.models.V1VolumeFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1Volume(), validationEnabled); } - public V1VolumeBuilder(io.kubernetes.client.openapi.models.V1VolumeFluent fluent,io.kubernetes.client.openapi.models.V1Volume instance) { + + public V1VolumeBuilder( + io.kubernetes.client.openapi.models.V1VolumeFluent fluent, + io.kubernetes.client.openapi.models.V1Volume instance) { this(fluent, instance, false); } - public V1VolumeBuilder(io.kubernetes.client.openapi.models.V1VolumeFluent fluent,io.kubernetes.client.openapi.models.V1Volume instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1VolumeBuilder( + io.kubernetes.client.openapi.models.V1VolumeFluent fluent, + io.kubernetes.client.openapi.models.V1Volume instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAwsElasticBlockStore(instance.getAwsElasticBlockStore()); fluent.withAzureDisk(instance.getAzureDisk()); @@ -81,13 +107,16 @@ public V1VolumeBuilder(io.kubernetes.client.openapi.models.V1VolumeFluent flu fluent.withVsphereVolume(instance.getVsphereVolume()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1VolumeBuilder(io.kubernetes.client.openapi.models.V1Volume instance) { - this(instance,false); + this(instance, false); } - public V1VolumeBuilder(io.kubernetes.client.openapi.models.V1Volume instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1VolumeBuilder( + io.kubernetes.client.openapi.models.V1Volume instance, java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAwsElasticBlockStore(instance.getAwsElasticBlockStore()); this.withAzureDisk(instance.getAzureDisk()); @@ -148,10 +177,12 @@ public V1VolumeBuilder(io.kubernetes.client.openapi.models.V1Volume instance,jav this.withVsphereVolume(instance.getVsphereVolume()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1VolumeFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1Volume build() { V1Volume buildable = new V1Volume(); buildable.setAwsElasticBlockStore(fluent.getAwsElasticBlockStore()); @@ -186,18 +217,23 @@ public io.kubernetes.client.openapi.models.V1Volume build() { buildable.setVsphereVolume(fluent.getVsphereVolume()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1VolumeBuilder that = (V1VolumeBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeDeviceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeDeviceBuilder.java index b2534b34c0..ed1d318ad0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeDeviceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeDeviceBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1VolumeDeviceBuilder extends io.kubernetes.client.openapi.models.V1VolumeDeviceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1VolumeDeviceBuilder + extends io.kubernetes.client.openapi.models.V1VolumeDeviceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1VolumeDevice, + io.kubernetes.client.openapi.models.V1VolumeDeviceBuilder> { public V1VolumeDeviceBuilder() { this(false); } + public V1VolumeDeviceBuilder(java.lang.Boolean validationEnabled) { this(new V1VolumeDevice(), validationEnabled); } + public V1VolumeDeviceBuilder(io.kubernetes.client.openapi.models.V1VolumeDeviceFluent fluent) { this(fluent, false); } - public V1VolumeDeviceBuilder(io.kubernetes.client.openapi.models.V1VolumeDeviceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1VolumeDeviceBuilder( + io.kubernetes.client.openapi.models.V1VolumeDeviceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1VolumeDevice(), validationEnabled); } - public V1VolumeDeviceBuilder(io.kubernetes.client.openapi.models.V1VolumeDeviceFluent fluent,io.kubernetes.client.openapi.models.V1VolumeDevice instance) { + + public V1VolumeDeviceBuilder( + io.kubernetes.client.openapi.models.V1VolumeDeviceFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeDevice instance) { this(fluent, instance, false); } - public V1VolumeDeviceBuilder(io.kubernetes.client.openapi.models.V1VolumeDeviceFluent fluent,io.kubernetes.client.openapi.models.V1VolumeDevice instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1VolumeDeviceBuilder( + io.kubernetes.client.openapi.models.V1VolumeDeviceFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeDevice instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDevicePath(instance.getDevicePath()); fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1VolumeDeviceBuilder(io.kubernetes.client.openapi.models.V1VolumeDevice instance) { - this(instance,false); + this(instance, false); } - public V1VolumeDeviceBuilder(io.kubernetes.client.openapi.models.V1VolumeDevice instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1VolumeDeviceBuilder( + io.kubernetes.client.openapi.models.V1VolumeDevice instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDevicePath(instance.getDevicePath()); this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1VolumeDeviceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1VolumeDevice build() { V1VolumeDevice buildable = new V1VolumeDevice(); buildable.setDevicePath(fluent.getDevicePath()); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1VolumeDeviceBuilder that = (V1VolumeDeviceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeDeviceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeDeviceFluent.java index a2e2532dad..12731cc6e8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeDeviceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeDeviceFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1VolumeDeviceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1VolumeDeviceFluent< + A extends io.kubernetes.client.openapi.models.V1VolumeDeviceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getDevicePath(); + public A withDevicePath(java.lang.String devicePath); + public java.lang.Boolean hasDevicePath(); - - /** - * Method is deprecated. use withDevicePath instead. - */ + + /** Method is deprecated. use withDevicePath instead. */ @java.lang.Deprecated public A withNewDevicePath(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeDeviceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeDeviceFluentImpl.java index 61bd723b84..128181828d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeDeviceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeDeviceFluentImpl.java @@ -1,69 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1VolumeDeviceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1VolumeDeviceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1VolumeDeviceFluent { + public V1VolumeDeviceFluentImpl() {} - /** - * Generated - */ -public class V1VolumeDeviceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1VolumeDeviceFluent{ - public V1VolumeDeviceFluentImpl() { - } public V1VolumeDeviceFluentImpl(io.kubernetes.client.openapi.models.V1VolumeDevice instance) { this.withDevicePath(instance.getDevicePath()); this.withName(instance.getName()); - } + private java.lang.String devicePath; private java.lang.String name; + public java.lang.String getDevicePath() { return this.devicePath; } + public A withDevicePath(java.lang.String devicePath) { - this.devicePath=devicePath; return (A) this; + this.devicePath = devicePath; + return (A) this; } + public java.lang.Boolean hasDevicePath() { return this.devicePath != null; } - - /** - * Method is deprecated. use withDevicePath instead. - */ + + /** Method is deprecated. use withDevicePath instead. */ @java.lang.Deprecated public A withNewDevicePath(java.lang.String original) { - return (A)withDevicePath(new String(original)); + return (A) withDevicePath(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1VolumeDeviceFluentImpl that = (V1VolumeDeviceFluentImpl) o; - if (devicePath != null ? !devicePath.equals(that.devicePath) :that.devicePath != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (devicePath != null ? !devicePath.equals(that.devicePath) : that.devicePath != null) + return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(devicePath, name, super.hashCode()); + return java.util.Objects.hash(devicePath, name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeErrorBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeErrorBuilder.java index aa42a8a81a..e1b88f3d3a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeErrorBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeErrorBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1VolumeErrorBuilder extends io.kubernetes.client.openapi.models.V1VolumeErrorFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1VolumeErrorBuilder + extends io.kubernetes.client.openapi.models.V1VolumeErrorFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeErrorBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1VolumeError, + io.kubernetes.client.openapi.models.V1VolumeErrorBuilder> { public V1VolumeErrorBuilder() { this(false); } + public V1VolumeErrorBuilder(java.lang.Boolean validationEnabled) { this(new V1VolumeError(), validationEnabled); } + public V1VolumeErrorBuilder(io.kubernetes.client.openapi.models.V1VolumeErrorFluent fluent) { this(fluent, false); } - public V1VolumeErrorBuilder(io.kubernetes.client.openapi.models.V1VolumeErrorFluent fluent,java.lang.Boolean validationEnabled) { + + public V1VolumeErrorBuilder( + io.kubernetes.client.openapi.models.V1VolumeErrorFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1VolumeError(), validationEnabled); } - public V1VolumeErrorBuilder(io.kubernetes.client.openapi.models.V1VolumeErrorFluent fluent,io.kubernetes.client.openapi.models.V1VolumeError instance) { + + public V1VolumeErrorBuilder( + io.kubernetes.client.openapi.models.V1VolumeErrorFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeError instance) { this(fluent, instance, false); } - public V1VolumeErrorBuilder(io.kubernetes.client.openapi.models.V1VolumeErrorFluent fluent,io.kubernetes.client.openapi.models.V1VolumeError instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1VolumeErrorBuilder( + io.kubernetes.client.openapi.models.V1VolumeErrorFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeError instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMessage(instance.getMessage()); fluent.withTime(instance.getTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1VolumeErrorBuilder(io.kubernetes.client.openapi.models.V1VolumeError instance) { - this(instance,false); + this(instance, false); } - public V1VolumeErrorBuilder(io.kubernetes.client.openapi.models.V1VolumeError instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1VolumeErrorBuilder( + io.kubernetes.client.openapi.models.V1VolumeError instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMessage(instance.getMessage()); this.withTime(instance.getTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1VolumeErrorFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1VolumeError build() { V1VolumeError buildable = new V1VolumeError(); buildable.setMessage(fluent.getMessage()); buildable.setTime(fluent.getTime()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1VolumeErrorBuilder that = (V1VolumeErrorBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeErrorFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeErrorFluent.java index 7029c72f28..af1514e1de 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeErrorFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeErrorFluent.java @@ -1,27 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1VolumeErrorFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1VolumeErrorFluent< + A extends io.kubernetes.client.openapi.models.V1VolumeErrorFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.time.OffsetDateTime getTime(); + public A withTime(java.time.OffsetDateTime time); + public java.lang.Boolean hasTime(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeErrorFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeErrorFluentImpl.java index 4c20858726..5f5302c5e0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeErrorFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeErrorFluentImpl.java @@ -1,62 +1,75 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1VolumeErrorFluentImpl< + A extends io.kubernetes.client.openapi.models.V1VolumeErrorFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1VolumeErrorFluent { + public V1VolumeErrorFluentImpl() {} - /** - * Generated - */ -public class V1VolumeErrorFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1VolumeErrorFluent{ - public V1VolumeErrorFluentImpl() { - } public V1VolumeErrorFluentImpl(io.kubernetes.client.openapi.models.V1VolumeError instance) { this.withMessage(instance.getMessage()); this.withTime(instance.getTime()); - } + private java.lang.String message; private java.time.OffsetDateTime time; + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.time.OffsetDateTime getTime() { return this.time; } + public A withTime(java.time.OffsetDateTime time) { - this.time=time; return (A) this; + this.time = time; + return (A) this; } + public java.lang.Boolean hasTime() { return this.time != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1VolumeErrorFluentImpl that = (V1VolumeErrorFluentImpl) o; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (time != null ? !time.equals(that.time) :that.time != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (time != null ? !time.equals(that.time) : that.time != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(message, time, super.hashCode()); + return java.util.Objects.hash(message, time, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeFluent.java index 379ab009e0..e1afab1e64 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeFluent.java @@ -1,604 +1,1089 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import java.lang.String; -import java.lang.Boolean; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; - - /** - * Generated - */ -public interface V1VolumeFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1VolumeFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildAwsElasticBlockStore instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource getAwsElasticBlockStore(); - public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource buildAwsElasticBlockStore(); - public A withAwsElasticBlockStore(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource awsElasticBlockStore); + public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource + getAwsElasticBlockStore(); + + public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource + buildAwsElasticBlockStore(); + + public A withAwsElasticBlockStore( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource awsElasticBlockStore); + public java.lang.Boolean hasAwsElasticBlockStore(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested withNewAwsElasticBlockStore(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested withNewAwsElasticBlockStoreLike(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item); - public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested editAwsElasticBlockStore(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested editOrNewAwsElasticBlockStore(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested editOrNewAwsElasticBlockStoreLike(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested + withNewAwsElasticBlockStore(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested + withNewAwsElasticBlockStoreLike( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested + editAwsElasticBlockStore(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested + editOrNewAwsElasticBlockStore(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested + editOrNewAwsElasticBlockStoreLike( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item); + /** * This method has been deprecated, please use method buildAzureDisk instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource getAzureDisk(); + public io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource buildAzureDisk(); + public A withAzureDisk(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource azureDisk); + public java.lang.Boolean hasAzureDisk(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested withNewAzureDisk(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested withNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested withNewAzureDiskLike( + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested editAzureDisk(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested editOrNewAzureDisk(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested editOrNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested + editOrNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item); + /** * This method has been deprecated, please use method buildAzureFile instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1AzureFileVolumeSource getAzureFile(); + public io.kubernetes.client.openapi.models.V1AzureFileVolumeSource buildAzureFile(); + public A withAzureFile(io.kubernetes.client.openapi.models.V1AzureFileVolumeSource azureFile); + public java.lang.Boolean hasAzureFile(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested withNewAzureFile(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested withNewAzureFileLike(io.kubernetes.client.openapi.models.V1AzureFileVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested withNewAzureFileLike( + io.kubernetes.client.openapi.models.V1AzureFileVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested editAzureFile(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested editOrNewAzureFile(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested editOrNewAzureFileLike(io.kubernetes.client.openapi.models.V1AzureFileVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested + editOrNewAzureFileLike(io.kubernetes.client.openapi.models.V1AzureFileVolumeSource item); + /** * This method has been deprecated, please use method buildCephfs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CephFSVolumeSource getCephfs(); + public io.kubernetes.client.openapi.models.V1CephFSVolumeSource buildCephfs(); + public A withCephfs(io.kubernetes.client.openapi.models.V1CephFSVolumeSource cephfs); + public java.lang.Boolean hasCephfs(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested withNewCephfs(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested withNewCephfsLike(io.kubernetes.client.openapi.models.V1CephFSVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested withNewCephfsLike( + io.kubernetes.client.openapi.models.V1CephFSVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested editCephfs(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested editOrNewCephfs(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested editOrNewCephfsLike(io.kubernetes.client.openapi.models.V1CephFSVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested editOrNewCephfsLike( + io.kubernetes.client.openapi.models.V1CephFSVolumeSource item); + /** * This method has been deprecated, please use method buildCinder instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CinderVolumeSource getCinder(); + public io.kubernetes.client.openapi.models.V1CinderVolumeSource buildCinder(); + public A withCinder(io.kubernetes.client.openapi.models.V1CinderVolumeSource cinder); + public java.lang.Boolean hasCinder(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested withNewCinder(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested withNewCinderLike(io.kubernetes.client.openapi.models.V1CinderVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested withNewCinderLike( + io.kubernetes.client.openapi.models.V1CinderVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested editCinder(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested editOrNewCinder(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested editOrNewCinderLike(io.kubernetes.client.openapi.models.V1CinderVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested editOrNewCinderLike( + io.kubernetes.client.openapi.models.V1CinderVolumeSource item); + /** * This method has been deprecated, please use method buildConfigMap instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource getConfigMap(); + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource buildConfigMap(); + public A withConfigMap(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource configMap); + public java.lang.Boolean hasConfigMap(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested withNewConfigMap(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested withNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested withNewConfigMapLike( + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested editConfigMap(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested editOrNewConfigMap(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested editOrNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested + editOrNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource item); + /** * This method has been deprecated, please use method buildCsi instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CSIVolumeSource getCsi(); + public io.kubernetes.client.openapi.models.V1CSIVolumeSource buildCsi(); + public A withCsi(io.kubernetes.client.openapi.models.V1CSIVolumeSource csi); + public java.lang.Boolean hasCsi(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested withNewCsi(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested withNewCsiLike(io.kubernetes.client.openapi.models.V1CSIVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested withNewCsiLike( + io.kubernetes.client.openapi.models.V1CSIVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested editCsi(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested editOrNewCsi(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested editOrNewCsiLike(io.kubernetes.client.openapi.models.V1CSIVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested editOrNewCsiLike( + io.kubernetes.client.openapi.models.V1CSIVolumeSource item); + /** * This method has been deprecated, please use method buildDownwardAPI instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource getDownwardAPI(); + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource buildDownwardAPI(); - public A withDownwardAPI(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource downwardAPI); + + public A withDownwardAPI( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource downwardAPI); + public java.lang.Boolean hasDownwardAPI(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested withNewDownwardAPI(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested withNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested + withNewDownwardAPI(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested + withNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested editDownwardAPI(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested editOrNewDownwardAPI(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested editOrNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested + editOrNewDownwardAPI(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested + editOrNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource item); + /** * This method has been deprecated, please use method buildEmptyDir instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource getEmptyDir(); + public io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource buildEmptyDir(); + public A withEmptyDir(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource emptyDir); + public java.lang.Boolean hasEmptyDir(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested withNewEmptyDir(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested withNewEmptyDirLike(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested withNewEmptyDirLike( + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested editEmptyDir(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested editOrNewEmptyDir(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested editOrNewEmptyDirLike(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested editOrNewEmptyDirLike( + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource item); + /** * This method has been deprecated, please use method buildEphemeral instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EphemeralVolumeSource getEphemeral(); + public io.kubernetes.client.openapi.models.V1EphemeralVolumeSource buildEphemeral(); + public A withEphemeral(io.kubernetes.client.openapi.models.V1EphemeralVolumeSource ephemeral); + public java.lang.Boolean hasEphemeral(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested withNewEphemeral(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested withNewEphemeralLike(io.kubernetes.client.openapi.models.V1EphemeralVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested withNewEphemeralLike( + io.kubernetes.client.openapi.models.V1EphemeralVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested editEphemeral(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested editOrNewEphemeral(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested editOrNewEphemeralLike(io.kubernetes.client.openapi.models.V1EphemeralVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested + editOrNewEphemeralLike(io.kubernetes.client.openapi.models.V1EphemeralVolumeSource item); + /** * This method has been deprecated, please use method buildFc instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1FCVolumeSource getFc(); + public io.kubernetes.client.openapi.models.V1FCVolumeSource buildFc(); + public A withFc(io.kubernetes.client.openapi.models.V1FCVolumeSource fc); + public java.lang.Boolean hasFc(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested withNewFc(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested withNewFcLike(io.kubernetes.client.openapi.models.V1FCVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested withNewFcLike( + io.kubernetes.client.openapi.models.V1FCVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested editFc(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested editOrNewFc(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested editOrNewFcLike(io.kubernetes.client.openapi.models.V1FCVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested editOrNewFcLike( + io.kubernetes.client.openapi.models.V1FCVolumeSource item); + /** * This method has been deprecated, please use method buildFlexVolume instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1FlexVolumeSource getFlexVolume(); + public io.kubernetes.client.openapi.models.V1FlexVolumeSource buildFlexVolume(); + public A withFlexVolume(io.kubernetes.client.openapi.models.V1FlexVolumeSource flexVolume); + public java.lang.Boolean hasFlexVolume(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested withNewFlexVolume(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested withNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested + withNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested editFlexVolume(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested editOrNewFlexVolume(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested editOrNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested + editOrNewFlexVolume(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested + editOrNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexVolumeSource item); + /** * This method has been deprecated, please use method buildFlocker instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1FlockerVolumeSource getFlocker(); + public io.kubernetes.client.openapi.models.V1FlockerVolumeSource buildFlocker(); + public A withFlocker(io.kubernetes.client.openapi.models.V1FlockerVolumeSource flocker); + public java.lang.Boolean hasFlocker(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested withNewFlocker(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested withNewFlockerLike(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested withNewFlockerLike( + io.kubernetes.client.openapi.models.V1FlockerVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested editFlocker(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested editOrNewFlocker(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested editOrNewFlockerLike(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested editOrNewFlockerLike( + io.kubernetes.client.openapi.models.V1FlockerVolumeSource item); + /** * This method has been deprecated, please use method buildGcePersistentDisk instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource getGcePersistentDisk(); - public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource buildGcePersistentDisk(); - public A withGcePersistentDisk(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource gcePersistentDisk); + + public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource + buildGcePersistentDisk(); + + public A withGcePersistentDisk( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource gcePersistentDisk); + public java.lang.Boolean hasGcePersistentDisk(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested withNewGcePersistentDisk(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested withNewGcePersistentDiskLike(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item); - public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested editGcePersistentDisk(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested editOrNewGcePersistentDisk(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested editOrNewGcePersistentDiskLike(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested + withNewGcePersistentDisk(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested + withNewGcePersistentDiskLike( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested + editGcePersistentDisk(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested + editOrNewGcePersistentDisk(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested + editOrNewGcePersistentDiskLike( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item); + /** * This method has been deprecated, please use method buildGitRepo instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1GitRepoVolumeSource getGitRepo(); + public io.kubernetes.client.openapi.models.V1GitRepoVolumeSource buildGitRepo(); + public A withGitRepo(io.kubernetes.client.openapi.models.V1GitRepoVolumeSource gitRepo); + public java.lang.Boolean hasGitRepo(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested withNewGitRepo(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested withNewGitRepoLike(io.kubernetes.client.openapi.models.V1GitRepoVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested withNewGitRepoLike( + io.kubernetes.client.openapi.models.V1GitRepoVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested editGitRepo(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested editOrNewGitRepo(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested editOrNewGitRepoLike(io.kubernetes.client.openapi.models.V1GitRepoVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested editOrNewGitRepoLike( + io.kubernetes.client.openapi.models.V1GitRepoVolumeSource item); + /** * This method has been deprecated, please use method buildGlusterfs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource getGlusterfs(); + public io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource buildGlusterfs(); + public A withGlusterfs(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource glusterfs); + public java.lang.Boolean hasGlusterfs(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested withNewGlusterfs(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested withNewGlusterfsLike(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested withNewGlusterfsLike( + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested editGlusterfs(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested editOrNewGlusterfs(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested editOrNewGlusterfsLike(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested + editOrNewGlusterfsLike(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource item); + /** * This method has been deprecated, please use method buildHostPath instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HostPathVolumeSource getHostPath(); + public io.kubernetes.client.openapi.models.V1HostPathVolumeSource buildHostPath(); + public A withHostPath(io.kubernetes.client.openapi.models.V1HostPathVolumeSource hostPath); + public java.lang.Boolean hasHostPath(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested withNewHostPath(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested withNewHostPathLike(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested withNewHostPathLike( + io.kubernetes.client.openapi.models.V1HostPathVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested editHostPath(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested editOrNewHostPath(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested editOrNewHostPathLike(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested editOrNewHostPathLike( + io.kubernetes.client.openapi.models.V1HostPathVolumeSource item); + /** * This method has been deprecated, please use method buildIscsi instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ISCSIVolumeSource getIscsi(); + public io.kubernetes.client.openapi.models.V1ISCSIVolumeSource buildIscsi(); + public A withIscsi(io.kubernetes.client.openapi.models.V1ISCSIVolumeSource iscsi); + public java.lang.Boolean hasIscsi(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested withNewIscsi(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested withNewIscsiLike(io.kubernetes.client.openapi.models.V1ISCSIVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested withNewIscsiLike( + io.kubernetes.client.openapi.models.V1ISCSIVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested editIscsi(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested editOrNewIscsi(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested editOrNewIscsiLike(io.kubernetes.client.openapi.models.V1ISCSIVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested editOrNewIscsiLike( + io.kubernetes.client.openapi.models.V1ISCSIVolumeSource item); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - + /** * This method has been deprecated, please use method buildNfs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NFSVolumeSource getNfs(); + public io.kubernetes.client.openapi.models.V1NFSVolumeSource buildNfs(); + public A withNfs(io.kubernetes.client.openapi.models.V1NFSVolumeSource nfs); + public java.lang.Boolean hasNfs(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested withNewNfs(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested withNewNfsLike(io.kubernetes.client.openapi.models.V1NFSVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested withNewNfsLike( + io.kubernetes.client.openapi.models.V1NFSVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested editNfs(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested editOrNewNfs(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested editOrNewNfsLike(io.kubernetes.client.openapi.models.V1NFSVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested editOrNewNfsLike( + io.kubernetes.client.openapi.models.V1NFSVolumeSource item); + /** * This method has been deprecated, please use method buildPersistentVolumeClaim instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource getPersistentVolumeClaim(); - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource buildPersistentVolumeClaim(); - public A withPersistentVolumeClaim(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource persistentVolumeClaim); + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource + getPersistentVolumeClaim(); + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource + buildPersistentVolumeClaim(); + + public A withPersistentVolumeClaim( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource + persistentVolumeClaim); + public java.lang.Boolean hasPersistentVolumeClaim(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested withNewPersistentVolumeClaim(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested withNewPersistentVolumeClaimLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource item); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested editPersistentVolumeClaim(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested editOrNewPersistentVolumeClaim(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested editOrNewPersistentVolumeClaimLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested + withNewPersistentVolumeClaim(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested + withNewPersistentVolumeClaimLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested + editPersistentVolumeClaim(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested + editOrNewPersistentVolumeClaim(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested + editOrNewPersistentVolumeClaimLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource item); + /** * This method has been deprecated, please use method buildPhotonPersistentDisk instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource getPhotonPersistentDisk(); - public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource buildPhotonPersistentDisk(); - public A withPhotonPersistentDisk(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource photonPersistentDisk); + public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource + getPhotonPersistentDisk(); + + public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource + buildPhotonPersistentDisk(); + + public A withPhotonPersistentDisk( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource photonPersistentDisk); + public java.lang.Boolean hasPhotonPersistentDisk(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested withNewPhotonPersistentDisk(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested withNewPhotonPersistentDiskLike(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested editPhotonPersistentDisk(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested editOrNewPhotonPersistentDisk(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested editOrNewPhotonPersistentDiskLike(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested + withNewPhotonPersistentDisk(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested + withNewPhotonPersistentDiskLike( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested + editPhotonPersistentDisk(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested + editOrNewPhotonPersistentDisk(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested + editOrNewPhotonPersistentDiskLike( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item); + /** * This method has been deprecated, please use method buildPortworxVolume instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PortworxVolumeSource getPortworxVolume(); + public io.kubernetes.client.openapi.models.V1PortworxVolumeSource buildPortworxVolume(); - public A withPortworxVolume(io.kubernetes.client.openapi.models.V1PortworxVolumeSource portworxVolume); + + public A withPortworxVolume( + io.kubernetes.client.openapi.models.V1PortworxVolumeSource portworxVolume); + public java.lang.Boolean hasPortworxVolume(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested withNewPortworxVolume(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested withNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested editPortworxVolume(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested editOrNewPortworxVolume(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested editOrNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested + withNewPortworxVolume(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested + withNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested + editPortworxVolume(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested + editOrNewPortworxVolume(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested + editOrNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item); + /** * This method has been deprecated, please use method buildProjected instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ProjectedVolumeSource getProjected(); + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSource buildProjected(); + public A withProjected(io.kubernetes.client.openapi.models.V1ProjectedVolumeSource projected); + public java.lang.Boolean hasProjected(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested withNewProjected(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested withNewProjectedLike(io.kubernetes.client.openapi.models.V1ProjectedVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested withNewProjectedLike( + io.kubernetes.client.openapi.models.V1ProjectedVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested editProjected(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested editOrNewProjected(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested editOrNewProjectedLike(io.kubernetes.client.openapi.models.V1ProjectedVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested + editOrNewProjectedLike(io.kubernetes.client.openapi.models.V1ProjectedVolumeSource item); + /** * This method has been deprecated, please use method buildQuobyte instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1QuobyteVolumeSource getQuobyte(); + public io.kubernetes.client.openapi.models.V1QuobyteVolumeSource buildQuobyte(); + public A withQuobyte(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource quobyte); + public java.lang.Boolean hasQuobyte(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested withNewQuobyte(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested withNewQuobyteLike(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested withNewQuobyteLike( + io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested editQuobyte(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested editOrNewQuobyte(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested editOrNewQuobyteLike(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested editOrNewQuobyteLike( + io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item); + /** * This method has been deprecated, please use method buildRbd instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RBDVolumeSource getRbd(); + public io.kubernetes.client.openapi.models.V1RBDVolumeSource buildRbd(); + public A withRbd(io.kubernetes.client.openapi.models.V1RBDVolumeSource rbd); + public java.lang.Boolean hasRbd(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested withNewRbd(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested withNewRbdLike(io.kubernetes.client.openapi.models.V1RBDVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested withNewRbdLike( + io.kubernetes.client.openapi.models.V1RBDVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested editRbd(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested editOrNewRbd(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested editOrNewRbdLike(io.kubernetes.client.openapi.models.V1RBDVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested editOrNewRbdLike( + io.kubernetes.client.openapi.models.V1RBDVolumeSource item); + /** * This method has been deprecated, please use method buildScaleIO instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource getScaleIO(); + public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource buildScaleIO(); + public A withScaleIO(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource scaleIO); + public java.lang.Boolean hasScaleIO(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested withNewScaleIO(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested withNewScaleIOLike(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested withNewScaleIOLike( + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested editScaleIO(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested editOrNewScaleIO(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested editOrNewScaleIOLike(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested editOrNewScaleIOLike( + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource item); + /** * This method has been deprecated, please use method buildSecret instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretVolumeSource getSecret(); + public io.kubernetes.client.openapi.models.V1SecretVolumeSource buildSecret(); + public A withSecret(io.kubernetes.client.openapi.models.V1SecretVolumeSource secret); + public java.lang.Boolean hasSecret(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested withNewSecret(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested withNewSecretLike(io.kubernetes.client.openapi.models.V1SecretVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested withNewSecretLike( + io.kubernetes.client.openapi.models.V1SecretVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested editSecret(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested editOrNewSecret(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested editOrNewSecretLike(io.kubernetes.client.openapi.models.V1SecretVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested editOrNewSecretLike( + io.kubernetes.client.openapi.models.V1SecretVolumeSource item); + /** * This method has been deprecated, please use method buildStorageos instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1StorageOSVolumeSource getStorageos(); + public io.kubernetes.client.openapi.models.V1StorageOSVolumeSource buildStorageos(); + public A withStorageos(io.kubernetes.client.openapi.models.V1StorageOSVolumeSource storageos); + public java.lang.Boolean hasStorageos(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested withNewStorageos(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested withNewStorageosLike(io.kubernetes.client.openapi.models.V1StorageOSVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested withNewStorageosLike( + io.kubernetes.client.openapi.models.V1StorageOSVolumeSource item); + public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested editStorageos(); + public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested editOrNewStorageos(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested editOrNewStorageosLike(io.kubernetes.client.openapi.models.V1StorageOSVolumeSource item); - + + public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested + editOrNewStorageosLike(io.kubernetes.client.openapi.models.V1StorageOSVolumeSource item); + /** * This method has been deprecated, please use method buildVsphereVolume instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource getVsphereVolume(); + public io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource buildVsphereVolume(); - public A withVsphereVolume(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource vsphereVolume); + + public A withVsphereVolume( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource vsphereVolume); + public java.lang.Boolean hasVsphereVolume(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested withNewVsphereVolume(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested withNewVsphereVolumeLike(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item); - public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested editVsphereVolume(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested editOrNewVsphereVolume(); - public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested editOrNewVsphereVolumeLike(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item); - public interface AwsElasticBlockStoreNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent>{ + + public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested + withNewVsphereVolume(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested + withNewVsphereVolumeLike( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested + editVsphereVolume(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested + editOrNewVsphereVolume(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested + editOrNewVsphereVolumeLike( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item); + + public interface AwsElasticBlockStoreNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested> { public N and(); + public N endAwsElasticBlockStore(); - } - public interface AzureDiskNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent>{ + + public interface AzureDiskNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested> { public N and(); + public N endAzureDisk(); - } - public interface AzureFileNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent>{ + + public interface AzureFileNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested> { public N and(); + public N endAzureFile(); - } - public interface CephfsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent>{ + + public interface CephfsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested> { public N and(); + public N endCephfs(); - } - public interface CinderNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent>{ + + public interface CinderNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested> { public N and(); + public N endCinder(); - } - public interface ConfigMapNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent>{ + + public interface ConfigMapNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested> { public N and(); + public N endConfigMap(); - } - public interface CsiNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent>{ + + public interface CsiNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested> { public N and(); + public N endCsi(); - } - public interface DownwardAPINested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent>{ + + public interface DownwardAPINested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested> { public N and(); + public N endDownwardAPI(); - } - public interface EmptyDirNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent>{ + + public interface EmptyDirNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested> { public N and(); + public N endEmptyDir(); - } - public interface EphemeralNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent>{ + + public interface EphemeralNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested> { public N and(); + public N endEphemeral(); - } - public interface FcNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent>{ + + public interface FcNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1FCVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested> { public N and(); + public N endFc(); - } - public interface FlexVolumeNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent>{ + + public interface FlexVolumeNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested> { public N and(); + public N endFlexVolume(); - } - public interface FlockerNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent>{ + + public interface FlockerNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested> { public N and(); + public N endFlocker(); - } - public interface GcePersistentDiskNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent>{ + + public interface GcePersistentDiskNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested> { public N and(); + public N endGcePersistentDisk(); - } - public interface GitRepoNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent>{ + + public interface GitRepoNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested> { public N and(); + public N endGitRepo(); - } - public interface GlusterfsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent>{ + + public interface GlusterfsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested> { public N and(); + public N endGlusterfs(); - } - public interface HostPathNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent>{ + + public interface HostPathNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested> { public N and(); + public N endHostPath(); - } - public interface IscsiNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent>{ + + public interface IscsiNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested> { public N and(); + public N endIscsi(); - } - public interface NfsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent>{ + + public interface NfsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested> { public N and(); + public N endNfs(); - } - public interface PersistentVolumeClaimNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent>{ + + public interface PersistentVolumeClaimNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested> { public N and(); + public N endPersistentVolumeClaim(); - } - public interface PhotonPersistentDiskNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent>{ + + public interface PhotonPersistentDiskNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested> { public N and(); + public N endPhotonPersistentDisk(); - } - public interface PortworxVolumeNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent>{ + + public interface PortworxVolumeNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested> { public N and(); + public N endPortworxVolume(); - } - public interface ProjectedNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent>{ + + public interface ProjectedNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested> { public N and(); + public N endProjected(); - } - public interface QuobyteNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent>{ + + public interface QuobyteNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested> { public N and(); + public N endQuobyte(); - } - public interface RbdNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent>{ + + public interface RbdNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested> { public N and(); + public N endRbd(); - } - public interface ScaleIONested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent>{ + + public interface ScaleIONested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested> { public N and(); + public N endScaleIO(); - } - public interface SecretNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent>{ + + public interface SecretNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested> { public N and(); + public N endSecret(); - } - public interface StorageosNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent>{ + + public interface StorageosNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested> { public N and(); + public N endStorageos(); - } - public interface VsphereVolumeNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent>{ + + public interface VsphereVolumeNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent< + io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested> { public N and(); + public N endVsphereVolume(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeFluentImpl.java index cf5ac833b0..e63e2518ec 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeFluentImpl.java @@ -1,18 +1,23 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.String; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Object; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.Nested; +/** Generated */ +public class V1VolumeFluentImpl> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1VolumeFluent { + public V1VolumeFluentImpl() {} - /** - * Generated - */ -public class V1VolumeFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1VolumeFluent{ - public V1VolumeFluentImpl() { - } public V1VolumeFluentImpl(io.kubernetes.client.openapi.models.V1Volume instance) { this.withAwsElasticBlockStore(instance.getAwsElasticBlockStore()); @@ -73,9 +78,10 @@ public V1VolumeFluentImpl(io.kubernetes.client.openapi.models.V1Volume instance) this.withStorageos(instance.getStorageos()); this.withVsphereVolume(instance.getVsphereVolume()); - } - private io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder awsElasticBlockStore; + + private io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder + awsElasticBlockStore; private io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder azureDisk; private io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceBuilder azureFile; private io.kubernetes.client.openapi.models.V1CephFSVolumeSourceBuilder cephfs; @@ -88,15 +94,18 @@ public V1VolumeFluentImpl(io.kubernetes.client.openapi.models.V1Volume instance) private io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder fc; private io.kubernetes.client.openapi.models.V1FlexVolumeSourceBuilder flexVolume; private io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder flocker; - private io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder gcePersistentDisk; + private io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder + gcePersistentDisk; private io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceBuilder gitRepo; private io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceBuilder glusterfs; private io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder hostPath; private io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceBuilder iscsi; private java.lang.String name; private io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder nfs; - private io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceBuilder persistentVolumeClaim; - private io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder photonPersistentDisk; + private io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceBuilder + persistentVolumeClaim; + private io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder + photonPersistentDisk; private io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder portworxVolume; private io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceBuilder projected; private io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder quobyte; @@ -105,1511 +114,2452 @@ public V1VolumeFluentImpl(io.kubernetes.client.openapi.models.V1Volume instance) private io.kubernetes.client.openapi.models.V1SecretVolumeSourceBuilder secret; private io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceBuilder storageos; private io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder vsphereVolume; - + /** * This method has been deprecated, please use method buildAwsElasticBlockStore instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource getAwsElasticBlockStore() { - return this.awsElasticBlockStore!=null ?this.awsElasticBlockStore.build():null; + public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource + getAwsElasticBlockStore() { + return this.awsElasticBlockStore != null ? this.awsElasticBlockStore.build() : null; } - public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource buildAwsElasticBlockStore() { - return this.awsElasticBlockStore!=null ?this.awsElasticBlockStore.build():null; + + public io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource + buildAwsElasticBlockStore() { + return this.awsElasticBlockStore != null ? this.awsElasticBlockStore.build() : null; } - public A withAwsElasticBlockStore(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource awsElasticBlockStore) { + + public A withAwsElasticBlockStore( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource awsElasticBlockStore) { _visitables.get("awsElasticBlockStore").remove(this.awsElasticBlockStore); - if (awsElasticBlockStore!=null){ this.awsElasticBlockStore= new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder(awsElasticBlockStore); _visitables.get("awsElasticBlockStore").add(this.awsElasticBlockStore);} return (A) this; + if (awsElasticBlockStore != null) { + this.awsElasticBlockStore = + new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder( + awsElasticBlockStore); + _visitables.get("awsElasticBlockStore").add(this.awsElasticBlockStore); + } + return (A) this; } + public java.lang.Boolean hasAwsElasticBlockStore() { return this.awsElasticBlockStore != null; } - public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested withNewAwsElasticBlockStore() { - return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.AwsElasticBlockStoreNestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested + withNewAwsElasticBlockStore() { + return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl + .AwsElasticBlockStoreNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested withNewAwsElasticBlockStoreLike(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.AwsElasticBlockStoreNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested + withNewAwsElasticBlockStoreLike( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl + .AwsElasticBlockStoreNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested editAwsElasticBlockStore() { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested + editAwsElasticBlockStore() { return withNewAwsElasticBlockStoreLike(getAwsElasticBlockStore()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested editOrNewAwsElasticBlockStore() { - return withNewAwsElasticBlockStoreLike(getAwsElasticBlockStore() != null ? getAwsElasticBlockStore(): new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested + editOrNewAwsElasticBlockStore() { + return withNewAwsElasticBlockStoreLike( + getAwsElasticBlockStore() != null + ? getAwsElasticBlockStore() + : new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested editOrNewAwsElasticBlockStoreLike(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item) { - return withNewAwsElasticBlockStoreLike(getAwsElasticBlockStore() != null ? getAwsElasticBlockStore(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested + editOrNewAwsElasticBlockStoreLike( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item) { + return withNewAwsElasticBlockStoreLike( + getAwsElasticBlockStore() != null ? getAwsElasticBlockStore() : item); } - + /** * This method has been deprecated, please use method buildAzureDisk instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource getAzureDisk() { - return this.azureDisk!=null ?this.azureDisk.build():null; + return this.azureDisk != null ? this.azureDisk.build() : null; } + public io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource buildAzureDisk() { - return this.azureDisk!=null ?this.azureDisk.build():null; + return this.azureDisk != null ? this.azureDisk.build() : null; } + public A withAzureDisk(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource azureDisk) { _visitables.get("azureDisk").remove(this.azureDisk); - if (azureDisk!=null){ this.azureDisk= new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder(azureDisk); _visitables.get("azureDisk").add(this.azureDisk);} return (A) this; + if (azureDisk != null) { + this.azureDisk = + new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder(azureDisk); + _visitables.get("azureDisk").add(this.azureDisk); + } + return (A) this; } + public java.lang.Boolean hasAzureDisk() { return this.azureDisk != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested withNewAzureDisk() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.AzureDiskNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested withNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested withNewAzureDiskLike( + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.AzureDiskNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested editAzureDisk() { return withNewAzureDiskLike(getAzureDisk()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested editOrNewAzureDisk() { - return withNewAzureDiskLike(getAzureDisk() != null ? getAzureDisk(): new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested + editOrNewAzureDisk() { + return withNewAzureDiskLike( + getAzureDisk() != null + ? getAzureDisk() + : new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested editOrNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item) { - return withNewAzureDiskLike(getAzureDisk() != null ? getAzureDisk(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested + editOrNewAzureDiskLike(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item) { + return withNewAzureDiskLike(getAzureDisk() != null ? getAzureDisk() : item); } - + /** * This method has been deprecated, please use method buildAzureFile instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1AzureFileVolumeSource getAzureFile() { - return this.azureFile!=null ?this.azureFile.build():null; + return this.azureFile != null ? this.azureFile.build() : null; } + public io.kubernetes.client.openapi.models.V1AzureFileVolumeSource buildAzureFile() { - return this.azureFile!=null ?this.azureFile.build():null; + return this.azureFile != null ? this.azureFile.build() : null; } + public A withAzureFile(io.kubernetes.client.openapi.models.V1AzureFileVolumeSource azureFile) { _visitables.get("azureFile").remove(this.azureFile); - if (azureFile!=null){ this.azureFile= new io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceBuilder(azureFile); _visitables.get("azureFile").add(this.azureFile);} return (A) this; + if (azureFile != null) { + this.azureFile = + new io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceBuilder(azureFile); + _visitables.get("azureFile").add(this.azureFile); + } + return (A) this; } + public java.lang.Boolean hasAzureFile() { return this.azureFile != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested withNewAzureFile() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.AzureFileNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested withNewAzureFileLike(io.kubernetes.client.openapi.models.V1AzureFileVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested withNewAzureFileLike( + io.kubernetes.client.openapi.models.V1AzureFileVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.AzureFileNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested editAzureFile() { return withNewAzureFileLike(getAzureFile()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested editOrNewAzureFile() { - return withNewAzureFileLike(getAzureFile() != null ? getAzureFile(): new io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested + editOrNewAzureFile() { + return withNewAzureFileLike( + getAzureFile() != null + ? getAzureFile() + : new io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested editOrNewAzureFileLike(io.kubernetes.client.openapi.models.V1AzureFileVolumeSource item) { - return withNewAzureFileLike(getAzureFile() != null ? getAzureFile(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested + editOrNewAzureFileLike(io.kubernetes.client.openapi.models.V1AzureFileVolumeSource item) { + return withNewAzureFileLike(getAzureFile() != null ? getAzureFile() : item); } - + /** * This method has been deprecated, please use method buildCephfs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CephFSVolumeSource getCephfs() { - return this.cephfs!=null ?this.cephfs.build():null; + return this.cephfs != null ? this.cephfs.build() : null; } + public io.kubernetes.client.openapi.models.V1CephFSVolumeSource buildCephfs() { - return this.cephfs!=null ?this.cephfs.build():null; + return this.cephfs != null ? this.cephfs.build() : null; } + public A withCephfs(io.kubernetes.client.openapi.models.V1CephFSVolumeSource cephfs) { _visitables.get("cephfs").remove(this.cephfs); - if (cephfs!=null){ this.cephfs= new io.kubernetes.client.openapi.models.V1CephFSVolumeSourceBuilder(cephfs); _visitables.get("cephfs").add(this.cephfs);} return (A) this; + if (cephfs != null) { + this.cephfs = new io.kubernetes.client.openapi.models.V1CephFSVolumeSourceBuilder(cephfs); + _visitables.get("cephfs").add(this.cephfs); + } + return (A) this; } + public java.lang.Boolean hasCephfs() { return this.cephfs != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested withNewCephfs() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.CephfsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested withNewCephfsLike(io.kubernetes.client.openapi.models.V1CephFSVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested withNewCephfsLike( + io.kubernetes.client.openapi.models.V1CephFSVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.CephfsNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested editCephfs() { return withNewCephfsLike(getCephfs()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested editOrNewCephfs() { - return withNewCephfsLike(getCephfs() != null ? getCephfs(): new io.kubernetes.client.openapi.models.V1CephFSVolumeSourceBuilder().build()); + return withNewCephfsLike( + getCephfs() != null + ? getCephfs() + : new io.kubernetes.client.openapi.models.V1CephFSVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested editOrNewCephfsLike(io.kubernetes.client.openapi.models.V1CephFSVolumeSource item) { - return withNewCephfsLike(getCephfs() != null ? getCephfs(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested editOrNewCephfsLike( + io.kubernetes.client.openapi.models.V1CephFSVolumeSource item) { + return withNewCephfsLike(getCephfs() != null ? getCephfs() : item); } - + /** * This method has been deprecated, please use method buildCinder instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CinderVolumeSource getCinder() { - return this.cinder!=null ?this.cinder.build():null; + return this.cinder != null ? this.cinder.build() : null; } + public io.kubernetes.client.openapi.models.V1CinderVolumeSource buildCinder() { - return this.cinder!=null ?this.cinder.build():null; + return this.cinder != null ? this.cinder.build() : null; } + public A withCinder(io.kubernetes.client.openapi.models.V1CinderVolumeSource cinder) { _visitables.get("cinder").remove(this.cinder); - if (cinder!=null){ this.cinder= new io.kubernetes.client.openapi.models.V1CinderVolumeSourceBuilder(cinder); _visitables.get("cinder").add(this.cinder);} return (A) this; + if (cinder != null) { + this.cinder = new io.kubernetes.client.openapi.models.V1CinderVolumeSourceBuilder(cinder); + _visitables.get("cinder").add(this.cinder); + } + return (A) this; } + public java.lang.Boolean hasCinder() { return this.cinder != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested withNewCinder() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.CinderNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested withNewCinderLike(io.kubernetes.client.openapi.models.V1CinderVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested withNewCinderLike( + io.kubernetes.client.openapi.models.V1CinderVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.CinderNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested editCinder() { return withNewCinderLike(getCinder()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested editOrNewCinder() { - return withNewCinderLike(getCinder() != null ? getCinder(): new io.kubernetes.client.openapi.models.V1CinderVolumeSourceBuilder().build()); + return withNewCinderLike( + getCinder() != null + ? getCinder() + : new io.kubernetes.client.openapi.models.V1CinderVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested editOrNewCinderLike(io.kubernetes.client.openapi.models.V1CinderVolumeSource item) { - return withNewCinderLike(getCinder() != null ? getCinder(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested editOrNewCinderLike( + io.kubernetes.client.openapi.models.V1CinderVolumeSource item) { + return withNewCinderLike(getCinder() != null ? getCinder() : item); } - + /** * This method has been deprecated, please use method buildConfigMap instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource getConfigMap() { - return this.configMap!=null ?this.configMap.build():null; + return this.configMap != null ? this.configMap.build() : null; } + public io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource buildConfigMap() { - return this.configMap!=null ?this.configMap.build():null; + return this.configMap != null ? this.configMap.build() : null; } + public A withConfigMap(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource configMap) { _visitables.get("configMap").remove(this.configMap); - if (configMap!=null){ this.configMap= new io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceBuilder(configMap); _visitables.get("configMap").add(this.configMap);} return (A) this; + if (configMap != null) { + this.configMap = + new io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceBuilder(configMap); + _visitables.get("configMap").add(this.configMap); + } + return (A) this; } + public java.lang.Boolean hasConfigMap() { return this.configMap != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested withNewConfigMap() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.ConfigMapNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested withNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested withNewConfigMapLike( + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.ConfigMapNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested editConfigMap() { return withNewConfigMapLike(getConfigMap()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested editOrNewConfigMap() { - return withNewConfigMapLike(getConfigMap() != null ? getConfigMap(): new io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested + editOrNewConfigMap() { + return withNewConfigMapLike( + getConfigMap() != null + ? getConfigMap() + : new io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested editOrNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource item) { - return withNewConfigMapLike(getConfigMap() != null ? getConfigMap(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested + editOrNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource item) { + return withNewConfigMapLike(getConfigMap() != null ? getConfigMap() : item); } - + /** * This method has been deprecated, please use method buildCsi instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1CSIVolumeSource getCsi() { - return this.csi!=null ?this.csi.build():null; + return this.csi != null ? this.csi.build() : null; } + public io.kubernetes.client.openapi.models.V1CSIVolumeSource buildCsi() { - return this.csi!=null ?this.csi.build():null; + return this.csi != null ? this.csi.build() : null; } + public A withCsi(io.kubernetes.client.openapi.models.V1CSIVolumeSource csi) { _visitables.get("csi").remove(this.csi); - if (csi!=null){ this.csi= new io.kubernetes.client.openapi.models.V1CSIVolumeSourceBuilder(csi); _visitables.get("csi").add(this.csi);} return (A) this; + if (csi != null) { + this.csi = new io.kubernetes.client.openapi.models.V1CSIVolumeSourceBuilder(csi); + _visitables.get("csi").add(this.csi); + } + return (A) this; } + public java.lang.Boolean hasCsi() { return this.csi != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested withNewCsi() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.CsiNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested withNewCsiLike(io.kubernetes.client.openapi.models.V1CSIVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested withNewCsiLike( + io.kubernetes.client.openapi.models.V1CSIVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.CsiNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested editCsi() { return withNewCsiLike(getCsi()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested editOrNewCsi() { - return withNewCsiLike(getCsi() != null ? getCsi(): new io.kubernetes.client.openapi.models.V1CSIVolumeSourceBuilder().build()); + return withNewCsiLike( + getCsi() != null + ? getCsi() + : new io.kubernetes.client.openapi.models.V1CSIVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested editOrNewCsiLike(io.kubernetes.client.openapi.models.V1CSIVolumeSource item) { - return withNewCsiLike(getCsi() != null ? getCsi(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested editOrNewCsiLike( + io.kubernetes.client.openapi.models.V1CSIVolumeSource item) { + return withNewCsiLike(getCsi() != null ? getCsi() : item); } - + /** * This method has been deprecated, please use method buildDownwardAPI instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource getDownwardAPI() { - return this.downwardAPI!=null ?this.downwardAPI.build():null; + return this.downwardAPI != null ? this.downwardAPI.build() : null; } + public io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource buildDownwardAPI() { - return this.downwardAPI!=null ?this.downwardAPI.build():null; + return this.downwardAPI != null ? this.downwardAPI.build() : null; } - public A withDownwardAPI(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource downwardAPI) { + + public A withDownwardAPI( + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource downwardAPI) { _visitables.get("downwardAPI").remove(this.downwardAPI); - if (downwardAPI!=null){ this.downwardAPI= new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceBuilder(downwardAPI); _visitables.get("downwardAPI").add(this.downwardAPI);} return (A) this; + if (downwardAPI != null) { + this.downwardAPI = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceBuilder(downwardAPI); + _visitables.get("downwardAPI").add(this.downwardAPI); + } + return (A) this; } + public java.lang.Boolean hasDownwardAPI() { return this.downwardAPI != null; } - public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested withNewDownwardAPI() { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested + withNewDownwardAPI() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.DownwardAPINestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested withNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested + withNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.DownwardAPINestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested editDownwardAPI() { return withNewDownwardAPILike(getDownwardAPI()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested editOrNewDownwardAPI() { - return withNewDownwardAPILike(getDownwardAPI() != null ? getDownwardAPI(): new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested + editOrNewDownwardAPI() { + return withNewDownwardAPILike( + getDownwardAPI() != null + ? getDownwardAPI() + : new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested editOrNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource item) { - return withNewDownwardAPILike(getDownwardAPI() != null ? getDownwardAPI(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested + editOrNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource item) { + return withNewDownwardAPILike(getDownwardAPI() != null ? getDownwardAPI() : item); } - + /** * This method has been deprecated, please use method buildEmptyDir instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource getEmptyDir() { - return this.emptyDir!=null ?this.emptyDir.build():null; + return this.emptyDir != null ? this.emptyDir.build() : null; } + public io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource buildEmptyDir() { - return this.emptyDir!=null ?this.emptyDir.build():null; + return this.emptyDir != null ? this.emptyDir.build() : null; } + public A withEmptyDir(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource emptyDir) { _visitables.get("emptyDir").remove(this.emptyDir); - if (emptyDir!=null){ this.emptyDir= new io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceBuilder(emptyDir); _visitables.get("emptyDir").add(this.emptyDir);} return (A) this; + if (emptyDir != null) { + this.emptyDir = + new io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceBuilder(emptyDir); + _visitables.get("emptyDir").add(this.emptyDir); + } + return (A) this; } + public java.lang.Boolean hasEmptyDir() { return this.emptyDir != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested withNewEmptyDir() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.EmptyDirNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested withNewEmptyDirLike(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested withNewEmptyDirLike( + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.EmptyDirNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested editEmptyDir() { return withNewEmptyDirLike(getEmptyDir()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested editOrNewEmptyDir() { - return withNewEmptyDirLike(getEmptyDir() != null ? getEmptyDir(): new io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceBuilder().build()); + return withNewEmptyDirLike( + getEmptyDir() != null + ? getEmptyDir() + : new io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested editOrNewEmptyDirLike(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource item) { - return withNewEmptyDirLike(getEmptyDir() != null ? getEmptyDir(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested editOrNewEmptyDirLike( + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource item) { + return withNewEmptyDirLike(getEmptyDir() != null ? getEmptyDir() : item); } - + /** * This method has been deprecated, please use method buildEphemeral instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EphemeralVolumeSource getEphemeral() { - return this.ephemeral!=null ?this.ephemeral.build():null; + return this.ephemeral != null ? this.ephemeral.build() : null; } + public io.kubernetes.client.openapi.models.V1EphemeralVolumeSource buildEphemeral() { - return this.ephemeral!=null ?this.ephemeral.build():null; + return this.ephemeral != null ? this.ephemeral.build() : null; } + public A withEphemeral(io.kubernetes.client.openapi.models.V1EphemeralVolumeSource ephemeral) { _visitables.get("ephemeral").remove(this.ephemeral); - if (ephemeral!=null){ this.ephemeral= new io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceBuilder(ephemeral); _visitables.get("ephemeral").add(this.ephemeral);} return (A) this; + if (ephemeral != null) { + this.ephemeral = + new io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceBuilder(ephemeral); + _visitables.get("ephemeral").add(this.ephemeral); + } + return (A) this; } + public java.lang.Boolean hasEphemeral() { return this.ephemeral != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested withNewEphemeral() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.EphemeralNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested withNewEphemeralLike(io.kubernetes.client.openapi.models.V1EphemeralVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested withNewEphemeralLike( + io.kubernetes.client.openapi.models.V1EphemeralVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.EphemeralNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested editEphemeral() { return withNewEphemeralLike(getEphemeral()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested editOrNewEphemeral() { - return withNewEphemeralLike(getEphemeral() != null ? getEphemeral(): new io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested + editOrNewEphemeral() { + return withNewEphemeralLike( + getEphemeral() != null + ? getEphemeral() + : new io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested editOrNewEphemeralLike(io.kubernetes.client.openapi.models.V1EphemeralVolumeSource item) { - return withNewEphemeralLike(getEphemeral() != null ? getEphemeral(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested + editOrNewEphemeralLike(io.kubernetes.client.openapi.models.V1EphemeralVolumeSource item) { + return withNewEphemeralLike(getEphemeral() != null ? getEphemeral() : item); } - + /** * This method has been deprecated, please use method buildFc instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1FCVolumeSource getFc() { - return this.fc!=null ?this.fc.build():null; + return this.fc != null ? this.fc.build() : null; } + public io.kubernetes.client.openapi.models.V1FCVolumeSource buildFc() { - return this.fc!=null ?this.fc.build():null; + return this.fc != null ? this.fc.build() : null; } + public A withFc(io.kubernetes.client.openapi.models.V1FCVolumeSource fc) { _visitables.get("fc").remove(this.fc); - if (fc!=null){ this.fc= new io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder(fc); _visitables.get("fc").add(this.fc);} return (A) this; + if (fc != null) { + this.fc = new io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder(fc); + _visitables.get("fc").add(this.fc); + } + return (A) this; } + public java.lang.Boolean hasFc() { return this.fc != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested withNewFc() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.FcNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested withNewFcLike(io.kubernetes.client.openapi.models.V1FCVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested withNewFcLike( + io.kubernetes.client.openapi.models.V1FCVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.FcNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested editFc() { return withNewFcLike(getFc()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested editOrNewFc() { - return withNewFcLike(getFc() != null ? getFc(): new io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder().build()); + return withNewFcLike( + getFc() != null + ? getFc() + : new io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested editOrNewFcLike(io.kubernetes.client.openapi.models.V1FCVolumeSource item) { - return withNewFcLike(getFc() != null ? getFc(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested editOrNewFcLike( + io.kubernetes.client.openapi.models.V1FCVolumeSource item) { + return withNewFcLike(getFc() != null ? getFc() : item); } - + /** * This method has been deprecated, please use method buildFlexVolume instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1FlexVolumeSource getFlexVolume() { - return this.flexVolume!=null ?this.flexVolume.build():null; + return this.flexVolume != null ? this.flexVolume.build() : null; } + public io.kubernetes.client.openapi.models.V1FlexVolumeSource buildFlexVolume() { - return this.flexVolume!=null ?this.flexVolume.build():null; + return this.flexVolume != null ? this.flexVolume.build() : null; } + public A withFlexVolume(io.kubernetes.client.openapi.models.V1FlexVolumeSource flexVolume) { _visitables.get("flexVolume").remove(this.flexVolume); - if (flexVolume!=null){ this.flexVolume= new io.kubernetes.client.openapi.models.V1FlexVolumeSourceBuilder(flexVolume); _visitables.get("flexVolume").add(this.flexVolume);} return (A) this; + if (flexVolume != null) { + this.flexVolume = + new io.kubernetes.client.openapi.models.V1FlexVolumeSourceBuilder(flexVolume); + _visitables.get("flexVolume").add(this.flexVolume); + } + return (A) this; } + public java.lang.Boolean hasFlexVolume() { return this.flexVolume != null; } - public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested withNewFlexVolume() { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested + withNewFlexVolume() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.FlexVolumeNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested withNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested + withNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.FlexVolumeNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested editFlexVolume() { return withNewFlexVolumeLike(getFlexVolume()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested editOrNewFlexVolume() { - return withNewFlexVolumeLike(getFlexVolume() != null ? getFlexVolume(): new io.kubernetes.client.openapi.models.V1FlexVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested + editOrNewFlexVolume() { + return withNewFlexVolumeLike( + getFlexVolume() != null + ? getFlexVolume() + : new io.kubernetes.client.openapi.models.V1FlexVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested editOrNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexVolumeSource item) { - return withNewFlexVolumeLike(getFlexVolume() != null ? getFlexVolume(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested + editOrNewFlexVolumeLike(io.kubernetes.client.openapi.models.V1FlexVolumeSource item) { + return withNewFlexVolumeLike(getFlexVolume() != null ? getFlexVolume() : item); } - + /** * This method has been deprecated, please use method buildFlocker instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1FlockerVolumeSource getFlocker() { - return this.flocker!=null ?this.flocker.build():null; + return this.flocker != null ? this.flocker.build() : null; } + public io.kubernetes.client.openapi.models.V1FlockerVolumeSource buildFlocker() { - return this.flocker!=null ?this.flocker.build():null; + return this.flocker != null ? this.flocker.build() : null; } + public A withFlocker(io.kubernetes.client.openapi.models.V1FlockerVolumeSource flocker) { _visitables.get("flocker").remove(this.flocker); - if (flocker!=null){ this.flocker= new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder(flocker); _visitables.get("flocker").add(this.flocker);} return (A) this; + if (flocker != null) { + this.flocker = new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder(flocker); + _visitables.get("flocker").add(this.flocker); + } + return (A) this; } + public java.lang.Boolean hasFlocker() { return this.flocker != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested withNewFlocker() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.FlockerNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested withNewFlockerLike(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested withNewFlockerLike( + io.kubernetes.client.openapi.models.V1FlockerVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.FlockerNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested editFlocker() { return withNewFlockerLike(getFlocker()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested editOrNewFlocker() { - return withNewFlockerLike(getFlocker() != null ? getFlocker(): new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder().build()); + return withNewFlockerLike( + getFlocker() != null + ? getFlocker() + : new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested editOrNewFlockerLike(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item) { - return withNewFlockerLike(getFlocker() != null ? getFlocker(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested editOrNewFlockerLike( + io.kubernetes.client.openapi.models.V1FlockerVolumeSource item) { + return withNewFlockerLike(getFlocker() != null ? getFlocker() : item); } - + /** * This method has been deprecated, please use method buildGcePersistentDisk instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource getGcePersistentDisk() { - return this.gcePersistentDisk!=null ?this.gcePersistentDisk.build():null; + public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource + getGcePersistentDisk() { + return this.gcePersistentDisk != null ? this.gcePersistentDisk.build() : null; } - public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource buildGcePersistentDisk() { - return this.gcePersistentDisk!=null ?this.gcePersistentDisk.build():null; + + public io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource + buildGcePersistentDisk() { + return this.gcePersistentDisk != null ? this.gcePersistentDisk.build() : null; } - public A withGcePersistentDisk(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource gcePersistentDisk) { + + public A withGcePersistentDisk( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource gcePersistentDisk) { _visitables.get("gcePersistentDisk").remove(this.gcePersistentDisk); - if (gcePersistentDisk!=null){ this.gcePersistentDisk= new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder(gcePersistentDisk); _visitables.get("gcePersistentDisk").add(this.gcePersistentDisk);} return (A) this; + if (gcePersistentDisk != null) { + this.gcePersistentDisk = + new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder( + gcePersistentDisk); + _visitables.get("gcePersistentDisk").add(this.gcePersistentDisk); + } + return (A) this; } + public java.lang.Boolean hasGcePersistentDisk() { return this.gcePersistentDisk != null; } - public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested withNewGcePersistentDisk() { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested + withNewGcePersistentDisk() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.GcePersistentDiskNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested withNewGcePersistentDiskLike(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.GcePersistentDiskNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested + withNewGcePersistentDiskLike( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.GcePersistentDiskNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested editGcePersistentDisk() { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested + editGcePersistentDisk() { return withNewGcePersistentDiskLike(getGcePersistentDisk()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested editOrNewGcePersistentDisk() { - return withNewGcePersistentDiskLike(getGcePersistentDisk() != null ? getGcePersistentDisk(): new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested + editOrNewGcePersistentDisk() { + return withNewGcePersistentDiskLike( + getGcePersistentDisk() != null + ? getGcePersistentDisk() + : new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested editOrNewGcePersistentDiskLike(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item) { - return withNewGcePersistentDiskLike(getGcePersistentDisk() != null ? getGcePersistentDisk(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested + editOrNewGcePersistentDiskLike( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item) { + return withNewGcePersistentDiskLike( + getGcePersistentDisk() != null ? getGcePersistentDisk() : item); } - + /** * This method has been deprecated, please use method buildGitRepo instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1GitRepoVolumeSource getGitRepo() { - return this.gitRepo!=null ?this.gitRepo.build():null; + return this.gitRepo != null ? this.gitRepo.build() : null; } + public io.kubernetes.client.openapi.models.V1GitRepoVolumeSource buildGitRepo() { - return this.gitRepo!=null ?this.gitRepo.build():null; + return this.gitRepo != null ? this.gitRepo.build() : null; } + public A withGitRepo(io.kubernetes.client.openapi.models.V1GitRepoVolumeSource gitRepo) { _visitables.get("gitRepo").remove(this.gitRepo); - if (gitRepo!=null){ this.gitRepo= new io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceBuilder(gitRepo); _visitables.get("gitRepo").add(this.gitRepo);} return (A) this; + if (gitRepo != null) { + this.gitRepo = new io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceBuilder(gitRepo); + _visitables.get("gitRepo").add(this.gitRepo); + } + return (A) this; } + public java.lang.Boolean hasGitRepo() { return this.gitRepo != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested withNewGitRepo() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.GitRepoNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested withNewGitRepoLike(io.kubernetes.client.openapi.models.V1GitRepoVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested withNewGitRepoLike( + io.kubernetes.client.openapi.models.V1GitRepoVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.GitRepoNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested editGitRepo() { return withNewGitRepoLike(getGitRepo()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested editOrNewGitRepo() { - return withNewGitRepoLike(getGitRepo() != null ? getGitRepo(): new io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceBuilder().build()); + return withNewGitRepoLike( + getGitRepo() != null + ? getGitRepo() + : new io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested editOrNewGitRepoLike(io.kubernetes.client.openapi.models.V1GitRepoVolumeSource item) { - return withNewGitRepoLike(getGitRepo() != null ? getGitRepo(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested editOrNewGitRepoLike( + io.kubernetes.client.openapi.models.V1GitRepoVolumeSource item) { + return withNewGitRepoLike(getGitRepo() != null ? getGitRepo() : item); } - + /** * This method has been deprecated, please use method buildGlusterfs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource getGlusterfs() { - return this.glusterfs!=null ?this.glusterfs.build():null; + return this.glusterfs != null ? this.glusterfs.build() : null; } + public io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource buildGlusterfs() { - return this.glusterfs!=null ?this.glusterfs.build():null; + return this.glusterfs != null ? this.glusterfs.build() : null; } + public A withGlusterfs(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource glusterfs) { _visitables.get("glusterfs").remove(this.glusterfs); - if (glusterfs!=null){ this.glusterfs= new io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceBuilder(glusterfs); _visitables.get("glusterfs").add(this.glusterfs);} return (A) this; + if (glusterfs != null) { + this.glusterfs = + new io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceBuilder(glusterfs); + _visitables.get("glusterfs").add(this.glusterfs); + } + return (A) this; } + public java.lang.Boolean hasGlusterfs() { return this.glusterfs != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested withNewGlusterfs() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.GlusterfsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested withNewGlusterfsLike(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested withNewGlusterfsLike( + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.GlusterfsNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested editGlusterfs() { return withNewGlusterfsLike(getGlusterfs()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested editOrNewGlusterfs() { - return withNewGlusterfsLike(getGlusterfs() != null ? getGlusterfs(): new io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested + editOrNewGlusterfs() { + return withNewGlusterfsLike( + getGlusterfs() != null + ? getGlusterfs() + : new io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested editOrNewGlusterfsLike(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource item) { - return withNewGlusterfsLike(getGlusterfs() != null ? getGlusterfs(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested + editOrNewGlusterfsLike(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource item) { + return withNewGlusterfsLike(getGlusterfs() != null ? getGlusterfs() : item); } - + /** * This method has been deprecated, please use method buildHostPath instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1HostPathVolumeSource getHostPath() { - return this.hostPath!=null ?this.hostPath.build():null; + return this.hostPath != null ? this.hostPath.build() : null; } + public io.kubernetes.client.openapi.models.V1HostPathVolumeSource buildHostPath() { - return this.hostPath!=null ?this.hostPath.build():null; + return this.hostPath != null ? this.hostPath.build() : null; } + public A withHostPath(io.kubernetes.client.openapi.models.V1HostPathVolumeSource hostPath) { _visitables.get("hostPath").remove(this.hostPath); - if (hostPath!=null){ this.hostPath= new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder(hostPath); _visitables.get("hostPath").add(this.hostPath);} return (A) this; + if (hostPath != null) { + this.hostPath = + new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder(hostPath); + _visitables.get("hostPath").add(this.hostPath); + } + return (A) this; } + public java.lang.Boolean hasHostPath() { return this.hostPath != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested withNewHostPath() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.HostPathNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested withNewHostPathLike(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested withNewHostPathLike( + io.kubernetes.client.openapi.models.V1HostPathVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.HostPathNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested editHostPath() { return withNewHostPathLike(getHostPath()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested editOrNewHostPath() { - return withNewHostPathLike(getHostPath() != null ? getHostPath(): new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder().build()); + return withNewHostPathLike( + getHostPath() != null + ? getHostPath() + : new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested editOrNewHostPathLike(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item) { - return withNewHostPathLike(getHostPath() != null ? getHostPath(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested editOrNewHostPathLike( + io.kubernetes.client.openapi.models.V1HostPathVolumeSource item) { + return withNewHostPathLike(getHostPath() != null ? getHostPath() : item); } - + /** * This method has been deprecated, please use method buildIscsi instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ISCSIVolumeSource getIscsi() { - return this.iscsi!=null ?this.iscsi.build():null; + return this.iscsi != null ? this.iscsi.build() : null; } + public io.kubernetes.client.openapi.models.V1ISCSIVolumeSource buildIscsi() { - return this.iscsi!=null ?this.iscsi.build():null; + return this.iscsi != null ? this.iscsi.build() : null; } + public A withIscsi(io.kubernetes.client.openapi.models.V1ISCSIVolumeSource iscsi) { _visitables.get("iscsi").remove(this.iscsi); - if (iscsi!=null){ this.iscsi= new io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceBuilder(iscsi); _visitables.get("iscsi").add(this.iscsi);} return (A) this; + if (iscsi != null) { + this.iscsi = new io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceBuilder(iscsi); + _visitables.get("iscsi").add(this.iscsi); + } + return (A) this; } + public java.lang.Boolean hasIscsi() { return this.iscsi != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested withNewIscsi() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.IscsiNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested withNewIscsiLike(io.kubernetes.client.openapi.models.V1ISCSIVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested withNewIscsiLike( + io.kubernetes.client.openapi.models.V1ISCSIVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.IscsiNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested editIscsi() { return withNewIscsiLike(getIscsi()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested editOrNewIscsi() { - return withNewIscsiLike(getIscsi() != null ? getIscsi(): new io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceBuilder().build()); + return withNewIscsiLike( + getIscsi() != null + ? getIscsi() + : new io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested editOrNewIscsiLike(io.kubernetes.client.openapi.models.V1ISCSIVolumeSource item) { - return withNewIscsiLike(getIscsi() != null ? getIscsi(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested editOrNewIscsiLike( + io.kubernetes.client.openapi.models.V1ISCSIVolumeSource item) { + return withNewIscsiLike(getIscsi() != null ? getIscsi() : item); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } - + /** * This method has been deprecated, please use method buildNfs instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NFSVolumeSource getNfs() { - return this.nfs!=null ?this.nfs.build():null; + return this.nfs != null ? this.nfs.build() : null; } + public io.kubernetes.client.openapi.models.V1NFSVolumeSource buildNfs() { - return this.nfs!=null ?this.nfs.build():null; + return this.nfs != null ? this.nfs.build() : null; } + public A withNfs(io.kubernetes.client.openapi.models.V1NFSVolumeSource nfs) { _visitables.get("nfs").remove(this.nfs); - if (nfs!=null){ this.nfs= new io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder(nfs); _visitables.get("nfs").add(this.nfs);} return (A) this; + if (nfs != null) { + this.nfs = new io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder(nfs); + _visitables.get("nfs").add(this.nfs); + } + return (A) this; } + public java.lang.Boolean hasNfs() { return this.nfs != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested withNewNfs() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.NfsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested withNewNfsLike(io.kubernetes.client.openapi.models.V1NFSVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested withNewNfsLike( + io.kubernetes.client.openapi.models.V1NFSVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.NfsNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested editNfs() { return withNewNfsLike(getNfs()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested editOrNewNfs() { - return withNewNfsLike(getNfs() != null ? getNfs(): new io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder().build()); + return withNewNfsLike( + getNfs() != null + ? getNfs() + : new io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested editOrNewNfsLike(io.kubernetes.client.openapi.models.V1NFSVolumeSource item) { - return withNewNfsLike(getNfs() != null ? getNfs(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested editOrNewNfsLike( + io.kubernetes.client.openapi.models.V1NFSVolumeSource item) { + return withNewNfsLike(getNfs() != null ? getNfs() : item); } - + /** * This method has been deprecated, please use method buildPersistentVolumeClaim instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource getPersistentVolumeClaim() { - return this.persistentVolumeClaim!=null ?this.persistentVolumeClaim.build():null; + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource + getPersistentVolumeClaim() { + return this.persistentVolumeClaim != null ? this.persistentVolumeClaim.build() : null; } - public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource buildPersistentVolumeClaim() { - return this.persistentVolumeClaim!=null ?this.persistentVolumeClaim.build():null; + + public io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource + buildPersistentVolumeClaim() { + return this.persistentVolumeClaim != null ? this.persistentVolumeClaim.build() : null; } - public A withPersistentVolumeClaim(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource persistentVolumeClaim) { + + public A withPersistentVolumeClaim( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource + persistentVolumeClaim) { _visitables.get("persistentVolumeClaim").remove(this.persistentVolumeClaim); - if (persistentVolumeClaim!=null){ this.persistentVolumeClaim= new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceBuilder(persistentVolumeClaim); _visitables.get("persistentVolumeClaim").add(this.persistentVolumeClaim);} return (A) this; + if (persistentVolumeClaim != null) { + this.persistentVolumeClaim = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceBuilder( + persistentVolumeClaim); + _visitables.get("persistentVolumeClaim").add(this.persistentVolumeClaim); + } + return (A) this; } + public java.lang.Boolean hasPersistentVolumeClaim() { return this.persistentVolumeClaim != null; } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested withNewPersistentVolumeClaim() { - return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.PersistentVolumeClaimNestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested + withNewPersistentVolumeClaim() { + return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl + .PersistentVolumeClaimNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested withNewPersistentVolumeClaimLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.PersistentVolumeClaimNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested + withNewPersistentVolumeClaimLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl + .PersistentVolumeClaimNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested editPersistentVolumeClaim() { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested + editPersistentVolumeClaim() { return withNewPersistentVolumeClaimLike(getPersistentVolumeClaim()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested editOrNewPersistentVolumeClaim() { - return withNewPersistentVolumeClaimLike(getPersistentVolumeClaim() != null ? getPersistentVolumeClaim(): new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested + editOrNewPersistentVolumeClaim() { + return withNewPersistentVolumeClaimLike( + getPersistentVolumeClaim() != null + ? getPersistentVolumeClaim() + : new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested editOrNewPersistentVolumeClaimLike(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource item) { - return withNewPersistentVolumeClaimLike(getPersistentVolumeClaim() != null ? getPersistentVolumeClaim(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested + editOrNewPersistentVolumeClaimLike( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource item) { + return withNewPersistentVolumeClaimLike( + getPersistentVolumeClaim() != null ? getPersistentVolumeClaim() : item); } - + /** * This method has been deprecated, please use method buildPhotonPersistentDisk instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource getPhotonPersistentDisk() { - return this.photonPersistentDisk!=null ?this.photonPersistentDisk.build():null; + public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource + getPhotonPersistentDisk() { + return this.photonPersistentDisk != null ? this.photonPersistentDisk.build() : null; } - public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource buildPhotonPersistentDisk() { - return this.photonPersistentDisk!=null ?this.photonPersistentDisk.build():null; + + public io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource + buildPhotonPersistentDisk() { + return this.photonPersistentDisk != null ? this.photonPersistentDisk.build() : null; } - public A withPhotonPersistentDisk(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource photonPersistentDisk) { + + public A withPhotonPersistentDisk( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource photonPersistentDisk) { _visitables.get("photonPersistentDisk").remove(this.photonPersistentDisk); - if (photonPersistentDisk!=null){ this.photonPersistentDisk= new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder(photonPersistentDisk); _visitables.get("photonPersistentDisk").add(this.photonPersistentDisk);} return (A) this; + if (photonPersistentDisk != null) { + this.photonPersistentDisk = + new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder( + photonPersistentDisk); + _visitables.get("photonPersistentDisk").add(this.photonPersistentDisk); + } + return (A) this; } + public java.lang.Boolean hasPhotonPersistentDisk() { return this.photonPersistentDisk != null; } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested withNewPhotonPersistentDisk() { - return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.PhotonPersistentDiskNestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested + withNewPhotonPersistentDisk() { + return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl + .PhotonPersistentDiskNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested withNewPhotonPersistentDiskLike(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.PhotonPersistentDiskNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested + withNewPhotonPersistentDiskLike( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl + .PhotonPersistentDiskNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested editPhotonPersistentDisk() { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested + editPhotonPersistentDisk() { return withNewPhotonPersistentDiskLike(getPhotonPersistentDisk()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested editOrNewPhotonPersistentDisk() { - return withNewPhotonPersistentDiskLike(getPhotonPersistentDisk() != null ? getPhotonPersistentDisk(): new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested + editOrNewPhotonPersistentDisk() { + return withNewPhotonPersistentDiskLike( + getPhotonPersistentDisk() != null + ? getPhotonPersistentDisk() + : new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested editOrNewPhotonPersistentDiskLike(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item) { - return withNewPhotonPersistentDiskLike(getPhotonPersistentDisk() != null ? getPhotonPersistentDisk(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested + editOrNewPhotonPersistentDiskLike( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item) { + return withNewPhotonPersistentDiskLike( + getPhotonPersistentDisk() != null ? getPhotonPersistentDisk() : item); } - + /** * This method has been deprecated, please use method buildPortworxVolume instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PortworxVolumeSource getPortworxVolume() { - return this.portworxVolume!=null ?this.portworxVolume.build():null; + return this.portworxVolume != null ? this.portworxVolume.build() : null; } + public io.kubernetes.client.openapi.models.V1PortworxVolumeSource buildPortworxVolume() { - return this.portworxVolume!=null ?this.portworxVolume.build():null; + return this.portworxVolume != null ? this.portworxVolume.build() : null; } - public A withPortworxVolume(io.kubernetes.client.openapi.models.V1PortworxVolumeSource portworxVolume) { + + public A withPortworxVolume( + io.kubernetes.client.openapi.models.V1PortworxVolumeSource portworxVolume) { _visitables.get("portworxVolume").remove(this.portworxVolume); - if (portworxVolume!=null){ this.portworxVolume= new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder(portworxVolume); _visitables.get("portworxVolume").add(this.portworxVolume);} return (A) this; + if (portworxVolume != null) { + this.portworxVolume = + new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder(portworxVolume); + _visitables.get("portworxVolume").add(this.portworxVolume); + } + return (A) this; } + public java.lang.Boolean hasPortworxVolume() { return this.portworxVolume != null; } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested withNewPortworxVolume() { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested + withNewPortworxVolume() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.PortworxVolumeNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested withNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item) { - return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.PortworxVolumeNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested + withNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item) { + return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.PortworxVolumeNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested editPortworxVolume() { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested + editPortworxVolume() { return withNewPortworxVolumeLike(getPortworxVolume()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested editOrNewPortworxVolume() { - return withNewPortworxVolumeLike(getPortworxVolume() != null ? getPortworxVolume(): new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested + editOrNewPortworxVolume() { + return withNewPortworxVolumeLike( + getPortworxVolume() != null + ? getPortworxVolume() + : new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested editOrNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item) { - return withNewPortworxVolumeLike(getPortworxVolume() != null ? getPortworxVolume(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested + editOrNewPortworxVolumeLike(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item) { + return withNewPortworxVolumeLike(getPortworxVolume() != null ? getPortworxVolume() : item); } - + /** * This method has been deprecated, please use method buildProjected instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ProjectedVolumeSource getProjected() { - return this.projected!=null ?this.projected.build():null; + return this.projected != null ? this.projected.build() : null; } + public io.kubernetes.client.openapi.models.V1ProjectedVolumeSource buildProjected() { - return this.projected!=null ?this.projected.build():null; + return this.projected != null ? this.projected.build() : null; } + public A withProjected(io.kubernetes.client.openapi.models.V1ProjectedVolumeSource projected) { _visitables.get("projected").remove(this.projected); - if (projected!=null){ this.projected= new io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceBuilder(projected); _visitables.get("projected").add(this.projected);} return (A) this; + if (projected != null) { + this.projected = + new io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceBuilder(projected); + _visitables.get("projected").add(this.projected); + } + return (A) this; } + public java.lang.Boolean hasProjected() { return this.projected != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested withNewProjected() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.ProjectedNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested withNewProjectedLike(io.kubernetes.client.openapi.models.V1ProjectedVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested withNewProjectedLike( + io.kubernetes.client.openapi.models.V1ProjectedVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.ProjectedNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested editProjected() { return withNewProjectedLike(getProjected()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested editOrNewProjected() { - return withNewProjectedLike(getProjected() != null ? getProjected(): new io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested + editOrNewProjected() { + return withNewProjectedLike( + getProjected() != null + ? getProjected() + : new io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested editOrNewProjectedLike(io.kubernetes.client.openapi.models.V1ProjectedVolumeSource item) { - return withNewProjectedLike(getProjected() != null ? getProjected(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested + editOrNewProjectedLike(io.kubernetes.client.openapi.models.V1ProjectedVolumeSource item) { + return withNewProjectedLike(getProjected() != null ? getProjected() : item); } - + /** * This method has been deprecated, please use method buildQuobyte instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1QuobyteVolumeSource getQuobyte() { - return this.quobyte!=null ?this.quobyte.build():null; + return this.quobyte != null ? this.quobyte.build() : null; } + public io.kubernetes.client.openapi.models.V1QuobyteVolumeSource buildQuobyte() { - return this.quobyte!=null ?this.quobyte.build():null; + return this.quobyte != null ? this.quobyte.build() : null; } + public A withQuobyte(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource quobyte) { _visitables.get("quobyte").remove(this.quobyte); - if (quobyte!=null){ this.quobyte= new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder(quobyte); _visitables.get("quobyte").add(this.quobyte);} return (A) this; + if (quobyte != null) { + this.quobyte = new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder(quobyte); + _visitables.get("quobyte").add(this.quobyte); + } + return (A) this; } + public java.lang.Boolean hasQuobyte() { return this.quobyte != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested withNewQuobyte() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.QuobyteNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested withNewQuobyteLike(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested withNewQuobyteLike( + io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.QuobyteNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested editQuobyte() { return withNewQuobyteLike(getQuobyte()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested editOrNewQuobyte() { - return withNewQuobyteLike(getQuobyte() != null ? getQuobyte(): new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder().build()); + return withNewQuobyteLike( + getQuobyte() != null + ? getQuobyte() + : new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested editOrNewQuobyteLike(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item) { - return withNewQuobyteLike(getQuobyte() != null ? getQuobyte(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested editOrNewQuobyteLike( + io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item) { + return withNewQuobyteLike(getQuobyte() != null ? getQuobyte() : item); } - + /** * This method has been deprecated, please use method buildRbd instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1RBDVolumeSource getRbd() { - return this.rbd!=null ?this.rbd.build():null; + return this.rbd != null ? this.rbd.build() : null; } + public io.kubernetes.client.openapi.models.V1RBDVolumeSource buildRbd() { - return this.rbd!=null ?this.rbd.build():null; + return this.rbd != null ? this.rbd.build() : null; } + public A withRbd(io.kubernetes.client.openapi.models.V1RBDVolumeSource rbd) { _visitables.get("rbd").remove(this.rbd); - if (rbd!=null){ this.rbd= new io.kubernetes.client.openapi.models.V1RBDVolumeSourceBuilder(rbd); _visitables.get("rbd").add(this.rbd);} return (A) this; + if (rbd != null) { + this.rbd = new io.kubernetes.client.openapi.models.V1RBDVolumeSourceBuilder(rbd); + _visitables.get("rbd").add(this.rbd); + } + return (A) this; } + public java.lang.Boolean hasRbd() { return this.rbd != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested withNewRbd() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.RbdNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested withNewRbdLike(io.kubernetes.client.openapi.models.V1RBDVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested withNewRbdLike( + io.kubernetes.client.openapi.models.V1RBDVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.RbdNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested editRbd() { return withNewRbdLike(getRbd()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested editOrNewRbd() { - return withNewRbdLike(getRbd() != null ? getRbd(): new io.kubernetes.client.openapi.models.V1RBDVolumeSourceBuilder().build()); + return withNewRbdLike( + getRbd() != null + ? getRbd() + : new io.kubernetes.client.openapi.models.V1RBDVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested editOrNewRbdLike(io.kubernetes.client.openapi.models.V1RBDVolumeSource item) { - return withNewRbdLike(getRbd() != null ? getRbd(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested editOrNewRbdLike( + io.kubernetes.client.openapi.models.V1RBDVolumeSource item) { + return withNewRbdLike(getRbd() != null ? getRbd() : item); } - + /** * This method has been deprecated, please use method buildScaleIO instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource getScaleIO() { - return this.scaleIO!=null ?this.scaleIO.build():null; + return this.scaleIO != null ? this.scaleIO.build() : null; } + public io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource buildScaleIO() { - return this.scaleIO!=null ?this.scaleIO.build():null; + return this.scaleIO != null ? this.scaleIO.build() : null; } + public A withScaleIO(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource scaleIO) { _visitables.get("scaleIO").remove(this.scaleIO); - if (scaleIO!=null){ this.scaleIO= new io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceBuilder(scaleIO); _visitables.get("scaleIO").add(this.scaleIO);} return (A) this; + if (scaleIO != null) { + this.scaleIO = new io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceBuilder(scaleIO); + _visitables.get("scaleIO").add(this.scaleIO); + } + return (A) this; } + public java.lang.Boolean hasScaleIO() { return this.scaleIO != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested withNewScaleIO() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.ScaleIONestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested withNewScaleIOLike(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested withNewScaleIOLike( + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.ScaleIONestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested editScaleIO() { return withNewScaleIOLike(getScaleIO()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested editOrNewScaleIO() { - return withNewScaleIOLike(getScaleIO() != null ? getScaleIO(): new io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceBuilder().build()); + return withNewScaleIOLike( + getScaleIO() != null + ? getScaleIO() + : new io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested editOrNewScaleIOLike(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource item) { - return withNewScaleIOLike(getScaleIO() != null ? getScaleIO(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested editOrNewScaleIOLike( + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource item) { + return withNewScaleIOLike(getScaleIO() != null ? getScaleIO() : item); } - + /** * This method has been deprecated, please use method buildSecret instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretVolumeSource getSecret() { - return this.secret!=null ?this.secret.build():null; + return this.secret != null ? this.secret.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretVolumeSource buildSecret() { - return this.secret!=null ?this.secret.build():null; + return this.secret != null ? this.secret.build() : null; } + public A withSecret(io.kubernetes.client.openapi.models.V1SecretVolumeSource secret) { _visitables.get("secret").remove(this.secret); - if (secret!=null){ this.secret= new io.kubernetes.client.openapi.models.V1SecretVolumeSourceBuilder(secret); _visitables.get("secret").add(this.secret);} return (A) this; + if (secret != null) { + this.secret = new io.kubernetes.client.openapi.models.V1SecretVolumeSourceBuilder(secret); + _visitables.get("secret").add(this.secret); + } + return (A) this; } + public java.lang.Boolean hasSecret() { return this.secret != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested withNewSecret() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.SecretNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested withNewSecretLike(io.kubernetes.client.openapi.models.V1SecretVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested withNewSecretLike( + io.kubernetes.client.openapi.models.V1SecretVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.SecretNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested editSecret() { return withNewSecretLike(getSecret()); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested editOrNewSecret() { - return withNewSecretLike(getSecret() != null ? getSecret(): new io.kubernetes.client.openapi.models.V1SecretVolumeSourceBuilder().build()); + return withNewSecretLike( + getSecret() != null + ? getSecret() + : new io.kubernetes.client.openapi.models.V1SecretVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested editOrNewSecretLike(io.kubernetes.client.openapi.models.V1SecretVolumeSource item) { - return withNewSecretLike(getSecret() != null ? getSecret(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested editOrNewSecretLike( + io.kubernetes.client.openapi.models.V1SecretVolumeSource item) { + return withNewSecretLike(getSecret() != null ? getSecret() : item); } - + /** * This method has been deprecated, please use method buildStorageos instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1StorageOSVolumeSource getStorageos() { - return this.storageos!=null ?this.storageos.build():null; + return this.storageos != null ? this.storageos.build() : null; } + public io.kubernetes.client.openapi.models.V1StorageOSVolumeSource buildStorageos() { - return this.storageos!=null ?this.storageos.build():null; + return this.storageos != null ? this.storageos.build() : null; } + public A withStorageos(io.kubernetes.client.openapi.models.V1StorageOSVolumeSource storageos) { _visitables.get("storageos").remove(this.storageos); - if (storageos!=null){ this.storageos= new io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceBuilder(storageos); _visitables.get("storageos").add(this.storageos);} return (A) this; + if (storageos != null) { + this.storageos = + new io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceBuilder(storageos); + _visitables.get("storageos").add(this.storageos); + } + return (A) this; } + public java.lang.Boolean hasStorageos() { return this.storageos != null; } + public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested withNewStorageos() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.StorageosNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested withNewStorageosLike(io.kubernetes.client.openapi.models.V1StorageOSVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested withNewStorageosLike( + io.kubernetes.client.openapi.models.V1StorageOSVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.StorageosNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested editStorageos() { return withNewStorageosLike(getStorageos()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested editOrNewStorageos() { - return withNewStorageosLike(getStorageos() != null ? getStorageos(): new io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested + editOrNewStorageos() { + return withNewStorageosLike( + getStorageos() != null + ? getStorageos() + : new io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested editOrNewStorageosLike(io.kubernetes.client.openapi.models.V1StorageOSVolumeSource item) { - return withNewStorageosLike(getStorageos() != null ? getStorageos(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested + editOrNewStorageosLike(io.kubernetes.client.openapi.models.V1StorageOSVolumeSource item) { + return withNewStorageosLike(getStorageos() != null ? getStorageos() : item); } - + /** * This method has been deprecated, please use method buildVsphereVolume instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource getVsphereVolume() { - return this.vsphereVolume!=null ?this.vsphereVolume.build():null; + return this.vsphereVolume != null ? this.vsphereVolume.build() : null; } + public io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource buildVsphereVolume() { - return this.vsphereVolume!=null ?this.vsphereVolume.build():null; + return this.vsphereVolume != null ? this.vsphereVolume.build() : null; } - public A withVsphereVolume(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource vsphereVolume) { + + public A withVsphereVolume( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource vsphereVolume) { _visitables.get("vsphereVolume").remove(this.vsphereVolume); - if (vsphereVolume!=null){ this.vsphereVolume= new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder(vsphereVolume); _visitables.get("vsphereVolume").add(this.vsphereVolume);} return (A) this; + if (vsphereVolume != null) { + this.vsphereVolume = + new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder( + vsphereVolume); + _visitables.get("vsphereVolume").add(this.vsphereVolume); + } + return (A) this; } + public java.lang.Boolean hasVsphereVolume() { return this.vsphereVolume != null; } - public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested withNewVsphereVolume() { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested + withNewVsphereVolume() { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.VsphereVolumeNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested withNewVsphereVolumeLike(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item) { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested + withNewVsphereVolumeLike( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item) { return new io.kubernetes.client.openapi.models.V1VolumeFluentImpl.VsphereVolumeNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested editVsphereVolume() { + + public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested + editVsphereVolume() { return withNewVsphereVolumeLike(getVsphereVolume()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested editOrNewVsphereVolume() { - return withNewVsphereVolumeLike(getVsphereVolume() != null ? getVsphereVolume(): new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested + editOrNewVsphereVolume() { + return withNewVsphereVolumeLike( + getVsphereVolume() != null + ? getVsphereVolume() + : new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested editOrNewVsphereVolumeLike(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item) { - return withNewVsphereVolumeLike(getVsphereVolume() != null ? getVsphereVolume(): item); + + public io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested + editOrNewVsphereVolumeLike( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item) { + return withNewVsphereVolumeLike(getVsphereVolume() != null ? getVsphereVolume() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1VolumeFluentImpl that = (V1VolumeFluentImpl) o; - if (awsElasticBlockStore != null ? !awsElasticBlockStore.equals(that.awsElasticBlockStore) :that.awsElasticBlockStore != null) return false; - if (azureDisk != null ? !azureDisk.equals(that.azureDisk) :that.azureDisk != null) return false; - if (azureFile != null ? !azureFile.equals(that.azureFile) :that.azureFile != null) return false; - if (cephfs != null ? !cephfs.equals(that.cephfs) :that.cephfs != null) return false; - if (cinder != null ? !cinder.equals(that.cinder) :that.cinder != null) return false; - if (configMap != null ? !configMap.equals(that.configMap) :that.configMap != null) return false; - if (csi != null ? !csi.equals(that.csi) :that.csi != null) return false; - if (downwardAPI != null ? !downwardAPI.equals(that.downwardAPI) :that.downwardAPI != null) return false; - if (emptyDir != null ? !emptyDir.equals(that.emptyDir) :that.emptyDir != null) return false; - if (ephemeral != null ? !ephemeral.equals(that.ephemeral) :that.ephemeral != null) return false; - if (fc != null ? !fc.equals(that.fc) :that.fc != null) return false; - if (flexVolume != null ? !flexVolume.equals(that.flexVolume) :that.flexVolume != null) return false; - if (flocker != null ? !flocker.equals(that.flocker) :that.flocker != null) return false; - if (gcePersistentDisk != null ? !gcePersistentDisk.equals(that.gcePersistentDisk) :that.gcePersistentDisk != null) return false; - if (gitRepo != null ? !gitRepo.equals(that.gitRepo) :that.gitRepo != null) return false; - if (glusterfs != null ? !glusterfs.equals(that.glusterfs) :that.glusterfs != null) return false; - if (hostPath != null ? !hostPath.equals(that.hostPath) :that.hostPath != null) return false; - if (iscsi != null ? !iscsi.equals(that.iscsi) :that.iscsi != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (nfs != null ? !nfs.equals(that.nfs) :that.nfs != null) return false; - if (persistentVolumeClaim != null ? !persistentVolumeClaim.equals(that.persistentVolumeClaim) :that.persistentVolumeClaim != null) return false; - if (photonPersistentDisk != null ? !photonPersistentDisk.equals(that.photonPersistentDisk) :that.photonPersistentDisk != null) return false; - if (portworxVolume != null ? !portworxVolume.equals(that.portworxVolume) :that.portworxVolume != null) return false; - if (projected != null ? !projected.equals(that.projected) :that.projected != null) return false; - if (quobyte != null ? !quobyte.equals(that.quobyte) :that.quobyte != null) return false; - if (rbd != null ? !rbd.equals(that.rbd) :that.rbd != null) return false; - if (scaleIO != null ? !scaleIO.equals(that.scaleIO) :that.scaleIO != null) return false; - if (secret != null ? !secret.equals(that.secret) :that.secret != null) return false; - if (storageos != null ? !storageos.equals(that.storageos) :that.storageos != null) return false; - if (vsphereVolume != null ? !vsphereVolume.equals(that.vsphereVolume) :that.vsphereVolume != null) return false; + if (awsElasticBlockStore != null + ? !awsElasticBlockStore.equals(that.awsElasticBlockStore) + : that.awsElasticBlockStore != null) return false; + if (azureDisk != null ? !azureDisk.equals(that.azureDisk) : that.azureDisk != null) + return false; + if (azureFile != null ? !azureFile.equals(that.azureFile) : that.azureFile != null) + return false; + if (cephfs != null ? !cephfs.equals(that.cephfs) : that.cephfs != null) return false; + if (cinder != null ? !cinder.equals(that.cinder) : that.cinder != null) return false; + if (configMap != null ? !configMap.equals(that.configMap) : that.configMap != null) + return false; + if (csi != null ? !csi.equals(that.csi) : that.csi != null) return false; + if (downwardAPI != null ? !downwardAPI.equals(that.downwardAPI) : that.downwardAPI != null) + return false; + if (emptyDir != null ? !emptyDir.equals(that.emptyDir) : that.emptyDir != null) return false; + if (ephemeral != null ? !ephemeral.equals(that.ephemeral) : that.ephemeral != null) + return false; + if (fc != null ? !fc.equals(that.fc) : that.fc != null) return false; + if (flexVolume != null ? !flexVolume.equals(that.flexVolume) : that.flexVolume != null) + return false; + if (flocker != null ? !flocker.equals(that.flocker) : that.flocker != null) return false; + if (gcePersistentDisk != null + ? !gcePersistentDisk.equals(that.gcePersistentDisk) + : that.gcePersistentDisk != null) return false; + if (gitRepo != null ? !gitRepo.equals(that.gitRepo) : that.gitRepo != null) return false; + if (glusterfs != null ? !glusterfs.equals(that.glusterfs) : that.glusterfs != null) + return false; + if (hostPath != null ? !hostPath.equals(that.hostPath) : that.hostPath != null) return false; + if (iscsi != null ? !iscsi.equals(that.iscsi) : that.iscsi != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (nfs != null ? !nfs.equals(that.nfs) : that.nfs != null) return false; + if (persistentVolumeClaim != null + ? !persistentVolumeClaim.equals(that.persistentVolumeClaim) + : that.persistentVolumeClaim != null) return false; + if (photonPersistentDisk != null + ? !photonPersistentDisk.equals(that.photonPersistentDisk) + : that.photonPersistentDisk != null) return false; + if (portworxVolume != null + ? !portworxVolume.equals(that.portworxVolume) + : that.portworxVolume != null) return false; + if (projected != null ? !projected.equals(that.projected) : that.projected != null) + return false; + if (quobyte != null ? !quobyte.equals(that.quobyte) : that.quobyte != null) return false; + if (rbd != null ? !rbd.equals(that.rbd) : that.rbd != null) return false; + if (scaleIO != null ? !scaleIO.equals(that.scaleIO) : that.scaleIO != null) return false; + if (secret != null ? !secret.equals(that.secret) : that.secret != null) return false; + if (storageos != null ? !storageos.equals(that.storageos) : that.storageos != null) + return false; + if (vsphereVolume != null + ? !vsphereVolume.equals(that.vsphereVolume) + : that.vsphereVolume != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(awsElasticBlockStore, azureDisk, azureFile, cephfs, cinder, configMap, csi, downwardAPI, emptyDir, ephemeral, fc, flexVolume, flocker, gcePersistentDisk, gitRepo, glusterfs, hostPath, iscsi, name, nfs, persistentVolumeClaim, photonPersistentDisk, portworxVolume, projected, quobyte, rbd, scaleIO, secret, storageos, vsphereVolume, super.hashCode()); + return java.util.Objects.hash( + awsElasticBlockStore, + azureDisk, + azureFile, + cephfs, + cinder, + configMap, + csi, + downwardAPI, + emptyDir, + ephemeral, + fc, + flexVolume, + flocker, + gcePersistentDisk, + gitRepo, + glusterfs, + hostPath, + iscsi, + name, + nfs, + persistentVolumeClaim, + photonPersistentDisk, + portworxVolume, + projected, + quobyte, + rbd, + scaleIO, + secret, + storageos, + vsphereVolume, + super.hashCode()); } - public class AwsElasticBlockStoreNestedImpl extends io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested,io.kubernetes.client.fluent.Nested{ - AwsElasticBlockStoreNestedImpl(io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder(this, item); + + public class AwsElasticBlockStoreNestedImpl + extends io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.AwsElasticBlockStoreNested, + io.kubernetes.client.fluent.Nested { + AwsElasticBlockStoreNestedImpl( + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder( + this, item); } + AwsElasticBlockStoreNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1AWSElasticBlockStoreVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withAwsElasticBlockStore(builder.build()); } + public N endAwsElasticBlockStore() { return and(); } - } - public class AzureDiskNestedImpl extends io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested,io.kubernetes.client.fluent.Nested{ + + public class AzureDiskNestedImpl + extends io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.AzureDiskNested, + io.kubernetes.client.fluent.Nested { AzureDiskNestedImpl(io.kubernetes.client.openapi.models.V1AzureDiskVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder(this, item); } + AzureDiskNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1AzureDiskVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withAzureDisk(builder.build()); } + public N endAzureDisk() { return and(); } - } - public class AzureFileNestedImpl extends io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested,io.kubernetes.client.fluent.Nested{ + + public class AzureFileNestedImpl + extends io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.AzureFileNested, + io.kubernetes.client.fluent.Nested { AzureFileNestedImpl(io.kubernetes.client.openapi.models.V1AzureFileVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceBuilder(this, item); } + AzureFileNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1AzureFileVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withAzureFile(builder.build()); } + public N endAzureFile() { return and(); } - } - public class CephfsNestedImpl extends io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested,io.kubernetes.client.fluent.Nested{ + + public class CephfsNestedImpl + extends io.kubernetes.client.openapi.models.V1CephFSVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.CephfsNested, + io.kubernetes.client.fluent.Nested { CephfsNestedImpl(io.kubernetes.client.openapi.models.V1CephFSVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1CephFSVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CephFSVolumeSourceBuilder(this, item); } + CephfsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1CephFSVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1CephFSVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withCephfs(builder.build()); } + public N endCephfs() { return and(); } - } - public class CinderNestedImpl extends io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested,io.kubernetes.client.fluent.Nested{ + + public class CinderNestedImpl + extends io.kubernetes.client.openapi.models.V1CinderVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.CinderNested, + io.kubernetes.client.fluent.Nested { CinderNestedImpl(io.kubernetes.client.openapi.models.V1CinderVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1CinderVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1CinderVolumeSourceBuilder(this, item); } + CinderNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1CinderVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1CinderVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withCinder(builder.build()); } + public N endCinder() { return and(); } - } - public class ConfigMapNestedImpl extends io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested,io.kubernetes.client.fluent.Nested{ + + public class ConfigMapNestedImpl + extends io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.ConfigMapNested, + io.kubernetes.client.fluent.Nested { ConfigMapNestedImpl(io.kubernetes.client.openapi.models.V1ConfigMapVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceBuilder(this, item); } + ConfigMapNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1ConfigMapVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withConfigMap(builder.build()); } + public N endConfigMap() { return and(); } - } - public class CsiNestedImpl extends io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested,io.kubernetes.client.fluent.Nested{ + + public class CsiNestedImpl + extends io.kubernetes.client.openapi.models.V1CSIVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.CsiNested, + io.kubernetes.client.fluent.Nested { CsiNestedImpl(io.kubernetes.client.openapi.models.V1CSIVolumeSource item) { this.builder = new io.kubernetes.client.openapi.models.V1CSIVolumeSourceBuilder(this, item); } + CsiNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1CSIVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1CSIVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withCsi(builder.build()); } + public N endCsi() { return and(); } - } - public class DownwardAPINestedImpl extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested,io.kubernetes.client.fluent.Nested{ + + public class DownwardAPINestedImpl + extends io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.DownwardAPINested, + io.kubernetes.client.fluent.Nested { DownwardAPINestedImpl(io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceBuilder(this, item); } + DownwardAPINestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1DownwardAPIVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withDownwardAPI(builder.build()); } + public N endDownwardAPI() { return and(); } - } - public class EmptyDirNestedImpl extends io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested,io.kubernetes.client.fluent.Nested{ + + public class EmptyDirNestedImpl + extends io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.EmptyDirNested, + io.kubernetes.client.fluent.Nested { EmptyDirNestedImpl(io.kubernetes.client.openapi.models.V1EmptyDirVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceBuilder(this, item); } + EmptyDirNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1EmptyDirVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withEmptyDir(builder.build()); } + public N endEmptyDir() { return and(); } - } - public class EphemeralNestedImpl extends io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested,io.kubernetes.client.fluent.Nested{ + + public class EphemeralNestedImpl + extends io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.EphemeralNested, + io.kubernetes.client.fluent.Nested { EphemeralNestedImpl(io.kubernetes.client.openapi.models.V1EphemeralVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceBuilder(this, item); } + EphemeralNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1EphemeralVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withEphemeral(builder.build()); } + public N endEphemeral() { return and(); } - } - public class FcNestedImpl extends io.kubernetes.client.openapi.models.V1FCVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested,io.kubernetes.client.fluent.Nested{ + + public class FcNestedImpl + extends io.kubernetes.client.openapi.models.V1FCVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.FcNested, + io.kubernetes.client.fluent.Nested { FcNestedImpl(io.kubernetes.client.openapi.models.V1FCVolumeSource item) { this.builder = new io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder(this, item); } + FcNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1FCVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withFc(builder.build()); } + public N endFc() { return and(); } - } - public class FlexVolumeNestedImpl extends io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested,io.kubernetes.client.fluent.Nested{ + + public class FlexVolumeNestedImpl + extends io.kubernetes.client.openapi.models.V1FlexVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.FlexVolumeNested, + io.kubernetes.client.fluent.Nested { FlexVolumeNestedImpl(io.kubernetes.client.openapi.models.V1FlexVolumeSource item) { this.builder = new io.kubernetes.client.openapi.models.V1FlexVolumeSourceBuilder(this, item); } + FlexVolumeNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1FlexVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1FlexVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withFlexVolume(builder.build()); } + public N endFlexVolume() { return and(); } - } - public class FlockerNestedImpl extends io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested,io.kubernetes.client.fluent.Nested{ + + public class FlockerNestedImpl + extends io.kubernetes.client.openapi.models.V1FlockerVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.FlockerNested, + io.kubernetes.client.fluent.Nested { FlockerNestedImpl(io.kubernetes.client.openapi.models.V1FlockerVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder(this, item); } + FlockerNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1FlockerVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withFlocker(builder.build()); } + public N endFlocker() { return and(); } - } - public class GcePersistentDiskNestedImpl extends io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested,io.kubernetes.client.fluent.Nested{ - GcePersistentDiskNestedImpl(io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder(this, item); + + public class GcePersistentDiskNestedImpl + extends io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.GcePersistentDiskNested, + io.kubernetes.client.fluent.Nested { + GcePersistentDiskNestedImpl( + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder( + this, item); } + GcePersistentDiskNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1GCEPersistentDiskVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withGcePersistentDisk(builder.build()); } + public N endGcePersistentDisk() { return and(); } - } - public class GitRepoNestedImpl extends io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested,io.kubernetes.client.fluent.Nested{ + + public class GitRepoNestedImpl + extends io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.GitRepoNested, + io.kubernetes.client.fluent.Nested { GitRepoNestedImpl(io.kubernetes.client.openapi.models.V1GitRepoVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceBuilder(this, item); } + GitRepoNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1GitRepoVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withGitRepo(builder.build()); } + public N endGitRepo() { return and(); } - } - public class GlusterfsNestedImpl extends io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested,io.kubernetes.client.fluent.Nested{ + + public class GlusterfsNestedImpl + extends io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.GlusterfsNested, + io.kubernetes.client.fluent.Nested { GlusterfsNestedImpl(io.kubernetes.client.openapi.models.V1GlusterfsVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceBuilder(this, item); } + GlusterfsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1GlusterfsVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withGlusterfs(builder.build()); } + public N endGlusterfs() { return and(); } - } - public class HostPathNestedImpl extends io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested,io.kubernetes.client.fluent.Nested{ + + public class HostPathNestedImpl + extends io.kubernetes.client.openapi.models.V1HostPathVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.HostPathNested, + io.kubernetes.client.fluent.Nested { HostPathNestedImpl(io.kubernetes.client.openapi.models.V1HostPathVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder(this, item); } + HostPathNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1HostPathVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withHostPath(builder.build()); } + public N endHostPath() { return and(); } - } - public class IscsiNestedImpl extends io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested,io.kubernetes.client.fluent.Nested{ + + public class IscsiNestedImpl + extends io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.IscsiNested, + io.kubernetes.client.fluent.Nested { IscsiNestedImpl(io.kubernetes.client.openapi.models.V1ISCSIVolumeSource item) { this.builder = new io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceBuilder(this, item); } + IscsiNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1ISCSIVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withIscsi(builder.build()); } + public N endIscsi() { return and(); } - } - public class NfsNestedImpl extends io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested,io.kubernetes.client.fluent.Nested{ + + public class NfsNestedImpl + extends io.kubernetes.client.openapi.models.V1NFSVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.NfsNested, + io.kubernetes.client.fluent.Nested { NfsNestedImpl(io.kubernetes.client.openapi.models.V1NFSVolumeSource item) { this.builder = new io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder(this, item); } + NfsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1NFSVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withNfs(builder.build()); } + public N endNfs() { return and(); } - } - public class PersistentVolumeClaimNestedImpl extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested,io.kubernetes.client.fluent.Nested{ - PersistentVolumeClaimNestedImpl(io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceBuilder(this, item); + + public class PersistentVolumeClaimNestedImpl + extends io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.PersistentVolumeClaimNested, + io.kubernetes.client.fluent.Nested { + PersistentVolumeClaimNestedImpl( + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceBuilder( + this, item); } + PersistentVolumeClaimNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1PersistentVolumeClaimVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withPersistentVolumeClaim(builder.build()); } + public N endPersistentVolumeClaim() { return and(); } - } - public class PhotonPersistentDiskNestedImpl extends io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested,io.kubernetes.client.fluent.Nested{ - PhotonPersistentDiskNestedImpl(io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder(this, item); + + public class PhotonPersistentDiskNestedImpl + extends io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.PhotonPersistentDiskNested, + io.kubernetes.client.fluent.Nested { + PhotonPersistentDiskNestedImpl( + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder( + this, item); } + PhotonPersistentDiskNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1PhotonPersistentDiskVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withPhotonPersistentDisk(builder.build()); } + public N endPhotonPersistentDisk() { return and(); } - } - public class PortworxVolumeNestedImpl extends io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested,io.kubernetes.client.fluent.Nested{ + + public class PortworxVolumeNestedImpl + extends io.kubernetes.client.openapi.models.V1PortworxVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.PortworxVolumeNested, + io.kubernetes.client.fluent.Nested { PortworxVolumeNestedImpl(io.kubernetes.client.openapi.models.V1PortworxVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder(this, item); } + PortworxVolumeNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1PortworxVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withPortworxVolume(builder.build()); } + public N endPortworxVolume() { return and(); } - } - public class ProjectedNestedImpl extends io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested,io.kubernetes.client.fluent.Nested{ + + public class ProjectedNestedImpl + extends io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.ProjectedNested, + io.kubernetes.client.fluent.Nested { ProjectedNestedImpl(io.kubernetes.client.openapi.models.V1ProjectedVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceBuilder(this, item); } + ProjectedNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1ProjectedVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withProjected(builder.build()); } + public N endProjected() { return and(); } - } - public class QuobyteNestedImpl extends io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested,io.kubernetes.client.fluent.Nested{ + + public class QuobyteNestedImpl + extends io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.QuobyteNested, + io.kubernetes.client.fluent.Nested { QuobyteNestedImpl(io.kubernetes.client.openapi.models.V1QuobyteVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder(this, item); } + QuobyteNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1QuobyteVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withQuobyte(builder.build()); } + public N endQuobyte() { return and(); } - } - public class RbdNestedImpl extends io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested,io.kubernetes.client.fluent.Nested{ + + public class RbdNestedImpl + extends io.kubernetes.client.openapi.models.V1RBDVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.RbdNested, + io.kubernetes.client.fluent.Nested { RbdNestedImpl(io.kubernetes.client.openapi.models.V1RBDVolumeSource item) { this.builder = new io.kubernetes.client.openapi.models.V1RBDVolumeSourceBuilder(this, item); } + RbdNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1RBDVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1RBDVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withRbd(builder.build()); } + public N endRbd() { return and(); } - } - public class ScaleIONestedImpl extends io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested,io.kubernetes.client.fluent.Nested{ + + public class ScaleIONestedImpl + extends io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.ScaleIONested, + io.kubernetes.client.fluent.Nested { ScaleIONestedImpl(io.kubernetes.client.openapi.models.V1ScaleIOVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceBuilder(this, item); } + ScaleIONestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1ScaleIOVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withScaleIO(builder.build()); } + public N endScaleIO() { return and(); } - } - public class SecretNestedImpl extends io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested,io.kubernetes.client.fluent.Nested{ + + public class SecretNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.SecretNested, + io.kubernetes.client.fluent.Nested { SecretNestedImpl(io.kubernetes.client.openapi.models.V1SecretVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1SecretVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1SecretVolumeSourceBuilder(this, item); } + SecretNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withSecret(builder.build()); } + public N endSecret() { return and(); } - } - public class StorageosNestedImpl extends io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested,io.kubernetes.client.fluent.Nested{ + + public class StorageosNestedImpl + extends io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.StorageosNested, + io.kubernetes.client.fluent.Nested { StorageosNestedImpl(io.kubernetes.client.openapi.models.V1StorageOSVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceBuilder(this, item); } + StorageosNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1StorageOSVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withStorageos(builder.build()); } + public N endStorageos() { return and(); } - } - public class VsphereVolumeNestedImpl extends io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested,io.kubernetes.client.fluent.Nested{ - VsphereVolumeNestedImpl(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item) { - this.builder = new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder(this, item); + + public class VsphereVolumeNestedImpl + extends io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested> + implements io.kubernetes.client.openapi.models.V1VolumeFluent.VsphereVolumeNested, + io.kubernetes.client.fluent.Nested { + VsphereVolumeNestedImpl( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder( + this, item); } + VsphereVolumeNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder builder; + public N and() { return (N) V1VolumeFluentImpl.this.withVsphereVolume(builder.build()); } + public N endVsphereVolume() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeMountBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeMountBuilder.java index 4d76b46a63..068fb24baf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeMountBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeMountBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1VolumeMountBuilder extends io.kubernetes.client.openapi.models.V1VolumeMountFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1VolumeMountBuilder + extends io.kubernetes.client.openapi.models.V1VolumeMountFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeMountBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1VolumeMount, + io.kubernetes.client.openapi.models.V1VolumeMountBuilder> { public V1VolumeMountBuilder() { this(false); } + public V1VolumeMountBuilder(java.lang.Boolean validationEnabled) { this(new V1VolumeMount(), validationEnabled); } + public V1VolumeMountBuilder(io.kubernetes.client.openapi.models.V1VolumeMountFluent fluent) { this(fluent, false); } - public V1VolumeMountBuilder(io.kubernetes.client.openapi.models.V1VolumeMountFluent fluent,java.lang.Boolean validationEnabled) { + + public V1VolumeMountBuilder( + io.kubernetes.client.openapi.models.V1VolumeMountFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1VolumeMount(), validationEnabled); } - public V1VolumeMountBuilder(io.kubernetes.client.openapi.models.V1VolumeMountFluent fluent,io.kubernetes.client.openapi.models.V1VolumeMount instance) { + + public V1VolumeMountBuilder( + io.kubernetes.client.openapi.models.V1VolumeMountFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeMount instance) { this(fluent, instance, false); } - public V1VolumeMountBuilder(io.kubernetes.client.openapi.models.V1VolumeMountFluent fluent,io.kubernetes.client.openapi.models.V1VolumeMount instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1VolumeMountBuilder( + io.kubernetes.client.openapi.models.V1VolumeMountFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeMount instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMountPath(instance.getMountPath()); fluent.withMountPropagation(instance.getMountPropagation()); @@ -33,13 +59,17 @@ public V1VolumeMountBuilder(io.kubernetes.client.openapi.models.V1VolumeMountFlu fluent.withSubPathExpr(instance.getSubPathExpr()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1VolumeMountBuilder(io.kubernetes.client.openapi.models.V1VolumeMount instance) { - this(instance,false); + this(instance, false); } - public V1VolumeMountBuilder(io.kubernetes.client.openapi.models.V1VolumeMount instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1VolumeMountBuilder( + io.kubernetes.client.openapi.models.V1VolumeMount instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMountPath(instance.getMountPath()); this.withMountPropagation(instance.getMountPropagation()); @@ -52,10 +82,12 @@ public V1VolumeMountBuilder(io.kubernetes.client.openapi.models.V1VolumeMount in this.withSubPathExpr(instance.getSubPathExpr()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1VolumeMountFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1VolumeMount build() { V1VolumeMount buildable = new V1VolumeMount(); buildable.setMountPath(fluent.getMountPath()); @@ -66,18 +98,23 @@ public io.kubernetes.client.openapi.models.V1VolumeMount build() { buildable.setSubPathExpr(fluent.getSubPathExpr()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1VolumeMountBuilder that = (V1VolumeMountBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeMountFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeMountFluent.java index e888e02053..6fcce1fea3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeMountFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeMountFluent.java @@ -1,62 +1,74 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1VolumeMountFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1VolumeMountFluent< + A extends io.kubernetes.client.openapi.models.V1VolumeMountFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getMountPath(); + public A withMountPath(java.lang.String mountPath); + public java.lang.Boolean hasMountPath(); - - /** - * Method is deprecated. use withMountPath instead. - */ + + /** Method is deprecated. use withMountPath instead. */ @java.lang.Deprecated public A withNewMountPath(java.lang.String original); + public java.lang.String getMountPropagation(); + public A withMountPropagation(java.lang.String mountPropagation); + public java.lang.Boolean hasMountPropagation(); - - /** - * Method is deprecated. use withMountPropagation instead. - */ + + /** Method is deprecated. use withMountPropagation instead. */ @java.lang.Deprecated public A withNewMountPropagation(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); + public java.lang.String getSubPath(); + public A withSubPath(java.lang.String subPath); + public java.lang.Boolean hasSubPath(); - - /** - * Method is deprecated. use withSubPath instead. - */ + + /** Method is deprecated. use withSubPath instead. */ @java.lang.Deprecated public A withNewSubPath(java.lang.String original); + public java.lang.String getSubPathExpr(); + public A withSubPathExpr(java.lang.String subPathExpr); + public java.lang.Boolean hasSubPathExpr(); - - /** - * Method is deprecated. use withSubPathExpr instead. - */ + + /** Method is deprecated. use withSubPathExpr instead. */ @java.lang.Deprecated public A withNewSubPathExpr(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeMountFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeMountFluentImpl.java index 1540c27909..10d6d42477 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeMountFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeMountFluentImpl.java @@ -1,17 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1VolumeMountFluentImpl< + A extends io.kubernetes.client.openapi.models.V1VolumeMountFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1VolumeMountFluent { + public V1VolumeMountFluentImpl() {} - /** - * Generated - */ -public class V1VolumeMountFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1VolumeMountFluent{ - public V1VolumeMountFluentImpl() { - } public V1VolumeMountFluentImpl(io.kubernetes.client.openapi.models.V1VolumeMount instance) { this.withMountPath(instance.getMountPath()); @@ -24,122 +31,142 @@ public V1VolumeMountFluentImpl(io.kubernetes.client.openapi.models.V1VolumeMount this.withSubPath(instance.getSubPath()); this.withSubPathExpr(instance.getSubPathExpr()); - } + private java.lang.String mountPath; private java.lang.String mountPropagation; private java.lang.String name; private java.lang.Boolean readOnly; private java.lang.String subPath; private java.lang.String subPathExpr; + public java.lang.String getMountPath() { return this.mountPath; } + public A withMountPath(java.lang.String mountPath) { - this.mountPath=mountPath; return (A) this; + this.mountPath = mountPath; + return (A) this; } + public java.lang.Boolean hasMountPath() { return this.mountPath != null; } - - /** - * Method is deprecated. use withMountPath instead. - */ + + /** Method is deprecated. use withMountPath instead. */ @java.lang.Deprecated public A withNewMountPath(java.lang.String original) { - return (A)withMountPath(new String(original)); + return (A) withMountPath(new String(original)); } + public java.lang.String getMountPropagation() { return this.mountPropagation; } + public A withMountPropagation(java.lang.String mountPropagation) { - this.mountPropagation=mountPropagation; return (A) this; + this.mountPropagation = mountPropagation; + return (A) this; } + public java.lang.Boolean hasMountPropagation() { return this.mountPropagation != null; } - - /** - * Method is deprecated. use withMountPropagation instead. - */ + + /** Method is deprecated. use withMountPropagation instead. */ @java.lang.Deprecated public A withNewMountPropagation(java.lang.String original) { - return (A)withMountPropagation(new String(original)); + return (A) withMountPropagation(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public java.lang.String getSubPath() { return this.subPath; } + public A withSubPath(java.lang.String subPath) { - this.subPath=subPath; return (A) this; + this.subPath = subPath; + return (A) this; } + public java.lang.Boolean hasSubPath() { return this.subPath != null; } - - /** - * Method is deprecated. use withSubPath instead. - */ + + /** Method is deprecated. use withSubPath instead. */ @java.lang.Deprecated public A withNewSubPath(java.lang.String original) { - return (A)withSubPath(new String(original)); + return (A) withSubPath(new String(original)); } + public java.lang.String getSubPathExpr() { return this.subPathExpr; } + public A withSubPathExpr(java.lang.String subPathExpr) { - this.subPathExpr=subPathExpr; return (A) this; + this.subPathExpr = subPathExpr; + return (A) this; } + public java.lang.Boolean hasSubPathExpr() { return this.subPathExpr != null; } - - /** - * Method is deprecated. use withSubPathExpr instead. - */ + + /** Method is deprecated. use withSubPathExpr instead. */ @java.lang.Deprecated public A withNewSubPathExpr(java.lang.String original) { - return (A)withSubPathExpr(new String(original)); + return (A) withSubPathExpr(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1VolumeMountFluentImpl that = (V1VolumeMountFluentImpl) o; - if (mountPath != null ? !mountPath.equals(that.mountPath) :that.mountPath != null) return false; - if (mountPropagation != null ? !mountPropagation.equals(that.mountPropagation) :that.mountPropagation != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; - if (subPath != null ? !subPath.equals(that.subPath) :that.subPath != null) return false; - if (subPathExpr != null ? !subPathExpr.equals(that.subPathExpr) :that.subPathExpr != null) return false; + if (mountPath != null ? !mountPath.equals(that.mountPath) : that.mountPath != null) + return false; + if (mountPropagation != null + ? !mountPropagation.equals(that.mountPropagation) + : that.mountPropagation != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; + if (subPath != null ? !subPath.equals(that.subPath) : that.subPath != null) return false; + if (subPathExpr != null ? !subPathExpr.equals(that.subPathExpr) : that.subPathExpr != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(mountPath, mountPropagation, name, readOnly, subPath, subPathExpr, super.hashCode()); + return java.util.Objects.hash( + mountPath, mountPropagation, name, readOnly, subPath, subPathExpr, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeAffinityBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeAffinityBuilder.java index 608b732e68..609c91b7d2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeAffinityBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeAffinityBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1VolumeNodeAffinityBuilder extends io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1VolumeNodeAffinityBuilder + extends io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeNodeAffinityBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1VolumeNodeAffinity, + io.kubernetes.client.openapi.models.V1VolumeNodeAffinityBuilder> { public V1VolumeNodeAffinityBuilder() { this(false); } + public V1VolumeNodeAffinityBuilder(java.lang.Boolean validationEnabled) { this(new V1VolumeNodeAffinity(), validationEnabled); } - public V1VolumeNodeAffinityBuilder(io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent fluent) { + + public V1VolumeNodeAffinityBuilder( + io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent fluent) { this(fluent, false); } - public V1VolumeNodeAffinityBuilder(io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent fluent,java.lang.Boolean validationEnabled) { + + public V1VolumeNodeAffinityBuilder( + io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1VolumeNodeAffinity(), validationEnabled); } - public V1VolumeNodeAffinityBuilder(io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent fluent,io.kubernetes.client.openapi.models.V1VolumeNodeAffinity instance) { + + public V1VolumeNodeAffinityBuilder( + io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeNodeAffinity instance) { this(fluent, instance, false); } - public V1VolumeNodeAffinityBuilder(io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent fluent,io.kubernetes.client.openapi.models.V1VolumeNodeAffinity instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1VolumeNodeAffinityBuilder( + io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeNodeAffinity instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withRequired(instance.getRequired()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1VolumeNodeAffinityBuilder(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity instance) { - this(instance,false); + + public V1VolumeNodeAffinityBuilder( + io.kubernetes.client.openapi.models.V1VolumeNodeAffinity instance) { + this(instance, false); } - public V1VolumeNodeAffinityBuilder(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1VolumeNodeAffinityBuilder( + io.kubernetes.client.openapi.models.V1VolumeNodeAffinity instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withRequired(instance.getRequired()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1VolumeNodeAffinity build() { V1VolumeNodeAffinity buildable = new V1VolumeNodeAffinity(); buildable.setRequired(fluent.getRequired()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1VolumeNodeAffinityBuilder that = (V1VolumeNodeAffinityBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeAffinityFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeAffinityFluent.java index 03991926bd..ab5d9a0199 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeAffinityFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeAffinityFluent.java @@ -1,35 +1,57 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1VolumeNodeAffinityFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1VolumeNodeAffinityFluent< + A extends io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildRequired instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeSelector getRequired(); + public io.kubernetes.client.openapi.models.V1NodeSelector buildRequired(); + public A withRequired(io.kubernetes.client.openapi.models.V1NodeSelector required); + public java.lang.Boolean hasRequired(); - public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested withNewRequired(); - public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested withNewRequiredLike(io.kubernetes.client.openapi.models.V1NodeSelector item); - public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested editRequired(); - public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested editOrNewRequired(); - public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested editOrNewRequiredLike(io.kubernetes.client.openapi.models.V1NodeSelector item); - public interface RequiredNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1NodeSelectorFluent>{ + + public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested + withNewRequired(); + + public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested + withNewRequiredLike(io.kubernetes.client.openapi.models.V1NodeSelector item); + + public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested + editRequired(); + + public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested + editOrNewRequired(); + + public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested + editOrNewRequiredLike(io.kubernetes.client.openapi.models.V1NodeSelector item); + + public interface RequiredNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1NodeSelectorFluent< + io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested> { public N and(); + public N endRequired(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeAffinityFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeAffinityFluentImpl.java index 5f39eaaaf6..68b1eef397 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeAffinityFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeAffinityFluentImpl.java @@ -1,81 +1,121 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1VolumeNodeAffinityFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent{ - public V1VolumeNodeAffinityFluentImpl() { - } - public V1VolumeNodeAffinityFluentImpl(io.kubernetes.client.openapi.models.V1VolumeNodeAffinity instance) { - this.withRequired(instance.getRequired()); +/** Generated */ +public class V1VolumeNodeAffinityFluentImpl< + A extends io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent { + public V1VolumeNodeAffinityFluentImpl() {} + public V1VolumeNodeAffinityFluentImpl( + io.kubernetes.client.openapi.models.V1VolumeNodeAffinity instance) { + this.withRequired(instance.getRequired()); } + private io.kubernetes.client.openapi.models.V1NodeSelectorBuilder required; - + /** * This method has been deprecated, please use method buildRequired instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1NodeSelector getRequired() { - return this.required!=null ?this.required.build():null; + return this.required != null ? this.required.build() : null; } + public io.kubernetes.client.openapi.models.V1NodeSelector buildRequired() { - return this.required!=null ?this.required.build():null; + return this.required != null ? this.required.build() : null; } + public A withRequired(io.kubernetes.client.openapi.models.V1NodeSelector required) { _visitables.get("required").remove(this.required); - if (required!=null){ this.required= new io.kubernetes.client.openapi.models.V1NodeSelectorBuilder(required); _visitables.get("required").add(this.required);} return (A) this; + if (required != null) { + this.required = new io.kubernetes.client.openapi.models.V1NodeSelectorBuilder(required); + _visitables.get("required").add(this.required); + } + return (A) this; } + public java.lang.Boolean hasRequired() { return this.required != null; } - public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested withNewRequired() { - return new io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluentImpl.RequiredNestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested + withNewRequired() { + return new io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluentImpl + .RequiredNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested withNewRequiredLike(io.kubernetes.client.openapi.models.V1NodeSelector item) { - return new io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluentImpl.RequiredNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested + withNewRequiredLike(io.kubernetes.client.openapi.models.V1NodeSelector item) { + return new io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluentImpl + .RequiredNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested editRequired() { + + public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested + editRequired() { return withNewRequiredLike(getRequired()); } - public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested editOrNewRequired() { - return withNewRequiredLike(getRequired() != null ? getRequired(): new io.kubernetes.client.openapi.models.V1NodeSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested + editOrNewRequired() { + return withNewRequiredLike( + getRequired() != null + ? getRequired() + : new io.kubernetes.client.openapi.models.V1NodeSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested editOrNewRequiredLike(io.kubernetes.client.openapi.models.V1NodeSelector item) { - return withNewRequiredLike(getRequired() != null ? getRequired(): item); + + public io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested + editOrNewRequiredLike(io.kubernetes.client.openapi.models.V1NodeSelector item) { + return withNewRequiredLike(getRequired() != null ? getRequired() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1VolumeNodeAffinityFluentImpl that = (V1VolumeNodeAffinityFluentImpl) o; - if (required != null ? !required.equals(that.required) :that.required != null) return false; + if (required != null ? !required.equals(that.required) : that.required != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(required, super.hashCode()); + return java.util.Objects.hash(required, super.hashCode()); } - public class RequiredNestedImpl extends io.kubernetes.client.openapi.models.V1NodeSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested,io.kubernetes.client.fluent.Nested{ + + public class RequiredNestedImpl + extends io.kubernetes.client.openapi.models.V1NodeSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested> + implements io.kubernetes.client.openapi.models.V1VolumeNodeAffinityFluent.RequiredNested, + io.kubernetes.client.fluent.Nested { RequiredNestedImpl(io.kubernetes.client.openapi.models.V1NodeSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1NodeSelectorBuilder(this, item); } + RequiredNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1NodeSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1NodeSelectorBuilder builder; + public N and() { return (N) V1VolumeNodeAffinityFluentImpl.this.withRequired(builder.build()); } + public N endRequired() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeResourcesBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeResourcesBuilder.java index 2b5271b8a2..1e9236ec28 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeResourcesBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeResourcesBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1VolumeNodeResourcesBuilder extends io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1VolumeNodeResourcesBuilder + extends io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeNodeResourcesBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1VolumeNodeResources, + io.kubernetes.client.openapi.models.V1VolumeNodeResourcesBuilder> { public V1VolumeNodeResourcesBuilder() { this(false); } + public V1VolumeNodeResourcesBuilder(java.lang.Boolean validationEnabled) { this(new V1VolumeNodeResources(), validationEnabled); } - public V1VolumeNodeResourcesBuilder(io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent fluent) { + + public V1VolumeNodeResourcesBuilder( + io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent fluent) { this(fluent, false); } - public V1VolumeNodeResourcesBuilder(io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent fluent,java.lang.Boolean validationEnabled) { + + public V1VolumeNodeResourcesBuilder( + io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1VolumeNodeResources(), validationEnabled); } - public V1VolumeNodeResourcesBuilder(io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent fluent,io.kubernetes.client.openapi.models.V1VolumeNodeResources instance) { + + public V1VolumeNodeResourcesBuilder( + io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeNodeResources instance) { this(fluent, instance, false); } - public V1VolumeNodeResourcesBuilder(io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent fluent,io.kubernetes.client.openapi.models.V1VolumeNodeResources instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1VolumeNodeResourcesBuilder( + io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeNodeResources instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCount(instance.getCount()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1VolumeNodeResourcesBuilder(io.kubernetes.client.openapi.models.V1VolumeNodeResources instance) { - this(instance,false); + + public V1VolumeNodeResourcesBuilder( + io.kubernetes.client.openapi.models.V1VolumeNodeResources instance) { + this(instance, false); } - public V1VolumeNodeResourcesBuilder(io.kubernetes.client.openapi.models.V1VolumeNodeResources instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1VolumeNodeResourcesBuilder( + io.kubernetes.client.openapi.models.V1VolumeNodeResources instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCount(instance.getCount()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1VolumeNodeResources build() { V1VolumeNodeResources buildable = new V1VolumeNodeResources(); buildable.setCount(fluent.getCount()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1VolumeNodeResourcesBuilder that = (V1VolumeNodeResourcesBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeResourcesFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeResourcesFluent.java index 31afd982fb..c54e90b7c3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeResourcesFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeResourcesFluent.java @@ -1,17 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1VolumeNodeResourcesFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1VolumeNodeResourcesFluent< + A extends io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getCount(); + public A withCount(java.lang.Integer count); + public java.lang.Boolean hasCount(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeResourcesFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeResourcesFluentImpl.java index aca62304ca..75bf4f323d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeResourcesFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeNodeResourcesFluentImpl.java @@ -1,39 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1VolumeNodeResourcesFluentImpl< + A extends io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent { + public V1VolumeNodeResourcesFluentImpl() {} - /** - * Generated - */ -public class V1VolumeNodeResourcesFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1VolumeNodeResourcesFluent{ - public V1VolumeNodeResourcesFluentImpl() { - } - public V1VolumeNodeResourcesFluentImpl(io.kubernetes.client.openapi.models.V1VolumeNodeResources instance) { + public V1VolumeNodeResourcesFluentImpl( + io.kubernetes.client.openapi.models.V1VolumeNodeResources instance) { this.withCount(instance.getCount()); - } + private java.lang.Integer count; + public java.lang.Integer getCount() { return this.count; } + public A withCount(java.lang.Integer count) { - this.count=count; return (A) this; + this.count = count; + return (A) this; } + public java.lang.Boolean hasCount() { return this.count != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1VolumeNodeResourcesFluentImpl that = (V1VolumeNodeResourcesFluentImpl) o; - if (count != null ? !count.equals(that.count) :that.count != null) return false; + if (count != null ? !count.equals(that.count) : that.count != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(count, super.hashCode()); + return java.util.Objects.hash(count, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeProjectionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeProjectionBuilder.java index 8a51c045bc..c8a7ec2ea5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeProjectionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeProjectionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1VolumeProjectionBuilder extends io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1VolumeProjectionBuilder + extends io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1VolumeProjection, + io.kubernetes.client.openapi.models.V1VolumeProjectionBuilder> { public V1VolumeProjectionBuilder() { this(false); } + public V1VolumeProjectionBuilder(java.lang.Boolean validationEnabled) { this(new V1VolumeProjection(), validationEnabled); } - public V1VolumeProjectionBuilder(io.kubernetes.client.openapi.models.V1VolumeProjectionFluent fluent) { + + public V1VolumeProjectionBuilder( + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent fluent) { this(fluent, false); } - public V1VolumeProjectionBuilder(io.kubernetes.client.openapi.models.V1VolumeProjectionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1VolumeProjectionBuilder( + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1VolumeProjection(), validationEnabled); } - public V1VolumeProjectionBuilder(io.kubernetes.client.openapi.models.V1VolumeProjectionFluent fluent,io.kubernetes.client.openapi.models.V1VolumeProjection instance) { + + public V1VolumeProjectionBuilder( + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeProjection instance) { this(fluent, instance, false); } - public V1VolumeProjectionBuilder(io.kubernetes.client.openapi.models.V1VolumeProjectionFluent fluent,io.kubernetes.client.openapi.models.V1VolumeProjection instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1VolumeProjectionBuilder( + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent fluent, + io.kubernetes.client.openapi.models.V1VolumeProjection instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConfigMap(instance.getConfigMap()); fluent.withDownwardAPI(instance.getDownwardAPI()); @@ -29,13 +56,18 @@ public V1VolumeProjectionBuilder(io.kubernetes.client.openapi.models.V1VolumePro fluent.withServiceAccountToken(instance.getServiceAccountToken()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1VolumeProjectionBuilder(io.kubernetes.client.openapi.models.V1VolumeProjection instance) { - this(instance,false); + + public V1VolumeProjectionBuilder( + io.kubernetes.client.openapi.models.V1VolumeProjection instance) { + this(instance, false); } - public V1VolumeProjectionBuilder(io.kubernetes.client.openapi.models.V1VolumeProjection instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1VolumeProjectionBuilder( + io.kubernetes.client.openapi.models.V1VolumeProjection instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConfigMap(instance.getConfigMap()); this.withDownwardAPI(instance.getDownwardAPI()); @@ -44,10 +76,12 @@ public V1VolumeProjectionBuilder(io.kubernetes.client.openapi.models.V1VolumePro this.withServiceAccountToken(instance.getServiceAccountToken()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1VolumeProjection build() { V1VolumeProjection buildable = new V1VolumeProjection(); buildable.setConfigMap(fluent.getConfigMap()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1VolumeProjection build() { buildable.setServiceAccountToken(fluent.getServiceAccountToken()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1VolumeProjectionBuilder that = (V1VolumeProjectionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeProjectionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeProjectionFluent.java index e13719f86c..fc6086eb75 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeProjectionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeProjectionFluent.java @@ -1,95 +1,177 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; - - /** - * Generated - */ -public interface V1VolumeProjectionFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1VolumeProjectionFluent< + A extends io.kubernetes.client.openapi.models.V1VolumeProjectionFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildConfigMap instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ConfigMapProjection getConfigMap(); + public io.kubernetes.client.openapi.models.V1ConfigMapProjection buildConfigMap(); + public A withConfigMap(io.kubernetes.client.openapi.models.V1ConfigMapProjection configMap); + public java.lang.Boolean hasConfigMap(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested withNewConfigMap(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested withNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapProjection item); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested editConfigMap(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested editOrNewConfigMap(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested editOrNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapProjection item); - + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested + withNewConfigMap(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested + withNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapProjection item); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested + editConfigMap(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested + editOrNewConfigMap(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested + editOrNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapProjection item); + /** * This method has been deprecated, please use method buildDownwardAPI instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DownwardAPIProjection getDownwardAPI(); + public io.kubernetes.client.openapi.models.V1DownwardAPIProjection buildDownwardAPI(); + public A withDownwardAPI(io.kubernetes.client.openapi.models.V1DownwardAPIProjection downwardAPI); + public java.lang.Boolean hasDownwardAPI(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested withNewDownwardAPI(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested withNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIProjection item); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested editDownwardAPI(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested editOrNewDownwardAPI(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested editOrNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIProjection item); - + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested + withNewDownwardAPI(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested + withNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIProjection item); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested + editDownwardAPI(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested + editOrNewDownwardAPI(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested + editOrNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIProjection item); + /** * This method has been deprecated, please use method buildSecret instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretProjection getSecret(); + public io.kubernetes.client.openapi.models.V1SecretProjection buildSecret(); + public A withSecret(io.kubernetes.client.openapi.models.V1SecretProjection secret); + public java.lang.Boolean hasSecret(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested withNewSecret(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested withNewSecretLike(io.kubernetes.client.openapi.models.V1SecretProjection item); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested + withNewSecret(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested + withNewSecretLike(io.kubernetes.client.openapi.models.V1SecretProjection item); + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested editSecret(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested editOrNewSecret(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested editOrNewSecretLike(io.kubernetes.client.openapi.models.V1SecretProjection item); - + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested + editOrNewSecret(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested + editOrNewSecretLike(io.kubernetes.client.openapi.models.V1SecretProjection item); + /** * This method has been deprecated, please use method buildServiceAccountToken instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection getServiceAccountToken(); - public io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection buildServiceAccountToken(); - public A withServiceAccountToken(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection serviceAccountToken); + public io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection + getServiceAccountToken(); + + public io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection + buildServiceAccountToken(); + + public A withServiceAccountToken( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection serviceAccountToken); + public java.lang.Boolean hasServiceAccountToken(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested withNewServiceAccountToken(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested withNewServiceAccountTokenLike(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection item); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested editServiceAccountToken(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested editOrNewServiceAccountToken(); - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested editOrNewServiceAccountTokenLike(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection item); - public interface ConfigMapNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent>{ + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested + withNewServiceAccountToken(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested + withNewServiceAccountTokenLike( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection item); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested + editServiceAccountToken(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested + editOrNewServiceAccountToken(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested + editOrNewServiceAccountTokenLike( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection item); + + public interface ConfigMapNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluent< + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested> { public N and(); + public N endConfigMap(); - } - public interface DownwardAPINested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent>{ + + public interface DownwardAPINested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluent< + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested> { public N and(); + public N endDownwardAPI(); - } - public interface SecretNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SecretProjectionFluent>{ + + public interface SecretNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SecretProjectionFluent< + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested> { public N and(); + public N endSecret(); - } - public interface ServiceAccountTokenNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent>{ + + public interface ServiceAccountTokenNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluent< + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent + .ServiceAccountTokenNested< + N>> { public N and(); + public N endServiceAccountToken(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeProjectionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeProjectionFluentImpl.java index 952e4debf8..3035dfbe81 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeProjectionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VolumeProjectionFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Object; +/** Generated */ +public class V1VolumeProjectionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1VolumeProjectionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1VolumeProjectionFluent { + public V1VolumeProjectionFluentImpl() {} - /** - * Generated - */ -public class V1VolumeProjectionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1VolumeProjectionFluent{ - public V1VolumeProjectionFluentImpl() { - } - public V1VolumeProjectionFluentImpl(io.kubernetes.client.openapi.models.V1VolumeProjection instance) { + public V1VolumeProjectionFluentImpl( + io.kubernetes.client.openapi.models.V1VolumeProjection instance) { this.withConfigMap(instance.getConfigMap()); this.withDownwardAPI(instance.getDownwardAPI()); @@ -20,224 +28,373 @@ public V1VolumeProjectionFluentImpl(io.kubernetes.client.openapi.models.V1Volume this.withSecret(instance.getSecret()); this.withServiceAccountToken(instance.getServiceAccountToken()); - } + private io.kubernetes.client.openapi.models.V1ConfigMapProjectionBuilder configMap; private io.kubernetes.client.openapi.models.V1DownwardAPIProjectionBuilder downwardAPI; private io.kubernetes.client.openapi.models.V1SecretProjectionBuilder secret; - private io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionBuilder serviceAccountToken; - + private io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionBuilder + serviceAccountToken; + /** * This method has been deprecated, please use method buildConfigMap instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ConfigMapProjection getConfigMap() { - return this.configMap!=null ?this.configMap.build():null; + return this.configMap != null ? this.configMap.build() : null; } + public io.kubernetes.client.openapi.models.V1ConfigMapProjection buildConfigMap() { - return this.configMap!=null ?this.configMap.build():null; + return this.configMap != null ? this.configMap.build() : null; } + public A withConfigMap(io.kubernetes.client.openapi.models.V1ConfigMapProjection configMap) { _visitables.get("configMap").remove(this.configMap); - if (configMap!=null){ this.configMap= new io.kubernetes.client.openapi.models.V1ConfigMapProjectionBuilder(configMap); _visitables.get("configMap").add(this.configMap);} return (A) this; + if (configMap != null) { + this.configMap = + new io.kubernetes.client.openapi.models.V1ConfigMapProjectionBuilder(configMap); + _visitables.get("configMap").add(this.configMap); + } + return (A) this; } + public java.lang.Boolean hasConfigMap() { return this.configMap != null; } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested withNewConfigMap() { - return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl.ConfigMapNestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested + withNewConfigMap() { + return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl + .ConfigMapNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested withNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapProjection item) { - return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl.ConfigMapNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested + withNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapProjection item) { + return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl.ConfigMapNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested editConfigMap() { + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested + editConfigMap() { return withNewConfigMapLike(getConfigMap()); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested editOrNewConfigMap() { - return withNewConfigMapLike(getConfigMap() != null ? getConfigMap(): new io.kubernetes.client.openapi.models.V1ConfigMapProjectionBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested + editOrNewConfigMap() { + return withNewConfigMapLike( + getConfigMap() != null + ? getConfigMap() + : new io.kubernetes.client.openapi.models.V1ConfigMapProjectionBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested editOrNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapProjection item) { - return withNewConfigMapLike(getConfigMap() != null ? getConfigMap(): item); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested + editOrNewConfigMapLike(io.kubernetes.client.openapi.models.V1ConfigMapProjection item) { + return withNewConfigMapLike(getConfigMap() != null ? getConfigMap() : item); } - + /** * This method has been deprecated, please use method buildDownwardAPI instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1DownwardAPIProjection getDownwardAPI() { - return this.downwardAPI!=null ?this.downwardAPI.build():null; + return this.downwardAPI != null ? this.downwardAPI.build() : null; } + public io.kubernetes.client.openapi.models.V1DownwardAPIProjection buildDownwardAPI() { - return this.downwardAPI!=null ?this.downwardAPI.build():null; + return this.downwardAPI != null ? this.downwardAPI.build() : null; } - public A withDownwardAPI(io.kubernetes.client.openapi.models.V1DownwardAPIProjection downwardAPI) { + + public A withDownwardAPI( + io.kubernetes.client.openapi.models.V1DownwardAPIProjection downwardAPI) { _visitables.get("downwardAPI").remove(this.downwardAPI); - if (downwardAPI!=null){ this.downwardAPI= new io.kubernetes.client.openapi.models.V1DownwardAPIProjectionBuilder(downwardAPI); _visitables.get("downwardAPI").add(this.downwardAPI);} return (A) this; + if (downwardAPI != null) { + this.downwardAPI = + new io.kubernetes.client.openapi.models.V1DownwardAPIProjectionBuilder(downwardAPI); + _visitables.get("downwardAPI").add(this.downwardAPI); + } + return (A) this; } + public java.lang.Boolean hasDownwardAPI() { return this.downwardAPI != null; } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested withNewDownwardAPI() { - return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl.DownwardAPINestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested + withNewDownwardAPI() { + return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl + .DownwardAPINestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested withNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIProjection item) { - return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl.DownwardAPINestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested + withNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIProjection item) { + return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl + .DownwardAPINestedImpl(item); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested editDownwardAPI() { + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested + editDownwardAPI() { return withNewDownwardAPILike(getDownwardAPI()); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested editOrNewDownwardAPI() { - return withNewDownwardAPILike(getDownwardAPI() != null ? getDownwardAPI(): new io.kubernetes.client.openapi.models.V1DownwardAPIProjectionBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested + editOrNewDownwardAPI() { + return withNewDownwardAPILike( + getDownwardAPI() != null + ? getDownwardAPI() + : new io.kubernetes.client.openapi.models.V1DownwardAPIProjectionBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested editOrNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIProjection item) { - return withNewDownwardAPILike(getDownwardAPI() != null ? getDownwardAPI(): item); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested + editOrNewDownwardAPILike(io.kubernetes.client.openapi.models.V1DownwardAPIProjection item) { + return withNewDownwardAPILike(getDownwardAPI() != null ? getDownwardAPI() : item); } - + /** * This method has been deprecated, please use method buildSecret instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SecretProjection getSecret() { - return this.secret!=null ?this.secret.build():null; + return this.secret != null ? this.secret.build() : null; } + public io.kubernetes.client.openapi.models.V1SecretProjection buildSecret() { - return this.secret!=null ?this.secret.build():null; + return this.secret != null ? this.secret.build() : null; } + public A withSecret(io.kubernetes.client.openapi.models.V1SecretProjection secret) { _visitables.get("secret").remove(this.secret); - if (secret!=null){ this.secret= new io.kubernetes.client.openapi.models.V1SecretProjectionBuilder(secret); _visitables.get("secret").add(this.secret);} return (A) this; + if (secret != null) { + this.secret = new io.kubernetes.client.openapi.models.V1SecretProjectionBuilder(secret); + _visitables.get("secret").add(this.secret); + } + return (A) this; } + public java.lang.Boolean hasSecret() { return this.secret != null; } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested withNewSecret() { + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested + withNewSecret() { return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl.SecretNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested withNewSecretLike(io.kubernetes.client.openapi.models.V1SecretProjection item) { - return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl.SecretNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested + withNewSecretLike(io.kubernetes.client.openapi.models.V1SecretProjection item) { + return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl.SecretNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested editSecret() { return withNewSecretLike(getSecret()); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested editOrNewSecret() { - return withNewSecretLike(getSecret() != null ? getSecret(): new io.kubernetes.client.openapi.models.V1SecretProjectionBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested + editOrNewSecret() { + return withNewSecretLike( + getSecret() != null + ? getSecret() + : new io.kubernetes.client.openapi.models.V1SecretProjectionBuilder().build()); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested editOrNewSecretLike(io.kubernetes.client.openapi.models.V1SecretProjection item) { - return withNewSecretLike(getSecret() != null ? getSecret(): item); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested + editOrNewSecretLike(io.kubernetes.client.openapi.models.V1SecretProjection item) { + return withNewSecretLike(getSecret() != null ? getSecret() : item); } - + /** * This method has been deprecated, please use method buildServiceAccountToken instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection getServiceAccountToken() { - return this.serviceAccountToken!=null ?this.serviceAccountToken.build():null; + public io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection + getServiceAccountToken() { + return this.serviceAccountToken != null ? this.serviceAccountToken.build() : null; } - public io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection buildServiceAccountToken() { - return this.serviceAccountToken!=null ?this.serviceAccountToken.build():null; + + public io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection + buildServiceAccountToken() { + return this.serviceAccountToken != null ? this.serviceAccountToken.build() : null; } - public A withServiceAccountToken(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection serviceAccountToken) { + + public A withServiceAccountToken( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection serviceAccountToken) { _visitables.get("serviceAccountToken").remove(this.serviceAccountToken); - if (serviceAccountToken!=null){ this.serviceAccountToken= new io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionBuilder(serviceAccountToken); _visitables.get("serviceAccountToken").add(this.serviceAccountToken);} return (A) this; + if (serviceAccountToken != null) { + this.serviceAccountToken = + new io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionBuilder( + serviceAccountToken); + _visitables.get("serviceAccountToken").add(this.serviceAccountToken); + } + return (A) this; } + public java.lang.Boolean hasServiceAccountToken() { return this.serviceAccountToken != null; } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested withNewServiceAccountToken() { - return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl.ServiceAccountTokenNestedImpl(); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested + withNewServiceAccountToken() { + return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl + .ServiceAccountTokenNestedImpl(); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested withNewServiceAccountTokenLike(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection item) { - return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl.ServiceAccountTokenNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested + withNewServiceAccountTokenLike( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection item) { + return new io.kubernetes.client.openapi.models.V1VolumeProjectionFluentImpl + .ServiceAccountTokenNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested editServiceAccountToken() { + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested + editServiceAccountToken() { return withNewServiceAccountTokenLike(getServiceAccountToken()); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested editOrNewServiceAccountToken() { - return withNewServiceAccountTokenLike(getServiceAccountToken() != null ? getServiceAccountToken(): new io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionBuilder().build()); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested + editOrNewServiceAccountToken() { + return withNewServiceAccountTokenLike( + getServiceAccountToken() != null + ? getServiceAccountToken() + : new io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested editOrNewServiceAccountTokenLike(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection item) { - return withNewServiceAccountTokenLike(getServiceAccountToken() != null ? getServiceAccountToken(): item); + + public io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested + editOrNewServiceAccountTokenLike( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection item) { + return withNewServiceAccountTokenLike( + getServiceAccountToken() != null ? getServiceAccountToken() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1VolumeProjectionFluentImpl that = (V1VolumeProjectionFluentImpl) o; - if (configMap != null ? !configMap.equals(that.configMap) :that.configMap != null) return false; - if (downwardAPI != null ? !downwardAPI.equals(that.downwardAPI) :that.downwardAPI != null) return false; - if (secret != null ? !secret.equals(that.secret) :that.secret != null) return false; - if (serviceAccountToken != null ? !serviceAccountToken.equals(that.serviceAccountToken) :that.serviceAccountToken != null) return false; + if (configMap != null ? !configMap.equals(that.configMap) : that.configMap != null) + return false; + if (downwardAPI != null ? !downwardAPI.equals(that.downwardAPI) : that.downwardAPI != null) + return false; + if (secret != null ? !secret.equals(that.secret) : that.secret != null) return false; + if (serviceAccountToken != null + ? !serviceAccountToken.equals(that.serviceAccountToken) + : that.serviceAccountToken != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(configMap, downwardAPI, secret, serviceAccountToken, super.hashCode()); + return java.util.Objects.hash( + configMap, downwardAPI, secret, serviceAccountToken, super.hashCode()); } - public class ConfigMapNestedImpl extends io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested,io.kubernetes.client.fluent.Nested{ + + public class ConfigMapNestedImpl + extends io.kubernetes.client.openapi.models.V1ConfigMapProjectionFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested> + implements io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ConfigMapNested, + io.kubernetes.client.fluent.Nested { ConfigMapNestedImpl(io.kubernetes.client.openapi.models.V1ConfigMapProjection item) { - this.builder = new io.kubernetes.client.openapi.models.V1ConfigMapProjectionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1ConfigMapProjectionBuilder(this, item); } + ConfigMapNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ConfigMapProjectionBuilder(this); } + io.kubernetes.client.openapi.models.V1ConfigMapProjectionBuilder builder; + public N and() { return (N) V1VolumeProjectionFluentImpl.this.withConfigMap(builder.build()); } + public N endConfigMap() { return and(); } - } - public class DownwardAPINestedImpl extends io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested,io.kubernetes.client.fluent.Nested{ + + public class DownwardAPINestedImpl + extends io.kubernetes.client.openapi.models.V1DownwardAPIProjectionFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested> + implements io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.DownwardAPINested, + io.kubernetes.client.fluent.Nested { DownwardAPINestedImpl(io.kubernetes.client.openapi.models.V1DownwardAPIProjection item) { - this.builder = new io.kubernetes.client.openapi.models.V1DownwardAPIProjectionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1DownwardAPIProjectionBuilder(this, item); } + DownwardAPINestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1DownwardAPIProjectionBuilder(this); } + io.kubernetes.client.openapi.models.V1DownwardAPIProjectionBuilder builder; + public N and() { return (N) V1VolumeProjectionFluentImpl.this.withDownwardAPI(builder.build()); } + public N endDownwardAPI() { return and(); } - } - public class SecretNestedImpl extends io.kubernetes.client.openapi.models.V1SecretProjectionFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested,io.kubernetes.client.fluent.Nested{ + + public class SecretNestedImpl + extends io.kubernetes.client.openapi.models.V1SecretProjectionFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested> + implements io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.SecretNested, + io.kubernetes.client.fluent.Nested { SecretNestedImpl(io.kubernetes.client.openapi.models.V1SecretProjection item) { this.builder = new io.kubernetes.client.openapi.models.V1SecretProjectionBuilder(this, item); } + SecretNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SecretProjectionBuilder(this); } + io.kubernetes.client.openapi.models.V1SecretProjectionBuilder builder; + public N and() { return (N) V1VolumeProjectionFluentImpl.this.withSecret(builder.build()); } + public N endSecret() { return and(); } - } - public class ServiceAccountTokenNestedImpl extends io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluentImpl> implements io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested,io.kubernetes.client.fluent.Nested{ - ServiceAccountTokenNestedImpl(io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection item) { - this.builder = new io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionBuilder(this, item); + + public class ServiceAccountTokenNestedImpl + extends io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionFluentImpl< + io.kubernetes.client.openapi.models.V1VolumeProjectionFluent.ServiceAccountTokenNested> + implements io.kubernetes.client.openapi.models.V1VolumeProjectionFluent + .ServiceAccountTokenNested< + N>, + io.kubernetes.client.fluent.Nested { + ServiceAccountTokenNestedImpl( + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjection item) { + this.builder = + new io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionBuilder( + this, item); } + ServiceAccountTokenNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionBuilder(this); } + io.kubernetes.client.openapi.models.V1ServiceAccountTokenProjectionBuilder builder; + public N and() { return (N) V1VolumeProjectionFluentImpl.this.withServiceAccountToken(builder.build()); } + public N endServiceAccountToken() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VsphereVirtualDiskVolumeSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VsphereVirtualDiskVolumeSourceBuilder.java index 93fa887331..c8cfadffab 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VsphereVirtualDiskVolumeSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VsphereVirtualDiskVolumeSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1VsphereVirtualDiskVolumeSourceBuilder extends io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1VsphereVirtualDiskVolumeSourceBuilder + extends io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluentImpl< + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource, + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceBuilder> { public V1VsphereVirtualDiskVolumeSourceBuilder() { this(false); } + public V1VsphereVirtualDiskVolumeSourceBuilder(java.lang.Boolean validationEnabled) { this(new V1VsphereVirtualDiskVolumeSource(), validationEnabled); } - public V1VsphereVirtualDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent fluent) { + + public V1VsphereVirtualDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent fluent) { this(fluent, false); } - public V1VsphereVirtualDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1VsphereVirtualDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1VsphereVirtualDiskVolumeSource(), validationEnabled); } - public V1VsphereVirtualDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource instance) { + + public V1VsphereVirtualDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource instance) { this(fluent, instance, false); } - public V1VsphereVirtualDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent fluent,io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1VsphereVirtualDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent fluent, + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withFsType(instance.getFsType()); fluent.withStoragePolicyID(instance.getStoragePolicyID()); @@ -29,13 +56,18 @@ public V1VsphereVirtualDiskVolumeSourceBuilder(io.kubernetes.client.openapi.mode fluent.withVolumePath(instance.getVolumePath()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1VsphereVirtualDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource instance) { - this(instance,false); + + public V1VsphereVirtualDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource instance) { + this(instance, false); } - public V1VsphereVirtualDiskVolumeSourceBuilder(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1VsphereVirtualDiskVolumeSourceBuilder( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withFsType(instance.getFsType()); this.withStoragePolicyID(instance.getStoragePolicyID()); @@ -44,10 +76,12 @@ public V1VsphereVirtualDiskVolumeSourceBuilder(io.kubernetes.client.openapi.mode this.withVolumePath(instance.getVolumePath()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource build() { V1VsphereVirtualDiskVolumeSource buildable = new V1VsphereVirtualDiskVolumeSource(); buildable.setFsType(fluent.getFsType()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource buil buildable.setVolumePath(fluent.getVolumePath()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1VsphereVirtualDiskVolumeSourceBuilder that = (V1VsphereVirtualDiskVolumeSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VsphereVirtualDiskVolumeSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VsphereVirtualDiskVolumeSourceFluent.java index 72c61352e6..585de19b8c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VsphereVirtualDiskVolumeSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VsphereVirtualDiskVolumeSourceFluent.java @@ -1,50 +1,58 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1VsphereVirtualDiskVolumeSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1VsphereVirtualDiskVolumeSourceFluent< + A extends io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getFsType(); + public A withFsType(java.lang.String fsType); + public java.lang.Boolean hasFsType(); - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original); + public java.lang.String getStoragePolicyID(); + public A withStoragePolicyID(java.lang.String storagePolicyID); + public java.lang.Boolean hasStoragePolicyID(); - - /** - * Method is deprecated. use withStoragePolicyID instead. - */ + + /** Method is deprecated. use withStoragePolicyID instead. */ @java.lang.Deprecated public A withNewStoragePolicyID(java.lang.String original); + public java.lang.String getStoragePolicyName(); + public A withStoragePolicyName(java.lang.String storagePolicyName); + public java.lang.Boolean hasStoragePolicyName(); - - /** - * Method is deprecated. use withStoragePolicyName instead. - */ + + /** Method is deprecated. use withStoragePolicyName instead. */ @java.lang.Deprecated public A withNewStoragePolicyName(java.lang.String original); + public java.lang.String getVolumePath(); + public A withVolumePath(java.lang.String volumePath); + public java.lang.Boolean hasVolumePath(); - - /** - * Method is deprecated. use withVolumePath instead. - */ + + /** Method is deprecated. use withVolumePath instead. */ @java.lang.Deprecated public A withNewVolumePath(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VsphereVirtualDiskVolumeSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VsphereVirtualDiskVolumeSourceFluentImpl.java index ce78a1b760..5d90188d16 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VsphereVirtualDiskVolumeSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1VsphereVirtualDiskVolumeSourceFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1VsphereVirtualDiskVolumeSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent { + public V1VsphereVirtualDiskVolumeSourceFluentImpl() {} - /** - * Generated - */ -public class V1VsphereVirtualDiskVolumeSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSourceFluent{ - public V1VsphereVirtualDiskVolumeSourceFluentImpl() { - } - public V1VsphereVirtualDiskVolumeSourceFluentImpl(io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource instance) { + public V1VsphereVirtualDiskVolumeSourceFluentImpl( + io.kubernetes.client.openapi.models.V1VsphereVirtualDiskVolumeSource instance) { this.withFsType(instance.getFsType()); this.withStoragePolicyID(instance.getStoragePolicyID()); @@ -20,92 +28,108 @@ public V1VsphereVirtualDiskVolumeSourceFluentImpl(io.kubernetes.client.openapi.m this.withStoragePolicyName(instance.getStoragePolicyName()); this.withVolumePath(instance.getVolumePath()); - } + private java.lang.String fsType; private java.lang.String storagePolicyID; private java.lang.String storagePolicyName; private java.lang.String volumePath; + public java.lang.String getFsType() { return this.fsType; } + public A withFsType(java.lang.String fsType) { - this.fsType=fsType; return (A) this; + this.fsType = fsType; + return (A) this; } + public java.lang.Boolean hasFsType() { return this.fsType != null; } - - /** - * Method is deprecated. use withFsType instead. - */ + + /** Method is deprecated. use withFsType instead. */ @java.lang.Deprecated public A withNewFsType(java.lang.String original) { - return (A)withFsType(new String(original)); + return (A) withFsType(new String(original)); } + public java.lang.String getStoragePolicyID() { return this.storagePolicyID; } + public A withStoragePolicyID(java.lang.String storagePolicyID) { - this.storagePolicyID=storagePolicyID; return (A) this; + this.storagePolicyID = storagePolicyID; + return (A) this; } + public java.lang.Boolean hasStoragePolicyID() { return this.storagePolicyID != null; } - - /** - * Method is deprecated. use withStoragePolicyID instead. - */ + + /** Method is deprecated. use withStoragePolicyID instead. */ @java.lang.Deprecated public A withNewStoragePolicyID(java.lang.String original) { - return (A)withStoragePolicyID(new String(original)); + return (A) withStoragePolicyID(new String(original)); } + public java.lang.String getStoragePolicyName() { return this.storagePolicyName; } + public A withStoragePolicyName(java.lang.String storagePolicyName) { - this.storagePolicyName=storagePolicyName; return (A) this; + this.storagePolicyName = storagePolicyName; + return (A) this; } + public java.lang.Boolean hasStoragePolicyName() { return this.storagePolicyName != null; } - - /** - * Method is deprecated. use withStoragePolicyName instead. - */ + + /** Method is deprecated. use withStoragePolicyName instead. */ @java.lang.Deprecated public A withNewStoragePolicyName(java.lang.String original) { - return (A)withStoragePolicyName(new String(original)); + return (A) withStoragePolicyName(new String(original)); } + public java.lang.String getVolumePath() { return this.volumePath; } + public A withVolumePath(java.lang.String volumePath) { - this.volumePath=volumePath; return (A) this; + this.volumePath = volumePath; + return (A) this; } + public java.lang.Boolean hasVolumePath() { return this.volumePath != null; } - - /** - * Method is deprecated. use withVolumePath instead. - */ + + /** Method is deprecated. use withVolumePath instead. */ @java.lang.Deprecated public A withNewVolumePath(java.lang.String original) { - return (A)withVolumePath(new String(original)); + return (A) withVolumePath(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1VsphereVirtualDiskVolumeSourceFluentImpl that = (V1VsphereVirtualDiskVolumeSourceFluentImpl) o; - if (fsType != null ? !fsType.equals(that.fsType) :that.fsType != null) return false; - if (storagePolicyID != null ? !storagePolicyID.equals(that.storagePolicyID) :that.storagePolicyID != null) return false; - if (storagePolicyName != null ? !storagePolicyName.equals(that.storagePolicyName) :that.storagePolicyName != null) return false; - if (volumePath != null ? !volumePath.equals(that.volumePath) :that.volumePath != null) return false; + V1VsphereVirtualDiskVolumeSourceFluentImpl that = + (V1VsphereVirtualDiskVolumeSourceFluentImpl) o; + if (fsType != null ? !fsType.equals(that.fsType) : that.fsType != null) return false; + if (storagePolicyID != null + ? !storagePolicyID.equals(that.storagePolicyID) + : that.storagePolicyID != null) return false; + if (storagePolicyName != null + ? !storagePolicyName.equals(that.storagePolicyName) + : that.storagePolicyName != null) return false; + if (volumePath != null ? !volumePath.equals(that.volumePath) : that.volumePath != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fsType, storagePolicyID, storagePolicyName, volumePath, super.hashCode()); + return java.util.Objects.hash( + fsType, storagePolicyID, storagePolicyName, volumePath, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WatchEventBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WatchEventBuilder.java index d7feefb32d..0a57b804ca 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WatchEventBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WatchEventBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1WatchEventBuilder extends io.kubernetes.client.openapi.models.V1WatchEventFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1WatchEventBuilder + extends io.kubernetes.client.openapi.models.V1WatchEventFluentImpl< + io.kubernetes.client.openapi.models.V1WatchEventBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1WatchEvent, + io.kubernetes.client.openapi.models.V1WatchEventBuilder> { public V1WatchEventBuilder() { this(false); } + public V1WatchEventBuilder(java.lang.Boolean validationEnabled) { this(new V1WatchEvent(), validationEnabled); } + public V1WatchEventBuilder(io.kubernetes.client.openapi.models.V1WatchEventFluent fluent) { this(fluent, false); } - public V1WatchEventBuilder(io.kubernetes.client.openapi.models.V1WatchEventFluent fluent,java.lang.Boolean validationEnabled) { + + public V1WatchEventBuilder( + io.kubernetes.client.openapi.models.V1WatchEventFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1WatchEvent(), validationEnabled); } - public V1WatchEventBuilder(io.kubernetes.client.openapi.models.V1WatchEventFluent fluent,io.kubernetes.client.openapi.models.V1WatchEvent instance) { + + public V1WatchEventBuilder( + io.kubernetes.client.openapi.models.V1WatchEventFluent fluent, + io.kubernetes.client.openapi.models.V1WatchEvent instance) { this(fluent, instance, false); } - public V1WatchEventBuilder(io.kubernetes.client.openapi.models.V1WatchEventFluent fluent,io.kubernetes.client.openapi.models.V1WatchEvent instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1WatchEventBuilder( + io.kubernetes.client.openapi.models.V1WatchEventFluent fluent, + io.kubernetes.client.openapi.models.V1WatchEvent instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withObject(instance.getObject()); fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1WatchEventBuilder(io.kubernetes.client.openapi.models.V1WatchEvent instance) { - this(instance,false); + this(instance, false); } - public V1WatchEventBuilder(io.kubernetes.client.openapi.models.V1WatchEvent instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1WatchEventBuilder( + io.kubernetes.client.openapi.models.V1WatchEvent instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withObject(instance.getObject()); this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1WatchEventFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1WatchEvent build() { V1WatchEvent buildable = new V1WatchEvent(); buildable.setObject(fluent.getObject()); buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1WatchEventBuilder that = (V1WatchEventBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WatchEventFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WatchEventFluent.java index 69edd1bde7..831b7fc87a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WatchEventFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WatchEventFluent.java @@ -1,27 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1WatchEventFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1WatchEventFluent< + A extends io.kubernetes.client.openapi.models.V1WatchEventFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Object getObject(); + public A withObject(java.lang.Object _object); + public java.lang.Boolean hasObject(); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WatchEventFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WatchEventFluentImpl.java index e6f170818f..02ed604030 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WatchEventFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WatchEventFluentImpl.java @@ -1,61 +1,75 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1WatchEventFluentImpl< + A extends io.kubernetes.client.openapi.models.V1WatchEventFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1WatchEventFluent { + public V1WatchEventFluentImpl() {} - /** - * Generated - */ -public class V1WatchEventFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1WatchEventFluent{ - public V1WatchEventFluentImpl() { - } public V1WatchEventFluentImpl(io.kubernetes.client.openapi.models.V1WatchEvent instance) { this.withObject(instance.getObject()); this.withType(instance.getType()); - } + private java.lang.Object _object; private java.lang.String type; + public java.lang.Object getObject() { return this._object; } + public A withObject(java.lang.Object _object) { - this._object=_object; return (A) this; + this._object = _object; + return (A) this; } + public java.lang.Boolean hasObject() { return this._object != null; } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1WatchEventFluentImpl that = (V1WatchEventFluentImpl) o; - if (_object != null ? !_object.equals(that._object) :that._object != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (_object != null ? !_object.equals(that._object) : that._object != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(_object, type, super.hashCode()); + return java.util.Objects.hash(_object, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WebhookConversionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WebhookConversionBuilder.java index 243394cb37..45ecdb68a1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WebhookConversionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WebhookConversionBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1WebhookConversionBuilder extends io.kubernetes.client.openapi.models.V1WebhookConversionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1WebhookConversionBuilder + extends io.kubernetes.client.openapi.models.V1WebhookConversionFluentImpl< + io.kubernetes.client.openapi.models.V1WebhookConversionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1WebhookConversion, + io.kubernetes.client.openapi.models.V1WebhookConversionBuilder> { public V1WebhookConversionBuilder() { this(false); } + public V1WebhookConversionBuilder(java.lang.Boolean validationEnabled) { this(new V1WebhookConversion(), validationEnabled); } - public V1WebhookConversionBuilder(io.kubernetes.client.openapi.models.V1WebhookConversionFluent fluent) { + + public V1WebhookConversionBuilder( + io.kubernetes.client.openapi.models.V1WebhookConversionFluent fluent) { this(fluent, false); } - public V1WebhookConversionBuilder(io.kubernetes.client.openapi.models.V1WebhookConversionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1WebhookConversionBuilder( + io.kubernetes.client.openapi.models.V1WebhookConversionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1WebhookConversion(), validationEnabled); } - public V1WebhookConversionBuilder(io.kubernetes.client.openapi.models.V1WebhookConversionFluent fluent,io.kubernetes.client.openapi.models.V1WebhookConversion instance) { + + public V1WebhookConversionBuilder( + io.kubernetes.client.openapi.models.V1WebhookConversionFluent fluent, + io.kubernetes.client.openapi.models.V1WebhookConversion instance) { this(fluent, instance, false); } - public V1WebhookConversionBuilder(io.kubernetes.client.openapi.models.V1WebhookConversionFluent fluent,io.kubernetes.client.openapi.models.V1WebhookConversion instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1WebhookConversionBuilder( + io.kubernetes.client.openapi.models.V1WebhookConversionFluent fluent, + io.kubernetes.client.openapi.models.V1WebhookConversion instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withClientConfig(instance.getClientConfig()); fluent.withConversionReviewVersions(instance.getConversionReviewVersions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1WebhookConversionBuilder(io.kubernetes.client.openapi.models.V1WebhookConversion instance) { - this(instance,false); + + public V1WebhookConversionBuilder( + io.kubernetes.client.openapi.models.V1WebhookConversion instance) { + this(instance, false); } - public V1WebhookConversionBuilder(io.kubernetes.client.openapi.models.V1WebhookConversion instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1WebhookConversionBuilder( + io.kubernetes.client.openapi.models.V1WebhookConversion instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withClientConfig(instance.getClientConfig()); this.withConversionReviewVersions(instance.getConversionReviewVersions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1WebhookConversionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1WebhookConversion build() { V1WebhookConversion buildable = new V1WebhookConversion(); buildable.setClientConfig(fluent.getClientConfig()); buildable.setConversionReviewVersions(fluent.getConversionReviewVersions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1WebhookConversionBuilder that = (V1WebhookConversionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WebhookConversionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WebhookConversionFluent.java index 897a71897a..f8b160aeb2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WebhookConversionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WebhookConversionFluent.java @@ -1,56 +1,94 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1WebhookConversionFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1WebhookConversionFluent< + A extends io.kubernetes.client.openapi.models.V1WebhookConversionFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildClientConfig instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig getClientConfig(); + public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig buildClientConfig(); - public A withClientConfig(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig clientConfig); + + public A withClientConfig( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig clientConfig); + public java.lang.Boolean hasClientConfig(); - public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested withNewClientConfig(); - public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested withNewClientConfigLike(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig item); - public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested editClientConfig(); - public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested editOrNewClientConfig(); - public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested editOrNewClientConfigLike(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig item); - public A addToConversionReviewVersions(java.lang.Integer index,java.lang.String item); - public A setToConversionReviewVersions(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested + withNewClientConfig(); + + public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested + withNewClientConfigLike( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig item); + + public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested + editClientConfig(); + + public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested + editOrNewClientConfig(); + + public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested + editOrNewClientConfigLike( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig item); + + public A addToConversionReviewVersions(java.lang.Integer index, java.lang.String item); + + public A setToConversionReviewVersions(java.lang.Integer index, java.lang.String item); + public A addToConversionReviewVersions(java.lang.String... items); + public A addAllToConversionReviewVersions(java.util.Collection items); + public A removeFromConversionReviewVersions(java.lang.String... items); + public A removeAllFromConversionReviewVersions(java.util.Collection items); + public java.util.List getConversionReviewVersions(); + public java.lang.String getConversionReviewVersion(java.lang.Integer index); + public java.lang.String getFirstConversionReviewVersion(); + public java.lang.String getLastConversionReviewVersion(); - public java.lang.String getMatchingConversionReviewVersion(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingConversionReviewVersion(java.util.function.Predicate predicate); + + public java.lang.String getMatchingConversionReviewVersion( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingConversionReviewVersion( + java.util.function.Predicate predicate); + public A withConversionReviewVersions(java.util.List conversionReviewVersions); + public A withConversionReviewVersions(java.lang.String... conversionReviewVersions); + public java.lang.Boolean hasConversionReviewVersions(); + public A addNewConversionReviewVersion(java.lang.String original); - public interface ClientConfigNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent>{ + + public interface ClientConfigNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluent< + io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested> { public N and(); + public N endClientConfig(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WebhookConversionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WebhookConversionFluentImpl.java index 9d5a6dfd21..cc08bfa465 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WebhookConversionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WebhookConversionFluentImpl.java @@ -1,145 +1,263 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1WebhookConversionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1WebhookConversionFluent{ - public V1WebhookConversionFluentImpl() { - } - public V1WebhookConversionFluentImpl(io.kubernetes.client.openapi.models.V1WebhookConversion instance) { +/** Generated */ +public class V1WebhookConversionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1WebhookConversionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1WebhookConversionFluent { + public V1WebhookConversionFluentImpl() {} + + public V1WebhookConversionFluentImpl( + io.kubernetes.client.openapi.models.V1WebhookConversion instance) { this.withClientConfig(instance.getClientConfig()); this.withConversionReviewVersions(instance.getConversionReviewVersions()); - } - private io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigBuilder clientConfig; + + private io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigBuilder + clientConfig; private java.util.List conversionReviewVersions; - + /** * This method has been deprecated, please use method buildClientConfig instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig getClientConfig() { - return this.clientConfig!=null ?this.clientConfig.build():null; + return this.clientConfig != null ? this.clientConfig.build() : null; } - public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig buildClientConfig() { - return this.clientConfig!=null ?this.clientConfig.build():null; + + public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig + buildClientConfig() { + return this.clientConfig != null ? this.clientConfig.build() : null; } - public A withClientConfig(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig clientConfig) { + + public A withClientConfig( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig clientConfig) { _visitables.get("clientConfig").remove(this.clientConfig); - if (clientConfig!=null){ this.clientConfig= new io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigBuilder(clientConfig); _visitables.get("clientConfig").add(this.clientConfig);} return (A) this; + if (clientConfig != null) { + this.clientConfig = + new io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigBuilder( + clientConfig); + _visitables.get("clientConfig").add(this.clientConfig); + } + return (A) this; } + public java.lang.Boolean hasClientConfig() { return this.clientConfig != null; } - public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested withNewClientConfig() { - return new io.kubernetes.client.openapi.models.V1WebhookConversionFluentImpl.ClientConfigNestedImpl(); + + public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested + withNewClientConfig() { + return new io.kubernetes.client.openapi.models.V1WebhookConversionFluentImpl + .ClientConfigNestedImpl(); } - public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested withNewClientConfigLike(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig item) { - return new io.kubernetes.client.openapi.models.V1WebhookConversionFluentImpl.ClientConfigNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested + withNewClientConfigLike( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig item) { + return new io.kubernetes.client.openapi.models.V1WebhookConversionFluentImpl + .ClientConfigNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested editClientConfig() { + + public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested + editClientConfig() { return withNewClientConfigLike(getClientConfig()); } - public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested editOrNewClientConfig() { - return withNewClientConfigLike(getClientConfig() != null ? getClientConfig(): new io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigBuilder().build()); + + public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested + editOrNewClientConfig() { + return withNewClientConfigLike( + getClientConfig() != null + ? getClientConfig() + : new io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested editOrNewClientConfigLike(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig item) { - return withNewClientConfigLike(getClientConfig() != null ? getClientConfig(): item); + + public io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested + editOrNewClientConfigLike( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig item) { + return withNewClientConfigLike(getClientConfig() != null ? getClientConfig() : item); } - public A addToConversionReviewVersions(java.lang.Integer index,java.lang.String item) { - if (this.conversionReviewVersions == null) {this.conversionReviewVersions = new java.util.ArrayList();} + + public A addToConversionReviewVersions(java.lang.Integer index, java.lang.String item) { + if (this.conversionReviewVersions == null) { + this.conversionReviewVersions = new java.util.ArrayList(); + } this.conversionReviewVersions.add(index, item); - return (A)this; + return (A) this; } - public A setToConversionReviewVersions(java.lang.Integer index,java.lang.String item) { - if (this.conversionReviewVersions == null) {this.conversionReviewVersions = new java.util.ArrayList();} - this.conversionReviewVersions.set(index, item); return (A)this; + + public A setToConversionReviewVersions(java.lang.Integer index, java.lang.String item) { + if (this.conversionReviewVersions == null) { + this.conversionReviewVersions = new java.util.ArrayList(); + } + this.conversionReviewVersions.set(index, item); + return (A) this; } + public A addToConversionReviewVersions(java.lang.String... items) { - if (this.conversionReviewVersions == null) {this.conversionReviewVersions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.conversionReviewVersions.add(item);} return (A)this; + if (this.conversionReviewVersions == null) { + this.conversionReviewVersions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.conversionReviewVersions.add(item); + } + return (A) this; } + public A addAllToConversionReviewVersions(java.util.Collection items) { - if (this.conversionReviewVersions == null) {this.conversionReviewVersions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.conversionReviewVersions.add(item);} return (A)this; + if (this.conversionReviewVersions == null) { + this.conversionReviewVersions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.conversionReviewVersions.add(item); + } + return (A) this; } + public A removeFromConversionReviewVersions(java.lang.String... items) { - for (java.lang.String item : items) {if (this.conversionReviewVersions!= null){ this.conversionReviewVersions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.conversionReviewVersions != null) { + this.conversionReviewVersions.remove(item); + } + } + return (A) this; } + public A removeAllFromConversionReviewVersions(java.util.Collection items) { - for (java.lang.String item : items) {if (this.conversionReviewVersions!= null){ this.conversionReviewVersions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.conversionReviewVersions != null) { + this.conversionReviewVersions.remove(item); + } + } + return (A) this; } + public java.util.List getConversionReviewVersions() { return this.conversionReviewVersions; } + public java.lang.String getConversionReviewVersion(java.lang.Integer index) { return this.conversionReviewVersions.get(index); } + public java.lang.String getFirstConversionReviewVersion() { return this.conversionReviewVersions.get(0); } + public java.lang.String getLastConversionReviewVersion() { return this.conversionReviewVersions.get(conversionReviewVersions.size() - 1); } - public java.lang.String getMatchingConversionReviewVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: conversionReviewVersions) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingConversionReviewVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : conversionReviewVersions) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingConversionReviewVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: conversionReviewVersions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingConversionReviewVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : conversionReviewVersions) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withConversionReviewVersions(java.util.List conversionReviewVersions) { - if (conversionReviewVersions != null) {this.conversionReviewVersions = new java.util.ArrayList(); for (java.lang.String item : conversionReviewVersions){this.addToConversionReviewVersions(item);}} else { this.conversionReviewVersions = null;} return (A) this; + if (conversionReviewVersions != null) { + this.conversionReviewVersions = new java.util.ArrayList(); + for (java.lang.String item : conversionReviewVersions) { + this.addToConversionReviewVersions(item); + } + } else { + this.conversionReviewVersions = null; + } + return (A) this; } + public A withConversionReviewVersions(java.lang.String... conversionReviewVersions) { - if (this.conversionReviewVersions != null) {this.conversionReviewVersions.clear();} - if (conversionReviewVersions != null) {for (java.lang.String item :conversionReviewVersions){ this.addToConversionReviewVersions(item);}} return (A) this; + if (this.conversionReviewVersions != null) { + this.conversionReviewVersions.clear(); + } + if (conversionReviewVersions != null) { + for (java.lang.String item : conversionReviewVersions) { + this.addToConversionReviewVersions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConversionReviewVersions() { return conversionReviewVersions != null && !conversionReviewVersions.isEmpty(); } + public A addNewConversionReviewVersion(java.lang.String original) { - return (A)addToConversionReviewVersions(new String(original)); + return (A) addToConversionReviewVersions(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1WebhookConversionFluentImpl that = (V1WebhookConversionFluentImpl) o; - if (clientConfig != null ? !clientConfig.equals(that.clientConfig) :that.clientConfig != null) return false; - if (conversionReviewVersions != null ? !conversionReviewVersions.equals(that.conversionReviewVersions) :that.conversionReviewVersions != null) return false; + if (clientConfig != null ? !clientConfig.equals(that.clientConfig) : that.clientConfig != null) + return false; + if (conversionReviewVersions != null + ? !conversionReviewVersions.equals(that.conversionReviewVersions) + : that.conversionReviewVersions != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(clientConfig, conversionReviewVersions, super.hashCode()); + return java.util.Objects.hash(clientConfig, conversionReviewVersions, super.hashCode()); } - public class ClientConfigNestedImpl extends io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluentImpl> implements io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested,io.kubernetes.client.fluent.Nested{ - ClientConfigNestedImpl(io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig item) { - this.builder = new io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigBuilder(this, item); + + public class ClientConfigNestedImpl + extends io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigFluentImpl< + io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested> + implements io.kubernetes.client.openapi.models.V1WebhookConversionFluent.ClientConfigNested< + N>, + io.kubernetes.client.fluent.Nested { + ClientConfigNestedImpl( + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig item) { + this.builder = + new io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigBuilder( + this, item); } + ClientConfigNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigBuilder(this); } + io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfigBuilder builder; + public N and() { return (N) V1WebhookConversionFluentImpl.this.withClientConfig(builder.build()); } + public N endClientConfig() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WeightedPodAffinityTermBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WeightedPodAffinityTermBuilder.java index 1e67e6980d..1842d0bf43 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WeightedPodAffinityTermBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WeightedPodAffinityTermBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1WeightedPodAffinityTermBuilder extends io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1WeightedPodAffinityTermBuilder + extends io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluentImpl< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm, + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermBuilder> { public V1WeightedPodAffinityTermBuilder() { this(false); } + public V1WeightedPodAffinityTermBuilder(java.lang.Boolean validationEnabled) { this(new V1WeightedPodAffinityTerm(), validationEnabled); } - public V1WeightedPodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent fluent) { + + public V1WeightedPodAffinityTermBuilder( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent fluent) { this(fluent, false); } - public V1WeightedPodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent fluent,java.lang.Boolean validationEnabled) { + + public V1WeightedPodAffinityTermBuilder( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1WeightedPodAffinityTerm(), validationEnabled); } - public V1WeightedPodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent fluent,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm instance) { + + public V1WeightedPodAffinityTermBuilder( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent fluent, + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm instance) { this(fluent, instance, false); } - public V1WeightedPodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent fluent,io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1WeightedPodAffinityTermBuilder( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent fluent, + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPodAffinityTerm(instance.getPodAffinityTerm()); fluent.withWeight(instance.getWeight()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1WeightedPodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm instance) { - this(instance,false); + + public V1WeightedPodAffinityTermBuilder( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm instance) { + this(instance, false); } - public V1WeightedPodAffinityTermBuilder(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1WeightedPodAffinityTermBuilder( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPodAffinityTerm(instance.getPodAffinityTerm()); this.withWeight(instance.getWeight()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm build() { V1WeightedPodAffinityTerm buildable = new V1WeightedPodAffinityTerm(); buildable.setPodAffinityTerm(fluent.getPodAffinityTerm()); buildable.setWeight(fluent.getWeight()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1WeightedPodAffinityTermBuilder that = (V1WeightedPodAffinityTermBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WeightedPodAffinityTermFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WeightedPodAffinityTermFluent.java index 8b91f4e5e3..3f841848db 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WeightedPodAffinityTermFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WeightedPodAffinityTermFluent.java @@ -1,39 +1,71 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1WeightedPodAffinityTermFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1WeightedPodAffinityTermFluent< + A extends io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildPodAffinityTerm instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodAffinityTerm getPodAffinityTerm(); + public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildPodAffinityTerm(); - public A withPodAffinityTerm(io.kubernetes.client.openapi.models.V1PodAffinityTerm podAffinityTerm); + + public A withPodAffinityTerm( + io.kubernetes.client.openapi.models.V1PodAffinityTerm podAffinityTerm); + public java.lang.Boolean hasPodAffinityTerm(); - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested withNewPodAffinityTerm(); - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested withNewPodAffinityTermLike(io.kubernetes.client.openapi.models.V1PodAffinityTerm item); - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested editPodAffinityTerm(); - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested editOrNewPodAffinityTerm(); - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested editOrNewPodAffinityTermLike(io.kubernetes.client.openapi.models.V1PodAffinityTerm item); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested< + A> + withNewPodAffinityTerm(); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested< + A> + withNewPodAffinityTermLike(io.kubernetes.client.openapi.models.V1PodAffinityTerm item); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested< + A> + editPodAffinityTerm(); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested< + A> + editOrNewPodAffinityTerm(); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested< + A> + editOrNewPodAffinityTermLike(io.kubernetes.client.openapi.models.V1PodAffinityTerm item); + public java.lang.Integer getWeight(); + public A withWeight(java.lang.Integer weight); + public java.lang.Boolean hasWeight(); - public interface PodAffinityTermNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1PodAffinityTermFluent>{ + + public interface PodAffinityTermNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1PodAffinityTermFluent< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent + .PodAffinityTermNested< + N>> { public N and(); + public N endPodAffinityTerm(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WeightedPodAffinityTermFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WeightedPodAffinityTermFluentImpl.java index 1a705ed283..55dffe9f2c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WeightedPodAffinityTermFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WeightedPodAffinityTermFluentImpl.java @@ -1,95 +1,150 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1WeightedPodAffinityTermFluentImpl< + A extends io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent { + public V1WeightedPodAffinityTermFluentImpl() {} - /** - * Generated - */ -public class V1WeightedPodAffinityTermFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent{ - public V1WeightedPodAffinityTermFluentImpl() { - } - public V1WeightedPodAffinityTermFluentImpl(io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm instance) { + public V1WeightedPodAffinityTermFluentImpl( + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTerm instance) { this.withPodAffinityTerm(instance.getPodAffinityTerm()); this.withWeight(instance.getWeight()); - } + private io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder podAffinityTerm; private java.lang.Integer weight; - + /** * This method has been deprecated, please use method buildPodAffinityTerm instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1PodAffinityTerm getPodAffinityTerm() { - return this.podAffinityTerm!=null ?this.podAffinityTerm.build():null; + return this.podAffinityTerm != null ? this.podAffinityTerm.build() : null; } + public io.kubernetes.client.openapi.models.V1PodAffinityTerm buildPodAffinityTerm() { - return this.podAffinityTerm!=null ?this.podAffinityTerm.build():null; + return this.podAffinityTerm != null ? this.podAffinityTerm.build() : null; } - public A withPodAffinityTerm(io.kubernetes.client.openapi.models.V1PodAffinityTerm podAffinityTerm) { + + public A withPodAffinityTerm( + io.kubernetes.client.openapi.models.V1PodAffinityTerm podAffinityTerm) { _visitables.get("podAffinityTerm").remove(this.podAffinityTerm); - if (podAffinityTerm!=null){ this.podAffinityTerm= new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(podAffinityTerm); _visitables.get("podAffinityTerm").add(this.podAffinityTerm);} return (A) this; + if (podAffinityTerm != null) { + this.podAffinityTerm = + new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(podAffinityTerm); + _visitables.get("podAffinityTerm").add(this.podAffinityTerm); + } + return (A) this; } + public java.lang.Boolean hasPodAffinityTerm() { return this.podAffinityTerm != null; } - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested withNewPodAffinityTerm() { - return new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluentImpl.PodAffinityTermNestedImpl(); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested< + A> + withNewPodAffinityTerm() { + return new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluentImpl + .PodAffinityTermNestedImpl(); } - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested withNewPodAffinityTermLike(io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { - return new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluentImpl.PodAffinityTermNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested< + A> + withNewPodAffinityTermLike(io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { + return new io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluentImpl + .PodAffinityTermNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested editPodAffinityTerm() { + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested< + A> + editPodAffinityTerm() { return withNewPodAffinityTermLike(getPodAffinityTerm()); } - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested editOrNewPodAffinityTerm() { - return withNewPodAffinityTermLike(getPodAffinityTerm() != null ? getPodAffinityTerm(): new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder().build()); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested< + A> + editOrNewPodAffinityTerm() { + return withNewPodAffinityTermLike( + getPodAffinityTerm() != null + ? getPodAffinityTerm() + : new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder().build()); } - public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested editOrNewPodAffinityTermLike(io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { - return withNewPodAffinityTermLike(getPodAffinityTerm() != null ? getPodAffinityTerm(): item); + + public io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested< + A> + editOrNewPodAffinityTermLike(io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { + return withNewPodAffinityTermLike(getPodAffinityTerm() != null ? getPodAffinityTerm() : item); } + public java.lang.Integer getWeight() { return this.weight; } + public A withWeight(java.lang.Integer weight) { - this.weight=weight; return (A) this; + this.weight = weight; + return (A) this; } + public java.lang.Boolean hasWeight() { return this.weight != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1WeightedPodAffinityTermFluentImpl that = (V1WeightedPodAffinityTermFluentImpl) o; - if (podAffinityTerm != null ? !podAffinityTerm.equals(that.podAffinityTerm) :that.podAffinityTerm != null) return false; - if (weight != null ? !weight.equals(that.weight) :that.weight != null) return false; + if (podAffinityTerm != null + ? !podAffinityTerm.equals(that.podAffinityTerm) + : that.podAffinityTerm != null) return false; + if (weight != null ? !weight.equals(that.weight) : that.weight != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(podAffinityTerm, weight, super.hashCode()); + return java.util.Objects.hash(podAffinityTerm, weight, super.hashCode()); } - public class PodAffinityTermNestedImpl extends io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl> implements io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested,io.kubernetes.client.fluent.Nested{ + + public class PodAffinityTermNestedImpl + extends io.kubernetes.client.openapi.models.V1PodAffinityTermFluentImpl< + io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent.PodAffinityTermNested< + N>> + implements io.kubernetes.client.openapi.models.V1WeightedPodAffinityTermFluent + .PodAffinityTermNested< + N>, + io.kubernetes.client.fluent.Nested { PodAffinityTermNestedImpl(io.kubernetes.client.openapi.models.V1PodAffinityTerm item) { this.builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(this, item); } + PodAffinityTermNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder(this); } + io.kubernetes.client.openapi.models.V1PodAffinityTermBuilder builder; + public N and() { return (N) V1WeightedPodAffinityTermFluentImpl.this.withPodAffinityTerm(builder.build()); } + public N endPodAffinityTerm() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WindowsSecurityContextOptionsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WindowsSecurityContextOptionsBuilder.java index c93cb1c7e6..5aed05058b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WindowsSecurityContextOptionsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WindowsSecurityContextOptionsBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1WindowsSecurityContextOptionsBuilder extends io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1WindowsSecurityContextOptionsBuilder + extends io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions, + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsBuilder> { public V1WindowsSecurityContextOptionsBuilder() { this(false); } + public V1WindowsSecurityContextOptionsBuilder(java.lang.Boolean validationEnabled) { this(new V1WindowsSecurityContextOptions(), validationEnabled); } - public V1WindowsSecurityContextOptionsBuilder(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent fluent) { + + public V1WindowsSecurityContextOptionsBuilder( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent fluent) { this(fluent, false); } - public V1WindowsSecurityContextOptionsBuilder(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1WindowsSecurityContextOptionsBuilder( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1WindowsSecurityContextOptions(), validationEnabled); } - public V1WindowsSecurityContextOptionsBuilder(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent fluent,io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions instance) { + + public V1WindowsSecurityContextOptionsBuilder( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions instance) { this(fluent, instance, false); } - public V1WindowsSecurityContextOptionsBuilder(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent fluent,io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1WindowsSecurityContextOptionsBuilder( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withGmsaCredentialSpec(instance.getGmsaCredentialSpec()); fluent.withGmsaCredentialSpecName(instance.getGmsaCredentialSpecName()); @@ -29,13 +56,18 @@ public V1WindowsSecurityContextOptionsBuilder(io.kubernetes.client.openapi.model fluent.withRunAsUserName(instance.getRunAsUserName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1WindowsSecurityContextOptionsBuilder(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions instance) { - this(instance,false); + + public V1WindowsSecurityContextOptionsBuilder( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions instance) { + this(instance, false); } - public V1WindowsSecurityContextOptionsBuilder(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1WindowsSecurityContextOptionsBuilder( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withGmsaCredentialSpec(instance.getGmsaCredentialSpec()); this.withGmsaCredentialSpecName(instance.getGmsaCredentialSpecName()); @@ -44,10 +76,12 @@ public V1WindowsSecurityContextOptionsBuilder(io.kubernetes.client.openapi.model this.withRunAsUserName(instance.getRunAsUserName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions build() { V1WindowsSecurityContextOptions buildable = new V1WindowsSecurityContextOptions(); buildable.setGmsaCredentialSpec(fluent.getGmsaCredentialSpec()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions build buildable.setRunAsUserName(fluent.getRunAsUserName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1WindowsSecurityContextOptionsBuilder that = (V1WindowsSecurityContextOptionsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WindowsSecurityContextOptionsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WindowsSecurityContextOptionsFluent.java index e29e11e892..a66dc50615 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WindowsSecurityContextOptionsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WindowsSecurityContextOptionsFluent.java @@ -1,44 +1,54 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1WindowsSecurityContextOptionsFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1WindowsSecurityContextOptionsFluent< + A extends io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getGmsaCredentialSpec(); + public A withGmsaCredentialSpec(java.lang.String gmsaCredentialSpec); + public java.lang.Boolean hasGmsaCredentialSpec(); - - /** - * Method is deprecated. use withGmsaCredentialSpec instead. - */ + + /** Method is deprecated. use withGmsaCredentialSpec instead. */ @java.lang.Deprecated public A withNewGmsaCredentialSpec(java.lang.String original); + public java.lang.String getGmsaCredentialSpecName(); + public A withGmsaCredentialSpecName(java.lang.String gmsaCredentialSpecName); + public java.lang.Boolean hasGmsaCredentialSpecName(); - - /** - * Method is deprecated. use withGmsaCredentialSpecName instead. - */ + + /** Method is deprecated. use withGmsaCredentialSpecName instead. */ @java.lang.Deprecated public A withNewGmsaCredentialSpecName(java.lang.String original); + public java.lang.Boolean getHostProcess(); + public A withHostProcess(java.lang.Boolean hostProcess); + public java.lang.Boolean hasHostProcess(); + public java.lang.String getRunAsUserName(); + public A withRunAsUserName(java.lang.String runAsUserName); + public java.lang.Boolean hasRunAsUserName(); - - /** - * Method is deprecated. use withRunAsUserName instead. - */ + + /** Method is deprecated. use withRunAsUserName instead. */ @java.lang.Deprecated public A withNewRunAsUserName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WindowsSecurityContextOptionsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WindowsSecurityContextOptionsFluentImpl.java index 5f8878a4cb..dd5bef565d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WindowsSecurityContextOptionsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1WindowsSecurityContextOptionsFluentImpl.java @@ -1,18 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1WindowsSecurityContextOptionsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent { + public V1WindowsSecurityContextOptionsFluentImpl() {} - /** - * Generated - */ -public class V1WindowsSecurityContextOptionsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptionsFluent{ - public V1WindowsSecurityContextOptionsFluentImpl() { - } - public V1WindowsSecurityContextOptionsFluentImpl(io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions instance) { + public V1WindowsSecurityContextOptionsFluentImpl( + io.kubernetes.client.openapi.models.V1WindowsSecurityContextOptions instance) { this.withGmsaCredentialSpec(instance.getGmsaCredentialSpec()); this.withGmsaCredentialSpecName(instance.getGmsaCredentialSpecName()); @@ -20,84 +28,103 @@ public V1WindowsSecurityContextOptionsFluentImpl(io.kubernetes.client.openapi.mo this.withHostProcess(instance.getHostProcess()); this.withRunAsUserName(instance.getRunAsUserName()); - } + private java.lang.String gmsaCredentialSpec; private java.lang.String gmsaCredentialSpecName; private java.lang.Boolean hostProcess; private java.lang.String runAsUserName; + public java.lang.String getGmsaCredentialSpec() { return this.gmsaCredentialSpec; } + public A withGmsaCredentialSpec(java.lang.String gmsaCredentialSpec) { - this.gmsaCredentialSpec=gmsaCredentialSpec; return (A) this; + this.gmsaCredentialSpec = gmsaCredentialSpec; + return (A) this; } + public java.lang.Boolean hasGmsaCredentialSpec() { return this.gmsaCredentialSpec != null; } - - /** - * Method is deprecated. use withGmsaCredentialSpec instead. - */ + + /** Method is deprecated. use withGmsaCredentialSpec instead. */ @java.lang.Deprecated public A withNewGmsaCredentialSpec(java.lang.String original) { - return (A)withGmsaCredentialSpec(new String(original)); + return (A) withGmsaCredentialSpec(new String(original)); } + public java.lang.String getGmsaCredentialSpecName() { return this.gmsaCredentialSpecName; } + public A withGmsaCredentialSpecName(java.lang.String gmsaCredentialSpecName) { - this.gmsaCredentialSpecName=gmsaCredentialSpecName; return (A) this; + this.gmsaCredentialSpecName = gmsaCredentialSpecName; + return (A) this; } + public java.lang.Boolean hasGmsaCredentialSpecName() { return this.gmsaCredentialSpecName != null; } - - /** - * Method is deprecated. use withGmsaCredentialSpecName instead. - */ + + /** Method is deprecated. use withGmsaCredentialSpecName instead. */ @java.lang.Deprecated public A withNewGmsaCredentialSpecName(java.lang.String original) { - return (A)withGmsaCredentialSpecName(new String(original)); + return (A) withGmsaCredentialSpecName(new String(original)); } + public java.lang.Boolean getHostProcess() { return this.hostProcess; } + public A withHostProcess(java.lang.Boolean hostProcess) { - this.hostProcess=hostProcess; return (A) this; + this.hostProcess = hostProcess; + return (A) this; } + public java.lang.Boolean hasHostProcess() { return this.hostProcess != null; } + public java.lang.String getRunAsUserName() { return this.runAsUserName; } + public A withRunAsUserName(java.lang.String runAsUserName) { - this.runAsUserName=runAsUserName; return (A) this; + this.runAsUserName = runAsUserName; + return (A) this; } + public java.lang.Boolean hasRunAsUserName() { return this.runAsUserName != null; } - - /** - * Method is deprecated. use withRunAsUserName instead. - */ + + /** Method is deprecated. use withRunAsUserName instead. */ @java.lang.Deprecated public A withNewRunAsUserName(java.lang.String original) { - return (A)withRunAsUserName(new String(original)); + return (A) withRunAsUserName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1WindowsSecurityContextOptionsFluentImpl that = (V1WindowsSecurityContextOptionsFluentImpl) o; - if (gmsaCredentialSpec != null ? !gmsaCredentialSpec.equals(that.gmsaCredentialSpec) :that.gmsaCredentialSpec != null) return false; - if (gmsaCredentialSpecName != null ? !gmsaCredentialSpecName.equals(that.gmsaCredentialSpecName) :that.gmsaCredentialSpecName != null) return false; - if (hostProcess != null ? !hostProcess.equals(that.hostProcess) :that.hostProcess != null) return false; - if (runAsUserName != null ? !runAsUserName.equals(that.runAsUserName) :that.runAsUserName != null) return false; + if (gmsaCredentialSpec != null + ? !gmsaCredentialSpec.equals(that.gmsaCredentialSpec) + : that.gmsaCredentialSpec != null) return false; + if (gmsaCredentialSpecName != null + ? !gmsaCredentialSpecName.equals(that.gmsaCredentialSpecName) + : that.gmsaCredentialSpecName != null) return false; + if (hostProcess != null ? !hostProcess.equals(that.hostProcess) : that.hostProcess != null) + return false; + if (runAsUserName != null + ? !runAsUserName.equals(that.runAsUserName) + : that.runAsUserName != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(gmsaCredentialSpec, gmsaCredentialSpecName, hostProcess, runAsUserName, super.hashCode()); + return java.util.Objects.hash( + gmsaCredentialSpec, gmsaCredentialSpecName, hostProcess, runAsUserName, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityBuilder.java index aa9a06f80b..8cc7f2ecee 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1alpha1CSIStorageCapacityBuilder extends io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1alpha1CSIStorageCapacityBuilder + extends io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity, + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder> { public V1alpha1CSIStorageCapacityBuilder() { this(false); } + public V1alpha1CSIStorageCapacityBuilder(java.lang.Boolean validationEnabled) { this(new V1alpha1CSIStorageCapacity(), validationEnabled); } - public V1alpha1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent fluent) { + + public V1alpha1CSIStorageCapacityBuilder( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent fluent) { this(fluent, false); } - public V1alpha1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent fluent,java.lang.Boolean validationEnabled) { + + public V1alpha1CSIStorageCapacityBuilder( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1alpha1CSIStorageCapacity(), validationEnabled); } - public V1alpha1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent fluent,io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity instance) { + + public V1alpha1CSIStorageCapacityBuilder( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity instance) { this(fluent, instance, false); } - public V1alpha1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent fluent,io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1alpha1CSIStorageCapacityBuilder( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withCapacity(instance.getCapacity()); @@ -35,13 +62,18 @@ public V1alpha1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1a fluent.withStorageClassName(instance.getStorageClassName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1alpha1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity instance) { - this(instance,false); + + public V1alpha1CSIStorageCapacityBuilder( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity instance) { + this(instance, false); } - public V1alpha1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1alpha1CSIStorageCapacityBuilder( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withCapacity(instance.getCapacity()); @@ -56,10 +88,12 @@ public V1alpha1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1a this.withStorageClassName(instance.getStorageClassName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity build() { V1alpha1CSIStorageCapacity buildable = new V1alpha1CSIStorageCapacity(); buildable.setApiVersion(fluent.getApiVersion()); @@ -71,18 +105,23 @@ public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity build() { buildable.setStorageClassName(fluent.getStorageClassName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1alpha1CSIStorageCapacityBuilder that = (V1alpha1CSIStorageCapacityBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityFluent.java index 9872b073b5..0415e5b86b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityFluent.java @@ -1,91 +1,143 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1alpha1CSIStorageCapacityFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1alpha1CSIStorageCapacityFluent< + A extends io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public io.kubernetes.client.custom.Quantity getCapacity(); + public A withCapacity(io.kubernetes.client.custom.Quantity capacity); + public java.lang.Boolean hasCapacity(); + public A withNewCapacity(java.lang.String value); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public io.kubernetes.client.custom.Quantity getMaximumVolumeSize(); + public A withMaximumVolumeSize(io.kubernetes.client.custom.Quantity maximumVolumeSize); + public java.lang.Boolean hasMaximumVolumeSize(); + public A withNewMaximumVolumeSize(java.lang.String value); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildNodeTopology instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getNodeTopology(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildNodeTopology(); + public A withNodeTopology(io.kubernetes.client.openapi.models.V1LabelSelector nodeTopology); + public java.lang.Boolean hasNodeTopology(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested withNewNodeTopology(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested withNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested editNodeTopology(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested editOrNewNodeTopology(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested editOrNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested + withNewNodeTopology(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested + withNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested + editNodeTopology(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested + editOrNewNodeTopology(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested + editOrNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + public java.lang.String getStorageClassName(); + public A withStorageClassName(java.lang.String storageClassName); + public java.lang.Boolean hasStorageClassName(); - - /** - * Method is deprecated. use withStorageClassName instead. - */ + + /** Method is deprecated. use withStorageClassName instead. */ @java.lang.Deprecated public A withNewStorageClassName(java.lang.String original); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface NodeTopologyNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface NodeTopologyNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent + .NodeTopologyNested< + N>> { public N and(); + public N endNodeTopology(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityFluentImpl.java index 03401377d5..3ccb4e04a4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityFluentImpl.java @@ -1,20 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1alpha1CSIStorageCapacityFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent{ - public V1alpha1CSIStorageCapacityFluentImpl() { - } - public V1alpha1CSIStorageCapacityFluentImpl(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity instance) { + +/** Generated */ +public class V1alpha1CSIStorageCapacityFluentImpl< + A extends io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent { + public V1alpha1CSIStorageCapacityFluentImpl() {} + + public V1alpha1CSIStorageCapacityFluentImpl( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity instance) { this.withApiVersion(instance.getApiVersion()); this.withCapacity(instance.getCapacity()); @@ -28,8 +36,8 @@ public V1alpha1CSIStorageCapacityFluentImpl(io.kubernetes.client.openapi.models. this.withNodeTopology(instance.getNodeTopology()); this.withStorageClassName(instance.getStorageClassName()); - } + private java.lang.String apiVersion; private io.kubernetes.client.custom.Quantity capacity; private java.lang.String kind; @@ -37,196 +45,295 @@ public V1alpha1CSIStorageCapacityFluentImpl(io.kubernetes.client.openapi.models. private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder nodeTopology; private java.lang.String storageClassName; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public io.kubernetes.client.custom.Quantity getCapacity() { return this.capacity; } + public A withCapacity(io.kubernetes.client.custom.Quantity capacity) { - this.capacity=capacity; return (A) this; + this.capacity = capacity; + return (A) this; } + public java.lang.Boolean hasCapacity() { return this.capacity != null; } + public A withNewCapacity(java.lang.String value) { - return (A)withCapacity(new Quantity(value)); + return (A) withCapacity(new Quantity(value)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public io.kubernetes.client.custom.Quantity getMaximumVolumeSize() { return this.maximumVolumeSize; } + public A withMaximumVolumeSize(io.kubernetes.client.custom.Quantity maximumVolumeSize) { - this.maximumVolumeSize=maximumVolumeSize; return (A) this; + this.maximumVolumeSize = maximumVolumeSize; + return (A) this; } + public java.lang.Boolean hasMaximumVolumeSize() { return this.maximumVolumeSize != null; } + public A withNewMaximumVolumeSize(java.lang.String value) { - return (A)withMaximumVolumeSize(new Quantity(value)); + return (A) withMaximumVolumeSize(new Quantity(value)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildNodeTopology instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getNodeTopology() { - return this.nodeTopology!=null ?this.nodeTopology.build():null; + return this.nodeTopology != null ? this.nodeTopology.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildNodeTopology() { - return this.nodeTopology!=null ?this.nodeTopology.build():null; + return this.nodeTopology != null ? this.nodeTopology.build() : null; } + public A withNodeTopology(io.kubernetes.client.openapi.models.V1LabelSelector nodeTopology) { _visitables.get("nodeTopology").remove(this.nodeTopology); - if (nodeTopology!=null){ this.nodeTopology= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(nodeTopology); _visitables.get("nodeTopology").add(this.nodeTopology);} return (A) this; + if (nodeTopology != null) { + this.nodeTopology = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(nodeTopology); + _visitables.get("nodeTopology").add(this.nodeTopology); + } + return (A) this; } + public java.lang.Boolean hasNodeTopology() { return this.nodeTopology != null; } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested withNewNodeTopology() { - return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluentImpl.NodeTopologyNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested + withNewNodeTopology() { + return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluentImpl + .NodeTopologyNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested withNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluentImpl.NodeTopologyNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested + withNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluentImpl + .NodeTopologyNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested editNodeTopology() { + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested + editNodeTopology() { return withNewNodeTopologyLike(getNodeTopology()); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested editOrNewNodeTopology() { - return withNewNodeTopologyLike(getNodeTopology() != null ? getNodeTopology(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested + editOrNewNodeTopology() { + return withNewNodeTopologyLike( + getNodeTopology() != null + ? getNodeTopology() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested editOrNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewNodeTopologyLike(getNodeTopology() != null ? getNodeTopology(): item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested + editOrNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewNodeTopologyLike(getNodeTopology() != null ? getNodeTopology() : item); } + public java.lang.String getStorageClassName() { return this.storageClassName; } + public A withStorageClassName(java.lang.String storageClassName) { - this.storageClassName=storageClassName; return (A) this; + this.storageClassName = storageClassName; + return (A) this; } + public java.lang.Boolean hasStorageClassName() { return this.storageClassName != null; } - - /** - * Method is deprecated. use withStorageClassName instead. - */ + + /** Method is deprecated. use withStorageClassName instead. */ @java.lang.Deprecated public A withNewStorageClassName(java.lang.String original) { - return (A)withStorageClassName(new String(original)); + return (A) withStorageClassName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1alpha1CSIStorageCapacityFluentImpl that = (V1alpha1CSIStorageCapacityFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (capacity != null ? !capacity.equals(that.capacity) :that.capacity != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (maximumVolumeSize != null ? !maximumVolumeSize.equals(that.maximumVolumeSize) :that.maximumVolumeSize != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (nodeTopology != null ? !nodeTopology.equals(that.nodeTopology) :that.nodeTopology != null) return false; - if (storageClassName != null ? !storageClassName.equals(that.storageClassName) :that.storageClassName != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (capacity != null ? !capacity.equals(that.capacity) : that.capacity != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (maximumVolumeSize != null + ? !maximumVolumeSize.equals(that.maximumVolumeSize) + : that.maximumVolumeSize != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (nodeTopology != null ? !nodeTopology.equals(that.nodeTopology) : that.nodeTopology != null) + return false; + if (storageClassName != null + ? !storageClassName.equals(that.storageClassName) + : that.storageClassName != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, capacity, kind, maximumVolumeSize, metadata, nodeTopology, storageClassName, super.hashCode()); + return java.util.Objects.hash( + apiVersion, + capacity, + kind, + maximumVolumeSize, + metadata, + nodeTopology, + storageClassName, + super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1alpha1CSIStorageCapacityFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class NodeTopologyNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested,io.kubernetes.client.fluent.Nested{ + + public class NodeTopologyNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent.NodeTopologyNested< + N>> + implements io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent + .NodeTopologyNested< + N>, + io.kubernetes.client.fluent.Nested { NodeTopologyNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + NodeTopologyNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1alpha1CSIStorageCapacityFluentImpl.this.withNodeTopology(builder.build()); } + public N endNodeTopology() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityListBuilder.java index 86269bdc9f..feed66efde 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1alpha1CSIStorageCapacityListBuilder extends io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1alpha1CSIStorageCapacityListBuilder + extends io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityList, + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListBuilder> { public V1alpha1CSIStorageCapacityListBuilder() { this(false); } + public V1alpha1CSIStorageCapacityListBuilder(java.lang.Boolean validationEnabled) { this(new V1alpha1CSIStorageCapacityList(), validationEnabled); } - public V1alpha1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent fluent) { + + public V1alpha1CSIStorageCapacityListBuilder( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent fluent) { this(fluent, false); } - public V1alpha1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1alpha1CSIStorageCapacityListBuilder( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1alpha1CSIStorageCapacityList(), validationEnabled); } - public V1alpha1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent fluent,io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityList instance) { + + public V1alpha1CSIStorageCapacityListBuilder( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityList instance) { this(fluent, instance, false); } - public V1alpha1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent fluent,io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1alpha1CSIStorageCapacityListBuilder( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1alpha1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1alpha1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityList instance) { - this(instance,false); + + public V1alpha1CSIStorageCapacityListBuilder( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityList instance) { + this(instance, false); } - public V1alpha1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1alpha1CSIStorageCapacityListBuilder( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1alpha1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityList build() { V1alpha1CSIStorageCapacityList buildable = new V1alpha1CSIStorageCapacityList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityList build( buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1alpha1CSIStorageCapacityListBuilder that = (V1alpha1CSIStorageCapacityListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityListFluent.java index 1712eec02b..205de77866 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityListFluent.java @@ -1,95 +1,170 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1alpha1CSIStorageCapacityListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1alpha1CSIStorageCapacityListFluent< + A extends io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item); + public A addToItems(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); - public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity buildItem(java.lang.Integer index); + + public java.util.List + buildItems(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity buildFirstItem(); + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity buildLastItem(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent>{ + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluent< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityListFluentImpl.java index 131c82a58f..5faec84414 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1CSIStorageCapacityListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1alpha1CSIStorageCapacityListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent{ - public V1alpha1CSIStorageCapacityListFluentImpl() { - } - public V1alpha1CSIStorageCapacityListFluentImpl(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityList instance) { + +/** Generated */ +public class V1alpha1CSIStorageCapacityListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent { + public V1alpha1CSIStorageCapacityListFluentImpl() {} + + public V1alpha1CSIStorageCapacityListFluentImpl( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,135 @@ public V1alpha1CSIStorageCapacityListFluentImpl(io.kubernetes.client.openapi.mod this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder>(); + } + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder>(); + } + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item : items) {io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item : items) { + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item : items) {io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item : items) { + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A removeFromItems(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity... items) { - for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item : items) {io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeFromItems( + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity... items) { + for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item : items) { + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item : items) {io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item : items) { + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder = each.next(); @@ -87,174 +168,297 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } - public java.util.List buildItems() { + + public java.util.List + buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item) { - return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item) { + return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item) { - return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item) { + return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1alpha1CSIStorageCapacityListFluentImpl that = (V1alpha1CSIStorageCapacityListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent + .ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacity item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder(this); } + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1alpha1CSIStorageCapacityListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1alpha1CSIStorageCapacityListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent.MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V1alpha1CSIStorageCapacityListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1alpha1CSIStorageCapacityListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1OverheadBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1OverheadBuilder.java index 1a36b3e78b..6507df111e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1OverheadBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1OverheadBuilder.java @@ -1,58 +1,96 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1alpha1OverheadBuilder extends io.kubernetes.client.openapi.models.V1alpha1OverheadFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1alpha1OverheadBuilder + extends io.kubernetes.client.openapi.models.V1alpha1OverheadFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1OverheadBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1alpha1Overhead, + io.kubernetes.client.openapi.models.V1alpha1OverheadBuilder> { public V1alpha1OverheadBuilder() { this(false); } + public V1alpha1OverheadBuilder(java.lang.Boolean validationEnabled) { this(new V1alpha1Overhead(), validationEnabled); } - public V1alpha1OverheadBuilder(io.kubernetes.client.openapi.models.V1alpha1OverheadFluent fluent) { + + public V1alpha1OverheadBuilder( + io.kubernetes.client.openapi.models.V1alpha1OverheadFluent fluent) { this(fluent, false); } - public V1alpha1OverheadBuilder(io.kubernetes.client.openapi.models.V1alpha1OverheadFluent fluent,java.lang.Boolean validationEnabled) { + + public V1alpha1OverheadBuilder( + io.kubernetes.client.openapi.models.V1alpha1OverheadFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1alpha1Overhead(), validationEnabled); } - public V1alpha1OverheadBuilder(io.kubernetes.client.openapi.models.V1alpha1OverheadFluent fluent,io.kubernetes.client.openapi.models.V1alpha1Overhead instance) { + + public V1alpha1OverheadBuilder( + io.kubernetes.client.openapi.models.V1alpha1OverheadFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1Overhead instance) { this(fluent, instance, false); } - public V1alpha1OverheadBuilder(io.kubernetes.client.openapi.models.V1alpha1OverheadFluent fluent,io.kubernetes.client.openapi.models.V1alpha1Overhead instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1alpha1OverheadBuilder( + io.kubernetes.client.openapi.models.V1alpha1OverheadFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1Overhead instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPodFixed(instance.getPodFixed()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1alpha1OverheadBuilder(io.kubernetes.client.openapi.models.V1alpha1Overhead instance) { - this(instance,false); + this(instance, false); } - public V1alpha1OverheadBuilder(io.kubernetes.client.openapi.models.V1alpha1Overhead instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1alpha1OverheadBuilder( + io.kubernetes.client.openapi.models.V1alpha1Overhead instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPodFixed(instance.getPodFixed()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1alpha1OverheadFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1alpha1Overhead build() { V1alpha1Overhead buildable = new V1alpha1Overhead(); buildable.setPodFixed(fluent.getPodFixed()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1alpha1OverheadBuilder that = (V1alpha1OverheadBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1OverheadFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1OverheadFluent.java index 6f70663056..9de218060d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1OverheadFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1OverheadFluent.java @@ -1,23 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; -import java.util.Map; -import java.util.LinkedHashMap; +/** Generated */ +public interface V1alpha1OverheadFluent< + A extends io.kubernetes.client.openapi.models.V1alpha1OverheadFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToPodFixed(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToPodFixed(java.util.Map map); - /** - * Generated - */ -public interface V1alpha1OverheadFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToPodFixed(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToPodFixed(java.util.Map map); public A removeFromPodFixed(java.lang.String key); - public A removeFromPodFixed(java.util.Map map); - public java.util.Map getPodFixed(); - public A withPodFixed(java.util.Map podFixed); + + public A removeFromPodFixed( + java.util.Map map); + + public java.util.Map getPodFixed(); + + public A withPodFixed( + java.util.Map podFixed); + public java.lang.Boolean hasPodFixed(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1OverheadFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1OverheadFluentImpl.java index 0ffc1e42d0..288734b4ce 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1OverheadFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1OverheadFluentImpl.java @@ -1,58 +1,103 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.BaseFluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; -import java.util.Map; -import java.util.LinkedHashMap; +/** Generated */ +public class V1alpha1OverheadFluentImpl< + A extends io.kubernetes.client.openapi.models.V1alpha1OverheadFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1alpha1OverheadFluent { + public V1alpha1OverheadFluentImpl() {} - /** - * Generated - */ -public class V1alpha1OverheadFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1alpha1OverheadFluent{ - public V1alpha1OverheadFluentImpl() { - } public V1alpha1OverheadFluentImpl(io.kubernetes.client.openapi.models.V1alpha1Overhead instance) { this.withPodFixed(instance.getPodFixed()); - } - private java.util.Map podFixed; - public A addToPodFixed(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.podFixed == null && key != null && value != null) { this.podFixed = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.podFixed.put(key, value);} return (A)this; + + private java.util.Map podFixed; + + public A addToPodFixed(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.podFixed == null && key != null && value != null) { + this.podFixed = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.podFixed.put(key, value); + } + return (A) this; } - public A addToPodFixed(java.util.Map map) { - if(this.podFixed == null && map != null) { this.podFixed = new java.util.LinkedHashMap(); } - if(map != null) { this.podFixed.putAll(map);} return (A)this; + + public A addToPodFixed( + java.util.Map map) { + if (this.podFixed == null && map != null) { + this.podFixed = new java.util.LinkedHashMap(); + } + if (map != null) { + this.podFixed.putAll(map); + } + return (A) this; } + public A removeFromPodFixed(java.lang.String key) { - if(this.podFixed == null) { return (A) this; } - if(key != null && this.podFixed != null) {this.podFixed.remove(key);} return (A)this; + if (this.podFixed == null) { + return (A) this; + } + if (key != null && this.podFixed != null) { + this.podFixed.remove(key); + } + return (A) this; } - public A removeFromPodFixed(java.util.Map map) { - if(this.podFixed == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.podFixed != null){this.podFixed.remove(key);}}} return (A)this; + + public A removeFromPodFixed( + java.util.Map map) { + if (this.podFixed == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.podFixed != null) { + this.podFixed.remove(key); + } + } + } + return (A) this; } - public java.util.Map getPodFixed() { + + public java.util.Map getPodFixed() { return this.podFixed; } - public A withPodFixed(java.util.Map podFixed) { - if (podFixed == null) { this.podFixed = null;} else {this.podFixed = new java.util.LinkedHashMap(podFixed);} return (A) this; + + public A withPodFixed( + java.util.Map podFixed) { + if (podFixed == null) { + this.podFixed = null; + } else { + this.podFixed = new java.util.LinkedHashMap(podFixed); + } + return (A) this; } + public java.lang.Boolean hasPodFixed() { return this.podFixed != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1alpha1OverheadFluentImpl that = (V1alpha1OverheadFluentImpl) o; - if (podFixed != null ? !podFixed.equals(that.podFixed) :that.podFixed != null) return false; + if (podFixed != null ? !podFixed.equals(that.podFixed) : that.podFixed != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(podFixed, super.hashCode()); + return java.util.Objects.hash(podFixed, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassBuilder.java index 47c33d78e2..2101debf49 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1alpha1RuntimeClassBuilder extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1alpha1RuntimeClassBuilder + extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClass, + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder> { public V1alpha1RuntimeClassBuilder() { this(false); } + public V1alpha1RuntimeClassBuilder(java.lang.Boolean validationEnabled) { this(new V1alpha1RuntimeClass(), validationEnabled); } - public V1alpha1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent fluent) { + + public V1alpha1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent fluent) { this(fluent, false); } - public V1alpha1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent fluent,java.lang.Boolean validationEnabled) { + + public V1alpha1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1alpha1RuntimeClass(), validationEnabled); } - public V1alpha1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent fluent,io.kubernetes.client.openapi.models.V1alpha1RuntimeClass instance) { + + public V1alpha1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1RuntimeClass instance) { this(fluent, instance, false); } - public V1alpha1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent fluent,io.kubernetes.client.openapi.models.V1alpha1RuntimeClass instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1alpha1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1RuntimeClass instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +56,18 @@ public V1alpha1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1alpha1R fluent.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1alpha1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClass instance) { - this(instance,false); + + public V1alpha1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClass instance) { + this(instance, false); } - public V1alpha1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClass instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1alpha1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClass instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +76,12 @@ public V1alpha1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1alpha1R this.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass build() { V1alpha1RuntimeClass buildable = new V1alpha1RuntimeClass(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass build() { buildable.setSpec(fluent.getSpec()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1alpha1RuntimeClassBuilder that = (V1alpha1RuntimeClassBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassFluent.java index ede6c5c09e..9a27ca36a9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassFluent.java @@ -1,73 +1,112 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1alpha1RuntimeClassFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1alpha1RuntimeClassFluent< + A extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec getSpec(); + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec item); + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested> { public N and(); + public N endSpec(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassFluentImpl.java index 2193dffb5f..1f1394e7aa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1alpha1RuntimeClassFluentImpl< + A extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent { + public V1alpha1RuntimeClassFluentImpl() {} - /** - * Generated - */ -public class V1alpha1RuntimeClassFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent{ - public V1alpha1RuntimeClassFluentImpl() { - } - public V1alpha1RuntimeClassFluentImpl(io.kubernetes.client.openapi.models.V1alpha1RuntimeClass instance) { + public V1alpha1RuntimeClassFluentImpl( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClass instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -21,158 +28,225 @@ public V1alpha1RuntimeClassFluentImpl(io.kubernetes.client.openapi.models.V1alph this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecBuilder spec; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested withNewSpec() { + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested + withNewSpec() { return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec item) { - return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec item) { + return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluentImpl.SpecNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1alpha1RuntimeClassFluentImpl that = (V1alpha1RuntimeClassFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1alpha1RuntimeClassFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecBuilder builder; + public N and() { return (N) V1alpha1RuntimeClassFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassListBuilder.java index 2dff98d8ea..521513bdd2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1alpha1RuntimeClassListBuilder extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1alpha1RuntimeClassListBuilder + extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassList, + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListBuilder> { public V1alpha1RuntimeClassListBuilder() { this(false); } + public V1alpha1RuntimeClassListBuilder(java.lang.Boolean validationEnabled) { this(new V1alpha1RuntimeClassList(), validationEnabled); } - public V1alpha1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent fluent) { + + public V1alpha1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent fluent) { this(fluent, false); } - public V1alpha1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1alpha1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1alpha1RuntimeClassList(), validationEnabled); } - public V1alpha1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent fluent,io.kubernetes.client.openapi.models.V1alpha1RuntimeClassList instance) { + + public V1alpha1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassList instance) { this(fluent, instance, false); } - public V1alpha1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent fluent,io.kubernetes.client.openapi.models.V1alpha1RuntimeClassList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1alpha1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1alpha1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1alp fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1alpha1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassList instance) { - this(instance,false); + + public V1alpha1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassList instance) { + this(instance, false); } - public V1alpha1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1alpha1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1alpha1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1alp this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassList build() { V1alpha1RuntimeClassList buildable = new V1alpha1RuntimeClassList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1alpha1RuntimeClassListBuilder that = (V1alpha1RuntimeClassListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassListFluent.java index 99fd686f9a..8a06c9f5c3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassListFluent.java @@ -1,95 +1,163 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1alpha1RuntimeClassListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1alpha1RuntimeClassListFluent< + A extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item); + public A addToItems(io.kubernetes.client.openapi.models.V1alpha1RuntimeClass... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1alpha1RuntimeClass... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass buildFirstItem(); + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass buildLastItem(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1alpha1RuntimeClass... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent>{ + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluent< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassListFluentImpl.java index ab823559e2..cd0d344002 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1alpha1RuntimeClassListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent{ - public V1alpha1RuntimeClassListFluentImpl() { - } - public V1alpha1RuntimeClassListFluentImpl(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassList instance) { + +/** Generated */ +public class V1alpha1RuntimeClassListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent { + public V1alpha1RuntimeClassListFluentImpl() {} + + public V1alpha1RuntimeClassListFluentImpl( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,131 @@ public V1alpha1RuntimeClassListFluentImpl(io.kubernetes.client.openapi.models.V1 this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder>(); + } + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder>(); + } + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1alpha1RuntimeClass... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item : items) {io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item : items) { + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item : items) {io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item : items) { + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1alpha1RuntimeClass... items) { - for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item : items) {io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item : items) { + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item : items) {io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item : items) { + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder = each.next(); @@ -87,174 +164,287 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClass buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1alpha1RuntimeClass... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item) { - return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item) { + return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item) { - return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item) { + return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1alpha1RuntimeClassListFluentImpl that = (V1alpha1RuntimeClassListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1RuntimeClass item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder(this); } + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1alpha1RuntimeClassListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1alpha1RuntimeClassListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassListFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1alpha1RuntimeClassListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassSpecBuilder.java index e5af0b1817..bc268e9e68 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassSpecBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1alpha1RuntimeClassSpecBuilder extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1alpha1RuntimeClassSpecBuilder + extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec, + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecBuilder> { public V1alpha1RuntimeClassSpecBuilder() { this(false); } + public V1alpha1RuntimeClassSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1alpha1RuntimeClassSpec(), validationEnabled); } - public V1alpha1RuntimeClassSpecBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent fluent) { + + public V1alpha1RuntimeClassSpecBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent fluent) { this(fluent, false); } - public V1alpha1RuntimeClassSpecBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1alpha1RuntimeClassSpecBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1alpha1RuntimeClassSpec(), validationEnabled); } - public V1alpha1RuntimeClassSpecBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent fluent,io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec instance) { + + public V1alpha1RuntimeClassSpecBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec instance) { this(fluent, instance, false); } - public V1alpha1RuntimeClassSpecBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent fluent,io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1alpha1RuntimeClassSpecBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withOverhead(instance.getOverhead()); fluent.withRuntimeHandler(instance.getRuntimeHandler()); fluent.withScheduling(instance.getScheduling()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1alpha1RuntimeClassSpecBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec instance) { - this(instance,false); + + public V1alpha1RuntimeClassSpecBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec instance) { + this(instance, false); } - public V1alpha1RuntimeClassSpecBuilder(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1alpha1RuntimeClassSpecBuilder( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withOverhead(instance.getOverhead()); this.withRuntimeHandler(instance.getRuntimeHandler()); this.withScheduling(instance.getScheduling()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec build() { V1alpha1RuntimeClassSpec buildable = new V1alpha1RuntimeClassSpec(); buildable.setOverhead(fluent.getOverhead()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec build() { buildable.setScheduling(fluent.getScheduling()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1alpha1RuntimeClassSpecBuilder that = (V1alpha1RuntimeClassSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassSpecFluent.java index 015abc03eb..1cfc08faab 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassSpecFluent.java @@ -1,64 +1,107 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1alpha1RuntimeClassSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1alpha1RuntimeClassSpecFluent< + A extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildOverhead instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1alpha1Overhead getOverhead(); + public io.kubernetes.client.openapi.models.V1alpha1Overhead buildOverhead(); + public A withOverhead(io.kubernetes.client.openapi.models.V1alpha1Overhead overhead); + public java.lang.Boolean hasOverhead(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested withNewOverhead(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested withNewOverheadLike(io.kubernetes.client.openapi.models.V1alpha1Overhead item); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested editOverhead(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested editOrNewOverhead(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested editOrNewOverheadLike(io.kubernetes.client.openapi.models.V1alpha1Overhead item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested + withNewOverhead(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested + withNewOverheadLike(io.kubernetes.client.openapi.models.V1alpha1Overhead item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested + editOverhead(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested + editOrNewOverhead(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested + editOrNewOverheadLike(io.kubernetes.client.openapi.models.V1alpha1Overhead item); + public java.lang.String getRuntimeHandler(); + public A withRuntimeHandler(java.lang.String runtimeHandler); + public java.lang.Boolean hasRuntimeHandler(); - - /** - * Method is deprecated. use withRuntimeHandler instead. - */ + + /** Method is deprecated. use withRuntimeHandler instead. */ @java.lang.Deprecated public A withNewRuntimeHandler(java.lang.String original); - + /** * This method has been deprecated, please use method buildScheduling instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1alpha1Scheduling getScheduling(); + public io.kubernetes.client.openapi.models.V1alpha1Scheduling buildScheduling(); + public A withScheduling(io.kubernetes.client.openapi.models.V1alpha1Scheduling scheduling); + public java.lang.Boolean hasScheduling(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested withNewScheduling(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested withNewSchedulingLike(io.kubernetes.client.openapi.models.V1alpha1Scheduling item); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested editScheduling(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested editOrNewScheduling(); - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested editOrNewSchedulingLike(io.kubernetes.client.openapi.models.V1alpha1Scheduling item); - public interface OverheadNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1alpha1OverheadFluent>{ + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested + withNewScheduling(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested + withNewSchedulingLike(io.kubernetes.client.openapi.models.V1alpha1Scheduling item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested + editScheduling(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested + editOrNewScheduling(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested + editOrNewSchedulingLike(io.kubernetes.client.openapi.models.V1alpha1Scheduling item); + + public interface OverheadNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1alpha1OverheadFluent< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested< + N>> { public N and(); + public N endOverhead(); - } - public interface SchedulingNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent>{ + + public interface SchedulingNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested< + N>> { public N and(); + public N endScheduling(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassSpecFluentImpl.java index c5c45179cc..9633bb0baf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1RuntimeClassSpecFluentImpl.java @@ -1,157 +1,236 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1alpha1RuntimeClassSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent { + public V1alpha1RuntimeClassSpecFluentImpl() {} - /** - * Generated - */ -public class V1alpha1RuntimeClassSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent{ - public V1alpha1RuntimeClassSpecFluentImpl() { - } - public V1alpha1RuntimeClassSpecFluentImpl(io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec instance) { + public V1alpha1RuntimeClassSpecFluentImpl( + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpec instance) { this.withOverhead(instance.getOverhead()); this.withRuntimeHandler(instance.getRuntimeHandler()); this.withScheduling(instance.getScheduling()); - } + private io.kubernetes.client.openapi.models.V1alpha1OverheadBuilder overhead; private java.lang.String runtimeHandler; private io.kubernetes.client.openapi.models.V1alpha1SchedulingBuilder scheduling; - + /** * This method has been deprecated, please use method buildOverhead instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1alpha1Overhead getOverhead() { - return this.overhead!=null ?this.overhead.build():null; + return this.overhead != null ? this.overhead.build() : null; } + public io.kubernetes.client.openapi.models.V1alpha1Overhead buildOverhead() { - return this.overhead!=null ?this.overhead.build():null; + return this.overhead != null ? this.overhead.build() : null; } + public A withOverhead(io.kubernetes.client.openapi.models.V1alpha1Overhead overhead) { _visitables.get("overhead").remove(this.overhead); - if (overhead!=null){ this.overhead= new io.kubernetes.client.openapi.models.V1alpha1OverheadBuilder(overhead); _visitables.get("overhead").add(this.overhead);} return (A) this; + if (overhead != null) { + this.overhead = new io.kubernetes.client.openapi.models.V1alpha1OverheadBuilder(overhead); + _visitables.get("overhead").add(this.overhead); + } + return (A) this; } + public java.lang.Boolean hasOverhead() { return this.overhead != null; } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested withNewOverhead() { - return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluentImpl.OverheadNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested + withNewOverhead() { + return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluentImpl + .OverheadNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested withNewOverheadLike(io.kubernetes.client.openapi.models.V1alpha1Overhead item) { - return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluentImpl.OverheadNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested + withNewOverheadLike(io.kubernetes.client.openapi.models.V1alpha1Overhead item) { + return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluentImpl + .OverheadNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested editOverhead() { + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested + editOverhead() { return withNewOverheadLike(getOverhead()); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested editOrNewOverhead() { - return withNewOverheadLike(getOverhead() != null ? getOverhead(): new io.kubernetes.client.openapi.models.V1alpha1OverheadBuilder().build()); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested + editOrNewOverhead() { + return withNewOverheadLike( + getOverhead() != null + ? getOverhead() + : new io.kubernetes.client.openapi.models.V1alpha1OverheadBuilder().build()); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested editOrNewOverheadLike(io.kubernetes.client.openapi.models.V1alpha1Overhead item) { - return withNewOverheadLike(getOverhead() != null ? getOverhead(): item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested + editOrNewOverheadLike(io.kubernetes.client.openapi.models.V1alpha1Overhead item) { + return withNewOverheadLike(getOverhead() != null ? getOverhead() : item); } + public java.lang.String getRuntimeHandler() { return this.runtimeHandler; } + public A withRuntimeHandler(java.lang.String runtimeHandler) { - this.runtimeHandler=runtimeHandler; return (A) this; + this.runtimeHandler = runtimeHandler; + return (A) this; } + public java.lang.Boolean hasRuntimeHandler() { return this.runtimeHandler != null; } - - /** - * Method is deprecated. use withRuntimeHandler instead. - */ + + /** Method is deprecated. use withRuntimeHandler instead. */ @java.lang.Deprecated public A withNewRuntimeHandler(java.lang.String original) { - return (A)withRuntimeHandler(new String(original)); + return (A) withRuntimeHandler(new String(original)); } - + /** * This method has been deprecated, please use method buildScheduling instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1alpha1Scheduling getScheduling() { - return this.scheduling!=null ?this.scheduling.build():null; + return this.scheduling != null ? this.scheduling.build() : null; } + public io.kubernetes.client.openapi.models.V1alpha1Scheduling buildScheduling() { - return this.scheduling!=null ?this.scheduling.build():null; + return this.scheduling != null ? this.scheduling.build() : null; } + public A withScheduling(io.kubernetes.client.openapi.models.V1alpha1Scheduling scheduling) { _visitables.get("scheduling").remove(this.scheduling); - if (scheduling!=null){ this.scheduling= new io.kubernetes.client.openapi.models.V1alpha1SchedulingBuilder(scheduling); _visitables.get("scheduling").add(this.scheduling);} return (A) this; + if (scheduling != null) { + this.scheduling = + new io.kubernetes.client.openapi.models.V1alpha1SchedulingBuilder(scheduling); + _visitables.get("scheduling").add(this.scheduling); + } + return (A) this; } + public java.lang.Boolean hasScheduling() { return this.scheduling != null; } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested withNewScheduling() { - return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluentImpl.SchedulingNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested + withNewScheduling() { + return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluentImpl + .SchedulingNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested withNewSchedulingLike(io.kubernetes.client.openapi.models.V1alpha1Scheduling item) { - return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluentImpl.SchedulingNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested + withNewSchedulingLike(io.kubernetes.client.openapi.models.V1alpha1Scheduling item) { + return new io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluentImpl + .SchedulingNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested editScheduling() { + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested + editScheduling() { return withNewSchedulingLike(getScheduling()); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested editOrNewScheduling() { - return withNewSchedulingLike(getScheduling() != null ? getScheduling(): new io.kubernetes.client.openapi.models.V1alpha1SchedulingBuilder().build()); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested + editOrNewScheduling() { + return withNewSchedulingLike( + getScheduling() != null + ? getScheduling() + : new io.kubernetes.client.openapi.models.V1alpha1SchedulingBuilder().build()); } - public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested editOrNewSchedulingLike(io.kubernetes.client.openapi.models.V1alpha1Scheduling item) { - return withNewSchedulingLike(getScheduling() != null ? getScheduling(): item); + + public io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested + editOrNewSchedulingLike(io.kubernetes.client.openapi.models.V1alpha1Scheduling item) { + return withNewSchedulingLike(getScheduling() != null ? getScheduling() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1alpha1RuntimeClassSpecFluentImpl that = (V1alpha1RuntimeClassSpecFluentImpl) o; - if (overhead != null ? !overhead.equals(that.overhead) :that.overhead != null) return false; - if (runtimeHandler != null ? !runtimeHandler.equals(that.runtimeHandler) :that.runtimeHandler != null) return false; - if (scheduling != null ? !scheduling.equals(that.scheduling) :that.scheduling != null) return false; + if (overhead != null ? !overhead.equals(that.overhead) : that.overhead != null) return false; + if (runtimeHandler != null + ? !runtimeHandler.equals(that.runtimeHandler) + : that.runtimeHandler != null) return false; + if (scheduling != null ? !scheduling.equals(that.scheduling) : that.scheduling != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(overhead, runtimeHandler, scheduling, super.hashCode()); + return java.util.Objects.hash(overhead, runtimeHandler, scheduling, super.hashCode()); } - public class OverheadNestedImpl extends io.kubernetes.client.openapi.models.V1alpha1OverheadFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested,io.kubernetes.client.fluent.Nested{ + + public class OverheadNestedImpl + extends io.kubernetes.client.openapi.models.V1alpha1OverheadFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested> + implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.OverheadNested< + N>, + io.kubernetes.client.fluent.Nested { OverheadNestedImpl(io.kubernetes.client.openapi.models.V1alpha1Overhead item) { this.builder = new io.kubernetes.client.openapi.models.V1alpha1OverheadBuilder(this, item); } + OverheadNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1alpha1OverheadBuilder(this); } + io.kubernetes.client.openapi.models.V1alpha1OverheadBuilder builder; + public N and() { return (N) V1alpha1RuntimeClassSpecFluentImpl.this.withOverhead(builder.build()); } + public N endOverhead() { return and(); } - } - public class SchedulingNestedImpl extends io.kubernetes.client.openapi.models.V1alpha1SchedulingFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested,io.kubernetes.client.fluent.Nested{ + + public class SchedulingNestedImpl + extends io.kubernetes.client.openapi.models.V1alpha1SchedulingFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent.SchedulingNested> + implements io.kubernetes.client.openapi.models.V1alpha1RuntimeClassSpecFluent + .SchedulingNested< + N>, + io.kubernetes.client.fluent.Nested { SchedulingNestedImpl(io.kubernetes.client.openapi.models.V1alpha1Scheduling item) { this.builder = new io.kubernetes.client.openapi.models.V1alpha1SchedulingBuilder(this, item); } + SchedulingNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1alpha1SchedulingBuilder(this); } + io.kubernetes.client.openapi.models.V1alpha1SchedulingBuilder builder; + public N and() { return (N) V1alpha1RuntimeClassSpecFluentImpl.this.withScheduling(builder.build()); } + public N endScheduling() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1SchedulingBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1SchedulingBuilder.java index 02554764d2..ccc1e93619 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1SchedulingBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1SchedulingBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1alpha1SchedulingBuilder extends io.kubernetes.client.openapi.models.V1alpha1SchedulingFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1alpha1SchedulingBuilder + extends io.kubernetes.client.openapi.models.V1alpha1SchedulingFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1SchedulingBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1alpha1Scheduling, + io.kubernetes.client.openapi.models.V1alpha1SchedulingBuilder> { public V1alpha1SchedulingBuilder() { this(false); } + public V1alpha1SchedulingBuilder(java.lang.Boolean validationEnabled) { this(new V1alpha1Scheduling(), validationEnabled); } - public V1alpha1SchedulingBuilder(io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent fluent) { + + public V1alpha1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent fluent) { this(fluent, false); } - public V1alpha1SchedulingBuilder(io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent fluent,java.lang.Boolean validationEnabled) { + + public V1alpha1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1alpha1Scheduling(), validationEnabled); } - public V1alpha1SchedulingBuilder(io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent fluent,io.kubernetes.client.openapi.models.V1alpha1Scheduling instance) { + + public V1alpha1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1Scheduling instance) { this(fluent, instance, false); } - public V1alpha1SchedulingBuilder(io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent fluent,io.kubernetes.client.openapi.models.V1alpha1Scheduling instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1alpha1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1Scheduling instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNodeSelector(instance.getNodeSelector()); fluent.withTolerations(instance.getTolerations()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1alpha1SchedulingBuilder(io.kubernetes.client.openapi.models.V1alpha1Scheduling instance) { - this(instance,false); + + public V1alpha1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1alpha1Scheduling instance) { + this(instance, false); } - public V1alpha1SchedulingBuilder(io.kubernetes.client.openapi.models.V1alpha1Scheduling instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1alpha1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1alpha1Scheduling instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNodeSelector(instance.getNodeSelector()); this.withTolerations(instance.getTolerations()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1alpha1Scheduling build() { V1alpha1Scheduling buildable = new V1alpha1Scheduling(); buildable.setNodeSelector(fluent.getNodeSelector()); buildable.setTolerations(fluent.getTolerations()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1alpha1SchedulingBuilder that = (V1alpha1SchedulingBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1SchedulingFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1SchedulingFluent.java index 4dfa25c136..5dfcccf6f3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1SchedulingFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1SchedulingFluent.java @@ -1,66 +1,116 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1alpha1SchedulingFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToNodeSelector(java.lang.String key,java.lang.String value); - public A addToNodeSelector(java.util.Map map); +/** Generated */ +public interface V1alpha1SchedulingFluent< + A extends io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToNodeSelector(java.lang.String key, java.lang.String value); + + public A addToNodeSelector(java.util.Map map); + public A removeFromNodeSelector(java.lang.String key); - public A removeFromNodeSelector(java.util.Map map); - public java.util.Map getNodeSelector(); - public A withNodeSelector(java.util.Map nodeSelector); + + public A removeFromNodeSelector(java.util.Map map); + + public java.util.Map getNodeSelector(); + + public A withNodeSelector(java.util.Map nodeSelector); + public java.lang.Boolean hasNodeSelector(); - public A addToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item); - public A setToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item); + + public A addToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item); + + public A setToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item); + public A addToTolerations(io.kubernetes.client.openapi.models.V1Toleration... items); - public A addAllToTolerations(java.util.Collection items); + + public A addAllToTolerations( + java.util.Collection items); + public A removeFromTolerations(io.kubernetes.client.openapi.models.V1Toleration... items); - public A removeAllFromTolerations(java.util.Collection items); - public A removeMatchingFromTolerations(java.util.function.Predicate predicate); - + + public A removeAllFromTolerations( + java.util.Collection items); + + public A removeMatchingFromTolerations( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildTolerations instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getTolerations(); + public java.util.List buildTolerations(); + public io.kubernetes.client.openapi.models.V1Toleration buildToleration(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Toleration buildFirstToleration(); + public io.kubernetes.client.openapi.models.V1Toleration buildLastToleration(); - public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingToleration(java.util.function.Predicate predicate); - public A withTolerations(java.util.List tolerations); + + public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingToleration( + java.util.function.Predicate + predicate); + + public A withTolerations( + java.util.List tolerations); + public A withTolerations(io.kubernetes.client.openapi.models.V1Toleration... tolerations); + public java.lang.Boolean hasTolerations(); - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested addNewToleration(); - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item); - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested setNewTolerationLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item); - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested editToleration(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested editFirstToleration(); - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested editLastToleration(); - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested editMatchingToleration(java.util.function.Predicate predicate); - public interface TolerationsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TolerationFluent>{ + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + addNewToleration(); + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item); + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + setNewTolerationLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item); + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + editToleration(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + editFirstToleration(); + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + editLastToleration(); + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + editMatchingToleration( + java.util.function.Predicate + predicate); + + public interface TolerationsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TolerationFluent< + io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested> { public N and(); + public N endToleration(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1SchedulingFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1SchedulingFluentImpl.java index d313c3831c..55b4056abd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1SchedulingFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1SchedulingFluentImpl.java @@ -1,88 +1,194 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; -import java.util.Map; - /** - * Generated - */ -public class V1alpha1SchedulingFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent{ - public V1alpha1SchedulingFluentImpl() { - } - public V1alpha1SchedulingFluentImpl(io.kubernetes.client.openapi.models.V1alpha1Scheduling instance) { +/** Generated */ +public class V1alpha1SchedulingFluentImpl< + A extends io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent { + public V1alpha1SchedulingFluentImpl() {} + + public V1alpha1SchedulingFluentImpl( + io.kubernetes.client.openapi.models.V1alpha1Scheduling instance) { this.withNodeSelector(instance.getNodeSelector()); this.withTolerations(instance.getTolerations()); - } - private java.util.Map nodeSelector; + + private java.util.Map nodeSelector; private java.util.ArrayList tolerations; - public A addToNodeSelector(java.lang.String key,java.lang.String value) { - if(this.nodeSelector == null && key != null && value != null) { this.nodeSelector = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.nodeSelector.put(key, value);} return (A)this; + + public A addToNodeSelector(java.lang.String key, java.lang.String value) { + if (this.nodeSelector == null && key != null && value != null) { + this.nodeSelector = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.nodeSelector.put(key, value); + } + return (A) this; } - public A addToNodeSelector(java.util.Map map) { - if(this.nodeSelector == null && map != null) { this.nodeSelector = new java.util.LinkedHashMap(); } - if(map != null) { this.nodeSelector.putAll(map);} return (A)this; + + public A addToNodeSelector(java.util.Map map) { + if (this.nodeSelector == null && map != null) { + this.nodeSelector = new java.util.LinkedHashMap(); + } + if (map != null) { + this.nodeSelector.putAll(map); + } + return (A) this; } + public A removeFromNodeSelector(java.lang.String key) { - if(this.nodeSelector == null) { return (A) this; } - if(key != null && this.nodeSelector != null) {this.nodeSelector.remove(key);} return (A)this; + if (this.nodeSelector == null) { + return (A) this; + } + if (key != null && this.nodeSelector != null) { + this.nodeSelector.remove(key); + } + return (A) this; } - public A removeFromNodeSelector(java.util.Map map) { - if(this.nodeSelector == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.nodeSelector != null){this.nodeSelector.remove(key);}}} return (A)this; + + public A removeFromNodeSelector(java.util.Map map) { + if (this.nodeSelector == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.nodeSelector != null) { + this.nodeSelector.remove(key); + } + } + } + return (A) this; } - public java.util.Map getNodeSelector() { + + public java.util.Map getNodeSelector() { return this.nodeSelector; } - public A withNodeSelector(java.util.Map nodeSelector) { - if (nodeSelector == null) { this.nodeSelector = null;} else {this.nodeSelector = new java.util.LinkedHashMap(nodeSelector);} return (A) this; + + public A withNodeSelector(java.util.Map nodeSelector) { + if (nodeSelector == null) { + this.nodeSelector = null; + } else { + this.nodeSelector = new java.util.LinkedHashMap(nodeSelector); + } + return (A) this; } + public java.lang.Boolean hasNodeSelector() { return this.nodeSelector != null; } - public A addToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").add(index >= 0 ? index : _visitables.get("tolerations").size(), builder);this.tolerations.add(index >= 0 ? index : tolerations.size(), builder); return (A)this; + + public A addToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables + .get("tolerations") + .add(index >= 0 ? index : _visitables.get("tolerations").size(), builder); + this.tolerations.add(index >= 0 ? index : tolerations.size(), builder); + return (A) this; } - public A setToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); - if (index < 0 || index >= _visitables.get("tolerations").size()) { _visitables.get("tolerations").add(builder); } else { _visitables.get("tolerations").set(index, builder);} - if (index < 0 || index >= tolerations.size()) { tolerations.add(builder); } else { tolerations.set(index, builder);} - return (A)this; + + public A setToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + if (index < 0 || index >= _visitables.get("tolerations").size()) { + _visitables.get("tolerations").add(builder); + } else { + _visitables.get("tolerations").set(index, builder); + } + if (index < 0 || index >= tolerations.size()) { + tolerations.add(builder); + } else { + tolerations.set(index, builder); + } + return (A) this; } + public A addToTolerations(io.kubernetes.client.openapi.models.V1Toleration... items) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").add(builder);this.tolerations.add(builder);} return (A)this; + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").add(builder); + this.tolerations.add(builder); + } + return (A) this; } - public A addAllToTolerations(java.util.Collection items) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").add(builder);this.tolerations.add(builder);} return (A)this; + + public A addAllToTolerations( + java.util.Collection items) { + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").add(builder); + this.tolerations.add(builder); + } + return (A) this; } + public A removeFromTolerations(io.kubernetes.client.openapi.models.V1Toleration... items) { - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").remove(builder);if (this.tolerations != null) {this.tolerations.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").remove(builder); + if (this.tolerations != null) { + this.tolerations.remove(builder); + } + } + return (A) this; } - public A removeAllFromTolerations(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").remove(builder);if (this.tolerations != null) {this.tolerations.remove(builder);}} return (A)this; + + public A removeAllFromTolerations( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").remove(builder); + if (this.tolerations != null) { + this.tolerations.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromTolerations(java.util.function.Predicate predicate) { + + public A removeMatchingFromTolerations( + java.util.function.Predicate + predicate) { if (tolerations == null) return (A) this; - final Iterator each = tolerations.iterator(); + final Iterator each = + tolerations.iterator(); final List visitables = _visitables.get("tolerations"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1TolerationBuilder builder = each.next(); @@ -91,105 +197,184 @@ public A removeMatchingFromTolerations(java.util.function.Predicate getTolerations() { return tolerations != null ? build(tolerations) : null; } + public java.util.List buildTolerations() { return tolerations != null ? build(tolerations) : null; } + public io.kubernetes.client.openapi.models.V1Toleration buildToleration(java.lang.Integer index) { return this.tolerations.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Toleration buildFirstToleration() { return this.tolerations.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Toleration buildLastToleration() { return this.tolerations.get(tolerations.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TolerationBuilder item: tolerations) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1TolerationBuilder item : tolerations) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingToleration(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TolerationBuilder item: tolerations) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingToleration( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1TolerationBuilder item : tolerations) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withTolerations(java.util.List tolerations) { - if (this.tolerations != null) { _visitables.get("tolerations").removeAll(this.tolerations);} - if (tolerations != null) {this.tolerations = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Toleration item : tolerations){this.addToTolerations(item);}} else { this.tolerations = null;} return (A) this; + + public A withTolerations( + java.util.List tolerations) { + if (this.tolerations != null) { + _visitables.get("tolerations").removeAll(this.tolerations); + } + if (tolerations != null) { + this.tolerations = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Toleration item : tolerations) { + this.addToTolerations(item); + } + } else { + this.tolerations = null; + } + return (A) this; } + public A withTolerations(io.kubernetes.client.openapi.models.V1Toleration... tolerations) { - if (this.tolerations != null) {this.tolerations.clear();} - if (tolerations != null) {for (io.kubernetes.client.openapi.models.V1Toleration item :tolerations){ this.addToTolerations(item);}} return (A) this; + if (this.tolerations != null) { + this.tolerations.clear(); + } + if (tolerations != null) { + for (io.kubernetes.client.openapi.models.V1Toleration item : tolerations) { + this.addToTolerations(item); + } + } + return (A) this; } + public java.lang.Boolean hasTolerations() { return tolerations != null && !tolerations.isEmpty(); } - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested addNewToleration() { - return new io.kubernetes.client.openapi.models.V1alpha1SchedulingFluentImpl.TolerationsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + addNewToleration() { + return new io.kubernetes.client.openapi.models.V1alpha1SchedulingFluentImpl + .TolerationsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item) { - return new io.kubernetes.client.openapi.models.V1alpha1SchedulingFluentImpl.TolerationsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item) { + return new io.kubernetes.client.openapi.models.V1alpha1SchedulingFluentImpl + .TolerationsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested setNewTolerationLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { - return new io.kubernetes.client.openapi.models.V1alpha1SchedulingFluentImpl.TolerationsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + setNewTolerationLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { + return new io.kubernetes.client.openapi.models.V1alpha1SchedulingFluentImpl + .TolerationsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested editToleration(java.lang.Integer index) { - if (tolerations.size() <= index) throw new RuntimeException("Can't edit tolerations. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + editToleration(java.lang.Integer index) { + if (tolerations.size() <= index) + throw new RuntimeException("Can't edit tolerations. Index exceeds size."); return setNewTolerationLike(index, buildToleration(index)); } - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested editFirstToleration() { - if (tolerations.size() == 0) throw new RuntimeException("Can't edit first tolerations. The list is empty."); + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + editFirstToleration() { + if (tolerations.size() == 0) + throw new RuntimeException("Can't edit first tolerations. The list is empty."); return setNewTolerationLike(0, buildToleration(0)); } - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested editLastToleration() { + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + editLastToleration() { int index = tolerations.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last tolerations. The list is empty."); return setNewTolerationLike(index, buildToleration(index)); } - public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested editMatchingToleration(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested + editMatchingToleration( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1TolerationFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested,io.kubernetes.client.fluent.Nested{ - TolerationsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { + + public class TolerationsNestedImpl + extends io.kubernetes.client.openapi.models.V1TolerationFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested> + implements io.kubernetes.client.openapi.models.V1alpha1SchedulingFluent.TolerationsNested, + io.kubernetes.client.fluent.Nested { + TolerationsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(this, item); } + TolerationsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(this); } + io.kubernetes.client.openapi.models.V1TolerationBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1alpha1SchedulingFluentImpl.this.setToTolerations(index,builder.build()); + return (N) V1alpha1SchedulingFluentImpl.this.setToTolerations(index, builder.build()); } + public N endToleration() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1ServerStorageVersionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1ServerStorageVersionBuilder.java index 56f84b0b92..e92235ba1f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1ServerStorageVersionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1ServerStorageVersionBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1alpha1ServerStorageVersionBuilder extends io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1alpha1ServerStorageVersionBuilder + extends io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion, + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder> { public V1alpha1ServerStorageVersionBuilder() { this(false); } + public V1alpha1ServerStorageVersionBuilder(java.lang.Boolean validationEnabled) { this(new V1alpha1ServerStorageVersion(), validationEnabled); } - public V1alpha1ServerStorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent fluent) { + + public V1alpha1ServerStorageVersionBuilder( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent fluent) { this(fluent, false); } - public V1alpha1ServerStorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1alpha1ServerStorageVersionBuilder( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1alpha1ServerStorageVersion(), validationEnabled); } - public V1alpha1ServerStorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent fluent,io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion instance) { + + public V1alpha1ServerStorageVersionBuilder( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion instance) { this(fluent, instance, false); } - public V1alpha1ServerStorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent fluent,io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1alpha1ServerStorageVersionBuilder( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiServerID(instance.getApiServerID()); fluent.withDecodableVersions(instance.getDecodableVersions()); fluent.withEncodingVersion(instance.getEncodingVersion()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1alpha1ServerStorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion instance) { - this(instance,false); + + public V1alpha1ServerStorageVersionBuilder( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion instance) { + this(instance, false); } - public V1alpha1ServerStorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1alpha1ServerStorageVersionBuilder( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiServerID(instance.getApiServerID()); this.withDecodableVersions(instance.getDecodableVersions()); this.withEncodingVersion(instance.getEncodingVersion()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion build() { V1alpha1ServerStorageVersion buildable = new V1alpha1ServerStorageVersion(); buildable.setApiServerID(fluent.getApiServerID()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion build() buildable.setEncodingVersion(fluent.getEncodingVersion()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1alpha1ServerStorageVersionBuilder that = (V1alpha1ServerStorageVersionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1ServerStorageVersionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1ServerStorageVersionFluent.java index 6b9a27fe02..a918222025 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1ServerStorageVersionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1ServerStorageVersionFluent.java @@ -1,53 +1,72 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1alpha1ServerStorageVersionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1alpha1ServerStorageVersionFluent< + A extends io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiServerID(); + public A withApiServerID(java.lang.String apiServerID); + public java.lang.Boolean hasApiServerID(); - - /** - * Method is deprecated. use withApiServerID instead. - */ + + /** Method is deprecated. use withApiServerID instead. */ @java.lang.Deprecated public A withNewApiServerID(java.lang.String original); - public A addToDecodableVersions(java.lang.Integer index,java.lang.String item); - public A setToDecodableVersions(java.lang.Integer index,java.lang.String item); + + public A addToDecodableVersions(java.lang.Integer index, java.lang.String item); + + public A setToDecodableVersions(java.lang.Integer index, java.lang.String item); + public A addToDecodableVersions(java.lang.String... items); + public A addAllToDecodableVersions(java.util.Collection items); + public A removeFromDecodableVersions(java.lang.String... items); + public A removeAllFromDecodableVersions(java.util.Collection items); + public java.util.List getDecodableVersions(); + public java.lang.String getDecodableVersion(java.lang.Integer index); + public java.lang.String getFirstDecodableVersion(); + public java.lang.String getLastDecodableVersion(); - public java.lang.String getMatchingDecodableVersion(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingDecodableVersion(java.util.function.Predicate predicate); + + public java.lang.String getMatchingDecodableVersion( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingDecodableVersion( + java.util.function.Predicate predicate); + public A withDecodableVersions(java.util.List decodableVersions); + public A withDecodableVersions(java.lang.String... decodableVersions); + public java.lang.Boolean hasDecodableVersions(); + public A addNewDecodableVersion(java.lang.String original); + public java.lang.String getEncodingVersion(); + public A withEncodingVersion(java.lang.String encodingVersion); + public java.lang.Boolean hasEncodingVersion(); - - /** - * Method is deprecated. use withEncodingVersion instead. - */ + + /** Method is deprecated. use withEncodingVersion instead. */ @java.lang.Deprecated public A withNewEncodingVersion(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1ServerStorageVersionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1ServerStorageVersionFluentImpl.java index 3c19ee9c81..3acdbdb445 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1ServerStorageVersionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1ServerStorageVersionFluentImpl.java @@ -1,132 +1,214 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1alpha1ServerStorageVersionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent{ - public V1alpha1ServerStorageVersionFluentImpl() { - } - public V1alpha1ServerStorageVersionFluentImpl(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion instance) { +/** Generated */ +public class V1alpha1ServerStorageVersionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent { + public V1alpha1ServerStorageVersionFluentImpl() {} + + public V1alpha1ServerStorageVersionFluentImpl( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion instance) { this.withApiServerID(instance.getApiServerID()); this.withDecodableVersions(instance.getDecodableVersions()); this.withEncodingVersion(instance.getEncodingVersion()); - } + private java.lang.String apiServerID; private java.util.List decodableVersions; private java.lang.String encodingVersion; + public java.lang.String getApiServerID() { return this.apiServerID; } + public A withApiServerID(java.lang.String apiServerID) { - this.apiServerID=apiServerID; return (A) this; + this.apiServerID = apiServerID; + return (A) this; } + public java.lang.Boolean hasApiServerID() { return this.apiServerID != null; } - - /** - * Method is deprecated. use withApiServerID instead. - */ + + /** Method is deprecated. use withApiServerID instead. */ @java.lang.Deprecated public A withNewApiServerID(java.lang.String original) { - return (A)withApiServerID(new String(original)); + return (A) withApiServerID(new String(original)); } - public A addToDecodableVersions(java.lang.Integer index,java.lang.String item) { - if (this.decodableVersions == null) {this.decodableVersions = new java.util.ArrayList();} + + public A addToDecodableVersions(java.lang.Integer index, java.lang.String item) { + if (this.decodableVersions == null) { + this.decodableVersions = new java.util.ArrayList(); + } this.decodableVersions.add(index, item); - return (A)this; + return (A) this; } - public A setToDecodableVersions(java.lang.Integer index,java.lang.String item) { - if (this.decodableVersions == null) {this.decodableVersions = new java.util.ArrayList();} - this.decodableVersions.set(index, item); return (A)this; + + public A setToDecodableVersions(java.lang.Integer index, java.lang.String item) { + if (this.decodableVersions == null) { + this.decodableVersions = new java.util.ArrayList(); + } + this.decodableVersions.set(index, item); + return (A) this; } + public A addToDecodableVersions(java.lang.String... items) { - if (this.decodableVersions == null) {this.decodableVersions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.decodableVersions.add(item);} return (A)this; + if (this.decodableVersions == null) { + this.decodableVersions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.decodableVersions.add(item); + } + return (A) this; } + public A addAllToDecodableVersions(java.util.Collection items) { - if (this.decodableVersions == null) {this.decodableVersions = new java.util.ArrayList();} - for (java.lang.String item : items) {this.decodableVersions.add(item);} return (A)this; + if (this.decodableVersions == null) { + this.decodableVersions = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.decodableVersions.add(item); + } + return (A) this; } + public A removeFromDecodableVersions(java.lang.String... items) { - for (java.lang.String item : items) {if (this.decodableVersions!= null){ this.decodableVersions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.decodableVersions != null) { + this.decodableVersions.remove(item); + } + } + return (A) this; } + public A removeAllFromDecodableVersions(java.util.Collection items) { - for (java.lang.String item : items) {if (this.decodableVersions!= null){ this.decodableVersions.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.decodableVersions != null) { + this.decodableVersions.remove(item); + } + } + return (A) this; } + public java.util.List getDecodableVersions() { return this.decodableVersions; } + public java.lang.String getDecodableVersion(java.lang.Integer index) { return this.decodableVersions.get(index); } + public java.lang.String getFirstDecodableVersion() { return this.decodableVersions.get(0); } + public java.lang.String getLastDecodableVersion() { return this.decodableVersions.get(decodableVersions.size() - 1); } - public java.lang.String getMatchingDecodableVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: decodableVersions) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingDecodableVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : decodableVersions) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingDecodableVersion(java.util.function.Predicate predicate) { - for (java.lang.String item: decodableVersions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingDecodableVersion( + java.util.function.Predicate predicate) { + for (java.lang.String item : decodableVersions) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withDecodableVersions(java.util.List decodableVersions) { - if (decodableVersions != null) {this.decodableVersions = new java.util.ArrayList(); for (java.lang.String item : decodableVersions){this.addToDecodableVersions(item);}} else { this.decodableVersions = null;} return (A) this; + if (decodableVersions != null) { + this.decodableVersions = new java.util.ArrayList(); + for (java.lang.String item : decodableVersions) { + this.addToDecodableVersions(item); + } + } else { + this.decodableVersions = null; + } + return (A) this; } + public A withDecodableVersions(java.lang.String... decodableVersions) { - if (this.decodableVersions != null) {this.decodableVersions.clear();} - if (decodableVersions != null) {for (java.lang.String item :decodableVersions){ this.addToDecodableVersions(item);}} return (A) this; + if (this.decodableVersions != null) { + this.decodableVersions.clear(); + } + if (decodableVersions != null) { + for (java.lang.String item : decodableVersions) { + this.addToDecodableVersions(item); + } + } + return (A) this; } + public java.lang.Boolean hasDecodableVersions() { return decodableVersions != null && !decodableVersions.isEmpty(); } + public A addNewDecodableVersion(java.lang.String original) { - return (A)addToDecodableVersions(new String(original)); + return (A) addToDecodableVersions(new String(original)); } + public java.lang.String getEncodingVersion() { return this.encodingVersion; } + public A withEncodingVersion(java.lang.String encodingVersion) { - this.encodingVersion=encodingVersion; return (A) this; + this.encodingVersion = encodingVersion; + return (A) this; } + public java.lang.Boolean hasEncodingVersion() { return this.encodingVersion != null; } - - /** - * Method is deprecated. use withEncodingVersion instead. - */ + + /** Method is deprecated. use withEncodingVersion instead. */ @java.lang.Deprecated public A withNewEncodingVersion(java.lang.String original) { - return (A)withEncodingVersion(new String(original)); + return (A) withEncodingVersion(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1alpha1ServerStorageVersionFluentImpl that = (V1alpha1ServerStorageVersionFluentImpl) o; - if (apiServerID != null ? !apiServerID.equals(that.apiServerID) :that.apiServerID != null) return false; - if (decodableVersions != null ? !decodableVersions.equals(that.decodableVersions) :that.decodableVersions != null) return false; - if (encodingVersion != null ? !encodingVersion.equals(that.encodingVersion) :that.encodingVersion != null) return false; + if (apiServerID != null ? !apiServerID.equals(that.apiServerID) : that.apiServerID != null) + return false; + if (decodableVersions != null + ? !decodableVersions.equals(that.decodableVersions) + : that.decodableVersions != null) return false; + if (encodingVersion != null + ? !encodingVersion.equals(that.encodingVersion) + : that.encodingVersion != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiServerID, decodableVersions, encodingVersion, super.hashCode()); + return java.util.Objects.hash( + apiServerID, decodableVersions, encodingVersion, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionBuilder.java index d6755d69ce..b79308c8b8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1alpha1StorageVersionBuilder extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1alpha1StorageVersionBuilder + extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1alpha1StorageVersion, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder> { public V1alpha1StorageVersionBuilder() { this(false); } + public V1alpha1StorageVersionBuilder(java.lang.Boolean validationEnabled) { this(new V1alpha1StorageVersion(), validationEnabled); } - public V1alpha1StorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent fluent) { + + public V1alpha1StorageVersionBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent fluent) { this(fluent, false); } - public V1alpha1StorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1alpha1StorageVersionBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1alpha1StorageVersion(), validationEnabled); } - public V1alpha1StorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent fluent,io.kubernetes.client.openapi.models.V1alpha1StorageVersion instance) { + + public V1alpha1StorageVersionBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1StorageVersion instance) { this(fluent, instance, false); } - public V1alpha1StorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent fluent,io.kubernetes.client.openapi.models.V1alpha1StorageVersion instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1alpha1StorageVersionBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1StorageVersion instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1alpha1StorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1alpha1StorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersion instance) { - this(instance,false); + + public V1alpha1StorageVersionBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersion instance) { + this(instance, false); } - public V1alpha1StorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersion instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1alpha1StorageVersionBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersion instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1alpha1StorageVersionBuilder(io.kubernetes.client.openapi.models.V1alpha this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1alpha1StorageVersion build() { V1alpha1StorageVersion buildable = new V1alpha1StorageVersion(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1alpha1StorageVersion build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1alpha1StorageVersionBuilder that = (V1alpha1StorageVersionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionConditionBuilder.java index 4ce023005e..29cd280d88 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1alpha1StorageVersionConditionBuilder extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1alpha1StorageVersionConditionBuilder + extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder> { public V1alpha1StorageVersionConditionBuilder() { this(false); } + public V1alpha1StorageVersionConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1alpha1StorageVersionCondition(), validationEnabled); } - public V1alpha1StorageVersionConditionBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent fluent) { + + public V1alpha1StorageVersionConditionBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent fluent) { this(fluent, false); } - public V1alpha1StorageVersionConditionBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1alpha1StorageVersionConditionBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1alpha1StorageVersionCondition(), validationEnabled); } - public V1alpha1StorageVersionConditionBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent fluent,io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition instance) { + + public V1alpha1StorageVersionConditionBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition instance) { this(fluent, instance, false); } - public V1alpha1StorageVersionConditionBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent fluent,io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1alpha1StorageVersionConditionBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -33,13 +60,18 @@ public V1alpha1StorageVersionConditionBuilder(io.kubernetes.client.openapi.model fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1alpha1StorageVersionConditionBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition instance) { - this(instance,false); + + public V1alpha1StorageVersionConditionBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition instance) { + this(instance, false); } - public V1alpha1StorageVersionConditionBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1alpha1StorageVersionConditionBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -52,10 +84,12 @@ public V1alpha1StorageVersionConditionBuilder(io.kubernetes.client.openapi.model this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition build() { V1alpha1StorageVersionCondition buildable = new V1alpha1StorageVersionCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition build buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1alpha1StorageVersionConditionBuilder that = (V1alpha1StorageVersionConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionConditionFluent.java index 0f2cd72ab6..f06d8cfb29 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionConditionFluent.java @@ -1,58 +1,70 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Long; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1alpha1StorageVersionConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1alpha1StorageVersionConditionFluent< + A extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.Long getObservedGeneration(); + public A withObservedGeneration(java.lang.Long observedGeneration); + public java.lang.Boolean hasObservedGeneration(); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionConditionFluentImpl.java index a760fdb3eb..4569750c48 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionConditionFluentImpl.java @@ -1,20 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1alpha1StorageVersionConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent{ - public V1alpha1StorageVersionConditionFluentImpl() { - } - public V1alpha1StorageVersionConditionFluentImpl(io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition instance) { +/** Generated */ +public class V1alpha1StorageVersionConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent { + public V1alpha1StorageVersionConditionFluentImpl() {} + + public V1alpha1StorageVersionConditionFluentImpl( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -26,114 +32,136 @@ public V1alpha1StorageVersionConditionFluentImpl(io.kubernetes.client.openapi.mo this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.Long observedGeneration; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.Long getObservedGeneration() { return this.observedGeneration; } + public A withObservedGeneration(java.lang.Long observedGeneration) { - this.observedGeneration=observedGeneration; return (A) this; + this.observedGeneration = observedGeneration; + return (A) this; } + public java.lang.Boolean hasObservedGeneration() { return this.observedGeneration != null; } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1alpha1StorageVersionConditionFluentImpl that = (V1alpha1StorageVersionConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (observedGeneration != null ? !observedGeneration.equals(that.observedGeneration) :that.observedGeneration != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (observedGeneration != null + ? !observedGeneration.equals(that.observedGeneration) + : that.observedGeneration != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, observedGeneration, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, observedGeneration, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionFluent.java index 64e15ddd9d..b7e55ab4b2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionFluent.java @@ -1,77 +1,120 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1alpha1StorageVersionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1alpha1StorageVersionFluent< + A extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public java.lang.Object getSpec(); + public A withSpec(java.lang.Object spec); + public java.lang.Boolean hasSpec(); - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus getStatus(); + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus item); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionFluentImpl.java index 4ca5cbf71a..b47996393d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1alpha1StorageVersionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent { + public V1alpha1StorageVersionFluentImpl() {} - /** - * Generated - */ -public class V1alpha1StorageVersionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent{ - public V1alpha1StorageVersionFluentImpl() { - } - public V1alpha1StorageVersionFluentImpl(io.kubernetes.client.openapi.models.V1alpha1StorageVersion instance) { + public V1alpha1StorageVersionFluentImpl( + io.kubernetes.client.openapi.models.V1alpha1StorageVersion instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,169 +30,245 @@ public V1alpha1StorageVersionFluentImpl(io.kubernetes.client.openapi.models.V1al this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private java.lang.Object spec; private io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public java.lang.Object getSpec() { return this.spec; } + public A withSpec(java.lang.Object spec) { - this.spec=spec; return (A) this; + this.spec = spec; + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus item) { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus item) { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1alpha1StorageVersionFluentImpl that = (V1alpha1StorageVersionFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1alpha1StorageVersionFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusBuilder(this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusBuilder builder; + public N and() { return (N) V1alpha1StorageVersionFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionListBuilder.java index 57d4fe50b3..4616e5e7bd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1alpha1StorageVersionListBuilder extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1alpha1StorageVersionListBuilder + extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionList, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionListBuilder> { public V1alpha1StorageVersionListBuilder() { this(false); } + public V1alpha1StorageVersionListBuilder(java.lang.Boolean validationEnabled) { this(new V1alpha1StorageVersionList(), validationEnabled); } - public V1alpha1StorageVersionListBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent fluent) { + + public V1alpha1StorageVersionListBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent fluent) { this(fluent, false); } - public V1alpha1StorageVersionListBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1alpha1StorageVersionListBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1alpha1StorageVersionList(), validationEnabled); } - public V1alpha1StorageVersionListBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent fluent,io.kubernetes.client.openapi.models.V1alpha1StorageVersionList instance) { + + public V1alpha1StorageVersionListBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionList instance) { this(fluent, instance, false); } - public V1alpha1StorageVersionListBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent fluent,io.kubernetes.client.openapi.models.V1alpha1StorageVersionList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1alpha1StorageVersionListBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1alpha1StorageVersionListBuilder(io.kubernetes.client.openapi.models.V1a fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1alpha1StorageVersionListBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionList instance) { - this(instance,false); + + public V1alpha1StorageVersionListBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionList instance) { + this(instance, false); } - public V1alpha1StorageVersionListBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1alpha1StorageVersionListBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1alpha1StorageVersionListBuilder(io.kubernetes.client.openapi.models.V1a this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionList build() { V1alpha1StorageVersionList buildable = new V1alpha1StorageVersionList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1alpha1StorageVersionList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1alpha1StorageVersionListBuilder that = (V1alpha1StorageVersionListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionListFluent.java index eff7b4f3cf..fceb334dd2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionListFluent.java @@ -1,95 +1,166 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1alpha1StorageVersionListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1alpha1StorageVersionListFluent< + A extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersion item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersion item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1StorageVersion item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1StorageVersion item); + public A addToItems(io.kubernetes.client.openapi.models.V1alpha1StorageVersion... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1alpha1StorageVersion... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersion buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersion buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1alpha1StorageVersion buildFirstItem(); + public io.kubernetes.client.openapi.models.V1alpha1StorageVersion buildLastItem(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersion buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersion buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1alpha1StorageVersion... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersion item); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersion item); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersion item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1StorageVersion item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent>{ + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluent< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionListFluentImpl.java index f801a2ae5e..e4de865c06 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1alpha1StorageVersionListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent{ - public V1alpha1StorageVersionListFluentImpl() { - } - public V1alpha1StorageVersionListFluentImpl(io.kubernetes.client.openapi.models.V1alpha1StorageVersionList instance) { + +/** Generated */ +public class V1alpha1StorageVersionListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent { + public V1alpha1StorageVersionListFluentImpl() {} + + public V1alpha1StorageVersionListFluentImpl( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,132 @@ public V1alpha1StorageVersionListFluentImpl(io.kubernetes.client.openapi.models. this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersion item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1StorageVersion item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder>(); + } + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersion item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1StorageVersion item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder>(); + } + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1alpha1StorageVersion... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1alpha1StorageVersion item : items) {io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersion item : items) { + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1alpha1StorageVersion item : items) {io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersion item : items) { + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1alpha1StorageVersion... items) { - for (io.kubernetes.client.openapi.models.V1alpha1StorageVersion item : items) {io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersion item : items) { + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1alpha1StorageVersion item : items) {io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersion item : items) { + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder = each.next(); @@ -87,174 +165,292 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersion buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersion buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1alpha1StorageVersion buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1alpha1StorageVersion buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersion buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersion buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1alpha1StorageVersion item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersion item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1alpha1StorageVersion... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1alpha1StorageVersion item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersion item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersion item) { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersion item) { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersion item) { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1StorageVersion item) { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1alpha1StorageVersionListFluentImpl that = (V1alpha1StorageVersionListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersion item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1alpha1StorageVersion item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder(this); } + io.kubernetes.client.openapi.models.V1alpha1StorageVersionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1alpha1StorageVersionListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1alpha1StorageVersionListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1alpha1StorageVersionListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionStatusBuilder.java index 330050a7dc..e935154b27 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionStatusBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1alpha1StorageVersionStatusBuilder extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1alpha1StorageVersionStatusBuilder + extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusBuilder> { public V1alpha1StorageVersionStatusBuilder() { this(false); } + public V1alpha1StorageVersionStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1alpha1StorageVersionStatus(), validationEnabled); } - public V1alpha1StorageVersionStatusBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent fluent) { + + public V1alpha1StorageVersionStatusBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent fluent) { this(fluent, false); } - public V1alpha1StorageVersionStatusBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1alpha1StorageVersionStatusBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1alpha1StorageVersionStatus(), validationEnabled); } - public V1alpha1StorageVersionStatusBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent fluent,io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus instance) { + + public V1alpha1StorageVersionStatusBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus instance) { this(fluent, instance, false); } - public V1alpha1StorageVersionStatusBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent fluent,io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1alpha1StorageVersionStatusBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent fluent, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCommonEncodingVersion(instance.getCommonEncodingVersion()); fluent.withConditions(instance.getConditions()); fluent.withStorageVersions(instance.getStorageVersions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1alpha1StorageVersionStatusBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus instance) { - this(instance,false); + + public V1alpha1StorageVersionStatusBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus instance) { + this(instance, false); } - public V1alpha1StorageVersionStatusBuilder(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1alpha1StorageVersionStatusBuilder( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCommonEncodingVersion(instance.getCommonEncodingVersion()); this.withConditions(instance.getConditions()); this.withStorageVersions(instance.getStorageVersions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus build() { V1alpha1StorageVersionStatus buildable = new V1alpha1StorageVersionStatus(); buildable.setCommonEncodingVersion(fluent.getCommonEncodingVersion()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus build() buildable.setStorageVersions(fluent.getStorageVersions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1alpha1StorageVersionStatusBuilder that = (V1alpha1StorageVersionStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionStatusFluent.java index 6554f2115b..ac314e3af5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionStatusFluent.java @@ -1,101 +1,247 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1alpha1StorageVersionStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1alpha1StorageVersionStatusFluent< + A extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getCommonEncodingVersion(); + public A withCommonEncodingVersion(java.lang.String commonEncodingVersion); + public java.lang.Boolean hasCommonEncodingVersion(); - - /** - * Method is deprecated. use withCommonEncodingVersion instead. - */ + + /** Method is deprecated. use withCommonEncodingVersion instead. */ @java.lang.Deprecated public A withNewCommonEncodingVersion(java.lang.String original); - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item); - public A addToConditions(io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition... items); - public A addAllToConditions(java.util.Collection items); - public A removeFromConditions(io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item); + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item); + + public A addToConditions( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition... items); + + public A addAllToConditions( + java.util.Collection + items); + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition... items); + + public A removeAllFromConditions( + java.util.Collection + items); + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder> + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition buildCondition(java.lang.Integer index); + public java.util.List + getConditions(); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition buildCondition( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); - public A withConditions(io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition... conditions); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder> + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder> + predicate); + + public A withConditions( + java.util.List + conditions); + + public A withConditions( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - public A addToStorageVersions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item); - public A setToStorageVersions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item); - public A addToStorageVersions(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion... items); - public A addAllToStorageVersions(java.util.Collection items); - public A removeFromStorageVersions(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion... items); - public A removeAllFromStorageVersions(java.util.Collection items); - public A removeMatchingFromStorageVersions(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder> + predicate); + + public A addToStorageVersions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item); + + public A setToStorageVersions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item); + + public A addToStorageVersions( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion... items); + + public A addAllToStorageVersions( + java.util.Collection items); + + public A removeFromStorageVersions( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion... items); + + public A removeAllFromStorageVersions( + java.util.Collection items); + + public A removeMatchingFromStorageVersions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder> + predicate); + /** * This method has been deprecated, please use method buildStorageVersions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getStorageVersions(); - public java.util.List buildStorageVersions(); - public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion buildStorageVersion(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion buildFirstStorageVersion(); + public java.util.List + getStorageVersions(); + + public java.util.List + buildStorageVersions(); + + public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion buildStorageVersion( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion + buildFirstStorageVersion(); + public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion buildLastStorageVersion(); - public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion buildMatchingStorageVersion(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingStorageVersion(java.util.function.Predicate predicate); - public A withStorageVersions(java.util.List storageVersions); - public A withStorageVersions(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion... storageVersions); + + public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion + buildMatchingStorageVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder> + predicate); + + public java.lang.Boolean hasMatchingStorageVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder> + predicate); + + public A withStorageVersions( + java.util.List + storageVersions); + + public A withStorageVersions( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion... storageVersions); + public java.lang.Boolean hasStorageVersions(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested addNewStorageVersion(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested addNewStorageVersionLike(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested setNewStorageVersionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested editStorageVersion(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested editFirstStorageVersion(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested editLastStorageVersion(); - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested editMatchingStorageVersion(java.util.function.Predicate predicate); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent>{ + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + addNewStorageVersion(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + addNewStorageVersionLike( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + setNewStorageVersionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + editStorageVersion(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + editFirstStorageVersion(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + editLastStorageVersion(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + editMatchingStorageVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder> + predicate); + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluent< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - public interface StorageVersionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent>{ + + public interface StorageVersionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluent< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + N>> { public N and(); + public N endStorageVersion(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionStatusFluentImpl.java index 717a138538..397135be0a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1alpha1StorageVersionStatusFluentImpl.java @@ -1,187 +1,436 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1alpha1StorageVersionStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent{ - public V1alpha1StorageVersionStatusFluentImpl() { - } - public V1alpha1StorageVersionStatusFluentImpl(io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus instance) { + +/** Generated */ +public class V1alpha1StorageVersionStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent { + public V1alpha1StorageVersionStatusFluentImpl() {} + + public V1alpha1StorageVersionStatusFluentImpl( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatus instance) { this.withCommonEncodingVersion(instance.getCommonEncodingVersion()); this.withConditions(instance.getConditions()); this.withStorageVersions(instance.getStorageVersions()); - } + private java.lang.String commonEncodingVersion; - private java.util.ArrayList conditions; - private java.util.ArrayList storageVersions; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder> + conditions; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder> + storageVersions; + public java.lang.String getCommonEncodingVersion() { return this.commonEncodingVersion; } + public A withCommonEncodingVersion(java.lang.String commonEncodingVersion) { - this.commonEncodingVersion=commonEncodingVersion; return (A) this; + this.commonEncodingVersion = commonEncodingVersion; + return (A) this; } + public java.lang.Boolean hasCommonEncodingVersion() { return this.commonEncodingVersion != null; } - - /** - * Method is deprecated. use withCommonEncodingVersion instead. - */ + + /** Method is deprecated. use withCommonEncodingVersion instead. */ @java.lang.Deprecated public A withNewCommonEncodingVersion(java.lang.String original) { - return (A)withCommonEncodingVersion(new String(original)); + return (A) withCommonEncodingVersion(new String(original)); } - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } - public A addToConditions(io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item : items) {io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addToConditions( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition... items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item : items) { + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item : items) {io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection + items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item : items) { + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition... items) { - for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item : items) {io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition... items) { + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item : items) { + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item : items) {io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item : items) { + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder> + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator + each = conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions() { + public java.util.List + getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List + conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } - public A withConditions(io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item :conditions){ this.addToConditions(item);}} return (A) this; + + public A withConditions( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition... conditions) { + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item) { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + addNewConditionLike( + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item) { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item) { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item) { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(item);_visitables.get("storageVersions").add(index >= 0 ? index : _visitables.get("storageVersions").size(), builder);this.storageVersions.add(index >= 0 ? index : storageVersions.size(), builder); return (A)this; + + public A addToStorageVersions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item) { + if (this.storageVersions == null) { + this.storageVersions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder>(); + } + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(item); + _visitables + .get("storageVersions") + .add(index >= 0 ? index : _visitables.get("storageVersions").size(), builder); + this.storageVersions.add(index >= 0 ? index : storageVersions.size(), builder); + return (A) this; } - public A setToStorageVersions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item) { - if (this.storageVersions == null) {this.storageVersions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(item); - if (index < 0 || index >= _visitables.get("storageVersions").size()) { _visitables.get("storageVersions").add(builder); } else { _visitables.get("storageVersions").set(index, builder);} - if (index < 0 || index >= storageVersions.size()) { storageVersions.add(builder); } else { storageVersions.set(index, builder);} - return (A)this; + + public A setToStorageVersions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item) { + if (this.storageVersions == null) { + this.storageVersions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder>(); + } + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(item); + if (index < 0 || index >= _visitables.get("storageVersions").size()) { + _visitables.get("storageVersions").add(builder); + } else { + _visitables.get("storageVersions").set(index, builder); + } + if (index < 0 || index >= storageVersions.size()) { + storageVersions.add(builder); + } else { + storageVersions.set(index, builder); + } + return (A) this; } - public A addToStorageVersions(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion... items) { - if (this.storageVersions == null) {this.storageVersions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item : items) {io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(item);_visitables.get("storageVersions").add(builder);this.storageVersions.add(builder);} return (A)this; + + public A addToStorageVersions( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion... items) { + if (this.storageVersions == null) { + this.storageVersions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item : items) { + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(item); + _visitables.get("storageVersions").add(builder); + this.storageVersions.add(builder); + } + return (A) this; } - public A addAllToStorageVersions(java.util.Collection items) { - if (this.storageVersions == null) {this.storageVersions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item : items) {io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(item);_visitables.get("storageVersions").add(builder);this.storageVersions.add(builder);} return (A)this; + + public A addAllToStorageVersions( + java.util.Collection + items) { + if (this.storageVersions == null) { + this.storageVersions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item : items) { + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(item); + _visitables.get("storageVersions").add(builder); + this.storageVersions.add(builder); + } + return (A) this; } - public A removeFromStorageVersions(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion... items) { - for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item : items) {io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(item);_visitables.get("storageVersions").remove(builder);if (this.storageVersions != null) {this.storageVersions.remove(builder);}} return (A)this; + + public A removeFromStorageVersions( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion... items) { + for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item : items) { + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(item); + _visitables.get("storageVersions").remove(builder); + if (this.storageVersions != null) { + this.storageVersions.remove(builder); + } + } + return (A) this; } - public A removeAllFromStorageVersions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item : items) {io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder = new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(item);_visitables.get("storageVersions").remove(builder);if (this.storageVersions != null) {this.storageVersions.remove(builder);}} return (A)this; + + public A removeAllFromStorageVersions( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item : items) { + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder = + new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(item); + _visitables.get("storageVersions").remove(builder); + if (this.storageVersions != null) { + this.storageVersions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromStorageVersions(java.util.function.Predicate predicate) { + + public A removeMatchingFromStorageVersions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder> + predicate) { if (storageVersions == null) return (A) this; - final Iterator each = storageVersions.iterator(); + final Iterator each = + storageVersions.iterator(); final List visitables = _visitables.get("storageVersions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder = each.next(); @@ -190,125 +439,266 @@ public A removeMatchingFromStorageVersions(java.util.function.Predicate getStorageVersions() { + public java.util.List + getStorageVersions() { return storageVersions != null ? build(storageVersions) : null; } - public java.util.List buildStorageVersions() { + + public java.util.List + buildStorageVersions() { return storageVersions != null ? build(storageVersions) : null; } - public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion buildStorageVersion(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion buildStorageVersion( + java.lang.Integer index) { return this.storageVersions.get(index).build(); } - public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion buildFirstStorageVersion() { + + public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion + buildFirstStorageVersion() { return this.storageVersions.get(0).build(); } - public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion buildLastStorageVersion() { + + public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion + buildLastStorageVersion() { return this.storageVersions.get(storageVersions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion buildMatchingStorageVersion(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder item: storageVersions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion + buildMatchingStorageVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder item : + storageVersions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingStorageVersion(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder item: storageVersions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingStorageVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder item : + storageVersions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withStorageVersions(java.util.List storageVersions) { - if (this.storageVersions != null) { _visitables.get("storageVersions").removeAll(this.storageVersions);} - if (storageVersions != null) {this.storageVersions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item : storageVersions){this.addToStorageVersions(item);}} else { this.storageVersions = null;} return (A) this; + + public A withStorageVersions( + java.util.List + storageVersions) { + if (this.storageVersions != null) { + _visitables.get("storageVersions").removeAll(this.storageVersions); + } + if (storageVersions != null) { + this.storageVersions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item : + storageVersions) { + this.addToStorageVersions(item); + } + } else { + this.storageVersions = null; + } + return (A) this; } - public A withStorageVersions(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion... storageVersions) { - if (this.storageVersions != null) {this.storageVersions.clear();} - if (storageVersions != null) {for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item :storageVersions){ this.addToStorageVersions(item);}} return (A) this; + + public A withStorageVersions( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion... storageVersions) { + if (this.storageVersions != null) { + this.storageVersions.clear(); + } + if (storageVersions != null) { + for (io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item : + storageVersions) { + this.addToStorageVersions(item); + } + } + return (A) this; } + public java.lang.Boolean hasStorageVersions() { return storageVersions != null && !storageVersions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested addNewStorageVersion() { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl.StorageVersionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + addNewStorageVersion() { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl + .StorageVersionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested addNewStorageVersionLike(io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item) { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl.StorageVersionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + addNewStorageVersionLike( + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item) { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl + .StorageVersionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested setNewStorageVersionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item) { - return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl.StorageVersionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + setNewStorageVersionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item) { + return new io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluentImpl + .StorageVersionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested editStorageVersion(java.lang.Integer index) { - if (storageVersions.size() <= index) throw new RuntimeException("Can't edit storageVersions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + editStorageVersion(java.lang.Integer index) { + if (storageVersions.size() <= index) + throw new RuntimeException("Can't edit storageVersions. Index exceeds size."); return setNewStorageVersionLike(index, buildStorageVersion(index)); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested editFirstStorageVersion() { - if (storageVersions.size() == 0) throw new RuntimeException("Can't edit first storageVersions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + editFirstStorageVersion() { + if (storageVersions.size() == 0) + throw new RuntimeException("Can't edit first storageVersions. The list is empty."); return setNewStorageVersionLike(0, buildStorageVersion(0)); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested editLastStorageVersion() { + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + editLastStorageVersion() { int index = storageVersions.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last storageVersions. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last storageVersions. The list is empty."); return setNewStorageVersionLike(index, buildStorageVersion(index)); } - public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested editMatchingStorageVersion(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + A> + editMatchingStorageVersion( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.ConditionsNested< + N>> + implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1StorageVersionCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder( + this, item); } + ConditionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1alpha1StorageVersionConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1alpha1StorageVersionStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) + V1alpha1StorageVersionStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - public class StorageVersionsNestedImpl extends io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluentImpl> implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent.StorageVersionsNested,io.kubernetes.client.fluent.Nested{ - StorageVersionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item) { + + public class StorageVersionsNestedImpl + extends io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionFluentImpl< + io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + N>> + implements io.kubernetes.client.openapi.models.V1alpha1StorageVersionStatusFluent + .StorageVersionsNested< + N>, + io.kubernetes.client.fluent.Nested { + StorageVersionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersion item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(this, item); } + StorageVersionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder(this); } + io.kubernetes.client.openapi.models.V1alpha1ServerStorageVersionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1alpha1StorageVersionStatusFluentImpl.this.setToStorageVersions(index,builder.build()); + return (N) + V1alpha1StorageVersionStatusFluentImpl.this.setToStorageVersions(index, builder.build()); } + public N endStorageVersion() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedCSIDriverBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedCSIDriverBuilder.java index 6144c1d0bb..df51ae69ae 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedCSIDriverBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedCSIDriverBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1AllowedCSIDriverBuilder extends io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1AllowedCSIDriverBuilder + extends io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluentImpl< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver, + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder> { public V1beta1AllowedCSIDriverBuilder() { this(false); } + public V1beta1AllowedCSIDriverBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1AllowedCSIDriver(), validationEnabled); } - public V1beta1AllowedCSIDriverBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent fluent) { + + public V1beta1AllowedCSIDriverBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent fluent) { this(fluent, false); } - public V1beta1AllowedCSIDriverBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1AllowedCSIDriverBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1AllowedCSIDriver(), validationEnabled); } - public V1beta1AllowedCSIDriverBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent fluent,io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver instance) { + + public V1beta1AllowedCSIDriverBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent fluent, + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver instance) { this(fluent, instance, false); } - public V1beta1AllowedCSIDriverBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent fluent,io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1AllowedCSIDriverBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent fluent, + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1AllowedCSIDriverBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver instance) { - this(instance,false); + + public V1beta1AllowedCSIDriverBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver instance) { + this(instance, false); } - public V1beta1AllowedCSIDriverBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1AllowedCSIDriverBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver build() { V1beta1AllowedCSIDriver buildable = new V1beta1AllowedCSIDriver(); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1AllowedCSIDriverBuilder that = (V1beta1AllowedCSIDriverBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedCSIDriverFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedCSIDriverFluent.java index 5f1541d7d5..154042931c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedCSIDriverFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedCSIDriverFluent.java @@ -1,23 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1AllowedCSIDriverFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1AllowedCSIDriverFluent< + A extends io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedCSIDriverFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedCSIDriverFluentImpl.java index 8b0eb8c840..7fc70086d5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedCSIDriverFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedCSIDriverFluentImpl.java @@ -1,48 +1,59 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta1AllowedCSIDriverFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent{ - public V1beta1AllowedCSIDriverFluentImpl() { - } - public V1beta1AllowedCSIDriverFluentImpl(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver instance) { - this.withName(instance.getName()); +/** Generated */ +public class V1beta1AllowedCSIDriverFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent { + public V1beta1AllowedCSIDriverFluentImpl() {} + public V1beta1AllowedCSIDriverFluentImpl( + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver instance) { + this.withName(instance.getName()); } + private java.lang.String name; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1AllowedCSIDriverFluentImpl that = (V1beta1AllowedCSIDriverFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, super.hashCode()); + return java.util.Objects.hash(name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedFlexVolumeBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedFlexVolumeBuilder.java index aea50089e3..19c25cb322 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedFlexVolumeBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedFlexVolumeBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1AllowedFlexVolumeBuilder extends io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1AllowedFlexVolumeBuilder + extends io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluentImpl< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume, + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder> { public V1beta1AllowedFlexVolumeBuilder() { this(false); } + public V1beta1AllowedFlexVolumeBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1AllowedFlexVolume(), validationEnabled); } - public V1beta1AllowedFlexVolumeBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent fluent) { + + public V1beta1AllowedFlexVolumeBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent fluent) { this(fluent, false); } - public V1beta1AllowedFlexVolumeBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1AllowedFlexVolumeBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1AllowedFlexVolume(), validationEnabled); } - public V1beta1AllowedFlexVolumeBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent fluent,io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume instance) { + + public V1beta1AllowedFlexVolumeBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent fluent, + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume instance) { this(fluent, instance, false); } - public V1beta1AllowedFlexVolumeBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent fluent,io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1AllowedFlexVolumeBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent fluent, + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDriver(instance.getDriver()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1AllowedFlexVolumeBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume instance) { - this(instance,false); + + public V1beta1AllowedFlexVolumeBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume instance) { + this(instance, false); } - public V1beta1AllowedFlexVolumeBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1AllowedFlexVolumeBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDriver(instance.getDriver()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume build() { V1beta1AllowedFlexVolume buildable = new V1beta1AllowedFlexVolume(); buildable.setDriver(fluent.getDriver()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1AllowedFlexVolumeBuilder that = (V1beta1AllowedFlexVolumeBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedFlexVolumeFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedFlexVolumeFluent.java index 31f1730de7..ab6e419f59 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedFlexVolumeFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedFlexVolumeFluent.java @@ -1,23 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1AllowedFlexVolumeFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1AllowedFlexVolumeFluent< + A extends io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getDriver(); + public A withDriver(java.lang.String driver); + public java.lang.Boolean hasDriver(); - - /** - * Method is deprecated. use withDriver instead. - */ + + /** Method is deprecated. use withDriver instead. */ @java.lang.Deprecated public A withNewDriver(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedFlexVolumeFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedFlexVolumeFluentImpl.java index 01ee1f9d90..58f4b89111 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedFlexVolumeFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedFlexVolumeFluentImpl.java @@ -1,48 +1,59 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta1AllowedFlexVolumeFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent{ - public V1beta1AllowedFlexVolumeFluentImpl() { - } - public V1beta1AllowedFlexVolumeFluentImpl(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume instance) { - this.withDriver(instance.getDriver()); +/** Generated */ +public class V1beta1AllowedFlexVolumeFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent { + public V1beta1AllowedFlexVolumeFluentImpl() {} + public V1beta1AllowedFlexVolumeFluentImpl( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume instance) { + this.withDriver(instance.getDriver()); } + private java.lang.String driver; + public java.lang.String getDriver() { return this.driver; } + public A withDriver(java.lang.String driver) { - this.driver=driver; return (A) this; + this.driver = driver; + return (A) this; } + public java.lang.Boolean hasDriver() { return this.driver != null; } - - /** - * Method is deprecated. use withDriver instead. - */ + + /** Method is deprecated. use withDriver instead. */ @java.lang.Deprecated public A withNewDriver(java.lang.String original) { - return (A)withDriver(new String(original)); + return (A) withDriver(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1AllowedFlexVolumeFluentImpl that = (V1beta1AllowedFlexVolumeFluentImpl) o; - if (driver != null ? !driver.equals(that.driver) :that.driver != null) return false; + if (driver != null ? !driver.equals(that.driver) : that.driver != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(driver, super.hashCode()); + return java.util.Objects.hash(driver, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedHostPathBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedHostPathBuilder.java index a5c54032fe..c5fadc9f77 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedHostPathBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedHostPathBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1AllowedHostPathBuilder extends io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1AllowedHostPathBuilder + extends io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluentImpl< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPath, + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder> { public V1beta1AllowedHostPathBuilder() { this(false); } + public V1beta1AllowedHostPathBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1AllowedHostPath(), validationEnabled); } - public V1beta1AllowedHostPathBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent fluent) { + + public V1beta1AllowedHostPathBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent fluent) { this(fluent, false); } - public V1beta1AllowedHostPathBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1AllowedHostPathBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1AllowedHostPath(), validationEnabled); } - public V1beta1AllowedHostPathBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent fluent,io.kubernetes.client.openapi.models.V1beta1AllowedHostPath instance) { + + public V1beta1AllowedHostPathBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent fluent, + io.kubernetes.client.openapi.models.V1beta1AllowedHostPath instance) { this(fluent, instance, false); } - public V1beta1AllowedHostPathBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent fluent,io.kubernetes.client.openapi.models.V1beta1AllowedHostPath instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1AllowedHostPathBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent fluent, + io.kubernetes.client.openapi.models.V1beta1AllowedHostPath instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPathPrefix(instance.getPathPrefix()); fluent.withReadOnly(instance.getReadOnly()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1AllowedHostPathBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedHostPath instance) { - this(instance,false); + + public V1beta1AllowedHostPathBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedHostPath instance) { + this(instance, false); } - public V1beta1AllowedHostPathBuilder(io.kubernetes.client.openapi.models.V1beta1AllowedHostPath instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1AllowedHostPathBuilder( + io.kubernetes.client.openapi.models.V1beta1AllowedHostPath instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPathPrefix(instance.getPathPrefix()); this.withReadOnly(instance.getReadOnly()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1AllowedHostPath build() { V1beta1AllowedHostPath buildable = new V1beta1AllowedHostPath(); buildable.setPathPrefix(fluent.getPathPrefix()); buildable.setReadOnly(fluent.getReadOnly()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1AllowedHostPathBuilder that = (V1beta1AllowedHostPathBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedHostPathFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedHostPathFluent.java index 5a987c3eed..5a12677386 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedHostPathFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedHostPathFluent.java @@ -1,26 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1AllowedHostPathFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1AllowedHostPathFluent< + A extends io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getPathPrefix(); + public A withPathPrefix(java.lang.String pathPrefix); + public java.lang.Boolean hasPathPrefix(); - - /** - * Method is deprecated. use withPathPrefix instead. - */ + + /** Method is deprecated. use withPathPrefix instead. */ @java.lang.Deprecated public A withNewPathPrefix(java.lang.String original); + public java.lang.Boolean getReadOnly(); + public A withReadOnly(java.lang.Boolean readOnly); + public java.lang.Boolean hasReadOnly(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedHostPathFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedHostPathFluentImpl.java index b2b4ef5c69..2e80ea3b07 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedHostPathFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1AllowedHostPathFluentImpl.java @@ -1,61 +1,77 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1beta1AllowedHostPathFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent { + public V1beta1AllowedHostPathFluentImpl() {} - /** - * Generated - */ -public class V1beta1AllowedHostPathFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent{ - public V1beta1AllowedHostPathFluentImpl() { - } - public V1beta1AllowedHostPathFluentImpl(io.kubernetes.client.openapi.models.V1beta1AllowedHostPath instance) { + public V1beta1AllowedHostPathFluentImpl( + io.kubernetes.client.openapi.models.V1beta1AllowedHostPath instance) { this.withPathPrefix(instance.getPathPrefix()); this.withReadOnly(instance.getReadOnly()); - } + private java.lang.String pathPrefix; private java.lang.Boolean readOnly; + public java.lang.String getPathPrefix() { return this.pathPrefix; } + public A withPathPrefix(java.lang.String pathPrefix) { - this.pathPrefix=pathPrefix; return (A) this; + this.pathPrefix = pathPrefix; + return (A) this; } + public java.lang.Boolean hasPathPrefix() { return this.pathPrefix != null; } - - /** - * Method is deprecated. use withPathPrefix instead. - */ + + /** Method is deprecated. use withPathPrefix instead. */ @java.lang.Deprecated public A withNewPathPrefix(java.lang.String original) { - return (A)withPathPrefix(new String(original)); + return (A) withPathPrefix(new String(original)); } + public java.lang.Boolean getReadOnly() { return this.readOnly; } + public A withReadOnly(java.lang.Boolean readOnly) { - this.readOnly=readOnly; return (A) this; + this.readOnly = readOnly; + return (A) this; } + public java.lang.Boolean hasReadOnly() { return this.readOnly != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1AllowedHostPathFluentImpl that = (V1beta1AllowedHostPathFluentImpl) o; - if (pathPrefix != null ? !pathPrefix.equals(that.pathPrefix) :that.pathPrefix != null) return false; - if (readOnly != null ? !readOnly.equals(that.readOnly) :that.readOnly != null) return false; + if (pathPrefix != null ? !pathPrefix.equals(that.pathPrefix) : that.pathPrefix != null) + return false; + if (readOnly != null ? !readOnly.equals(that.readOnly) : that.readOnly != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(pathPrefix, readOnly, super.hashCode()); + return java.util.Objects.hash(pathPrefix, readOnly, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityBuilder.java index 83c26b099f..6e02e93875 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1CSIStorageCapacityBuilder extends io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1CSIStorageCapacityBuilder + extends io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity, + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder> { public V1beta1CSIStorageCapacityBuilder() { this(false); } + public V1beta1CSIStorageCapacityBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1CSIStorageCapacity(), validationEnabled); } - public V1beta1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent fluent) { + + public V1beta1CSIStorageCapacityBuilder( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent fluent) { this(fluent, false); } - public V1beta1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1CSIStorageCapacityBuilder( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1CSIStorageCapacity(), validationEnabled); } - public V1beta1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent fluent,io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity instance) { + + public V1beta1CSIStorageCapacityBuilder( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent fluent, + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity instance) { this(fluent, instance, false); } - public V1beta1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent fluent,io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1CSIStorageCapacityBuilder( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent fluent, + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withCapacity(instance.getCapacity()); @@ -35,13 +62,18 @@ public V1beta1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1be fluent.withStorageClassName(instance.getStorageClassName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity instance) { - this(instance,false); + + public V1beta1CSIStorageCapacityBuilder( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity instance) { + this(instance, false); } - public V1beta1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1CSIStorageCapacityBuilder( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withCapacity(instance.getCapacity()); @@ -56,10 +88,12 @@ public V1beta1CSIStorageCapacityBuilder(io.kubernetes.client.openapi.models.V1be this.withStorageClassName(instance.getStorageClassName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity build() { V1beta1CSIStorageCapacity buildable = new V1beta1CSIStorageCapacity(); buildable.setApiVersion(fluent.getApiVersion()); @@ -71,18 +105,23 @@ public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity build() { buildable.setStorageClassName(fluent.getStorageClassName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1CSIStorageCapacityBuilder that = (V1beta1CSIStorageCapacityBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityFluent.java index 4f1095ab0a..089a2e28f6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityFluent.java @@ -1,91 +1,143 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1CSIStorageCapacityFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1CSIStorageCapacityFluent< + A extends io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public io.kubernetes.client.custom.Quantity getCapacity(); + public A withCapacity(io.kubernetes.client.custom.Quantity capacity); + public java.lang.Boolean hasCapacity(); + public A withNewCapacity(java.lang.String value); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public io.kubernetes.client.custom.Quantity getMaximumVolumeSize(); + public A withMaximumVolumeSize(io.kubernetes.client.custom.Quantity maximumVolumeSize); + public java.lang.Boolean hasMaximumVolumeSize(); + public A withNewMaximumVolumeSize(java.lang.String value); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildNodeTopology instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getNodeTopology(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildNodeTopology(); + public A withNodeTopology(io.kubernetes.client.openapi.models.V1LabelSelector nodeTopology); + public java.lang.Boolean hasNodeTopology(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested withNewNodeTopology(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested withNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested editNodeTopology(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested editOrNewNodeTopology(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested editOrNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested + withNewNodeTopology(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested + withNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested + editNodeTopology(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested + editOrNewNodeTopology(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested + editOrNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + public java.lang.String getStorageClassName(); + public A withStorageClassName(java.lang.String storageClassName); + public java.lang.Boolean hasStorageClassName(); - - /** - * Method is deprecated. use withStorageClassName instead. - */ + + /** Method is deprecated. use withStorageClassName instead. */ @java.lang.Deprecated public A withNewStorageClassName(java.lang.String original); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface NodeTopologyNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface NodeTopologyNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent + .NodeTopologyNested< + N>> { public N and(); + public N endNodeTopology(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityFluentImpl.java index b8d2c927e4..543a0c165f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityFluentImpl.java @@ -1,20 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta1CSIStorageCapacityFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent{ - public V1beta1CSIStorageCapacityFluentImpl() { - } - public V1beta1CSIStorageCapacityFluentImpl(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity instance) { + +/** Generated */ +public class V1beta1CSIStorageCapacityFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent { + public V1beta1CSIStorageCapacityFluentImpl() {} + + public V1beta1CSIStorageCapacityFluentImpl( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity instance) { this.withApiVersion(instance.getApiVersion()); this.withCapacity(instance.getCapacity()); @@ -28,8 +36,8 @@ public V1beta1CSIStorageCapacityFluentImpl(io.kubernetes.client.openapi.models.V this.withNodeTopology(instance.getNodeTopology()); this.withStorageClassName(instance.getStorageClassName()); - } + private java.lang.String apiVersion; private io.kubernetes.client.custom.Quantity capacity; private java.lang.String kind; @@ -37,196 +45,293 @@ public V1beta1CSIStorageCapacityFluentImpl(io.kubernetes.client.openapi.models.V private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder nodeTopology; private java.lang.String storageClassName; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public io.kubernetes.client.custom.Quantity getCapacity() { return this.capacity; } + public A withCapacity(io.kubernetes.client.custom.Quantity capacity) { - this.capacity=capacity; return (A) this; + this.capacity = capacity; + return (A) this; } + public java.lang.Boolean hasCapacity() { return this.capacity != null; } + public A withNewCapacity(java.lang.String value) { - return (A)withCapacity(new Quantity(value)); + return (A) withCapacity(new Quantity(value)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public io.kubernetes.client.custom.Quantity getMaximumVolumeSize() { return this.maximumVolumeSize; } + public A withMaximumVolumeSize(io.kubernetes.client.custom.Quantity maximumVolumeSize) { - this.maximumVolumeSize=maximumVolumeSize; return (A) this; + this.maximumVolumeSize = maximumVolumeSize; + return (A) this; } + public java.lang.Boolean hasMaximumVolumeSize() { return this.maximumVolumeSize != null; } + public A withNewMaximumVolumeSize(java.lang.String value) { - return (A)withMaximumVolumeSize(new Quantity(value)); + return (A) withMaximumVolumeSize(new Quantity(value)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildNodeTopology instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getNodeTopology() { - return this.nodeTopology!=null ?this.nodeTopology.build():null; + return this.nodeTopology != null ? this.nodeTopology.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildNodeTopology() { - return this.nodeTopology!=null ?this.nodeTopology.build():null; + return this.nodeTopology != null ? this.nodeTopology.build() : null; } + public A withNodeTopology(io.kubernetes.client.openapi.models.V1LabelSelector nodeTopology) { _visitables.get("nodeTopology").remove(this.nodeTopology); - if (nodeTopology!=null){ this.nodeTopology= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(nodeTopology); _visitables.get("nodeTopology").add(this.nodeTopology);} return (A) this; + if (nodeTopology != null) { + this.nodeTopology = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(nodeTopology); + _visitables.get("nodeTopology").add(this.nodeTopology); + } + return (A) this; } + public java.lang.Boolean hasNodeTopology() { return this.nodeTopology != null; } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested withNewNodeTopology() { - return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluentImpl.NodeTopologyNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested + withNewNodeTopology() { + return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluentImpl + .NodeTopologyNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested withNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluentImpl.NodeTopologyNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested + withNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluentImpl + .NodeTopologyNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested editNodeTopology() { + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested + editNodeTopology() { return withNewNodeTopologyLike(getNodeTopology()); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested editOrNewNodeTopology() { - return withNewNodeTopologyLike(getNodeTopology() != null ? getNodeTopology(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested + editOrNewNodeTopology() { + return withNewNodeTopologyLike( + getNodeTopology() != null + ? getNodeTopology() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested editOrNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewNodeTopologyLike(getNodeTopology() != null ? getNodeTopology(): item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested + editOrNewNodeTopologyLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewNodeTopologyLike(getNodeTopology() != null ? getNodeTopology() : item); } + public java.lang.String getStorageClassName() { return this.storageClassName; } + public A withStorageClassName(java.lang.String storageClassName) { - this.storageClassName=storageClassName; return (A) this; + this.storageClassName = storageClassName; + return (A) this; } + public java.lang.Boolean hasStorageClassName() { return this.storageClassName != null; } - - /** - * Method is deprecated. use withStorageClassName instead. - */ + + /** Method is deprecated. use withStorageClassName instead. */ @java.lang.Deprecated public A withNewStorageClassName(java.lang.String original) { - return (A)withStorageClassName(new String(original)); + return (A) withStorageClassName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1CSIStorageCapacityFluentImpl that = (V1beta1CSIStorageCapacityFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (capacity != null ? !capacity.equals(that.capacity) :that.capacity != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (maximumVolumeSize != null ? !maximumVolumeSize.equals(that.maximumVolumeSize) :that.maximumVolumeSize != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (nodeTopology != null ? !nodeTopology.equals(that.nodeTopology) :that.nodeTopology != null) return false; - if (storageClassName != null ? !storageClassName.equals(that.storageClassName) :that.storageClassName != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (capacity != null ? !capacity.equals(that.capacity) : that.capacity != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (maximumVolumeSize != null + ? !maximumVolumeSize.equals(that.maximumVolumeSize) + : that.maximumVolumeSize != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (nodeTopology != null ? !nodeTopology.equals(that.nodeTopology) : that.nodeTopology != null) + return false; + if (storageClassName != null + ? !storageClassName.equals(that.storageClassName) + : that.storageClassName != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, capacity, kind, maximumVolumeSize, metadata, nodeTopology, storageClassName, super.hashCode()); + return java.util.Objects.hash( + apiVersion, + capacity, + kind, + maximumVolumeSize, + metadata, + nodeTopology, + storageClassName, + super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1beta1CSIStorageCapacityFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class NodeTopologyNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested,io.kubernetes.client.fluent.Nested{ + + public class NodeTopologyNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent.NodeTopologyNested> + implements io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent + .NodeTopologyNested< + N>, + io.kubernetes.client.fluent.Nested { NodeTopologyNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + NodeTopologyNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1beta1CSIStorageCapacityFluentImpl.this.withNodeTopology(builder.build()); } + public N endNodeTopology() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityListBuilder.java index 422bef556f..2bf4d89074 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1CSIStorageCapacityListBuilder extends io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1CSIStorageCapacityListBuilder + extends io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityList, + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListBuilder> { public V1beta1CSIStorageCapacityListBuilder() { this(false); } + public V1beta1CSIStorageCapacityListBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1CSIStorageCapacityList(), validationEnabled); } - public V1beta1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent fluent) { + + public V1beta1CSIStorageCapacityListBuilder( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent fluent) { this(fluent, false); } - public V1beta1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1CSIStorageCapacityListBuilder( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1CSIStorageCapacityList(), validationEnabled); } - public V1beta1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent fluent,io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityList instance) { + + public V1beta1CSIStorageCapacityListBuilder( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityList instance) { this(fluent, instance, false); } - public V1beta1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent fluent,io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1CSIStorageCapacityListBuilder( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1beta1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models. fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityList instance) { - this(instance,false); + + public V1beta1CSIStorageCapacityListBuilder( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityList instance) { + this(instance, false); } - public V1beta1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1CSIStorageCapacityListBuilder( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1beta1CSIStorageCapacityListBuilder(io.kubernetes.client.openapi.models. this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityList build() { V1beta1CSIStorageCapacityList buildable = new V1beta1CSIStorageCapacityList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityList build() buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1CSIStorageCapacityListBuilder that = (V1beta1CSIStorageCapacityListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityListFluent.java index 819da75506..b94572352c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityListFluent.java @@ -1,95 +1,169 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1CSIStorageCapacityListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1CSIStorageCapacityListFluent< + A extends io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item); + public A addToItems(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity buildFirstItem(); + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity buildLastItem(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluent< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityListFluentImpl.java index 236e2a5a87..3d43f41c87 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CSIStorageCapacityListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta1CSIStorageCapacityListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent{ - public V1beta1CSIStorageCapacityListFluentImpl() { - } - public V1beta1CSIStorageCapacityListFluentImpl(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityList instance) { + +/** Generated */ +public class V1beta1CSIStorageCapacityListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent { + public V1beta1CSIStorageCapacityListFluentImpl() {} + + public V1beta1CSIStorageCapacityListFluentImpl( + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,132 @@ public V1beta1CSIStorageCapacityListFluentImpl(io.kubernetes.client.openapi.mode this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder = new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder = new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item : items) {io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder = new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item : items) { + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item : items) {io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder = new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item : items) { + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity... items) { - for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item : items) {io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder = new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item : items) { + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item : items) {io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder = new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item : items) { + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder = each.next(); @@ -87,174 +165,295 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } - public java.util.List buildItems() { + + public java.util.List + buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item) { - return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item) { + return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item) { - return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item) { + return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1CSIStorageCapacityListFluentImpl that = (V1beta1CSIStorageCapacityListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent + .ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacity item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1CSIStorageCapacityListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1beta1CSIStorageCapacityListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1CSIStorageCapacityListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1beta1CSIStorageCapacityListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobBuilder.java index 9756bd8538..bff1f7621e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1CronJobBuilder extends io.kubernetes.client.openapi.models.V1beta1CronJobFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1CronJobBuilder + extends io.kubernetes.client.openapi.models.V1beta1CronJobFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CronJobBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1CronJob, + io.kubernetes.client.openapi.models.V1beta1CronJobBuilder> { public V1beta1CronJobBuilder() { this(false); } + public V1beta1CronJobBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1CronJob(), validationEnabled); } + public V1beta1CronJobBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobFluent fluent) { this(fluent, false); } - public V1beta1CronJobBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1CronJobBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1CronJob(), validationEnabled); } - public V1beta1CronJobBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobFluent fluent,io.kubernetes.client.openapi.models.V1beta1CronJob instance) { + + public V1beta1CronJobBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobFluent fluent, + io.kubernetes.client.openapi.models.V1beta1CronJob instance) { this(fluent, instance, false); } - public V1beta1CronJobBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobFluent fluent,io.kubernetes.client.openapi.models.V1beta1CronJob instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1CronJobBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobFluent fluent, + io.kubernetes.client.openapi.models.V1beta1CronJob instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +57,17 @@ public V1beta1CronJobBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobF fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1beta1CronJobBuilder(io.kubernetes.client.openapi.models.V1beta1CronJob instance) { - this(instance,false); + this(instance, false); } - public V1beta1CronJobBuilder(io.kubernetes.client.openapi.models.V1beta1CronJob instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1CronJobBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJob instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +78,12 @@ public V1beta1CronJobBuilder(io.kubernetes.client.openapi.models.V1beta1CronJob this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1CronJobFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1CronJob build() { V1beta1CronJob buildable = new V1beta1CronJob(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +93,23 @@ public io.kubernetes.client.openapi.models.V1beta1CronJob build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1CronJobBuilder that = (V1beta1CronJobBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobFluent.java index c564a7f8f5..48bf7d0794 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobFluent.java @@ -1,93 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1CronJobFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1CronJobFluent< + A extends io.kubernetes.client.openapi.models.V1beta1CronJobFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1CronJobSpec getSpec(); + public io.kubernetes.client.openapi.models.V1beta1CronJobSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1beta1CronJobSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1CronJobSpec item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1beta1CronJobSpec item); + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1CronJobSpec item); - + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1beta1CronJobSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1CronJobStatus getStatus(); + public io.kubernetes.client.openapi.models.V1beta1CronJobStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1beta1CronJobStatus status); + public java.lang.Boolean hasStatus(); + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1beta1CronJobStatus item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1beta1CronJobStatus item); + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested editStatus(); + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta1CronJobStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta1CronJobStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent< + io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent< + io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobFluentImpl.java index fbfe1f944a..36a090b980 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1CronJobFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1CronJobFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1CronJobFluent { + public V1beta1CronJobFluentImpl() {} - /** - * Generated - */ -public class V1beta1CronJobFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1CronJobFluent{ - public V1beta1CronJobFluentImpl() { - } public V1beta1CronJobFluentImpl(io.kubernetes.client.openapi.models.V1beta1CronJob instance) { this.withApiVersion(instance.getApiVersion()); @@ -23,210 +29,299 @@ public V1beta1CronJobFluentImpl(io.kubernetes.client.openapi.models.V1beta1CronJ this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1beta1CronJobSpecBuilder spec; private io.kubernetes.client.openapi.models.V1beta1CronJobStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1beta1CronJobFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1CronJobFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1CronJobFluentImpl.MetadataNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1CronJobSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1CronJobSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1beta1CronJobSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1beta1CronJobSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1beta1CronJobSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1beta1CronJobFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1CronJobSpec item) { + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1beta1CronJobSpec item) { return new io.kubernetes.client.openapi.models.V1beta1CronJobFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1beta1CronJobSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1beta1CronJobSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1CronJobSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1beta1CronJobSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1CronJobStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1CronJobStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1beta1CronJobStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1beta1CronJobStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1beta1CronJobStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested withNewStatus() { return new io.kubernetes.client.openapi.models.V1beta1CronJobFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1beta1CronJobStatus item) { + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested withNewStatusLike( + io.kubernetes.client.openapi.models.V1beta1CronJobStatus item) { return new io.kubernetes.client.openapi.models.V1beta1CronJobFluentImpl.StatusNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1beta1CronJobStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1beta1CronJobStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta1CronJobStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta1CronJobStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1CronJobFluentImpl that = (V1beta1CronJobFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1CronJobFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1beta1CronJobFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1beta1CronJobFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1beta1CronJobSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1beta1CronJobSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta1CronJobSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1CronJobSpecBuilder builder; + public N and() { return (N) V1beta1CronJobFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1beta1CronJobFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1beta1CronJobStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1CronJobStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1CronJobStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta1CronJobStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1CronJobStatusBuilder builder; + public N and() { return (N) V1beta1CronJobFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobListBuilder.java index 6923f554d6..39a794a0b2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1CronJobListBuilder extends io.kubernetes.client.openapi.models.V1beta1CronJobListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1CronJobListBuilder + extends io.kubernetes.client.openapi.models.V1beta1CronJobListFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CronJobListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1CronJobList, + io.kubernetes.client.openapi.models.V1beta1CronJobListBuilder> { public V1beta1CronJobListBuilder() { this(false); } + public V1beta1CronJobListBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1CronJobList(), validationEnabled); } - public V1beta1CronJobListBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobListFluent fluent) { + + public V1beta1CronJobListBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobListFluent fluent) { this(fluent, false); } - public V1beta1CronJobListBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1CronJobListBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1CronJobList(), validationEnabled); } - public V1beta1CronJobListBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobListFluent fluent,io.kubernetes.client.openapi.models.V1beta1CronJobList instance) { + + public V1beta1CronJobListBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1CronJobList instance) { this(fluent, instance, false); } - public V1beta1CronJobListBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobListFluent fluent,io.kubernetes.client.openapi.models.V1beta1CronJobList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1CronJobListBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1CronJobList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1beta1CronJobListBuilder(io.kubernetes.client.openapi.models.V1beta1Cron fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1CronJobListBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobList instance) { - this(instance,false); + + public V1beta1CronJobListBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobList instance) { + this(instance, false); } - public V1beta1CronJobListBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1CronJobListBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1beta1CronJobListBuilder(io.kubernetes.client.openapi.models.V1beta1Cron this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1CronJobListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1CronJobList build() { V1beta1CronJobList buildable = new V1beta1CronJobList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1beta1CronJobList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1CronJobListBuilder that = (V1beta1CronJobListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobListFluent.java index c2cd37cacb..608c4fc18a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobListFluent.java @@ -1,95 +1,156 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1CronJobListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1CronJobListFluent< + A extends io.kubernetes.client.openapi.models.V1beta1CronJobListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CronJob item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CronJob item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1CronJob item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1CronJob item); + public A addToItems(io.kubernetes.client.openapi.models.V1beta1CronJob... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1CronJob... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1beta1CronJob buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1CronJob buildFirstItem(); + public io.kubernetes.client.openapi.models.V1beta1CronJob buildLastItem(); - public io.kubernetes.client.openapi.models.V1beta1CronJob buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1CronJob buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1beta1CronJob... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1CronJob item); - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CronJob item); - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested editFirstItem(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1beta1CronJob item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1CronJob item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested + editFirstItem(); + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1CronJobFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1CronJobFluent< + io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobListFluentImpl.java index 12af43253a..25b9209d85 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta1CronJobListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1CronJobListFluent{ - public V1beta1CronJobListFluentImpl() { - } - public V1beta1CronJobListFluentImpl(io.kubernetes.client.openapi.models.V1beta1CronJobList instance) { + +/** Generated */ +public class V1beta1CronJobListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1CronJobListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1CronJobListFluent { + public V1beta1CronJobListFluentImpl() {} + + public V1beta1CronJobListFluentImpl( + io.kubernetes.client.openapi.models.V1beta1CronJobList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1beta1CronJobListFluentImpl(io.kubernetes.client.openapi.models.V1beta1C this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CronJob item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder = new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1CronJob item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CronJob item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder = new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1CronJob item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1beta1CronJob... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1CronJob item : items) {io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder = new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1CronJob item : items) { + io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1CronJob item : items) {io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder = new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1CronJob item : items) { + io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1CronJob... items) { - for (io.kubernetes.client.openapi.models.V1beta1CronJob item : items) {io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder = new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1CronJob item : items) { + io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1CronJob item : items) {io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder = new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1CronJob item : items) { + io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder = each.next(); @@ -87,174 +159,279 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1beta1CronJob buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1CronJob buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1CronJob buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1CronJob buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1CronJobBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1CronJob buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1CronJobBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1CronJobBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1CronJobBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1CronJob item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1CronJob item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1beta1CronJob... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1beta1CronJob item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1beta1CronJob item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1beta1CronJobListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1CronJob item) { - return new io.kubernetes.client.openapi.models.V1beta1CronJobListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1beta1CronJob item) { + return new io.kubernetes.client.openapi.models.V1beta1CronJobListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CronJob item) { - return new io.kubernetes.client.openapi.models.V1beta1CronJobListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1CronJob item) { + return new io.kubernetes.client.openapi.models.V1beta1CronJobListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1CronJobListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1CronJobListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1CronJobListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1CronJobListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1CronJobListFluentImpl that = (V1beta1CronJobListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1CronJobFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1CronJob item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1CronJobFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1CronJob item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1CronJobBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1CronJobBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1CronJobListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1beta1CronJobListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1CronJobListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1beta1CronJobListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobSpecBuilder.java index db5cc9f2ff..c0ee9e55f9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1CronJobSpecBuilder extends io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1CronJobSpecBuilder + extends io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CronJobSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1CronJobSpec, + io.kubernetes.client.openapi.models.V1beta1CronJobSpecBuilder> { public V1beta1CronJobSpecBuilder() { this(false); } + public V1beta1CronJobSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1CronJobSpec(), validationEnabled); } - public V1beta1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent fluent) { + + public V1beta1CronJobSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent fluent) { this(fluent, false); } - public V1beta1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1CronJobSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1CronJobSpec(), validationEnabled); } - public V1beta1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta1CronJobSpec instance) { + + public V1beta1CronJobSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta1CronJobSpec instance) { this(fluent, instance, false); } - public V1beta1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta1CronJobSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1CronJobSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta1CronJobSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConcurrencyPolicy(instance.getConcurrencyPolicy()); fluent.withFailedJobsHistoryLimit(instance.getFailedJobsHistoryLimit()); @@ -35,13 +62,18 @@ public V1beta1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1beta1Cron fluent.withSuspend(instance.getSuspend()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobSpec instance) { - this(instance,false); + + public V1beta1CronJobSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobSpec instance) { + this(instance, false); } - public V1beta1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1CronJobSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConcurrencyPolicy(instance.getConcurrencyPolicy()); this.withFailedJobsHistoryLimit(instance.getFailedJobsHistoryLimit()); @@ -56,10 +88,12 @@ public V1beta1CronJobSpecBuilder(io.kubernetes.client.openapi.models.V1beta1Cron this.withSuspend(instance.getSuspend()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1CronJobSpec build() { V1beta1CronJobSpec buildable = new V1beta1CronJobSpec(); buildable.setConcurrencyPolicy(fluent.getConcurrencyPolicy()); @@ -71,18 +105,23 @@ public io.kubernetes.client.openapi.models.V1beta1CronJobSpec build() { buildable.setSuspend(fluent.getSuspend()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1CronJobSpecBuilder that = (V1beta1CronJobSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobSpecFluent.java index 0807eaea6b..db3124e315 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobSpecFluent.java @@ -1,67 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Long; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1CronJobSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1CronJobSpecFluent< + A extends io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getConcurrencyPolicy(); + public A withConcurrencyPolicy(java.lang.String concurrencyPolicy); + public java.lang.Boolean hasConcurrencyPolicy(); - - /** - * Method is deprecated. use withConcurrencyPolicy instead. - */ + + /** Method is deprecated. use withConcurrencyPolicy instead. */ @java.lang.Deprecated public A withNewConcurrencyPolicy(java.lang.String original); + public java.lang.Integer getFailedJobsHistoryLimit(); + public A withFailedJobsHistoryLimit(java.lang.Integer failedJobsHistoryLimit); + public java.lang.Boolean hasFailedJobsHistoryLimit(); - + /** * This method has been deprecated, please use method buildJobTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec getJobTemplate(); + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec buildJobTemplate(); + public A withJobTemplate(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec jobTemplate); + public java.lang.Boolean hasJobTemplate(); - public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested withNewJobTemplate(); - public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested withNewJobTemplateLike(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec item); - public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested editJobTemplate(); - public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested editOrNewJobTemplate(); - public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested editOrNewJobTemplateLike(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested + withNewJobTemplate(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested + withNewJobTemplateLike(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested + editJobTemplate(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested + editOrNewJobTemplate(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested + editOrNewJobTemplateLike(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec item); + public java.lang.String getSchedule(); + public A withSchedule(java.lang.String schedule); + public java.lang.Boolean hasSchedule(); - - /** - * Method is deprecated. use withSchedule instead. - */ + + /** Method is deprecated. use withSchedule instead. */ @java.lang.Deprecated public A withNewSchedule(java.lang.String original); + public java.lang.Long getStartingDeadlineSeconds(); + public A withStartingDeadlineSeconds(java.lang.Long startingDeadlineSeconds); + public java.lang.Boolean hasStartingDeadlineSeconds(); + public java.lang.Integer getSuccessfulJobsHistoryLimit(); + public A withSuccessfulJobsHistoryLimit(java.lang.Integer successfulJobsHistoryLimit); + public java.lang.Boolean hasSuccessfulJobsHistoryLimit(); + public java.lang.Boolean getSuspend(); + public A withSuspend(java.lang.Boolean suspend); + public java.lang.Boolean hasSuspend(); - public interface JobTemplateNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent>{ + + public interface JobTemplateNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent< + io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested> { public N and(); + public N endJobTemplate(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobSpecFluentImpl.java index 8fce4dbe60..609832a197 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobSpecFluentImpl.java @@ -1,21 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta1CronJobSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent{ - public V1beta1CronJobSpecFluentImpl() { - } - public V1beta1CronJobSpecFluentImpl(io.kubernetes.client.openapi.models.V1beta1CronJobSpec instance) { +/** Generated */ +public class V1beta1CronJobSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent { + public V1beta1CronJobSpecFluentImpl() {} + + public V1beta1CronJobSpecFluentImpl( + io.kubernetes.client.openapi.models.V1beta1CronJobSpec instance) { this.withConcurrencyPolicy(instance.getConcurrencyPolicy()); this.withFailedJobsHistoryLimit(instance.getFailedJobsHistoryLimit()); @@ -29,8 +34,8 @@ public V1beta1CronJobSpecFluentImpl(io.kubernetes.client.openapi.models.V1beta1C this.withSuccessfulJobsHistoryLimit(instance.getSuccessfulJobsHistoryLimit()); this.withSuspend(instance.getSuspend()); - } + private java.lang.String concurrencyPolicy; private java.lang.Integer failedJobsHistoryLimit; private io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecBuilder jobTemplate; @@ -38,141 +43,212 @@ public V1beta1CronJobSpecFluentImpl(io.kubernetes.client.openapi.models.V1beta1C private java.lang.Long startingDeadlineSeconds; private java.lang.Integer successfulJobsHistoryLimit; private java.lang.Boolean suspend; + public java.lang.String getConcurrencyPolicy() { return this.concurrencyPolicy; } + public A withConcurrencyPolicy(java.lang.String concurrencyPolicy) { - this.concurrencyPolicy=concurrencyPolicy; return (A) this; + this.concurrencyPolicy = concurrencyPolicy; + return (A) this; } + public java.lang.Boolean hasConcurrencyPolicy() { return this.concurrencyPolicy != null; } - - /** - * Method is deprecated. use withConcurrencyPolicy instead. - */ + + /** Method is deprecated. use withConcurrencyPolicy instead. */ @java.lang.Deprecated public A withNewConcurrencyPolicy(java.lang.String original) { - return (A)withConcurrencyPolicy(new String(original)); + return (A) withConcurrencyPolicy(new String(original)); } + public java.lang.Integer getFailedJobsHistoryLimit() { return this.failedJobsHistoryLimit; } + public A withFailedJobsHistoryLimit(java.lang.Integer failedJobsHistoryLimit) { - this.failedJobsHistoryLimit=failedJobsHistoryLimit; return (A) this; + this.failedJobsHistoryLimit = failedJobsHistoryLimit; + return (A) this; } + public java.lang.Boolean hasFailedJobsHistoryLimit() { return this.failedJobsHistoryLimit != null; } - + /** * This method has been deprecated, please use method buildJobTemplate instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec getJobTemplate() { - return this.jobTemplate!=null ?this.jobTemplate.build():null; + return this.jobTemplate != null ? this.jobTemplate.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec buildJobTemplate() { - return this.jobTemplate!=null ?this.jobTemplate.build():null; + return this.jobTemplate != null ? this.jobTemplate.build() : null; } + public A withJobTemplate(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec jobTemplate) { _visitables.get("jobTemplate").remove(this.jobTemplate); - if (jobTemplate!=null){ this.jobTemplate= new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecBuilder(jobTemplate); _visitables.get("jobTemplate").add(this.jobTemplate);} return (A) this; + if (jobTemplate != null) { + this.jobTemplate = + new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecBuilder(jobTemplate); + _visitables.get("jobTemplate").add(this.jobTemplate); + } + return (A) this; } + public java.lang.Boolean hasJobTemplate() { return this.jobTemplate != null; } - public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested withNewJobTemplate() { - return new io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluentImpl.JobTemplateNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested + withNewJobTemplate() { + return new io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluentImpl + .JobTemplateNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested withNewJobTemplateLike(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec item) { - return new io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluentImpl.JobTemplateNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested + withNewJobTemplateLike(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec item) { + return new io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluentImpl + .JobTemplateNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested editJobTemplate() { + + public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested + editJobTemplate() { return withNewJobTemplateLike(getJobTemplate()); } - public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested editOrNewJobTemplate() { - return withNewJobTemplateLike(getJobTemplate() != null ? getJobTemplate(): new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested + editOrNewJobTemplate() { + return withNewJobTemplateLike( + getJobTemplate() != null + ? getJobTemplate() + : new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested editOrNewJobTemplateLike(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec item) { - return withNewJobTemplateLike(getJobTemplate() != null ? getJobTemplate(): item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested + editOrNewJobTemplateLike(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec item) { + return withNewJobTemplateLike(getJobTemplate() != null ? getJobTemplate() : item); } + public java.lang.String getSchedule() { return this.schedule; } + public A withSchedule(java.lang.String schedule) { - this.schedule=schedule; return (A) this; + this.schedule = schedule; + return (A) this; } + public java.lang.Boolean hasSchedule() { return this.schedule != null; } - - /** - * Method is deprecated. use withSchedule instead. - */ + + /** Method is deprecated. use withSchedule instead. */ @java.lang.Deprecated public A withNewSchedule(java.lang.String original) { - return (A)withSchedule(new String(original)); + return (A) withSchedule(new String(original)); } + public java.lang.Long getStartingDeadlineSeconds() { return this.startingDeadlineSeconds; } + public A withStartingDeadlineSeconds(java.lang.Long startingDeadlineSeconds) { - this.startingDeadlineSeconds=startingDeadlineSeconds; return (A) this; + this.startingDeadlineSeconds = startingDeadlineSeconds; + return (A) this; } + public java.lang.Boolean hasStartingDeadlineSeconds() { return this.startingDeadlineSeconds != null; } + public java.lang.Integer getSuccessfulJobsHistoryLimit() { return this.successfulJobsHistoryLimit; } + public A withSuccessfulJobsHistoryLimit(java.lang.Integer successfulJobsHistoryLimit) { - this.successfulJobsHistoryLimit=successfulJobsHistoryLimit; return (A) this; + this.successfulJobsHistoryLimit = successfulJobsHistoryLimit; + return (A) this; } + public java.lang.Boolean hasSuccessfulJobsHistoryLimit() { return this.successfulJobsHistoryLimit != null; } + public java.lang.Boolean getSuspend() { return this.suspend; } + public A withSuspend(java.lang.Boolean suspend) { - this.suspend=suspend; return (A) this; + this.suspend = suspend; + return (A) this; } + public java.lang.Boolean hasSuspend() { return this.suspend != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1CronJobSpecFluentImpl that = (V1beta1CronJobSpecFluentImpl) o; - if (concurrencyPolicy != null ? !concurrencyPolicy.equals(that.concurrencyPolicy) :that.concurrencyPolicy != null) return false; - if (failedJobsHistoryLimit != null ? !failedJobsHistoryLimit.equals(that.failedJobsHistoryLimit) :that.failedJobsHistoryLimit != null) return false; - if (jobTemplate != null ? !jobTemplate.equals(that.jobTemplate) :that.jobTemplate != null) return false; - if (schedule != null ? !schedule.equals(that.schedule) :that.schedule != null) return false; - if (startingDeadlineSeconds != null ? !startingDeadlineSeconds.equals(that.startingDeadlineSeconds) :that.startingDeadlineSeconds != null) return false; - if (successfulJobsHistoryLimit != null ? !successfulJobsHistoryLimit.equals(that.successfulJobsHistoryLimit) :that.successfulJobsHistoryLimit != null) return false; - if (suspend != null ? !suspend.equals(that.suspend) :that.suspend != null) return false; + if (concurrencyPolicy != null + ? !concurrencyPolicy.equals(that.concurrencyPolicy) + : that.concurrencyPolicy != null) return false; + if (failedJobsHistoryLimit != null + ? !failedJobsHistoryLimit.equals(that.failedJobsHistoryLimit) + : that.failedJobsHistoryLimit != null) return false; + if (jobTemplate != null ? !jobTemplate.equals(that.jobTemplate) : that.jobTemplate != null) + return false; + if (schedule != null ? !schedule.equals(that.schedule) : that.schedule != null) return false; + if (startingDeadlineSeconds != null + ? !startingDeadlineSeconds.equals(that.startingDeadlineSeconds) + : that.startingDeadlineSeconds != null) return false; + if (successfulJobsHistoryLimit != null + ? !successfulJobsHistoryLimit.equals(that.successfulJobsHistoryLimit) + : that.successfulJobsHistoryLimit != null) return false; + if (suspend != null ? !suspend.equals(that.suspend) : that.suspend != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(concurrencyPolicy, failedJobsHistoryLimit, jobTemplate, schedule, startingDeadlineSeconds, successfulJobsHistoryLimit, suspend, super.hashCode()); + return java.util.Objects.hash( + concurrencyPolicy, + failedJobsHistoryLimit, + jobTemplate, + schedule, + startingDeadlineSeconds, + successfulJobsHistoryLimit, + suspend, + super.hashCode()); } - public class JobTemplateNestedImpl extends io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested,io.kubernetes.client.fluent.Nested{ + + public class JobTemplateNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested> + implements io.kubernetes.client.openapi.models.V1beta1CronJobSpecFluent.JobTemplateNested, + io.kubernetes.client.fluent.Nested { JobTemplateNestedImpl(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecBuilder(this, item); } + JobTemplateNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecBuilder builder; + public N and() { return (N) V1beta1CronJobSpecFluentImpl.this.withJobTemplate(builder.build()); } + public N endJobTemplate() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobStatusBuilder.java index bd98940d90..56af2e4108 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobStatusBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1CronJobStatusBuilder extends io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1CronJobStatusBuilder + extends io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CronJobStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1CronJobStatus, + io.kubernetes.client.openapi.models.V1beta1CronJobStatusBuilder> { public V1beta1CronJobStatusBuilder() { this(false); } + public V1beta1CronJobStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1CronJobStatus(), validationEnabled); } - public V1beta1CronJobStatusBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent fluent) { + + public V1beta1CronJobStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent fluent) { this(fluent, false); } - public V1beta1CronJobStatusBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1CronJobStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1CronJobStatus(), validationEnabled); } - public V1beta1CronJobStatusBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent fluent,io.kubernetes.client.openapi.models.V1beta1CronJobStatus instance) { + + public V1beta1CronJobStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent fluent, + io.kubernetes.client.openapi.models.V1beta1CronJobStatus instance) { this(fluent, instance, false); } - public V1beta1CronJobStatusBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent fluent,io.kubernetes.client.openapi.models.V1beta1CronJobStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1CronJobStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent fluent, + io.kubernetes.client.openapi.models.V1beta1CronJobStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withActive(instance.getActive()); fluent.withLastScheduleTime(instance.getLastScheduleTime()); fluent.withLastSuccessfulTime(instance.getLastSuccessfulTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1CronJobStatusBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobStatus instance) { - this(instance,false); + + public V1beta1CronJobStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobStatus instance) { + this(instance, false); } - public V1beta1CronJobStatusBuilder(io.kubernetes.client.openapi.models.V1beta1CronJobStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1CronJobStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1CronJobStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withActive(instance.getActive()); this.withLastScheduleTime(instance.getLastScheduleTime()); this.withLastSuccessfulTime(instance.getLastSuccessfulTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1CronJobStatus build() { V1beta1CronJobStatus buildable = new V1beta1CronJobStatus(); buildable.setActive(fluent.getActive()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1beta1CronJobStatus build() { buildable.setLastSuccessfulTime(fluent.getLastSuccessfulTime()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1CronJobStatusBuilder that = (V1beta1CronJobStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobStatusFluent.java index 9cfb0e9f08..b662b05703 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobStatusFluent.java @@ -1,64 +1,113 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1CronJobStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToActive(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item); - public A setToActive(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item); +/** Generated */ +public interface V1beta1CronJobStatusFluent< + A extends io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToActive( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item); + + public A setToActive( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item); + public A addToActive(io.kubernetes.client.openapi.models.V1ObjectReference... items); - public A addAllToActive(java.util.Collection items); + + public A addAllToActive( + java.util.Collection items); + public A removeFromActive(io.kubernetes.client.openapi.models.V1ObjectReference... items); - public A removeAllFromActive(java.util.Collection items); - public A removeMatchingFromActive(java.util.function.Predicate predicate); - + + public A removeAllFromActive( + java.util.Collection items); + + public A removeMatchingFromActive( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildActive instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getActive(); + public java.util.List buildActive(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildActive(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1ObjectReference buildFirstActive(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildLastActive(); - public io.kubernetes.client.openapi.models.V1ObjectReference buildMatchingActive(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingActive(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1ObjectReference buildMatchingActive( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingActive( + java.util.function.Predicate + predicate); + public A withActive(java.util.List active); + public A withActive(io.kubernetes.client.openapi.models.V1ObjectReference... active); + public java.lang.Boolean hasActive(); - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested addNewActive(); - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested addNewActiveLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested setNewActiveLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item); - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested editActive(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested editFirstActive(); - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested editLastActive(); - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested editMatchingActive(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested + addNewActive(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested + addNewActiveLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested + setNewActiveLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested editActive( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested + editFirstActive(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested + editLastActive(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested + editMatchingActive( + java.util.function.Predicate + predicate); + public java.time.OffsetDateTime getLastScheduleTime(); + public A withLastScheduleTime(java.time.OffsetDateTime lastScheduleTime); + public java.lang.Boolean hasLastScheduleTime(); + public java.time.OffsetDateTime getLastSuccessfulTime(); + public A withLastSuccessfulTime(java.time.OffsetDateTime lastSuccessfulTime); + public java.lang.Boolean hasLastSuccessfulTime(); - public interface ActiveNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface ActiveNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested> { public N and(); + public N endActive(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobStatusFluentImpl.java index b38087a56f..129d78aa46 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1CronJobStatusFluentImpl.java @@ -1,64 +1,134 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1beta1CronJobStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent{ - public V1beta1CronJobStatusFluentImpl() { - } - public V1beta1CronJobStatusFluentImpl(io.kubernetes.client.openapi.models.V1beta1CronJobStatus instance) { +/** Generated */ +public class V1beta1CronJobStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent { + public V1beta1CronJobStatusFluentImpl() {} + + public V1beta1CronJobStatusFluentImpl( + io.kubernetes.client.openapi.models.V1beta1CronJobStatus instance) { this.withActive(instance.getActive()); this.withLastScheduleTime(instance.getLastScheduleTime()); this.withLastSuccessfulTime(instance.getLastSuccessfulTime()); - } + private java.util.ArrayList active; private java.time.OffsetDateTime lastScheduleTime; private java.time.OffsetDateTime lastSuccessfulTime; - public A addToActive(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item) { - if (this.active == null) {this.active = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("active").add(index >= 0 ? index : _visitables.get("active").size(), builder);this.active.add(index >= 0 ? index : active.size(), builder); return (A)this; + + public A addToActive( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item) { + if (this.active == null) { + this.active = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("active").add(index >= 0 ? index : _visitables.get("active").size(), builder); + this.active.add(index >= 0 ? index : active.size(), builder); + return (A) this; } - public A setToActive(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item) { - if (this.active == null) {this.active = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); - if (index < 0 || index >= _visitables.get("active").size()) { _visitables.get("active").add(builder); } else { _visitables.get("active").set(index, builder);} - if (index < 0 || index >= active.size()) { active.add(builder); } else { active.set(index, builder);} - return (A)this; + + public A setToActive( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item) { + if (this.active == null) { + this.active = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + if (index < 0 || index >= _visitables.get("active").size()) { + _visitables.get("active").add(builder); + } else { + _visitables.get("active").set(index, builder); + } + if (index < 0 || index >= active.size()) { + active.add(builder); + } else { + active.set(index, builder); + } + return (A) this; } + public A addToActive(io.kubernetes.client.openapi.models.V1ObjectReference... items) { - if (this.active == null) {this.active = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) {io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("active").add(builder);this.active.add(builder);} return (A)this; + if (this.active == null) { + this.active = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) { + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("active").add(builder); + this.active.add(builder); + } + return (A) this; } - public A addAllToActive(java.util.Collection items) { - if (this.active == null) {this.active = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) {io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("active").add(builder);this.active.add(builder);} return (A)this; + + public A addAllToActive( + java.util.Collection items) { + if (this.active == null) { + this.active = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) { + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("active").add(builder); + this.active.add(builder); + } + return (A) this; } + public A removeFromActive(io.kubernetes.client.openapi.models.V1ObjectReference... items) { - for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) {io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("active").remove(builder);if (this.active != null) {this.active.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) { + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("active").remove(builder); + if (this.active != null) { + this.active.remove(builder); + } + } + return (A) this; } - public A removeAllFromActive(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) {io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item);_visitables.get("active").remove(builder);if (this.active != null) {this.active.remove(builder);}} return (A)this; + + public A removeAllFromActive( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1ObjectReference item : items) { + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = + new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(item); + _visitables.get("active").remove(builder); + if (this.active != null) { + this.active.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromActive(java.util.function.Predicate predicate) { + + public A removeMatchingFromActive( + java.util.function.Predicate + predicate) { if (active == null) return (A) this; - final Iterator each = active.iterator(); + final Iterator each = + active.iterator(); final List visitables = _visitables.get("active"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder = each.next(); @@ -67,124 +137,214 @@ public A removeMatchingFromActive(java.util.function.Predicate getActive() { return active != null ? build(active) : null; } + public java.util.List buildActive() { return active != null ? build(active) : null; } - public io.kubernetes.client.openapi.models.V1ObjectReference buildActive(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1ObjectReference buildActive( + java.lang.Integer index) { return this.active.get(index).build(); } + public io.kubernetes.client.openapi.models.V1ObjectReference buildFirstActive() { return this.active.get(0).build(); } + public io.kubernetes.client.openapi.models.V1ObjectReference buildLastActive() { return this.active.get(active.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1ObjectReference buildMatchingActive(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder item: active) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1ObjectReference buildMatchingActive( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder item : active) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingActive(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder item: active) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingActive( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder item : active) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withActive(java.util.List active) { - if (this.active != null) { _visitables.get("active").removeAll(this.active);} - if (active != null) {this.active = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1ObjectReference item : active){this.addToActive(item);}} else { this.active = null;} return (A) this; + + public A withActive( + java.util.List active) { + if (this.active != null) { + _visitables.get("active").removeAll(this.active); + } + if (active != null) { + this.active = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1ObjectReference item : active) { + this.addToActive(item); + } + } else { + this.active = null; + } + return (A) this; } + public A withActive(io.kubernetes.client.openapi.models.V1ObjectReference... active) { - if (this.active != null) {this.active.clear();} - if (active != null) {for (io.kubernetes.client.openapi.models.V1ObjectReference item :active){ this.addToActive(item);}} return (A) this; + if (this.active != null) { + this.active.clear(); + } + if (active != null) { + for (io.kubernetes.client.openapi.models.V1ObjectReference item : active) { + this.addToActive(item); + } + } + return (A) this; } + public java.lang.Boolean hasActive() { return active != null && !active.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested addNewActive() { - return new io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluentImpl.ActiveNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested + addNewActive() { + return new io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluentImpl + .ActiveNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested addNewActiveLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return new io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluentImpl.ActiveNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested + addNewActiveLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return new io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluentImpl.ActiveNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested setNewActiveLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item) { - return new io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluentImpl.ActiveNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested + setNewActiveLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item) { + return new io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluentImpl.ActiveNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested editActive(java.lang.Integer index) { - if (active.size() <= index) throw new RuntimeException("Can't edit active. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested editActive( + java.lang.Integer index) { + if (active.size() <= index) + throw new RuntimeException("Can't edit active. Index exceeds size."); return setNewActiveLike(index, buildActive(index)); } - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested editFirstActive() { - if (active.size() == 0) throw new RuntimeException("Can't edit first active. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested + editFirstActive() { + if (active.size() == 0) + throw new RuntimeException("Can't edit first active. The list is empty."); return setNewActiveLike(0, buildActive(0)); } - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested editLastActive() { + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested + editLastActive() { int index = active.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last active. The list is empty."); return setNewActiveLike(index, buildActive(index)); } - public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested editMatchingActive(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested + editMatchingActive( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested,io.kubernetes.client.fluent.Nested{ - ActiveNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1ObjectReference item) { + + public class ActiveNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested> + implements io.kubernetes.client.openapi.models.V1beta1CronJobStatusFluent.ActiveNested, + io.kubernetes.client.fluent.Nested { + ActiveNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1ObjectReference item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + ActiveNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1CronJobStatusFluentImpl.this.setToActive(index,builder.build()); + return (N) V1beta1CronJobStatusFluentImpl.this.setToActive(index, builder.build()); } + public N endActive() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointBuilder.java index d719c9c135..0ba76643df 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1EndpointBuilder extends io.kubernetes.client.openapi.models.V1beta1EndpointFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1EndpointBuilder + extends io.kubernetes.client.openapi.models.V1beta1EndpointFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1Endpoint, + io.kubernetes.client.openapi.models.V1beta1EndpointBuilder> { public V1beta1EndpointBuilder() { this(false); } + public V1beta1EndpointBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1Endpoint(), validationEnabled); } - public V1beta1EndpointBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointFluent fluent) { + + public V1beta1EndpointBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointFluent fluent) { this(fluent, false); } - public V1beta1EndpointBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1EndpointBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1Endpoint(), validationEnabled); } - public V1beta1EndpointBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointFluent fluent,io.kubernetes.client.openapi.models.V1beta1Endpoint instance) { + + public V1beta1EndpointBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointFluent fluent, + io.kubernetes.client.openapi.models.V1beta1Endpoint instance) { this(fluent, instance, false); } - public V1beta1EndpointBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointFluent fluent,io.kubernetes.client.openapi.models.V1beta1Endpoint instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1EndpointBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointFluent fluent, + io.kubernetes.client.openapi.models.V1beta1Endpoint instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAddresses(instance.getAddresses()); fluent.withConditions(instance.getConditions()); @@ -35,13 +62,17 @@ public V1beta1EndpointBuilder(io.kubernetes.client.openapi.models.V1beta1Endpoin fluent.withTopology(instance.getTopology()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1beta1EndpointBuilder(io.kubernetes.client.openapi.models.V1beta1Endpoint instance) { - this(instance,false); + this(instance, false); } - public V1beta1EndpointBuilder(io.kubernetes.client.openapi.models.V1beta1Endpoint instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1EndpointBuilder( + io.kubernetes.client.openapi.models.V1beta1Endpoint instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAddresses(instance.getAddresses()); this.withConditions(instance.getConditions()); @@ -56,10 +87,12 @@ public V1beta1EndpointBuilder(io.kubernetes.client.openapi.models.V1beta1Endpoin this.withTopology(instance.getTopology()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1EndpointFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1Endpoint build() { V1beta1Endpoint buildable = new V1beta1Endpoint(); buildable.setAddresses(fluent.getAddresses()); @@ -71,18 +104,23 @@ public io.kubernetes.client.openapi.models.V1beta1Endpoint build() { buildable.setTopology(fluent.getTopology()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1EndpointBuilder that = (V1beta1EndpointBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointConditionsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointConditionsBuilder.java index 15575c5b73..c6562b9992 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointConditionsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointConditionsBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1EndpointConditionsBuilder extends io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1EndpointConditionsBuilder + extends io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointConditionsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1EndpointConditions, + io.kubernetes.client.openapi.models.V1beta1EndpointConditionsBuilder> { public V1beta1EndpointConditionsBuilder() { this(false); } + public V1beta1EndpointConditionsBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1EndpointConditions(), validationEnabled); } - public V1beta1EndpointConditionsBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent fluent) { + + public V1beta1EndpointConditionsBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent fluent) { this(fluent, false); } - public V1beta1EndpointConditionsBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1EndpointConditionsBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1EndpointConditions(), validationEnabled); } - public V1beta1EndpointConditionsBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1EndpointConditions instance) { + + public V1beta1EndpointConditionsBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EndpointConditions instance) { this(fluent, instance, false); } - public V1beta1EndpointConditionsBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1EndpointConditions instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1EndpointConditionsBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EndpointConditions instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withReady(instance.getReady()); fluent.withServing(instance.getServing()); fluent.withTerminating(instance.getTerminating()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1EndpointConditionsBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointConditions instance) { - this(instance,false); + + public V1beta1EndpointConditionsBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointConditions instance) { + this(instance, false); } - public V1beta1EndpointConditionsBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointConditions instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1EndpointConditionsBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointConditions instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withReady(instance.getReady()); this.withServing(instance.getServing()); this.withTerminating(instance.getTerminating()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1EndpointConditions build() { V1beta1EndpointConditions buildable = new V1beta1EndpointConditions(); buildable.setReady(fluent.getReady()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1beta1EndpointConditions build() { buildable.setTerminating(fluent.getTerminating()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1EndpointConditionsBuilder that = (V1beta1EndpointConditionsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointConditionsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointConditionsFluent.java index 996afb2f90..417dafb810 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointConditionsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointConditionsFluent.java @@ -1,22 +1,36 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1EndpointConditionsFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1EndpointConditionsFluent< + A extends io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Boolean getReady(); + public A withReady(java.lang.Boolean ready); + public java.lang.Boolean hasReady(); + public java.lang.Boolean getServing(); + public A withServing(java.lang.Boolean serving); + public java.lang.Boolean hasServing(); + public java.lang.Boolean getTerminating(); + public A withTerminating(java.lang.Boolean terminating); + public java.lang.Boolean hasTerminating(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointConditionsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointConditionsFluentImpl.java index ce9c452c28..fbc87d0dd7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointConditionsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointConditionsFluentImpl.java @@ -1,64 +1,88 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1EndpointConditionsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent { + public V1beta1EndpointConditionsFluentImpl() {} - /** - * Generated - */ -public class V1beta1EndpointConditionsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent{ - public V1beta1EndpointConditionsFluentImpl() { - } - public V1beta1EndpointConditionsFluentImpl(io.kubernetes.client.openapi.models.V1beta1EndpointConditions instance) { + public V1beta1EndpointConditionsFluentImpl( + io.kubernetes.client.openapi.models.V1beta1EndpointConditions instance) { this.withReady(instance.getReady()); this.withServing(instance.getServing()); this.withTerminating(instance.getTerminating()); - } + private java.lang.Boolean ready; private java.lang.Boolean serving; private java.lang.Boolean terminating; + public java.lang.Boolean getReady() { return this.ready; } + public A withReady(java.lang.Boolean ready) { - this.ready=ready; return (A) this; + this.ready = ready; + return (A) this; } + public java.lang.Boolean hasReady() { return this.ready != null; } + public java.lang.Boolean getServing() { return this.serving; } + public A withServing(java.lang.Boolean serving) { - this.serving=serving; return (A) this; + this.serving = serving; + return (A) this; } + public java.lang.Boolean hasServing() { return this.serving != null; } + public java.lang.Boolean getTerminating() { return this.terminating; } + public A withTerminating(java.lang.Boolean terminating) { - this.terminating=terminating; return (A) this; + this.terminating = terminating; + return (A) this; } + public java.lang.Boolean hasTerminating() { return this.terminating != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1EndpointConditionsFluentImpl that = (V1beta1EndpointConditionsFluentImpl) o; - if (ready != null ? !ready.equals(that.ready) :that.ready != null) return false; - if (serving != null ? !serving.equals(that.serving) :that.serving != null) return false; - if (terminating != null ? !terminating.equals(that.terminating) :that.terminating != null) return false; + if (ready != null ? !ready.equals(that.ready) : that.ready != null) return false; + if (serving != null ? !serving.equals(that.serving) : that.serving != null) return false; + if (terminating != null ? !terminating.equals(that.terminating) : that.terminating != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(ready, serving, terminating, super.hashCode()); + return java.util.Objects.hash(ready, serving, terminating, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointFluent.java index 81ab4d87ee..06f416caef 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointFluent.java @@ -1,123 +1,197 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; -import java.util.Map; - - /** - * Generated - */ -public interface V1beta1EndpointFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAddresses(java.lang.Integer index,java.lang.String item); - public A setToAddresses(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1beta1EndpointFluent< + A extends io.kubernetes.client.openapi.models.V1beta1EndpointFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAddresses(java.lang.Integer index, java.lang.String item); + + public A setToAddresses(java.lang.Integer index, java.lang.String item); + public A addToAddresses(java.lang.String... items); + public A addAllToAddresses(java.util.Collection items); + public A removeFromAddresses(java.lang.String... items); + public A removeAllFromAddresses(java.util.Collection items); + public java.util.List getAddresses(); + public java.lang.String getAddress(java.lang.Integer index); + public java.lang.String getFirstAddress(); + public java.lang.String getLastAddress(); - public java.lang.String getMatchingAddress(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAddress(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAddress( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAddress( + java.util.function.Predicate predicate); + public A withAddresses(java.util.List addresses); + public A withAddresses(java.lang.String... addresses); + public java.lang.Boolean hasAddresses(); + public A addNewAddress(java.lang.String original); - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1EndpointConditions getConditions(); + public io.kubernetes.client.openapi.models.V1beta1EndpointConditions buildConditions(); + public A withConditions(io.kubernetes.client.openapi.models.V1beta1EndpointConditions conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested withNewConditions(); - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested withNewConditionsLike(io.kubernetes.client.openapi.models.V1beta1EndpointConditions item); - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested editConditions(); - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested editOrNewConditions(); - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested editOrNewConditionsLike(io.kubernetes.client.openapi.models.V1beta1EndpointConditions item); - + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested + withNewConditions(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested + withNewConditionsLike(io.kubernetes.client.openapi.models.V1beta1EndpointConditions item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested + editConditions(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested + editOrNewConditions(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested + editOrNewConditionsLike(io.kubernetes.client.openapi.models.V1beta1EndpointConditions item); + /** * This method has been deprecated, please use method buildHints instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1EndpointHints getHints(); + public io.kubernetes.client.openapi.models.V1beta1EndpointHints buildHints(); + public A withHints(io.kubernetes.client.openapi.models.V1beta1EndpointHints hints); + public java.lang.Boolean hasHints(); + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested withNewHints(); - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested withNewHintsLike(io.kubernetes.client.openapi.models.V1beta1EndpointHints item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested withNewHintsLike( + io.kubernetes.client.openapi.models.V1beta1EndpointHints item); + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested editHints(); + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested editOrNewHints(); - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested editOrNewHintsLike(io.kubernetes.client.openapi.models.V1beta1EndpointHints item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested + editOrNewHintsLike(io.kubernetes.client.openapi.models.V1beta1EndpointHints item); + public java.lang.String getHostname(); + public A withHostname(java.lang.String hostname); + public java.lang.Boolean hasHostname(); - - /** - * Method is deprecated. use withHostname instead. - */ + + /** Method is deprecated. use withHostname instead. */ @java.lang.Deprecated public A withNewHostname(java.lang.String original); + public java.lang.String getNodeName(); + public A withNodeName(java.lang.String nodeName); + public java.lang.Boolean hasNodeName(); - - /** - * Method is deprecated. use withNodeName instead. - */ + + /** Method is deprecated. use withNodeName instead. */ @java.lang.Deprecated public A withNewNodeName(java.lang.String original); - + /** * This method has been deprecated, please use method buildTargetRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getTargetRef(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildTargetRef(); + public A withTargetRef(io.kubernetes.client.openapi.models.V1ObjectReference targetRef); + public java.lang.Boolean hasTargetRef(); - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested withNewTargetRef(); - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested withNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested editTargetRef(); - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested editOrNewTargetRef(); - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested editOrNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - public A addToTopology(java.lang.String key,java.lang.String value); - public A addToTopology(java.util.Map map); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested + withNewTargetRef(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested + withNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested + editTargetRef(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested + editOrNewTargetRef(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested + editOrNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public A addToTopology(java.lang.String key, java.lang.String value); + + public A addToTopology(java.util.Map map); + public A removeFromTopology(java.lang.String key); - public A removeFromTopology(java.util.Map map); - public java.util.Map getTopology(); - public A withTopology(java.util.Map topology); + + public A removeFromTopology(java.util.Map map); + + public java.util.Map getTopology(); + + public A withTopology(java.util.Map topology); + public java.lang.Boolean hasTopology(); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluent< + io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested> { public N and(); + public N endConditions(); - } - public interface HintsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent>{ + + public interface HintsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent< + io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested> { public N and(); + public N endHints(); - } - public interface TargetRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface TargetRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested> { public N and(); + public N endTargetRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointFluentImpl.java index ea2526fb26..1c413c3c99 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointFluentImpl.java @@ -1,25 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; -import java.util.Map; - - /** - * Generated - */ -public class V1beta1EndpointFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1EndpointFluent{ - public V1beta1EndpointFluentImpl() { - } +/** Generated */ +public class V1beta1EndpointFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1EndpointFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1EndpointFluent { + public V1beta1EndpointFluentImpl() {} + public V1beta1EndpointFluentImpl(io.kubernetes.client.openapi.models.V1beta1Endpoint instance) { this.withAddresses(instance.getAddresses()); @@ -34,293 +33,496 @@ public V1beta1EndpointFluentImpl(io.kubernetes.client.openapi.models.V1beta1Endp this.withTargetRef(instance.getTargetRef()); this.withTopology(instance.getTopology()); - } + private java.util.List addresses; private io.kubernetes.client.openapi.models.V1beta1EndpointConditionsBuilder conditions; private io.kubernetes.client.openapi.models.V1beta1EndpointHintsBuilder hints; private java.lang.String hostname; private java.lang.String nodeName; private io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder targetRef; - private java.util.Map topology; - public A addToAddresses(java.lang.Integer index,java.lang.String item) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} + private java.util.Map topology; + + public A addToAddresses(java.lang.Integer index, java.lang.String item) { + if (this.addresses == null) { + this.addresses = new java.util.ArrayList(); + } this.addresses.add(index, item); - return (A)this; + return (A) this; } - public A setToAddresses(java.lang.Integer index,java.lang.String item) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - this.addresses.set(index, item); return (A)this; + + public A setToAddresses(java.lang.Integer index, java.lang.String item) { + if (this.addresses == null) { + this.addresses = new java.util.ArrayList(); + } + this.addresses.set(index, item); + return (A) this; } + public A addToAddresses(java.lang.String... items) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - for (java.lang.String item : items) {this.addresses.add(item);} return (A)this; + if (this.addresses == null) { + this.addresses = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.addresses.add(item); + } + return (A) this; } + public A addAllToAddresses(java.util.Collection items) { - if (this.addresses == null) {this.addresses = new java.util.ArrayList();} - for (java.lang.String item : items) {this.addresses.add(item);} return (A)this; + if (this.addresses == null) { + this.addresses = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.addresses.add(item); + } + return (A) this; } + public A removeFromAddresses(java.lang.String... items) { - for (java.lang.String item : items) {if (this.addresses!= null){ this.addresses.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.addresses != null) { + this.addresses.remove(item); + } + } + return (A) this; } + public A removeAllFromAddresses(java.util.Collection items) { - for (java.lang.String item : items) {if (this.addresses!= null){ this.addresses.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.addresses != null) { + this.addresses.remove(item); + } + } + return (A) this; } + public java.util.List getAddresses() { return this.addresses; } + public java.lang.String getAddress(java.lang.Integer index) { return this.addresses.get(index); } + public java.lang.String getFirstAddress() { return this.addresses.get(0); } + public java.lang.String getLastAddress() { return this.addresses.get(addresses.size() - 1); } - public java.lang.String getMatchingAddress(java.util.function.Predicate predicate) { - for (java.lang.String item: addresses) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAddress( + java.util.function.Predicate predicate) { + for (java.lang.String item : addresses) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAddress(java.util.function.Predicate predicate) { - for (java.lang.String item: addresses) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAddress( + java.util.function.Predicate predicate) { + for (java.lang.String item : addresses) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAddresses(java.util.List addresses) { - if (addresses != null) {this.addresses = new java.util.ArrayList(); for (java.lang.String item : addresses){this.addToAddresses(item);}} else { this.addresses = null;} return (A) this; + if (addresses != null) { + this.addresses = new java.util.ArrayList(); + for (java.lang.String item : addresses) { + this.addToAddresses(item); + } + } else { + this.addresses = null; + } + return (A) this; } + public A withAddresses(java.lang.String... addresses) { - if (this.addresses != null) {this.addresses.clear();} - if (addresses != null) {for (java.lang.String item :addresses){ this.addToAddresses(item);}} return (A) this; + if (this.addresses != null) { + this.addresses.clear(); + } + if (addresses != null) { + for (java.lang.String item : addresses) { + this.addToAddresses(item); + } + } + return (A) this; } + public java.lang.Boolean hasAddresses() { return addresses != null && !addresses.isEmpty(); } + public A addNewAddress(java.lang.String original) { - return (A)addToAddresses(new String(original)); + return (A) addToAddresses(new String(original)); } - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1EndpointConditions getConditions() { - return this.conditions!=null ?this.conditions.build():null; + return this.conditions != null ? this.conditions.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1EndpointConditions buildConditions() { - return this.conditions!=null ?this.conditions.build():null; + return this.conditions != null ? this.conditions.build() : null; } - public A withConditions(io.kubernetes.client.openapi.models.V1beta1EndpointConditions conditions) { + + public A withConditions( + io.kubernetes.client.openapi.models.V1beta1EndpointConditions conditions) { _visitables.get("conditions").remove(this.conditions); - if (conditions!=null){ this.conditions= new io.kubernetes.client.openapi.models.V1beta1EndpointConditionsBuilder(conditions); _visitables.get("conditions").add(this.conditions);} return (A) this; + if (conditions != null) { + this.conditions = + new io.kubernetes.client.openapi.models.V1beta1EndpointConditionsBuilder(conditions); + _visitables.get("conditions").add(this.conditions); + } + return (A) this; } + public java.lang.Boolean hasConditions() { return this.conditions != null; } - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested withNewConditions() { + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested + withNewConditions() { return new io.kubernetes.client.openapi.models.V1beta1EndpointFluentImpl.ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested withNewConditionsLike(io.kubernetes.client.openapi.models.V1beta1EndpointConditions item) { - return new io.kubernetes.client.openapi.models.V1beta1EndpointFluentImpl.ConditionsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested + withNewConditionsLike(io.kubernetes.client.openapi.models.V1beta1EndpointConditions item) { + return new io.kubernetes.client.openapi.models.V1beta1EndpointFluentImpl.ConditionsNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested editConditions() { + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested + editConditions() { return withNewConditionsLike(getConditions()); } - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested editOrNewConditions() { - return withNewConditionsLike(getConditions() != null ? getConditions(): new io.kubernetes.client.openapi.models.V1beta1EndpointConditionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested + editOrNewConditions() { + return withNewConditionsLike( + getConditions() != null + ? getConditions() + : new io.kubernetes.client.openapi.models.V1beta1EndpointConditionsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested editOrNewConditionsLike(io.kubernetes.client.openapi.models.V1beta1EndpointConditions item) { - return withNewConditionsLike(getConditions() != null ? getConditions(): item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested + editOrNewConditionsLike(io.kubernetes.client.openapi.models.V1beta1EndpointConditions item) { + return withNewConditionsLike(getConditions() != null ? getConditions() : item); } - + /** * This method has been deprecated, please use method buildHints instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1EndpointHints getHints() { - return this.hints!=null ?this.hints.build():null; + return this.hints != null ? this.hints.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1EndpointHints buildHints() { - return this.hints!=null ?this.hints.build():null; + return this.hints != null ? this.hints.build() : null; } + public A withHints(io.kubernetes.client.openapi.models.V1beta1EndpointHints hints) { _visitables.get("hints").remove(this.hints); - if (hints!=null){ this.hints= new io.kubernetes.client.openapi.models.V1beta1EndpointHintsBuilder(hints); _visitables.get("hints").add(this.hints);} return (A) this; + if (hints != null) { + this.hints = new io.kubernetes.client.openapi.models.V1beta1EndpointHintsBuilder(hints); + _visitables.get("hints").add(this.hints); + } + return (A) this; } + public java.lang.Boolean hasHints() { return this.hints != null; } + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested withNewHints() { return new io.kubernetes.client.openapi.models.V1beta1EndpointFluentImpl.HintsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested withNewHintsLike(io.kubernetes.client.openapi.models.V1beta1EndpointHints item) { + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested withNewHintsLike( + io.kubernetes.client.openapi.models.V1beta1EndpointHints item) { return new io.kubernetes.client.openapi.models.V1beta1EndpointFluentImpl.HintsNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested editHints() { return withNewHintsLike(getHints()); } + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested editOrNewHints() { - return withNewHintsLike(getHints() != null ? getHints(): new io.kubernetes.client.openapi.models.V1beta1EndpointHintsBuilder().build()); + return withNewHintsLike( + getHints() != null + ? getHints() + : new io.kubernetes.client.openapi.models.V1beta1EndpointHintsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested editOrNewHintsLike(io.kubernetes.client.openapi.models.V1beta1EndpointHints item) { - return withNewHintsLike(getHints() != null ? getHints(): item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested + editOrNewHintsLike(io.kubernetes.client.openapi.models.V1beta1EndpointHints item) { + return withNewHintsLike(getHints() != null ? getHints() : item); } + public java.lang.String getHostname() { return this.hostname; } + public A withHostname(java.lang.String hostname) { - this.hostname=hostname; return (A) this; + this.hostname = hostname; + return (A) this; } + public java.lang.Boolean hasHostname() { return this.hostname != null; } - - /** - * Method is deprecated. use withHostname instead. - */ + + /** Method is deprecated. use withHostname instead. */ @java.lang.Deprecated public A withNewHostname(java.lang.String original) { - return (A)withHostname(new String(original)); + return (A) withHostname(new String(original)); } + public java.lang.String getNodeName() { return this.nodeName; } + public A withNodeName(java.lang.String nodeName) { - this.nodeName=nodeName; return (A) this; + this.nodeName = nodeName; + return (A) this; } + public java.lang.Boolean hasNodeName() { return this.nodeName != null; } - - /** - * Method is deprecated. use withNodeName instead. - */ + + /** Method is deprecated. use withNodeName instead. */ @java.lang.Deprecated public A withNewNodeName(java.lang.String original) { - return (A)withNodeName(new String(original)); + return (A) withNodeName(new String(original)); } - + /** * This method has been deprecated, please use method buildTargetRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getTargetRef() { - return this.targetRef!=null ?this.targetRef.build():null; + return this.targetRef != null ? this.targetRef.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectReference buildTargetRef() { - return this.targetRef!=null ?this.targetRef.build():null; + return this.targetRef != null ? this.targetRef.build() : null; } + public A withTargetRef(io.kubernetes.client.openapi.models.V1ObjectReference targetRef) { _visitables.get("targetRef").remove(this.targetRef); - if (targetRef!=null){ this.targetRef= new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(targetRef); _visitables.get("targetRef").add(this.targetRef);} return (A) this; + if (targetRef != null) { + this.targetRef = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(targetRef); + _visitables.get("targetRef").add(this.targetRef); + } + return (A) this; } + public java.lang.Boolean hasTargetRef() { return this.targetRef != null; } - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested withNewTargetRef() { + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested + withNewTargetRef() { return new io.kubernetes.client.openapi.models.V1beta1EndpointFluentImpl.TargetRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested withNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return new io.kubernetes.client.openapi.models.V1beta1EndpointFluentImpl.TargetRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested + withNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return new io.kubernetes.client.openapi.models.V1beta1EndpointFluentImpl.TargetRefNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested editTargetRef() { + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested + editTargetRef() { return withNewTargetRefLike(getTargetRef()); } - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested editOrNewTargetRef() { - return withNewTargetRefLike(getTargetRef() != null ? getTargetRef(): new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested + editOrNewTargetRef() { + return withNewTargetRefLike( + getTargetRef() != null + ? getTargetRef() + : new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested editOrNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return withNewTargetRefLike(getTargetRef() != null ? getTargetRef(): item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested + editOrNewTargetRefLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return withNewTargetRefLike(getTargetRef() != null ? getTargetRef() : item); } - public A addToTopology(java.lang.String key,java.lang.String value) { - if(this.topology == null && key != null && value != null) { this.topology = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.topology.put(key, value);} return (A)this; + + public A addToTopology(java.lang.String key, java.lang.String value) { + if (this.topology == null && key != null && value != null) { + this.topology = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.topology.put(key, value); + } + return (A) this; } - public A addToTopology(java.util.Map map) { - if(this.topology == null && map != null) { this.topology = new java.util.LinkedHashMap(); } - if(map != null) { this.topology.putAll(map);} return (A)this; + + public A addToTopology(java.util.Map map) { + if (this.topology == null && map != null) { + this.topology = new java.util.LinkedHashMap(); + } + if (map != null) { + this.topology.putAll(map); + } + return (A) this; } + public A removeFromTopology(java.lang.String key) { - if(this.topology == null) { return (A) this; } - if(key != null && this.topology != null) {this.topology.remove(key);} return (A)this; + if (this.topology == null) { + return (A) this; + } + if (key != null && this.topology != null) { + this.topology.remove(key); + } + return (A) this; } - public A removeFromTopology(java.util.Map map) { - if(this.topology == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.topology != null){this.topology.remove(key);}}} return (A)this; + + public A removeFromTopology(java.util.Map map) { + if (this.topology == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.topology != null) { + this.topology.remove(key); + } + } + } + return (A) this; } - public java.util.Map getTopology() { + + public java.util.Map getTopology() { return this.topology; } - public A withTopology(java.util.Map topology) { - if (topology == null) { this.topology = null;} else {this.topology = new java.util.LinkedHashMap(topology);} return (A) this; + + public A withTopology(java.util.Map topology) { + if (topology == null) { + this.topology = null; + } else { + this.topology = new java.util.LinkedHashMap(topology); + } + return (A) this; } + public java.lang.Boolean hasTopology() { return this.topology != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1EndpointFluentImpl that = (V1beta1EndpointFluentImpl) o; - if (addresses != null ? !addresses.equals(that.addresses) :that.addresses != null) return false; - if (conditions != null ? !conditions.equals(that.conditions) :that.conditions != null) return false; - if (hints != null ? !hints.equals(that.hints) :that.hints != null) return false; - if (hostname != null ? !hostname.equals(that.hostname) :that.hostname != null) return false; - if (nodeName != null ? !nodeName.equals(that.nodeName) :that.nodeName != null) return false; - if (targetRef != null ? !targetRef.equals(that.targetRef) :that.targetRef != null) return false; - if (topology != null ? !topology.equals(that.topology) :that.topology != null) return false; + if (addresses != null ? !addresses.equals(that.addresses) : that.addresses != null) + return false; + if (conditions != null ? !conditions.equals(that.conditions) : that.conditions != null) + return false; + if (hints != null ? !hints.equals(that.hints) : that.hints != null) return false; + if (hostname != null ? !hostname.equals(that.hostname) : that.hostname != null) return false; + if (nodeName != null ? !nodeName.equals(that.nodeName) : that.nodeName != null) return false; + if (targetRef != null ? !targetRef.equals(that.targetRef) : that.targetRef != null) + return false; + if (topology != null ? !topology.equals(that.topology) : that.topology != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(addresses, conditions, hints, hostname, nodeName, targetRef, topology, super.hashCode()); + return java.util.Objects.hash( + addresses, conditions, hints, hostname, nodeName, targetRef, topology, super.hashCode()); } - public class ConditionsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1EndpointConditionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1beta1EndpointFluent.ConditionsNested, + io.kubernetes.client.fluent.Nested { ConditionsNestedImpl(io.kubernetes.client.openapi.models.V1beta1EndpointConditions item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1EndpointConditionsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointConditionsBuilder(this, item); } + ConditionsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta1EndpointConditionsBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1EndpointConditionsBuilder builder; + public N and() { return (N) V1beta1EndpointFluentImpl.this.withConditions(builder.build()); } + public N endConditions() { return and(); } - } - public class HintsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested,io.kubernetes.client.fluent.Nested{ + + public class HintsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested> + implements io.kubernetes.client.openapi.models.V1beta1EndpointFluent.HintsNested, + io.kubernetes.client.fluent.Nested { HintsNestedImpl(io.kubernetes.client.openapi.models.V1beta1EndpointHints item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1EndpointHintsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointHintsBuilder(this, item); } + HintsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta1EndpointHintsBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1EndpointHintsBuilder builder; + public N and() { return (N) V1beta1EndpointFluentImpl.this.withHints(builder.build()); } + public N endHints() { return and(); } - } - public class TargetRefNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested,io.kubernetes.client.fluent.Nested{ + + public class TargetRefNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested> + implements io.kubernetes.client.openapi.models.V1beta1EndpointFluent.TargetRefNested, + io.kubernetes.client.fluent.Nested { TargetRefNestedImpl(io.kubernetes.client.openapi.models.V1ObjectReference item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + TargetRefNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; + public N and() { return (N) V1beta1EndpointFluentImpl.this.withTargetRef(builder.build()); } + public N endTargetRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointHintsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointHintsBuilder.java index 10de08ff0e..6540c74fd0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointHintsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointHintsBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1EndpointHintsBuilder extends io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1EndpointHintsBuilder + extends io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointHintsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1EndpointHints, + io.kubernetes.client.openapi.models.V1beta1EndpointHintsBuilder> { public V1beta1EndpointHintsBuilder() { this(false); } + public V1beta1EndpointHintsBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1EndpointHints(), validationEnabled); } - public V1beta1EndpointHintsBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent fluent) { + + public V1beta1EndpointHintsBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent fluent) { this(fluent, false); } - public V1beta1EndpointHintsBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1EndpointHintsBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1EndpointHints(), validationEnabled); } - public V1beta1EndpointHintsBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent fluent,io.kubernetes.client.openapi.models.V1beta1EndpointHints instance) { + + public V1beta1EndpointHintsBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EndpointHints instance) { this(fluent, instance, false); } - public V1beta1EndpointHintsBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent fluent,io.kubernetes.client.openapi.models.V1beta1EndpointHints instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1EndpointHintsBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EndpointHints instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withForZones(instance.getForZones()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1EndpointHintsBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointHints instance) { - this(instance,false); + + public V1beta1EndpointHintsBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointHints instance) { + this(instance, false); } - public V1beta1EndpointHintsBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointHints instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1EndpointHintsBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointHints instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withForZones(instance.getForZones()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1EndpointHints build() { V1beta1EndpointHints buildable = new V1beta1EndpointHints(); buildable.setForZones(fluent.getForZones()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1EndpointHintsBuilder that = (V1beta1EndpointHintsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointHintsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointHintsFluent.java index e5af63d803..a1185ab2b2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointHintsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointHintsFluent.java @@ -1,57 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1EndpointHintsFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToForZones(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1ForZone item); - public A setToForZones(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1ForZone item); +/** Generated */ +public interface V1beta1EndpointHintsFluent< + A extends io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToForZones( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1ForZone item); + + public A setToForZones( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1ForZone item); + public A addToForZones(io.kubernetes.client.openapi.models.V1beta1ForZone... items); - public A addAllToForZones(java.util.Collection items); + + public A addAllToForZones( + java.util.Collection items); + public A removeFromForZones(io.kubernetes.client.openapi.models.V1beta1ForZone... items); - public A removeAllFromForZones(java.util.Collection items); - public A removeMatchingFromForZones(java.util.function.Predicate predicate); - + + public A removeAllFromForZones( + java.util.Collection items); + + public A removeMatchingFromForZones( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildForZones instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getForZones(); + public java.util.List buildForZones(); + public io.kubernetes.client.openapi.models.V1beta1ForZone buildForZone(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1ForZone buildFirstForZone(); + public io.kubernetes.client.openapi.models.V1beta1ForZone buildLastForZone(); - public io.kubernetes.client.openapi.models.V1beta1ForZone buildMatchingForZone(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingForZone(java.util.function.Predicate predicate); - public A withForZones(java.util.List forZones); + + public io.kubernetes.client.openapi.models.V1beta1ForZone buildMatchingForZone( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingForZone( + java.util.function.Predicate + predicate); + + public A withForZones( + java.util.List forZones); + public A withForZones(io.kubernetes.client.openapi.models.V1beta1ForZone... forZones); + public java.lang.Boolean hasForZones(); - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested addNewForZone(); - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested addNewForZoneLike(io.kubernetes.client.openapi.models.V1beta1ForZone item); - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested setNewForZoneLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1ForZone item); - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested editForZone(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested editFirstForZone(); - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested editLastForZone(); - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested editMatchingForZone(java.util.function.Predicate predicate); - public interface ForZonesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1ForZoneFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + addNewForZone(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + addNewForZoneLike(io.kubernetes.client.openapi.models.V1beta1ForZone item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + setNewForZoneLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1ForZone item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + editForZone(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + editFirstForZone(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + editLastForZone(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + editMatchingForZone( + java.util.function.Predicate + predicate); + + public interface ForZonesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1ForZoneFluent< + io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested> { public N and(); + public N endForZone(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointHintsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointHintsFluentImpl.java index 490be43588..a7abd40142 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointHintsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointHintsFluentImpl.java @@ -1,57 +1,130 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1beta1EndpointHintsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent{ - public V1beta1EndpointHintsFluentImpl() { - } - public V1beta1EndpointHintsFluentImpl(io.kubernetes.client.openapi.models.V1beta1EndpointHints instance) { - this.withForZones(instance.getForZones()); +/** Generated */ +public class V1beta1EndpointHintsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent { + public V1beta1EndpointHintsFluentImpl() {} + public V1beta1EndpointHintsFluentImpl( + io.kubernetes.client.openapi.models.V1beta1EndpointHints instance) { + this.withForZones(instance.getForZones()); } + private java.util.ArrayList forZones; - public A addToForZones(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1ForZone item) { - if (this.forZones == null) {this.forZones = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder = new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(item);_visitables.get("forZones").add(index >= 0 ? index : _visitables.get("forZones").size(), builder);this.forZones.add(index >= 0 ? index : forZones.size(), builder); return (A)this; + + public A addToForZones( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1ForZone item) { + if (this.forZones == null) { + this.forZones = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(item); + _visitables + .get("forZones") + .add(index >= 0 ? index : _visitables.get("forZones").size(), builder); + this.forZones.add(index >= 0 ? index : forZones.size(), builder); + return (A) this; } - public A setToForZones(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1ForZone item) { - if (this.forZones == null) {this.forZones = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder = new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(item); - if (index < 0 || index >= _visitables.get("forZones").size()) { _visitables.get("forZones").add(builder); } else { _visitables.get("forZones").set(index, builder);} - if (index < 0 || index >= forZones.size()) { forZones.add(builder); } else { forZones.set(index, builder);} - return (A)this; + + public A setToForZones( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1ForZone item) { + if (this.forZones == null) { + this.forZones = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(item); + if (index < 0 || index >= _visitables.get("forZones").size()) { + _visitables.get("forZones").add(builder); + } else { + _visitables.get("forZones").set(index, builder); + } + if (index < 0 || index >= forZones.size()) { + forZones.add(builder); + } else { + forZones.set(index, builder); + } + return (A) this; } + public A addToForZones(io.kubernetes.client.openapi.models.V1beta1ForZone... items) { - if (this.forZones == null) {this.forZones = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1ForZone item : items) {io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder = new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(item);_visitables.get("forZones").add(builder);this.forZones.add(builder);} return (A)this; + if (this.forZones == null) { + this.forZones = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1ForZone item : items) { + io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(item); + _visitables.get("forZones").add(builder); + this.forZones.add(builder); + } + return (A) this; } - public A addAllToForZones(java.util.Collection items) { - if (this.forZones == null) {this.forZones = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1ForZone item : items) {io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder = new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(item);_visitables.get("forZones").add(builder);this.forZones.add(builder);} return (A)this; + + public A addAllToForZones( + java.util.Collection items) { + if (this.forZones == null) { + this.forZones = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1ForZone item : items) { + io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(item); + _visitables.get("forZones").add(builder); + this.forZones.add(builder); + } + return (A) this; } + public A removeFromForZones(io.kubernetes.client.openapi.models.V1beta1ForZone... items) { - for (io.kubernetes.client.openapi.models.V1beta1ForZone item : items) {io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder = new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(item);_visitables.get("forZones").remove(builder);if (this.forZones != null) {this.forZones.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1ForZone item : items) { + io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(item); + _visitables.get("forZones").remove(builder); + if (this.forZones != null) { + this.forZones.remove(builder); + } + } + return (A) this; } - public A removeAllFromForZones(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1ForZone item : items) {io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder = new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(item);_visitables.get("forZones").remove(builder);if (this.forZones != null) {this.forZones.remove(builder);}} return (A)this; + + public A removeAllFromForZones( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1ForZone item : items) { + io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(item); + _visitables.get("forZones").remove(builder); + if (this.forZones != null) { + this.forZones.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromForZones(java.util.function.Predicate predicate) { + + public A removeMatchingFromForZones( + java.util.function.Predicate + predicate) { if (forZones == null) return (A) this; - final Iterator each = forZones.iterator(); + final Iterator each = + forZones.iterator(); final List visitables = _visitables.get("forZones"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder = each.next(); @@ -60,104 +133,181 @@ public A removeMatchingFromForZones(java.util.function.Predicate getForZones() { return forZones != null ? build(forZones) : null; } + public java.util.List buildForZones() { return forZones != null ? build(forZones) : null; } + public io.kubernetes.client.openapi.models.V1beta1ForZone buildForZone(java.lang.Integer index) { return this.forZones.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1ForZone buildFirstForZone() { return this.forZones.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1ForZone buildLastForZone() { return this.forZones.get(forZones.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1ForZone buildMatchingForZone(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder item: forZones) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1ForZone buildMatchingForZone( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder item : forZones) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingForZone(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder item: forZones) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingForZone( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder item : forZones) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withForZones(java.util.List forZones) { - if (this.forZones != null) { _visitables.get("forZones").removeAll(this.forZones);} - if (forZones != null) {this.forZones = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1ForZone item : forZones){this.addToForZones(item);}} else { this.forZones = null;} return (A) this; + + public A withForZones( + java.util.List forZones) { + if (this.forZones != null) { + _visitables.get("forZones").removeAll(this.forZones); + } + if (forZones != null) { + this.forZones = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1ForZone item : forZones) { + this.addToForZones(item); + } + } else { + this.forZones = null; + } + return (A) this; } + public A withForZones(io.kubernetes.client.openapi.models.V1beta1ForZone... forZones) { - if (this.forZones != null) {this.forZones.clear();} - if (forZones != null) {for (io.kubernetes.client.openapi.models.V1beta1ForZone item :forZones){ this.addToForZones(item);}} return (A) this; + if (this.forZones != null) { + this.forZones.clear(); + } + if (forZones != null) { + for (io.kubernetes.client.openapi.models.V1beta1ForZone item : forZones) { + this.addToForZones(item); + } + } + return (A) this; } + public java.lang.Boolean hasForZones() { return forZones != null && !forZones.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested addNewForZone() { - return new io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluentImpl.ForZonesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + addNewForZone() { + return new io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluentImpl + .ForZonesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested addNewForZoneLike(io.kubernetes.client.openapi.models.V1beta1ForZone item) { - return new io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluentImpl.ForZonesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + addNewForZoneLike(io.kubernetes.client.openapi.models.V1beta1ForZone item) { + return new io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluentImpl + .ForZonesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested setNewForZoneLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1ForZone item) { - return new io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluentImpl.ForZonesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + setNewForZoneLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1ForZone item) { + return new io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluentImpl + .ForZonesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested editForZone(java.lang.Integer index) { - if (forZones.size() <= index) throw new RuntimeException("Can't edit forZones. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + editForZone(java.lang.Integer index) { + if (forZones.size() <= index) + throw new RuntimeException("Can't edit forZones. Index exceeds size."); return setNewForZoneLike(index, buildForZone(index)); } - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested editFirstForZone() { - if (forZones.size() == 0) throw new RuntimeException("Can't edit first forZones. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + editFirstForZone() { + if (forZones.size() == 0) + throw new RuntimeException("Can't edit first forZones. The list is empty."); return setNewForZoneLike(0, buildForZone(0)); } - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested editLastForZone() { + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + editLastForZone() { int index = forZones.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last forZones. The list is empty."); return setNewForZoneLike(index, buildForZone(index)); } - public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested editMatchingForZone(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested + editMatchingForZone( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta1ForZoneFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested,io.kubernetes.client.fluent.Nested{ - ForZonesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1ForZone item) { + + public class ForZonesNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1ForZoneFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested> + implements io.kubernetes.client.openapi.models.V1beta1EndpointHintsFluent.ForZonesNested, + io.kubernetes.client.fluent.Nested { + ForZonesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1ForZone item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(this, item); } + ForZonesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1EndpointHintsFluentImpl.this.setToForZones(index,builder.build()); + return (N) V1beta1EndpointHintsFluentImpl.this.setToForZones(index, builder.build()); } + public N endForZone() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointPortBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointPortBuilder.java index 2ac4e8856d..3e39676921 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointPortBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointPortBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1EndpointPortBuilder extends io.kubernetes.client.openapi.models.V1beta1EndpointPortFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1EndpointPortBuilder + extends io.kubernetes.client.openapi.models.V1beta1EndpointPortFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1EndpointPort, + io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder> { public V1beta1EndpointPortBuilder() { this(false); } + public V1beta1EndpointPortBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1EndpointPort(), validationEnabled); } - public V1beta1EndpointPortBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent fluent) { + + public V1beta1EndpointPortBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent fluent) { this(fluent, false); } - public V1beta1EndpointPortBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1EndpointPortBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1EndpointPort(), validationEnabled); } - public V1beta1EndpointPortBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent fluent,io.kubernetes.client.openapi.models.V1beta1EndpointPort instance) { + + public V1beta1EndpointPortBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EndpointPort instance) { this(fluent, instance, false); } - public V1beta1EndpointPortBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent fluent,io.kubernetes.client.openapi.models.V1beta1EndpointPort instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1EndpointPortBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EndpointPort instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAppProtocol(instance.getAppProtocol()); fluent.withName(instance.getName()); @@ -29,13 +56,18 @@ public V1beta1EndpointPortBuilder(io.kubernetes.client.openapi.models.V1beta1End fluent.withProtocol(instance.getProtocol()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1EndpointPortBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointPort instance) { - this(instance,false); + + public V1beta1EndpointPortBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointPort instance) { + this(instance, false); } - public V1beta1EndpointPortBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointPort instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1EndpointPortBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointPort instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAppProtocol(instance.getAppProtocol()); this.withName(instance.getName()); @@ -44,10 +76,12 @@ public V1beta1EndpointPortBuilder(io.kubernetes.client.openapi.models.V1beta1End this.withProtocol(instance.getProtocol()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1EndpointPort build() { V1beta1EndpointPort buildable = new V1beta1EndpointPort(); buildable.setAppProtocol(fluent.getAppProtocol()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1beta1EndpointPort build() { buildable.setProtocol(fluent.getProtocol()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1EndpointPortBuilder that = (V1beta1EndpointPortBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointPortFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointPortFluent.java index 3c6301e904..9adbb0c850 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointPortFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointPortFluent.java @@ -1,45 +1,54 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1EndpointPortFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1EndpointPortFluent< + A extends io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getAppProtocol(); + public A withAppProtocol(java.lang.String appProtocol); + public java.lang.Boolean hasAppProtocol(); - - /** - * Method is deprecated. use withAppProtocol instead. - */ + + /** Method is deprecated. use withAppProtocol instead. */ @java.lang.Deprecated public A withNewAppProtocol(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Integer getPort(); + public A withPort(java.lang.Integer port); + public java.lang.Boolean hasPort(); + public java.lang.String getProtocol(); + public A withProtocol(java.lang.String protocol); + public java.lang.Boolean hasProtocol(); - - /** - * Method is deprecated. use withProtocol instead. - */ + + /** Method is deprecated. use withProtocol instead. */ @java.lang.Deprecated public A withNewProtocol(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointPortFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointPortFluentImpl.java index a40a4c8593..e5c06bb1f9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointPortFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointPortFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1beta1EndpointPortFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent { + public V1beta1EndpointPortFluentImpl() {} - /** - * Generated - */ -public class V1beta1EndpointPortFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent{ - public V1beta1EndpointPortFluentImpl() { - } - public V1beta1EndpointPortFluentImpl(io.kubernetes.client.openapi.models.V1beta1EndpointPort instance) { + public V1beta1EndpointPortFluentImpl( + io.kubernetes.client.openapi.models.V1beta1EndpointPort instance) { this.withAppProtocol(instance.getAppProtocol()); this.withName(instance.getName()); @@ -21,84 +28,96 @@ public V1beta1EndpointPortFluentImpl(io.kubernetes.client.openapi.models.V1beta1 this.withPort(instance.getPort()); this.withProtocol(instance.getProtocol()); - } + private java.lang.String appProtocol; private java.lang.String name; private java.lang.Integer port; private java.lang.String protocol; + public java.lang.String getAppProtocol() { return this.appProtocol; } + public A withAppProtocol(java.lang.String appProtocol) { - this.appProtocol=appProtocol; return (A) this; + this.appProtocol = appProtocol; + return (A) this; } + public java.lang.Boolean hasAppProtocol() { return this.appProtocol != null; } - - /** - * Method is deprecated. use withAppProtocol instead. - */ + + /** Method is deprecated. use withAppProtocol instead. */ @java.lang.Deprecated public A withNewAppProtocol(java.lang.String original) { - return (A)withAppProtocol(new String(original)); + return (A) withAppProtocol(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Integer getPort() { return this.port; } + public A withPort(java.lang.Integer port) { - this.port=port; return (A) this; + this.port = port; + return (A) this; } + public java.lang.Boolean hasPort() { return this.port != null; } + public java.lang.String getProtocol() { return this.protocol; } + public A withProtocol(java.lang.String protocol) { - this.protocol=protocol; return (A) this; + this.protocol = protocol; + return (A) this; } + public java.lang.Boolean hasProtocol() { return this.protocol != null; } - - /** - * Method is deprecated. use withProtocol instead. - */ + + /** Method is deprecated. use withProtocol instead. */ @java.lang.Deprecated public A withNewProtocol(java.lang.String original) { - return (A)withProtocol(new String(original)); + return (A) withProtocol(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1EndpointPortFluentImpl that = (V1beta1EndpointPortFluentImpl) o; - if (appProtocol != null ? !appProtocol.equals(that.appProtocol) :that.appProtocol != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (port != null ? !port.equals(that.port) :that.port != null) return false; - if (protocol != null ? !protocol.equals(that.protocol) :that.protocol != null) return false; + if (appProtocol != null ? !appProtocol.equals(that.appProtocol) : that.appProtocol != null) + return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (port != null ? !port.equals(that.port) : that.port != null) return false; + if (protocol != null ? !protocol.equals(that.protocol) : that.protocol != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(appProtocol, name, port, protocol, super.hashCode()); + return java.util.Objects.hash(appProtocol, name, port, protocol, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceBuilder.java index b8fc368ef1..3a7ad646e0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1EndpointSliceBuilder extends io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1EndpointSliceBuilder + extends io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1EndpointSlice, + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder> { public V1beta1EndpointSliceBuilder() { this(false); } + public V1beta1EndpointSliceBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1EndpointSlice(), validationEnabled); } - public V1beta1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent fluent) { + + public V1beta1EndpointSliceBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent fluent) { this(fluent, false); } - public V1beta1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1EndpointSliceBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1EndpointSlice(), validationEnabled); } - public V1beta1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent fluent,io.kubernetes.client.openapi.models.V1beta1EndpointSlice instance) { + + public V1beta1EndpointSliceBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EndpointSlice instance) { this(fluent, instance, false); } - public V1beta1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent fluent,io.kubernetes.client.openapi.models.V1beta1EndpointSlice instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1EndpointSliceBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EndpointSlice instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAddressType(instance.getAddressType()); fluent.withApiVersion(instance.getApiVersion()); @@ -33,13 +60,18 @@ public V1beta1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1beta1En fluent.withPorts(instance.getPorts()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointSlice instance) { - this(instance,false); + + public V1beta1EndpointSliceBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointSlice instance) { + this(instance, false); } - public V1beta1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointSlice instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1EndpointSliceBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointSlice instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAddressType(instance.getAddressType()); this.withApiVersion(instance.getApiVersion()); @@ -52,10 +84,12 @@ public V1beta1EndpointSliceBuilder(io.kubernetes.client.openapi.models.V1beta1En this.withPorts(instance.getPorts()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1EndpointSlice build() { V1beta1EndpointSlice buildable = new V1beta1EndpointSlice(); buildable.setAddressType(fluent.getAddressType()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1beta1EndpointSlice build() { buildable.setPorts(fluent.getPorts()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1EndpointSliceBuilder that = (V1beta1EndpointSliceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceFluent.java index b61be40e88..d578956372 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceFluent.java @@ -1,139 +1,253 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1beta1EndpointSliceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1EndpointSliceFluent< + A extends io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getAddressType(); + public A withAddressType(java.lang.String addressType); + public java.lang.Boolean hasAddressType(); - - /** - * Method is deprecated. use withAddressType instead. - */ + + /** Method is deprecated. use withAddressType instead. */ @java.lang.Deprecated public A withNewAddressType(java.lang.String original); + public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToEndpoints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Endpoint item); - public A setToEndpoints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Endpoint item); + + public A addToEndpoints( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Endpoint item); + + public A setToEndpoints( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Endpoint item); + public A addToEndpoints(io.kubernetes.client.openapi.models.V1beta1Endpoint... items); - public A addAllToEndpoints(java.util.Collection items); + + public A addAllToEndpoints( + java.util.Collection items); + public A removeFromEndpoints(io.kubernetes.client.openapi.models.V1beta1Endpoint... items); - public A removeAllFromEndpoints(java.util.Collection items); - public A removeMatchingFromEndpoints(java.util.function.Predicate predicate); - + + public A removeAllFromEndpoints( + java.util.Collection items); + + public A removeMatchingFromEndpoints( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildEndpoints instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getEndpoints(); + public java.util.List buildEndpoints(); + public io.kubernetes.client.openapi.models.V1beta1Endpoint buildEndpoint(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1Endpoint buildFirstEndpoint(); + public io.kubernetes.client.openapi.models.V1beta1Endpoint buildLastEndpoint(); - public io.kubernetes.client.openapi.models.V1beta1Endpoint buildMatchingEndpoint(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingEndpoint(java.util.function.Predicate predicate); - public A withEndpoints(java.util.List endpoints); + + public io.kubernetes.client.openapi.models.V1beta1Endpoint buildMatchingEndpoint( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingEndpoint( + java.util.function.Predicate + predicate); + + public A withEndpoints( + java.util.List endpoints); + public A withEndpoints(io.kubernetes.client.openapi.models.V1beta1Endpoint... endpoints); + public java.lang.Boolean hasEndpoints(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested addNewEndpoint(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested addNewEndpointLike(io.kubernetes.client.openapi.models.V1beta1Endpoint item); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested setNewEndpointLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Endpoint item); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested editEndpoint(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested editFirstEndpoint(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested editLastEndpoint(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested editMatchingEndpoint(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + addNewEndpoint(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + addNewEndpointLike(io.kubernetes.client.openapi.models.V1beta1Endpoint item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + setNewEndpointLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Endpoint item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + editEndpoint(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + editFirstEndpoint(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + editLastEndpoint(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + editMatchingEndpoint( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointPort item); - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointPort item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointPort item); + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointPort item); + public A addToPorts(io.kubernetes.client.openapi.models.V1beta1EndpointPort... items); - public A addAllToPorts(java.util.Collection items); + + public A addAllToPorts( + java.util.Collection items); + public A removeFromPorts(io.kubernetes.client.openapi.models.V1beta1EndpointPort... items); - public A removeAllFromPorts(java.util.Collection items); - public A removeMatchingFromPorts(java.util.function.Predicate predicate); - + + public A removeAllFromPorts( + java.util.Collection items); + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildPorts instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getPorts(); + public java.util.List buildPorts(); + public io.kubernetes.client.openapi.models.V1beta1EndpointPort buildPort(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1EndpointPort buildFirstPort(); + public io.kubernetes.client.openapi.models.V1beta1EndpointPort buildLastPort(); - public io.kubernetes.client.openapi.models.V1beta1EndpointPort buildMatchingPort(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1EndpointPort buildMatchingPort( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate); + public A withPorts(java.util.List ports); + public A withPorts(io.kubernetes.client.openapi.models.V1beta1EndpointPort... ports); + public java.lang.Boolean hasPorts(); + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested addNewPort(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1beta1EndpointPort item); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointPort item); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested editPort(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested editFirstPort(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested editLastPort(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate); - public interface EndpointsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1EndpointFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested + addNewPortLike(io.kubernetes.client.openapi.models.V1beta1EndpointPort item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested + setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointPort item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested editPort( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested + editFirstPort(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested + editLastPort(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested + editMatchingPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder> + predicate); + + public interface EndpointsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1EndpointFluent< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested> { public N and(); + public N endEndpoint(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface PortsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent>{ + + public interface PortsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1EndpointPortFluent< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested> { public N and(); + public N endPort(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceFluentImpl.java index 22707bebc5..2d035ba004 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta1EndpointSliceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent{ - public V1beta1EndpointSliceFluentImpl() { - } - public V1beta1EndpointSliceFluentImpl(io.kubernetes.client.openapi.models.V1beta1EndpointSlice instance) { + +/** Generated */ +public class V1beta1EndpointSliceFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent { + public V1beta1EndpointSliceFluentImpl() {} + + public V1beta1EndpointSliceFluentImpl( + io.kubernetes.client.openapi.models.V1beta1EndpointSlice instance) { this.withAddressType(instance.getAddressType()); this.withApiVersion(instance.getApiVersion()); @@ -32,76 +35,149 @@ public V1beta1EndpointSliceFluentImpl(io.kubernetes.client.openapi.models.V1beta this.withMetadata(instance.getMetadata()); this.withPorts(instance.getPorts()); - } + private java.lang.String addressType; private java.lang.String apiVersion; private java.util.ArrayList endpoints; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private java.util.ArrayList ports; + public java.lang.String getAddressType() { return this.addressType; } + public A withAddressType(java.lang.String addressType) { - this.addressType=addressType; return (A) this; + this.addressType = addressType; + return (A) this; } + public java.lang.Boolean hasAddressType() { return this.addressType != null; } - - /** - * Method is deprecated. use withAddressType instead. - */ + + /** Method is deprecated. use withAddressType instead. */ @java.lang.Deprecated public A withNewAddressType(java.lang.String original) { - return (A)withAddressType(new String(original)); + return (A) withAddressType(new String(original)); } + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToEndpoints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Endpoint item) { - if (this.endpoints == null) {this.endpoints = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(item);_visitables.get("endpoints").add(index >= 0 ? index : _visitables.get("endpoints").size(), builder);this.endpoints.add(index >= 0 ? index : endpoints.size(), builder); return (A)this; + + public A addToEndpoints( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Endpoint item) { + if (this.endpoints == null) { + this.endpoints = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(item); + _visitables + .get("endpoints") + .add(index >= 0 ? index : _visitables.get("endpoints").size(), builder); + this.endpoints.add(index >= 0 ? index : endpoints.size(), builder); + return (A) this; } - public A setToEndpoints(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Endpoint item) { - if (this.endpoints == null) {this.endpoints = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(item); - if (index < 0 || index >= _visitables.get("endpoints").size()) { _visitables.get("endpoints").add(builder); } else { _visitables.get("endpoints").set(index, builder);} - if (index < 0 || index >= endpoints.size()) { endpoints.add(builder); } else { endpoints.set(index, builder);} - return (A)this; + + public A setToEndpoints( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Endpoint item) { + if (this.endpoints == null) { + this.endpoints = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(item); + if (index < 0 || index >= _visitables.get("endpoints").size()) { + _visitables.get("endpoints").add(builder); + } else { + _visitables.get("endpoints").set(index, builder); + } + if (index < 0 || index >= endpoints.size()) { + endpoints.add(builder); + } else { + endpoints.set(index, builder); + } + return (A) this; } + public A addToEndpoints(io.kubernetes.client.openapi.models.V1beta1Endpoint... items) { - if (this.endpoints == null) {this.endpoints = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1Endpoint item : items) {io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(item);_visitables.get("endpoints").add(builder);this.endpoints.add(builder);} return (A)this; + if (this.endpoints == null) { + this.endpoints = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1Endpoint item : items) { + io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(item); + _visitables.get("endpoints").add(builder); + this.endpoints.add(builder); + } + return (A) this; } - public A addAllToEndpoints(java.util.Collection items) { - if (this.endpoints == null) {this.endpoints = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1Endpoint item : items) {io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(item);_visitables.get("endpoints").add(builder);this.endpoints.add(builder);} return (A)this; + + public A addAllToEndpoints( + java.util.Collection items) { + if (this.endpoints == null) { + this.endpoints = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1Endpoint item : items) { + io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(item); + _visitables.get("endpoints").add(builder); + this.endpoints.add(builder); + } + return (A) this; } + public A removeFromEndpoints(io.kubernetes.client.openapi.models.V1beta1Endpoint... items) { - for (io.kubernetes.client.openapi.models.V1beta1Endpoint item : items) {io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(item);_visitables.get("endpoints").remove(builder);if (this.endpoints != null) {this.endpoints.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1Endpoint item : items) { + io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(item); + _visitables.get("endpoints").remove(builder); + if (this.endpoints != null) { + this.endpoints.remove(builder); + } + } + return (A) this; } - public A removeAllFromEndpoints(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1Endpoint item : items) {io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(item);_visitables.get("endpoints").remove(builder);if (this.endpoints != null) {this.endpoints.remove(builder);}} return (A)this; + + public A removeAllFromEndpoints( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1Endpoint item : items) { + io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(item); + _visitables.get("endpoints").remove(builder); + if (this.endpoints != null) { + this.endpoints.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromEndpoints(java.util.function.Predicate predicate) { + + public A removeMatchingFromEndpoints( + java.util.function.Predicate + predicate) { if (endpoints == null) return (A) this; - final Iterator each = endpoints.iterator(); + final Iterator each = + endpoints.iterator(); final List visitables = _visitables.get("endpoints"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder = each.next(); @@ -110,155 +186,315 @@ public A removeMatchingFromEndpoints(java.util.function.Predicate getEndpoints() { return endpoints != null ? build(endpoints) : null; } + public java.util.List buildEndpoints() { return endpoints != null ? build(endpoints) : null; } - public io.kubernetes.client.openapi.models.V1beta1Endpoint buildEndpoint(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1Endpoint buildEndpoint( + java.lang.Integer index) { return this.endpoints.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1Endpoint buildFirstEndpoint() { return this.endpoints.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1Endpoint buildLastEndpoint() { return this.endpoints.get(endpoints.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1Endpoint buildMatchingEndpoint(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1EndpointBuilder item: endpoints) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1Endpoint buildMatchingEndpoint( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1EndpointBuilder item : endpoints) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingEndpoint(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1EndpointBuilder item: endpoints) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingEndpoint( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1EndpointBuilder item : endpoints) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withEndpoints(java.util.List endpoints) { - if (this.endpoints != null) { _visitables.get("endpoints").removeAll(this.endpoints);} - if (endpoints != null) {this.endpoints = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1Endpoint item : endpoints){this.addToEndpoints(item);}} else { this.endpoints = null;} return (A) this; + + public A withEndpoints( + java.util.List endpoints) { + if (this.endpoints != null) { + _visitables.get("endpoints").removeAll(this.endpoints); + } + if (endpoints != null) { + this.endpoints = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1Endpoint item : endpoints) { + this.addToEndpoints(item); + } + } else { + this.endpoints = null; + } + return (A) this; } + public A withEndpoints(io.kubernetes.client.openapi.models.V1beta1Endpoint... endpoints) { - if (this.endpoints != null) {this.endpoints.clear();} - if (endpoints != null) {for (io.kubernetes.client.openapi.models.V1beta1Endpoint item :endpoints){ this.addToEndpoints(item);}} return (A) this; + if (this.endpoints != null) { + this.endpoints.clear(); + } + if (endpoints != null) { + for (io.kubernetes.client.openapi.models.V1beta1Endpoint item : endpoints) { + this.addToEndpoints(item); + } + } + return (A) this; } + public java.lang.Boolean hasEndpoints() { return endpoints != null && !endpoints.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested addNewEndpoint() { - return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl.EndpointsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + addNewEndpoint() { + return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl + .EndpointsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested addNewEndpointLike(io.kubernetes.client.openapi.models.V1beta1Endpoint item) { - return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl.EndpointsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + addNewEndpointLike(io.kubernetes.client.openapi.models.V1beta1Endpoint item) { + return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl + .EndpointsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested setNewEndpointLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Endpoint item) { - return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl.EndpointsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + setNewEndpointLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Endpoint item) { + return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl + .EndpointsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested editEndpoint(java.lang.Integer index) { - if (endpoints.size() <= index) throw new RuntimeException("Can't edit endpoints. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + editEndpoint(java.lang.Integer index) { + if (endpoints.size() <= index) + throw new RuntimeException("Can't edit endpoints. Index exceeds size."); return setNewEndpointLike(index, buildEndpoint(index)); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested editFirstEndpoint() { - if (endpoints.size() == 0) throw new RuntimeException("Can't edit first endpoints. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + editFirstEndpoint() { + if (endpoints.size() == 0) + throw new RuntimeException("Can't edit first endpoints. The list is empty."); return setNewEndpointLike(0, buildEndpoint(0)); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested editLastEndpoint() { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + editLastEndpoint() { int index = endpoints.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last endpoints. The list is empty."); return setNewEndpointLike(index, buildEndpoint(index)); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested editMatchingEndpoint(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested + editMatchingEndpoint( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - public A addToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointPort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(item);_visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder);this.ports.add(index >= 0 ? index : ports.size(), builder); return (A)this; + + public A addToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(item); + _visitables.get("ports").add(index >= 0 ? index : _visitables.get("ports").size(), builder); + this.ports.add(index >= 0 ? index : ports.size(), builder); + return (A) this; } - public A setToPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointPort item) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(item); - if (index < 0 || index >= _visitables.get("ports").size()) { _visitables.get("ports").add(builder); } else { _visitables.get("ports").set(index, builder);} - if (index < 0 || index >= ports.size()) { ports.add(builder); } else { ports.set(index, builder);} - return (A)this; + + public A setToPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointPort item) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(item); + if (index < 0 || index >= _visitables.get("ports").size()) { + _visitables.get("ports").add(builder); + } else { + _visitables.get("ports").set(index, builder); + } + if (index < 0 || index >= ports.size()) { + ports.add(builder); + } else { + ports.set(index, builder); + } + return (A) this; } + public A addToPorts(io.kubernetes.client.openapi.models.V1beta1EndpointPort... items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1EndpointPort item : items) {io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1EndpointPort item : items) { + io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } - public A addAllToPorts(java.util.Collection items) { - if (this.ports == null) {this.ports = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1EndpointPort item : items) {io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(item);_visitables.get("ports").add(builder);this.ports.add(builder);} return (A)this; + + public A addAllToPorts( + java.util.Collection items) { + if (this.ports == null) { + this.ports = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1EndpointPort item : items) { + io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(item); + _visitables.get("ports").add(builder); + this.ports.add(builder); + } + return (A) this; } + public A removeFromPorts(io.kubernetes.client.openapi.models.V1beta1EndpointPort... items) { - for (io.kubernetes.client.openapi.models.V1beta1EndpointPort item : items) {io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1EndpointPort item : items) { + io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeAllFromPorts(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1EndpointPort item : items) {io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(item);_visitables.get("ports").remove(builder);if (this.ports != null) {this.ports.remove(builder);}} return (A)this; + + public A removeAllFromPorts( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1EndpointPort item : items) { + io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(item); + _visitables.get("ports").remove(builder); + if (this.ports != null) { + this.ports.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPorts(java.util.function.Predicate predicate) { + + public A removeMatchingFromPorts( + java.util.function.Predicate + predicate) { if (ports == null) return (A) this; - final Iterator each = ports.iterator(); + final Iterator each = + ports.iterator(); final List visitables = _visitables.get("ports"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder = each.next(); @@ -267,144 +503,241 @@ public A removeMatchingFromPorts(java.util.function.Predicate getPorts() { return ports != null ? build(ports) : null; } + public java.util.List buildPorts() { return ports != null ? build(ports) : null; } - public io.kubernetes.client.openapi.models.V1beta1EndpointPort buildPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1EndpointPort buildPort( + java.lang.Integer index) { return this.ports.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1EndpointPort buildFirstPort() { return this.ports.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1EndpointPort buildLastPort() { return this.ports.get(ports.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointPort buildMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder item: ports) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1EndpointPort buildMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder item : ports) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder item: ports) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder item : ports) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withPorts(java.util.List ports) { - if (this.ports != null) { _visitables.get("ports").removeAll(this.ports);} - if (ports != null) {this.ports = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1EndpointPort item : ports){this.addToPorts(item);}} else { this.ports = null;} return (A) this; + + public A withPorts( + java.util.List ports) { + if (this.ports != null) { + _visitables.get("ports").removeAll(this.ports); + } + if (ports != null) { + this.ports = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1EndpointPort item : ports) { + this.addToPorts(item); + } + } else { + this.ports = null; + } + return (A) this; } + public A withPorts(io.kubernetes.client.openapi.models.V1beta1EndpointPort... ports) { - if (this.ports != null) {this.ports.clear();} - if (ports != null) {for (io.kubernetes.client.openapi.models.V1beta1EndpointPort item :ports){ this.addToPorts(item);}} return (A) this; + if (this.ports != null) { + this.ports.clear(); + } + if (ports != null) { + for (io.kubernetes.client.openapi.models.V1beta1EndpointPort item : ports) { + this.addToPorts(item); + } + } + return (A) this; } + public java.lang.Boolean hasPorts() { return ports != null && !ports.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested addNewPort() { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested + addNewPort() { return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl.PortsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested addNewPortLike(io.kubernetes.client.openapi.models.V1beta1EndpointPort item) { - return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl.PortsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested + addNewPortLike(io.kubernetes.client.openapi.models.V1beta1EndpointPort item) { + return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl.PortsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested setNewPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointPort item) { - return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl.PortsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested + setNewPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointPort item) { + return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl.PortsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested editPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested editPort( + java.lang.Integer index) { if (ports.size() <= index) throw new RuntimeException("Can't edit ports. Index exceeds size."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested editFirstPort() { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested + editFirstPort() { if (ports.size() == 0) throw new RuntimeException("Can't edit first ports. The list is empty."); return setNewPortLike(0, buildPort(0)); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested editLastPort() { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested + editLastPort() { int index = ports.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ports. The list is empty."); return setNewPortLike(index, buildPort(index)); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested editMatchingPort(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested + editMatchingPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta1EndpointFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested,io.kubernetes.client.fluent.Nested{ - EndpointsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Endpoint item) { + + public class EndpointsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1EndpointFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested> + implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.EndpointsNested, + io.kubernetes.client.fluent.Nested { + EndpointsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Endpoint item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(this, item); } + EndpointsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1EndpointBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1EndpointBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1EndpointSliceFluentImpl.this.setToEndpoints(index,builder.build()); + return (N) V1beta1EndpointSliceFluentImpl.this.setToEndpoints(index, builder.build()); } + public N endEndpoint() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1beta1EndpointSliceFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class PortsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1EndpointPortFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested,io.kubernetes.client.fluent.Nested{ - PortsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointPort item) { + + public class PortsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1EndpointPortFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested> + implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent.PortsNested, + io.kubernetes.client.fluent.Nested { + PortsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointPort item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(this, item); } + PortsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1EndpointPortBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1EndpointSliceFluentImpl.this.setToPorts(index,builder.build()); + return (N) V1beta1EndpointSliceFluentImpl.this.setToPorts(index, builder.build()); } + public N endPort() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceListBuilder.java index b9751738a1..8bdf74f4bd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1EndpointSliceListBuilder extends io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1EndpointSliceListBuilder + extends io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceList, + io.kubernetes.client.openapi.models.V1beta1EndpointSliceListBuilder> { public V1beta1EndpointSliceListBuilder() { this(false); } + public V1beta1EndpointSliceListBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1EndpointSliceList(), validationEnabled); } - public V1beta1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent fluent) { + + public V1beta1EndpointSliceListBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent fluent) { this(fluent, false); } - public V1beta1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1EndpointSliceListBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1EndpointSliceList(), validationEnabled); } - public V1beta1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent fluent,io.kubernetes.client.openapi.models.V1beta1EndpointSliceList instance) { + + public V1beta1EndpointSliceListBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EndpointSliceList instance) { this(fluent, instance, false); } - public V1beta1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent fluent,io.kubernetes.client.openapi.models.V1beta1EndpointSliceList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1EndpointSliceListBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EndpointSliceList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1beta1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1bet fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointSliceList instance) { - this(instance,false); + + public V1beta1EndpointSliceListBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointSliceList instance) { + this(instance, false); } - public V1beta1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1beta1EndpointSliceList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1EndpointSliceListBuilder( + io.kubernetes.client.openapi.models.V1beta1EndpointSliceList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1beta1EndpointSliceListBuilder(io.kubernetes.client.openapi.models.V1bet this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceList build() { V1beta1EndpointSliceList buildable = new V1beta1EndpointSliceList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1beta1EndpointSliceList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1EndpointSliceListBuilder that = (V1beta1EndpointSliceListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceListFluent.java index e96a7beec8..5c655833a1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceListFluent.java @@ -1,95 +1,163 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1EndpointSliceListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1EndpointSliceListFluent< + A extends io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointSlice item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointSlice item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointSlice item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointSlice item); + public A addToItems(io.kubernetes.client.openapi.models.V1beta1EndpointSlice... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1EndpointSlice... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSlice buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSlice buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1EndpointSlice buildFirstItem(); + public io.kubernetes.client.openapi.models.V1beta1EndpointSlice buildLastItem(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSlice buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSlice buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1beta1EndpointSlice... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1EndpointSlice item); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointSlice item); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1EndpointSlice item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointSlice item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluent< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceListFluentImpl.java index 0f75394538..9dad6703f7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EndpointSliceListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta1EndpointSliceListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent{ - public V1beta1EndpointSliceListFluentImpl() { - } - public V1beta1EndpointSliceListFluentImpl(io.kubernetes.client.openapi.models.V1beta1EndpointSliceList instance) { + +/** Generated */ +public class V1beta1EndpointSliceListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent { + public V1beta1EndpointSliceListFluentImpl() {} + + public V1beta1EndpointSliceListFluentImpl( + io.kubernetes.client.openapi.models.V1beta1EndpointSliceList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,131 @@ public V1beta1EndpointSliceListFluentImpl(io.kubernetes.client.openapi.models.V1 this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointSlice item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointSlice item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointSlice item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointSlice item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1beta1EndpointSlice... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1EndpointSlice item : items) {io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1EndpointSlice item : items) { + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1EndpointSlice item : items) {io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1EndpointSlice item : items) { + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1EndpointSlice... items) { - for (io.kubernetes.client.openapi.models.V1beta1EndpointSlice item : items) {io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1EndpointSlice item : items) { + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1EndpointSlice item : items) {io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1EndpointSlice item : items) { + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder = each.next(); @@ -87,174 +164,287 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1beta1EndpointSlice buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSlice buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1EndpointSlice buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1EndpointSlice buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSlice buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1EndpointSlice buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1EndpointSlice item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1EndpointSlice item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1beta1EndpointSlice... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1beta1EndpointSlice item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1beta1EndpointSlice item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1EndpointSlice item) { - return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1EndpointSlice item) { + return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointSlice item) { - return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointSlice item) { + return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1EndpointSliceListFluentImpl that = (V1beta1EndpointSliceListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1EndpointSlice item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1EndpointSliceFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1EndpointSlice item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1EndpointSliceBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1EndpointSliceListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1beta1EndpointSliceListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1EndpointSliceListFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1beta1EndpointSliceListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventBuilder.java index ba29cb0e3c..c8ccb718a4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1EventBuilder extends io.kubernetes.client.openapi.models.V1beta1EventFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1EventBuilder + extends io.kubernetes.client.openapi.models.V1beta1EventFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EventBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1Event, + io.kubernetes.client.openapi.models.V1beta1EventBuilder> { public V1beta1EventBuilder() { this(false); } + public V1beta1EventBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1Event(), validationEnabled); } + public V1beta1EventBuilder(io.kubernetes.client.openapi.models.V1beta1EventFluent fluent) { this(fluent, false); } - public V1beta1EventBuilder(io.kubernetes.client.openapi.models.V1beta1EventFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1EventBuilder( + io.kubernetes.client.openapi.models.V1beta1EventFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1Event(), validationEnabled); } - public V1beta1EventBuilder(io.kubernetes.client.openapi.models.V1beta1EventFluent fluent,io.kubernetes.client.openapi.models.V1beta1Event instance) { + + public V1beta1EventBuilder( + io.kubernetes.client.openapi.models.V1beta1EventFluent fluent, + io.kubernetes.client.openapi.models.V1beta1Event instance) { this(fluent, instance, false); } - public V1beta1EventBuilder(io.kubernetes.client.openapi.models.V1beta1EventFluent fluent,io.kubernetes.client.openapi.models.V1beta1Event instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1EventBuilder( + io.kubernetes.client.openapi.models.V1beta1EventFluent fluent, + io.kubernetes.client.openapi.models.V1beta1Event instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAction(instance.getAction()); fluent.withApiVersion(instance.getApiVersion()); @@ -55,13 +81,17 @@ public V1beta1EventBuilder(io.kubernetes.client.openapi.models.V1beta1EventFluen fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1beta1EventBuilder(io.kubernetes.client.openapi.models.V1beta1Event instance) { - this(instance,false); + this(instance, false); } - public V1beta1EventBuilder(io.kubernetes.client.openapi.models.V1beta1Event instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1EventBuilder( + io.kubernetes.client.openapi.models.V1beta1Event instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAction(instance.getAction()); this.withApiVersion(instance.getApiVersion()); @@ -96,10 +126,12 @@ public V1beta1EventBuilder(io.kubernetes.client.openapi.models.V1beta1Event inst this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1EventFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1Event build() { V1beta1Event buildable = new V1beta1Event(); buildable.setAction(fluent.getAction()); @@ -121,18 +153,23 @@ public io.kubernetes.client.openapi.models.V1beta1Event build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1EventBuilder that = (V1beta1EventBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventFluent.java index 88ca8b6b98..c85e08ab72 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventFluent.java @@ -1,201 +1,303 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.time.OffsetDateTime; - - /** - * Generated - */ -public interface V1beta1EventFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1EventFluent< + A extends io.kubernetes.client.openapi.models.V1beta1EventFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getAction(); + public A withAction(java.lang.String action); + public java.lang.Boolean hasAction(); - - /** - * Method is deprecated. use withAction instead. - */ + + /** Method is deprecated. use withAction instead. */ @java.lang.Deprecated public A withNewAction(java.lang.String original); + public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.Integer getDeprecatedCount(); + public A withDeprecatedCount(java.lang.Integer deprecatedCount); + public java.lang.Boolean hasDeprecatedCount(); + public java.time.OffsetDateTime getDeprecatedFirstTimestamp(); + public A withDeprecatedFirstTimestamp(java.time.OffsetDateTime deprecatedFirstTimestamp); + public java.lang.Boolean hasDeprecatedFirstTimestamp(); + public java.time.OffsetDateTime getDeprecatedLastTimestamp(); + public A withDeprecatedLastTimestamp(java.time.OffsetDateTime deprecatedLastTimestamp); + public java.lang.Boolean hasDeprecatedLastTimestamp(); - + /** * This method has been deprecated, please use method buildDeprecatedSource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EventSource getDeprecatedSource(); + public io.kubernetes.client.openapi.models.V1EventSource buildDeprecatedSource(); + public A withDeprecatedSource(io.kubernetes.client.openapi.models.V1EventSource deprecatedSource); + public java.lang.Boolean hasDeprecatedSource(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested withNewDeprecatedSource(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested withNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested editDeprecatedSource(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested editOrNewDeprecatedSource(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested editOrNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested + withNewDeprecatedSource(); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested + withNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested + editDeprecatedSource(); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested + editOrNewDeprecatedSource(); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested + editOrNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item); + public java.time.OffsetDateTime getEventTime(); + public A withEventTime(java.time.OffsetDateTime eventTime); + public java.lang.Boolean hasEventTime(); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); + public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + public java.lang.String getNote(); + public A withNote(java.lang.String note); + public java.lang.Boolean hasNote(); - - /** - * Method is deprecated. use withNote instead. - */ + + /** Method is deprecated. use withNote instead. */ @java.lang.Deprecated public A withNewNote(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); - + /** * This method has been deprecated, please use method buildRegarding instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getRegarding(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildRegarding(); + public A withRegarding(io.kubernetes.client.openapi.models.V1ObjectReference regarding); + public java.lang.Boolean hasRegarding(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested withNewRegarding(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested withNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested + withNewRegarding(); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested + withNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested editRegarding(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested editOrNewRegarding(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested editOrNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item); - + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested + editOrNewRegarding(); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested + editOrNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + /** * This method has been deprecated, please use method buildRelated instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getRelated(); + public io.kubernetes.client.openapi.models.V1ObjectReference buildRelated(); + public A withRelated(io.kubernetes.client.openapi.models.V1ObjectReference related); + public java.lang.Boolean hasRelated(); + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested withNewRelated(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested withNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested withNewRelatedLike( + io.kubernetes.client.openapi.models.V1ObjectReference item); + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested editRelated(); + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested editOrNewRelated(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested editOrNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested + editOrNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item); + public java.lang.String getReportingController(); + public A withReportingController(java.lang.String reportingController); + public java.lang.Boolean hasReportingController(); - - /** - * Method is deprecated. use withReportingController instead. - */ + + /** Method is deprecated. use withReportingController instead. */ @java.lang.Deprecated public A withNewReportingController(java.lang.String original); + public java.lang.String getReportingInstance(); + public A withReportingInstance(java.lang.String reportingInstance); + public java.lang.Boolean hasReportingInstance(); - - /** - * Method is deprecated. use withReportingInstance instead. - */ + + /** Method is deprecated. use withReportingInstance instead. */ @java.lang.Deprecated public A withNewReportingInstance(java.lang.String original); - + /** * This method has been deprecated, please use method buildSeries instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1EventSeries getSeries(); + public io.kubernetes.client.openapi.models.V1beta1EventSeries buildSeries(); + public A withSeries(io.kubernetes.client.openapi.models.V1beta1EventSeries series); + public java.lang.Boolean hasSeries(); + public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested withNewSeries(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested withNewSeriesLike(io.kubernetes.client.openapi.models.V1beta1EventSeries item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested withNewSeriesLike( + io.kubernetes.client.openapi.models.V1beta1EventSeries item); + public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested editSeries(); + public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested editOrNewSeries(); - public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested editOrNewSeriesLike(io.kubernetes.client.openapi.models.V1beta1EventSeries item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested editOrNewSeriesLike( + io.kubernetes.client.openapi.models.V1beta1EventSeries item); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface DeprecatedSourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1EventSourceFluent>{ + + public interface DeprecatedSourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1EventSourceFluent< + io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested> { public N and(); + public N endDeprecatedSource(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface RegardingNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface RegardingNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested> { public N and(); + public N endRegarding(); - } - public interface RelatedNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectReferenceFluent>{ + + public interface RelatedNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectReferenceFluent< + io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested> { public N and(); + public N endRelated(); - } - public interface SeriesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent>{ + + public interface SeriesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent< + io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested> { public N and(); + public N endSeries(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventFluentImpl.java index 67be0c7d9a..354de67924 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventFluentImpl.java @@ -1,20 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta1EventFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1EventFluent{ - public V1beta1EventFluentImpl() { - } +/** Generated */ +public class V1beta1EventFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1EventFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1EventFluent { + public V1beta1EventFluentImpl() {} + public V1beta1EventFluentImpl(io.kubernetes.client.openapi.models.V1beta1Event instance) { this.withAction(instance.getAction()); @@ -49,8 +53,8 @@ public V1beta1EventFluentImpl(io.kubernetes.client.openapi.models.V1beta1Event i this.withSeries(instance.getSeries()); this.withType(instance.getType()); - } + private java.lang.String action; private java.lang.String apiVersion; private java.lang.Integer deprecatedCount; @@ -68,453 +72,662 @@ public V1beta1EventFluentImpl(io.kubernetes.client.openapi.models.V1beta1Event i private java.lang.String reportingInstance; private io.kubernetes.client.openapi.models.V1beta1EventSeriesBuilder series; private java.lang.String type; + public java.lang.String getAction() { return this.action; } + public A withAction(java.lang.String action) { - this.action=action; return (A) this; + this.action = action; + return (A) this; } + public java.lang.Boolean hasAction() { return this.action != null; } - - /** - * Method is deprecated. use withAction instead. - */ + + /** Method is deprecated. use withAction instead. */ @java.lang.Deprecated public A withNewAction(java.lang.String original) { - return (A)withAction(new String(original)); + return (A) withAction(new String(original)); } + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.Integer getDeprecatedCount() { return this.deprecatedCount; } + public A withDeprecatedCount(java.lang.Integer deprecatedCount) { - this.deprecatedCount=deprecatedCount; return (A) this; + this.deprecatedCount = deprecatedCount; + return (A) this; } + public java.lang.Boolean hasDeprecatedCount() { return this.deprecatedCount != null; } + public java.time.OffsetDateTime getDeprecatedFirstTimestamp() { return this.deprecatedFirstTimestamp; } + public A withDeprecatedFirstTimestamp(java.time.OffsetDateTime deprecatedFirstTimestamp) { - this.deprecatedFirstTimestamp=deprecatedFirstTimestamp; return (A) this; + this.deprecatedFirstTimestamp = deprecatedFirstTimestamp; + return (A) this; } + public java.lang.Boolean hasDeprecatedFirstTimestamp() { return this.deprecatedFirstTimestamp != null; } + public java.time.OffsetDateTime getDeprecatedLastTimestamp() { return this.deprecatedLastTimestamp; } + public A withDeprecatedLastTimestamp(java.time.OffsetDateTime deprecatedLastTimestamp) { - this.deprecatedLastTimestamp=deprecatedLastTimestamp; return (A) this; + this.deprecatedLastTimestamp = deprecatedLastTimestamp; + return (A) this; } + public java.lang.Boolean hasDeprecatedLastTimestamp() { return this.deprecatedLastTimestamp != null; } - + /** * This method has been deprecated, please use method buildDeprecatedSource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1EventSource getDeprecatedSource() { - return this.deprecatedSource!=null ?this.deprecatedSource.build():null; + return this.deprecatedSource != null ? this.deprecatedSource.build() : null; } + public io.kubernetes.client.openapi.models.V1EventSource buildDeprecatedSource() { - return this.deprecatedSource!=null ?this.deprecatedSource.build():null; + return this.deprecatedSource != null ? this.deprecatedSource.build() : null; } - public A withDeprecatedSource(io.kubernetes.client.openapi.models.V1EventSource deprecatedSource) { + + public A withDeprecatedSource( + io.kubernetes.client.openapi.models.V1EventSource deprecatedSource) { _visitables.get("deprecatedSource").remove(this.deprecatedSource); - if (deprecatedSource!=null){ this.deprecatedSource= new io.kubernetes.client.openapi.models.V1EventSourceBuilder(deprecatedSource); _visitables.get("deprecatedSource").add(this.deprecatedSource);} return (A) this; + if (deprecatedSource != null) { + this.deprecatedSource = + new io.kubernetes.client.openapi.models.V1EventSourceBuilder(deprecatedSource); + _visitables.get("deprecatedSource").add(this.deprecatedSource); + } + return (A) this; } + public java.lang.Boolean hasDeprecatedSource() { return this.deprecatedSource != null; } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested withNewDeprecatedSource() { - return new io.kubernetes.client.openapi.models.V1beta1EventFluentImpl.DeprecatedSourceNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested + withNewDeprecatedSource() { + return new io.kubernetes.client.openapi.models.V1beta1EventFluentImpl + .DeprecatedSourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested withNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item) { - return new io.kubernetes.client.openapi.models.V1beta1EventFluentImpl.DeprecatedSourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested + withNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item) { + return new io.kubernetes.client.openapi.models.V1beta1EventFluentImpl + .DeprecatedSourceNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested editDeprecatedSource() { + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested + editDeprecatedSource() { return withNewDeprecatedSourceLike(getDeprecatedSource()); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested editOrNewDeprecatedSource() { - return withNewDeprecatedSourceLike(getDeprecatedSource() != null ? getDeprecatedSource(): new io.kubernetes.client.openapi.models.V1EventSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested + editOrNewDeprecatedSource() { + return withNewDeprecatedSourceLike( + getDeprecatedSource() != null + ? getDeprecatedSource() + : new io.kubernetes.client.openapi.models.V1EventSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested editOrNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item) { - return withNewDeprecatedSourceLike(getDeprecatedSource() != null ? getDeprecatedSource(): item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested + editOrNewDeprecatedSourceLike(io.kubernetes.client.openapi.models.V1EventSource item) { + return withNewDeprecatedSourceLike( + getDeprecatedSource() != null ? getDeprecatedSource() : item); } + public java.time.OffsetDateTime getEventTime() { return this.eventTime; } + public A withEventTime(java.time.OffsetDateTime eventTime) { - this.eventTime=eventTime; return (A) this; + this.eventTime = eventTime; + return (A) this; } + public java.lang.Boolean hasEventTime() { return this.eventTime != null; } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1beta1EventFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { return new io.kubernetes.client.openapi.models.V1beta1EventFluentImpl.MetadataNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public java.lang.String getNote() { return this.note; } + public A withNote(java.lang.String note) { - this.note=note; return (A) this; + this.note = note; + return (A) this; } + public java.lang.Boolean hasNote() { return this.note != null; } - - /** - * Method is deprecated. use withNote instead. - */ + + /** Method is deprecated. use withNote instead. */ @java.lang.Deprecated public A withNewNote(java.lang.String original) { - return (A)withNote(new String(original)); + return (A) withNote(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } - + /** * This method has been deprecated, please use method buildRegarding instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getRegarding() { - return this.regarding!=null ?this.regarding.build():null; + return this.regarding != null ? this.regarding.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectReference buildRegarding() { - return this.regarding!=null ?this.regarding.build():null; + return this.regarding != null ? this.regarding.build() : null; } + public A withRegarding(io.kubernetes.client.openapi.models.V1ObjectReference regarding) { _visitables.get("regarding").remove(this.regarding); - if (regarding!=null){ this.regarding= new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(regarding); _visitables.get("regarding").add(this.regarding);} return (A) this; + if (regarding != null) { + this.regarding = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(regarding); + _visitables.get("regarding").add(this.regarding); + } + return (A) this; } + public java.lang.Boolean hasRegarding() { return this.regarding != null; } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested withNewRegarding() { + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested + withNewRegarding() { return new io.kubernetes.client.openapi.models.V1beta1EventFluentImpl.RegardingNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested withNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested + withNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { return new io.kubernetes.client.openapi.models.V1beta1EventFluentImpl.RegardingNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested editRegarding() { return withNewRegardingLike(getRegarding()); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested editOrNewRegarding() { - return withNewRegardingLike(getRegarding() != null ? getRegarding(): new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested + editOrNewRegarding() { + return withNewRegardingLike( + getRegarding() != null + ? getRegarding() + : new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested editOrNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return withNewRegardingLike(getRegarding() != null ? getRegarding(): item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested + editOrNewRegardingLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return withNewRegardingLike(getRegarding() != null ? getRegarding() : item); } - + /** * This method has been deprecated, please use method buildRelated instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectReference getRelated() { - return this.related!=null ?this.related.build():null; + return this.related != null ? this.related.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectReference buildRelated() { - return this.related!=null ?this.related.build():null; + return this.related != null ? this.related.build() : null; } + public A withRelated(io.kubernetes.client.openapi.models.V1ObjectReference related) { _visitables.get("related").remove(this.related); - if (related!=null){ this.related= new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(related); _visitables.get("related").add(this.related);} return (A) this; + if (related != null) { + this.related = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(related); + _visitables.get("related").add(this.related); + } + return (A) this; } + public java.lang.Boolean hasRelated() { return this.related != null; } + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested withNewRelated() { return new io.kubernetes.client.openapi.models.V1beta1EventFluentImpl.RelatedNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested withNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested withNewRelatedLike( + io.kubernetes.client.openapi.models.V1ObjectReference item) { return new io.kubernetes.client.openapi.models.V1beta1EventFluentImpl.RelatedNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested editRelated() { return withNewRelatedLike(getRelated()); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested editOrNewRelated() { - return withNewRelatedLike(getRelated() != null ? getRelated(): new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested + editOrNewRelated() { + return withNewRelatedLike( + getRelated() != null + ? getRelated() + : new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested editOrNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { - return withNewRelatedLike(getRelated() != null ? getRelated(): item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested + editOrNewRelatedLike(io.kubernetes.client.openapi.models.V1ObjectReference item) { + return withNewRelatedLike(getRelated() != null ? getRelated() : item); } + public java.lang.String getReportingController() { return this.reportingController; } + public A withReportingController(java.lang.String reportingController) { - this.reportingController=reportingController; return (A) this; + this.reportingController = reportingController; + return (A) this; } + public java.lang.Boolean hasReportingController() { return this.reportingController != null; } - - /** - * Method is deprecated. use withReportingController instead. - */ + + /** Method is deprecated. use withReportingController instead. */ @java.lang.Deprecated public A withNewReportingController(java.lang.String original) { - return (A)withReportingController(new String(original)); + return (A) withReportingController(new String(original)); } + public java.lang.String getReportingInstance() { return this.reportingInstance; } + public A withReportingInstance(java.lang.String reportingInstance) { - this.reportingInstance=reportingInstance; return (A) this; + this.reportingInstance = reportingInstance; + return (A) this; } + public java.lang.Boolean hasReportingInstance() { return this.reportingInstance != null; } - - /** - * Method is deprecated. use withReportingInstance instead. - */ + + /** Method is deprecated. use withReportingInstance instead. */ @java.lang.Deprecated public A withNewReportingInstance(java.lang.String original) { - return (A)withReportingInstance(new String(original)); + return (A) withReportingInstance(new String(original)); } - + /** * This method has been deprecated, please use method buildSeries instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1EventSeries getSeries() { - return this.series!=null ?this.series.build():null; + return this.series != null ? this.series.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1EventSeries buildSeries() { - return this.series!=null ?this.series.build():null; + return this.series != null ? this.series.build() : null; } + public A withSeries(io.kubernetes.client.openapi.models.V1beta1EventSeries series) { _visitables.get("series").remove(this.series); - if (series!=null){ this.series= new io.kubernetes.client.openapi.models.V1beta1EventSeriesBuilder(series); _visitables.get("series").add(this.series);} return (A) this; + if (series != null) { + this.series = new io.kubernetes.client.openapi.models.V1beta1EventSeriesBuilder(series); + _visitables.get("series").add(this.series); + } + return (A) this; } + public java.lang.Boolean hasSeries() { return this.series != null; } + public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested withNewSeries() { return new io.kubernetes.client.openapi.models.V1beta1EventFluentImpl.SeriesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested withNewSeriesLike(io.kubernetes.client.openapi.models.V1beta1EventSeries item) { + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested withNewSeriesLike( + io.kubernetes.client.openapi.models.V1beta1EventSeries item) { return new io.kubernetes.client.openapi.models.V1beta1EventFluentImpl.SeriesNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested editSeries() { return withNewSeriesLike(getSeries()); } + public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested editOrNewSeries() { - return withNewSeriesLike(getSeries() != null ? getSeries(): new io.kubernetes.client.openapi.models.V1beta1EventSeriesBuilder().build()); + return withNewSeriesLike( + getSeries() != null + ? getSeries() + : new io.kubernetes.client.openapi.models.V1beta1EventSeriesBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested editOrNewSeriesLike(io.kubernetes.client.openapi.models.V1beta1EventSeries item) { - return withNewSeriesLike(getSeries() != null ? getSeries(): item); + + public io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested editOrNewSeriesLike( + io.kubernetes.client.openapi.models.V1beta1EventSeries item) { + return withNewSeriesLike(getSeries() != null ? getSeries() : item); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1EventFluentImpl that = (V1beta1EventFluentImpl) o; - if (action != null ? !action.equals(that.action) :that.action != null) return false; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (deprecatedCount != null ? !deprecatedCount.equals(that.deprecatedCount) :that.deprecatedCount != null) return false; - if (deprecatedFirstTimestamp != null ? !deprecatedFirstTimestamp.equals(that.deprecatedFirstTimestamp) :that.deprecatedFirstTimestamp != null) return false; - if (deprecatedLastTimestamp != null ? !deprecatedLastTimestamp.equals(that.deprecatedLastTimestamp) :that.deprecatedLastTimestamp != null) return false; - if (deprecatedSource != null ? !deprecatedSource.equals(that.deprecatedSource) :that.deprecatedSource != null) return false; - if (eventTime != null ? !eventTime.equals(that.eventTime) :that.eventTime != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (note != null ? !note.equals(that.note) :that.note != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (regarding != null ? !regarding.equals(that.regarding) :that.regarding != null) return false; - if (related != null ? !related.equals(that.related) :that.related != null) return false; - if (reportingController != null ? !reportingController.equals(that.reportingController) :that.reportingController != null) return false; - if (reportingInstance != null ? !reportingInstance.equals(that.reportingInstance) :that.reportingInstance != null) return false; - if (series != null ? !series.equals(that.series) :that.series != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (action != null ? !action.equals(that.action) : that.action != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (deprecatedCount != null + ? !deprecatedCount.equals(that.deprecatedCount) + : that.deprecatedCount != null) return false; + if (deprecatedFirstTimestamp != null + ? !deprecatedFirstTimestamp.equals(that.deprecatedFirstTimestamp) + : that.deprecatedFirstTimestamp != null) return false; + if (deprecatedLastTimestamp != null + ? !deprecatedLastTimestamp.equals(that.deprecatedLastTimestamp) + : that.deprecatedLastTimestamp != null) return false; + if (deprecatedSource != null + ? !deprecatedSource.equals(that.deprecatedSource) + : that.deprecatedSource != null) return false; + if (eventTime != null ? !eventTime.equals(that.eventTime) : that.eventTime != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (note != null ? !note.equals(that.note) : that.note != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (regarding != null ? !regarding.equals(that.regarding) : that.regarding != null) + return false; + if (related != null ? !related.equals(that.related) : that.related != null) return false; + if (reportingController != null + ? !reportingController.equals(that.reportingController) + : that.reportingController != null) return false; + if (reportingInstance != null + ? !reportingInstance.equals(that.reportingInstance) + : that.reportingInstance != null) return false; + if (series != null ? !series.equals(that.series) : that.series != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(action, apiVersion, deprecatedCount, deprecatedFirstTimestamp, deprecatedLastTimestamp, deprecatedSource, eventTime, kind, metadata, note, reason, regarding, related, reportingController, reportingInstance, series, type, super.hashCode()); + return java.util.Objects.hash( + action, + apiVersion, + deprecatedCount, + deprecatedFirstTimestamp, + deprecatedLastTimestamp, + deprecatedSource, + eventTime, + kind, + metadata, + note, + reason, + regarding, + related, + reportingController, + reportingInstance, + series, + type, + super.hashCode()); } - public class DeprecatedSourceNestedImpl extends io.kubernetes.client.openapi.models.V1EventSourceFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested,io.kubernetes.client.fluent.Nested{ + + public class DeprecatedSourceNestedImpl + extends io.kubernetes.client.openapi.models.V1EventSourceFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested> + implements io.kubernetes.client.openapi.models.V1beta1EventFluent.DeprecatedSourceNested, + io.kubernetes.client.fluent.Nested { DeprecatedSourceNestedImpl(io.kubernetes.client.openapi.models.V1EventSource item) { this.builder = new io.kubernetes.client.openapi.models.V1EventSourceBuilder(this, item); } + DeprecatedSourceNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1EventSourceBuilder(this); } + io.kubernetes.client.openapi.models.V1EventSourceBuilder builder; + public N and() { return (N) V1beta1EventFluentImpl.this.withDeprecatedSource(builder.build()); } + public N endDeprecatedSource() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1EventFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1beta1EventFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class RegardingNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested,io.kubernetes.client.fluent.Nested{ + + public class RegardingNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested> + implements io.kubernetes.client.openapi.models.V1beta1EventFluent.RegardingNested, + io.kubernetes.client.fluent.Nested { RegardingNestedImpl(io.kubernetes.client.openapi.models.V1ObjectReference item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + RegardingNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; + public N and() { return (N) V1beta1EventFluentImpl.this.withRegarding(builder.build()); } + public N endRegarding() { return and(); } - } - public class RelatedNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested,io.kubernetes.client.fluent.Nested{ + + public class RelatedNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested> + implements io.kubernetes.client.openapi.models.V1beta1EventFluent.RelatedNested, + io.kubernetes.client.fluent.Nested { RelatedNestedImpl(io.kubernetes.client.openapi.models.V1ObjectReference item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this, item); } + RelatedNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectReferenceBuilder builder; + public N and() { return (N) V1beta1EventFluentImpl.this.withRelated(builder.build()); } + public N endRelated() { return and(); } - } - public class SeriesNestedImpl extends io.kubernetes.client.openapi.models.V1beta1EventSeriesFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested,io.kubernetes.client.fluent.Nested{ + + public class SeriesNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1EventSeriesFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested> + implements io.kubernetes.client.openapi.models.V1beta1EventFluent.SeriesNested, + io.kubernetes.client.fluent.Nested { SeriesNestedImpl(io.kubernetes.client.openapi.models.V1beta1EventSeries item) { this.builder = new io.kubernetes.client.openapi.models.V1beta1EventSeriesBuilder(this, item); } + SeriesNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta1EventSeriesBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1EventSeriesBuilder builder; + public N and() { return (N) V1beta1EventFluentImpl.this.withSeries(builder.build()); } + public N endSeries() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventListBuilder.java index 076c5879e3..d5fc7ad924 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1EventListBuilder extends io.kubernetes.client.openapi.models.V1beta1EventListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1EventListBuilder + extends io.kubernetes.client.openapi.models.V1beta1EventListFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EventListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1EventList, + io.kubernetes.client.openapi.models.V1beta1EventListBuilder> { public V1beta1EventListBuilder() { this(false); } + public V1beta1EventListBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1EventList(), validationEnabled); } - public V1beta1EventListBuilder(io.kubernetes.client.openapi.models.V1beta1EventListFluent fluent) { + + public V1beta1EventListBuilder( + io.kubernetes.client.openapi.models.V1beta1EventListFluent fluent) { this(fluent, false); } - public V1beta1EventListBuilder(io.kubernetes.client.openapi.models.V1beta1EventListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1EventListBuilder( + io.kubernetes.client.openapi.models.V1beta1EventListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1EventList(), validationEnabled); } - public V1beta1EventListBuilder(io.kubernetes.client.openapi.models.V1beta1EventListFluent fluent,io.kubernetes.client.openapi.models.V1beta1EventList instance) { + + public V1beta1EventListBuilder( + io.kubernetes.client.openapi.models.V1beta1EventListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EventList instance) { this(fluent, instance, false); } - public V1beta1EventListBuilder(io.kubernetes.client.openapi.models.V1beta1EventListFluent fluent,io.kubernetes.client.openapi.models.V1beta1EventList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1EventListBuilder( + io.kubernetes.client.openapi.models.V1beta1EventListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EventList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,17 @@ public V1beta1EventListBuilder(io.kubernetes.client.openapi.models.V1beta1EventL fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1beta1EventListBuilder(io.kubernetes.client.openapi.models.V1beta1EventList instance) { - this(instance,false); + this(instance, false); } - public V1beta1EventListBuilder(io.kubernetes.client.openapi.models.V1beta1EventList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1EventListBuilder( + io.kubernetes.client.openapi.models.V1beta1EventList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +75,12 @@ public V1beta1EventListBuilder(io.kubernetes.client.openapi.models.V1beta1EventL this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1EventListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1EventList build() { V1beta1EventList buildable = new V1beta1EventList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +89,23 @@ public io.kubernetes.client.openapi.models.V1beta1EventList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1EventListBuilder that = (V1beta1EventListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventListFluent.java index 7a35bcfd36..188f11370a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventListFluent.java @@ -1,95 +1,154 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1EventListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1EventListFluent< + A extends io.kubernetes.client.openapi.models.V1beta1EventListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Event item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Event item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Event item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Event item); + public A addToItems(io.kubernetes.client.openapi.models.V1beta1Event... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1Event... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1beta1Event buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1Event buildFirstItem(); + public io.kubernetes.client.openapi.models.V1beta1Event buildLastItem(); - public io.kubernetes.client.openapi.models.V1beta1Event buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1Event buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1beta1Event... items); + public java.lang.Boolean hasItems(); + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1Event item); - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Event item); - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1beta1Event item); + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Event item); + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested editItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested editFirstItem(); + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1EventFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1EventFluent< + io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventListFluentImpl.java index c7ddd668b5..39207c2622 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventListFluentImpl.java @@ -1,25 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - /** - * Generated - */ -public class V1beta1EventListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1EventListFluent{ - public V1beta1EventListFluentImpl() { - } +/** Generated */ +public class V1beta1EventListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1EventListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1EventListFluent { + public V1beta1EventListFluentImpl() {} + public V1beta1EventListFluentImpl(io.kubernetes.client.openapi.models.V1beta1EventList instance) { this.withApiVersion(instance.getApiVersion()); @@ -28,55 +30,123 @@ public V1beta1EventListFluentImpl(io.kubernetes.client.openapi.models.V1beta1Eve this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Event item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1EventBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EventBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Event item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1EventBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EventBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Event item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1EventBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EventBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Event item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1EventBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EventBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1beta1Event... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1Event item : items) {io.kubernetes.client.openapi.models.V1beta1EventBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EventBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1Event item : items) { + io.kubernetes.client.openapi.models.V1beta1EventBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EventBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1Event item : items) {io.kubernetes.client.openapi.models.V1beta1EventBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EventBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1Event item : items) { + io.kubernetes.client.openapi.models.V1beta1EventBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EventBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1Event... items) { - for (io.kubernetes.client.openapi.models.V1beta1Event item : items) {io.kubernetes.client.openapi.models.V1beta1EventBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EventBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1Event item : items) { + io.kubernetes.client.openapi.models.V1beta1EventBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EventBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1Event item : items) {io.kubernetes.client.openapi.models.V1beta1EventBuilder builder = new io.kubernetes.client.openapi.models.V1beta1EventBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1Event item : items) { + io.kubernetes.client.openapi.models.V1beta1EventBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1EventBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; final Iterator each = items.iterator(); final List visitables = _visitables.get("items"); @@ -87,174 +157,275 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1beta1Event buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1Event buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1Event buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1Event buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1EventBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1Event buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1EventBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1EventBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1EventBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1Event item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1Event item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1beta1Event... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1beta1Event item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1beta1Event item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested addNewItem() { return new io.kubernetes.client.openapi.models.V1beta1EventListFluentImpl.ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1Event item) { - return new io.kubernetes.client.openapi.models.V1beta1EventListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested addNewItemLike( + io.kubernetes.client.openapi.models.V1beta1Event item) { + return new io.kubernetes.client.openapi.models.V1beta1EventListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Event item) { - return new io.kubernetes.client.openapi.models.V1beta1EventListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Event item) { + return new io.kubernetes.client.openapi.models.V1beta1EventListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1beta1EventListFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1EventListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1EventListFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1EventListFluentImpl that = (V1beta1EventListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1EventFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Event item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1EventFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1beta1EventListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Event item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta1EventBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1EventBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1EventBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1EventListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1beta1EventListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1EventListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1beta1EventListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventSeriesBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventSeriesBuilder.java index 1128e2eee9..01433aee10 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventSeriesBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventSeriesBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1EventSeriesBuilder extends io.kubernetes.client.openapi.models.V1beta1EventSeriesFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1EventSeriesBuilder + extends io.kubernetes.client.openapi.models.V1beta1EventSeriesFluentImpl< + io.kubernetes.client.openapi.models.V1beta1EventSeriesBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1EventSeries, + io.kubernetes.client.openapi.models.V1beta1EventSeriesBuilder> { public V1beta1EventSeriesBuilder() { this(false); } + public V1beta1EventSeriesBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1EventSeries(), validationEnabled); } - public V1beta1EventSeriesBuilder(io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent fluent) { + + public V1beta1EventSeriesBuilder( + io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent fluent) { this(fluent, false); } - public V1beta1EventSeriesBuilder(io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1EventSeriesBuilder( + io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1EventSeries(), validationEnabled); } - public V1beta1EventSeriesBuilder(io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent fluent,io.kubernetes.client.openapi.models.V1beta1EventSeries instance) { + + public V1beta1EventSeriesBuilder( + io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EventSeries instance) { this(fluent, instance, false); } - public V1beta1EventSeriesBuilder(io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent fluent,io.kubernetes.client.openapi.models.V1beta1EventSeries instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1EventSeriesBuilder( + io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent fluent, + io.kubernetes.client.openapi.models.V1beta1EventSeries instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCount(instance.getCount()); fluent.withLastObservedTime(instance.getLastObservedTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1EventSeriesBuilder(io.kubernetes.client.openapi.models.V1beta1EventSeries instance) { - this(instance,false); + + public V1beta1EventSeriesBuilder( + io.kubernetes.client.openapi.models.V1beta1EventSeries instance) { + this(instance, false); } - public V1beta1EventSeriesBuilder(io.kubernetes.client.openapi.models.V1beta1EventSeries instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1EventSeriesBuilder( + io.kubernetes.client.openapi.models.V1beta1EventSeries instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCount(instance.getCount()); this.withLastObservedTime(instance.getLastObservedTime()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1EventSeries build() { V1beta1EventSeries buildable = new V1beta1EventSeries(); buildable.setCount(fluent.getCount()); buildable.setLastObservedTime(fluent.getLastObservedTime()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1EventSeriesBuilder that = (V1beta1EventSeriesBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventSeriesFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventSeriesFluent.java index 2458a96fa0..c6d3e0e592 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventSeriesFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventSeriesFluent.java @@ -1,21 +1,30 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1EventSeriesFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1EventSeriesFluent< + A extends io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getCount(); + public A withCount(java.lang.Integer count); + public java.lang.Boolean hasCount(); + public java.time.OffsetDateTime getLastObservedTime(); + public A withLastObservedTime(java.time.OffsetDateTime lastObservedTime); + public java.lang.Boolean hasLastObservedTime(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventSeriesFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventSeriesFluentImpl.java index e56288d830..d28aa547dc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventSeriesFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1EventSeriesFluentImpl.java @@ -1,53 +1,72 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1EventSeriesFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent { + public V1beta1EventSeriesFluentImpl() {} - /** - * Generated - */ -public class V1beta1EventSeriesFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1EventSeriesFluent{ - public V1beta1EventSeriesFluentImpl() { - } - public V1beta1EventSeriesFluentImpl(io.kubernetes.client.openapi.models.V1beta1EventSeries instance) { + public V1beta1EventSeriesFluentImpl( + io.kubernetes.client.openapi.models.V1beta1EventSeries instance) { this.withCount(instance.getCount()); this.withLastObservedTime(instance.getLastObservedTime()); - } + private java.lang.Integer count; private java.time.OffsetDateTime lastObservedTime; + public java.lang.Integer getCount() { return this.count; } + public A withCount(java.lang.Integer count) { - this.count=count; return (A) this; + this.count = count; + return (A) this; } + public java.lang.Boolean hasCount() { return this.count != null; } + public java.time.OffsetDateTime getLastObservedTime() { return this.lastObservedTime; } + public A withLastObservedTime(java.time.OffsetDateTime lastObservedTime) { - this.lastObservedTime=lastObservedTime; return (A) this; + this.lastObservedTime = lastObservedTime; + return (A) this; } + public java.lang.Boolean hasLastObservedTime() { return this.lastObservedTime != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1EventSeriesFluentImpl that = (V1beta1EventSeriesFluentImpl) o; - if (count != null ? !count.equals(that.count) :that.count != null) return false; - if (lastObservedTime != null ? !lastObservedTime.equals(that.lastObservedTime) :that.lastObservedTime != null) return false; + if (count != null ? !count.equals(that.count) : that.count != null) return false; + if (lastObservedTime != null + ? !lastObservedTime.equals(that.lastObservedTime) + : that.lastObservedTime != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(count, lastObservedTime, super.hashCode()); + return java.util.Objects.hash(count, lastObservedTime, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FSGroupStrategyOptionsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FSGroupStrategyOptionsBuilder.java index 35ac49cb63..d3f6561eb4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FSGroupStrategyOptionsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FSGroupStrategyOptionsBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1FSGroupStrategyOptionsBuilder extends io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1FSGroupStrategyOptionsBuilder + extends io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions, + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsBuilder> { public V1beta1FSGroupStrategyOptionsBuilder() { this(false); } + public V1beta1FSGroupStrategyOptionsBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1FSGroupStrategyOptions(), validationEnabled); } - public V1beta1FSGroupStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent fluent) { + + public V1beta1FSGroupStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent fluent) { this(fluent, false); } - public V1beta1FSGroupStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1FSGroupStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1FSGroupStrategyOptions(), validationEnabled); } - public V1beta1FSGroupStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions instance) { + + public V1beta1FSGroupStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions instance) { this(fluent, instance, false); } - public V1beta1FSGroupStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1FSGroupStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withRanges(instance.getRanges()); fluent.withRule(instance.getRule()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1FSGroupStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions instance) { - this(instance,false); + + public V1beta1FSGroupStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions instance) { + this(instance, false); } - public V1beta1FSGroupStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1FSGroupStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withRanges(instance.getRanges()); this.withRule(instance.getRule()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions build() { V1beta1FSGroupStrategyOptions buildable = new V1beta1FSGroupStrategyOptions(); buildable.setRanges(fluent.getRanges()); buildable.setRule(fluent.getRule()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1FSGroupStrategyOptionsBuilder that = (V1beta1FSGroupStrategyOptionsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FSGroupStrategyOptionsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FSGroupStrategyOptionsFluent.java index b225308cdb..eaad0fbd60 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FSGroupStrategyOptionsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FSGroupStrategyOptionsFluent.java @@ -1,66 +1,112 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1FSGroupStrategyOptionsFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item); - public A setToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item); +/** Generated */ +public interface V1beta1FSGroupStrategyOptionsFluent< + A extends io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item); + + public A setToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item); + public A addToRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items); - public A addAllToRanges(java.util.Collection items); + + public A addAllToRanges( + java.util.Collection items); + public A removeFromRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items); - public A removeAllFromRanges(java.util.Collection items); - public A removeMatchingFromRanges(java.util.function.Predicate predicate); - + + public A removeAllFromRanges( + java.util.Collection items); + + public A removeMatchingFromRanges( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildRanges instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getRanges(); + public java.util.List buildRanges(); + public io.kubernetes.client.openapi.models.V1beta1IDRange buildRange(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1IDRange buildFirstRange(); + public io.kubernetes.client.openapi.models.V1beta1IDRange buildLastRange(); - public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRange(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingRange( + java.util.function.Predicate + predicate); + public A withRanges(java.util.List ranges); + public A withRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... ranges); + public java.lang.Boolean hasRanges(); - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested addNewRange(); - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item); - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested setNewRangeLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item); - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested editRange(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested editFirstRange(); - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested editLastRange(); - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested editMatchingRange(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + addNewRange(); + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item); + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + setNewRangeLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item); + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + editRange(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + editFirstRange(); + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + editLastRange(); + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + editMatchingRange( + java.util.function.Predicate + predicate); + public java.lang.String getRule(); + public A withRule(java.lang.String rule); + public java.lang.Boolean hasRule(); - - /** - * Method is deprecated. use withRule instead. - */ + + /** Method is deprecated. use withRule instead. */ @java.lang.Deprecated public A withNewRule(java.lang.String original); - public interface RangesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1IDRangeFluent>{ + + public interface RangesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1IDRangeFluent< + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested< + N>> { public N and(); + public N endRange(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FSGroupStrategyOptionsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FSGroupStrategyOptionsFluentImpl.java index 181af21dc1..e0c38bba4e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FSGroupStrategyOptionsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FSGroupStrategyOptionsFluentImpl.java @@ -1,61 +1,131 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1beta1FSGroupStrategyOptionsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent{ - public V1beta1FSGroupStrategyOptionsFluentImpl() { - } - public V1beta1FSGroupStrategyOptionsFluentImpl(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions instance) { +/** Generated */ +public class V1beta1FSGroupStrategyOptionsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent { + public V1beta1FSGroupStrategyOptionsFluentImpl() {} + + public V1beta1FSGroupStrategyOptionsFluentImpl( + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions instance) { this.withRanges(instance.getRanges()); this.withRule(instance.getRule()); - } + private java.util.ArrayList ranges; private java.lang.String rule; - public A addToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").add(index >= 0 ? index : _visitables.get("ranges").size(), builder);this.ranges.add(index >= 0 ? index : ranges.size(), builder); return (A)this; + + public A addToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").add(index >= 0 ? index : _visitables.get("ranges").size(), builder); + this.ranges.add(index >= 0 ? index : ranges.size(), builder); + return (A) this; } - public A setToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); - if (index < 0 || index >= _visitables.get("ranges").size()) { _visitables.get("ranges").add(builder); } else { _visitables.get("ranges").set(index, builder);} - if (index < 0 || index >= ranges.size()) { ranges.add(builder); } else { ranges.set(index, builder);} - return (A)this; + + public A setToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + if (index < 0 || index >= _visitables.get("ranges").size()) { + _visitables.get("ranges").add(builder); + } else { + _visitables.get("ranges").set(index, builder); + } + if (index < 0 || index >= ranges.size()) { + ranges.add(builder); + } else { + ranges.set(index, builder); + } + return (A) this; } + public A addToRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").add(builder);this.ranges.add(builder);} return (A)this; + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").add(builder); + this.ranges.add(builder); + } + return (A) this; } - public A addAllToRanges(java.util.Collection items) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").add(builder);this.ranges.add(builder);} return (A)this; + + public A addAllToRanges( + java.util.Collection items) { + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").add(builder); + this.ranges.add(builder); + } + return (A) this; } + public A removeFromRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items) { - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").remove(builder);if (this.ranges != null) {this.ranges.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").remove(builder); + if (this.ranges != null) { + this.ranges.remove(builder); + } + } + return (A) this; } - public A removeAllFromRanges(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").remove(builder);if (this.ranges != null) {this.ranges.remove(builder);}} return (A)this; + + public A removeAllFromRanges( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").remove(builder); + if (this.ranges != null) { + this.ranges.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromRanges(java.util.function.Predicate predicate) { + + public A removeMatchingFromRanges( + java.util.function.Predicate + predicate) { if (ranges == null) return (A) this; - final Iterator each = ranges.iterator(); + final Iterator each = + ranges.iterator(); final List visitables = _visitables.get("ranges"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = each.next(); @@ -64,122 +134,202 @@ public A removeMatchingFromRanges(java.util.function.Predicate getRanges() { return ranges != null ? build(ranges) : null; } + public java.util.List buildRanges() { return ranges != null ? build(ranges) : null; } + public io.kubernetes.client.openapi.models.V1beta1IDRange buildRange(java.lang.Integer index) { return this.ranges.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1IDRange buildFirstRange() { return this.ranges.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1IDRange buildLastRange() { return this.ranges.get(ranges.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item: ranges) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item : ranges) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingRange(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item: ranges) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRange( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item : ranges) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withRanges(java.util.List ranges) { - if (this.ranges != null) { _visitables.get("ranges").removeAll(this.ranges);} - if (ranges != null) {this.ranges = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1IDRange item : ranges){this.addToRanges(item);}} else { this.ranges = null;} return (A) this; + if (this.ranges != null) { + _visitables.get("ranges").removeAll(this.ranges); + } + if (ranges != null) { + this.ranges = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : ranges) { + this.addToRanges(item); + } + } else { + this.ranges = null; + } + return (A) this; } + public A withRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... ranges) { - if (this.ranges != null) {this.ranges.clear();} - if (ranges != null) {for (io.kubernetes.client.openapi.models.V1beta1IDRange item :ranges){ this.addToRanges(item);}} return (A) this; + if (this.ranges != null) { + this.ranges.clear(); + } + if (ranges != null) { + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : ranges) { + this.addToRanges(item); + } + } + return (A) this; } + public java.lang.Boolean hasRanges() { return ranges != null && !ranges.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested addNewRange() { - return new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluentImpl.RangesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + addNewRange() { + return new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluentImpl + .RangesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item) { - return new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluentImpl.RangesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item) { + return new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluentImpl + .RangesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested setNewRangeLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { - return new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluentImpl.RangesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + setNewRangeLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { + return new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluentImpl + .RangesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested editRange(java.lang.Integer index) { - if (ranges.size() <= index) throw new RuntimeException("Can't edit ranges. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + editRange(java.lang.Integer index) { + if (ranges.size() <= index) + throw new RuntimeException("Can't edit ranges. Index exceeds size."); return setNewRangeLike(index, buildRange(index)); } - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested editFirstRange() { - if (ranges.size() == 0) throw new RuntimeException("Can't edit first ranges. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + editFirstRange() { + if (ranges.size() == 0) + throw new RuntimeException("Can't edit first ranges. The list is empty."); return setNewRangeLike(0, buildRange(0)); } - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested editLastRange() { + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + editLastRange() { int index = ranges.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ranges. The list is empty."); return setNewRangeLike(index, buildRange(index)); } - public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested editMatchingRange(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested + editMatchingRange( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta1IDRangeFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested,io.kubernetes.client.fluent.Nested{ - RangesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { + + public class RangesNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1IDRangeFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent.RangesNested> + implements io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent + .RangesNested< + N>, + io.kubernetes.client.fluent.Nested { + RangesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(this, item); } + RangesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1FSGroupStrategyOptionsFluentImpl.this.setToRanges(index,builder.build()); + return (N) V1beta1FSGroupStrategyOptionsFluentImpl.this.setToRanges(index, builder.build()); } + public N endRange() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowDistinguisherMethodBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowDistinguisherMethodBuilder.java index cfc8c0c1f5..5f05401dfa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowDistinguisherMethodBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowDistinguisherMethodBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1FlowDistinguisherMethodBuilder extends io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1FlowDistinguisherMethodBuilder + extends io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod, + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodBuilder> { public V1beta1FlowDistinguisherMethodBuilder() { this(false); } + public V1beta1FlowDistinguisherMethodBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1FlowDistinguisherMethod(), validationEnabled); } - public V1beta1FlowDistinguisherMethodBuilder(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent fluent) { + + public V1beta1FlowDistinguisherMethodBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent fluent) { this(fluent, false); } - public V1beta1FlowDistinguisherMethodBuilder(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1FlowDistinguisherMethodBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1FlowDistinguisherMethod(), validationEnabled); } - public V1beta1FlowDistinguisherMethodBuilder(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent fluent,io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod instance) { + + public V1beta1FlowDistinguisherMethodBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod instance) { this(fluent, instance, false); } - public V1beta1FlowDistinguisherMethodBuilder(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent fluent,io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1FlowDistinguisherMethodBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1FlowDistinguisherMethodBuilder(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod instance) { - this(instance,false); + + public V1beta1FlowDistinguisherMethodBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod instance) { + this(instance, false); } - public V1beta1FlowDistinguisherMethodBuilder(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1FlowDistinguisherMethodBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod build() { V1beta1FlowDistinguisherMethod buildable = new V1beta1FlowDistinguisherMethod(); buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1FlowDistinguisherMethodBuilder that = (V1beta1FlowDistinguisherMethodBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowDistinguisherMethodFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowDistinguisherMethodFluent.java index 34b63e7617..f5013a2401 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowDistinguisherMethodFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowDistinguisherMethodFluent.java @@ -1,23 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1FlowDistinguisherMethodFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1FlowDistinguisherMethodFluent< + A extends io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowDistinguisherMethodFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowDistinguisherMethodFluentImpl.java index cd683f2f7a..cd6534c0a6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowDistinguisherMethodFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowDistinguisherMethodFluentImpl.java @@ -1,48 +1,59 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta1FlowDistinguisherMethodFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent{ - public V1beta1FlowDistinguisherMethodFluentImpl() { - } - public V1beta1FlowDistinguisherMethodFluentImpl(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod instance) { - this.withType(instance.getType()); +/** Generated */ +public class V1beta1FlowDistinguisherMethodFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent { + public V1beta1FlowDistinguisherMethodFluentImpl() {} + public V1beta1FlowDistinguisherMethodFluentImpl( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod instance) { + this.withType(instance.getType()); } + private java.lang.String type; + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1FlowDistinguisherMethodFluentImpl that = (V1beta1FlowDistinguisherMethodFluentImpl) o; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(type, super.hashCode()); + return java.util.Objects.hash(type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaBuilder.java index 61c298c108..5f4333efac 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1FlowSchemaBuilder extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1FlowSchemaBuilder + extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1FlowSchema, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder> { public V1beta1FlowSchemaBuilder() { this(false); } + public V1beta1FlowSchemaBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1FlowSchema(), validationEnabled); } - public V1beta1FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent fluent) { + + public V1beta1FlowSchemaBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent fluent) { this(fluent, false); } - public V1beta1FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1FlowSchemaBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1FlowSchema(), validationEnabled); } - public V1beta1FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent fluent,io.kubernetes.client.openapi.models.V1beta1FlowSchema instance) { + + public V1beta1FlowSchemaBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FlowSchema instance) { this(fluent, instance, false); } - public V1beta1FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent fluent,io.kubernetes.client.openapi.models.V1beta1FlowSchema instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1FlowSchemaBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FlowSchema instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,17 @@ public V1beta1FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta1FlowS fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1beta1FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchema instance) { - this(instance,false); + this(instance, false); } - public V1beta1FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchema instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1FlowSchemaBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchema instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +79,12 @@ public V1beta1FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta1FlowS this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1FlowSchema build() { V1beta1FlowSchema buildable = new V1beta1FlowSchema(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +94,23 @@ public io.kubernetes.client.openapi.models.V1beta1FlowSchema build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1FlowSchemaBuilder that = (V1beta1FlowSchemaBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaConditionBuilder.java index 97e5b2de9b..c31f4c4d66 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1FlowSchemaConditionBuilder extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1FlowSchemaConditionBuilder + extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder> { public V1beta1FlowSchemaConditionBuilder() { this(false); } + public V1beta1FlowSchemaConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1FlowSchemaCondition(), validationEnabled); } - public V1beta1FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent fluent) { + + public V1beta1FlowSchemaConditionBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent fluent) { this(fluent, false); } - public V1beta1FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1FlowSchemaConditionBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1FlowSchemaCondition(), validationEnabled); } - public V1beta1FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent fluent,io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition instance) { + + public V1beta1FlowSchemaConditionBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition instance) { this(fluent, instance, false); } - public V1beta1FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent fluent,io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1FlowSchemaConditionBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +58,18 @@ public V1beta1FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1b fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition instance) { - this(instance,false); + + public V1beta1FlowSchemaConditionBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition instance) { + this(instance, false); } - public V1beta1FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1FlowSchemaConditionBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,10 +80,12 @@ public V1beta1FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1b this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition build() { V1beta1FlowSchemaCondition buildable = new V1beta1FlowSchemaCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1FlowSchemaConditionBuilder that = (V1beta1FlowSchemaConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaConditionFluent.java index 7f3828d6c2..0185118e50 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaConditionFluent.java @@ -1,54 +1,64 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1FlowSchemaConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1FlowSchemaConditionFluent< + A extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaConditionFluentImpl.java index 52d15d9f1d..39d63f5500 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaConditionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1beta1FlowSchemaConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent { + public V1beta1FlowSchemaConditionFluentImpl() {} - /** - * Generated - */ -public class V1beta1FlowSchemaConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent{ - public V1beta1FlowSchemaConditionFluentImpl() { - } - public V1beta1FlowSchemaConditionFluentImpl(io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition instance) { + public V1beta1FlowSchemaConditionFluentImpl( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,103 +30,119 @@ public V1beta1FlowSchemaConditionFluentImpl(io.kubernetes.client.openapi.models. this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1FlowSchemaConditionFluentImpl that = (V1beta1FlowSchemaConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaFluent.java index 8f17c0f597..9414e5aa4c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaFluent.java @@ -1,93 +1,148 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1FlowSchemaFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1FlowSchemaFluent< + A extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec getSpec(); + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec item); + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec item); - + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus getStatus(); + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus item); + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaFluentImpl.java index 1c8d47962f..892f39435c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1FlowSchemaFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent { + public V1beta1FlowSchemaFluentImpl() {} - /** - * Generated - */ -public class V1beta1FlowSchemaFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent{ - public V1beta1FlowSchemaFluentImpl() { - } - public V1beta1FlowSchemaFluentImpl(io.kubernetes.client.openapi.models.V1beta1FlowSchema instance) { + public V1beta1FlowSchemaFluentImpl( + io.kubernetes.client.openapi.models.V1beta1FlowSchema instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,303 @@ public V1beta1FlowSchemaFluentImpl(io.kubernetes.client.openapi.models.V1beta1Fl this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecBuilder spec; private io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec item) { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec item) { return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested withNewStatus() { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested + withNewStatus() { return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus item) { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus item) { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluentImpl.StatusNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1FlowSchemaFluentImpl that = (V1beta1FlowSchemaFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1beta1FlowSchemaFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecBuilder builder; + public N and() { return (N) V1beta1FlowSchemaFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusBuilder builder; + public N and() { return (N) V1beta1FlowSchemaFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaListBuilder.java index 624cccf313..c8c9dc3ca7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1FlowSchemaListBuilder extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1FlowSchemaListBuilder + extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaList, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaListBuilder> { public V1beta1FlowSchemaListBuilder() { this(false); } + public V1beta1FlowSchemaListBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1FlowSchemaList(), validationEnabled); } - public V1beta1FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent fluent) { + + public V1beta1FlowSchemaListBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent fluent) { this(fluent, false); } - public V1beta1FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1FlowSchemaListBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1FlowSchemaList(), validationEnabled); } - public V1beta1FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent fluent,io.kubernetes.client.openapi.models.V1beta1FlowSchemaList instance) { + + public V1beta1FlowSchemaListBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaList instance) { this(fluent, instance, false); } - public V1beta1FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent fluent,io.kubernetes.client.openapi.models.V1beta1FlowSchemaList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1FlowSchemaListBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1beta1FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta1F fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaList instance) { - this(instance,false); + + public V1beta1FlowSchemaListBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaList instance) { + this(instance, false); } - public V1beta1FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1FlowSchemaListBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1beta1FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta1F this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaList build() { V1beta1FlowSchemaList buildable = new V1beta1FlowSchemaList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1beta1FlowSchemaList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1FlowSchemaListBuilder that = (V1beta1FlowSchemaListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaListFluent.java index fac75afa7a..1d1602c3b3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaListFluent.java @@ -1,95 +1,159 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1FlowSchemaListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1FlowSchemaListFluent< + A extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchema item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchema item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1FlowSchema item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1FlowSchema item); + public A addToItems(io.kubernetes.client.openapi.models.V1beta1FlowSchema... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1FlowSchema... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1beta1FlowSchema buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1FlowSchema buildFirstItem(); + public io.kubernetes.client.openapi.models.V1beta1FlowSchema buildLastItem(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchema buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchema buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1beta1FlowSchema... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1FlowSchema item); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchema item); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1FlowSchema item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1FlowSchema item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluent< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaListFluentImpl.java index 2faddbc9dc..8a0ba9a722 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta1FlowSchemaListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent{ - public V1beta1FlowSchemaListFluentImpl() { - } - public V1beta1FlowSchemaListFluentImpl(io.kubernetes.client.openapi.models.V1beta1FlowSchemaList instance) { + +/** Generated */ +public class V1beta1FlowSchemaListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent { + public V1beta1FlowSchemaListFluentImpl() {} + + public V1beta1FlowSchemaListFluentImpl( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1beta1FlowSchemaListFluentImpl(io.kubernetes.client.openapi.models.V1bet this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchema item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1FlowSchema item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchema item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1FlowSchema item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1beta1FlowSchema... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1FlowSchema item : items) {io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1FlowSchema item : items) { + io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1FlowSchema item : items) {io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1FlowSchema item : items) { + io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1FlowSchema... items) { - for (io.kubernetes.client.openapi.models.V1beta1FlowSchema item : items) {io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1FlowSchema item : items) { + io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1FlowSchema item : items) {io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1FlowSchema item : items) { + io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder = each.next(); @@ -87,174 +159,282 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1beta1FlowSchema buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1FlowSchema buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1FlowSchema buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchema buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1FlowSchema buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1FlowSchema item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1FlowSchema item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1beta1FlowSchema... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1beta1FlowSchema item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1beta1FlowSchema item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1FlowSchema item) { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1FlowSchema item) { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchema item) { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1FlowSchema item) { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1FlowSchemaListFluentImpl that = (V1beta1FlowSchemaListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchema item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1FlowSchema item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1FlowSchemaBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1FlowSchemaListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1beta1FlowSchemaListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1beta1FlowSchemaListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaSpecBuilder.java index 11027ab2c1..182979c18b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1FlowSchemaSpecBuilder extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1FlowSchemaSpecBuilder + extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecBuilder> { public V1beta1FlowSchemaSpecBuilder() { this(false); } + public V1beta1FlowSchemaSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1FlowSchemaSpec(), validationEnabled); } - public V1beta1FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent fluent) { + + public V1beta1FlowSchemaSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent fluent) { this(fluent, false); } - public V1beta1FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1FlowSchemaSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1FlowSchemaSpec(), validationEnabled); } - public V1beta1FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec instance) { + + public V1beta1FlowSchemaSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec instance) { this(fluent, instance, false); } - public V1beta1FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1FlowSchemaSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDistinguisherMethod(instance.getDistinguisherMethod()); fluent.withMatchingPrecedence(instance.getMatchingPrecedence()); @@ -29,13 +56,18 @@ public V1beta1FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta1F fluent.withRules(instance.getRules()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec instance) { - this(instance,false); + + public V1beta1FlowSchemaSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec instance) { + this(instance, false); } - public V1beta1FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1FlowSchemaSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDistinguisherMethod(instance.getDistinguisherMethod()); this.withMatchingPrecedence(instance.getMatchingPrecedence()); @@ -44,10 +76,12 @@ public V1beta1FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta1F this.withRules(instance.getRules()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec build() { V1beta1FlowSchemaSpec buildable = new V1beta1FlowSchemaSpec(); buildable.setDistinguisherMethod(fluent.getDistinguisherMethod()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec build() { buildable.setRules(fluent.getRules()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1FlowSchemaSpecBuilder that = (V1beta1FlowSchemaSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaSpecFluent.java index 2eec00238b..83f1de4ed1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaSpecFluent.java @@ -1,100 +1,228 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1beta1FlowSchemaSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1beta1FlowSchemaSpecFluent< + A extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildDistinguisherMethod instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod getDistinguisherMethod(); - public io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod buildDistinguisherMethod(); - public A withDistinguisherMethod(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod distinguisherMethod); + public io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod + getDistinguisherMethod(); + + public io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod + buildDistinguisherMethod(); + + public A withDistinguisherMethod( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod distinguisherMethod); + public java.lang.Boolean hasDistinguisherMethod(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested withNewDistinguisherMethod(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested withNewDistinguisherMethodLike(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod item); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested editDistinguisherMethod(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested editOrNewDistinguisherMethod(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested editOrNewDistinguisherMethodLike(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + withNewDistinguisherMethod(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + withNewDistinguisherMethodLike( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + editDistinguisherMethod(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + editOrNewDistinguisherMethod(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + editOrNewDistinguisherMethodLike( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod item); + public java.lang.Integer getMatchingPrecedence(); + public A withMatchingPrecedence(java.lang.Integer matchingPrecedence); + public java.lang.Boolean hasMatchingPrecedence(); - + /** * This method has been deprecated, please use method buildPriorityLevelConfiguration instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference getPriorityLevelConfiguration(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference buildPriorityLevelConfiguration(); - public A withPriorityLevelConfiguration(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference priorityLevelConfiguration); + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference + getPriorityLevelConfiguration(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference + buildPriorityLevelConfiguration(); + + public A withPriorityLevelConfiguration( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference + priorityLevelConfiguration); + public java.lang.Boolean hasPriorityLevelConfiguration(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.PriorityLevelConfigurationNested withNewPriorityLevelConfiguration(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.PriorityLevelConfigurationNested withNewPriorityLevelConfigurationLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference item); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.PriorityLevelConfigurationNested editPriorityLevelConfiguration(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.PriorityLevelConfigurationNested editOrNewPriorityLevelConfiguration(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.PriorityLevelConfigurationNested editOrNewPriorityLevelConfigurationLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference item); - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item); - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + withNewPriorityLevelConfiguration(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + withNewPriorityLevelConfigurationLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + editPriorityLevelConfiguration(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + editOrNewPriorityLevelConfiguration(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + editOrNewPriorityLevelConfigurationLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference item); + + public A addToRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item); + + public A setToRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item); + public A addToRules(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects... items); - public A addAllToRules(java.util.Collection items); - public A removeFromRules(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects... items); - public A removeAllFromRules(java.util.Collection items); - public A removeMatchingFromRules(java.util.function.Predicate predicate); - + + public A addAllToRules( + java.util.Collection + items); + + public A removeFromRules( + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects... items); + + public A removeAllFromRules( + java.util.Collection + items); + + public A removeMatchingFromRules( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder> + predicate); + /** * This method has been deprecated, please use method buildRules instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getRules(); - public java.util.List buildRules(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects buildRule(java.lang.Integer index); + public java.util.List + getRules(); + + public java.util.List + buildRules(); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects buildRule( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects buildFirstRule(); + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects buildLastRule(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects buildMatchingRule(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate); - public A withRules(java.util.List rules); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects buildMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder> + predicate); + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder> + predicate); + + public A withRules( + java.util.List rules); + public A withRules(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects... rules); + public java.lang.Boolean hasRules(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested addNewRule(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested editRule(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested editFirstRule(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested editLastRule(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate); - public interface DistinguisherMethodNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested + addNewRule(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested + addNewRuleLike(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested + setNewRuleLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested editRule( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested + editFirstRule(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested + editLastRule(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested + editMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder> + predicate); + + public interface DistinguisherMethodNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluent< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .DistinguisherMethodNested< + N>> { public N and(); + public N endDistinguisherMethod(); - } - public interface PriorityLevelConfigurationNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent>{ + + public interface PriorityLevelConfigurationNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + N>> { public N and(); + public N endPriorityLevelConfiguration(); - } - public interface RulesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent>{ + + public interface RulesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested> { public N and(); + public N endRule(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaSpecFluentImpl.java index b370d33754..51cbb6f913 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaSpecFluentImpl.java @@ -1,25 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta1FlowSchemaSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent{ - public V1beta1FlowSchemaSpecFluentImpl() { - } - public V1beta1FlowSchemaSpecFluentImpl(io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec instance) { + +/** Generated */ +public class V1beta1FlowSchemaSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent { + public V1beta1FlowSchemaSpecFluentImpl() {} + + public V1beta1FlowSchemaSpecFluentImpl( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpec instance) { this.withDistinguisherMethod(instance.getDistinguisherMethod()); this.withMatchingPrecedence(instance.getMatchingPrecedence()); @@ -27,258 +31,554 @@ public V1beta1FlowSchemaSpecFluentImpl(io.kubernetes.client.openapi.models.V1bet this.withPriorityLevelConfiguration(instance.getPriorityLevelConfiguration()); this.withRules(instance.getRules()); - } - private io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodBuilder distinguisherMethod; + + private io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodBuilder + distinguisherMethod; private java.lang.Integer matchingPrecedence; - private io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceBuilder priorityLevelConfiguration; - private java.util.ArrayList rules; - + private io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceBuilder + priorityLevelConfiguration; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder> + rules; + /** * This method has been deprecated, please use method buildDistinguisherMethod instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod getDistinguisherMethod() { - return this.distinguisherMethod!=null ?this.distinguisherMethod.build():null; + public io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod + getDistinguisherMethod() { + return this.distinguisherMethod != null ? this.distinguisherMethod.build() : null; } - public io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod buildDistinguisherMethod() { - return this.distinguisherMethod!=null ?this.distinguisherMethod.build():null; + + public io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod + buildDistinguisherMethod() { + return this.distinguisherMethod != null ? this.distinguisherMethod.build() : null; } - public A withDistinguisherMethod(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod distinguisherMethod) { + + public A withDistinguisherMethod( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod distinguisherMethod) { _visitables.get("distinguisherMethod").remove(this.distinguisherMethod); - if (distinguisherMethod!=null){ this.distinguisherMethod= new io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodBuilder(distinguisherMethod); _visitables.get("distinguisherMethod").add(this.distinguisherMethod);} return (A) this; + if (distinguisherMethod != null) { + this.distinguisherMethod = + new io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodBuilder( + distinguisherMethod); + _visitables.get("distinguisherMethod").add(this.distinguisherMethod); + } + return (A) this; } + public java.lang.Boolean hasDistinguisherMethod() { return this.distinguisherMethod != null; } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested withNewDistinguisherMethod() { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl.DistinguisherMethodNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + withNewDistinguisherMethod() { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl + .DistinguisherMethodNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested withNewDistinguisherMethodLike(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod item) { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl.DistinguisherMethodNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + withNewDistinguisherMethodLike( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod item) { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl + .DistinguisherMethodNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested editDistinguisherMethod() { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + editDistinguisherMethod() { return withNewDistinguisherMethodLike(getDistinguisherMethod()); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested editOrNewDistinguisherMethod() { - return withNewDistinguisherMethodLike(getDistinguisherMethod() != null ? getDistinguisherMethod(): new io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + editOrNewDistinguisherMethod() { + return withNewDistinguisherMethodLike( + getDistinguisherMethod() != null + ? getDistinguisherMethod() + : new io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested editOrNewDistinguisherMethodLike(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod item) { - return withNewDistinguisherMethodLike(getDistinguisherMethod() != null ? getDistinguisherMethod(): item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + editOrNewDistinguisherMethodLike( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod item) { + return withNewDistinguisherMethodLike( + getDistinguisherMethod() != null ? getDistinguisherMethod() : item); } + public java.lang.Integer getMatchingPrecedence() { return this.matchingPrecedence; } + public A withMatchingPrecedence(java.lang.Integer matchingPrecedence) { - this.matchingPrecedence=matchingPrecedence; return (A) this; + this.matchingPrecedence = matchingPrecedence; + return (A) this; } + public java.lang.Boolean hasMatchingPrecedence() { return this.matchingPrecedence != null; } - + /** * This method has been deprecated, please use method buildPriorityLevelConfiguration instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference getPriorityLevelConfiguration() { - return this.priorityLevelConfiguration!=null ?this.priorityLevelConfiguration.build():null; + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference + getPriorityLevelConfiguration() { + return this.priorityLevelConfiguration != null ? this.priorityLevelConfiguration.build() : null; } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference buildPriorityLevelConfiguration() { - return this.priorityLevelConfiguration!=null ?this.priorityLevelConfiguration.build():null; + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference + buildPriorityLevelConfiguration() { + return this.priorityLevelConfiguration != null ? this.priorityLevelConfiguration.build() : null; } - public A withPriorityLevelConfiguration(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference priorityLevelConfiguration) { + + public A withPriorityLevelConfiguration( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference + priorityLevelConfiguration) { _visitables.get("priorityLevelConfiguration").remove(this.priorityLevelConfiguration); - if (priorityLevelConfiguration!=null){ this.priorityLevelConfiguration= new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceBuilder(priorityLevelConfiguration); _visitables.get("priorityLevelConfiguration").add(this.priorityLevelConfiguration);} return (A) this; + if (priorityLevelConfiguration != null) { + this.priorityLevelConfiguration = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceBuilder( + priorityLevelConfiguration); + _visitables.get("priorityLevelConfiguration").add(this.priorityLevelConfiguration); + } + return (A) this; } + public java.lang.Boolean hasPriorityLevelConfiguration() { return this.priorityLevelConfiguration != null; } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.PriorityLevelConfigurationNested withNewPriorityLevelConfiguration() { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl.PriorityLevelConfigurationNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + withNewPriorityLevelConfiguration() { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl + .PriorityLevelConfigurationNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.PriorityLevelConfigurationNested withNewPriorityLevelConfigurationLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference item) { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl.PriorityLevelConfigurationNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + withNewPriorityLevelConfigurationLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference item) { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl + .PriorityLevelConfigurationNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.PriorityLevelConfigurationNested editPriorityLevelConfiguration() { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + editPriorityLevelConfiguration() { return withNewPriorityLevelConfigurationLike(getPriorityLevelConfiguration()); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.PriorityLevelConfigurationNested editOrNewPriorityLevelConfiguration() { - return withNewPriorityLevelConfigurationLike(getPriorityLevelConfiguration() != null ? getPriorityLevelConfiguration(): new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + editOrNewPriorityLevelConfiguration() { + return withNewPriorityLevelConfigurationLike( + getPriorityLevelConfiguration() != null + ? getPriorityLevelConfiguration() + : new io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.PriorityLevelConfigurationNested editOrNewPriorityLevelConfigurationLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference item) { - return withNewPriorityLevelConfigurationLike(getPriorityLevelConfiguration() != null ? getPriorityLevelConfiguration(): item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + editOrNewPriorityLevelConfigurationLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference item) { + return withNewPriorityLevelConfigurationLike( + getPriorityLevelConfiguration() != null ? getPriorityLevelConfiguration() : item); } - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(item);_visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder);this.rules.add(index >= 0 ? index : rules.size(), builder); return (A)this; + + public A addToRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(item); + _visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder); + this.rules.add(index >= 0 ? index : rules.size(), builder); + return (A) this; } - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(item); - if (index < 0 || index >= _visitables.get("rules").size()) { _visitables.get("rules").add(builder); } else { _visitables.get("rules").set(index, builder);} - if (index < 0 || index >= rules.size()) { rules.add(builder); } else { rules.set(index, builder);} - return (A)this; + + public A setToRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(item); + if (index < 0 || index >= _visitables.get("rules").size()) { + _visitables.get("rules").add(builder); + } else { + _visitables.get("rules").set(index, builder); + } + if (index < 0 || index >= rules.size()) { + rules.add(builder); + } else { + rules.set(index, builder); + } + return (A) this; } + public A addToRules(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects... items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item : items) {io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item : items) { + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } - public A addAllToRules(java.util.Collection items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item : items) {io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + + public A addAllToRules( + java.util.Collection + items) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item : items) { + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } - public A removeFromRules(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects... items) { - for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item : items) {io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + + public A removeFromRules( + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects... items) { + for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item : items) { + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeAllFromRules(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item : items) {io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + + public A removeAllFromRules( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item : items) { + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromRules(java.util.function.Predicate predicate) { + + public A removeMatchingFromRules( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder> + predicate) { if (rules == null) return (A) this; - final Iterator each = rules.iterator(); + final Iterator each = + rules.iterator(); final List visitables = _visitables.get("rules"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildRules instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getRules() { + public java.util.List + getRules() { return rules != null ? build(rules) : null; } - public java.util.List buildRules() { + + public java.util.List + buildRules() { return rules != null ? build(rules) : null; } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects buildRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects buildRule( + java.lang.Integer index) { return this.rules.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects buildFirstRule() { return this.rules.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects buildLastRule() { return this.rules.get(rules.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects buildMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder item: rules) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects buildMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder item : rules) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder item: rules) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder item : rules) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withRules(java.util.List rules) { - if (this.rules != null) { _visitables.get("rules").removeAll(this.rules);} - if (rules != null) {this.rules = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item : rules){this.addToRules(item);}} else { this.rules = null;} return (A) this; + + public A withRules( + java.util.List rules) { + if (this.rules != null) { + _visitables.get("rules").removeAll(this.rules); + } + if (rules != null) { + this.rules = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item : rules) { + this.addToRules(item); + } + } else { + this.rules = null; + } + return (A) this; } + public A withRules(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects... rules) { - if (this.rules != null) {this.rules.clear();} - if (rules != null) {for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item :rules){ this.addToRules(item);}} return (A) this; + if (this.rules != null) { + this.rules.clear(); + } + if (rules != null) { + for (io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item : rules) { + this.addToRules(item); + } + } + return (A) this; } + public java.lang.Boolean hasRules() { return rules != null && !rules.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested addNewRule() { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl.RulesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested + addNewRule() { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl + .RulesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item) { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl.RulesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested + addNewRuleLike(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item) { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl.RulesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item) { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl.RulesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested + setNewRuleLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item) { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluentImpl.RulesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested editRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested editRule( + java.lang.Integer index) { if (rules.size() <= index) throw new RuntimeException("Can't edit rules. Index exceeds size."); return setNewRuleLike(index, buildRule(index)); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested editFirstRule() { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested + editFirstRule() { if (rules.size() == 0) throw new RuntimeException("Can't edit first rules. The list is empty."); return setNewRuleLike(0, buildRule(0)); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested editLastRule() { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested + editLastRule() { int index = rules.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last rules. The list is empty."); return setNewRuleLike(index, buildRule(index)); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested + editMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested,io.kubernetes.client.fluent.Nested{ - DistinguisherMethodNestedImpl(io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodBuilder(this, item); + + public class DistinguisherMethodNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.DistinguisherMethodNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .DistinguisherMethodNested< + N>, + io.kubernetes.client.fluent.Nested { + DistinguisherMethodNestedImpl( + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethod item) { + this.builder = + new io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodBuilder(this, item); } + DistinguisherMethodNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1FlowDistinguisherMethodBuilder builder; + public N and() { return (N) V1beta1FlowSchemaSpecFluentImpl.this.withDistinguisherMethod(builder.build()); } + public N endDistinguisherMethod() { return and(); } - } - public class PriorityLevelConfigurationNestedImpl extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.PriorityLevelConfigurationNested,io.kubernetes.client.fluent.Nested{ - PriorityLevelConfigurationNestedImpl(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceBuilder(this, item); + + public class PriorityLevelConfigurationNestedImpl + extends io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + N>, + io.kubernetes.client.fluent.Nested { + PriorityLevelConfigurationNestedImpl( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference item) { + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceBuilder( + this, item); } + PriorityLevelConfigurationNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceBuilder( + this); } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceBuilder builder; + public N and() { - return (N) V1beta1FlowSchemaSpecFluentImpl.this.withPriorityLevelConfiguration(builder.build()); + return (N) + V1beta1FlowSchemaSpecFluentImpl.this.withPriorityLevelConfiguration(builder.build()); } + public N endPriorityLevelConfiguration() { return and(); } - } - public class RulesNestedImpl extends io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested,io.kubernetes.client.fluent.Nested{ - RulesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item) { + + public class RulesNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested> + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaSpecFluent.RulesNested, + io.kubernetes.client.fluent.Nested { + RulesNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(this, item); } + RulesNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1FlowSchemaSpecFluentImpl.this.setToRules(index,builder.build()); + return (N) V1beta1FlowSchemaSpecFluentImpl.this.setToRules(index, builder.build()); } + public N endRule() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaStatusBuilder.java index 98a653556c..2bd4912cf4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaStatusBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1FlowSchemaStatusBuilder extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1FlowSchemaStatusBuilder + extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusBuilder> { public V1beta1FlowSchemaStatusBuilder() { this(false); } + public V1beta1FlowSchemaStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1FlowSchemaStatus(), validationEnabled); } - public V1beta1FlowSchemaStatusBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent fluent) { + + public V1beta1FlowSchemaStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent fluent) { this(fluent, false); } - public V1beta1FlowSchemaStatusBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1FlowSchemaStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1FlowSchemaStatus(), validationEnabled); } - public V1beta1FlowSchemaStatusBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent fluent,io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus instance) { + + public V1beta1FlowSchemaStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus instance) { this(fluent, instance, false); } - public V1beta1FlowSchemaStatusBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent fluent,io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1FlowSchemaStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent fluent, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditions(instance.getConditions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1FlowSchemaStatusBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus instance) { - this(instance,false); + + public V1beta1FlowSchemaStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus instance) { + this(instance, false); } - public V1beta1FlowSchemaStatusBuilder(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1FlowSchemaStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditions(instance.getConditions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus build() { V1beta1FlowSchemaStatus buildable = new V1beta1FlowSchemaStatus(); buildable.setConditions(fluent.getConditions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1FlowSchemaStatusBuilder that = (V1beta1FlowSchemaStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaStatusFluent.java index c26057c4f2..65ca80357c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaStatusFluent.java @@ -1,57 +1,113 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1FlowSchemaStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item); +/** Generated */ +public interface V1beta1FlowSchemaStatusFluent< + A extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition... items); - public A addAllToConditions(java.util.Collection items); - public A removeFromConditions(io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A addAllToConditions( + java.util.Collection items); + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition... items); + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder> + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition buildCondition(java.lang.Integer index); + public java.util.List + getConditions(); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition buildCondition( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); - public A withConditions(io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition... conditions); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder> + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder> + predicate); + + public A withConditions( + java.util.List conditions); + + public A withConditions( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder> + predicate); + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluent< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaStatusFluentImpl.java index f335c7d525..fd63ce817f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1FlowSchemaStatusFluentImpl.java @@ -1,57 +1,140 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1beta1FlowSchemaStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent{ - public V1beta1FlowSchemaStatusFluentImpl() { - } - public V1beta1FlowSchemaStatusFluentImpl(io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus instance) { - this.withConditions(instance.getConditions()); +/** Generated */ +public class V1beta1FlowSchemaStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent { + public V1beta1FlowSchemaStatusFluentImpl() {} + public V1beta1FlowSchemaStatusFluentImpl( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatus instance) { + this.withConditions(instance.getConditions()); } - private java.util.ArrayList conditions; - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + private java.util.ArrayList + conditions; + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } - public A addToConditions(io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item : items) {io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addToConditions( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition... items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item : items) { + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item : items) {io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item : items) { + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition... items) { - for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item : items) {io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition... items) { + for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item : items) { + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item : items) {io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item : items) { + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder> + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder = each.next(); @@ -60,104 +143,194 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { + public java.util.List + getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } - public A withConditions(io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item :conditions){ this.addToConditions(item);}} return (A) this; + + public A withConditions( + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition... conditions) { + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item) { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item) { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item) { - return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item) { + return new io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionFluentImpl< + io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1beta1FlowSchemaStatusFluent.ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1FlowSchemaCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1FlowSchemaConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1FlowSchemaStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1beta1FlowSchemaStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ForZoneBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ForZoneBuilder.java index 6b00efc85e..a7ed2273f5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ForZoneBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ForZoneBuilder.java @@ -1,58 +1,95 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1ForZoneBuilder extends io.kubernetes.client.openapi.models.V1beta1ForZoneFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1ForZoneBuilder + extends io.kubernetes.client.openapi.models.V1beta1ForZoneFluentImpl< + io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1ForZone, + io.kubernetes.client.openapi.models.V1beta1ForZoneBuilder> { public V1beta1ForZoneBuilder() { this(false); } + public V1beta1ForZoneBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1ForZone(), validationEnabled); } + public V1beta1ForZoneBuilder(io.kubernetes.client.openapi.models.V1beta1ForZoneFluent fluent) { this(fluent, false); } - public V1beta1ForZoneBuilder(io.kubernetes.client.openapi.models.V1beta1ForZoneFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1ForZoneBuilder( + io.kubernetes.client.openapi.models.V1beta1ForZoneFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1ForZone(), validationEnabled); } - public V1beta1ForZoneBuilder(io.kubernetes.client.openapi.models.V1beta1ForZoneFluent fluent,io.kubernetes.client.openapi.models.V1beta1ForZone instance) { + + public V1beta1ForZoneBuilder( + io.kubernetes.client.openapi.models.V1beta1ForZoneFluent fluent, + io.kubernetes.client.openapi.models.V1beta1ForZone instance) { this(fluent, instance, false); } - public V1beta1ForZoneBuilder(io.kubernetes.client.openapi.models.V1beta1ForZoneFluent fluent,io.kubernetes.client.openapi.models.V1beta1ForZone instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1ForZoneBuilder( + io.kubernetes.client.openapi.models.V1beta1ForZoneFluent fluent, + io.kubernetes.client.openapi.models.V1beta1ForZone instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1beta1ForZoneBuilder(io.kubernetes.client.openapi.models.V1beta1ForZone instance) { - this(instance,false); + this(instance, false); } - public V1beta1ForZoneBuilder(io.kubernetes.client.openapi.models.V1beta1ForZone instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1ForZoneBuilder( + io.kubernetes.client.openapi.models.V1beta1ForZone instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1ForZoneFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1ForZone build() { V1beta1ForZone buildable = new V1beta1ForZone(); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1ForZoneBuilder that = (V1beta1ForZoneBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ForZoneFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ForZoneFluent.java index 81963b892c..2ea30fb725 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ForZoneFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ForZoneFluent.java @@ -1,23 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1ForZoneFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1ForZoneFluent< + A extends io.kubernetes.client.openapi.models.V1beta1ForZoneFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ForZoneFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ForZoneFluentImpl.java index 75ff776390..27e93c06e4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ForZoneFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ForZoneFluentImpl.java @@ -1,48 +1,58 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta1ForZoneFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1ForZoneFluent{ - public V1beta1ForZoneFluentImpl() { - } +/** Generated */ +public class V1beta1ForZoneFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1ForZoneFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1ForZoneFluent { + public V1beta1ForZoneFluentImpl() {} + public V1beta1ForZoneFluentImpl(io.kubernetes.client.openapi.models.V1beta1ForZone instance) { this.withName(instance.getName()); - } + private java.lang.String name; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1ForZoneFluentImpl that = (V1beta1ForZoneFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, super.hashCode()); + return java.util.Objects.hash(name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1GroupSubjectBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1GroupSubjectBuilder.java index a4ee3b4770..b049f1dff4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1GroupSubjectBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1GroupSubjectBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1GroupSubjectBuilder extends io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1GroupSubjectBuilder + extends io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta1GroupSubjectBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1GroupSubject, + io.kubernetes.client.openapi.models.V1beta1GroupSubjectBuilder> { public V1beta1GroupSubjectBuilder() { this(false); } + public V1beta1GroupSubjectBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1GroupSubject(), validationEnabled); } - public V1beta1GroupSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent fluent) { + + public V1beta1GroupSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent fluent) { this(fluent, false); } - public V1beta1GroupSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1GroupSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1GroupSubject(), validationEnabled); } - public V1beta1GroupSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta1GroupSubject instance) { + + public V1beta1GroupSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta1GroupSubject instance) { this(fluent, instance, false); } - public V1beta1GroupSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta1GroupSubject instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1GroupSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta1GroupSubject instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1GroupSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1GroupSubject instance) { - this(instance,false); + + public V1beta1GroupSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1GroupSubject instance) { + this(instance, false); } - public V1beta1GroupSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1GroupSubject instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1GroupSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1GroupSubject instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1GroupSubject build() { V1beta1GroupSubject buildable = new V1beta1GroupSubject(); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1GroupSubjectBuilder that = (V1beta1GroupSubjectBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1GroupSubjectFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1GroupSubjectFluent.java index 7691baeafc..bd662a7976 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1GroupSubjectFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1GroupSubjectFluent.java @@ -1,23 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1GroupSubjectFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1GroupSubjectFluent< + A extends io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1GroupSubjectFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1GroupSubjectFluentImpl.java index c98d74692b..e933b88425 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1GroupSubjectFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1GroupSubjectFluentImpl.java @@ -1,48 +1,59 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta1GroupSubjectFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent{ - public V1beta1GroupSubjectFluentImpl() { - } - public V1beta1GroupSubjectFluentImpl(io.kubernetes.client.openapi.models.V1beta1GroupSubject instance) { - this.withName(instance.getName()); +/** Generated */ +public class V1beta1GroupSubjectFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent { + public V1beta1GroupSubjectFluentImpl() {} + public V1beta1GroupSubjectFluentImpl( + io.kubernetes.client.openapi.models.V1beta1GroupSubject instance) { + this.withName(instance.getName()); } + private java.lang.String name; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1GroupSubjectFluentImpl that = (V1beta1GroupSubjectFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, super.hashCode()); + return java.util.Objects.hash(name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1HostPortRangeBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1HostPortRangeBuilder.java index 343d756803..b94c10e158 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1HostPortRangeBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1HostPortRangeBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1HostPortRangeBuilder extends io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1HostPortRangeBuilder + extends io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluentImpl< + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1HostPortRange, + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder> { public V1beta1HostPortRangeBuilder() { this(false); } + public V1beta1HostPortRangeBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1HostPortRange(), validationEnabled); } - public V1beta1HostPortRangeBuilder(io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent fluent) { + + public V1beta1HostPortRangeBuilder( + io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent fluent) { this(fluent, false); } - public V1beta1HostPortRangeBuilder(io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1HostPortRangeBuilder( + io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1HostPortRange(), validationEnabled); } - public V1beta1HostPortRangeBuilder(io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent fluent,io.kubernetes.client.openapi.models.V1beta1HostPortRange instance) { + + public V1beta1HostPortRangeBuilder( + io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent fluent, + io.kubernetes.client.openapi.models.V1beta1HostPortRange instance) { this(fluent, instance, false); } - public V1beta1HostPortRangeBuilder(io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent fluent,io.kubernetes.client.openapi.models.V1beta1HostPortRange instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1HostPortRangeBuilder( + io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent fluent, + io.kubernetes.client.openapi.models.V1beta1HostPortRange instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMax(instance.getMax()); fluent.withMin(instance.getMin()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1HostPortRangeBuilder(io.kubernetes.client.openapi.models.V1beta1HostPortRange instance) { - this(instance,false); + + public V1beta1HostPortRangeBuilder( + io.kubernetes.client.openapi.models.V1beta1HostPortRange instance) { + this(instance, false); } - public V1beta1HostPortRangeBuilder(io.kubernetes.client.openapi.models.V1beta1HostPortRange instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1HostPortRangeBuilder( + io.kubernetes.client.openapi.models.V1beta1HostPortRange instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMax(instance.getMax()); this.withMin(instance.getMin()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1HostPortRange build() { V1beta1HostPortRange buildable = new V1beta1HostPortRange(); buildable.setMax(fluent.getMax()); buildable.setMin(fluent.getMin()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1HostPortRangeBuilder that = (V1beta1HostPortRangeBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1HostPortRangeFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1HostPortRangeFluent.java index 8c2707d681..e91c2ce6f6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1HostPortRangeFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1HostPortRangeFluent.java @@ -1,20 +1,30 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1HostPortRangeFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1HostPortRangeFluent< + A extends io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getMax(); + public A withMax(java.lang.Integer max); + public java.lang.Boolean hasMax(); + public java.lang.Integer getMin(); + public A withMin(java.lang.Integer min); + public java.lang.Boolean hasMin(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1HostPortRangeFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1HostPortRangeFluentImpl.java index ab4682efd4..a78ba77c0a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1HostPortRangeFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1HostPortRangeFluentImpl.java @@ -1,52 +1,70 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1HostPortRangeFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent { + public V1beta1HostPortRangeFluentImpl() {} - /** - * Generated - */ -public class V1beta1HostPortRangeFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent{ - public V1beta1HostPortRangeFluentImpl() { - } - public V1beta1HostPortRangeFluentImpl(io.kubernetes.client.openapi.models.V1beta1HostPortRange instance) { + public V1beta1HostPortRangeFluentImpl( + io.kubernetes.client.openapi.models.V1beta1HostPortRange instance) { this.withMax(instance.getMax()); this.withMin(instance.getMin()); - } + private java.lang.Integer max; private java.lang.Integer min; + public java.lang.Integer getMax() { return this.max; } + public A withMax(java.lang.Integer max) { - this.max=max; return (A) this; + this.max = max; + return (A) this; } + public java.lang.Boolean hasMax() { return this.max != null; } + public java.lang.Integer getMin() { return this.min; } + public A withMin(java.lang.Integer min) { - this.min=min; return (A) this; + this.min = min; + return (A) this; } + public java.lang.Boolean hasMin() { return this.min != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1HostPortRangeFluentImpl that = (V1beta1HostPortRangeFluentImpl) o; - if (max != null ? !max.equals(that.max) :that.max != null) return false; - if (min != null ? !min.equals(that.min) :that.min != null) return false; + if (max != null ? !max.equals(that.max) : that.max != null) return false; + if (min != null ? !min.equals(that.min) : that.min != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(max, min, super.hashCode()); + return java.util.Objects.hash(max, min, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1IDRangeBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1IDRangeBuilder.java index 72ea1f7df4..de07c902bb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1IDRangeBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1IDRangeBuilder.java @@ -1,63 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1IDRangeBuilder extends io.kubernetes.client.openapi.models.V1beta1IDRangeFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1IDRangeBuilder + extends io.kubernetes.client.openapi.models.V1beta1IDRangeFluentImpl< + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1IDRange, + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder> { public V1beta1IDRangeBuilder() { this(false); } + public V1beta1IDRangeBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1IDRange(), validationEnabled); } + public V1beta1IDRangeBuilder(io.kubernetes.client.openapi.models.V1beta1IDRangeFluent fluent) { this(fluent, false); } - public V1beta1IDRangeBuilder(io.kubernetes.client.openapi.models.V1beta1IDRangeFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1IDRangeBuilder( + io.kubernetes.client.openapi.models.V1beta1IDRangeFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1IDRange(), validationEnabled); } - public V1beta1IDRangeBuilder(io.kubernetes.client.openapi.models.V1beta1IDRangeFluent fluent,io.kubernetes.client.openapi.models.V1beta1IDRange instance) { + + public V1beta1IDRangeBuilder( + io.kubernetes.client.openapi.models.V1beta1IDRangeFluent fluent, + io.kubernetes.client.openapi.models.V1beta1IDRange instance) { this(fluent, instance, false); } - public V1beta1IDRangeBuilder(io.kubernetes.client.openapi.models.V1beta1IDRangeFluent fluent,io.kubernetes.client.openapi.models.V1beta1IDRange instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1IDRangeBuilder( + io.kubernetes.client.openapi.models.V1beta1IDRangeFluent fluent, + io.kubernetes.client.openapi.models.V1beta1IDRange instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMax(instance.getMax()); fluent.withMin(instance.getMin()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1beta1IDRangeBuilder(io.kubernetes.client.openapi.models.V1beta1IDRange instance) { - this(instance,false); + this(instance, false); } - public V1beta1IDRangeBuilder(io.kubernetes.client.openapi.models.V1beta1IDRange instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1IDRangeBuilder( + io.kubernetes.client.openapi.models.V1beta1IDRange instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMax(instance.getMax()); this.withMin(instance.getMin()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1IDRangeFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1IDRange build() { V1beta1IDRange buildable = new V1beta1IDRange(); buildable.setMax(fluent.getMax()); buildable.setMin(fluent.getMin()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1IDRangeBuilder that = (V1beta1IDRangeBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1IDRangeFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1IDRangeFluent.java index 16f21510a1..f6e701e3c5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1IDRangeFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1IDRangeFluent.java @@ -1,20 +1,30 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Long; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1IDRangeFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1IDRangeFluent< + A extends io.kubernetes.client.openapi.models.V1beta1IDRangeFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Long getMax(); + public A withMax(java.lang.Long max); + public java.lang.Boolean hasMax(); + public java.lang.Long getMin(); + public A withMin(java.lang.Long min); + public java.lang.Boolean hasMin(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1IDRangeFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1IDRangeFluentImpl.java index a1fc467725..3829d627d0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1IDRangeFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1IDRangeFluentImpl.java @@ -1,52 +1,69 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Long; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1IDRangeFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1IDRangeFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1IDRangeFluent { + public V1beta1IDRangeFluentImpl() {} - /** - * Generated - */ -public class V1beta1IDRangeFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1IDRangeFluent{ - public V1beta1IDRangeFluentImpl() { - } public V1beta1IDRangeFluentImpl(io.kubernetes.client.openapi.models.V1beta1IDRange instance) { this.withMax(instance.getMax()); this.withMin(instance.getMin()); - } + private java.lang.Long max; private java.lang.Long min; + public java.lang.Long getMax() { return this.max; } + public A withMax(java.lang.Long max) { - this.max=max; return (A) this; + this.max = max; + return (A) this; } + public java.lang.Boolean hasMax() { return this.max != null; } + public java.lang.Long getMin() { return this.min; } + public A withMin(java.lang.Long min) { - this.min=min; return (A) this; + this.min = min; + return (A) this; } + public java.lang.Boolean hasMin() { return this.min != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1IDRangeFluentImpl that = (V1beta1IDRangeFluentImpl) o; - if (max != null ? !max.equals(that.max) :that.max != null) return false; - if (min != null ? !min.equals(that.min) :that.min != null) return false; + if (max != null ? !max.equals(that.max) : that.max != null) return false; + if (min != null ? !min.equals(that.min) : that.min != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(max, min, super.hashCode()); + return java.util.Objects.hash(max, min, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1JobTemplateSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1JobTemplateSpecBuilder.java index 2ac247275d..4513bae1ad 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1JobTemplateSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1JobTemplateSpecBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1JobTemplateSpecBuilder extends io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1JobTemplateSpecBuilder + extends io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec, + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecBuilder> { public V1beta1JobTemplateSpecBuilder() { this(false); } + public V1beta1JobTemplateSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1JobTemplateSpec(), validationEnabled); } - public V1beta1JobTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent fluent) { + + public V1beta1JobTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent fluent) { this(fluent, false); } - public V1beta1JobTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1JobTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1JobTemplateSpec(), validationEnabled); } - public V1beta1JobTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec instance) { + + public V1beta1JobTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec instance) { this(fluent, instance, false); } - public V1beta1JobTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1JobTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMetadata(instance.getMetadata()); fluent.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1JobTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec instance) { - this(instance,false); + + public V1beta1JobTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec instance) { + this(instance, false); } - public V1beta1JobTemplateSpecBuilder(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1JobTemplateSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec build() { V1beta1JobTemplateSpec buildable = new V1beta1JobTemplateSpec(); buildable.setMetadata(fluent.getMetadata()); buildable.setSpec(fluent.getSpec()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1JobTemplateSpecBuilder that = (V1beta1JobTemplateSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1JobTemplateSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1JobTemplateSpecFluent.java index 95d4753e8f..d3a7bbc505 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1JobTemplateSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1JobTemplateSpecFluent.java @@ -1,55 +1,94 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1JobTemplateSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1beta1JobTemplateSpecFluent< + A extends io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JobSpec getSpec(); + public io.kubernetes.client.openapi.models.V1JobSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1JobSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item); + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1JobSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1JobSpecFluent< + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested> { public N and(); + public N endSpec(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1JobTemplateSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1JobTemplateSpecFluentImpl.java index b9424dd240..78a3a14a21 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1JobTemplateSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1JobTemplateSpecFluentImpl.java @@ -1,135 +1,205 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1JobTemplateSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent { + public V1beta1JobTemplateSpecFluentImpl() {} - /** - * Generated - */ -public class V1beta1JobTemplateSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent{ - public V1beta1JobTemplateSpecFluentImpl() { - } - public V1beta1JobTemplateSpecFluentImpl(io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec instance) { + public V1beta1JobTemplateSpecFluentImpl( + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpec instance) { this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - } + private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1JobSpecBuilder spec; - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1JobSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1JobSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1JobSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1JobSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1JobSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item) { - return new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item) { + return new io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluentImpl.SpecNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1JobSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1JobSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1JobSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1JobTemplateSpecFluentImpl that = (V1beta1JobTemplateSpecFluentImpl) o; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(metadata, spec, super.hashCode()); + return java.util.Objects.hash(metadata, spec, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1beta1JobTemplateSpecFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1JobSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1JobSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1beta1JobTemplateSpecFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1JobSpec item) { this.builder = new io.kubernetes.client.openapi.models.V1JobSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1JobSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1JobSpecBuilder builder; + public N and() { return (N) V1beta1JobTemplateSpecFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitResponseBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitResponseBuilder.java index 865cecf29e..b4b7b9a463 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitResponseBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitResponseBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1LimitResponseBuilder extends io.kubernetes.client.openapi.models.V1beta1LimitResponseFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1LimitResponseBuilder + extends io.kubernetes.client.openapi.models.V1beta1LimitResponseFluentImpl< + io.kubernetes.client.openapi.models.V1beta1LimitResponseBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1LimitResponse, + io.kubernetes.client.openapi.models.V1beta1LimitResponseBuilder> { public V1beta1LimitResponseBuilder() { this(false); } + public V1beta1LimitResponseBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1LimitResponse(), validationEnabled); } - public V1beta1LimitResponseBuilder(io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent fluent) { + + public V1beta1LimitResponseBuilder( + io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent fluent) { this(fluent, false); } - public V1beta1LimitResponseBuilder(io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1LimitResponseBuilder( + io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1LimitResponse(), validationEnabled); } - public V1beta1LimitResponseBuilder(io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent fluent,io.kubernetes.client.openapi.models.V1beta1LimitResponse instance) { + + public V1beta1LimitResponseBuilder( + io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent fluent, + io.kubernetes.client.openapi.models.V1beta1LimitResponse instance) { this(fluent, instance, false); } - public V1beta1LimitResponseBuilder(io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent fluent,io.kubernetes.client.openapi.models.V1beta1LimitResponse instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1LimitResponseBuilder( + io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent fluent, + io.kubernetes.client.openapi.models.V1beta1LimitResponse instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withQueuing(instance.getQueuing()); fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1LimitResponseBuilder(io.kubernetes.client.openapi.models.V1beta1LimitResponse instance) { - this(instance,false); + + public V1beta1LimitResponseBuilder( + io.kubernetes.client.openapi.models.V1beta1LimitResponse instance) { + this(instance, false); } - public V1beta1LimitResponseBuilder(io.kubernetes.client.openapi.models.V1beta1LimitResponse instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1LimitResponseBuilder( + io.kubernetes.client.openapi.models.V1beta1LimitResponse instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withQueuing(instance.getQueuing()); this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1LimitResponse build() { V1beta1LimitResponse buildable = new V1beta1LimitResponse(); buildable.setQueuing(fluent.getQueuing()); buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1LimitResponseBuilder that = (V1beta1LimitResponseBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitResponseFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitResponseFluent.java index a223dd8189..f5789cd537 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitResponseFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitResponseFluent.java @@ -1,44 +1,67 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1LimitResponseFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1beta1LimitResponseFluent< + A extends io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildQueuing instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration getQueuing(); + public io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration buildQueuing(); + public A withQueuing(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration queuing); + public java.lang.Boolean hasQueuing(); - public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested withNewQueuing(); - public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested withNewQueuingLike(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration item); - public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested editQueuing(); - public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested editOrNewQueuing(); - public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested editOrNewQueuingLike(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration item); + + public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested + withNewQueuing(); + + public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested + withNewQueuingLike(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration item); + + public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested + editQueuing(); + + public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested + editOrNewQueuing(); + + public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested + editOrNewQueuingLike(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration item); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface QueuingNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent>{ + + public interface QueuingNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent< + io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested> { public N and(); + public N endQueuing(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitResponseFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitResponseFluentImpl.java index 9f373446b9..49b44ced72 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitResponseFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitResponseFluentImpl.java @@ -1,103 +1,147 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1LimitResponseFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent { + public V1beta1LimitResponseFluentImpl() {} - /** - * Generated - */ -public class V1beta1LimitResponseFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent{ - public V1beta1LimitResponseFluentImpl() { - } - public V1beta1LimitResponseFluentImpl(io.kubernetes.client.openapi.models.V1beta1LimitResponse instance) { + public V1beta1LimitResponseFluentImpl( + io.kubernetes.client.openapi.models.V1beta1LimitResponse instance) { this.withQueuing(instance.getQueuing()); this.withType(instance.getType()); - } + private io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationBuilder queuing; private java.lang.String type; - + /** * This method has been deprecated, please use method buildQueuing instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration getQueuing() { - return this.queuing!=null ?this.queuing.build():null; + return this.queuing != null ? this.queuing.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration buildQueuing() { - return this.queuing!=null ?this.queuing.build():null; + return this.queuing != null ? this.queuing.build() : null; } + public A withQueuing(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration queuing) { _visitables.get("queuing").remove(this.queuing); - if (queuing!=null){ this.queuing= new io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationBuilder(queuing); _visitables.get("queuing").add(this.queuing);} return (A) this; + if (queuing != null) { + this.queuing = + new io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationBuilder(queuing); + _visitables.get("queuing").add(this.queuing); + } + return (A) this; } + public java.lang.Boolean hasQueuing() { return this.queuing != null; } - public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested withNewQueuing() { - return new io.kubernetes.client.openapi.models.V1beta1LimitResponseFluentImpl.QueuingNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested + withNewQueuing() { + return new io.kubernetes.client.openapi.models.V1beta1LimitResponseFluentImpl + .QueuingNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested withNewQueuingLike(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration item) { - return new io.kubernetes.client.openapi.models.V1beta1LimitResponseFluentImpl.QueuingNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested + withNewQueuingLike(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration item) { + return new io.kubernetes.client.openapi.models.V1beta1LimitResponseFluentImpl.QueuingNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested editQueuing() { + + public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested + editQueuing() { return withNewQueuingLike(getQueuing()); } - public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested editOrNewQueuing() { - return withNewQueuingLike(getQueuing() != null ? getQueuing(): new io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested + editOrNewQueuing() { + return withNewQueuingLike( + getQueuing() != null + ? getQueuing() + : new io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested editOrNewQueuingLike(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration item) { - return withNewQueuingLike(getQueuing() != null ? getQueuing(): item); + + public io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested + editOrNewQueuingLike(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration item) { + return withNewQueuingLike(getQueuing() != null ? getQueuing() : item); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1LimitResponseFluentImpl that = (V1beta1LimitResponseFluentImpl) o; - if (queuing != null ? !queuing.equals(that.queuing) :that.queuing != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (queuing != null ? !queuing.equals(that.queuing) : that.queuing != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(queuing, type, super.hashCode()); + return java.util.Objects.hash(queuing, type, super.hashCode()); } - public class QueuingNestedImpl extends io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested,io.kubernetes.client.fluent.Nested{ + + public class QueuingNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested> + implements io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent.QueuingNested, + io.kubernetes.client.fluent.Nested { QueuingNestedImpl(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationBuilder(this, item); } + QueuingNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationBuilder builder; + public N and() { return (N) V1beta1LimitResponseFluentImpl.this.withQueuing(builder.build()); } + public N endQueuing() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitedPriorityLevelConfigurationBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitedPriorityLevelConfigurationBuilder.java index 519a9bc975..e20eb642f6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitedPriorityLevelConfigurationBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitedPriorityLevelConfigurationBuilder.java @@ -1,63 +1,105 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1LimitedPriorityLevelConfigurationBuilder extends io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1LimitedPriorityLevelConfigurationBuilder + extends io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration, + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationBuilder> { public V1beta1LimitedPriorityLevelConfigurationBuilder() { this(false); } + public V1beta1LimitedPriorityLevelConfigurationBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1LimitedPriorityLevelConfiguration(), validationEnabled); } - public V1beta1LimitedPriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent fluent) { + + public V1beta1LimitedPriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + fluent) { this(fluent, false); } - public V1beta1LimitedPriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1LimitedPriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1LimitedPriorityLevelConfiguration(), validationEnabled); } - public V1beta1LimitedPriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration instance) { + + public V1beta1LimitedPriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration instance) { this(fluent, instance, false); } - public V1beta1LimitedPriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1LimitedPriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAssuredConcurrencyShares(instance.getAssuredConcurrencyShares()); fluent.withLimitResponse(instance.getLimitResponse()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1LimitedPriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration instance) { - this(instance,false); + + public V1beta1LimitedPriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration instance) { + this(instance, false); } - public V1beta1LimitedPriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1LimitedPriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAssuredConcurrencyShares(instance.getAssuredConcurrencyShares()); this.withLimitResponse(instance.getLimitResponse()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration build() { - V1beta1LimitedPriorityLevelConfiguration buildable = new V1beta1LimitedPriorityLevelConfiguration(); + V1beta1LimitedPriorityLevelConfiguration buildable = + new V1beta1LimitedPriorityLevelConfiguration(); buildable.setAssuredConcurrencyShares(fluent.getAssuredConcurrencyShares()); buildable.setLimitResponse(fluent.getLimitResponse()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1beta1LimitedPriorityLevelConfigurationBuilder that = (V1beta1LimitedPriorityLevelConfigurationBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1beta1LimitedPriorityLevelConfigurationBuilder that = + (V1beta1LimitedPriorityLevelConfigurationBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitedPriorityLevelConfigurationFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitedPriorityLevelConfigurationFluent.java index a004b264b7..36e126e319 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitedPriorityLevelConfigurationFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitedPriorityLevelConfigurationFluent.java @@ -1,39 +1,76 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1LimitedPriorityLevelConfigurationFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1LimitedPriorityLevelConfigurationFluent< + A extends + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getAssuredConcurrencyShares(); + public A withAssuredConcurrencyShares(java.lang.Integer assuredConcurrencyShares); + public java.lang.Boolean hasAssuredConcurrencyShares(); - + /** * This method has been deprecated, please use method buildLimitResponse instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1LimitResponse getLimitResponse(); + public io.kubernetes.client.openapi.models.V1beta1LimitResponse buildLimitResponse(); - public A withLimitResponse(io.kubernetes.client.openapi.models.V1beta1LimitResponse limitResponse); + + public A withLimitResponse( + io.kubernetes.client.openapi.models.V1beta1LimitResponse limitResponse); + public java.lang.Boolean hasLimitResponse(); - public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent.LimitResponseNested withNewLimitResponse(); - public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent.LimitResponseNested withNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta1LimitResponse item); - public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent.LimitResponseNested editLimitResponse(); - public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent.LimitResponseNested editOrNewLimitResponse(); - public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent.LimitResponseNested editOrNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta1LimitResponse item); - public interface LimitResponseNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + withNewLimitResponse(); + + public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + withNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta1LimitResponse item); + + public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + editLimitResponse(); + + public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + editOrNewLimitResponse(); + + public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + editOrNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta1LimitResponse item); + + public interface LimitResponseNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1LimitResponseFluent< + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + N>> { public N and(); + public N endLimitResponse(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitedPriorityLevelConfigurationFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitedPriorityLevelConfigurationFluentImpl.java index 547ae19cad..da74de114f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitedPriorityLevelConfigurationFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1LimitedPriorityLevelConfigurationFluentImpl.java @@ -1,95 +1,164 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1LimitedPriorityLevelConfigurationFluentImpl< + A extends + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent< + A> { + public V1beta1LimitedPriorityLevelConfigurationFluentImpl() {} - /** - * Generated - */ -public class V1beta1LimitedPriorityLevelConfigurationFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent{ - public V1beta1LimitedPriorityLevelConfigurationFluentImpl() { - } - public V1beta1LimitedPriorityLevelConfigurationFluentImpl(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration instance) { + public V1beta1LimitedPriorityLevelConfigurationFluentImpl( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration instance) { this.withAssuredConcurrencyShares(instance.getAssuredConcurrencyShares()); this.withLimitResponse(instance.getLimitResponse()); - } + private java.lang.Integer assuredConcurrencyShares; private io.kubernetes.client.openapi.models.V1beta1LimitResponseBuilder limitResponse; + public java.lang.Integer getAssuredConcurrencyShares() { return this.assuredConcurrencyShares; } + public A withAssuredConcurrencyShares(java.lang.Integer assuredConcurrencyShares) { - this.assuredConcurrencyShares=assuredConcurrencyShares; return (A) this; + this.assuredConcurrencyShares = assuredConcurrencyShares; + return (A) this; } + public java.lang.Boolean hasAssuredConcurrencyShares() { return this.assuredConcurrencyShares != null; } - + /** * This method has been deprecated, please use method buildLimitResponse instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1LimitResponse getLimitResponse() { - return this.limitResponse!=null ?this.limitResponse.build():null; + return this.limitResponse != null ? this.limitResponse.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1LimitResponse buildLimitResponse() { - return this.limitResponse!=null ?this.limitResponse.build():null; + return this.limitResponse != null ? this.limitResponse.build() : null; } - public A withLimitResponse(io.kubernetes.client.openapi.models.V1beta1LimitResponse limitResponse) { + + public A withLimitResponse( + io.kubernetes.client.openapi.models.V1beta1LimitResponse limitResponse) { _visitables.get("limitResponse").remove(this.limitResponse); - if (limitResponse!=null){ this.limitResponse= new io.kubernetes.client.openapi.models.V1beta1LimitResponseBuilder(limitResponse); _visitables.get("limitResponse").add(this.limitResponse);} return (A) this; + if (limitResponse != null) { + this.limitResponse = + new io.kubernetes.client.openapi.models.V1beta1LimitResponseBuilder(limitResponse); + _visitables.get("limitResponse").add(this.limitResponse); + } + return (A) this; } + public java.lang.Boolean hasLimitResponse() { return this.limitResponse != null; } - public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent.LimitResponseNested withNewLimitResponse() { - return new io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluentImpl.LimitResponseNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + withNewLimitResponse() { + return new io.kubernetes.client.openapi.models + .V1beta1LimitedPriorityLevelConfigurationFluentImpl.LimitResponseNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent.LimitResponseNested withNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta1LimitResponse item) { - return new io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluentImpl.LimitResponseNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + withNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta1LimitResponse item) { + return new io.kubernetes.client.openapi.models + .V1beta1LimitedPriorityLevelConfigurationFluentImpl.LimitResponseNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent.LimitResponseNested editLimitResponse() { + + public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + editLimitResponse() { return withNewLimitResponseLike(getLimitResponse()); } - public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent.LimitResponseNested editOrNewLimitResponse() { - return withNewLimitResponseLike(getLimitResponse() != null ? getLimitResponse(): new io.kubernetes.client.openapi.models.V1beta1LimitResponseBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + editOrNewLimitResponse() { + return withNewLimitResponseLike( + getLimitResponse() != null + ? getLimitResponse() + : new io.kubernetes.client.openapi.models.V1beta1LimitResponseBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent.LimitResponseNested editOrNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta1LimitResponse item) { - return withNewLimitResponseLike(getLimitResponse() != null ? getLimitResponse(): item); + + public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + editOrNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta1LimitResponse item) { + return withNewLimitResponseLike(getLimitResponse() != null ? getLimitResponse() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta1LimitedPriorityLevelConfigurationFluentImpl that = (V1beta1LimitedPriorityLevelConfigurationFluentImpl) o; - if (assuredConcurrencyShares != null ? !assuredConcurrencyShares.equals(that.assuredConcurrencyShares) :that.assuredConcurrencyShares != null) return false; - if (limitResponse != null ? !limitResponse.equals(that.limitResponse) :that.limitResponse != null) return false; + V1beta1LimitedPriorityLevelConfigurationFluentImpl that = + (V1beta1LimitedPriorityLevelConfigurationFluentImpl) o; + if (assuredConcurrencyShares != null + ? !assuredConcurrencyShares.equals(that.assuredConcurrencyShares) + : that.assuredConcurrencyShares != null) return false; + if (limitResponse != null + ? !limitResponse.equals(that.limitResponse) + : that.limitResponse != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(assuredConcurrencyShares, limitResponse, super.hashCode()); + return java.util.Objects.hash(assuredConcurrencyShares, limitResponse, super.hashCode()); } - public class LimitResponseNestedImpl extends io.kubernetes.client.openapi.models.V1beta1LimitResponseFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent.LimitResponseNested,io.kubernetes.client.fluent.Nested{ + + public class LimitResponseNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1LimitResponseFluentImpl< + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + N>, + io.kubernetes.client.fluent.Nested { LimitResponseNestedImpl(io.kubernetes.client.openapi.models.V1beta1LimitResponse item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1LimitResponseBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1LimitResponseBuilder(this, item); } + LimitResponseNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta1LimitResponseBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1LimitResponseBuilder builder; + public N and() { - return (N) V1beta1LimitedPriorityLevelConfigurationFluentImpl.this.withLimitResponse(builder.build()); + return (N) + V1beta1LimitedPriorityLevelConfigurationFluentImpl.this.withLimitResponse( + builder.build()); } + public N endLimitResponse() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1NonResourcePolicyRuleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1NonResourcePolicyRuleBuilder.java index d90217cbd7..52bdaa090a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1NonResourcePolicyRuleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1NonResourcePolicyRuleBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1NonResourcePolicyRuleBuilder extends io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1NonResourcePolicyRuleBuilder + extends io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluentImpl< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule, + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder> { public V1beta1NonResourcePolicyRuleBuilder() { this(false); } + public V1beta1NonResourcePolicyRuleBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1NonResourcePolicyRule(), validationEnabled); } - public V1beta1NonResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent fluent) { + + public V1beta1NonResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent fluent) { this(fluent, false); } - public V1beta1NonResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1NonResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1NonResourcePolicyRule(), validationEnabled); } - public V1beta1NonResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent fluent,io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule instance) { + + public V1beta1NonResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent fluent, + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule instance) { this(fluent, instance, false); } - public V1beta1NonResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent fluent,io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1NonResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent fluent, + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNonResourceURLs(instance.getNonResourceURLs()); fluent.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1NonResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule instance) { - this(instance,false); + + public V1beta1NonResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule instance) { + this(instance, false); } - public V1beta1NonResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1NonResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNonResourceURLs(instance.getNonResourceURLs()); this.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule build() { V1beta1NonResourcePolicyRule buildable = new V1beta1NonResourcePolicyRule(); buildable.setNonResourceURLs(fluent.getNonResourceURLs()); buildable.setVerbs(fluent.getVerbs()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1NonResourcePolicyRuleBuilder that = (V1beta1NonResourcePolicyRuleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1NonResourcePolicyRuleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1NonResourcePolicyRuleFluent.java index c5760bb0a5..dc5acb7021 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1NonResourcePolicyRuleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1NonResourcePolicyRuleFluent.java @@ -1,50 +1,85 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1beta1NonResourcePolicyRuleFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToNonResourceURLs(java.lang.Integer index,java.lang.String item); - public A setToNonResourceURLs(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1beta1NonResourcePolicyRuleFluent< + A extends io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToNonResourceURLs(java.lang.Integer index, java.lang.String item); + + public A setToNonResourceURLs(java.lang.Integer index, java.lang.String item); + public A addToNonResourceURLs(java.lang.String... items); + public A addAllToNonResourceURLs(java.util.Collection items); + public A removeFromNonResourceURLs(java.lang.String... items); + public A removeAllFromNonResourceURLs(java.util.Collection items); + public java.util.List getNonResourceURLs(); + public java.lang.String getNonResourceURL(java.lang.Integer index); + public java.lang.String getFirstNonResourceURL(); + public java.lang.String getLastNonResourceURL(); - public java.lang.String getMatchingNonResourceURL(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingNonResourceURL(java.util.function.Predicate predicate); + + public java.lang.String getMatchingNonResourceURL( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingNonResourceURL( + java.util.function.Predicate predicate); + public A withNonResourceURLs(java.util.List nonResourceURLs); + public A withNonResourceURLs(java.lang.String... nonResourceURLs); + public java.lang.Boolean hasNonResourceURLs(); + public A addNewNonResourceURL(java.lang.String original); - public A addToVerbs(java.lang.Integer index,java.lang.String item); - public A setToVerbs(java.lang.Integer index,java.lang.String item); + + public A addToVerbs(java.lang.Integer index, java.lang.String item); + + public A setToVerbs(java.lang.Integer index, java.lang.String item); + public A addToVerbs(java.lang.String... items); + public A addAllToVerbs(java.util.Collection items); + public A removeFromVerbs(java.lang.String... items); + public A removeAllFromVerbs(java.util.Collection items); + public java.util.List getVerbs(); + public java.lang.String getVerb(java.lang.Integer index); + public java.lang.String getFirstVerb(); + public java.lang.String getLastVerb(); + public java.lang.String getMatchingVerb(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate); + public A withVerbs(java.util.List verbs); + public A withVerbs(java.lang.String... verbs); + public java.lang.Boolean hasVerbs(); + public A addNewVerb(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1NonResourcePolicyRuleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1NonResourcePolicyRuleFluentImpl.java index 3b3bc1fc3e..87db55e53b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1NonResourcePolicyRuleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1NonResourcePolicyRuleFluentImpl.java @@ -1,147 +1,290 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.ArrayList; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public class V1beta1NonResourcePolicyRuleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent{ - public V1beta1NonResourcePolicyRuleFluentImpl() { - } - public V1beta1NonResourcePolicyRuleFluentImpl(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule instance) { +/** Generated */ +public class V1beta1NonResourcePolicyRuleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent { + public V1beta1NonResourcePolicyRuleFluentImpl() {} + + public V1beta1NonResourcePolicyRuleFluentImpl( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule instance) { this.withNonResourceURLs(instance.getNonResourceURLs()); this.withVerbs(instance.getVerbs()); - } + private java.util.List nonResourceURLs; private java.util.List verbs; - public A addToNonResourceURLs(java.lang.Integer index,java.lang.String item) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} + + public A addToNonResourceURLs(java.lang.Integer index, java.lang.String item) { + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } this.nonResourceURLs.add(index, item); - return (A)this; + return (A) this; } - public A setToNonResourceURLs(java.lang.Integer index,java.lang.String item) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} - this.nonResourceURLs.set(index, item); return (A)this; + + public A setToNonResourceURLs(java.lang.Integer index, java.lang.String item) { + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } + this.nonResourceURLs.set(index, item); + return (A) this; } + public A addToNonResourceURLs(java.lang.String... items) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.nonResourceURLs.add(item);} return (A)this; + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.nonResourceURLs.add(item); + } + return (A) this; } + public A addAllToNonResourceURLs(java.util.Collection items) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.nonResourceURLs.add(item);} return (A)this; + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.nonResourceURLs.add(item); + } + return (A) this; } + public A removeFromNonResourceURLs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.nonResourceURLs!= null){ this.nonResourceURLs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.nonResourceURLs != null) { + this.nonResourceURLs.remove(item); + } + } + return (A) this; } + public A removeAllFromNonResourceURLs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.nonResourceURLs!= null){ this.nonResourceURLs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.nonResourceURLs != null) { + this.nonResourceURLs.remove(item); + } + } + return (A) this; } + public java.util.List getNonResourceURLs() { return this.nonResourceURLs; } + public java.lang.String getNonResourceURL(java.lang.Integer index) { return this.nonResourceURLs.get(index); } + public java.lang.String getFirstNonResourceURL() { return this.nonResourceURLs.get(0); } + public java.lang.String getLastNonResourceURL() { return this.nonResourceURLs.get(nonResourceURLs.size() - 1); } - public java.lang.String getMatchingNonResourceURL(java.util.function.Predicate predicate) { - for (java.lang.String item: nonResourceURLs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingNonResourceURL( + java.util.function.Predicate predicate) { + for (java.lang.String item : nonResourceURLs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingNonResourceURL(java.util.function.Predicate predicate) { - for (java.lang.String item: nonResourceURLs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingNonResourceURL( + java.util.function.Predicate predicate) { + for (java.lang.String item : nonResourceURLs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withNonResourceURLs(java.util.List nonResourceURLs) { - if (nonResourceURLs != null) {this.nonResourceURLs = new java.util.ArrayList(); for (java.lang.String item : nonResourceURLs){this.addToNonResourceURLs(item);}} else { this.nonResourceURLs = null;} return (A) this; + if (nonResourceURLs != null) { + this.nonResourceURLs = new java.util.ArrayList(); + for (java.lang.String item : nonResourceURLs) { + this.addToNonResourceURLs(item); + } + } else { + this.nonResourceURLs = null; + } + return (A) this; } + public A withNonResourceURLs(java.lang.String... nonResourceURLs) { - if (this.nonResourceURLs != null) {this.nonResourceURLs.clear();} - if (nonResourceURLs != null) {for (java.lang.String item :nonResourceURLs){ this.addToNonResourceURLs(item);}} return (A) this; + if (this.nonResourceURLs != null) { + this.nonResourceURLs.clear(); + } + if (nonResourceURLs != null) { + for (java.lang.String item : nonResourceURLs) { + this.addToNonResourceURLs(item); + } + } + return (A) this; } + public java.lang.Boolean hasNonResourceURLs() { return nonResourceURLs != null && !nonResourceURLs.isEmpty(); } + public A addNewNonResourceURL(java.lang.String original) { - return (A)addToNonResourceURLs(new String(original)); + return (A) addToNonResourceURLs(new String(original)); } - public A addToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} + + public A addToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } this.verbs.add(index, item); - return (A)this; + return (A) this; } - public A setToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - this.verbs.set(index, item); return (A)this; + + public A setToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + this.verbs.set(index, item); + return (A) this; } + public A addToVerbs(java.lang.String... items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A addAllToVerbs(java.util.Collection items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A removeFromVerbs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public A removeAllFromVerbs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public java.util.List getVerbs() { return this.verbs; } + public java.lang.String getVerb(java.lang.Integer index) { return this.verbs.get(index); } + public java.lang.String getFirstVerb() { return this.verbs.get(0); } + public java.lang.String getLastVerb() { return this.verbs.get(verbs.size() - 1); } - public java.lang.String getMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withVerbs(java.util.List verbs) { - if (verbs != null) {this.verbs = new java.util.ArrayList(); for (java.lang.String item : verbs){this.addToVerbs(item);}} else { this.verbs = null;} return (A) this; + if (verbs != null) { + this.verbs = new java.util.ArrayList(); + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } else { + this.verbs = null; + } + return (A) this; } + public A withVerbs(java.lang.String... verbs) { - if (this.verbs != null) {this.verbs.clear();} - if (verbs != null) {for (java.lang.String item :verbs){ this.addToVerbs(item);}} return (A) this; + if (this.verbs != null) { + this.verbs.clear(); + } + if (verbs != null) { + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } + return (A) this; } + public java.lang.Boolean hasVerbs() { return verbs != null && !verbs.isEmpty(); } + public A addNewVerb(java.lang.String original) { - return (A)addToVerbs(new String(original)); + return (A) addToVerbs(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1NonResourcePolicyRuleFluentImpl that = (V1beta1NonResourcePolicyRuleFluentImpl) o; - if (nonResourceURLs != null ? !nonResourceURLs.equals(that.nonResourceURLs) :that.nonResourceURLs != null) return false; - if (verbs != null ? !verbs.equals(that.verbs) :that.verbs != null) return false; + if (nonResourceURLs != null + ? !nonResourceURLs.equals(that.nonResourceURLs) + : that.nonResourceURLs != null) return false; + if (verbs != null ? !verbs.equals(that.verbs) : that.verbs != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(nonResourceURLs, verbs, super.hashCode()); + return java.util.Objects.hash(nonResourceURLs, verbs, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1OverheadBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1OverheadBuilder.java index 1a56467a15..55235469a9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1OverheadBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1OverheadBuilder.java @@ -1,58 +1,96 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1OverheadBuilder extends io.kubernetes.client.openapi.models.V1beta1OverheadFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1OverheadBuilder + extends io.kubernetes.client.openapi.models.V1beta1OverheadFluentImpl< + io.kubernetes.client.openapi.models.V1beta1OverheadBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1Overhead, + io.kubernetes.client.openapi.models.V1beta1OverheadBuilder> { public V1beta1OverheadBuilder() { this(false); } + public V1beta1OverheadBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1Overhead(), validationEnabled); } - public V1beta1OverheadBuilder(io.kubernetes.client.openapi.models.V1beta1OverheadFluent fluent) { + + public V1beta1OverheadBuilder( + io.kubernetes.client.openapi.models.V1beta1OverheadFluent fluent) { this(fluent, false); } - public V1beta1OverheadBuilder(io.kubernetes.client.openapi.models.V1beta1OverheadFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1OverheadBuilder( + io.kubernetes.client.openapi.models.V1beta1OverheadFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1Overhead(), validationEnabled); } - public V1beta1OverheadBuilder(io.kubernetes.client.openapi.models.V1beta1OverheadFluent fluent,io.kubernetes.client.openapi.models.V1beta1Overhead instance) { + + public V1beta1OverheadBuilder( + io.kubernetes.client.openapi.models.V1beta1OverheadFluent fluent, + io.kubernetes.client.openapi.models.V1beta1Overhead instance) { this(fluent, instance, false); } - public V1beta1OverheadBuilder(io.kubernetes.client.openapi.models.V1beta1OverheadFluent fluent,io.kubernetes.client.openapi.models.V1beta1Overhead instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1OverheadBuilder( + io.kubernetes.client.openapi.models.V1beta1OverheadFluent fluent, + io.kubernetes.client.openapi.models.V1beta1Overhead instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPodFixed(instance.getPodFixed()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1beta1OverheadBuilder(io.kubernetes.client.openapi.models.V1beta1Overhead instance) { - this(instance,false); + this(instance, false); } - public V1beta1OverheadBuilder(io.kubernetes.client.openapi.models.V1beta1Overhead instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1OverheadBuilder( + io.kubernetes.client.openapi.models.V1beta1Overhead instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPodFixed(instance.getPodFixed()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1OverheadFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1Overhead build() { V1beta1Overhead buildable = new V1beta1Overhead(); buildable.setPodFixed(fluent.getPodFixed()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1OverheadBuilder that = (V1beta1OverheadBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1OverheadFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1OverheadFluent.java index 0360269920..c92931584b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1OverheadFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1OverheadFluent.java @@ -1,23 +1,34 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; -import java.util.Map; -import java.util.LinkedHashMap; +/** Generated */ +public interface V1beta1OverheadFluent< + A extends io.kubernetes.client.openapi.models.V1beta1OverheadFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToPodFixed(java.lang.String key, io.kubernetes.client.custom.Quantity value); + + public A addToPodFixed(java.util.Map map); - /** - * Generated - */ -public interface V1beta1OverheadFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToPodFixed(java.lang.String key,io.kubernetes.client.custom.Quantity value); - public A addToPodFixed(java.util.Map map); public A removeFromPodFixed(java.lang.String key); - public A removeFromPodFixed(java.util.Map map); - public java.util.Map getPodFixed(); - public A withPodFixed(java.util.Map podFixed); + + public A removeFromPodFixed( + java.util.Map map); + + public java.util.Map getPodFixed(); + + public A withPodFixed( + java.util.Map podFixed); + public java.lang.Boolean hasPodFixed(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1OverheadFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1OverheadFluentImpl.java index 8b771a5f5a..09e17dd34c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1OverheadFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1OverheadFluentImpl.java @@ -1,58 +1,103 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.BaseFluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; -import java.util.Map; -import java.util.LinkedHashMap; +/** Generated */ +public class V1beta1OverheadFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1OverheadFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1OverheadFluent { + public V1beta1OverheadFluentImpl() {} - /** - * Generated - */ -public class V1beta1OverheadFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1OverheadFluent{ - public V1beta1OverheadFluentImpl() { - } public V1beta1OverheadFluentImpl(io.kubernetes.client.openapi.models.V1beta1Overhead instance) { this.withPodFixed(instance.getPodFixed()); - } - private java.util.Map podFixed; - public A addToPodFixed(java.lang.String key,io.kubernetes.client.custom.Quantity value) { - if(this.podFixed == null && key != null && value != null) { this.podFixed = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.podFixed.put(key, value);} return (A)this; + + private java.util.Map podFixed; + + public A addToPodFixed(java.lang.String key, io.kubernetes.client.custom.Quantity value) { + if (this.podFixed == null && key != null && value != null) { + this.podFixed = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.podFixed.put(key, value); + } + return (A) this; } - public A addToPodFixed(java.util.Map map) { - if(this.podFixed == null && map != null) { this.podFixed = new java.util.LinkedHashMap(); } - if(map != null) { this.podFixed.putAll(map);} return (A)this; + + public A addToPodFixed( + java.util.Map map) { + if (this.podFixed == null && map != null) { + this.podFixed = new java.util.LinkedHashMap(); + } + if (map != null) { + this.podFixed.putAll(map); + } + return (A) this; } + public A removeFromPodFixed(java.lang.String key) { - if(this.podFixed == null) { return (A) this; } - if(key != null && this.podFixed != null) {this.podFixed.remove(key);} return (A)this; + if (this.podFixed == null) { + return (A) this; + } + if (key != null && this.podFixed != null) { + this.podFixed.remove(key); + } + return (A) this; } - public A removeFromPodFixed(java.util.Map map) { - if(this.podFixed == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.podFixed != null){this.podFixed.remove(key);}}} return (A)this; + + public A removeFromPodFixed( + java.util.Map map) { + if (this.podFixed == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.podFixed != null) { + this.podFixed.remove(key); + } + } + } + return (A) this; } - public java.util.Map getPodFixed() { + + public java.util.Map getPodFixed() { return this.podFixed; } - public A withPodFixed(java.util.Map podFixed) { - if (podFixed == null) { this.podFixed = null;} else {this.podFixed = new java.util.LinkedHashMap(podFixed);} return (A) this; + + public A withPodFixed( + java.util.Map podFixed) { + if (podFixed == null) { + this.podFixed = null; + } else { + this.podFixed = new java.util.LinkedHashMap(podFixed); + } + return (A) this; } + public java.lang.Boolean hasPodFixed() { return this.podFixed != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1OverheadFluentImpl that = (V1beta1OverheadFluentImpl) o; - if (podFixed != null ? !podFixed.equals(that.podFixed) :that.podFixed != null) return false; + if (podFixed != null ? !podFixed.equals(that.podFixed) : that.podFixed != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(podFixed, super.hashCode()); + return java.util.Objects.hash(podFixed, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetBuilder.java index 414d99abfa..195e1fd178 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PodDisruptionBudgetBuilder extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PodDisruptionBudgetBuilder + extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder> { public V1beta1PodDisruptionBudgetBuilder() { this(false); } + public V1beta1PodDisruptionBudgetBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PodDisruptionBudget(), validationEnabled); } - public V1beta1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent fluent) { + + public V1beta1PodDisruptionBudgetBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent fluent) { this(fluent, false); } - public V1beta1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PodDisruptionBudgetBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PodDisruptionBudget(), validationEnabled); } - public V1beta1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget instance) { + + public V1beta1PodDisruptionBudgetBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget instance) { this(fluent, instance, false); } - public V1beta1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PodDisruptionBudgetBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1beta1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1b fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget instance) { - this(instance,false); + + public V1beta1PodDisruptionBudgetBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget instance) { + this(instance, false); } - public V1beta1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PodDisruptionBudgetBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1beta1PodDisruptionBudgetBuilder(io.kubernetes.client.openapi.models.V1b this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget build() { V1beta1PodDisruptionBudget buildable = new V1beta1PodDisruptionBudget(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1PodDisruptionBudgetBuilder that = (V1beta1PodDisruptionBudgetBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetFluent.java index 5b957ff600..f15230609c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetFluent.java @@ -1,93 +1,155 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1PodDisruptionBudgetFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1PodDisruptionBudgetFluent< + A extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec getSpec(); + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec item); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec item); - + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus getStatus(); + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus item); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested< + N>> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetFluentImpl.java index 3f46924c87..120e4d1652 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1PodDisruptionBudgetFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent { + public V1beta1PodDisruptionBudgetFluentImpl() {} - /** - * Generated - */ -public class V1beta1PodDisruptionBudgetFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent{ - public V1beta1PodDisruptionBudgetFluentImpl() { - } - public V1beta1PodDisruptionBudgetFluentImpl(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget instance) { + public V1beta1PodDisruptionBudgetFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,322 @@ public V1beta1PodDisruptionBudgetFluentImpl(io.kubernetes.client.openapi.models. this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecBuilder spec; private io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec item) { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec item) { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus item) { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus item) { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1PodDisruptionBudgetFluentImpl that = (V1beta1PodDisruptionBudgetFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1beta1PodDisruptionBudgetFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecBuilder(this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecBuilder builder; + public N and() { return (N) V1beta1PodDisruptionBudgetFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent.StatusNested< + N>, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusBuilder( + this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusBuilder builder; + public N and() { return (N) V1beta1PodDisruptionBudgetFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetListBuilder.java index 60112dae47..014d87324d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PodDisruptionBudgetListBuilder extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PodDisruptionBudgetListBuilder + extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetList, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListBuilder> { public V1beta1PodDisruptionBudgetListBuilder() { this(false); } + public V1beta1PodDisruptionBudgetListBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PodDisruptionBudgetList(), validationEnabled); } - public V1beta1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent fluent) { + + public V1beta1PodDisruptionBudgetListBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent fluent) { this(fluent, false); } - public V1beta1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PodDisruptionBudgetListBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PodDisruptionBudgetList(), validationEnabled); } - public V1beta1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetList instance) { + + public V1beta1PodDisruptionBudgetListBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetList instance) { this(fluent, instance, false); } - public V1beta1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PodDisruptionBudgetListBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1beta1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetList instance) { - this(instance,false); + + public V1beta1PodDisruptionBudgetListBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetList instance) { + this(instance, false); } - public V1beta1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PodDisruptionBudgetListBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1beta1PodDisruptionBudgetListBuilder(io.kubernetes.client.openapi.models this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetList build() { V1beta1PodDisruptionBudgetList buildable = new V1beta1PodDisruptionBudgetList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetList build( buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1PodDisruptionBudgetListBuilder that = (V1beta1PodDisruptionBudgetListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetListFluent.java index 5436290c7b..dd4882b560 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetListFluent.java @@ -1,95 +1,170 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1PodDisruptionBudgetListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1PodDisruptionBudgetListFluent< + A extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item); + public A addToItems(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); - public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget buildItem(java.lang.Integer index); + + public java.util.List + buildItems(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget buildFirstItem(); + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget buildLastItem(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluent< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetListFluentImpl.java index b8f21841f8..b324e0e7c2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta1PodDisruptionBudgetListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent{ - public V1beta1PodDisruptionBudgetListFluentImpl() { - } - public V1beta1PodDisruptionBudgetListFluentImpl(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetList instance) { + +/** Generated */ +public class V1beta1PodDisruptionBudgetListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent { + public V1beta1PodDisruptionBudgetListFluentImpl() {} + + public V1beta1PodDisruptionBudgetListFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,135 @@ public V1beta1PodDisruptionBudgetListFluentImpl(io.kubernetes.client.openapi.mod this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item : items) {io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item : items) { + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item : items) {io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item : items) { + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget... items) { - for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item : items) {io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeFromItems( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget... items) { + for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item : items) { + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item : items) {io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item : items) { + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder = each.next(); @@ -87,174 +168,297 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } - public java.util.List buildItems() { + + public java.util.List + buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item) { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item) { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item) { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item) { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1PodDisruptionBudgetListFluentImpl that = (V1beta1PodDisruptionBudgetListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent + .ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudget item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1PodDisruptionBudgetListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1beta1PodDisruptionBudgetListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent.MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1beta1PodDisruptionBudgetListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetSpecBuilder.java index a77be141eb..7643584ddb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetSpecBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PodDisruptionBudgetSpecBuilder extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PodDisruptionBudgetSpecBuilder + extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecBuilder> { public V1beta1PodDisruptionBudgetSpecBuilder() { this(false); } + public V1beta1PodDisruptionBudgetSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PodDisruptionBudgetSpec(), validationEnabled); } - public V1beta1PodDisruptionBudgetSpecBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent fluent) { + + public V1beta1PodDisruptionBudgetSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent fluent) { this(fluent, false); } - public V1beta1PodDisruptionBudgetSpecBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PodDisruptionBudgetSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PodDisruptionBudgetSpec(), validationEnabled); } - public V1beta1PodDisruptionBudgetSpecBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec instance) { + + public V1beta1PodDisruptionBudgetSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec instance) { this(fluent, instance, false); } - public V1beta1PodDisruptionBudgetSpecBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PodDisruptionBudgetSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMaxUnavailable(instance.getMaxUnavailable()); fluent.withMinAvailable(instance.getMinAvailable()); fluent.withSelector(instance.getSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PodDisruptionBudgetSpecBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec instance) { - this(instance,false); + + public V1beta1PodDisruptionBudgetSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec instance) { + this(instance, false); } - public V1beta1PodDisruptionBudgetSpecBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PodDisruptionBudgetSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMaxUnavailable(instance.getMaxUnavailable()); this.withMinAvailable(instance.getMinAvailable()); this.withSelector(instance.getSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec build() { V1beta1PodDisruptionBudgetSpec buildable = new V1beta1PodDisruptionBudgetSpec(); buildable.setMaxUnavailable(fluent.getMaxUnavailable()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec build( buildable.setSelector(fluent.getSelector()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1PodDisruptionBudgetSpecBuilder that = (V1beta1PodDisruptionBudgetSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetSpecFluent.java index 3b29755c1f..bca9d53938 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetSpecFluent.java @@ -1,46 +1,78 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.custom.IntOrString; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1PodDisruptionBudgetSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1PodDisruptionBudgetSpecFluent< + A extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public io.kubernetes.client.custom.IntOrString getMaxUnavailable(); + public A withMaxUnavailable(io.kubernetes.client.custom.IntOrString maxUnavailable); + public java.lang.Boolean hasMaxUnavailable(); + public A withNewMaxUnavailable(int value); + public A withNewMaxUnavailable(java.lang.String value); + public io.kubernetes.client.custom.IntOrString getMinAvailable(); + public A withMinAvailable(io.kubernetes.client.custom.IntOrString minAvailable); + public java.lang.Boolean hasMinAvailable(); + public A withNewMinAvailable(int value); + public A withNewMinAvailable(java.lang.String value); - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested editSelector(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested + withNewSelector(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested + editSelector(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested + editOrNewSelector(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent + .SelectorNested< + N>> { public N and(); + public N endSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetSpecFluentImpl.java index 2644dfb4ac..46546bddee 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetSpecFluentImpl.java @@ -1,121 +1,179 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; import io.kubernetes.client.custom.IntOrString; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta1PodDisruptionBudgetSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent{ - public V1beta1PodDisruptionBudgetSpecFluentImpl() { - } - public V1beta1PodDisruptionBudgetSpecFluentImpl(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec instance) { + +/** Generated */ +public class V1beta1PodDisruptionBudgetSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent { + public V1beta1PodDisruptionBudgetSpecFluentImpl() {} + + public V1beta1PodDisruptionBudgetSpecFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpec instance) { this.withMaxUnavailable(instance.getMaxUnavailable()); this.withMinAvailable(instance.getMinAvailable()); this.withSelector(instance.getSelector()); - } + private io.kubernetes.client.custom.IntOrString maxUnavailable; private io.kubernetes.client.custom.IntOrString minAvailable; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder selector; + public io.kubernetes.client.custom.IntOrString getMaxUnavailable() { return this.maxUnavailable; } + public A withMaxUnavailable(io.kubernetes.client.custom.IntOrString maxUnavailable) { - this.maxUnavailable=maxUnavailable; return (A) this; + this.maxUnavailable = maxUnavailable; + return (A) this; } + public java.lang.Boolean hasMaxUnavailable() { return this.maxUnavailable != null; } + public A withNewMaxUnavailable(int value) { - return (A)withMaxUnavailable(new IntOrString(value)); + return (A) withMaxUnavailable(new IntOrString(value)); } + public A withNewMaxUnavailable(java.lang.String value) { - return (A)withMaxUnavailable(new IntOrString(value)); + return (A) withMaxUnavailable(new IntOrString(value)); } + public io.kubernetes.client.custom.IntOrString getMinAvailable() { return this.minAvailable; } + public A withMinAvailable(io.kubernetes.client.custom.IntOrString minAvailable) { - this.minAvailable=minAvailable; return (A) this; + this.minAvailable = minAvailable; + return (A) this; } + public java.lang.Boolean hasMinAvailable() { return this.minAvailable != null; } + public A withNewMinAvailable(int value) { - return (A)withMinAvailable(new IntOrString(value)); + return (A) withMinAvailable(new IntOrString(value)); } + public A withNewMinAvailable(java.lang.String value) { - return (A)withMinAvailable(new IntOrString(value)); + return (A) withMinAvailable(new IntOrString(value)); } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested withNewSelector() { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluentImpl.SelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested + withNewSelector() { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluentImpl + .SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluentImpl.SelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluentImpl + .SelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested editSelector() { + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested + editSelector() { return withNewSelectorLike(getSelector()); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested + editOrNewSelector() { + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1PodDisruptionBudgetSpecFluentImpl that = (V1beta1PodDisruptionBudgetSpecFluentImpl) o; - if (maxUnavailable != null ? !maxUnavailable.equals(that.maxUnavailable) :that.maxUnavailable != null) return false; - if (minAvailable != null ? !minAvailable.equals(that.minAvailable) :that.minAvailable != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; + if (maxUnavailable != null + ? !maxUnavailable.equals(that.maxUnavailable) + : that.maxUnavailable != null) return false; + if (minAvailable != null ? !minAvailable.equals(that.minAvailable) : that.minAvailable != null) + return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(maxUnavailable, minAvailable, selector, super.hashCode()); + return java.util.Objects.hash(maxUnavailable, minAvailable, selector, super.hashCode()); } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent.SelectorNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetSpecFluent + .SelectorNested< + N>, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V1beta1PodDisruptionBudgetSpecFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetStatusBuilder.java index f29fd81e9f..4e0fddb968 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PodDisruptionBudgetStatusBuilder extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PodDisruptionBudgetStatusBuilder + extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusBuilder> { public V1beta1PodDisruptionBudgetStatusBuilder() { this(false); } + public V1beta1PodDisruptionBudgetStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PodDisruptionBudgetStatus(), validationEnabled); } - public V1beta1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent fluent) { + + public V1beta1PodDisruptionBudgetStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent fluent) { this(fluent, false); } - public V1beta1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PodDisruptionBudgetStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PodDisruptionBudgetStatus(), validationEnabled); } - public V1beta1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus instance) { + + public V1beta1PodDisruptionBudgetStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus instance) { this(fluent, instance, false); } - public V1beta1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PodDisruptionBudgetStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditions(instance.getConditions()); fluent.withCurrentHealthy(instance.getCurrentHealthy()); @@ -35,13 +62,18 @@ public V1beta1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.mode fluent.withObservedGeneration(instance.getObservedGeneration()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus instance) { - this(instance,false); + + public V1beta1PodDisruptionBudgetStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus instance) { + this(instance, false); } - public V1beta1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PodDisruptionBudgetStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditions(instance.getConditions()); this.withCurrentHealthy(instance.getCurrentHealthy()); @@ -56,10 +88,12 @@ public V1beta1PodDisruptionBudgetStatusBuilder(io.kubernetes.client.openapi.mode this.withObservedGeneration(instance.getObservedGeneration()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus build() { V1beta1PodDisruptionBudgetStatus buildable = new V1beta1PodDisruptionBudgetStatus(); buildable.setConditions(fluent.getConditions()); @@ -71,18 +105,23 @@ public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus buil buildable.setObservedGeneration(fluent.getObservedGeneration()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1PodDisruptionBudgetStatusBuilder that = (V1beta1PodDisruptionBudgetStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetStatusFluent.java index 28ce3fa370..ff77ddb7c6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetStatusFluent.java @@ -1,83 +1,163 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import java.lang.Long; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1beta1PodDisruptionBudgetStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item); +/** Generated */ +public interface V1beta1PodDisruptionBudgetStatusFluent< + A extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1Condition... items); - public A addAllToConditions(java.util.Collection items); + + public A addAllToConditions( + java.util.Collection items); + public A removeFromConditions(io.kubernetes.client.openapi.models.V1Condition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getConditions(); + public java.util.List buildConditions(); + public io.kubernetes.client.openapi.models.V1Condition buildCondition(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Condition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1Condition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1Condition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); + + public io.kubernetes.client.openapi.models.V1Condition buildMatchingCondition( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate); + + public A withConditions( + java.util.List conditions); + public A withConditions(io.kubernetes.client.openapi.models.V1Condition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1Condition item); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + addNewConditionLike(io.kubernetes.client.openapi.models.V1Condition item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate + predicate); + public java.lang.Integer getCurrentHealthy(); + public A withCurrentHealthy(java.lang.Integer currentHealthy); + public java.lang.Boolean hasCurrentHealthy(); + public java.lang.Integer getDesiredHealthy(); + public A withDesiredHealthy(java.lang.Integer desiredHealthy); + public java.lang.Boolean hasDesiredHealthy(); - public A addToDisruptedPods(java.lang.String key,java.time.OffsetDateTime value); - public A addToDisruptedPods(java.util.Map map); + + public A addToDisruptedPods(java.lang.String key, java.time.OffsetDateTime value); + + public A addToDisruptedPods(java.util.Map map); + public A removeFromDisruptedPods(java.lang.String key); - public A removeFromDisruptedPods(java.util.Map map); - public java.util.Map getDisruptedPods(); - public A withDisruptedPods(java.util.Map disruptedPods); + + public A removeFromDisruptedPods(java.util.Map map); + + public java.util.Map getDisruptedPods(); + + public A withDisruptedPods( + java.util.Map disruptedPods); + public java.lang.Boolean hasDisruptedPods(); + public java.lang.Integer getDisruptionsAllowed(); + public A withDisruptionsAllowed(java.lang.Integer disruptionsAllowed); + public java.lang.Boolean hasDisruptionsAllowed(); + public java.lang.Integer getExpectedPods(); + public A withExpectedPods(java.lang.Integer expectedPods); + public java.lang.Boolean hasExpectedPods(); + public java.lang.Long getObservedGeneration(); + public A withObservedGeneration(java.lang.Long observedGeneration); + public java.lang.Boolean hasObservedGeneration(); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ConditionFluent< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetStatusFluentImpl.java index 77e7549dca..72fbbab853 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodDisruptionBudgetStatusFluentImpl.java @@ -1,30 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.lang.Long; -import java.util.Collection; -import java.lang.Object; -import java.util.Map; - - /** - * Generated - */ -public class V1beta1PodDisruptionBudgetStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent{ - public V1beta1PodDisruptionBudgetStatusFluentImpl() { - } - public V1beta1PodDisruptionBudgetStatusFluentImpl(io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus instance) { + +/** Generated */ +public class V1beta1PodDisruptionBudgetStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent { + public V1beta1PodDisruptionBudgetStatusFluentImpl() {} + + public V1beta1PodDisruptionBudgetStatusFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatus instance) { this.withConditions(instance.getConditions()); this.withCurrentHealthy(instance.getCurrentHealthy()); @@ -38,43 +37,112 @@ public V1beta1PodDisruptionBudgetStatusFluentImpl(io.kubernetes.client.openapi.m this.withExpectedPods(instance.getExpectedPods()); this.withObservedGeneration(instance.getObservedGeneration()); - } + private java.util.ArrayList conditions; private java.lang.Integer currentHealthy; private java.lang.Integer desiredHealthy; - private java.util.Map disruptedPods; + private java.util.Map disruptedPods; private java.lang.Integer disruptionsAllowed; private java.lang.Integer expectedPods; private java.lang.Long observedGeneration; - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } + public A addToConditions(io.kubernetes.client.openapi.models.V1Condition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Condition item : items) {io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Condition item : items) { + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Condition item : items) {io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Condition item : items) { + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } + public A removeFromConditions(io.kubernetes.client.openapi.models.V1Condition... items) { - for (io.kubernetes.client.openapi.models.V1Condition item : items) {io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Condition item : items) { + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Condition item : items) {io.kubernetes.client.openapi.models.V1ConditionBuilder builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Condition item : items) { + io.kubernetes.client.openapi.models.V1ConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1ConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1ConditionBuilder builder = each.next(); @@ -83,180 +151,354 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { return conditions != null ? build(conditions) : null; } + public java.util.List buildConditions() { return conditions != null ? build(conditions) : null; } + public io.kubernetes.client.openapi.models.V1Condition buildCondition(java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Condition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Condition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Condition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Condition buildMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1ConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1ConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Condition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Condition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } + public A withConditions(io.kubernetes.client.openapi.models.V1Condition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1Condition item :conditions){ this.addToConditions(item);}} return (A) this; + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1Condition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1Condition item) { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + addNewConditionLike(io.kubernetes.client.openapi.models.V1Condition item) { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item) { - return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item) { + return new io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i map) { - if(this.disruptedPods == null && map != null) { this.disruptedPods = new java.util.LinkedHashMap(); } - if(map != null) { this.disruptedPods.putAll(map);} return (A)this; + + public A addToDisruptedPods(java.util.Map map) { + if (this.disruptedPods == null && map != null) { + this.disruptedPods = new java.util.LinkedHashMap(); + } + if (map != null) { + this.disruptedPods.putAll(map); + } + return (A) this; } + public A removeFromDisruptedPods(java.lang.String key) { - if(this.disruptedPods == null) { return (A) this; } - if(key != null && this.disruptedPods != null) {this.disruptedPods.remove(key);} return (A)this; + if (this.disruptedPods == null) { + return (A) this; + } + if (key != null && this.disruptedPods != null) { + this.disruptedPods.remove(key); + } + return (A) this; } - public A removeFromDisruptedPods(java.util.Map map) { - if(this.disruptedPods == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.disruptedPods != null){this.disruptedPods.remove(key);}}} return (A)this; + + public A removeFromDisruptedPods(java.util.Map map) { + if (this.disruptedPods == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.disruptedPods != null) { + this.disruptedPods.remove(key); + } + } + } + return (A) this; } - public java.util.Map getDisruptedPods() { + + public java.util.Map getDisruptedPods() { return this.disruptedPods; } - public A withDisruptedPods(java.util.Map disruptedPods) { - if (disruptedPods == null) { this.disruptedPods = null;} else {this.disruptedPods = new java.util.LinkedHashMap(disruptedPods);} return (A) this; + + public A withDisruptedPods( + java.util.Map disruptedPods) { + if (disruptedPods == null) { + this.disruptedPods = null; + } else { + this.disruptedPods = new java.util.LinkedHashMap(disruptedPods); + } + return (A) this; } + public java.lang.Boolean hasDisruptedPods() { return this.disruptedPods != null; } + public java.lang.Integer getDisruptionsAllowed() { return this.disruptionsAllowed; } + public A withDisruptionsAllowed(java.lang.Integer disruptionsAllowed) { - this.disruptionsAllowed=disruptionsAllowed; return (A) this; + this.disruptionsAllowed = disruptionsAllowed; + return (A) this; } + public java.lang.Boolean hasDisruptionsAllowed() { return this.disruptionsAllowed != null; } + public java.lang.Integer getExpectedPods() { return this.expectedPods; } + public A withExpectedPods(java.lang.Integer expectedPods) { - this.expectedPods=expectedPods; return (A) this; + this.expectedPods = expectedPods; + return (A) this; } + public java.lang.Boolean hasExpectedPods() { return this.expectedPods != null; } + public java.lang.Long getObservedGeneration() { return this.observedGeneration; } + public A withObservedGeneration(java.lang.Long observedGeneration) { - this.observedGeneration=observedGeneration; return (A) this; + this.observedGeneration = observedGeneration; + return (A) this; } + public java.lang.Boolean hasObservedGeneration() { return this.observedGeneration != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta1PodDisruptionBudgetStatusFluentImpl that = (V1beta1PodDisruptionBudgetStatusFluentImpl) o; - if (conditions != null ? !conditions.equals(that.conditions) :that.conditions != null) return false; - if (currentHealthy != null ? !currentHealthy.equals(that.currentHealthy) :that.currentHealthy != null) return false; - if (desiredHealthy != null ? !desiredHealthy.equals(that.desiredHealthy) :that.desiredHealthy != null) return false; - if (disruptedPods != null ? !disruptedPods.equals(that.disruptedPods) :that.disruptedPods != null) return false; - if (disruptionsAllowed != null ? !disruptionsAllowed.equals(that.disruptionsAllowed) :that.disruptionsAllowed != null) return false; - if (expectedPods != null ? !expectedPods.equals(that.expectedPods) :that.expectedPods != null) return false; - if (observedGeneration != null ? !observedGeneration.equals(that.observedGeneration) :that.observedGeneration != null) return false; + V1beta1PodDisruptionBudgetStatusFluentImpl that = + (V1beta1PodDisruptionBudgetStatusFluentImpl) o; + if (conditions != null ? !conditions.equals(that.conditions) : that.conditions != null) + return false; + if (currentHealthy != null + ? !currentHealthy.equals(that.currentHealthy) + : that.currentHealthy != null) return false; + if (desiredHealthy != null + ? !desiredHealthy.equals(that.desiredHealthy) + : that.desiredHealthy != null) return false; + if (disruptedPods != null + ? !disruptedPods.equals(that.disruptedPods) + : that.disruptedPods != null) return false; + if (disruptionsAllowed != null + ? !disruptionsAllowed.equals(that.disruptionsAllowed) + : that.disruptionsAllowed != null) return false; + if (expectedPods != null ? !expectedPods.equals(that.expectedPods) : that.expectedPods != null) + return false; + if (observedGeneration != null + ? !observedGeneration.equals(that.observedGeneration) + : that.observedGeneration != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(conditions, currentHealthy, desiredHealthy, disruptedPods, disruptionsAllowed, expectedPods, observedGeneration, super.hashCode()); + return java.util.Objects.hash( + conditions, + currentHealthy, + desiredHealthy, + disruptedPods, + disruptionsAllowed, + expectedPods, + observedGeneration, + super.hashCode()); } - public class ConditionsNestedImpl extends io.kubernetes.client.openapi.models.V1ConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Condition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1ConditionFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PodDisruptionBudgetStatusFluent + .ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Condition item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1ConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1ConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1PodDisruptionBudgetStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) + V1beta1PodDisruptionBudgetStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyBuilder.java index 731b3bd16d..198e7137d2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PodSecurityPolicyBuilder extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PodSecurityPolicyBuilder + extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder> { public V1beta1PodSecurityPolicyBuilder() { this(false); } + public V1beta1PodSecurityPolicyBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PodSecurityPolicy(), validationEnabled); } - public V1beta1PodSecurityPolicyBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent fluent) { + + public V1beta1PodSecurityPolicyBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent fluent) { this(fluent, false); } - public V1beta1PodSecurityPolicyBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PodSecurityPolicyBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PodSecurityPolicy(), validationEnabled); } - public V1beta1PodSecurityPolicyBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy instance) { + + public V1beta1PodSecurityPolicyBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy instance) { this(fluent, instance, false); } - public V1beta1PodSecurityPolicyBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PodSecurityPolicyBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -29,13 +56,18 @@ public V1beta1PodSecurityPolicyBuilder(io.kubernetes.client.openapi.models.V1bet fluent.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PodSecurityPolicyBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy instance) { - this(instance,false); + + public V1beta1PodSecurityPolicyBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy instance) { + this(instance, false); } - public V1beta1PodSecurityPolicyBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PodSecurityPolicyBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -44,10 +76,12 @@ public V1beta1PodSecurityPolicyBuilder(io.kubernetes.client.openapi.models.V1bet this.withSpec(instance.getSpec()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy build() { V1beta1PodSecurityPolicy buildable = new V1beta1PodSecurityPolicy(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy build() { buildable.setSpec(fluent.getSpec()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1PodSecurityPolicyBuilder that = (V1beta1PodSecurityPolicyBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyFluent.java index 3a4ce8bce4..fb43dc1ad7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyFluent.java @@ -1,73 +1,115 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1PodSecurityPolicyFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1PodSecurityPolicyFluent< + A extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec getSpec(); + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested> { public N and(); + public N endSpec(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyFluentImpl.java index f2ff6e87cc..fc9b0b4900 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1PodSecurityPolicyFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent { + public V1beta1PodSecurityPolicyFluentImpl() {} - /** - * Generated - */ -public class V1beta1PodSecurityPolicyFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent{ - public V1beta1PodSecurityPolicyFluentImpl() { - } - public V1beta1PodSecurityPolicyFluentImpl(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy instance) { + public V1beta1PodSecurityPolicyFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -21,158 +28,230 @@ public V1beta1PodSecurityPolicyFluentImpl(io.kubernetes.client.openapi.models.V1 this.withMetadata(instance.getMetadata()); this.withSpec(instance.getSpec()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecBuilder spec; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1PodSecurityPolicyFluentImpl that = (V1beta1PodSecurityPolicyFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1beta1PodSecurityPolicyFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecBuilder(this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecBuilder builder; + public N and() { return (N) V1beta1PodSecurityPolicyFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyListBuilder.java index cd977d2ec5..0c0b8dce44 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PodSecurityPolicyListBuilder extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PodSecurityPolicyListBuilder + extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyList, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListBuilder> { public V1beta1PodSecurityPolicyListBuilder() { this(false); } + public V1beta1PodSecurityPolicyListBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PodSecurityPolicyList(), validationEnabled); } - public V1beta1PodSecurityPolicyListBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent fluent) { + + public V1beta1PodSecurityPolicyListBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent fluent) { this(fluent, false); } - public V1beta1PodSecurityPolicyListBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PodSecurityPolicyListBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PodSecurityPolicyList(), validationEnabled); } - public V1beta1PodSecurityPolicyListBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyList instance) { + + public V1beta1PodSecurityPolicyListBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyList instance) { this(fluent, instance, false); } - public V1beta1PodSecurityPolicyListBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PodSecurityPolicyListBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1beta1PodSecurityPolicyListBuilder(io.kubernetes.client.openapi.models.V fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PodSecurityPolicyListBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyList instance) { - this(instance,false); + + public V1beta1PodSecurityPolicyListBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyList instance) { + this(instance, false); } - public V1beta1PodSecurityPolicyListBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PodSecurityPolicyListBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1beta1PodSecurityPolicyListBuilder(io.kubernetes.client.openapi.models.V this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyList build() { V1beta1PodSecurityPolicyList buildable = new V1beta1PodSecurityPolicyList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyList build() buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1PodSecurityPolicyListBuilder that = (V1beta1PodSecurityPolicyListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyListFluent.java index 89cc36065f..1657316dd6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyListFluent.java @@ -1,95 +1,168 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1PodSecurityPolicyListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1PodSecurityPolicyListFluent< + A extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item); + public A addToItems(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy buildFirstItem(); + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy buildLastItem(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyListFluentImpl.java index 21ae1e6c6b..f76e36b142 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicyListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta1PodSecurityPolicyListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent{ - public V1beta1PodSecurityPolicyListFluentImpl() { - } - public V1beta1PodSecurityPolicyListFluentImpl(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyList instance) { + +/** Generated */ +public class V1beta1PodSecurityPolicyListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent { + public V1beta1PodSecurityPolicyListFluentImpl() {} + + public V1beta1PodSecurityPolicyListFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,132 @@ public V1beta1PodSecurityPolicyListFluentImpl(io.kubernetes.client.openapi.model this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item : items) {io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item : items) { + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item : items) {io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item : items) { + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy... items) { - for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item : items) {io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item : items) { + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item : items) {io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item : items) { + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder = each.next(); @@ -87,174 +165,293 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1PodSecurityPolicyListFluentImpl that = (V1beta1PodSecurityPolicyListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicy item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1PodSecurityPolicyListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1beta1PodSecurityPolicyListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicyListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1beta1PodSecurityPolicyListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicySpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicySpecBuilder.java index 06f91267f0..46b7b16b01 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicySpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicySpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PodSecurityPolicySpecBuilder extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PodSecurityPolicySpecBuilder + extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecBuilder> { public V1beta1PodSecurityPolicySpecBuilder() { this(false); } + public V1beta1PodSecurityPolicySpecBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PodSecurityPolicySpec(), validationEnabled); } - public V1beta1PodSecurityPolicySpecBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent fluent) { + + public V1beta1PodSecurityPolicySpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent fluent) { this(fluent, false); } - public V1beta1PodSecurityPolicySpecBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PodSecurityPolicySpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PodSecurityPolicySpec(), validationEnabled); } - public V1beta1PodSecurityPolicySpecBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec instance) { + + public V1beta1PodSecurityPolicySpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec instance) { this(fluent, instance, false); } - public V1beta1PodSecurityPolicySpecBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent fluent,io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PodSecurityPolicySpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAllowPrivilegeEscalation(instance.getAllowPrivilegeEscalation()); fluent.withAllowedCSIDrivers(instance.getAllowedCSIDrivers()); @@ -69,13 +96,18 @@ public V1beta1PodSecurityPolicySpecBuilder(io.kubernetes.client.openapi.models.V fluent.withVolumes(instance.getVolumes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PodSecurityPolicySpecBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec instance) { - this(instance,false); + + public V1beta1PodSecurityPolicySpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec instance) { + this(instance, false); } - public V1beta1PodSecurityPolicySpecBuilder(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PodSecurityPolicySpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAllowPrivilegeEscalation(instance.getAllowPrivilegeEscalation()); this.withAllowedCSIDrivers(instance.getAllowedCSIDrivers()); @@ -124,10 +156,12 @@ public V1beta1PodSecurityPolicySpecBuilder(io.kubernetes.client.openapi.models.V this.withVolumes(instance.getVolumes()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec build() { V1beta1PodSecurityPolicySpec buildable = new V1beta1PodSecurityPolicySpec(); buildable.setAllowPrivilegeEscalation(fluent.getAllowPrivilegeEscalation()); @@ -156,18 +190,23 @@ public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec build() buildable.setVolumes(fluent.getVolumes()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1PodSecurityPolicySpecBuilder that = (V1beta1PodSecurityPolicySpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicySpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicySpecFluent.java index 89e0ceee78..28371a04c0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicySpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicySpecFluent.java @@ -1,415 +1,990 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.util.Collection; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import java.util.Iterator; -import java.lang.Integer; - - /** - * Generated - */ -public interface V1beta1PodSecurityPolicySpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1PodSecurityPolicySpecFluent< + A extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Boolean getAllowPrivilegeEscalation(); + public A withAllowPrivilegeEscalation(java.lang.Boolean allowPrivilegeEscalation); + public java.lang.Boolean hasAllowPrivilegeEscalation(); - public A addToAllowedCSIDrivers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item); - public A setToAllowedCSIDrivers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item); - public A addToAllowedCSIDrivers(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver... items); - public A addAllToAllowedCSIDrivers(java.util.Collection items); - public A removeFromAllowedCSIDrivers(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver... items); - public A removeAllFromAllowedCSIDrivers(java.util.Collection items); - public A removeMatchingFromAllowedCSIDrivers(java.util.function.Predicate predicate); - + + public A addToAllowedCSIDrivers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item); + + public A setToAllowedCSIDrivers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item); + + public A addToAllowedCSIDrivers( + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver... items); + + public A addAllToAllowedCSIDrivers( + java.util.Collection items); + + public A removeFromAllowedCSIDrivers( + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver... items); + + public A removeAllFromAllowedCSIDrivers( + java.util.Collection items); + + public A removeMatchingFromAllowedCSIDrivers( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder> + predicate); + /** * This method has been deprecated, please use method buildAllowedCSIDrivers instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getAllowedCSIDrivers(); - public java.util.List buildAllowedCSIDrivers(); - public io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver buildAllowedCSIDriver(java.lang.Integer index); + public java.util.List + getAllowedCSIDrivers(); + + public java.util.List + buildAllowedCSIDrivers(); + + public io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver buildAllowedCSIDriver( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver buildFirstAllowedCSIDriver(); + public io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver buildLastAllowedCSIDriver(); - public io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver buildMatchingAllowedCSIDriver(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAllowedCSIDriver(java.util.function.Predicate predicate); - public A withAllowedCSIDrivers(java.util.List allowedCSIDrivers); - public A withAllowedCSIDrivers(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver... allowedCSIDrivers); + + public io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver buildMatchingAllowedCSIDriver( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder> + predicate); + + public java.lang.Boolean hasMatchingAllowedCSIDriver( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder> + predicate); + + public A withAllowedCSIDrivers( + java.util.List + allowedCSIDrivers); + + public A withAllowedCSIDrivers( + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver... allowedCSIDrivers); + public java.lang.Boolean hasAllowedCSIDrivers(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested addNewAllowedCSIDriver(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested addNewAllowedCSIDriverLike(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested setNewAllowedCSIDriverLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested editAllowedCSIDriver(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested editFirstAllowedCSIDriver(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested editLastAllowedCSIDriver(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested editMatchingAllowedCSIDriver(java.util.function.Predicate predicate); - public A addToAllowedCapabilities(java.lang.Integer index,java.lang.String item); - public A setToAllowedCapabilities(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + addNewAllowedCSIDriver(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + addNewAllowedCSIDriverLike(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + setNewAllowedCSIDriverLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + editAllowedCSIDriver(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + editFirstAllowedCSIDriver(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + editLastAllowedCSIDriver(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + editMatchingAllowedCSIDriver( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder> + predicate); + + public A addToAllowedCapabilities(java.lang.Integer index, java.lang.String item); + + public A setToAllowedCapabilities(java.lang.Integer index, java.lang.String item); + public A addToAllowedCapabilities(java.lang.String... items); + public A addAllToAllowedCapabilities(java.util.Collection items); + public A removeFromAllowedCapabilities(java.lang.String... items); + public A removeAllFromAllowedCapabilities(java.util.Collection items); + public java.util.List getAllowedCapabilities(); + public java.lang.String getAllowedCapability(java.lang.Integer index); + public java.lang.String getFirstAllowedCapability(); + public java.lang.String getLastAllowedCapability(); - public java.lang.String getMatchingAllowedCapability(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAllowedCapability(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAllowedCapability( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAllowedCapability( + java.util.function.Predicate predicate); + public A withAllowedCapabilities(java.util.List allowedCapabilities); + public A withAllowedCapabilities(java.lang.String... allowedCapabilities); + public java.lang.Boolean hasAllowedCapabilities(); + public A addNewAllowedCapability(java.lang.String original); - public A addToAllowedFlexVolumes(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item); - public A setToAllowedFlexVolumes(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item); - public A addToAllowedFlexVolumes(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume... items); - public A addAllToAllowedFlexVolumes(java.util.Collection items); - public A removeFromAllowedFlexVolumes(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume... items); - public A removeAllFromAllowedFlexVolumes(java.util.Collection items); - public A removeMatchingFromAllowedFlexVolumes(java.util.function.Predicate predicate); - + + public A addToAllowedFlexVolumes( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item); + + public A setToAllowedFlexVolumes( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item); + + public A addToAllowedFlexVolumes( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume... items); + + public A addAllToAllowedFlexVolumes( + java.util.Collection items); + + public A removeFromAllowedFlexVolumes( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume... items); + + public A removeAllFromAllowedFlexVolumes( + java.util.Collection items); + + public A removeMatchingFromAllowedFlexVolumes( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder> + predicate); + /** * This method has been deprecated, please use method buildAllowedFlexVolumes instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getAllowedFlexVolumes(); - public java.util.List buildAllowedFlexVolumes(); - public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume buildAllowedFlexVolume(java.lang.Integer index); + public java.util.List + getAllowedFlexVolumes(); + + public java.util.List + buildAllowedFlexVolumes(); + + public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume buildAllowedFlexVolume( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume buildFirstAllowedFlexVolume(); + public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume buildLastAllowedFlexVolume(); - public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume buildMatchingAllowedFlexVolume(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAllowedFlexVolume(java.util.function.Predicate predicate); - public A withAllowedFlexVolumes(java.util.List allowedFlexVolumes); - public A withAllowedFlexVolumes(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume... allowedFlexVolumes); + + public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume + buildMatchingAllowedFlexVolume( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder> + predicate); + + public java.lang.Boolean hasMatchingAllowedFlexVolume( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder> + predicate); + + public A withAllowedFlexVolumes( + java.util.List + allowedFlexVolumes); + + public A withAllowedFlexVolumes( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume... allowedFlexVolumes); + public java.lang.Boolean hasAllowedFlexVolumes(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested addNewAllowedFlexVolume(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested addNewAllowedFlexVolumeLike(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested setNewAllowedFlexVolumeLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested editAllowedFlexVolume(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested editFirstAllowedFlexVolume(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested editLastAllowedFlexVolume(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested editMatchingAllowedFlexVolume(java.util.function.Predicate predicate); - public A addToAllowedHostPaths(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item); - public A setToAllowedHostPaths(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item); - public A addToAllowedHostPaths(io.kubernetes.client.openapi.models.V1beta1AllowedHostPath... items); - public A addAllToAllowedHostPaths(java.util.Collection items); - public A removeFromAllowedHostPaths(io.kubernetes.client.openapi.models.V1beta1AllowedHostPath... items); - public A removeAllFromAllowedHostPaths(java.util.Collection items); - public A removeMatchingFromAllowedHostPaths(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + addNewAllowedFlexVolume(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + addNewAllowedFlexVolumeLike( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + setNewAllowedFlexVolumeLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + editAllowedFlexVolume(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + editFirstAllowedFlexVolume(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + editLastAllowedFlexVolume(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + editMatchingAllowedFlexVolume( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder> + predicate); + + public A addToAllowedHostPaths( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item); + + public A setToAllowedHostPaths( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item); + + public A addToAllowedHostPaths( + io.kubernetes.client.openapi.models.V1beta1AllowedHostPath... items); + + public A addAllToAllowedHostPaths( + java.util.Collection items); + + public A removeFromAllowedHostPaths( + io.kubernetes.client.openapi.models.V1beta1AllowedHostPath... items); + + public A removeAllFromAllowedHostPaths( + java.util.Collection items); + + public A removeMatchingFromAllowedHostPaths( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder> + predicate); + /** * This method has been deprecated, please use method buildAllowedHostPaths instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getAllowedHostPaths(); - public java.util.List buildAllowedHostPaths(); - public io.kubernetes.client.openapi.models.V1beta1AllowedHostPath buildAllowedHostPath(java.lang.Integer index); + public java.util.List + getAllowedHostPaths(); + + public java.util.List + buildAllowedHostPaths(); + + public io.kubernetes.client.openapi.models.V1beta1AllowedHostPath buildAllowedHostPath( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1AllowedHostPath buildFirstAllowedHostPath(); + public io.kubernetes.client.openapi.models.V1beta1AllowedHostPath buildLastAllowedHostPath(); - public io.kubernetes.client.openapi.models.V1beta1AllowedHostPath buildMatchingAllowedHostPath(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAllowedHostPath(java.util.function.Predicate predicate); - public A withAllowedHostPaths(java.util.List allowedHostPaths); - public A withAllowedHostPaths(io.kubernetes.client.openapi.models.V1beta1AllowedHostPath... allowedHostPaths); + + public io.kubernetes.client.openapi.models.V1beta1AllowedHostPath buildMatchingAllowedHostPath( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder> + predicate); + + public java.lang.Boolean hasMatchingAllowedHostPath( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder> + predicate); + + public A withAllowedHostPaths( + java.util.List allowedHostPaths); + + public A withAllowedHostPaths( + io.kubernetes.client.openapi.models.V1beta1AllowedHostPath... allowedHostPaths); + public java.lang.Boolean hasAllowedHostPaths(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested addNewAllowedHostPath(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested addNewAllowedHostPathLike(io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested setNewAllowedHostPathLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested editAllowedHostPath(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested editFirstAllowedHostPath(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested editLastAllowedHostPath(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested editMatchingAllowedHostPath(java.util.function.Predicate predicate); - public A addToAllowedProcMountTypes(java.lang.Integer index,java.lang.String item); - public A setToAllowedProcMountTypes(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + addNewAllowedHostPath(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + addNewAllowedHostPathLike(io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + setNewAllowedHostPathLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + editAllowedHostPath(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + editFirstAllowedHostPath(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + editLastAllowedHostPath(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + editMatchingAllowedHostPath( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder> + predicate); + + public A addToAllowedProcMountTypes(java.lang.Integer index, java.lang.String item); + + public A setToAllowedProcMountTypes(java.lang.Integer index, java.lang.String item); + public A addToAllowedProcMountTypes(java.lang.String... items); + public A addAllToAllowedProcMountTypes(java.util.Collection items); + public A removeFromAllowedProcMountTypes(java.lang.String... items); + public A removeAllFromAllowedProcMountTypes(java.util.Collection items); + public java.util.List getAllowedProcMountTypes(); + public java.lang.String getAllowedProcMountType(java.lang.Integer index); + public java.lang.String getFirstAllowedProcMountType(); + public java.lang.String getLastAllowedProcMountType(); - public java.lang.String getMatchingAllowedProcMountType(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAllowedProcMountType(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAllowedProcMountType( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAllowedProcMountType( + java.util.function.Predicate predicate); + public A withAllowedProcMountTypes(java.util.List allowedProcMountTypes); + public A withAllowedProcMountTypes(java.lang.String... allowedProcMountTypes); + public java.lang.Boolean hasAllowedProcMountTypes(); + public A addNewAllowedProcMountType(java.lang.String original); - public A addToAllowedUnsafeSysctls(java.lang.Integer index,java.lang.String item); - public A setToAllowedUnsafeSysctls(java.lang.Integer index,java.lang.String item); + + public A addToAllowedUnsafeSysctls(java.lang.Integer index, java.lang.String item); + + public A setToAllowedUnsafeSysctls(java.lang.Integer index, java.lang.String item); + public A addToAllowedUnsafeSysctls(java.lang.String... items); + public A addAllToAllowedUnsafeSysctls(java.util.Collection items); + public A removeFromAllowedUnsafeSysctls(java.lang.String... items); + public A removeAllFromAllowedUnsafeSysctls(java.util.Collection items); + public java.util.List getAllowedUnsafeSysctls(); + public java.lang.String getAllowedUnsafeSysctl(java.lang.Integer index); + public java.lang.String getFirstAllowedUnsafeSysctl(); + public java.lang.String getLastAllowedUnsafeSysctl(); - public java.lang.String getMatchingAllowedUnsafeSysctl(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAllowedUnsafeSysctl(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAllowedUnsafeSysctl( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAllowedUnsafeSysctl( + java.util.function.Predicate predicate); + public A withAllowedUnsafeSysctls(java.util.List allowedUnsafeSysctls); + public A withAllowedUnsafeSysctls(java.lang.String... allowedUnsafeSysctls); + public java.lang.Boolean hasAllowedUnsafeSysctls(); + public A addNewAllowedUnsafeSysctl(java.lang.String original); - public A addToDefaultAddCapabilities(java.lang.Integer index,java.lang.String item); - public A setToDefaultAddCapabilities(java.lang.Integer index,java.lang.String item); + + public A addToDefaultAddCapabilities(java.lang.Integer index, java.lang.String item); + + public A setToDefaultAddCapabilities(java.lang.Integer index, java.lang.String item); + public A addToDefaultAddCapabilities(java.lang.String... items); + public A addAllToDefaultAddCapabilities(java.util.Collection items); + public A removeFromDefaultAddCapabilities(java.lang.String... items); + public A removeAllFromDefaultAddCapabilities(java.util.Collection items); + public java.util.List getDefaultAddCapabilities(); + public java.lang.String getDefaultAddCapability(java.lang.Integer index); + public java.lang.String getFirstDefaultAddCapability(); + public java.lang.String getLastDefaultAddCapability(); - public java.lang.String getMatchingDefaultAddCapability(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingDefaultAddCapability(java.util.function.Predicate predicate); + + public java.lang.String getMatchingDefaultAddCapability( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingDefaultAddCapability( + java.util.function.Predicate predicate); + public A withDefaultAddCapabilities(java.util.List defaultAddCapabilities); + public A withDefaultAddCapabilities(java.lang.String... defaultAddCapabilities); + public java.lang.Boolean hasDefaultAddCapabilities(); + public A addNewDefaultAddCapability(java.lang.String original); + public java.lang.Boolean getDefaultAllowPrivilegeEscalation(); + public A withDefaultAllowPrivilegeEscalation(java.lang.Boolean defaultAllowPrivilegeEscalation); + public java.lang.Boolean hasDefaultAllowPrivilegeEscalation(); - public A addToForbiddenSysctls(java.lang.Integer index,java.lang.String item); - public A setToForbiddenSysctls(java.lang.Integer index,java.lang.String item); + + public A addToForbiddenSysctls(java.lang.Integer index, java.lang.String item); + + public A setToForbiddenSysctls(java.lang.Integer index, java.lang.String item); + public A addToForbiddenSysctls(java.lang.String... items); + public A addAllToForbiddenSysctls(java.util.Collection items); + public A removeFromForbiddenSysctls(java.lang.String... items); + public A removeAllFromForbiddenSysctls(java.util.Collection items); + public java.util.List getForbiddenSysctls(); + public java.lang.String getForbiddenSysctl(java.lang.Integer index); + public java.lang.String getFirstForbiddenSysctl(); + public java.lang.String getLastForbiddenSysctl(); - public java.lang.String getMatchingForbiddenSysctl(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingForbiddenSysctl(java.util.function.Predicate predicate); + + public java.lang.String getMatchingForbiddenSysctl( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingForbiddenSysctl( + java.util.function.Predicate predicate); + public A withForbiddenSysctls(java.util.List forbiddenSysctls); + public A withForbiddenSysctls(java.lang.String... forbiddenSysctls); + public java.lang.Boolean hasForbiddenSysctls(); + public A addNewForbiddenSysctl(java.lang.String original); - + /** * This method has been deprecated, please use method buildFsGroup instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions getFsGroup(); + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions buildFsGroup(); + public A withFsGroup(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions fsGroup); + public java.lang.Boolean hasFsGroup(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested withNewFsGroup(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested withNewFsGroupLike(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested editFsGroup(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested editOrNewFsGroup(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested editOrNewFsGroupLike(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested + withNewFsGroup(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested + withNewFsGroupLike(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested + editFsGroup(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested + editOrNewFsGroup(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested + editOrNewFsGroupLike(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions item); + public java.lang.Boolean getHostIPC(); + public A withHostIPC(java.lang.Boolean hostIPC); + public java.lang.Boolean hasHostIPC(); + public java.lang.Boolean getHostNetwork(); + public A withHostNetwork(java.lang.Boolean hostNetwork); + public java.lang.Boolean hasHostNetwork(); + public java.lang.Boolean getHostPID(); + public A withHostPID(java.lang.Boolean hostPID); + public java.lang.Boolean hasHostPID(); - public A addToHostPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1HostPortRange item); - public A setToHostPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1HostPortRange item); + + public A addToHostPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1HostPortRange item); + + public A setToHostPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1HostPortRange item); + public A addToHostPorts(io.kubernetes.client.openapi.models.V1beta1HostPortRange... items); - public A addAllToHostPorts(java.util.Collection items); + + public A addAllToHostPorts( + java.util.Collection items); + public A removeFromHostPorts(io.kubernetes.client.openapi.models.V1beta1HostPortRange... items); - public A removeAllFromHostPorts(java.util.Collection items); - public A removeMatchingFromHostPorts(java.util.function.Predicate predicate); - + + public A removeAllFromHostPorts( + java.util.Collection items); + + public A removeMatchingFromHostPorts( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildHostPorts instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getHostPorts(); + public java.util.List buildHostPorts(); - public io.kubernetes.client.openapi.models.V1beta1HostPortRange buildHostPort(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1HostPortRange buildHostPort( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1HostPortRange buildFirstHostPort(); + public io.kubernetes.client.openapi.models.V1beta1HostPortRange buildLastHostPort(); - public io.kubernetes.client.openapi.models.V1beta1HostPortRange buildMatchingHostPort(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingHostPort(java.util.function.Predicate predicate); - public A withHostPorts(java.util.List hostPorts); + + public io.kubernetes.client.openapi.models.V1beta1HostPortRange buildMatchingHostPort( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingHostPort( + java.util.function.Predicate + predicate); + + public A withHostPorts( + java.util.List hostPorts); + public A withHostPorts(io.kubernetes.client.openapi.models.V1beta1HostPortRange... hostPorts); + public java.lang.Boolean hasHostPorts(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested addNewHostPort(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested addNewHostPortLike(io.kubernetes.client.openapi.models.V1beta1HostPortRange item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested setNewHostPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1HostPortRange item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested editHostPort(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested editFirstHostPort(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested editLastHostPort(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested editMatchingHostPort(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + addNewHostPort(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + addNewHostPortLike(io.kubernetes.client.openapi.models.V1beta1HostPortRange item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + setNewHostPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1HostPortRange item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + editHostPort(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + editFirstHostPort(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + editLastHostPort(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + editMatchingHostPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder> + predicate); + public java.lang.Boolean getPrivileged(); + public A withPrivileged(java.lang.Boolean privileged); + public java.lang.Boolean hasPrivileged(); + public java.lang.Boolean getReadOnlyRootFilesystem(); + public A withReadOnlyRootFilesystem(java.lang.Boolean readOnlyRootFilesystem); + public java.lang.Boolean hasReadOnlyRootFilesystem(); - public A addToRequiredDropCapabilities(java.lang.Integer index,java.lang.String item); - public A setToRequiredDropCapabilities(java.lang.Integer index,java.lang.String item); + + public A addToRequiredDropCapabilities(java.lang.Integer index, java.lang.String item); + + public A setToRequiredDropCapabilities(java.lang.Integer index, java.lang.String item); + public A addToRequiredDropCapabilities(java.lang.String... items); + public A addAllToRequiredDropCapabilities(java.util.Collection items); + public A removeFromRequiredDropCapabilities(java.lang.String... items); + public A removeAllFromRequiredDropCapabilities(java.util.Collection items); + public java.util.List getRequiredDropCapabilities(); + public java.lang.String getRequiredDropCapability(java.lang.Integer index); + public java.lang.String getFirstRequiredDropCapability(); + public java.lang.String getLastRequiredDropCapability(); - public java.lang.String getMatchingRequiredDropCapability(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRequiredDropCapability(java.util.function.Predicate predicate); + + public java.lang.String getMatchingRequiredDropCapability( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingRequiredDropCapability( + java.util.function.Predicate predicate); + public A withRequiredDropCapabilities(java.util.List requiredDropCapabilities); + public A withRequiredDropCapabilities(java.lang.String... requiredDropCapabilities); + public java.lang.Boolean hasRequiredDropCapabilities(); + public A addNewRequiredDropCapability(java.lang.String original); - + /** * This method has been deprecated, please use method buildRunAsGroup instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions getRunAsGroup(); + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions buildRunAsGroup(); - public A withRunAsGroup(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions runAsGroup); + + public A withRunAsGroup( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions runAsGroup); + public java.lang.Boolean hasRunAsGroup(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested withNewRunAsGroup(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested withNewRunAsGroupLike(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested editRunAsGroup(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested editOrNewRunAsGroup(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested editOrNewRunAsGroupLike(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions item); - + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested + withNewRunAsGroup(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested + withNewRunAsGroupLike( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested + editRunAsGroup(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested + editOrNewRunAsGroup(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested + editOrNewRunAsGroupLike( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions item); + /** * This method has been deprecated, please use method buildRunAsUser instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions getRunAsUser(); + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions buildRunAsUser(); - public A withRunAsUser(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions runAsUser); + + public A withRunAsUser( + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions runAsUser); + public java.lang.Boolean hasRunAsUser(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested withNewRunAsUser(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested withNewRunAsUserLike(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested editRunAsUser(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested editOrNewRunAsUser(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested editOrNewRunAsUserLike(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions item); - + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested + withNewRunAsUser(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested + withNewRunAsUserLike( + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested + editRunAsUser(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested + editOrNewRunAsUser(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested + editOrNewRunAsUserLike( + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions item); + /** * This method has been deprecated, please use method buildRuntimeClass instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions getRuntimeClass(); + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions buildRuntimeClass(); - public A withRuntimeClass(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions runtimeClass); + + public A withRuntimeClass( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions runtimeClass); + public java.lang.Boolean hasRuntimeClass(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested withNewRuntimeClass(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested withNewRuntimeClassLike(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested editRuntimeClass(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested editOrNewRuntimeClass(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested editOrNewRuntimeClassLike(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions item); - + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested< + A> + withNewRuntimeClass(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested< + A> + withNewRuntimeClassLike( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested< + A> + editRuntimeClass(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested< + A> + editOrNewRuntimeClass(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested< + A> + editOrNewRuntimeClassLike( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions item); + /** * This method has been deprecated, please use method buildSeLinux instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions getSeLinux(); + public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions buildSeLinux(); + public A withSeLinux(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions seLinux); + public java.lang.Boolean hasSeLinux(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested withNewSeLinux(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested withNewSeLinuxLike(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested editSeLinux(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested editOrNewSeLinux(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested editOrNewSeLinuxLike(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions item); - + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested + withNewSeLinux(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested + withNewSeLinuxLike(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested + editSeLinux(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested + editOrNewSeLinux(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested + editOrNewSeLinuxLike(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions item); + /** * This method has been deprecated, please use method buildSupplementalGroups instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions getSupplementalGroups(); - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions buildSupplementalGroups(); - public A withSupplementalGroups(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions supplementalGroups); + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions + getSupplementalGroups(); + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions + buildSupplementalGroups(); + + public A withSupplementalGroups( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions + supplementalGroups); + public java.lang.Boolean hasSupplementalGroups(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SupplementalGroupsNested withNewSupplementalGroups(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SupplementalGroupsNested withNewSupplementalGroupsLike(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions item); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SupplementalGroupsNested editSupplementalGroups(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SupplementalGroupsNested editOrNewSupplementalGroups(); - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SupplementalGroupsNested editOrNewSupplementalGroupsLike(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions item); - public A addToVolumes(java.lang.Integer index,java.lang.String item); - public A setToVolumes(java.lang.Integer index,java.lang.String item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SupplementalGroupsNested< + A> + withNewSupplementalGroups(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SupplementalGroupsNested< + A> + withNewSupplementalGroupsLike( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SupplementalGroupsNested< + A> + editSupplementalGroups(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SupplementalGroupsNested< + A> + editOrNewSupplementalGroups(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SupplementalGroupsNested< + A> + editOrNewSupplementalGroupsLike( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions item); + + public A addToVolumes(java.lang.Integer index, java.lang.String item); + + public A setToVolumes(java.lang.Integer index, java.lang.String item); + public A addToVolumes(java.lang.String... items); + public A addAllToVolumes(java.util.Collection items); + public A removeFromVolumes(java.lang.String... items); + public A removeAllFromVolumes(java.util.Collection items); + public java.util.List getVolumes(); + public java.lang.String getVolume(java.lang.Integer index); + public java.lang.String getFirstVolume(); + public java.lang.String getLastVolume(); - public java.lang.String getMatchingVolume(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVolume(java.util.function.Predicate predicate); + + public java.lang.String getMatchingVolume( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingVolume( + java.util.function.Predicate predicate); + public A withVolumes(java.util.List volumes); + public A withVolumes(java.lang.String... volumes); + public java.lang.Boolean hasVolumes(); + public A addNewVolume(java.lang.String original); - public interface AllowedCSIDriversNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent>{ + + public interface AllowedCSIDriversNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + N>> { public N and(); + public N endAllowedCSIDriver(); - } - public interface AllowedFlexVolumesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent>{ + + public interface AllowedFlexVolumesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + N>> { public N and(); + public N endAllowedFlexVolume(); - } - public interface AllowedHostPathsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent>{ + + public interface AllowedHostPathsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + N>> { public N and(); + public N endAllowedHostPath(); - } - public interface FsGroupNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent>{ + + public interface FsGroupNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested< + N>> { public N and(); + public N endFsGroup(); - } - public interface HostPortsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent>{ + + public interface HostPortsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .HostPortsNested< + N>> { public N and(); + public N endHostPort(); - } - public interface RunAsGroupNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent>{ + + public interface RunAsGroupNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .RunAsGroupNested< + N>> { public N and(); + public N endRunAsGroup(); - } - public interface RunAsUserNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent>{ + + public interface RunAsUserNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .RunAsUserNested< + N>> { public N and(); + public N endRunAsUser(); - } - public interface RuntimeClassNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent>{ + + public interface RuntimeClassNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .RuntimeClassNested< + N>> { public N and(); + public N endRuntimeClass(); - } - public interface SeLinuxNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent>{ + + public interface SeLinuxNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested< + N>> { public N and(); + public N endSeLinux(); - } - public interface SupplementalGroupsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent>{ + + public interface SupplementalGroupsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SupplementalGroupsNested< + N>> { public N and(); + public N endSupplementalGroups(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicySpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicySpecFluentImpl.java index b166502a0d..212778c8a2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicySpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PodSecurityPolicySpecFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.List; -import java.lang.Boolean; -import java.util.Collection; -import java.lang.Object; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; import java.util.Iterator; -import java.lang.Integer; +import java.util.List; - /** - * Generated - */ -public class V1beta1PodSecurityPolicySpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent{ - public V1beta1PodSecurityPolicySpecFluentImpl() { - } - public V1beta1PodSecurityPolicySpecFluentImpl(io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec instance) { +/** Generated */ +public class V1beta1PodSecurityPolicySpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent { + public V1beta1PodSecurityPolicySpecFluentImpl() {} + + public V1beta1PodSecurityPolicySpecFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpec instance) { this.withAllowPrivilegeEscalation(instance.getAllowPrivilegeEscalation()); this.withAllowedCSIDrivers(instance.getAllowedCSIDrivers()); @@ -68,13 +71,16 @@ public V1beta1PodSecurityPolicySpecFluentImpl(io.kubernetes.client.openapi.model this.withSupplementalGroups(instance.getSupplementalGroups()); this.withVolumes(instance.getVolumes()); - } + private java.lang.Boolean allowPrivilegeEscalation; - private java.util.ArrayList allowedCSIDrivers; + private java.util.ArrayList + allowedCSIDrivers; private java.util.List allowedCapabilities; - private java.util.ArrayList allowedFlexVolumes; - private java.util.ArrayList allowedHostPaths; + private java.util.ArrayList + allowedFlexVolumes; + private java.util.ArrayList + allowedHostPaths; private java.util.List allowedProcMountTypes; private java.util.List allowedUnsafeSysctls; private java.util.List defaultAddCapabilities; @@ -84,53 +90,136 @@ public V1beta1PodSecurityPolicySpecFluentImpl(io.kubernetes.client.openapi.model private java.lang.Boolean hostIPC; private java.lang.Boolean hostNetwork; private java.lang.Boolean hostPID; - private java.util.ArrayList hostPorts; + private java.util.ArrayList + hostPorts; private java.lang.Boolean privileged; private java.lang.Boolean readOnlyRootFilesystem; private java.util.List requiredDropCapabilities; private io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsBuilder runAsGroup; private io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsBuilder runAsUser; - private io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsBuilder runtimeClass; + private io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsBuilder + runtimeClass; private io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsBuilder seLinux; - private io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsBuilder supplementalGroups; + private io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsBuilder + supplementalGroups; private java.util.List volumes; + public java.lang.Boolean getAllowPrivilegeEscalation() { return this.allowPrivilegeEscalation; } + public A withAllowPrivilegeEscalation(java.lang.Boolean allowPrivilegeEscalation) { - this.allowPrivilegeEscalation=allowPrivilegeEscalation; return (A) this; + this.allowPrivilegeEscalation = allowPrivilegeEscalation; + return (A) this; } + public java.lang.Boolean hasAllowPrivilegeEscalation() { return this.allowPrivilegeEscalation != null; } - public A addToAllowedCSIDrivers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item) { - if (this.allowedCSIDrivers == null) {this.allowedCSIDrivers = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(item);_visitables.get("allowedCSIDrivers").add(index >= 0 ? index : _visitables.get("allowedCSIDrivers").size(), builder);this.allowedCSIDrivers.add(index >= 0 ? index : allowedCSIDrivers.size(), builder); return (A)this; + + public A addToAllowedCSIDrivers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item) { + if (this.allowedCSIDrivers == null) { + this.allowedCSIDrivers = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(item); + _visitables + .get("allowedCSIDrivers") + .add(index >= 0 ? index : _visitables.get("allowedCSIDrivers").size(), builder); + this.allowedCSIDrivers.add(index >= 0 ? index : allowedCSIDrivers.size(), builder); + return (A) this; } - public A setToAllowedCSIDrivers(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item) { - if (this.allowedCSIDrivers == null) {this.allowedCSIDrivers = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(item); - if (index < 0 || index >= _visitables.get("allowedCSIDrivers").size()) { _visitables.get("allowedCSIDrivers").add(builder); } else { _visitables.get("allowedCSIDrivers").set(index, builder);} - if (index < 0 || index >= allowedCSIDrivers.size()) { allowedCSIDrivers.add(builder); } else { allowedCSIDrivers.set(index, builder);} - return (A)this; + + public A setToAllowedCSIDrivers( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item) { + if (this.allowedCSIDrivers == null) { + this.allowedCSIDrivers = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(item); + if (index < 0 || index >= _visitables.get("allowedCSIDrivers").size()) { + _visitables.get("allowedCSIDrivers").add(builder); + } else { + _visitables.get("allowedCSIDrivers").set(index, builder); + } + if (index < 0 || index >= allowedCSIDrivers.size()) { + allowedCSIDrivers.add(builder); + } else { + allowedCSIDrivers.set(index, builder); + } + return (A) this; } - public A addToAllowedCSIDrivers(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver... items) { - if (this.allowedCSIDrivers == null) {this.allowedCSIDrivers = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item : items) {io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(item);_visitables.get("allowedCSIDrivers").add(builder);this.allowedCSIDrivers.add(builder);} return (A)this; + + public A addToAllowedCSIDrivers( + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver... items) { + if (this.allowedCSIDrivers == null) { + this.allowedCSIDrivers = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item : items) { + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(item); + _visitables.get("allowedCSIDrivers").add(builder); + this.allowedCSIDrivers.add(builder); + } + return (A) this; } - public A addAllToAllowedCSIDrivers(java.util.Collection items) { - if (this.allowedCSIDrivers == null) {this.allowedCSIDrivers = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item : items) {io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(item);_visitables.get("allowedCSIDrivers").add(builder);this.allowedCSIDrivers.add(builder);} return (A)this; + + public A addAllToAllowedCSIDrivers( + java.util.Collection items) { + if (this.allowedCSIDrivers == null) { + this.allowedCSIDrivers = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item : items) { + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(item); + _visitables.get("allowedCSIDrivers").add(builder); + this.allowedCSIDrivers.add(builder); + } + return (A) this; } - public A removeFromAllowedCSIDrivers(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver... items) { - for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item : items) {io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(item);_visitables.get("allowedCSIDrivers").remove(builder);if (this.allowedCSIDrivers != null) {this.allowedCSIDrivers.remove(builder);}} return (A)this; + + public A removeFromAllowedCSIDrivers( + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver... items) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item : items) { + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(item); + _visitables.get("allowedCSIDrivers").remove(builder); + if (this.allowedCSIDrivers != null) { + this.allowedCSIDrivers.remove(builder); + } + } + return (A) this; } - public A removeAllFromAllowedCSIDrivers(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item : items) {io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(item);_visitables.get("allowedCSIDrivers").remove(builder);if (this.allowedCSIDrivers != null) {this.allowedCSIDrivers.remove(builder);}} return (A)this; + + public A removeAllFromAllowedCSIDrivers( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item : items) { + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(item); + _visitables.get("allowedCSIDrivers").remove(builder); + if (this.allowedCSIDrivers != null) { + this.allowedCSIDrivers.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromAllowedCSIDrivers(java.util.function.Predicate predicate) { + + public A removeMatchingFromAllowedCSIDrivers( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder> + predicate) { if (allowedCSIDrivers == null) return (A) this; - final Iterator each = allowedCSIDrivers.iterator(); + final Iterator each = + allowedCSIDrivers.iterator(); final List visitables = _visitables.get("allowedCSIDrivers"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder = each.next(); @@ -139,158 +228,396 @@ public A removeMatchingFromAllowedCSIDrivers(java.util.function.Predicate getAllowedCSIDrivers() { + public java.util.List + getAllowedCSIDrivers() { return allowedCSIDrivers != null ? build(allowedCSIDrivers) : null; } - public java.util.List buildAllowedCSIDrivers() { + + public java.util.List + buildAllowedCSIDrivers() { return allowedCSIDrivers != null ? build(allowedCSIDrivers) : null; } - public io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver buildAllowedCSIDriver(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver buildAllowedCSIDriver( + java.lang.Integer index) { return this.allowedCSIDrivers.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver buildFirstAllowedCSIDriver() { return this.allowedCSIDrivers.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver buildLastAllowedCSIDriver() { return this.allowedCSIDrivers.get(allowedCSIDrivers.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver buildMatchingAllowedCSIDriver(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder item: allowedCSIDrivers) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver buildMatchingAllowedCSIDriver( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder item : + allowedCSIDrivers) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingAllowedCSIDriver(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder item: allowedCSIDrivers) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAllowedCSIDriver( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder item : + allowedCSIDrivers) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withAllowedCSIDrivers(java.util.List allowedCSIDrivers) { - if (this.allowedCSIDrivers != null) { _visitables.get("allowedCSIDrivers").removeAll(this.allowedCSIDrivers);} - if (allowedCSIDrivers != null) {this.allowedCSIDrivers = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item : allowedCSIDrivers){this.addToAllowedCSIDrivers(item);}} else { this.allowedCSIDrivers = null;} return (A) this; + + public A withAllowedCSIDrivers( + java.util.List + allowedCSIDrivers) { + if (this.allowedCSIDrivers != null) { + _visitables.get("allowedCSIDrivers").removeAll(this.allowedCSIDrivers); + } + if (allowedCSIDrivers != null) { + this.allowedCSIDrivers = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item : allowedCSIDrivers) { + this.addToAllowedCSIDrivers(item); + } + } else { + this.allowedCSIDrivers = null; + } + return (A) this; } - public A withAllowedCSIDrivers(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver... allowedCSIDrivers) { - if (this.allowedCSIDrivers != null) {this.allowedCSIDrivers.clear();} - if (allowedCSIDrivers != null) {for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item :allowedCSIDrivers){ this.addToAllowedCSIDrivers(item);}} return (A) this; + + public A withAllowedCSIDrivers( + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver... allowedCSIDrivers) { + if (this.allowedCSIDrivers != null) { + this.allowedCSIDrivers.clear(); + } + if (allowedCSIDrivers != null) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item : allowedCSIDrivers) { + this.addToAllowedCSIDrivers(item); + } + } + return (A) this; } + public java.lang.Boolean hasAllowedCSIDrivers() { return allowedCSIDrivers != null && !allowedCSIDrivers.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested addNewAllowedCSIDriver() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.AllowedCSIDriversNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + addNewAllowedCSIDriver() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .AllowedCSIDriversNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested addNewAllowedCSIDriverLike(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.AllowedCSIDriversNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + addNewAllowedCSIDriverLike(io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .AllowedCSIDriversNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested setNewAllowedCSIDriverLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.AllowedCSIDriversNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + setNewAllowedCSIDriverLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .AllowedCSIDriversNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested editAllowedCSIDriver(java.lang.Integer index) { - if (allowedCSIDrivers.size() <= index) throw new RuntimeException("Can't edit allowedCSIDrivers. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + editAllowedCSIDriver(java.lang.Integer index) { + if (allowedCSIDrivers.size() <= index) + throw new RuntimeException("Can't edit allowedCSIDrivers. Index exceeds size."); return setNewAllowedCSIDriverLike(index, buildAllowedCSIDriver(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested editFirstAllowedCSIDriver() { - if (allowedCSIDrivers.size() == 0) throw new RuntimeException("Can't edit first allowedCSIDrivers. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + editFirstAllowedCSIDriver() { + if (allowedCSIDrivers.size() == 0) + throw new RuntimeException("Can't edit first allowedCSIDrivers. The list is empty."); return setNewAllowedCSIDriverLike(0, buildAllowedCSIDriver(0)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested editLastAllowedCSIDriver() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + editLastAllowedCSIDriver() { int index = allowedCSIDrivers.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last allowedCSIDrivers. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last allowedCSIDrivers. The list is empty."); return setNewAllowedCSIDriverLike(index, buildAllowedCSIDriver(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested editMatchingAllowedCSIDriver(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + A> + editMatchingAllowedCSIDriver( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder> + predicate) { int index = -1; - for (int i=0;i();} + + public A addToAllowedCapabilities(java.lang.Integer index, java.lang.String item) { + if (this.allowedCapabilities == null) { + this.allowedCapabilities = new java.util.ArrayList(); + } this.allowedCapabilities.add(index, item); - return (A)this; + return (A) this; } - public A setToAllowedCapabilities(java.lang.Integer index,java.lang.String item) { - if (this.allowedCapabilities == null) {this.allowedCapabilities = new java.util.ArrayList();} - this.allowedCapabilities.set(index, item); return (A)this; + + public A setToAllowedCapabilities(java.lang.Integer index, java.lang.String item) { + if (this.allowedCapabilities == null) { + this.allowedCapabilities = new java.util.ArrayList(); + } + this.allowedCapabilities.set(index, item); + return (A) this; } + public A addToAllowedCapabilities(java.lang.String... items) { - if (this.allowedCapabilities == null) {this.allowedCapabilities = new java.util.ArrayList();} - for (java.lang.String item : items) {this.allowedCapabilities.add(item);} return (A)this; + if (this.allowedCapabilities == null) { + this.allowedCapabilities = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.allowedCapabilities.add(item); + } + return (A) this; } + public A addAllToAllowedCapabilities(java.util.Collection items) { - if (this.allowedCapabilities == null) {this.allowedCapabilities = new java.util.ArrayList();} - for (java.lang.String item : items) {this.allowedCapabilities.add(item);} return (A)this; + if (this.allowedCapabilities == null) { + this.allowedCapabilities = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.allowedCapabilities.add(item); + } + return (A) this; } + public A removeFromAllowedCapabilities(java.lang.String... items) { - for (java.lang.String item : items) {if (this.allowedCapabilities!= null){ this.allowedCapabilities.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.allowedCapabilities != null) { + this.allowedCapabilities.remove(item); + } + } + return (A) this; } + public A removeAllFromAllowedCapabilities(java.util.Collection items) { - for (java.lang.String item : items) {if (this.allowedCapabilities!= null){ this.allowedCapabilities.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.allowedCapabilities != null) { + this.allowedCapabilities.remove(item); + } + } + return (A) this; } + public java.util.List getAllowedCapabilities() { return this.allowedCapabilities; } + public java.lang.String getAllowedCapability(java.lang.Integer index) { return this.allowedCapabilities.get(index); } + public java.lang.String getFirstAllowedCapability() { return this.allowedCapabilities.get(0); } + public java.lang.String getLastAllowedCapability() { return this.allowedCapabilities.get(allowedCapabilities.size() - 1); } - public java.lang.String getMatchingAllowedCapability(java.util.function.Predicate predicate) { - for (java.lang.String item: allowedCapabilities) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAllowedCapability( + java.util.function.Predicate predicate) { + for (java.lang.String item : allowedCapabilities) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAllowedCapability(java.util.function.Predicate predicate) { - for (java.lang.String item: allowedCapabilities) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAllowedCapability( + java.util.function.Predicate predicate) { + for (java.lang.String item : allowedCapabilities) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAllowedCapabilities(java.util.List allowedCapabilities) { - if (allowedCapabilities != null) {this.allowedCapabilities = new java.util.ArrayList(); for (java.lang.String item : allowedCapabilities){this.addToAllowedCapabilities(item);}} else { this.allowedCapabilities = null;} return (A) this; + if (allowedCapabilities != null) { + this.allowedCapabilities = new java.util.ArrayList(); + for (java.lang.String item : allowedCapabilities) { + this.addToAllowedCapabilities(item); + } + } else { + this.allowedCapabilities = null; + } + return (A) this; } + public A withAllowedCapabilities(java.lang.String... allowedCapabilities) { - if (this.allowedCapabilities != null) {this.allowedCapabilities.clear();} - if (allowedCapabilities != null) {for (java.lang.String item :allowedCapabilities){ this.addToAllowedCapabilities(item);}} return (A) this; + if (this.allowedCapabilities != null) { + this.allowedCapabilities.clear(); + } + if (allowedCapabilities != null) { + for (java.lang.String item : allowedCapabilities) { + this.addToAllowedCapabilities(item); + } + } + return (A) this; } + public java.lang.Boolean hasAllowedCapabilities() { return allowedCapabilities != null && !allowedCapabilities.isEmpty(); } + public A addNewAllowedCapability(java.lang.String original) { - return (A)addToAllowedCapabilities(new String(original)); + return (A) addToAllowedCapabilities(new String(original)); } - public A addToAllowedFlexVolumes(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item) { - if (this.allowedFlexVolumes == null) {this.allowedFlexVolumes = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(item);_visitables.get("allowedFlexVolumes").add(index >= 0 ? index : _visitables.get("allowedFlexVolumes").size(), builder);this.allowedFlexVolumes.add(index >= 0 ? index : allowedFlexVolumes.size(), builder); return (A)this; + + public A addToAllowedFlexVolumes( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item) { + if (this.allowedFlexVolumes == null) { + this.allowedFlexVolumes = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(item); + _visitables + .get("allowedFlexVolumes") + .add(index >= 0 ? index : _visitables.get("allowedFlexVolumes").size(), builder); + this.allowedFlexVolumes.add(index >= 0 ? index : allowedFlexVolumes.size(), builder); + return (A) this; } - public A setToAllowedFlexVolumes(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item) { - if (this.allowedFlexVolumes == null) {this.allowedFlexVolumes = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(item); - if (index < 0 || index >= _visitables.get("allowedFlexVolumes").size()) { _visitables.get("allowedFlexVolumes").add(builder); } else { _visitables.get("allowedFlexVolumes").set(index, builder);} - if (index < 0 || index >= allowedFlexVolumes.size()) { allowedFlexVolumes.add(builder); } else { allowedFlexVolumes.set(index, builder);} - return (A)this; + + public A setToAllowedFlexVolumes( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item) { + if (this.allowedFlexVolumes == null) { + this.allowedFlexVolumes = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(item); + if (index < 0 || index >= _visitables.get("allowedFlexVolumes").size()) { + _visitables.get("allowedFlexVolumes").add(builder); + } else { + _visitables.get("allowedFlexVolumes").set(index, builder); + } + if (index < 0 || index >= allowedFlexVolumes.size()) { + allowedFlexVolumes.add(builder); + } else { + allowedFlexVolumes.set(index, builder); + } + return (A) this; } - public A addToAllowedFlexVolumes(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume... items) { - if (this.allowedFlexVolumes == null) {this.allowedFlexVolumes = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item : items) {io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(item);_visitables.get("allowedFlexVolumes").add(builder);this.allowedFlexVolumes.add(builder);} return (A)this; + + public A addToAllowedFlexVolumes( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume... items) { + if (this.allowedFlexVolumes == null) { + this.allowedFlexVolumes = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item : items) { + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(item); + _visitables.get("allowedFlexVolumes").add(builder); + this.allowedFlexVolumes.add(builder); + } + return (A) this; } - public A addAllToAllowedFlexVolumes(java.util.Collection items) { - if (this.allowedFlexVolumes == null) {this.allowedFlexVolumes = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item : items) {io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(item);_visitables.get("allowedFlexVolumes").add(builder);this.allowedFlexVolumes.add(builder);} return (A)this; + + public A addAllToAllowedFlexVolumes( + java.util.Collection items) { + if (this.allowedFlexVolumes == null) { + this.allowedFlexVolumes = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item : items) { + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(item); + _visitables.get("allowedFlexVolumes").add(builder); + this.allowedFlexVolumes.add(builder); + } + return (A) this; } - public A removeFromAllowedFlexVolumes(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume... items) { - for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item : items) {io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(item);_visitables.get("allowedFlexVolumes").remove(builder);if (this.allowedFlexVolumes != null) {this.allowedFlexVolumes.remove(builder);}} return (A)this; + + public A removeFromAllowedFlexVolumes( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume... items) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item : items) { + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(item); + _visitables.get("allowedFlexVolumes").remove(builder); + if (this.allowedFlexVolumes != null) { + this.allowedFlexVolumes.remove(builder); + } + } + return (A) this; } - public A removeAllFromAllowedFlexVolumes(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item : items) {io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(item);_visitables.get("allowedFlexVolumes").remove(builder);if (this.allowedFlexVolumes != null) {this.allowedFlexVolumes.remove(builder);}} return (A)this; + + public A removeAllFromAllowedFlexVolumes( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item : items) { + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(item); + _visitables.get("allowedFlexVolumes").remove(builder); + if (this.allowedFlexVolumes != null) { + this.allowedFlexVolumes.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromAllowedFlexVolumes(java.util.function.Predicate predicate) { + + public A removeMatchingFromAllowedFlexVolumes( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder> + predicate) { if (allowedFlexVolumes == null) return (A) this; - final Iterator each = allowedFlexVolumes.iterator(); + final Iterator each = + allowedFlexVolumes.iterator(); final List visitables = _visitables.get("allowedFlexVolumes"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder = each.next(); @@ -299,104 +626,277 @@ public A removeMatchingFromAllowedFlexVolumes(java.util.function.Predicate getAllowedFlexVolumes() { + public java.util.List + getAllowedFlexVolumes() { return allowedFlexVolumes != null ? build(allowedFlexVolumes) : null; } - public java.util.List buildAllowedFlexVolumes() { + + public java.util.List + buildAllowedFlexVolumes() { return allowedFlexVolumes != null ? build(allowedFlexVolumes) : null; } - public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume buildAllowedFlexVolume(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume buildAllowedFlexVolume( + java.lang.Integer index) { return this.allowedFlexVolumes.get(index).build(); } - public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume buildFirstAllowedFlexVolume() { + + public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume + buildFirstAllowedFlexVolume() { return this.allowedFlexVolumes.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume buildLastAllowedFlexVolume() { return this.allowedFlexVolumes.get(allowedFlexVolumes.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume buildMatchingAllowedFlexVolume(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder item: allowedFlexVolumes) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume + buildMatchingAllowedFlexVolume( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder item : + allowedFlexVolumes) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingAllowedFlexVolume(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder item: allowedFlexVolumes) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAllowedFlexVolume( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder item : + allowedFlexVolumes) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withAllowedFlexVolumes(java.util.List allowedFlexVolumes) { - if (this.allowedFlexVolumes != null) { _visitables.get("allowedFlexVolumes").removeAll(this.allowedFlexVolumes);} - if (allowedFlexVolumes != null) {this.allowedFlexVolumes = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item : allowedFlexVolumes){this.addToAllowedFlexVolumes(item);}} else { this.allowedFlexVolumes = null;} return (A) this; + + public A withAllowedFlexVolumes( + java.util.List + allowedFlexVolumes) { + if (this.allowedFlexVolumes != null) { + _visitables.get("allowedFlexVolumes").removeAll(this.allowedFlexVolumes); + } + if (allowedFlexVolumes != null) { + this.allowedFlexVolumes = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item : allowedFlexVolumes) { + this.addToAllowedFlexVolumes(item); + } + } else { + this.allowedFlexVolumes = null; + } + return (A) this; } - public A withAllowedFlexVolumes(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume... allowedFlexVolumes) { - if (this.allowedFlexVolumes != null) {this.allowedFlexVolumes.clear();} - if (allowedFlexVolumes != null) {for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item :allowedFlexVolumes){ this.addToAllowedFlexVolumes(item);}} return (A) this; + + public A withAllowedFlexVolumes( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume... allowedFlexVolumes) { + if (this.allowedFlexVolumes != null) { + this.allowedFlexVolumes.clear(); + } + if (allowedFlexVolumes != null) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item : allowedFlexVolumes) { + this.addToAllowedFlexVolumes(item); + } + } + return (A) this; } + public java.lang.Boolean hasAllowedFlexVolumes() { return allowedFlexVolumes != null && !allowedFlexVolumes.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested addNewAllowedFlexVolume() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.AllowedFlexVolumesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + addNewAllowedFlexVolume() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .AllowedFlexVolumesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested addNewAllowedFlexVolumeLike(io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.AllowedFlexVolumesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + addNewAllowedFlexVolumeLike( + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .AllowedFlexVolumesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested setNewAllowedFlexVolumeLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.AllowedFlexVolumesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + setNewAllowedFlexVolumeLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .AllowedFlexVolumesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested editAllowedFlexVolume(java.lang.Integer index) { - if (allowedFlexVolumes.size() <= index) throw new RuntimeException("Can't edit allowedFlexVolumes. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + editAllowedFlexVolume(java.lang.Integer index) { + if (allowedFlexVolumes.size() <= index) + throw new RuntimeException("Can't edit allowedFlexVolumes. Index exceeds size."); return setNewAllowedFlexVolumeLike(index, buildAllowedFlexVolume(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested editFirstAllowedFlexVolume() { - if (allowedFlexVolumes.size() == 0) throw new RuntimeException("Can't edit first allowedFlexVolumes. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + editFirstAllowedFlexVolume() { + if (allowedFlexVolumes.size() == 0) + throw new RuntimeException("Can't edit first allowedFlexVolumes. The list is empty."); return setNewAllowedFlexVolumeLike(0, buildAllowedFlexVolume(0)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested editLastAllowedFlexVolume() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + editLastAllowedFlexVolume() { int index = allowedFlexVolumes.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last allowedFlexVolumes. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last allowedFlexVolumes. The list is empty."); return setNewAllowedFlexVolumeLike(index, buildAllowedFlexVolume(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested editMatchingAllowedFlexVolume(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + A> + editMatchingAllowedFlexVolume( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(item);_visitables.get("allowedHostPaths").add(index >= 0 ? index : _visitables.get("allowedHostPaths").size(), builder);this.allowedHostPaths.add(index >= 0 ? index : allowedHostPaths.size(), builder); return (A)this; + + public A addToAllowedHostPaths( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item) { + if (this.allowedHostPaths == null) { + this.allowedHostPaths = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(item); + _visitables + .get("allowedHostPaths") + .add(index >= 0 ? index : _visitables.get("allowedHostPaths").size(), builder); + this.allowedHostPaths.add(index >= 0 ? index : allowedHostPaths.size(), builder); + return (A) this; } - public A setToAllowedHostPaths(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item) { - if (this.allowedHostPaths == null) {this.allowedHostPaths = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(item); - if (index < 0 || index >= _visitables.get("allowedHostPaths").size()) { _visitables.get("allowedHostPaths").add(builder); } else { _visitables.get("allowedHostPaths").set(index, builder);} - if (index < 0 || index >= allowedHostPaths.size()) { allowedHostPaths.add(builder); } else { allowedHostPaths.set(index, builder);} - return (A)this; + + public A setToAllowedHostPaths( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item) { + if (this.allowedHostPaths == null) { + this.allowedHostPaths = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(item); + if (index < 0 || index >= _visitables.get("allowedHostPaths").size()) { + _visitables.get("allowedHostPaths").add(builder); + } else { + _visitables.get("allowedHostPaths").set(index, builder); + } + if (index < 0 || index >= allowedHostPaths.size()) { + allowedHostPaths.add(builder); + } else { + allowedHostPaths.set(index, builder); + } + return (A) this; } - public A addToAllowedHostPaths(io.kubernetes.client.openapi.models.V1beta1AllowedHostPath... items) { - if (this.allowedHostPaths == null) {this.allowedHostPaths = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item : items) {io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(item);_visitables.get("allowedHostPaths").add(builder);this.allowedHostPaths.add(builder);} return (A)this; + + public A addToAllowedHostPaths( + io.kubernetes.client.openapi.models.V1beta1AllowedHostPath... items) { + if (this.allowedHostPaths == null) { + this.allowedHostPaths = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item : items) { + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(item); + _visitables.get("allowedHostPaths").add(builder); + this.allowedHostPaths.add(builder); + } + return (A) this; } - public A addAllToAllowedHostPaths(java.util.Collection items) { - if (this.allowedHostPaths == null) {this.allowedHostPaths = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item : items) {io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(item);_visitables.get("allowedHostPaths").add(builder);this.allowedHostPaths.add(builder);} return (A)this; + + public A addAllToAllowedHostPaths( + java.util.Collection items) { + if (this.allowedHostPaths == null) { + this.allowedHostPaths = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item : items) { + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(item); + _visitables.get("allowedHostPaths").add(builder); + this.allowedHostPaths.add(builder); + } + return (A) this; } - public A removeFromAllowedHostPaths(io.kubernetes.client.openapi.models.V1beta1AllowedHostPath... items) { - for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item : items) {io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(item);_visitables.get("allowedHostPaths").remove(builder);if (this.allowedHostPaths != null) {this.allowedHostPaths.remove(builder);}} return (A)this; + + public A removeFromAllowedHostPaths( + io.kubernetes.client.openapi.models.V1beta1AllowedHostPath... items) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item : items) { + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(item); + _visitables.get("allowedHostPaths").remove(builder); + if (this.allowedHostPaths != null) { + this.allowedHostPaths.remove(builder); + } + } + return (A) this; } - public A removeAllFromAllowedHostPaths(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item : items) {io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder = new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(item);_visitables.get("allowedHostPaths").remove(builder);if (this.allowedHostPaths != null) {this.allowedHostPaths.remove(builder);}} return (A)this; + + public A removeAllFromAllowedHostPaths( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item : items) { + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(item); + _visitables.get("allowedHostPaths").remove(builder); + if (this.allowedHostPaths != null) { + this.allowedHostPaths.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromAllowedHostPaths(java.util.function.Predicate predicate) { + + public A removeMatchingFromAllowedHostPaths( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder> + predicate) { if (allowedHostPaths == null) return (A) this; - final Iterator each = allowedHostPaths.iterator(); + final Iterator each = + allowedHostPaths.iterator(); final List visitables = _visitables.get("allowedHostPaths"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder = each.next(); @@ -405,390 +905,869 @@ public A removeMatchingFromAllowedHostPaths(java.util.function.Predicate getAllowedHostPaths() { + public java.util.List + getAllowedHostPaths() { return allowedHostPaths != null ? build(allowedHostPaths) : null; } - public java.util.List buildAllowedHostPaths() { + + public java.util.List + buildAllowedHostPaths() { return allowedHostPaths != null ? build(allowedHostPaths) : null; } - public io.kubernetes.client.openapi.models.V1beta1AllowedHostPath buildAllowedHostPath(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1AllowedHostPath buildAllowedHostPath( + java.lang.Integer index) { return this.allowedHostPaths.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1AllowedHostPath buildFirstAllowedHostPath() { return this.allowedHostPaths.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1AllowedHostPath buildLastAllowedHostPath() { return this.allowedHostPaths.get(allowedHostPaths.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1AllowedHostPath buildMatchingAllowedHostPath(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder item: allowedHostPaths) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1AllowedHostPath buildMatchingAllowedHostPath( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder item : + allowedHostPaths) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingAllowedHostPath(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder item: allowedHostPaths) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAllowedHostPath( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder item : + allowedHostPaths) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withAllowedHostPaths(java.util.List allowedHostPaths) { - if (this.allowedHostPaths != null) { _visitables.get("allowedHostPaths").removeAll(this.allowedHostPaths);} - if (allowedHostPaths != null) {this.allowedHostPaths = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item : allowedHostPaths){this.addToAllowedHostPaths(item);}} else { this.allowedHostPaths = null;} return (A) this; + + public A withAllowedHostPaths( + java.util.List allowedHostPaths) { + if (this.allowedHostPaths != null) { + _visitables.get("allowedHostPaths").removeAll(this.allowedHostPaths); + } + if (allowedHostPaths != null) { + this.allowedHostPaths = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item : allowedHostPaths) { + this.addToAllowedHostPaths(item); + } + } else { + this.allowedHostPaths = null; + } + return (A) this; } - public A withAllowedHostPaths(io.kubernetes.client.openapi.models.V1beta1AllowedHostPath... allowedHostPaths) { - if (this.allowedHostPaths != null) {this.allowedHostPaths.clear();} - if (allowedHostPaths != null) {for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item :allowedHostPaths){ this.addToAllowedHostPaths(item);}} return (A) this; + + public A withAllowedHostPaths( + io.kubernetes.client.openapi.models.V1beta1AllowedHostPath... allowedHostPaths) { + if (this.allowedHostPaths != null) { + this.allowedHostPaths.clear(); + } + if (allowedHostPaths != null) { + for (io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item : allowedHostPaths) { + this.addToAllowedHostPaths(item); + } + } + return (A) this; } + public java.lang.Boolean hasAllowedHostPaths() { return allowedHostPaths != null && !allowedHostPaths.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested addNewAllowedHostPath() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.AllowedHostPathsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + addNewAllowedHostPath() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .AllowedHostPathsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested addNewAllowedHostPathLike(io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.AllowedHostPathsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + addNewAllowedHostPathLike(io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .AllowedHostPathsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested setNewAllowedHostPathLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.AllowedHostPathsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + setNewAllowedHostPathLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .AllowedHostPathsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested editAllowedHostPath(java.lang.Integer index) { - if (allowedHostPaths.size() <= index) throw new RuntimeException("Can't edit allowedHostPaths. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + editAllowedHostPath(java.lang.Integer index) { + if (allowedHostPaths.size() <= index) + throw new RuntimeException("Can't edit allowedHostPaths. Index exceeds size."); return setNewAllowedHostPathLike(index, buildAllowedHostPath(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested editFirstAllowedHostPath() { - if (allowedHostPaths.size() == 0) throw new RuntimeException("Can't edit first allowedHostPaths. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + editFirstAllowedHostPath() { + if (allowedHostPaths.size() == 0) + throw new RuntimeException("Can't edit first allowedHostPaths. The list is empty."); return setNewAllowedHostPathLike(0, buildAllowedHostPath(0)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested editLastAllowedHostPath() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + editLastAllowedHostPath() { int index = allowedHostPaths.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last allowedHostPaths. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last allowedHostPaths. The list is empty."); return setNewAllowedHostPathLike(index, buildAllowedHostPath(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested editMatchingAllowedHostPath(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + A> + editMatchingAllowedHostPath( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder> + predicate) { int index = -1; - for (int i=0;i();} + + public A addToAllowedProcMountTypes(java.lang.Integer index, java.lang.String item) { + if (this.allowedProcMountTypes == null) { + this.allowedProcMountTypes = new java.util.ArrayList(); + } this.allowedProcMountTypes.add(index, item); - return (A)this; + return (A) this; } - public A setToAllowedProcMountTypes(java.lang.Integer index,java.lang.String item) { - if (this.allowedProcMountTypes == null) {this.allowedProcMountTypes = new java.util.ArrayList();} - this.allowedProcMountTypes.set(index, item); return (A)this; + + public A setToAllowedProcMountTypes(java.lang.Integer index, java.lang.String item) { + if (this.allowedProcMountTypes == null) { + this.allowedProcMountTypes = new java.util.ArrayList(); + } + this.allowedProcMountTypes.set(index, item); + return (A) this; } + public A addToAllowedProcMountTypes(java.lang.String... items) { - if (this.allowedProcMountTypes == null) {this.allowedProcMountTypes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.allowedProcMountTypes.add(item);} return (A)this; + if (this.allowedProcMountTypes == null) { + this.allowedProcMountTypes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.allowedProcMountTypes.add(item); + } + return (A) this; } + public A addAllToAllowedProcMountTypes(java.util.Collection items) { - if (this.allowedProcMountTypes == null) {this.allowedProcMountTypes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.allowedProcMountTypes.add(item);} return (A)this; + if (this.allowedProcMountTypes == null) { + this.allowedProcMountTypes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.allowedProcMountTypes.add(item); + } + return (A) this; } + public A removeFromAllowedProcMountTypes(java.lang.String... items) { - for (java.lang.String item : items) {if (this.allowedProcMountTypes!= null){ this.allowedProcMountTypes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.allowedProcMountTypes != null) { + this.allowedProcMountTypes.remove(item); + } + } + return (A) this; } + public A removeAllFromAllowedProcMountTypes(java.util.Collection items) { - for (java.lang.String item : items) {if (this.allowedProcMountTypes!= null){ this.allowedProcMountTypes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.allowedProcMountTypes != null) { + this.allowedProcMountTypes.remove(item); + } + } + return (A) this; } + public java.util.List getAllowedProcMountTypes() { return this.allowedProcMountTypes; } + public java.lang.String getAllowedProcMountType(java.lang.Integer index) { return this.allowedProcMountTypes.get(index); } + public java.lang.String getFirstAllowedProcMountType() { return this.allowedProcMountTypes.get(0); } + public java.lang.String getLastAllowedProcMountType() { return this.allowedProcMountTypes.get(allowedProcMountTypes.size() - 1); } - public java.lang.String getMatchingAllowedProcMountType(java.util.function.Predicate predicate) { - for (java.lang.String item: allowedProcMountTypes) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAllowedProcMountType( + java.util.function.Predicate predicate) { + for (java.lang.String item : allowedProcMountTypes) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAllowedProcMountType(java.util.function.Predicate predicate) { - for (java.lang.String item: allowedProcMountTypes) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAllowedProcMountType( + java.util.function.Predicate predicate) { + for (java.lang.String item : allowedProcMountTypes) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAllowedProcMountTypes(java.util.List allowedProcMountTypes) { - if (allowedProcMountTypes != null) {this.allowedProcMountTypes = new java.util.ArrayList(); for (java.lang.String item : allowedProcMountTypes){this.addToAllowedProcMountTypes(item);}} else { this.allowedProcMountTypes = null;} return (A) this; + if (allowedProcMountTypes != null) { + this.allowedProcMountTypes = new java.util.ArrayList(); + for (java.lang.String item : allowedProcMountTypes) { + this.addToAllowedProcMountTypes(item); + } + } else { + this.allowedProcMountTypes = null; + } + return (A) this; } + public A withAllowedProcMountTypes(java.lang.String... allowedProcMountTypes) { - if (this.allowedProcMountTypes != null) {this.allowedProcMountTypes.clear();} - if (allowedProcMountTypes != null) {for (java.lang.String item :allowedProcMountTypes){ this.addToAllowedProcMountTypes(item);}} return (A) this; + if (this.allowedProcMountTypes != null) { + this.allowedProcMountTypes.clear(); + } + if (allowedProcMountTypes != null) { + for (java.lang.String item : allowedProcMountTypes) { + this.addToAllowedProcMountTypes(item); + } + } + return (A) this; } + public java.lang.Boolean hasAllowedProcMountTypes() { return allowedProcMountTypes != null && !allowedProcMountTypes.isEmpty(); } + public A addNewAllowedProcMountType(java.lang.String original) { - return (A)addToAllowedProcMountTypes(new String(original)); + return (A) addToAllowedProcMountTypes(new String(original)); } - public A addToAllowedUnsafeSysctls(java.lang.Integer index,java.lang.String item) { - if (this.allowedUnsafeSysctls == null) {this.allowedUnsafeSysctls = new java.util.ArrayList();} + + public A addToAllowedUnsafeSysctls(java.lang.Integer index, java.lang.String item) { + if (this.allowedUnsafeSysctls == null) { + this.allowedUnsafeSysctls = new java.util.ArrayList(); + } this.allowedUnsafeSysctls.add(index, item); - return (A)this; + return (A) this; } - public A setToAllowedUnsafeSysctls(java.lang.Integer index,java.lang.String item) { - if (this.allowedUnsafeSysctls == null) {this.allowedUnsafeSysctls = new java.util.ArrayList();} - this.allowedUnsafeSysctls.set(index, item); return (A)this; + + public A setToAllowedUnsafeSysctls(java.lang.Integer index, java.lang.String item) { + if (this.allowedUnsafeSysctls == null) { + this.allowedUnsafeSysctls = new java.util.ArrayList(); + } + this.allowedUnsafeSysctls.set(index, item); + return (A) this; } + public A addToAllowedUnsafeSysctls(java.lang.String... items) { - if (this.allowedUnsafeSysctls == null) {this.allowedUnsafeSysctls = new java.util.ArrayList();} - for (java.lang.String item : items) {this.allowedUnsafeSysctls.add(item);} return (A)this; + if (this.allowedUnsafeSysctls == null) { + this.allowedUnsafeSysctls = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.allowedUnsafeSysctls.add(item); + } + return (A) this; } + public A addAllToAllowedUnsafeSysctls(java.util.Collection items) { - if (this.allowedUnsafeSysctls == null) {this.allowedUnsafeSysctls = new java.util.ArrayList();} - for (java.lang.String item : items) {this.allowedUnsafeSysctls.add(item);} return (A)this; + if (this.allowedUnsafeSysctls == null) { + this.allowedUnsafeSysctls = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.allowedUnsafeSysctls.add(item); + } + return (A) this; } + public A removeFromAllowedUnsafeSysctls(java.lang.String... items) { - for (java.lang.String item : items) {if (this.allowedUnsafeSysctls!= null){ this.allowedUnsafeSysctls.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.allowedUnsafeSysctls != null) { + this.allowedUnsafeSysctls.remove(item); + } + } + return (A) this; } + public A removeAllFromAllowedUnsafeSysctls(java.util.Collection items) { - for (java.lang.String item : items) {if (this.allowedUnsafeSysctls!= null){ this.allowedUnsafeSysctls.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.allowedUnsafeSysctls != null) { + this.allowedUnsafeSysctls.remove(item); + } + } + return (A) this; } + public java.util.List getAllowedUnsafeSysctls() { return this.allowedUnsafeSysctls; } + public java.lang.String getAllowedUnsafeSysctl(java.lang.Integer index) { return this.allowedUnsafeSysctls.get(index); } + public java.lang.String getFirstAllowedUnsafeSysctl() { return this.allowedUnsafeSysctls.get(0); } + public java.lang.String getLastAllowedUnsafeSysctl() { return this.allowedUnsafeSysctls.get(allowedUnsafeSysctls.size() - 1); } - public java.lang.String getMatchingAllowedUnsafeSysctl(java.util.function.Predicate predicate) { - for (java.lang.String item: allowedUnsafeSysctls) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAllowedUnsafeSysctl( + java.util.function.Predicate predicate) { + for (java.lang.String item : allowedUnsafeSysctls) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAllowedUnsafeSysctl(java.util.function.Predicate predicate) { - for (java.lang.String item: allowedUnsafeSysctls) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAllowedUnsafeSysctl( + java.util.function.Predicate predicate) { + for (java.lang.String item : allowedUnsafeSysctls) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAllowedUnsafeSysctls(java.util.List allowedUnsafeSysctls) { - if (allowedUnsafeSysctls != null) {this.allowedUnsafeSysctls = new java.util.ArrayList(); for (java.lang.String item : allowedUnsafeSysctls){this.addToAllowedUnsafeSysctls(item);}} else { this.allowedUnsafeSysctls = null;} return (A) this; + if (allowedUnsafeSysctls != null) { + this.allowedUnsafeSysctls = new java.util.ArrayList(); + for (java.lang.String item : allowedUnsafeSysctls) { + this.addToAllowedUnsafeSysctls(item); + } + } else { + this.allowedUnsafeSysctls = null; + } + return (A) this; } + public A withAllowedUnsafeSysctls(java.lang.String... allowedUnsafeSysctls) { - if (this.allowedUnsafeSysctls != null) {this.allowedUnsafeSysctls.clear();} - if (allowedUnsafeSysctls != null) {for (java.lang.String item :allowedUnsafeSysctls){ this.addToAllowedUnsafeSysctls(item);}} return (A) this; + if (this.allowedUnsafeSysctls != null) { + this.allowedUnsafeSysctls.clear(); + } + if (allowedUnsafeSysctls != null) { + for (java.lang.String item : allowedUnsafeSysctls) { + this.addToAllowedUnsafeSysctls(item); + } + } + return (A) this; } + public java.lang.Boolean hasAllowedUnsafeSysctls() { return allowedUnsafeSysctls != null && !allowedUnsafeSysctls.isEmpty(); } + public A addNewAllowedUnsafeSysctl(java.lang.String original) { - return (A)addToAllowedUnsafeSysctls(new String(original)); + return (A) addToAllowedUnsafeSysctls(new String(original)); } - public A addToDefaultAddCapabilities(java.lang.Integer index,java.lang.String item) { - if (this.defaultAddCapabilities == null) {this.defaultAddCapabilities = new java.util.ArrayList();} + + public A addToDefaultAddCapabilities(java.lang.Integer index, java.lang.String item) { + if (this.defaultAddCapabilities == null) { + this.defaultAddCapabilities = new java.util.ArrayList(); + } this.defaultAddCapabilities.add(index, item); - return (A)this; + return (A) this; } - public A setToDefaultAddCapabilities(java.lang.Integer index,java.lang.String item) { - if (this.defaultAddCapabilities == null) {this.defaultAddCapabilities = new java.util.ArrayList();} - this.defaultAddCapabilities.set(index, item); return (A)this; + + public A setToDefaultAddCapabilities(java.lang.Integer index, java.lang.String item) { + if (this.defaultAddCapabilities == null) { + this.defaultAddCapabilities = new java.util.ArrayList(); + } + this.defaultAddCapabilities.set(index, item); + return (A) this; } + public A addToDefaultAddCapabilities(java.lang.String... items) { - if (this.defaultAddCapabilities == null) {this.defaultAddCapabilities = new java.util.ArrayList();} - for (java.lang.String item : items) {this.defaultAddCapabilities.add(item);} return (A)this; + if (this.defaultAddCapabilities == null) { + this.defaultAddCapabilities = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.defaultAddCapabilities.add(item); + } + return (A) this; } + public A addAllToDefaultAddCapabilities(java.util.Collection items) { - if (this.defaultAddCapabilities == null) {this.defaultAddCapabilities = new java.util.ArrayList();} - for (java.lang.String item : items) {this.defaultAddCapabilities.add(item);} return (A)this; + if (this.defaultAddCapabilities == null) { + this.defaultAddCapabilities = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.defaultAddCapabilities.add(item); + } + return (A) this; } + public A removeFromDefaultAddCapabilities(java.lang.String... items) { - for (java.lang.String item : items) {if (this.defaultAddCapabilities!= null){ this.defaultAddCapabilities.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.defaultAddCapabilities != null) { + this.defaultAddCapabilities.remove(item); + } + } + return (A) this; } + public A removeAllFromDefaultAddCapabilities(java.util.Collection items) { - for (java.lang.String item : items) {if (this.defaultAddCapabilities!= null){ this.defaultAddCapabilities.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.defaultAddCapabilities != null) { + this.defaultAddCapabilities.remove(item); + } + } + return (A) this; } + public java.util.List getDefaultAddCapabilities() { return this.defaultAddCapabilities; } + public java.lang.String getDefaultAddCapability(java.lang.Integer index) { return this.defaultAddCapabilities.get(index); } + public java.lang.String getFirstDefaultAddCapability() { return this.defaultAddCapabilities.get(0); } + public java.lang.String getLastDefaultAddCapability() { return this.defaultAddCapabilities.get(defaultAddCapabilities.size() - 1); } - public java.lang.String getMatchingDefaultAddCapability(java.util.function.Predicate predicate) { - for (java.lang.String item: defaultAddCapabilities) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingDefaultAddCapability( + java.util.function.Predicate predicate) { + for (java.lang.String item : defaultAddCapabilities) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingDefaultAddCapability(java.util.function.Predicate predicate) { - for (java.lang.String item: defaultAddCapabilities) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingDefaultAddCapability( + java.util.function.Predicate predicate) { + for (java.lang.String item : defaultAddCapabilities) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withDefaultAddCapabilities(java.util.List defaultAddCapabilities) { - if (defaultAddCapabilities != null) {this.defaultAddCapabilities = new java.util.ArrayList(); for (java.lang.String item : defaultAddCapabilities){this.addToDefaultAddCapabilities(item);}} else { this.defaultAddCapabilities = null;} return (A) this; + if (defaultAddCapabilities != null) { + this.defaultAddCapabilities = new java.util.ArrayList(); + for (java.lang.String item : defaultAddCapabilities) { + this.addToDefaultAddCapabilities(item); + } + } else { + this.defaultAddCapabilities = null; + } + return (A) this; } + public A withDefaultAddCapabilities(java.lang.String... defaultAddCapabilities) { - if (this.defaultAddCapabilities != null) {this.defaultAddCapabilities.clear();} - if (defaultAddCapabilities != null) {for (java.lang.String item :defaultAddCapabilities){ this.addToDefaultAddCapabilities(item);}} return (A) this; + if (this.defaultAddCapabilities != null) { + this.defaultAddCapabilities.clear(); + } + if (defaultAddCapabilities != null) { + for (java.lang.String item : defaultAddCapabilities) { + this.addToDefaultAddCapabilities(item); + } + } + return (A) this; } + public java.lang.Boolean hasDefaultAddCapabilities() { return defaultAddCapabilities != null && !defaultAddCapabilities.isEmpty(); } + public A addNewDefaultAddCapability(java.lang.String original) { - return (A)addToDefaultAddCapabilities(new String(original)); + return (A) addToDefaultAddCapabilities(new String(original)); } + public java.lang.Boolean getDefaultAllowPrivilegeEscalation() { return this.defaultAllowPrivilegeEscalation; } + public A withDefaultAllowPrivilegeEscalation(java.lang.Boolean defaultAllowPrivilegeEscalation) { - this.defaultAllowPrivilegeEscalation=defaultAllowPrivilegeEscalation; return (A) this; + this.defaultAllowPrivilegeEscalation = defaultAllowPrivilegeEscalation; + return (A) this; } + public java.lang.Boolean hasDefaultAllowPrivilegeEscalation() { return this.defaultAllowPrivilegeEscalation != null; } - public A addToForbiddenSysctls(java.lang.Integer index,java.lang.String item) { - if (this.forbiddenSysctls == null) {this.forbiddenSysctls = new java.util.ArrayList();} + + public A addToForbiddenSysctls(java.lang.Integer index, java.lang.String item) { + if (this.forbiddenSysctls == null) { + this.forbiddenSysctls = new java.util.ArrayList(); + } this.forbiddenSysctls.add(index, item); - return (A)this; + return (A) this; } - public A setToForbiddenSysctls(java.lang.Integer index,java.lang.String item) { - if (this.forbiddenSysctls == null) {this.forbiddenSysctls = new java.util.ArrayList();} - this.forbiddenSysctls.set(index, item); return (A)this; + + public A setToForbiddenSysctls(java.lang.Integer index, java.lang.String item) { + if (this.forbiddenSysctls == null) { + this.forbiddenSysctls = new java.util.ArrayList(); + } + this.forbiddenSysctls.set(index, item); + return (A) this; } + public A addToForbiddenSysctls(java.lang.String... items) { - if (this.forbiddenSysctls == null) {this.forbiddenSysctls = new java.util.ArrayList();} - for (java.lang.String item : items) {this.forbiddenSysctls.add(item);} return (A)this; + if (this.forbiddenSysctls == null) { + this.forbiddenSysctls = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.forbiddenSysctls.add(item); + } + return (A) this; } + public A addAllToForbiddenSysctls(java.util.Collection items) { - if (this.forbiddenSysctls == null) {this.forbiddenSysctls = new java.util.ArrayList();} - for (java.lang.String item : items) {this.forbiddenSysctls.add(item);} return (A)this; + if (this.forbiddenSysctls == null) { + this.forbiddenSysctls = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.forbiddenSysctls.add(item); + } + return (A) this; } + public A removeFromForbiddenSysctls(java.lang.String... items) { - for (java.lang.String item : items) {if (this.forbiddenSysctls!= null){ this.forbiddenSysctls.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.forbiddenSysctls != null) { + this.forbiddenSysctls.remove(item); + } + } + return (A) this; } + public A removeAllFromForbiddenSysctls(java.util.Collection items) { - for (java.lang.String item : items) {if (this.forbiddenSysctls!= null){ this.forbiddenSysctls.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.forbiddenSysctls != null) { + this.forbiddenSysctls.remove(item); + } + } + return (A) this; } + public java.util.List getForbiddenSysctls() { return this.forbiddenSysctls; } + public java.lang.String getForbiddenSysctl(java.lang.Integer index) { return this.forbiddenSysctls.get(index); } + public java.lang.String getFirstForbiddenSysctl() { return this.forbiddenSysctls.get(0); } + public java.lang.String getLastForbiddenSysctl() { return this.forbiddenSysctls.get(forbiddenSysctls.size() - 1); } - public java.lang.String getMatchingForbiddenSysctl(java.util.function.Predicate predicate) { - for (java.lang.String item: forbiddenSysctls) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingForbiddenSysctl( + java.util.function.Predicate predicate) { + for (java.lang.String item : forbiddenSysctls) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingForbiddenSysctl(java.util.function.Predicate predicate) { - for (java.lang.String item: forbiddenSysctls) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingForbiddenSysctl( + java.util.function.Predicate predicate) { + for (java.lang.String item : forbiddenSysctls) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withForbiddenSysctls(java.util.List forbiddenSysctls) { - if (forbiddenSysctls != null) {this.forbiddenSysctls = new java.util.ArrayList(); for (java.lang.String item : forbiddenSysctls){this.addToForbiddenSysctls(item);}} else { this.forbiddenSysctls = null;} return (A) this; + if (forbiddenSysctls != null) { + this.forbiddenSysctls = new java.util.ArrayList(); + for (java.lang.String item : forbiddenSysctls) { + this.addToForbiddenSysctls(item); + } + } else { + this.forbiddenSysctls = null; + } + return (A) this; } + public A withForbiddenSysctls(java.lang.String... forbiddenSysctls) { - if (this.forbiddenSysctls != null) {this.forbiddenSysctls.clear();} - if (forbiddenSysctls != null) {for (java.lang.String item :forbiddenSysctls){ this.addToForbiddenSysctls(item);}} return (A) this; + if (this.forbiddenSysctls != null) { + this.forbiddenSysctls.clear(); + } + if (forbiddenSysctls != null) { + for (java.lang.String item : forbiddenSysctls) { + this.addToForbiddenSysctls(item); + } + } + return (A) this; } + public java.lang.Boolean hasForbiddenSysctls() { return forbiddenSysctls != null && !forbiddenSysctls.isEmpty(); } + public A addNewForbiddenSysctl(java.lang.String original) { - return (A)addToForbiddenSysctls(new String(original)); + return (A) addToForbiddenSysctls(new String(original)); } - + /** * This method has been deprecated, please use method buildFsGroup instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions getFsGroup() { - return this.fsGroup!=null ?this.fsGroup.build():null; + return this.fsGroup != null ? this.fsGroup.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions buildFsGroup() { - return this.fsGroup!=null ?this.fsGroup.build():null; + return this.fsGroup != null ? this.fsGroup.build() : null; } + public A withFsGroup(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions fsGroup) { _visitables.get("fsGroup").remove(this.fsGroup); - if (fsGroup!=null){ this.fsGroup= new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsBuilder(fsGroup); _visitables.get("fsGroup").add(this.fsGroup);} return (A) this; + if (fsGroup != null) { + this.fsGroup = + new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsBuilder(fsGroup); + _visitables.get("fsGroup").add(this.fsGroup); + } + return (A) this; } + public java.lang.Boolean hasFsGroup() { return this.fsGroup != null; } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested withNewFsGroup() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.FsGroupNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested + withNewFsGroup() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .FsGroupNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested withNewFsGroupLike(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.FsGroupNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested + withNewFsGroupLike(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .FsGroupNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested editFsGroup() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested + editFsGroup() { return withNewFsGroupLike(getFsGroup()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested editOrNewFsGroup() { - return withNewFsGroupLike(getFsGroup() != null ? getFsGroup(): new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested + editOrNewFsGroup() { + return withNewFsGroupLike( + getFsGroup() != null + ? getFsGroup() + : new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested editOrNewFsGroupLike(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions item) { - return withNewFsGroupLike(getFsGroup() != null ? getFsGroup(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested + editOrNewFsGroupLike(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions item) { + return withNewFsGroupLike(getFsGroup() != null ? getFsGroup() : item); } + public java.lang.Boolean getHostIPC() { return this.hostIPC; } + public A withHostIPC(java.lang.Boolean hostIPC) { - this.hostIPC=hostIPC; return (A) this; + this.hostIPC = hostIPC; + return (A) this; } + public java.lang.Boolean hasHostIPC() { return this.hostIPC != null; } + public java.lang.Boolean getHostNetwork() { return this.hostNetwork; } + public A withHostNetwork(java.lang.Boolean hostNetwork) { - this.hostNetwork=hostNetwork; return (A) this; + this.hostNetwork = hostNetwork; + return (A) this; } + public java.lang.Boolean hasHostNetwork() { return this.hostNetwork != null; } + public java.lang.Boolean getHostPID() { return this.hostPID; } + public A withHostPID(java.lang.Boolean hostPID) { - this.hostPID=hostPID; return (A) this; + this.hostPID = hostPID; + return (A) this; } + public java.lang.Boolean hasHostPID() { return this.hostPID != null; } - public A addToHostPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1HostPortRange item) { - if (this.hostPorts == null) {this.hostPorts = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(item);_visitables.get("hostPorts").add(index >= 0 ? index : _visitables.get("hostPorts").size(), builder);this.hostPorts.add(index >= 0 ? index : hostPorts.size(), builder); return (A)this; + + public A addToHostPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1HostPortRange item) { + if (this.hostPorts == null) { + this.hostPorts = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(item); + _visitables + .get("hostPorts") + .add(index >= 0 ? index : _visitables.get("hostPorts").size(), builder); + this.hostPorts.add(index >= 0 ? index : hostPorts.size(), builder); + return (A) this; } - public A setToHostPorts(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1HostPortRange item) { - if (this.hostPorts == null) {this.hostPorts = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(item); - if (index < 0 || index >= _visitables.get("hostPorts").size()) { _visitables.get("hostPorts").add(builder); } else { _visitables.get("hostPorts").set(index, builder);} - if (index < 0 || index >= hostPorts.size()) { hostPorts.add(builder); } else { hostPorts.set(index, builder);} - return (A)this; + + public A setToHostPorts( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1HostPortRange item) { + if (this.hostPorts == null) { + this.hostPorts = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(item); + if (index < 0 || index >= _visitables.get("hostPorts").size()) { + _visitables.get("hostPorts").add(builder); + } else { + _visitables.get("hostPorts").set(index, builder); + } + if (index < 0 || index >= hostPorts.size()) { + hostPorts.add(builder); + } else { + hostPorts.set(index, builder); + } + return (A) this; } + public A addToHostPorts(io.kubernetes.client.openapi.models.V1beta1HostPortRange... items) { - if (this.hostPorts == null) {this.hostPorts = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1HostPortRange item : items) {io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(item);_visitables.get("hostPorts").add(builder);this.hostPorts.add(builder);} return (A)this; + if (this.hostPorts == null) { + this.hostPorts = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1HostPortRange item : items) { + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(item); + _visitables.get("hostPorts").add(builder); + this.hostPorts.add(builder); + } + return (A) this; } - public A addAllToHostPorts(java.util.Collection items) { - if (this.hostPorts == null) {this.hostPorts = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1HostPortRange item : items) {io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(item);_visitables.get("hostPorts").add(builder);this.hostPorts.add(builder);} return (A)this; + + public A addAllToHostPorts( + java.util.Collection items) { + if (this.hostPorts == null) { + this.hostPorts = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1HostPortRange item : items) { + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(item); + _visitables.get("hostPorts").add(builder); + this.hostPorts.add(builder); + } + return (A) this; } + public A removeFromHostPorts(io.kubernetes.client.openapi.models.V1beta1HostPortRange... items) { - for (io.kubernetes.client.openapi.models.V1beta1HostPortRange item : items) {io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(item);_visitables.get("hostPorts").remove(builder);if (this.hostPorts != null) {this.hostPorts.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1HostPortRange item : items) { + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(item); + _visitables.get("hostPorts").remove(builder); + if (this.hostPorts != null) { + this.hostPorts.remove(builder); + } + } + return (A) this; } - public A removeAllFromHostPorts(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1HostPortRange item : items) {io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(item);_visitables.get("hostPorts").remove(builder);if (this.hostPorts != null) {this.hostPorts.remove(builder);}} return (A)this; + + public A removeAllFromHostPorts( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1HostPortRange item : items) { + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(item); + _visitables.get("hostPorts").remove(builder); + if (this.hostPorts != null) { + this.hostPorts.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromHostPorts(java.util.function.Predicate predicate) { + + public A removeMatchingFromHostPorts( + java.util.function.Predicate + predicate) { if (hostPorts == null) return (A) this; - final Iterator each = hostPorts.iterator(); + final Iterator each = + hostPorts.iterator(); final List visitables = _visitables.get("hostPorts"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder = each.next(); @@ -797,576 +1776,1154 @@ public A removeMatchingFromHostPorts(java.util.function.Predicate getHostPorts() { return hostPorts != null ? build(hostPorts) : null; } + public java.util.List buildHostPorts() { return hostPorts != null ? build(hostPorts) : null; } - public io.kubernetes.client.openapi.models.V1beta1HostPortRange buildHostPort(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1HostPortRange buildHostPort( + java.lang.Integer index) { return this.hostPorts.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1HostPortRange buildFirstHostPort() { return this.hostPorts.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1HostPortRange buildLastHostPort() { return this.hostPorts.get(hostPorts.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1HostPortRange buildMatchingHostPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder item: hostPorts) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1HostPortRange buildMatchingHostPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder item : hostPorts) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingHostPort(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder item: hostPorts) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingHostPort( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder item : hostPorts) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withHostPorts(java.util.List hostPorts) { - if (this.hostPorts != null) { _visitables.get("hostPorts").removeAll(this.hostPorts);} - if (hostPorts != null) {this.hostPorts = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1HostPortRange item : hostPorts){this.addToHostPorts(item);}} else { this.hostPorts = null;} return (A) this; + + public A withHostPorts( + java.util.List hostPorts) { + if (this.hostPorts != null) { + _visitables.get("hostPorts").removeAll(this.hostPorts); + } + if (hostPorts != null) { + this.hostPorts = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1HostPortRange item : hostPorts) { + this.addToHostPorts(item); + } + } else { + this.hostPorts = null; + } + return (A) this; } + public A withHostPorts(io.kubernetes.client.openapi.models.V1beta1HostPortRange... hostPorts) { - if (this.hostPorts != null) {this.hostPorts.clear();} - if (hostPorts != null) {for (io.kubernetes.client.openapi.models.V1beta1HostPortRange item :hostPorts){ this.addToHostPorts(item);}} return (A) this; + if (this.hostPorts != null) { + this.hostPorts.clear(); + } + if (hostPorts != null) { + for (io.kubernetes.client.openapi.models.V1beta1HostPortRange item : hostPorts) { + this.addToHostPorts(item); + } + } + return (A) this; } + public java.lang.Boolean hasHostPorts() { return hostPorts != null && !hostPorts.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested addNewHostPort() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.HostPortsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + addNewHostPort() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .HostPortsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested addNewHostPortLike(io.kubernetes.client.openapi.models.V1beta1HostPortRange item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.HostPortsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + addNewHostPortLike(io.kubernetes.client.openapi.models.V1beta1HostPortRange item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .HostPortsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested setNewHostPortLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1HostPortRange item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.HostPortsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + setNewHostPortLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1HostPortRange item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .HostPortsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested editHostPort(java.lang.Integer index) { - if (hostPorts.size() <= index) throw new RuntimeException("Can't edit hostPorts. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + editHostPort(java.lang.Integer index) { + if (hostPorts.size() <= index) + throw new RuntimeException("Can't edit hostPorts. Index exceeds size."); return setNewHostPortLike(index, buildHostPort(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested editFirstHostPort() { - if (hostPorts.size() == 0) throw new RuntimeException("Can't edit first hostPorts. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + editFirstHostPort() { + if (hostPorts.size() == 0) + throw new RuntimeException("Can't edit first hostPorts. The list is empty."); return setNewHostPortLike(0, buildHostPort(0)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested editLastHostPort() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + editLastHostPort() { int index = hostPorts.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last hostPorts. The list is empty."); return setNewHostPortLike(index, buildHostPort(index)); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested editMatchingHostPort(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested + editMatchingHostPort( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder> + predicate) { int index = -1; - for (int i=0;i();} + + public A addToRequiredDropCapabilities(java.lang.Integer index, java.lang.String item) { + if (this.requiredDropCapabilities == null) { + this.requiredDropCapabilities = new java.util.ArrayList(); + } this.requiredDropCapabilities.add(index, item); - return (A)this; + return (A) this; } - public A setToRequiredDropCapabilities(java.lang.Integer index,java.lang.String item) { - if (this.requiredDropCapabilities == null) {this.requiredDropCapabilities = new java.util.ArrayList();} - this.requiredDropCapabilities.set(index, item); return (A)this; + + public A setToRequiredDropCapabilities(java.lang.Integer index, java.lang.String item) { + if (this.requiredDropCapabilities == null) { + this.requiredDropCapabilities = new java.util.ArrayList(); + } + this.requiredDropCapabilities.set(index, item); + return (A) this; } + public A addToRequiredDropCapabilities(java.lang.String... items) { - if (this.requiredDropCapabilities == null) {this.requiredDropCapabilities = new java.util.ArrayList();} - for (java.lang.String item : items) {this.requiredDropCapabilities.add(item);} return (A)this; + if (this.requiredDropCapabilities == null) { + this.requiredDropCapabilities = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.requiredDropCapabilities.add(item); + } + return (A) this; } + public A addAllToRequiredDropCapabilities(java.util.Collection items) { - if (this.requiredDropCapabilities == null) {this.requiredDropCapabilities = new java.util.ArrayList();} - for (java.lang.String item : items) {this.requiredDropCapabilities.add(item);} return (A)this; + if (this.requiredDropCapabilities == null) { + this.requiredDropCapabilities = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.requiredDropCapabilities.add(item); + } + return (A) this; } + public A removeFromRequiredDropCapabilities(java.lang.String... items) { - for (java.lang.String item : items) {if (this.requiredDropCapabilities!= null){ this.requiredDropCapabilities.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.requiredDropCapabilities != null) { + this.requiredDropCapabilities.remove(item); + } + } + return (A) this; } + public A removeAllFromRequiredDropCapabilities(java.util.Collection items) { - for (java.lang.String item : items) {if (this.requiredDropCapabilities!= null){ this.requiredDropCapabilities.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.requiredDropCapabilities != null) { + this.requiredDropCapabilities.remove(item); + } + } + return (A) this; } + public java.util.List getRequiredDropCapabilities() { return this.requiredDropCapabilities; } + public java.lang.String getRequiredDropCapability(java.lang.Integer index) { return this.requiredDropCapabilities.get(index); } + public java.lang.String getFirstRequiredDropCapability() { return this.requiredDropCapabilities.get(0); } + public java.lang.String getLastRequiredDropCapability() { return this.requiredDropCapabilities.get(requiredDropCapabilities.size() - 1); } - public java.lang.String getMatchingRequiredDropCapability(java.util.function.Predicate predicate) { - for (java.lang.String item: requiredDropCapabilities) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingRequiredDropCapability( + java.util.function.Predicate predicate) { + for (java.lang.String item : requiredDropCapabilities) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingRequiredDropCapability(java.util.function.Predicate predicate) { - for (java.lang.String item: requiredDropCapabilities) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRequiredDropCapability( + java.util.function.Predicate predicate) { + for (java.lang.String item : requiredDropCapabilities) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withRequiredDropCapabilities(java.util.List requiredDropCapabilities) { - if (requiredDropCapabilities != null) {this.requiredDropCapabilities = new java.util.ArrayList(); for (java.lang.String item : requiredDropCapabilities){this.addToRequiredDropCapabilities(item);}} else { this.requiredDropCapabilities = null;} return (A) this; + if (requiredDropCapabilities != null) { + this.requiredDropCapabilities = new java.util.ArrayList(); + for (java.lang.String item : requiredDropCapabilities) { + this.addToRequiredDropCapabilities(item); + } + } else { + this.requiredDropCapabilities = null; + } + return (A) this; } + public A withRequiredDropCapabilities(java.lang.String... requiredDropCapabilities) { - if (this.requiredDropCapabilities != null) {this.requiredDropCapabilities.clear();} - if (requiredDropCapabilities != null) {for (java.lang.String item :requiredDropCapabilities){ this.addToRequiredDropCapabilities(item);}} return (A) this; + if (this.requiredDropCapabilities != null) { + this.requiredDropCapabilities.clear(); + } + if (requiredDropCapabilities != null) { + for (java.lang.String item : requiredDropCapabilities) { + this.addToRequiredDropCapabilities(item); + } + } + return (A) this; } + public java.lang.Boolean hasRequiredDropCapabilities() { return requiredDropCapabilities != null && !requiredDropCapabilities.isEmpty(); } + public A addNewRequiredDropCapability(java.lang.String original) { - return (A)addToRequiredDropCapabilities(new String(original)); + return (A) addToRequiredDropCapabilities(new String(original)); } - + /** * This method has been deprecated, please use method buildRunAsGroup instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions getRunAsGroup() { - return this.runAsGroup!=null ?this.runAsGroup.build():null; + return this.runAsGroup != null ? this.runAsGroup.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions buildRunAsGroup() { - return this.runAsGroup!=null ?this.runAsGroup.build():null; + return this.runAsGroup != null ? this.runAsGroup.build() : null; } - public A withRunAsGroup(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions runAsGroup) { + + public A withRunAsGroup( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions runAsGroup) { _visitables.get("runAsGroup").remove(this.runAsGroup); - if (runAsGroup!=null){ this.runAsGroup= new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsBuilder(runAsGroup); _visitables.get("runAsGroup").add(this.runAsGroup);} return (A) this; + if (runAsGroup != null) { + this.runAsGroup = + new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsBuilder( + runAsGroup); + _visitables.get("runAsGroup").add(this.runAsGroup); + } + return (A) this; } + public java.lang.Boolean hasRunAsGroup() { return this.runAsGroup != null; } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested withNewRunAsGroup() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.RunAsGroupNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested + withNewRunAsGroup() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .RunAsGroupNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested withNewRunAsGroupLike(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.RunAsGroupNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested + withNewRunAsGroupLike( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .RunAsGroupNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested editRunAsGroup() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested + editRunAsGroup() { return withNewRunAsGroupLike(getRunAsGroup()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested editOrNewRunAsGroup() { - return withNewRunAsGroupLike(getRunAsGroup() != null ? getRunAsGroup(): new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested + editOrNewRunAsGroup() { + return withNewRunAsGroupLike( + getRunAsGroup() != null + ? getRunAsGroup() + : new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested editOrNewRunAsGroupLike(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions item) { - return withNewRunAsGroupLike(getRunAsGroup() != null ? getRunAsGroup(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested + editOrNewRunAsGroupLike( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions item) { + return withNewRunAsGroupLike(getRunAsGroup() != null ? getRunAsGroup() : item); } - + /** * This method has been deprecated, please use method buildRunAsUser instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions getRunAsUser() { - return this.runAsUser!=null ?this.runAsUser.build():null; + return this.runAsUser != null ? this.runAsUser.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions buildRunAsUser() { - return this.runAsUser!=null ?this.runAsUser.build():null; + return this.runAsUser != null ? this.runAsUser.build() : null; } - public A withRunAsUser(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions runAsUser) { + + public A withRunAsUser( + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions runAsUser) { _visitables.get("runAsUser").remove(this.runAsUser); - if (runAsUser!=null){ this.runAsUser= new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsBuilder(runAsUser); _visitables.get("runAsUser").add(this.runAsUser);} return (A) this; + if (runAsUser != null) { + this.runAsUser = + new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsBuilder(runAsUser); + _visitables.get("runAsUser").add(this.runAsUser); + } + return (A) this; } + public java.lang.Boolean hasRunAsUser() { return this.runAsUser != null; } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested withNewRunAsUser() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.RunAsUserNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested + withNewRunAsUser() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .RunAsUserNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested withNewRunAsUserLike(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.RunAsUserNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested + withNewRunAsUserLike( + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .RunAsUserNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested editRunAsUser() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested + editRunAsUser() { return withNewRunAsUserLike(getRunAsUser()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested editOrNewRunAsUser() { - return withNewRunAsUserLike(getRunAsUser() != null ? getRunAsUser(): new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested + editOrNewRunAsUser() { + return withNewRunAsUserLike( + getRunAsUser() != null + ? getRunAsUser() + : new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested editOrNewRunAsUserLike(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions item) { - return withNewRunAsUserLike(getRunAsUser() != null ? getRunAsUser(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested + editOrNewRunAsUserLike( + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions item) { + return withNewRunAsUserLike(getRunAsUser() != null ? getRunAsUser() : item); } - + /** * This method has been deprecated, please use method buildRuntimeClass instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions getRuntimeClass() { - return this.runtimeClass!=null ?this.runtimeClass.build():null; + return this.runtimeClass != null ? this.runtimeClass.build() : null; } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions buildRuntimeClass() { - return this.runtimeClass!=null ?this.runtimeClass.build():null; + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions + buildRuntimeClass() { + return this.runtimeClass != null ? this.runtimeClass.build() : null; } - public A withRuntimeClass(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions runtimeClass) { + + public A withRuntimeClass( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions runtimeClass) { _visitables.get("runtimeClass").remove(this.runtimeClass); - if (runtimeClass!=null){ this.runtimeClass= new io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsBuilder(runtimeClass); _visitables.get("runtimeClass").add(this.runtimeClass);} return (A) this; + if (runtimeClass != null) { + this.runtimeClass = + new io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsBuilder( + runtimeClass); + _visitables.get("runtimeClass").add(this.runtimeClass); + } + return (A) this; } + public java.lang.Boolean hasRuntimeClass() { return this.runtimeClass != null; } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested withNewRuntimeClass() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.RuntimeClassNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested< + A> + withNewRuntimeClass() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .RuntimeClassNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested withNewRuntimeClassLike(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.RuntimeClassNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested< + A> + withNewRuntimeClassLike( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .RuntimeClassNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested editRuntimeClass() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested< + A> + editRuntimeClass() { return withNewRuntimeClassLike(getRuntimeClass()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested editOrNewRuntimeClass() { - return withNewRuntimeClassLike(getRuntimeClass() != null ? getRuntimeClass(): new io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested< + A> + editOrNewRuntimeClass() { + return withNewRuntimeClassLike( + getRuntimeClass() != null + ? getRuntimeClass() + : new io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested editOrNewRuntimeClassLike(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions item) { - return withNewRuntimeClassLike(getRuntimeClass() != null ? getRuntimeClass(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested< + A> + editOrNewRuntimeClassLike( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions item) { + return withNewRuntimeClassLike(getRuntimeClass() != null ? getRuntimeClass() : item); } - + /** * This method has been deprecated, please use method buildSeLinux instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions getSeLinux() { - return this.seLinux!=null ?this.seLinux.build():null; + return this.seLinux != null ? this.seLinux.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions buildSeLinux() { - return this.seLinux!=null ?this.seLinux.build():null; + return this.seLinux != null ? this.seLinux.build() : null; } + public A withSeLinux(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions seLinux) { _visitables.get("seLinux").remove(this.seLinux); - if (seLinux!=null){ this.seLinux= new io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsBuilder(seLinux); _visitables.get("seLinux").add(this.seLinux);} return (A) this; + if (seLinux != null) { + this.seLinux = + new io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsBuilder(seLinux); + _visitables.get("seLinux").add(this.seLinux); + } + return (A) this; } + public java.lang.Boolean hasSeLinux() { return this.seLinux != null; } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested withNewSeLinux() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.SeLinuxNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested + withNewSeLinux() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .SeLinuxNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested withNewSeLinuxLike(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.SeLinuxNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested + withNewSeLinuxLike(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .SeLinuxNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested editSeLinux() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested + editSeLinux() { return withNewSeLinuxLike(getSeLinux()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested editOrNewSeLinux() { - return withNewSeLinuxLike(getSeLinux() != null ? getSeLinux(): new io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested + editOrNewSeLinux() { + return withNewSeLinuxLike( + getSeLinux() != null + ? getSeLinux() + : new io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested editOrNewSeLinuxLike(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions item) { - return withNewSeLinuxLike(getSeLinux() != null ? getSeLinux(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested + editOrNewSeLinuxLike(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions item) { + return withNewSeLinuxLike(getSeLinux() != null ? getSeLinux() : item); } - + /** * This method has been deprecated, please use method buildSupplementalGroups instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions getSupplementalGroups() { - return this.supplementalGroups!=null ?this.supplementalGroups.build():null; + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions + getSupplementalGroups() { + return this.supplementalGroups != null ? this.supplementalGroups.build() : null; } - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions buildSupplementalGroups() { - return this.supplementalGroups!=null ?this.supplementalGroups.build():null; + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions + buildSupplementalGroups() { + return this.supplementalGroups != null ? this.supplementalGroups.build() : null; } - public A withSupplementalGroups(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions supplementalGroups) { + + public A withSupplementalGroups( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions + supplementalGroups) { _visitables.get("supplementalGroups").remove(this.supplementalGroups); - if (supplementalGroups!=null){ this.supplementalGroups= new io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsBuilder(supplementalGroups); _visitables.get("supplementalGroups").add(this.supplementalGroups);} return (A) this; + if (supplementalGroups != null) { + this.supplementalGroups = + new io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsBuilder( + supplementalGroups); + _visitables.get("supplementalGroups").add(this.supplementalGroups); + } + return (A) this; } + public java.lang.Boolean hasSupplementalGroups() { return this.supplementalGroups != null; } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SupplementalGroupsNested withNewSupplementalGroups() { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.SupplementalGroupsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SupplementalGroupsNested< + A> + withNewSupplementalGroups() { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .SupplementalGroupsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SupplementalGroupsNested withNewSupplementalGroupsLike(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions item) { - return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl.SupplementalGroupsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SupplementalGroupsNested< + A> + withNewSupplementalGroupsLike( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions item) { + return new io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluentImpl + .SupplementalGroupsNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SupplementalGroupsNested editSupplementalGroups() { + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SupplementalGroupsNested< + A> + editSupplementalGroups() { return withNewSupplementalGroupsLike(getSupplementalGroups()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SupplementalGroupsNested editOrNewSupplementalGroups() { - return withNewSupplementalGroupsLike(getSupplementalGroups() != null ? getSupplementalGroups(): new io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SupplementalGroupsNested< + A> + editOrNewSupplementalGroups() { + return withNewSupplementalGroupsLike( + getSupplementalGroups() != null + ? getSupplementalGroups() + : new io.kubernetes.client.openapi.models + .V1beta1SupplementalGroupsStrategyOptionsBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SupplementalGroupsNested editOrNewSupplementalGroupsLike(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions item) { - return withNewSupplementalGroupsLike(getSupplementalGroups() != null ? getSupplementalGroups(): item); + + public io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SupplementalGroupsNested< + A> + editOrNewSupplementalGroupsLike( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions item) { + return withNewSupplementalGroupsLike( + getSupplementalGroups() != null ? getSupplementalGroups() : item); } - public A addToVolumes(java.lang.Integer index,java.lang.String item) { - if (this.volumes == null) {this.volumes = new java.util.ArrayList();} + + public A addToVolumes(java.lang.Integer index, java.lang.String item) { + if (this.volumes == null) { + this.volumes = new java.util.ArrayList(); + } this.volumes.add(index, item); - return (A)this; + return (A) this; } - public A setToVolumes(java.lang.Integer index,java.lang.String item) { - if (this.volumes == null) {this.volumes = new java.util.ArrayList();} - this.volumes.set(index, item); return (A)this; + + public A setToVolumes(java.lang.Integer index, java.lang.String item) { + if (this.volumes == null) { + this.volumes = new java.util.ArrayList(); + } + this.volumes.set(index, item); + return (A) this; } + public A addToVolumes(java.lang.String... items) { - if (this.volumes == null) {this.volumes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.volumes.add(item);} return (A)this; + if (this.volumes == null) { + this.volumes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.volumes.add(item); + } + return (A) this; } + public A addAllToVolumes(java.util.Collection items) { - if (this.volumes == null) {this.volumes = new java.util.ArrayList();} - for (java.lang.String item : items) {this.volumes.add(item);} return (A)this; + if (this.volumes == null) { + this.volumes = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.volumes.add(item); + } + return (A) this; } + public A removeFromVolumes(java.lang.String... items) { - for (java.lang.String item : items) {if (this.volumes!= null){ this.volumes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.volumes != null) { + this.volumes.remove(item); + } + } + return (A) this; } + public A removeAllFromVolumes(java.util.Collection items) { - for (java.lang.String item : items) {if (this.volumes!= null){ this.volumes.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.volumes != null) { + this.volumes.remove(item); + } + } + return (A) this; } + public java.util.List getVolumes() { return this.volumes; } + public java.lang.String getVolume(java.lang.Integer index) { return this.volumes.get(index); } + public java.lang.String getFirstVolume() { return this.volumes.get(0); } + public java.lang.String getLastVolume() { return this.volumes.get(volumes.size() - 1); } - public java.lang.String getMatchingVolume(java.util.function.Predicate predicate) { - for (java.lang.String item: volumes) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingVolume( + java.util.function.Predicate predicate) { + for (java.lang.String item : volumes) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingVolume(java.util.function.Predicate predicate) { - for (java.lang.String item: volumes) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVolume( + java.util.function.Predicate predicate) { + for (java.lang.String item : volumes) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withVolumes(java.util.List volumes) { - if (volumes != null) {this.volumes = new java.util.ArrayList(); for (java.lang.String item : volumes){this.addToVolumes(item);}} else { this.volumes = null;} return (A) this; + if (volumes != null) { + this.volumes = new java.util.ArrayList(); + for (java.lang.String item : volumes) { + this.addToVolumes(item); + } + } else { + this.volumes = null; + } + return (A) this; } + public A withVolumes(java.lang.String... volumes) { - if (this.volumes != null) {this.volumes.clear();} - if (volumes != null) {for (java.lang.String item :volumes){ this.addToVolumes(item);}} return (A) this; + if (this.volumes != null) { + this.volumes.clear(); + } + if (volumes != null) { + for (java.lang.String item : volumes) { + this.addToVolumes(item); + } + } + return (A) this; } + public java.lang.Boolean hasVolumes() { return volumes != null && !volumes.isEmpty(); } + public A addNewVolume(java.lang.String original) { - return (A)addToVolumes(new String(original)); + return (A) addToVolumes(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1PodSecurityPolicySpecFluentImpl that = (V1beta1PodSecurityPolicySpecFluentImpl) o; - if (allowPrivilegeEscalation != null ? !allowPrivilegeEscalation.equals(that.allowPrivilegeEscalation) :that.allowPrivilegeEscalation != null) return false; - if (allowedCSIDrivers != null ? !allowedCSIDrivers.equals(that.allowedCSIDrivers) :that.allowedCSIDrivers != null) return false; - if (allowedCapabilities != null ? !allowedCapabilities.equals(that.allowedCapabilities) :that.allowedCapabilities != null) return false; - if (allowedFlexVolumes != null ? !allowedFlexVolumes.equals(that.allowedFlexVolumes) :that.allowedFlexVolumes != null) return false; - if (allowedHostPaths != null ? !allowedHostPaths.equals(that.allowedHostPaths) :that.allowedHostPaths != null) return false; - if (allowedProcMountTypes != null ? !allowedProcMountTypes.equals(that.allowedProcMountTypes) :that.allowedProcMountTypes != null) return false; - if (allowedUnsafeSysctls != null ? !allowedUnsafeSysctls.equals(that.allowedUnsafeSysctls) :that.allowedUnsafeSysctls != null) return false; - if (defaultAddCapabilities != null ? !defaultAddCapabilities.equals(that.defaultAddCapabilities) :that.defaultAddCapabilities != null) return false; - if (defaultAllowPrivilegeEscalation != null ? !defaultAllowPrivilegeEscalation.equals(that.defaultAllowPrivilegeEscalation) :that.defaultAllowPrivilegeEscalation != null) return false; - if (forbiddenSysctls != null ? !forbiddenSysctls.equals(that.forbiddenSysctls) :that.forbiddenSysctls != null) return false; - if (fsGroup != null ? !fsGroup.equals(that.fsGroup) :that.fsGroup != null) return false; - if (hostIPC != null ? !hostIPC.equals(that.hostIPC) :that.hostIPC != null) return false; - if (hostNetwork != null ? !hostNetwork.equals(that.hostNetwork) :that.hostNetwork != null) return false; - if (hostPID != null ? !hostPID.equals(that.hostPID) :that.hostPID != null) return false; - if (hostPorts != null ? !hostPorts.equals(that.hostPorts) :that.hostPorts != null) return false; - if (privileged != null ? !privileged.equals(that.privileged) :that.privileged != null) return false; - if (readOnlyRootFilesystem != null ? !readOnlyRootFilesystem.equals(that.readOnlyRootFilesystem) :that.readOnlyRootFilesystem != null) return false; - if (requiredDropCapabilities != null ? !requiredDropCapabilities.equals(that.requiredDropCapabilities) :that.requiredDropCapabilities != null) return false; - if (runAsGroup != null ? !runAsGroup.equals(that.runAsGroup) :that.runAsGroup != null) return false; - if (runAsUser != null ? !runAsUser.equals(that.runAsUser) :that.runAsUser != null) return false; - if (runtimeClass != null ? !runtimeClass.equals(that.runtimeClass) :that.runtimeClass != null) return false; - if (seLinux != null ? !seLinux.equals(that.seLinux) :that.seLinux != null) return false; - if (supplementalGroups != null ? !supplementalGroups.equals(that.supplementalGroups) :that.supplementalGroups != null) return false; - if (volumes != null ? !volumes.equals(that.volumes) :that.volumes != null) return false; + if (allowPrivilegeEscalation != null + ? !allowPrivilegeEscalation.equals(that.allowPrivilegeEscalation) + : that.allowPrivilegeEscalation != null) return false; + if (allowedCSIDrivers != null + ? !allowedCSIDrivers.equals(that.allowedCSIDrivers) + : that.allowedCSIDrivers != null) return false; + if (allowedCapabilities != null + ? !allowedCapabilities.equals(that.allowedCapabilities) + : that.allowedCapabilities != null) return false; + if (allowedFlexVolumes != null + ? !allowedFlexVolumes.equals(that.allowedFlexVolumes) + : that.allowedFlexVolumes != null) return false; + if (allowedHostPaths != null + ? !allowedHostPaths.equals(that.allowedHostPaths) + : that.allowedHostPaths != null) return false; + if (allowedProcMountTypes != null + ? !allowedProcMountTypes.equals(that.allowedProcMountTypes) + : that.allowedProcMountTypes != null) return false; + if (allowedUnsafeSysctls != null + ? !allowedUnsafeSysctls.equals(that.allowedUnsafeSysctls) + : that.allowedUnsafeSysctls != null) return false; + if (defaultAddCapabilities != null + ? !defaultAddCapabilities.equals(that.defaultAddCapabilities) + : that.defaultAddCapabilities != null) return false; + if (defaultAllowPrivilegeEscalation != null + ? !defaultAllowPrivilegeEscalation.equals(that.defaultAllowPrivilegeEscalation) + : that.defaultAllowPrivilegeEscalation != null) return false; + if (forbiddenSysctls != null + ? !forbiddenSysctls.equals(that.forbiddenSysctls) + : that.forbiddenSysctls != null) return false; + if (fsGroup != null ? !fsGroup.equals(that.fsGroup) : that.fsGroup != null) return false; + if (hostIPC != null ? !hostIPC.equals(that.hostIPC) : that.hostIPC != null) return false; + if (hostNetwork != null ? !hostNetwork.equals(that.hostNetwork) : that.hostNetwork != null) + return false; + if (hostPID != null ? !hostPID.equals(that.hostPID) : that.hostPID != null) return false; + if (hostPorts != null ? !hostPorts.equals(that.hostPorts) : that.hostPorts != null) + return false; + if (privileged != null ? !privileged.equals(that.privileged) : that.privileged != null) + return false; + if (readOnlyRootFilesystem != null + ? !readOnlyRootFilesystem.equals(that.readOnlyRootFilesystem) + : that.readOnlyRootFilesystem != null) return false; + if (requiredDropCapabilities != null + ? !requiredDropCapabilities.equals(that.requiredDropCapabilities) + : that.requiredDropCapabilities != null) return false; + if (runAsGroup != null ? !runAsGroup.equals(that.runAsGroup) : that.runAsGroup != null) + return false; + if (runAsUser != null ? !runAsUser.equals(that.runAsUser) : that.runAsUser != null) + return false; + if (runtimeClass != null ? !runtimeClass.equals(that.runtimeClass) : that.runtimeClass != null) + return false; + if (seLinux != null ? !seLinux.equals(that.seLinux) : that.seLinux != null) return false; + if (supplementalGroups != null + ? !supplementalGroups.equals(that.supplementalGroups) + : that.supplementalGroups != null) return false; + if (volumes != null ? !volumes.equals(that.volumes) : that.volumes != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(allowPrivilegeEscalation, allowedCSIDrivers, allowedCapabilities, allowedFlexVolumes, allowedHostPaths, allowedProcMountTypes, allowedUnsafeSysctls, defaultAddCapabilities, defaultAllowPrivilegeEscalation, forbiddenSysctls, fsGroup, hostIPC, hostNetwork, hostPID, hostPorts, privileged, readOnlyRootFilesystem, requiredDropCapabilities, runAsGroup, runAsUser, runtimeClass, seLinux, supplementalGroups, volumes, super.hashCode()); + return java.util.Objects.hash( + allowPrivilegeEscalation, + allowedCSIDrivers, + allowedCapabilities, + allowedFlexVolumes, + allowedHostPaths, + allowedProcMountTypes, + allowedUnsafeSysctls, + defaultAddCapabilities, + defaultAllowPrivilegeEscalation, + forbiddenSysctls, + fsGroup, + hostIPC, + hostNetwork, + hostPID, + hostPorts, + privileged, + readOnlyRootFilesystem, + requiredDropCapabilities, + runAsGroup, + runAsUser, + runtimeClass, + seLinux, + supplementalGroups, + volumes, + super.hashCode()); } - public class AllowedCSIDriversNestedImpl extends io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedCSIDriversNested,io.kubernetes.client.fluent.Nested{ - AllowedCSIDriversNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item) { + + public class AllowedCSIDriversNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedCSIDriversNested< + N>, + io.kubernetes.client.fluent.Nested { + AllowedCSIDriversNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriver item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(this, item); } + AllowedCSIDriversNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1AllowedCSIDriverBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1PodSecurityPolicySpecFluentImpl.this.setToAllowedCSIDrivers(index,builder.build()); + return (N) + V1beta1PodSecurityPolicySpecFluentImpl.this.setToAllowedCSIDrivers( + index, builder.build()); } + public N endAllowedCSIDriver() { return and(); } - } - public class AllowedFlexVolumesNestedImpl extends io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedFlexVolumesNested,io.kubernetes.client.fluent.Nested{ - AllowedFlexVolumesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item) { + + public class AllowedFlexVolumesNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedFlexVolumesNested< + N>, + io.kubernetes.client.fluent.Nested { + AllowedFlexVolumesNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolume item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(this, item); } + AllowedFlexVolumesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1AllowedFlexVolumeBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1PodSecurityPolicySpecFluentImpl.this.setToAllowedFlexVolumes(index,builder.build()); + return (N) + V1beta1PodSecurityPolicySpecFluentImpl.this.setToAllowedFlexVolumes( + index, builder.build()); } + public N endAllowedFlexVolume() { return and(); } - } - public class AllowedHostPathsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.AllowedHostPathsNested,io.kubernetes.client.fluent.Nested{ - AllowedHostPathsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item) { + + public class AllowedHostPathsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1AllowedHostPathFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .AllowedHostPathsNested< + N>, + io.kubernetes.client.fluent.Nested { + AllowedHostPathsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1AllowedHostPath item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(this, item); } + AllowedHostPathsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1AllowedHostPathBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1PodSecurityPolicySpecFluentImpl.this.setToAllowedHostPaths(index,builder.build()); + return (N) + V1beta1PodSecurityPolicySpecFluentImpl.this.setToAllowedHostPaths(index, builder.build()); } + public N endAllowedHostPath() { return and(); } - } - public class FsGroupNestedImpl extends io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested,io.kubernetes.client.fluent.Nested{ + + public class FsGroupNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.FsGroupNested> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .FsGroupNested< + N>, + io.kubernetes.client.fluent.Nested { FsGroupNestedImpl(io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptions item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsBuilder(this, item); } + FsGroupNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1FSGroupStrategyOptionsBuilder builder; + public N and() { return (N) V1beta1PodSecurityPolicySpecFluentImpl.this.withFsGroup(builder.build()); } + public N endFsGroup() { return and(); } - } - public class HostPortsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested,io.kubernetes.client.fluent.Nested{ - HostPortsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1HostPortRange item) { + + public class HostPortsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1HostPortRangeFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.HostPortsNested> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .HostPortsNested< + N>, + io.kubernetes.client.fluent.Nested { + HostPortsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1HostPortRange item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(this, item); } + HostPortsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1HostPortRangeBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1PodSecurityPolicySpecFluentImpl.this.setToHostPorts(index,builder.build()); + return (N) V1beta1PodSecurityPolicySpecFluentImpl.this.setToHostPorts(index, builder.build()); } + public N endHostPort() { return and(); } - } - public class RunAsGroupNestedImpl extends io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested,io.kubernetes.client.fluent.Nested{ - RunAsGroupNestedImpl(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsBuilder(this, item); + + public class RunAsGroupNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsGroupNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .RunAsGroupNested< + N>, + io.kubernetes.client.fluent.Nested { + RunAsGroupNestedImpl( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions item) { + this.builder = + new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsBuilder( + this, item); } + RunAsGroupNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsBuilder builder; + public N and() { return (N) V1beta1PodSecurityPolicySpecFluentImpl.this.withRunAsGroup(builder.build()); } + public N endRunAsGroup() { return and(); } - } - public class RunAsUserNestedImpl extends io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested,io.kubernetes.client.fluent.Nested{ + + public class RunAsUserNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RunAsUserNested> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .RunAsUserNested< + N>, + io.kubernetes.client.fluent.Nested { RunAsUserNestedImpl(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsBuilder( + this, item); } + RunAsUserNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsBuilder builder; + public N and() { return (N) V1beta1PodSecurityPolicySpecFluentImpl.this.withRunAsUser(builder.build()); } + public N endRunAsUser() { return and(); } - } - public class RuntimeClassNestedImpl extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested,io.kubernetes.client.fluent.Nested{ - RuntimeClassNestedImpl(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsBuilder(this, item); + + public class RuntimeClassNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.RuntimeClassNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .RuntimeClassNested< + N>, + io.kubernetes.client.fluent.Nested { + RuntimeClassNestedImpl( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions item) { + this.builder = + new io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsBuilder( + this, item); } + RuntimeClassNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsBuilder builder; + public N and() { return (N) V1beta1PodSecurityPolicySpecFluentImpl.this.withRuntimeClass(builder.build()); } + public N endRuntimeClass() { return and(); } - } - public class SeLinuxNestedImpl extends io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested,io.kubernetes.client.fluent.Nested{ + + public class SeLinuxNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SeLinuxNested> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SeLinuxNested< + N>, + io.kubernetes.client.fluent.Nested { SeLinuxNestedImpl(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsBuilder(this, item); } + SeLinuxNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsBuilder builder; + public N and() { return (N) V1beta1PodSecurityPolicySpecFluentImpl.this.withSeLinux(builder.build()); } + public N endSeLinux() { return and(); } - } - public class SupplementalGroupsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent.SupplementalGroupsNested,io.kubernetes.client.fluent.Nested{ - SupplementalGroupsNestedImpl(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsBuilder(this, item); + + public class SupplementalGroupsNestedImpl + extends io.kubernetes.client.openapi.models + .V1beta1SupplementalGroupsStrategyOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SupplementalGroupsNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PodSecurityPolicySpecFluent + .SupplementalGroupsNested< + N>, + io.kubernetes.client.fluent.Nested { + SupplementalGroupsNestedImpl( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions item) { + this.builder = + new io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsBuilder( + this, item); } + SupplementalGroupsNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsBuilder( + this); } + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsBuilder builder; + public N and() { - return (N) V1beta1PodSecurityPolicySpecFluentImpl.this.withSupplementalGroups(builder.build()); + return (N) + V1beta1PodSecurityPolicySpecFluentImpl.this.withSupplementalGroups(builder.build()); } + public N endSupplementalGroups() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PolicyRulesWithSubjectsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PolicyRulesWithSubjectsBuilder.java index f3ae398a0e..5036eb4433 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PolicyRulesWithSubjectsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PolicyRulesWithSubjectsBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PolicyRulesWithSubjectsBuilder extends io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PolicyRulesWithSubjectsBuilder + extends io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects, + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsBuilder> { public V1beta1PolicyRulesWithSubjectsBuilder() { this(false); } + public V1beta1PolicyRulesWithSubjectsBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PolicyRulesWithSubjects(), validationEnabled); } - public V1beta1PolicyRulesWithSubjectsBuilder(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent fluent) { + + public V1beta1PolicyRulesWithSubjectsBuilder( + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent fluent) { this(fluent, false); } - public V1beta1PolicyRulesWithSubjectsBuilder(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PolicyRulesWithSubjectsBuilder( + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PolicyRulesWithSubjects(), validationEnabled); } - public V1beta1PolicyRulesWithSubjectsBuilder(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent fluent,io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects instance) { + + public V1beta1PolicyRulesWithSubjectsBuilder( + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects instance) { this(fluent, instance, false); } - public V1beta1PolicyRulesWithSubjectsBuilder(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent fluent,io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PolicyRulesWithSubjectsBuilder( + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNonResourceRules(instance.getNonResourceRules()); fluent.withResourceRules(instance.getResourceRules()); fluent.withSubjects(instance.getSubjects()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PolicyRulesWithSubjectsBuilder(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects instance) { - this(instance,false); + + public V1beta1PolicyRulesWithSubjectsBuilder( + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects instance) { + this(instance, false); } - public V1beta1PolicyRulesWithSubjectsBuilder(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PolicyRulesWithSubjectsBuilder( + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNonResourceRules(instance.getNonResourceRules()); this.withResourceRules(instance.getResourceRules()); this.withSubjects(instance.getSubjects()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects build() { V1beta1PolicyRulesWithSubjects buildable = new V1beta1PolicyRulesWithSubjects(); buildable.setNonResourceRules(fluent.getNonResourceRules()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects build( buildable.setSubjects(fluent.getSubjects()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1PolicyRulesWithSubjectsBuilder that = (V1beta1PolicyRulesWithSubjectsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PolicyRulesWithSubjectsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PolicyRulesWithSubjectsFluent.java index d30c815d5c..9f01a364a4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PolicyRulesWithSubjectsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PolicyRulesWithSubjectsFluent.java @@ -1,127 +1,333 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1beta1PolicyRulesWithSubjectsFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToNonResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item); - public A setToNonResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item); - public A addToNonResourceRules(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule... items); - public A addAllToNonResourceRules(java.util.Collection items); - public A removeFromNonResourceRules(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule... items); - public A removeAllFromNonResourceRules(java.util.Collection items); - public A removeMatchingFromNonResourceRules(java.util.function.Predicate predicate); - +/** Generated */ +public interface V1beta1PolicyRulesWithSubjectsFluent< + A extends io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToNonResourceRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item); + + public A setToNonResourceRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item); + + public A addToNonResourceRules( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule... items); + + public A addAllToNonResourceRules( + java.util.Collection items); + + public A removeFromNonResourceRules( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule... items); + + public A removeAllFromNonResourceRules( + java.util.Collection items); + + public A removeMatchingFromNonResourceRules( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder> + predicate); + /** * This method has been deprecated, please use method buildNonResourceRules instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getNonResourceRules(); - public java.util.List buildNonResourceRules(); - public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule buildNonResourceRule(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule buildFirstNonResourceRule(); - public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule buildLastNonResourceRule(); - public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule buildMatchingNonResourceRule(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingNonResourceRule(java.util.function.Predicate predicate); - public A withNonResourceRules(java.util.List nonResourceRules); - public A withNonResourceRules(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule... nonResourceRules); + public java.util.List + getNonResourceRules(); + + public java.util.List + buildNonResourceRules(); + + public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule buildNonResourceRule( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule + buildFirstNonResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule + buildLastNonResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule + buildMatchingNonResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder> + predicate); + + public java.lang.Boolean hasMatchingNonResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder> + predicate); + + public A withNonResourceRules( + java.util.List + nonResourceRules); + + public A withNonResourceRules( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule... nonResourceRules); + public java.lang.Boolean hasNonResourceRules(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested addNewNonResourceRule(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested addNewNonResourceRuleLike(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested setNewNonResourceRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested editNonResourceRule(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested editFirstNonResourceRule(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested editLastNonResourceRule(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested editMatchingNonResourceRule(java.util.function.Predicate predicate); - public A addToResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item); - public A setToResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item); - public A addToResourceRules(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule... items); - public A addAllToResourceRules(java.util.Collection items); - public A removeFromResourceRules(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule... items); - public A removeAllFromResourceRules(java.util.Collection items); - public A removeMatchingFromResourceRules(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + addNewNonResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + addNewNonResourceRuleLike( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + setNewNonResourceRuleLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editNonResourceRule(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editFirstNonResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editLastNonResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editMatchingNonResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder> + predicate); + + public A addToResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item); + + public A setToResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item); + + public A addToResourceRules( + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule... items); + + public A addAllToResourceRules( + java.util.Collection items); + + public A removeFromResourceRules( + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule... items); + + public A removeAllFromResourceRules( + java.util.Collection items); + + public A removeMatchingFromResourceRules( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder> + predicate); + /** * This method has been deprecated, please use method buildResourceRules instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getResourceRules(); - public java.util.List buildResourceRules(); - public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule buildResourceRule(java.lang.Integer index); + public java.util.List + getResourceRules(); + + public java.util.List + buildResourceRules(); + + public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule buildResourceRule( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule buildFirstResourceRule(); + public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule buildLastResourceRule(); - public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule buildMatchingResourceRule(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingResourceRule(java.util.function.Predicate predicate); - public A withResourceRules(java.util.List resourceRules); - public A withResourceRules(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule... resourceRules); + + public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule buildMatchingResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder> + predicate); + + public java.lang.Boolean hasMatchingResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder> + predicate); + + public A withResourceRules( + java.util.List resourceRules); + + public A withResourceRules( + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule... resourceRules); + public java.lang.Boolean hasResourceRules(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested addNewResourceRule(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested addNewResourceRuleLike(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested setNewResourceRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested editResourceRule(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested editFirstResourceRule(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested editLastResourceRule(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested editMatchingResourceRule(java.util.function.Predicate predicate); - public A addToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Subject item); - public A setToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Subject item); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + addNewResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + addNewResourceRuleLike(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + setNewResourceRuleLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editResourceRule(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editFirstResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editLastResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editMatchingResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder> + predicate); + + public A addToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Subject item); + + public A setToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Subject item); + public A addToSubjects(io.kubernetes.client.openapi.models.V1beta1Subject... items); - public A addAllToSubjects(java.util.Collection items); + + public A addAllToSubjects( + java.util.Collection items); + public A removeFromSubjects(io.kubernetes.client.openapi.models.V1beta1Subject... items); - public A removeAllFromSubjects(java.util.Collection items); - public A removeMatchingFromSubjects(java.util.function.Predicate predicate); - + + public A removeAllFromSubjects( + java.util.Collection items); + + public A removeMatchingFromSubjects( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildSubjects instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getSubjects(); + public java.util.List buildSubjects(); + public io.kubernetes.client.openapi.models.V1beta1Subject buildSubject(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1Subject buildFirstSubject(); + public io.kubernetes.client.openapi.models.V1beta1Subject buildLastSubject(); - public io.kubernetes.client.openapi.models.V1beta1Subject buildMatchingSubject(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingSubject(java.util.function.Predicate predicate); - public A withSubjects(java.util.List subjects); + + public io.kubernetes.client.openapi.models.V1beta1Subject buildMatchingSubject( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingSubject( + java.util.function.Predicate + predicate); + + public A withSubjects( + java.util.List subjects); + public A withSubjects(io.kubernetes.client.openapi.models.V1beta1Subject... subjects); + public java.lang.Boolean hasSubjects(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested addNewSubject(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested addNewSubjectLike(io.kubernetes.client.openapi.models.V1beta1Subject item); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested setNewSubjectLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Subject item); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested editSubject(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested editFirstSubject(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested editLastSubject(); - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested editMatchingSubject(java.util.function.Predicate predicate); - public interface NonResourceRulesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + addNewSubject(); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + addNewSubjectLike(io.kubernetes.client.openapi.models.V1beta1Subject item); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + setNewSubjectLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Subject item); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + editSubject(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + editFirstSubject(); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + editLastSubject(); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + editMatchingSubject( + java.util.function.Predicate + predicate); + + public interface NonResourceRulesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluent< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + N>> { public N and(); + public N endNonResourceRule(); - } - public interface ResourceRulesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent>{ + + public interface ResourceRulesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + N>> { public N and(); + public N endResourceRule(); - } - public interface SubjectsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1SubjectFluent>{ + + public interface SubjectsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1SubjectFluent< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .SubjectsNested< + N>> { public N and(); + public N endSubject(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PolicyRulesWithSubjectsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PolicyRulesWithSubjectsFluentImpl.java index 7327d6880e..8f42aa4e21 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PolicyRulesWithSubjectsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PolicyRulesWithSubjectsFluentImpl.java @@ -1,63 +1,150 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta1PolicyRulesWithSubjectsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent{ - public V1beta1PolicyRulesWithSubjectsFluentImpl() { - } - public V1beta1PolicyRulesWithSubjectsFluentImpl(io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects instance) { + +/** Generated */ +public class V1beta1PolicyRulesWithSubjectsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent { + public V1beta1PolicyRulesWithSubjectsFluentImpl() {} + + public V1beta1PolicyRulesWithSubjectsFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjects instance) { this.withNonResourceRules(instance.getNonResourceRules()); this.withResourceRules(instance.getResourceRules()); this.withSubjects(instance.getSubjects()); - } - private java.util.ArrayList nonResourceRules; - private java.util.ArrayList resourceRules; + + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder> + nonResourceRules; + private java.util.ArrayList + resourceRules; private java.util.ArrayList subjects; - public A addToNonResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item) { - if (this.nonResourceRules == null) {this.nonResourceRules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(item);_visitables.get("nonResourceRules").add(index >= 0 ? index : _visitables.get("nonResourceRules").size(), builder);this.nonResourceRules.add(index >= 0 ? index : nonResourceRules.size(), builder); return (A)this; + + public A addToNonResourceRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item) { + if (this.nonResourceRules == null) { + this.nonResourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(item); + _visitables + .get("nonResourceRules") + .add(index >= 0 ? index : _visitables.get("nonResourceRules").size(), builder); + this.nonResourceRules.add(index >= 0 ? index : nonResourceRules.size(), builder); + return (A) this; } - public A setToNonResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item) { - if (this.nonResourceRules == null) {this.nonResourceRules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(item); - if (index < 0 || index >= _visitables.get("nonResourceRules").size()) { _visitables.get("nonResourceRules").add(builder); } else { _visitables.get("nonResourceRules").set(index, builder);} - if (index < 0 || index >= nonResourceRules.size()) { nonResourceRules.add(builder); } else { nonResourceRules.set(index, builder);} - return (A)this; + + public A setToNonResourceRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item) { + if (this.nonResourceRules == null) { + this.nonResourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(item); + if (index < 0 || index >= _visitables.get("nonResourceRules").size()) { + _visitables.get("nonResourceRules").add(builder); + } else { + _visitables.get("nonResourceRules").set(index, builder); + } + if (index < 0 || index >= nonResourceRules.size()) { + nonResourceRules.add(builder); + } else { + nonResourceRules.set(index, builder); + } + return (A) this; } - public A addToNonResourceRules(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule... items) { - if (this.nonResourceRules == null) {this.nonResourceRules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(item);_visitables.get("nonResourceRules").add(builder);this.nonResourceRules.add(builder);} return (A)this; + + public A addToNonResourceRules( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule... items) { + if (this.nonResourceRules == null) { + this.nonResourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(item); + _visitables.get("nonResourceRules").add(builder); + this.nonResourceRules.add(builder); + } + return (A) this; } - public A addAllToNonResourceRules(java.util.Collection items) { - if (this.nonResourceRules == null) {this.nonResourceRules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(item);_visitables.get("nonResourceRules").add(builder);this.nonResourceRules.add(builder);} return (A)this; + + public A addAllToNonResourceRules( + java.util.Collection + items) { + if (this.nonResourceRules == null) { + this.nonResourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(item); + _visitables.get("nonResourceRules").add(builder); + this.nonResourceRules.add(builder); + } + return (A) this; } - public A removeFromNonResourceRules(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule... items) { - for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(item);_visitables.get("nonResourceRules").remove(builder);if (this.nonResourceRules != null) {this.nonResourceRules.remove(builder);}} return (A)this; + + public A removeFromNonResourceRules( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule... items) { + for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(item); + _visitables.get("nonResourceRules").remove(builder); + if (this.nonResourceRules != null) { + this.nonResourceRules.remove(builder); + } + } + return (A) this; } - public A removeAllFromNonResourceRules(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(item);_visitables.get("nonResourceRules").remove(builder);if (this.nonResourceRules != null) {this.nonResourceRules.remove(builder);}} return (A)this; + + public A removeAllFromNonResourceRules( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(item); + _visitables.get("nonResourceRules").remove(builder); + if (this.nonResourceRules != null) { + this.nonResourceRules.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromNonResourceRules(java.util.function.Predicate predicate) { + + public A removeMatchingFromNonResourceRules( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder> + predicate) { if (nonResourceRules == null) return (A) this; - final Iterator each = nonResourceRules.iterator(); + final Iterator each = + nonResourceRules.iterator(); final List visitables = _visitables.get("nonResourceRules"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder = each.next(); @@ -66,104 +153,280 @@ public A removeMatchingFromNonResourceRules(java.util.function.Predicate getNonResourceRules() { + public java.util.List + getNonResourceRules() { return nonResourceRules != null ? build(nonResourceRules) : null; } - public java.util.List buildNonResourceRules() { + + public java.util.List + buildNonResourceRules() { return nonResourceRules != null ? build(nonResourceRules) : null; } - public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule buildNonResourceRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule buildNonResourceRule( + java.lang.Integer index) { return this.nonResourceRules.get(index).build(); } - public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule buildFirstNonResourceRule() { + + public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule + buildFirstNonResourceRule() { return this.nonResourceRules.get(0).build(); } - public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule buildLastNonResourceRule() { + + public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule + buildLastNonResourceRule() { return this.nonResourceRules.get(nonResourceRules.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule buildMatchingNonResourceRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder item: nonResourceRules) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule + buildMatchingNonResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder item : + nonResourceRules) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingNonResourceRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder item: nonResourceRules) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingNonResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder item : + nonResourceRules) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withNonResourceRules(java.util.List nonResourceRules) { - if (this.nonResourceRules != null) { _visitables.get("nonResourceRules").removeAll(this.nonResourceRules);} - if (nonResourceRules != null) {this.nonResourceRules = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item : nonResourceRules){this.addToNonResourceRules(item);}} else { this.nonResourceRules = null;} return (A) this; + + public A withNonResourceRules( + java.util.List + nonResourceRules) { + if (this.nonResourceRules != null) { + _visitables.get("nonResourceRules").removeAll(this.nonResourceRules); + } + if (nonResourceRules != null) { + this.nonResourceRules = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item : + nonResourceRules) { + this.addToNonResourceRules(item); + } + } else { + this.nonResourceRules = null; + } + return (A) this; } - public A withNonResourceRules(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule... nonResourceRules) { - if (this.nonResourceRules != null) {this.nonResourceRules.clear();} - if (nonResourceRules != null) {for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item :nonResourceRules){ this.addToNonResourceRules(item);}} return (A) this; + + public A withNonResourceRules( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule... nonResourceRules) { + if (this.nonResourceRules != null) { + this.nonResourceRules.clear(); + } + if (nonResourceRules != null) { + for (io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item : + nonResourceRules) { + this.addToNonResourceRules(item); + } + } + return (A) this; } + public java.lang.Boolean hasNonResourceRules() { return nonResourceRules != null && !nonResourceRules.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested addNewNonResourceRule() { - return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl.NonResourceRulesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + addNewNonResourceRule() { + return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl + .NonResourceRulesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested addNewNonResourceRuleLike(io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item) { - return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl.NonResourceRulesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + addNewNonResourceRuleLike( + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item) { + return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl + .NonResourceRulesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested setNewNonResourceRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item) { - return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl.NonResourceRulesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + setNewNonResourceRuleLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item) { + return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl + .NonResourceRulesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested editNonResourceRule(java.lang.Integer index) { - if (nonResourceRules.size() <= index) throw new RuntimeException("Can't edit nonResourceRules. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editNonResourceRule(java.lang.Integer index) { + if (nonResourceRules.size() <= index) + throw new RuntimeException("Can't edit nonResourceRules. Index exceeds size."); return setNewNonResourceRuleLike(index, buildNonResourceRule(index)); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested editFirstNonResourceRule() { - if (nonResourceRules.size() == 0) throw new RuntimeException("Can't edit first nonResourceRules. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editFirstNonResourceRule() { + if (nonResourceRules.size() == 0) + throw new RuntimeException("Can't edit first nonResourceRules. The list is empty."); return setNewNonResourceRuleLike(0, buildNonResourceRule(0)); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested editLastNonResourceRule() { + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editLastNonResourceRule() { int index = nonResourceRules.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last nonResourceRules. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last nonResourceRules. The list is empty."); return setNewNonResourceRuleLike(index, buildNonResourceRule(index)); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested editMatchingNonResourceRule(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editMatchingNonResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(item);_visitables.get("resourceRules").add(index >= 0 ? index : _visitables.get("resourceRules").size(), builder);this.resourceRules.add(index >= 0 ? index : resourceRules.size(), builder); return (A)this; + + public A addToResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item) { + if (this.resourceRules == null) { + this.resourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(item); + _visitables + .get("resourceRules") + .add(index >= 0 ? index : _visitables.get("resourceRules").size(), builder); + this.resourceRules.add(index >= 0 ? index : resourceRules.size(), builder); + return (A) this; } - public A setToResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item) { - if (this.resourceRules == null) {this.resourceRules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(item); - if (index < 0 || index >= _visitables.get("resourceRules").size()) { _visitables.get("resourceRules").add(builder); } else { _visitables.get("resourceRules").set(index, builder);} - if (index < 0 || index >= resourceRules.size()) { resourceRules.add(builder); } else { resourceRules.set(index, builder);} - return (A)this; + + public A setToResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item) { + if (this.resourceRules == null) { + this.resourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(item); + if (index < 0 || index >= _visitables.get("resourceRules").size()) { + _visitables.get("resourceRules").add(builder); + } else { + _visitables.get("resourceRules").set(index, builder); + } + if (index < 0 || index >= resourceRules.size()) { + resourceRules.add(builder); + } else { + resourceRules.set(index, builder); + } + return (A) this; } - public A addToResourceRules(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule... items) { - if (this.resourceRules == null) {this.resourceRules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(item);_visitables.get("resourceRules").add(builder);this.resourceRules.add(builder);} return (A)this; + + public A addToResourceRules( + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule... items) { + if (this.resourceRules == null) { + this.resourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(item); + _visitables.get("resourceRules").add(builder); + this.resourceRules.add(builder); + } + return (A) this; } - public A addAllToResourceRules(java.util.Collection items) { - if (this.resourceRules == null) {this.resourceRules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(item);_visitables.get("resourceRules").add(builder);this.resourceRules.add(builder);} return (A)this; + + public A addAllToResourceRules( + java.util.Collection items) { + if (this.resourceRules == null) { + this.resourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(item); + _visitables.get("resourceRules").add(builder); + this.resourceRules.add(builder); + } + return (A) this; } - public A removeFromResourceRules(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule... items) { - for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(item);_visitables.get("resourceRules").remove(builder);if (this.resourceRules != null) {this.resourceRules.remove(builder);}} return (A)this; + + public A removeFromResourceRules( + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule... items) { + for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(item); + _visitables.get("resourceRules").remove(builder); + if (this.resourceRules != null) { + this.resourceRules.remove(builder); + } + } + return (A) this; } - public A removeAllFromResourceRules(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(item);_visitables.get("resourceRules").remove(builder);if (this.resourceRules != null) {this.resourceRules.remove(builder);}} return (A)this; + + public A removeAllFromResourceRules( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(item); + _visitables.get("resourceRules").remove(builder); + if (this.resourceRules != null) { + this.resourceRules.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromResourceRules(java.util.function.Predicate predicate) { + + public A removeMatchingFromResourceRules( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder> + predicate) { if (resourceRules == null) return (A) this; - final Iterator each = resourceRules.iterator(); + final Iterator each = + resourceRules.iterator(); final List visitables = _visitables.get("resourceRules"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder = each.next(); @@ -172,104 +435,264 @@ public A removeMatchingFromResourceRules(java.util.function.Predicate getResourceRules() { + public java.util.List + getResourceRules() { return resourceRules != null ? build(resourceRules) : null; } - public java.util.List buildResourceRules() { + + public java.util.List + buildResourceRules() { return resourceRules != null ? build(resourceRules) : null; } - public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule buildResourceRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule buildResourceRule( + java.lang.Integer index) { return this.resourceRules.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule buildFirstResourceRule() { return this.resourceRules.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule buildLastResourceRule() { return this.resourceRules.get(resourceRules.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule buildMatchingResourceRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder item: resourceRules) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule buildMatchingResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder item : + resourceRules) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingResourceRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder item: resourceRules) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder item : + resourceRules) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withResourceRules(java.util.List resourceRules) { - if (this.resourceRules != null) { _visitables.get("resourceRules").removeAll(this.resourceRules);} - if (resourceRules != null) {this.resourceRules = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item : resourceRules){this.addToResourceRules(item);}} else { this.resourceRules = null;} return (A) this; + + public A withResourceRules( + java.util.List resourceRules) { + if (this.resourceRules != null) { + _visitables.get("resourceRules").removeAll(this.resourceRules); + } + if (resourceRules != null) { + this.resourceRules = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item : resourceRules) { + this.addToResourceRules(item); + } + } else { + this.resourceRules = null; + } + return (A) this; } - public A withResourceRules(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule... resourceRules) { - if (this.resourceRules != null) {this.resourceRules.clear();} - if (resourceRules != null) {for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item :resourceRules){ this.addToResourceRules(item);}} return (A) this; + + public A withResourceRules( + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule... resourceRules) { + if (this.resourceRules != null) { + this.resourceRules.clear(); + } + if (resourceRules != null) { + for (io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item : resourceRules) { + this.addToResourceRules(item); + } + } + return (A) this; } + public java.lang.Boolean hasResourceRules() { return resourceRules != null && !resourceRules.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested addNewResourceRule() { - return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl.ResourceRulesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + addNewResourceRule() { + return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl + .ResourceRulesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested addNewResourceRuleLike(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item) { - return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl.ResourceRulesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + addNewResourceRuleLike(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item) { + return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl + .ResourceRulesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested setNewResourceRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item) { - return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl.ResourceRulesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + setNewResourceRuleLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item) { + return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl + .ResourceRulesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested editResourceRule(java.lang.Integer index) { - if (resourceRules.size() <= index) throw new RuntimeException("Can't edit resourceRules. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editResourceRule(java.lang.Integer index) { + if (resourceRules.size() <= index) + throw new RuntimeException("Can't edit resourceRules. Index exceeds size."); return setNewResourceRuleLike(index, buildResourceRule(index)); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested editFirstResourceRule() { - if (resourceRules.size() == 0) throw new RuntimeException("Can't edit first resourceRules. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editFirstResourceRule() { + if (resourceRules.size() == 0) + throw new RuntimeException("Can't edit first resourceRules. The list is empty."); return setNewResourceRuleLike(0, buildResourceRule(0)); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested editLastResourceRule() { + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editLastResourceRule() { int index = resourceRules.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last resourceRules. The list is empty."); return setNewResourceRuleLike(index, buildResourceRule(index)); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested editMatchingResourceRule(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editMatchingResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(item);_visitables.get("subjects").add(index >= 0 ? index : _visitables.get("subjects").size(), builder);this.subjects.add(index >= 0 ? index : subjects.size(), builder); return (A)this; + + public A addToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Subject item) { + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(item); + _visitables + .get("subjects") + .add(index >= 0 ? index : _visitables.get("subjects").size(), builder); + this.subjects.add(index >= 0 ? index : subjects.size(), builder); + return (A) this; } - public A setToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Subject item) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(item); - if (index < 0 || index >= _visitables.get("subjects").size()) { _visitables.get("subjects").add(builder); } else { _visitables.get("subjects").set(index, builder);} - if (index < 0 || index >= subjects.size()) { subjects.add(builder); } else { subjects.set(index, builder);} - return (A)this; + + public A setToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Subject item) { + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(item); + if (index < 0 || index >= _visitables.get("subjects").size()) { + _visitables.get("subjects").add(builder); + } else { + _visitables.get("subjects").set(index, builder); + } + if (index < 0 || index >= subjects.size()) { + subjects.add(builder); + } else { + subjects.set(index, builder); + } + return (A) this; } + public A addToSubjects(io.kubernetes.client.openapi.models.V1beta1Subject... items) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1Subject item : items) {io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(item);_visitables.get("subjects").add(builder);this.subjects.add(builder);} return (A)this; + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1Subject item : items) { + io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(item); + _visitables.get("subjects").add(builder); + this.subjects.add(builder); + } + return (A) this; } - public A addAllToSubjects(java.util.Collection items) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1Subject item : items) {io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(item);_visitables.get("subjects").add(builder);this.subjects.add(builder);} return (A)this; + + public A addAllToSubjects( + java.util.Collection items) { + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1Subject item : items) { + io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(item); + _visitables.get("subjects").add(builder); + this.subjects.add(builder); + } + return (A) this; } + public A removeFromSubjects(io.kubernetes.client.openapi.models.V1beta1Subject... items) { - for (io.kubernetes.client.openapi.models.V1beta1Subject item : items) {io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(item);_visitables.get("subjects").remove(builder);if (this.subjects != null) {this.subjects.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1Subject item : items) { + io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(item); + _visitables.get("subjects").remove(builder); + if (this.subjects != null) { + this.subjects.remove(builder); + } + } + return (A) this; } - public A removeAllFromSubjects(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1Subject item : items) {io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(item);_visitables.get("subjects").remove(builder);if (this.subjects != null) {this.subjects.remove(builder);}} return (A)this; + + public A removeAllFromSubjects( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1Subject item : items) { + io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(item); + _visitables.get("subjects").remove(builder); + if (this.subjects != null) { + this.subjects.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromSubjects(java.util.function.Predicate predicate) { + + public A removeMatchingFromSubjects( + java.util.function.Predicate + predicate) { if (subjects == null) return (A) this; - final Iterator each = subjects.iterator(); + final Iterator each = + subjects.iterator(); final List visitables = _visitables.get("subjects"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder = each.next(); @@ -278,144 +701,263 @@ public A removeMatchingFromSubjects(java.util.function.Predicate getSubjects() { return subjects != null ? build(subjects) : null; } + public java.util.List buildSubjects() { return subjects != null ? build(subjects) : null; } + public io.kubernetes.client.openapi.models.V1beta1Subject buildSubject(java.lang.Integer index) { return this.subjects.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1Subject buildFirstSubject() { return this.subjects.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1Subject buildLastSubject() { return this.subjects.get(subjects.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1Subject buildMatchingSubject(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1SubjectBuilder item: subjects) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1Subject buildMatchingSubject( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1SubjectBuilder item : subjects) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingSubject(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1SubjectBuilder item: subjects) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingSubject( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1SubjectBuilder item : subjects) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withSubjects(java.util.List subjects) { - if (this.subjects != null) { _visitables.get("subjects").removeAll(this.subjects);} - if (subjects != null) {this.subjects = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1Subject item : subjects){this.addToSubjects(item);}} else { this.subjects = null;} return (A) this; + + public A withSubjects( + java.util.List subjects) { + if (this.subjects != null) { + _visitables.get("subjects").removeAll(this.subjects); + } + if (subjects != null) { + this.subjects = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1Subject item : subjects) { + this.addToSubjects(item); + } + } else { + this.subjects = null; + } + return (A) this; } + public A withSubjects(io.kubernetes.client.openapi.models.V1beta1Subject... subjects) { - if (this.subjects != null) {this.subjects.clear();} - if (subjects != null) {for (io.kubernetes.client.openapi.models.V1beta1Subject item :subjects){ this.addToSubjects(item);}} return (A) this; + if (this.subjects != null) { + this.subjects.clear(); + } + if (subjects != null) { + for (io.kubernetes.client.openapi.models.V1beta1Subject item : subjects) { + this.addToSubjects(item); + } + } + return (A) this; } + public java.lang.Boolean hasSubjects() { return subjects != null && !subjects.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested addNewSubject() { - return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl.SubjectsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + addNewSubject() { + return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl + .SubjectsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested addNewSubjectLike(io.kubernetes.client.openapi.models.V1beta1Subject item) { - return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl.SubjectsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + addNewSubjectLike(io.kubernetes.client.openapi.models.V1beta1Subject item) { + return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl + .SubjectsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested setNewSubjectLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Subject item) { - return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl.SubjectsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + setNewSubjectLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Subject item) { + return new io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluentImpl + .SubjectsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested editSubject(java.lang.Integer index) { - if (subjects.size() <= index) throw new RuntimeException("Can't edit subjects. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + editSubject(java.lang.Integer index) { + if (subjects.size() <= index) + throw new RuntimeException("Can't edit subjects. Index exceeds size."); return setNewSubjectLike(index, buildSubject(index)); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested editFirstSubject() { - if (subjects.size() == 0) throw new RuntimeException("Can't edit first subjects. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + editFirstSubject() { + if (subjects.size() == 0) + throw new RuntimeException("Can't edit first subjects. The list is empty."); return setNewSubjectLike(0, buildSubject(0)); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested editLastSubject() { + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + editLastSubject() { int index = subjects.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last subjects. The list is empty."); return setNewSubjectLike(index, buildSubject(index)); } - public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested editMatchingSubject(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested + editMatchingSubject( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.NonResourceRulesNested,io.kubernetes.client.fluent.Nested{ - NonResourceRulesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item) { + + public class NonResourceRulesNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + N>, + io.kubernetes.client.fluent.Nested { + NonResourceRulesNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRule item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(this, item); } + NonResourceRulesNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1NonResourcePolicyRuleBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1PolicyRulesWithSubjectsFluentImpl.this.setToNonResourceRules(index,builder.build()); + return (N) + V1beta1PolicyRulesWithSubjectsFluentImpl.this.setToNonResourceRules( + index, builder.build()); } + public N endNonResourceRule() { return and(); } - } - public class ResourceRulesNestedImpl extends io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.ResourceRulesNested,io.kubernetes.client.fluent.Nested{ - ResourceRulesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item) { + + public class ResourceRulesNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + N>, + io.kubernetes.client.fluent.Nested { + ResourceRulesNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(this, item); } + ResourceRulesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1PolicyRulesWithSubjectsFluentImpl.this.setToResourceRules(index,builder.build()); + return (N) + V1beta1PolicyRulesWithSubjectsFluentImpl.this.setToResourceRules(index, builder.build()); } + public N endResourceRule() { return and(); } - } - public class SubjectsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1SubjectFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested,io.kubernetes.client.fluent.Nested{ - SubjectsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1Subject item) { + + public class SubjectsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1SubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent.SubjectsNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PolicyRulesWithSubjectsFluent + .SubjectsNested< + N>, + io.kubernetes.client.fluent.Nested { + SubjectsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1Subject item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(this, item); } + SubjectsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1SubjectBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1SubjectBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1PolicyRulesWithSubjectsFluentImpl.this.setToSubjects(index,builder.build()); + return (N) + V1beta1PolicyRulesWithSubjectsFluentImpl.this.setToSubjects(index, builder.build()); } + public N endSubject() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationBuilder.java index e523dc1a4e..27eef45620 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PriorityLevelConfigurationBuilder extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PriorityLevelConfigurationBuilder + extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder> { public V1beta1PriorityLevelConfigurationBuilder() { this(false); } + public V1beta1PriorityLevelConfigurationBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PriorityLevelConfiguration(), validationEnabled); } - public V1beta1PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent fluent) { + + public V1beta1PriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent fluent) { this(fluent, false); } - public V1beta1PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PriorityLevelConfiguration(), validationEnabled); } - public V1beta1PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration instance) { + + public V1beta1PriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration instance) { this(fluent, instance, false); } - public V1beta1PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1beta1PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.mod fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration instance) { - this(instance,false); + + public V1beta1PriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration instance) { + this(instance, false); } - public V1beta1PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1beta1PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.mod this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration build() { V1beta1PriorityLevelConfiguration buildable = new V1beta1PriorityLevelConfiguration(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration bui buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1PriorityLevelConfigurationBuilder that = (V1beta1PriorityLevelConfigurationBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationConditionBuilder.java index 5cac579368..6ea1efbbb0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationConditionBuilder.java @@ -1,26 +1,58 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PriorityLevelConfigurationConditionBuilder extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PriorityLevelConfigurationConditionBuilder + extends io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder> { public V1beta1PriorityLevelConfigurationConditionBuilder() { this(false); } + public V1beta1PriorityLevelConfigurationConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PriorityLevelConfigurationCondition(), validationEnabled); } - public V1beta1PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent fluent) { + + public V1beta1PriorityLevelConfigurationConditionBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent + fluent) { this(fluent, false); } - public V1beta1PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PriorityLevelConfigurationConditionBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent + fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PriorityLevelConfigurationCondition(), validationEnabled); } - public V1beta1PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent fluent,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition instance) { + + public V1beta1PriorityLevelConfigurationConditionBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent + fluent, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition instance) { this(fluent, instance, false); } - public V1beta1PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent fluent,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PriorityLevelConfigurationConditionBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent + fluent, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +63,18 @@ public V1beta1PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.op fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition instance) { - this(instance,false); + + public V1beta1PriorityLevelConfigurationConditionBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition instance) { + this(instance, false); } - public V1beta1PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PriorityLevelConfigurationConditionBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,12 +85,15 @@ public V1beta1PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.op this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition build() { - V1beta1PriorityLevelConfigurationCondition buildable = new V1beta1PriorityLevelConfigurationCondition(); + V1beta1PriorityLevelConfigurationCondition buildable = + new V1beta1PriorityLevelConfigurationCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); buildable.setMessage(fluent.getMessage()); buildable.setReason(fluent.getReason()); @@ -61,18 +101,24 @@ public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCond buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1beta1PriorityLevelConfigurationConditionBuilder that = (V1beta1PriorityLevelConfigurationConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1beta1PriorityLevelConfigurationConditionBuilder that = + (V1beta1PriorityLevelConfigurationConditionBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationConditionFluent.java index c4c242da6b..86fb40c84f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationConditionFluent.java @@ -1,54 +1,65 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1PriorityLevelConfigurationConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1PriorityLevelConfigurationConditionFluent< + A extends + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationConditionFluentImpl.java index b5a478c56f..a855a16110 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationConditionFluentImpl.java @@ -1,19 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1beta1PriorityLevelConfigurationConditionFluentImpl< + A extends + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent< + A> { + public V1beta1PriorityLevelConfigurationConditionFluentImpl() {} - /** - * Generated - */ -public class V1beta1PriorityLevelConfigurationConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent{ - public V1beta1PriorityLevelConfigurationConditionFluentImpl() { - } - public V1beta1PriorityLevelConfigurationConditionFluentImpl(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition instance) { + public V1beta1PriorityLevelConfigurationConditionFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,103 +32,120 @@ public V1beta1PriorityLevelConfigurationConditionFluentImpl(io.kubernetes.client this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta1PriorityLevelConfigurationConditionFluentImpl that = (V1beta1PriorityLevelConfigurationConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + V1beta1PriorityLevelConfigurationConditionFluentImpl that = + (V1beta1PriorityLevelConfigurationConditionFluentImpl) o; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationFluent.java index 7b96d36432..7a16ca3915 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationFluent.java @@ -1,93 +1,168 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1PriorityLevelConfigurationFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1PriorityLevelConfigurationFluent< + A extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested< + A> + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested< + A> + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested< + A> + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec getSpec(); + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec item); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec item); - + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested + withNewSpecLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested + editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus getStatus(); + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus buildStatus(); - public A withStatus(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus status); + + public A withStatus( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus item); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested + withNewStatusLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent + .SpecNested< + N>> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent + .StatusNested< + N>> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationFluentImpl.java index 88cb113e88..92229b599b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1PriorityLevelConfigurationFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent { + public V1beta1PriorityLevelConfigurationFluentImpl() {} - /** - * Generated - */ -public class V1beta1PriorityLevelConfigurationFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent{ - public V1beta1PriorityLevelConfigurationFluentImpl() { - } - public V1beta1PriorityLevelConfigurationFluentImpl(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration instance) { + public V1beta1PriorityLevelConfigurationFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,346 @@ public V1beta1PriorityLevelConfigurationFluentImpl(io.kubernetes.client.openapi. this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecBuilder spec; private io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested< + A> + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested< + A> + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested< + A> + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } - public A withSpec(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec spec) { + + public A withSpec( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecBuilder( + spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec item) { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested + withNewSpecLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec item) { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested + editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } - public A withStatus(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus status) { + + public A withStatus( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusBuilder( + status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus item) { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested + withNewStatusLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus item) { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta1PriorityLevelConfigurationFluentImpl that = (V1beta1PriorityLevelConfigurationFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + V1beta1PriorityLevelConfigurationFluentImpl that = + (V1beta1PriorityLevelConfigurationFluentImpl) o; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent + .MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1beta1PriorityLevelConfigurationFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent + .SpecNested< + N>, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecBuilder( + this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecBuilder( + this); } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecBuilder builder; + public N and() { return (N) V1beta1PriorityLevelConfigurationFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested,io.kubernetes.client.fluent.Nested{ - StatusNestedImpl(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusBuilder(this, item); + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent.StatusNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent + .StatusNested< + N>, + io.kubernetes.client.fluent.Nested { + StatusNestedImpl( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus item) { + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusBuilder( + this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusBuilder( + this); } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusBuilder builder; + public N and() { return (N) V1beta1PriorityLevelConfigurationFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationListBuilder.java index 2390ecd48d..2218cd754a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PriorityLevelConfigurationListBuilder extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PriorityLevelConfigurationListBuilder + extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationList, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListBuilder> { public V1beta1PriorityLevelConfigurationListBuilder() { this(false); } + public V1beta1PriorityLevelConfigurationListBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PriorityLevelConfigurationList(), validationEnabled); } - public V1beta1PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent fluent) { + + public V1beta1PriorityLevelConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent fluent) { this(fluent, false); } - public V1beta1PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PriorityLevelConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PriorityLevelConfigurationList(), validationEnabled); } - public V1beta1PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent fluent,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationList instance) { + + public V1beta1PriorityLevelConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationList instance) { this(fluent, instance, false); } - public V1beta1PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent fluent,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PriorityLevelConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1beta1PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationList instance) { - this(instance,false); + + public V1beta1PriorityLevelConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationList instance) { + this(instance, false); } - public V1beta1PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PriorityLevelConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1beta1PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationList build() { V1beta1PriorityLevelConfigurationList buildable = new V1beta1PriorityLevelConfigurationList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,24 @@ public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationList buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1beta1PriorityLevelConfigurationListBuilder that = (V1beta1PriorityLevelConfigurationListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1beta1PriorityLevelConfigurationListBuilder that = + (V1beta1PriorityLevelConfigurationListBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationListFluent.java index 23b68cf2a2..072452ed4e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationListFluent.java @@ -1,95 +1,204 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1PriorityLevelConfigurationListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1PriorityLevelConfigurationListFluent< + A extends + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item); - public A addToItems(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration... items); - public A addAllToItems(java.util.Collection items); - public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item); + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item); + + public A addToItems( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration... items); + + public A addAllToItems( + java.util.Collection + items); + + public A removeFromItems( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration... items); + + public A removeAllFromItems( + java.util.Collection + items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getItems(); - public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration buildItem(java.lang.Integer index); + public java.util.List + getItems(); + + public java.util.List + buildItems(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration buildFirstItem(); + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration buildLastItem(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); - public A withItems(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration... items); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder> + predicate); + + public A withItems( + java.util.List items); + + public A withItems( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + addNewItem(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editLastItem(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .MetadataNested< + A> + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .MetadataNested< + A> + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluent< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationListFluentImpl.java index 40f81c4707..46443d8d53 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationListFluentImpl.java @@ -1,26 +1,30 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta1PriorityLevelConfigurationListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent{ - public V1beta1PriorityLevelConfigurationListFluentImpl() { - } - public V1beta1PriorityLevelConfigurationListFluentImpl(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationList instance) { + +/** Generated */ +public class V1beta1PriorityLevelConfigurationListFluentImpl< + A extends + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent { + public V1beta1PriorityLevelConfigurationListFluentImpl() {} + + public V1beta1PriorityLevelConfigurationListFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,233 +32,473 @@ public V1beta1PriorityLevelConfigurationListFluentImpl(io.kubernetes.client.open this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder> + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } - public A addToItems(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item : items) {io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addToItems( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration... items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item : items) { + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item : items) {io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection + items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item : items) { + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration... items) { - for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item : items) {io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeFromItems( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration... items) { + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item : items) { + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item : items) {io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item : items) { + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator + each = items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getItems() { + public java.util.List + getItems() { return items != null ? build(items) : null; } - public java.util.List buildItems() { + + public java.util.List + buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder item : + items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder item : + items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } - public A withItems(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item :items){ this.addToItems(item);}} return (A) this; + + public A withItems( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration... items) { + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + addNewItem() { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item) { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item) { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item) { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item) { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .MetadataNested< + A> + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .MetadataNested< + A> + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta1PriorityLevelConfigurationListFluentImpl that = (V1beta1PriorityLevelConfigurationListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + V1beta1PriorityLevelConfigurationListFluentImpl that = + (V1beta1PriorityLevelConfigurationListFluentImpl) o; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfiguration item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder( + this, item); } + ItemsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1PriorityLevelConfigurationListFluentImpl.this.setToItems(index,builder.build()); + return (N) + V1beta1PriorityLevelConfigurationListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1beta1PriorityLevelConfigurationListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationReferenceBuilder.java index 79b310bb7b..6f8e4222e9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationReferenceBuilder.java @@ -1,58 +1,104 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PriorityLevelConfigurationReferenceBuilder extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PriorityLevelConfigurationReferenceBuilder + extends io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceBuilder> { public V1beta1PriorityLevelConfigurationReferenceBuilder() { this(false); } + public V1beta1PriorityLevelConfigurationReferenceBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PriorityLevelConfigurationReference(), validationEnabled); } - public V1beta1PriorityLevelConfigurationReferenceBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent fluent) { + + public V1beta1PriorityLevelConfigurationReferenceBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent + fluent) { this(fluent, false); } - public V1beta1PriorityLevelConfigurationReferenceBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PriorityLevelConfigurationReferenceBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent + fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PriorityLevelConfigurationReference(), validationEnabled); } - public V1beta1PriorityLevelConfigurationReferenceBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent fluent,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference instance) { + + public V1beta1PriorityLevelConfigurationReferenceBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent + fluent, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference instance) { this(fluent, instance, false); } - public V1beta1PriorityLevelConfigurationReferenceBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent fluent,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PriorityLevelConfigurationReferenceBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent + fluent, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PriorityLevelConfigurationReferenceBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference instance) { - this(instance,false); + + public V1beta1PriorityLevelConfigurationReferenceBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference instance) { + this(instance, false); } - public V1beta1PriorityLevelConfigurationReferenceBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PriorityLevelConfigurationReferenceBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference build() { - V1beta1PriorityLevelConfigurationReference buildable = new V1beta1PriorityLevelConfigurationReference(); + V1beta1PriorityLevelConfigurationReference buildable = + new V1beta1PriorityLevelConfigurationReference(); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1beta1PriorityLevelConfigurationReferenceBuilder that = (V1beta1PriorityLevelConfigurationReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1beta1PriorityLevelConfigurationReferenceBuilder that = + (V1beta1PriorityLevelConfigurationReferenceBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationReferenceFluent.java index beb60e0c73..fcdfe4b4c2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationReferenceFluent.java @@ -1,23 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1PriorityLevelConfigurationReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1PriorityLevelConfigurationReferenceFluent< + A extends + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationReferenceFluentImpl.java index 043ab0a212..4267228531 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationReferenceFluentImpl.java @@ -1,48 +1,62 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta1PriorityLevelConfigurationReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent{ - public V1beta1PriorityLevelConfigurationReferenceFluentImpl() { - } - public V1beta1PriorityLevelConfigurationReferenceFluentImpl(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference instance) { - this.withName(instance.getName()); +/** Generated */ +public class V1beta1PriorityLevelConfigurationReferenceFluentImpl< + A extends + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReferenceFluent< + A> { + public V1beta1PriorityLevelConfigurationReferenceFluentImpl() {} + public V1beta1PriorityLevelConfigurationReferenceFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationReference instance) { + this.withName(instance.getName()); } + private java.lang.String name; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta1PriorityLevelConfigurationReferenceFluentImpl that = (V1beta1PriorityLevelConfigurationReferenceFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + V1beta1PriorityLevelConfigurationReferenceFluentImpl that = + (V1beta1PriorityLevelConfigurationReferenceFluentImpl) o; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, super.hashCode()); + return java.util.Objects.hash(name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationSpecBuilder.java index 902821ae15..8671221459 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationSpecBuilder.java @@ -1,63 +1,103 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PriorityLevelConfigurationSpecBuilder extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PriorityLevelConfigurationSpecBuilder + extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecBuilder> { public V1beta1PriorityLevelConfigurationSpecBuilder() { this(false); } + public V1beta1PriorityLevelConfigurationSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PriorityLevelConfigurationSpec(), validationEnabled); } - public V1beta1PriorityLevelConfigurationSpecBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent fluent) { + + public V1beta1PriorityLevelConfigurationSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent fluent) { this(fluent, false); } - public V1beta1PriorityLevelConfigurationSpecBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PriorityLevelConfigurationSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PriorityLevelConfigurationSpec(), validationEnabled); } - public V1beta1PriorityLevelConfigurationSpecBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec instance) { + + public V1beta1PriorityLevelConfigurationSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec instance) { this(fluent, instance, false); } - public V1beta1PriorityLevelConfigurationSpecBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PriorityLevelConfigurationSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLimited(instance.getLimited()); fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PriorityLevelConfigurationSpecBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec instance) { - this(instance,false); + + public V1beta1PriorityLevelConfigurationSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec instance) { + this(instance, false); } - public V1beta1PriorityLevelConfigurationSpecBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PriorityLevelConfigurationSpecBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLimited(instance.getLimited()); this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec build() { V1beta1PriorityLevelConfigurationSpec buildable = new V1beta1PriorityLevelConfigurationSpec(); buildable.setLimited(fluent.getLimited()); buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1beta1PriorityLevelConfigurationSpecBuilder that = (V1beta1PriorityLevelConfigurationSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1beta1PriorityLevelConfigurationSpecBuilder that = + (V1beta1PriorityLevelConfigurationSpecBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationSpecFluent.java index cd52424c8b..f074b0f26f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationSpecFluent.java @@ -1,44 +1,84 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1PriorityLevelConfigurationSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1beta1PriorityLevelConfigurationSpecFluent< + A extends + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildLimited instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration getLimited(); - public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration buildLimited(); - public A withLimited(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration limited); + + public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration + buildLimited(); + + public A withLimited( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration limited); + public java.lang.Boolean hasLimited(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent.LimitedNested withNewLimited(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent.LimitedNested withNewLimitedLike(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration item); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent.LimitedNested editLimited(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent.LimitedNested editOrNewLimited(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent.LimitedNested editOrNewLimitedLike(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + withNewLimited(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + withNewLimitedLike( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + editLimited(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + editOrNewLimited(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + editOrNewLimitedLike( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration item); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface LimitedNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent>{ + + public interface LimitedNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluent< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent + .LimitedNested< + N>> { public N and(); + public N endLimited(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationSpecFluentImpl.java index 7df9df9c64..486dffc642 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationSpecFluentImpl.java @@ -1,103 +1,175 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1PriorityLevelConfigurationSpecFluentImpl< + A extends + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent { + public V1beta1PriorityLevelConfigurationSpecFluentImpl() {} - /** - * Generated - */ -public class V1beta1PriorityLevelConfigurationSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent{ - public V1beta1PriorityLevelConfigurationSpecFluentImpl() { - } - public V1beta1PriorityLevelConfigurationSpecFluentImpl(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec instance) { + public V1beta1PriorityLevelConfigurationSpecFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpec instance) { this.withLimited(instance.getLimited()); this.withType(instance.getType()); - } - private io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationBuilder limited; + + private io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationBuilder + limited; private java.lang.String type; - + /** * This method has been deprecated, please use method buildLimited instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration getLimited() { - return this.limited!=null ?this.limited.build():null; + return this.limited != null ? this.limited.build() : null; } - public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration buildLimited() { - return this.limited!=null ?this.limited.build():null; + + public io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration + buildLimited() { + return this.limited != null ? this.limited.build() : null; } - public A withLimited(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration limited) { + + public A withLimited( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration limited) { _visitables.get("limited").remove(this.limited); - if (limited!=null){ this.limited= new io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationBuilder(limited); _visitables.get("limited").add(this.limited);} return (A) this; + if (limited != null) { + this.limited = + new io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationBuilder( + limited); + _visitables.get("limited").add(this.limited); + } + return (A) this; } + public java.lang.Boolean hasLimited() { return this.limited != null; } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent.LimitedNested withNewLimited() { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluentImpl.LimitedNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + withNewLimited() { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluentImpl + .LimitedNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent.LimitedNested withNewLimitedLike(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration item) { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluentImpl.LimitedNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + withNewLimitedLike( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration item) { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluentImpl + .LimitedNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent.LimitedNested editLimited() { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + editLimited() { return withNewLimitedLike(getLimited()); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent.LimitedNested editOrNewLimited() { - return withNewLimitedLike(getLimited() != null ? getLimited(): new io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + editOrNewLimited() { + return withNewLimitedLike( + getLimited() != null + ? getLimited() + : new io.kubernetes.client.openapi.models + .V1beta1LimitedPriorityLevelConfigurationBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent.LimitedNested editOrNewLimitedLike(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration item) { - return withNewLimitedLike(getLimited() != null ? getLimited(): item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + editOrNewLimitedLike( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration item) { + return withNewLimitedLike(getLimited() != null ? getLimited() : item); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta1PriorityLevelConfigurationSpecFluentImpl that = (V1beta1PriorityLevelConfigurationSpecFluentImpl) o; - if (limited != null ? !limited.equals(that.limited) :that.limited != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + V1beta1PriorityLevelConfigurationSpecFluentImpl that = + (V1beta1PriorityLevelConfigurationSpecFluentImpl) o; + if (limited != null ? !limited.equals(that.limited) : that.limited != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(limited, type, super.hashCode()); + return java.util.Objects.hash(limited, type, super.hashCode()); } - public class LimitedNestedImpl extends io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent.LimitedNested,io.kubernetes.client.fluent.Nested{ - LimitedNestedImpl(io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationBuilder(this, item); + + public class LimitedNestedImpl + extends io.kubernetes.client.openapi.models + .V1beta1LimitedPriorityLevelConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent + .LimitedNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationSpecFluent + .LimitedNested< + N>, + io.kubernetes.client.fluent.Nested { + LimitedNestedImpl( + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfiguration item) { + this.builder = + new io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationBuilder( + this, item); } + LimitedNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationBuilder( + this); } + io.kubernetes.client.openapi.models.V1beta1LimitedPriorityLevelConfigurationBuilder builder; + public N and() { return (N) V1beta1PriorityLevelConfigurationSpecFluentImpl.this.withLimited(builder.build()); } + public N endLimited() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationStatusBuilder.java index 924d6a2e12..2a1af5dd22 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationStatusBuilder.java @@ -1,58 +1,99 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1PriorityLevelConfigurationStatusBuilder extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1PriorityLevelConfigurationStatusBuilder + extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusBuilder> { public V1beta1PriorityLevelConfigurationStatusBuilder() { this(false); } + public V1beta1PriorityLevelConfigurationStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1PriorityLevelConfigurationStatus(), validationEnabled); } - public V1beta1PriorityLevelConfigurationStatusBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent fluent) { + + public V1beta1PriorityLevelConfigurationStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent fluent) { this(fluent, false); } - public V1beta1PriorityLevelConfigurationStatusBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1PriorityLevelConfigurationStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1PriorityLevelConfigurationStatus(), validationEnabled); } - public V1beta1PriorityLevelConfigurationStatusBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent fluent,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus instance) { + + public V1beta1PriorityLevelConfigurationStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus instance) { this(fluent, instance, false); } - public V1beta1PriorityLevelConfigurationStatusBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent fluent,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1PriorityLevelConfigurationStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent fluent, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditions(instance.getConditions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1PriorityLevelConfigurationStatusBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus instance) { - this(instance,false); + + public V1beta1PriorityLevelConfigurationStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus instance) { + this(instance, false); } - public V1beta1PriorityLevelConfigurationStatusBuilder(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1PriorityLevelConfigurationStatusBuilder( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditions(instance.getConditions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus build() { - V1beta1PriorityLevelConfigurationStatus buildable = new V1beta1PriorityLevelConfigurationStatus(); + V1beta1PriorityLevelConfigurationStatus buildable = + new V1beta1PriorityLevelConfigurationStatus(); buildable.setConditions(fluent.getConditions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1beta1PriorityLevelConfigurationStatusBuilder that = (V1beta1PriorityLevelConfigurationStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1beta1PriorityLevelConfigurationStatusBuilder that = + (V1beta1PriorityLevelConfigurationStatusBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationStatusFluent.java index 96a9acb4b3..eaa9b53bb7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationStatusFluent.java @@ -1,57 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1PriorityLevelConfigurationStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item); - public A addToConditions(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition... items); - public A addAllToConditions(java.util.Collection items); - public A removeFromConditions(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - +/** Generated */ +public interface V1beta1PriorityLevelConfigurationStatusFluent< + A extends + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item); + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item); + + public A addToConditions( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition... items); + + public A addAllToConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition> + items); + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition... items); + + public A removeAllFromConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition> + items); + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder> + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition buildCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition buildFirstCondition(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); - public A withConditions(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition... conditions); + public java.util.List< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition> + getConditions(); + + public java.util.List< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition> + buildConditions(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition + buildCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition + buildFirstCondition(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition + buildLastCondition(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionBuilder> + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder> + predicate); + + public A withConditions( + java.util.List + conditions); + + public A withConditions( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionBuilder> + predicate); + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluent< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationStatusFluentImpl.java index 77faa57c0c..cb45e77cc9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1PriorityLevelConfigurationStatusFluentImpl.java @@ -1,163 +1,400 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1beta1PriorityLevelConfigurationStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent{ - public V1beta1PriorityLevelConfigurationStatusFluentImpl() { - } - public V1beta1PriorityLevelConfigurationStatusFluentImpl(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus instance) { - this.withConditions(instance.getConditions()); +/** Generated */ +public class V1beta1PriorityLevelConfigurationStatusFluentImpl< + A extends + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent< + A> { + public V1beta1PriorityLevelConfigurationStatusFluentImpl() {} + public V1beta1PriorityLevelConfigurationStatusFluentImpl( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatus instance) { + this.withConditions(instance.getConditions()); } - private java.util.ArrayList conditions; - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder> + conditions; + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder( + item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder( + item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } - public A addToConditions(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item : items) {io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addToConditions( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition... items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item : + items) { + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder + builder = + new io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item : items) {io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition> + items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item : + items) { + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder + builder = + new io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition... items) { - for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item : items) {io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition... items) { + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item : + items) { + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder + builder = + new io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item : items) {io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition> + items) { + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item : + items) { + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder + builder = + new io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder> + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder> + each = conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder + builder = each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions() { + public java.util.List< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition> + getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition> + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition + buildCondition(java.lang.Integer index) { return this.conditions.get(index).build(); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition buildFirstCondition() { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition + buildFirstCondition() { return this.conditions.get(0).build(); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition buildLastCondition() { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition + buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder + item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder + item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List + conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item : + conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } - public A withConditions(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item :conditions){ this.addToConditions(item);}} return (A) this; + + public A withConditions( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition... + conditions) { + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item : + conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item) { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item) { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item) { - return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item) { + return new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models + .V1beta1PriorityLevelConfigurationConditionFluentImpl< + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationStatusFluent + .ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder( + this, item); } + ConditionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder( + this); } + io.kubernetes.client.openapi.models.V1beta1PriorityLevelConfigurationConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1PriorityLevelConfigurationStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) + V1beta1PriorityLevelConfigurationStatusFluentImpl.this.setToConditions( + index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1QueuingConfigurationBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1QueuingConfigurationBuilder.java index da0e599468..cfd0005157 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1QueuingConfigurationBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1QueuingConfigurationBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1QueuingConfigurationBuilder extends io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1QueuingConfigurationBuilder + extends io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration, + io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationBuilder> { public V1beta1QueuingConfigurationBuilder() { this(false); } + public V1beta1QueuingConfigurationBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1QueuingConfiguration(), validationEnabled); } - public V1beta1QueuingConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent fluent) { + + public V1beta1QueuingConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent fluent) { this(fluent, false); } - public V1beta1QueuingConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1QueuingConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1QueuingConfiguration(), validationEnabled); } - public V1beta1QueuingConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration instance) { + + public V1beta1QueuingConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration instance) { this(fluent, instance, false); } - public V1beta1QueuingConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1QueuingConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withHandSize(instance.getHandSize()); fluent.withQueueLengthLimit(instance.getQueueLengthLimit()); fluent.withQueues(instance.getQueues()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1QueuingConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration instance) { - this(instance,false); + + public V1beta1QueuingConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration instance) { + this(instance, false); } - public V1beta1QueuingConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1QueuingConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withHandSize(instance.getHandSize()); this.withQueueLengthLimit(instance.getQueueLengthLimit()); this.withQueues(instance.getQueues()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration build() { V1beta1QueuingConfiguration buildable = new V1beta1QueuingConfiguration(); buildable.setHandSize(fluent.getHandSize()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration build() { buildable.setQueues(fluent.getQueues()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1QueuingConfigurationBuilder that = (V1beta1QueuingConfigurationBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1QueuingConfigurationFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1QueuingConfigurationFluent.java index 0977116918..299c482251 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1QueuingConfigurationFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1QueuingConfigurationFluent.java @@ -1,23 +1,36 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1QueuingConfigurationFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1QueuingConfigurationFluent< + A extends io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getHandSize(); + public A withHandSize(java.lang.Integer handSize); + public java.lang.Boolean hasHandSize(); + public java.lang.Integer getQueueLengthLimit(); + public A withQueueLengthLimit(java.lang.Integer queueLengthLimit); + public java.lang.Boolean hasQueueLengthLimit(); + public java.lang.Integer getQueues(); + public A withQueues(java.lang.Integer queues); + public java.lang.Boolean hasQueues(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1QueuingConfigurationFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1QueuingConfigurationFluentImpl.java index f9b7a81533..77af229edd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1QueuingConfigurationFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1QueuingConfigurationFluentImpl.java @@ -1,65 +1,89 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1QueuingConfigurationFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent { + public V1beta1QueuingConfigurationFluentImpl() {} - /** - * Generated - */ -public class V1beta1QueuingConfigurationFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1QueuingConfigurationFluent{ - public V1beta1QueuingConfigurationFluentImpl() { - } - public V1beta1QueuingConfigurationFluentImpl(io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration instance) { + public V1beta1QueuingConfigurationFluentImpl( + io.kubernetes.client.openapi.models.V1beta1QueuingConfiguration instance) { this.withHandSize(instance.getHandSize()); this.withQueueLengthLimit(instance.getQueueLengthLimit()); this.withQueues(instance.getQueues()); - } + private java.lang.Integer handSize; private java.lang.Integer queueLengthLimit; private java.lang.Integer queues; + public java.lang.Integer getHandSize() { return this.handSize; } + public A withHandSize(java.lang.Integer handSize) { - this.handSize=handSize; return (A) this; + this.handSize = handSize; + return (A) this; } + public java.lang.Boolean hasHandSize() { return this.handSize != null; } + public java.lang.Integer getQueueLengthLimit() { return this.queueLengthLimit; } + public A withQueueLengthLimit(java.lang.Integer queueLengthLimit) { - this.queueLengthLimit=queueLengthLimit; return (A) this; + this.queueLengthLimit = queueLengthLimit; + return (A) this; } + public java.lang.Boolean hasQueueLengthLimit() { return this.queueLengthLimit != null; } + public java.lang.Integer getQueues() { return this.queues; } + public A withQueues(java.lang.Integer queues) { - this.queues=queues; return (A) this; + this.queues = queues; + return (A) this; } + public java.lang.Boolean hasQueues() { return this.queues != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1QueuingConfigurationFluentImpl that = (V1beta1QueuingConfigurationFluentImpl) o; - if (handSize != null ? !handSize.equals(that.handSize) :that.handSize != null) return false; - if (queueLengthLimit != null ? !queueLengthLimit.equals(that.queueLengthLimit) :that.queueLengthLimit != null) return false; - if (queues != null ? !queues.equals(that.queues) :that.queues != null) return false; + if (handSize != null ? !handSize.equals(that.handSize) : that.handSize != null) return false; + if (queueLengthLimit != null + ? !queueLengthLimit.equals(that.queueLengthLimit) + : that.queueLengthLimit != null) return false; + if (queues != null ? !queues.equals(that.queues) : that.queues != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(handSize, queueLengthLimit, queues, super.hashCode()); + return java.util.Objects.hash(handSize, queueLengthLimit, queues, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ResourcePolicyRuleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ResourcePolicyRuleBuilder.java index e38dd07579..0228c14109 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ResourcePolicyRuleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ResourcePolicyRuleBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1ResourcePolicyRuleBuilder extends io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1ResourcePolicyRuleBuilder + extends io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluentImpl< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule, + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleBuilder> { public V1beta1ResourcePolicyRuleBuilder() { this(false); } + public V1beta1ResourcePolicyRuleBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1ResourcePolicyRule(), validationEnabled); } - public V1beta1ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent fluent) { + + public V1beta1ResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent fluent) { this(fluent, false); } - public V1beta1ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1ResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1ResourcePolicyRule(), validationEnabled); } - public V1beta1ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent fluent,io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule instance) { + + public V1beta1ResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent fluent, + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule instance) { this(fluent, instance, false); } - public V1beta1ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent fluent,io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1ResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent fluent, + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiGroups(instance.getApiGroups()); fluent.withClusterScope(instance.getClusterScope()); @@ -31,13 +58,18 @@ public V1beta1ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1be fluent.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule instance) { - this(instance,false); + + public V1beta1ResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule instance) { + this(instance, false); } - public V1beta1ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1ResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiGroups(instance.getApiGroups()); this.withClusterScope(instance.getClusterScope()); @@ -48,10 +80,12 @@ public V1beta1ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1be this.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule build() { V1beta1ResourcePolicyRule buildable = new V1beta1ResourcePolicyRule(); buildable.setApiGroups(fluent.getApiGroups()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule build() { buildable.setVerbs(fluent.getVerbs()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1ResourcePolicyRuleBuilder that = (V1beta1ResourcePolicyRuleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ResourcePolicyRuleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ResourcePolicyRuleFluent.java index 51c03848b2..4d3b90902a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ResourcePolicyRuleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ResourcePolicyRuleFluent.java @@ -1,85 +1,159 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1beta1ResourcePolicyRuleFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToApiGroups(java.lang.Integer index,java.lang.String item); - public A setToApiGroups(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1beta1ResourcePolicyRuleFluent< + A extends io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToApiGroups(java.lang.Integer index, java.lang.String item); + + public A setToApiGroups(java.lang.Integer index, java.lang.String item); + public A addToApiGroups(java.lang.String... items); + public A addAllToApiGroups(java.util.Collection items); + public A removeFromApiGroups(java.lang.String... items); + public A removeAllFromApiGroups(java.util.Collection items); + public java.util.List getApiGroups(); + public java.lang.String getApiGroup(java.lang.Integer index); + public java.lang.String getFirstApiGroup(); + public java.lang.String getLastApiGroup(); - public java.lang.String getMatchingApiGroup(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingApiGroup(java.util.function.Predicate predicate); + + public java.lang.String getMatchingApiGroup( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingApiGroup( + java.util.function.Predicate predicate); + public A withApiGroups(java.util.List apiGroups); + public A withApiGroups(java.lang.String... apiGroups); + public java.lang.Boolean hasApiGroups(); + public A addNewApiGroup(java.lang.String original); + public java.lang.Boolean getClusterScope(); + public A withClusterScope(java.lang.Boolean clusterScope); + public java.lang.Boolean hasClusterScope(); - public A addToNamespaces(java.lang.Integer index,java.lang.String item); - public A setToNamespaces(java.lang.Integer index,java.lang.String item); + + public A addToNamespaces(java.lang.Integer index, java.lang.String item); + + public A setToNamespaces(java.lang.Integer index, java.lang.String item); + public A addToNamespaces(java.lang.String... items); + public A addAllToNamespaces(java.util.Collection items); + public A removeFromNamespaces(java.lang.String... items); + public A removeAllFromNamespaces(java.util.Collection items); + public java.util.List getNamespaces(); + public java.lang.String getNamespace(java.lang.Integer index); + public java.lang.String getFirstNamespace(); + public java.lang.String getLastNamespace(); - public java.lang.String getMatchingNamespace(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingNamespace(java.util.function.Predicate predicate); + + public java.lang.String getMatchingNamespace( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingNamespace( + java.util.function.Predicate predicate); + public A withNamespaces(java.util.List namespaces); + public A withNamespaces(java.lang.String... namespaces); + public java.lang.Boolean hasNamespaces(); + public A addNewNamespace(java.lang.String original); - public A addToResources(java.lang.Integer index,java.lang.String item); - public A setToResources(java.lang.Integer index,java.lang.String item); + + public A addToResources(java.lang.Integer index, java.lang.String item); + + public A setToResources(java.lang.Integer index, java.lang.String item); + public A addToResources(java.lang.String... items); + public A addAllToResources(java.util.Collection items); + public A removeFromResources(java.lang.String... items); + public A removeAllFromResources(java.util.Collection items); + public java.util.List getResources(); + public java.lang.String getResource(java.lang.Integer index); + public java.lang.String getFirstResource(); + public java.lang.String getLastResource(); - public java.lang.String getMatchingResource(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingResource(java.util.function.Predicate predicate); + + public java.lang.String getMatchingResource( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingResource( + java.util.function.Predicate predicate); + public A withResources(java.util.List resources); + public A withResources(java.lang.String... resources); + public java.lang.Boolean hasResources(); + public A addNewResource(java.lang.String original); - public A addToVerbs(java.lang.Integer index,java.lang.String item); - public A setToVerbs(java.lang.Integer index,java.lang.String item); + + public A addToVerbs(java.lang.Integer index, java.lang.String item); + + public A setToVerbs(java.lang.Integer index, java.lang.String item); + public A addToVerbs(java.lang.String... items); + public A addAllToVerbs(java.util.Collection items); + public A removeFromVerbs(java.lang.String... items); + public A removeAllFromVerbs(java.util.Collection items); + public java.util.List getVerbs(); + public java.lang.String getVerb(java.lang.Integer index); + public java.lang.String getFirstVerb(); + public java.lang.String getLastVerb(); + public java.lang.String getMatchingVerb(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate); + public A withVerbs(java.util.List verbs); + public A withVerbs(java.lang.String... verbs); + public java.lang.Boolean hasVerbs(); + public A addNewVerb(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ResourcePolicyRuleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ResourcePolicyRuleFluentImpl.java index 77f9f5f8a3..c9c3c93c1a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ResourcePolicyRuleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ResourcePolicyRuleFluentImpl.java @@ -1,22 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.ArrayList; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public class V1beta1ResourcePolicyRuleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent{ - public V1beta1ResourcePolicyRuleFluentImpl() { - } - public V1beta1ResourcePolicyRuleFluentImpl(io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule instance) { +/** Generated */ +public class V1beta1ResourcePolicyRuleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRuleFluent { + public V1beta1ResourcePolicyRuleFluentImpl() {} + + public V1beta1ResourcePolicyRuleFluentImpl( + io.kubernetes.client.openapi.models.V1beta1ResourcePolicyRule instance) { this.withApiGroups(instance.getApiGroups()); this.withClusterScope(instance.getClusterScope()); @@ -26,251 +30,533 @@ public V1beta1ResourcePolicyRuleFluentImpl(io.kubernetes.client.openapi.models.V this.withResources(instance.getResources()); this.withVerbs(instance.getVerbs()); - } + private java.util.List apiGroups; private java.lang.Boolean clusterScope; private java.util.List namespaces; private java.util.List resources; private java.util.List verbs; - public A addToApiGroups(java.lang.Integer index,java.lang.String item) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} + + public A addToApiGroups(java.lang.Integer index, java.lang.String item) { + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } this.apiGroups.add(index, item); - return (A)this; + return (A) this; } - public A setToApiGroups(java.lang.Integer index,java.lang.String item) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - this.apiGroups.set(index, item); return (A)this; + + public A setToApiGroups(java.lang.Integer index, java.lang.String item) { + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + this.apiGroups.set(index, item); + return (A) this; } + public A addToApiGroups(java.lang.String... items) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.apiGroups.add(item);} return (A)this; + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.apiGroups.add(item); + } + return (A) this; } + public A addAllToApiGroups(java.util.Collection items) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.apiGroups.add(item);} return (A)this; + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.apiGroups.add(item); + } + return (A) this; } + public A removeFromApiGroups(java.lang.String... items) { - for (java.lang.String item : items) {if (this.apiGroups!= null){ this.apiGroups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.apiGroups != null) { + this.apiGroups.remove(item); + } + } + return (A) this; } + public A removeAllFromApiGroups(java.util.Collection items) { - for (java.lang.String item : items) {if (this.apiGroups!= null){ this.apiGroups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.apiGroups != null) { + this.apiGroups.remove(item); + } + } + return (A) this; } + public java.util.List getApiGroups() { return this.apiGroups; } + public java.lang.String getApiGroup(java.lang.Integer index) { return this.apiGroups.get(index); } + public java.lang.String getFirstApiGroup() { return this.apiGroups.get(0); } + public java.lang.String getLastApiGroup() { return this.apiGroups.get(apiGroups.size() - 1); } - public java.lang.String getMatchingApiGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: apiGroups) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingApiGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : apiGroups) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingApiGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: apiGroups) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingApiGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : apiGroups) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withApiGroups(java.util.List apiGroups) { - if (apiGroups != null) {this.apiGroups = new java.util.ArrayList(); for (java.lang.String item : apiGroups){this.addToApiGroups(item);}} else { this.apiGroups = null;} return (A) this; + if (apiGroups != null) { + this.apiGroups = new java.util.ArrayList(); + for (java.lang.String item : apiGroups) { + this.addToApiGroups(item); + } + } else { + this.apiGroups = null; + } + return (A) this; } + public A withApiGroups(java.lang.String... apiGroups) { - if (this.apiGroups != null) {this.apiGroups.clear();} - if (apiGroups != null) {for (java.lang.String item :apiGroups){ this.addToApiGroups(item);}} return (A) this; + if (this.apiGroups != null) { + this.apiGroups.clear(); + } + if (apiGroups != null) { + for (java.lang.String item : apiGroups) { + this.addToApiGroups(item); + } + } + return (A) this; } + public java.lang.Boolean hasApiGroups() { return apiGroups != null && !apiGroups.isEmpty(); } + public A addNewApiGroup(java.lang.String original) { - return (A)addToApiGroups(new String(original)); + return (A) addToApiGroups(new String(original)); } + public java.lang.Boolean getClusterScope() { return this.clusterScope; } + public A withClusterScope(java.lang.Boolean clusterScope) { - this.clusterScope=clusterScope; return (A) this; + this.clusterScope = clusterScope; + return (A) this; } + public java.lang.Boolean hasClusterScope() { return this.clusterScope != null; } - public A addToNamespaces(java.lang.Integer index,java.lang.String item) { - if (this.namespaces == null) {this.namespaces = new java.util.ArrayList();} + + public A addToNamespaces(java.lang.Integer index, java.lang.String item) { + if (this.namespaces == null) { + this.namespaces = new java.util.ArrayList(); + } this.namespaces.add(index, item); - return (A)this; + return (A) this; } - public A setToNamespaces(java.lang.Integer index,java.lang.String item) { - if (this.namespaces == null) {this.namespaces = new java.util.ArrayList();} - this.namespaces.set(index, item); return (A)this; + + public A setToNamespaces(java.lang.Integer index, java.lang.String item) { + if (this.namespaces == null) { + this.namespaces = new java.util.ArrayList(); + } + this.namespaces.set(index, item); + return (A) this; } + public A addToNamespaces(java.lang.String... items) { - if (this.namespaces == null) {this.namespaces = new java.util.ArrayList();} - for (java.lang.String item : items) {this.namespaces.add(item);} return (A)this; + if (this.namespaces == null) { + this.namespaces = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.namespaces.add(item); + } + return (A) this; } + public A addAllToNamespaces(java.util.Collection items) { - if (this.namespaces == null) {this.namespaces = new java.util.ArrayList();} - for (java.lang.String item : items) {this.namespaces.add(item);} return (A)this; + if (this.namespaces == null) { + this.namespaces = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.namespaces.add(item); + } + return (A) this; } + public A removeFromNamespaces(java.lang.String... items) { - for (java.lang.String item : items) {if (this.namespaces!= null){ this.namespaces.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.namespaces != null) { + this.namespaces.remove(item); + } + } + return (A) this; } + public A removeAllFromNamespaces(java.util.Collection items) { - for (java.lang.String item : items) {if (this.namespaces!= null){ this.namespaces.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.namespaces != null) { + this.namespaces.remove(item); + } + } + return (A) this; } + public java.util.List getNamespaces() { return this.namespaces; } + public java.lang.String getNamespace(java.lang.Integer index) { return this.namespaces.get(index); } + public java.lang.String getFirstNamespace() { return this.namespaces.get(0); } + public java.lang.String getLastNamespace() { return this.namespaces.get(namespaces.size() - 1); } - public java.lang.String getMatchingNamespace(java.util.function.Predicate predicate) { - for (java.lang.String item: namespaces) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingNamespace( + java.util.function.Predicate predicate) { + for (java.lang.String item : namespaces) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingNamespace(java.util.function.Predicate predicate) { - for (java.lang.String item: namespaces) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingNamespace( + java.util.function.Predicate predicate) { + for (java.lang.String item : namespaces) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withNamespaces(java.util.List namespaces) { - if (namespaces != null) {this.namespaces = new java.util.ArrayList(); for (java.lang.String item : namespaces){this.addToNamespaces(item);}} else { this.namespaces = null;} return (A) this; + if (namespaces != null) { + this.namespaces = new java.util.ArrayList(); + for (java.lang.String item : namespaces) { + this.addToNamespaces(item); + } + } else { + this.namespaces = null; + } + return (A) this; } + public A withNamespaces(java.lang.String... namespaces) { - if (this.namespaces != null) {this.namespaces.clear();} - if (namespaces != null) {for (java.lang.String item :namespaces){ this.addToNamespaces(item);}} return (A) this; + if (this.namespaces != null) { + this.namespaces.clear(); + } + if (namespaces != null) { + for (java.lang.String item : namespaces) { + this.addToNamespaces(item); + } + } + return (A) this; } + public java.lang.Boolean hasNamespaces() { return namespaces != null && !namespaces.isEmpty(); } + public A addNewNamespace(java.lang.String original) { - return (A)addToNamespaces(new String(original)); + return (A) addToNamespaces(new String(original)); } - public A addToResources(java.lang.Integer index,java.lang.String item) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} + + public A addToResources(java.lang.Integer index, java.lang.String item) { + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } this.resources.add(index, item); - return (A)this; + return (A) this; } - public A setToResources(java.lang.Integer index,java.lang.String item) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - this.resources.set(index, item); return (A)this; + + public A setToResources(java.lang.Integer index, java.lang.String item) { + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + this.resources.set(index, item); + return (A) this; } + public A addToResources(java.lang.String... items) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resources.add(item);} return (A)this; + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resources.add(item); + } + return (A) this; } + public A addAllToResources(java.util.Collection items) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resources.add(item);} return (A)this; + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resources.add(item); + } + return (A) this; } + public A removeFromResources(java.lang.String... items) { - for (java.lang.String item : items) {if (this.resources!= null){ this.resources.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resources != null) { + this.resources.remove(item); + } + } + return (A) this; } + public A removeAllFromResources(java.util.Collection items) { - for (java.lang.String item : items) {if (this.resources!= null){ this.resources.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resources != null) { + this.resources.remove(item); + } + } + return (A) this; } + public java.util.List getResources() { return this.resources; } + public java.lang.String getResource(java.lang.Integer index) { return this.resources.get(index); } + public java.lang.String getFirstResource() { return this.resources.get(0); } + public java.lang.String getLastResource() { return this.resources.get(resources.size() - 1); } - public java.lang.String getMatchingResource(java.util.function.Predicate predicate) { - for (java.lang.String item: resources) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingResource( + java.util.function.Predicate predicate) { + for (java.lang.String item : resources) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingResource(java.util.function.Predicate predicate) { - for (java.lang.String item: resources) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingResource( + java.util.function.Predicate predicate) { + for (java.lang.String item : resources) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withResources(java.util.List resources) { - if (resources != null) {this.resources = new java.util.ArrayList(); for (java.lang.String item : resources){this.addToResources(item);}} else { this.resources = null;} return (A) this; + if (resources != null) { + this.resources = new java.util.ArrayList(); + for (java.lang.String item : resources) { + this.addToResources(item); + } + } else { + this.resources = null; + } + return (A) this; } + public A withResources(java.lang.String... resources) { - if (this.resources != null) {this.resources.clear();} - if (resources != null) {for (java.lang.String item :resources){ this.addToResources(item);}} return (A) this; + if (this.resources != null) { + this.resources.clear(); + } + if (resources != null) { + for (java.lang.String item : resources) { + this.addToResources(item); + } + } + return (A) this; } + public java.lang.Boolean hasResources() { return resources != null && !resources.isEmpty(); } + public A addNewResource(java.lang.String original) { - return (A)addToResources(new String(original)); + return (A) addToResources(new String(original)); } - public A addToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} + + public A addToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } this.verbs.add(index, item); - return (A)this; + return (A) this; } - public A setToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - this.verbs.set(index, item); return (A)this; + + public A setToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + this.verbs.set(index, item); + return (A) this; } + public A addToVerbs(java.lang.String... items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A addAllToVerbs(java.util.Collection items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A removeFromVerbs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public A removeAllFromVerbs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public java.util.List getVerbs() { return this.verbs; } + public java.lang.String getVerb(java.lang.Integer index) { return this.verbs.get(index); } + public java.lang.String getFirstVerb() { return this.verbs.get(0); } + public java.lang.String getLastVerb() { return this.verbs.get(verbs.size() - 1); } - public java.lang.String getMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withVerbs(java.util.List verbs) { - if (verbs != null) {this.verbs = new java.util.ArrayList(); for (java.lang.String item : verbs){this.addToVerbs(item);}} else { this.verbs = null;} return (A) this; + if (verbs != null) { + this.verbs = new java.util.ArrayList(); + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } else { + this.verbs = null; + } + return (A) this; } + public A withVerbs(java.lang.String... verbs) { - if (this.verbs != null) {this.verbs.clear();} - if (verbs != null) {for (java.lang.String item :verbs){ this.addToVerbs(item);}} return (A) this; + if (this.verbs != null) { + this.verbs.clear(); + } + if (verbs != null) { + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } + return (A) this; } + public java.lang.Boolean hasVerbs() { return verbs != null && !verbs.isEmpty(); } + public A addNewVerb(java.lang.String original) { - return (A)addToVerbs(new String(original)); + return (A) addToVerbs(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1ResourcePolicyRuleFluentImpl that = (V1beta1ResourcePolicyRuleFluentImpl) o; - if (apiGroups != null ? !apiGroups.equals(that.apiGroups) :that.apiGroups != null) return false; - if (clusterScope != null ? !clusterScope.equals(that.clusterScope) :that.clusterScope != null) return false; - if (namespaces != null ? !namespaces.equals(that.namespaces) :that.namespaces != null) return false; - if (resources != null ? !resources.equals(that.resources) :that.resources != null) return false; - if (verbs != null ? !verbs.equals(that.verbs) :that.verbs != null) return false; + if (apiGroups != null ? !apiGroups.equals(that.apiGroups) : that.apiGroups != null) + return false; + if (clusterScope != null ? !clusterScope.equals(that.clusterScope) : that.clusterScope != null) + return false; + if (namespaces != null ? !namespaces.equals(that.namespaces) : that.namespaces != null) + return false; + if (resources != null ? !resources.equals(that.resources) : that.resources != null) + return false; + if (verbs != null ? !verbs.equals(that.verbs) : that.verbs != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiGroups, clusterScope, namespaces, resources, verbs, super.hashCode()); + return java.util.Objects.hash( + apiGroups, clusterScope, namespaces, resources, verbs, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsGroupStrategyOptionsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsGroupStrategyOptionsBuilder.java index 66464c87ce..2a9bea9310 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsGroupStrategyOptionsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsGroupStrategyOptionsBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1RunAsGroupStrategyOptionsBuilder extends io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1RunAsGroupStrategyOptionsBuilder + extends io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions, + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsBuilder> { public V1beta1RunAsGroupStrategyOptionsBuilder() { this(false); } + public V1beta1RunAsGroupStrategyOptionsBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1RunAsGroupStrategyOptions(), validationEnabled); } - public V1beta1RunAsGroupStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent fluent) { + + public V1beta1RunAsGroupStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent fluent) { this(fluent, false); } - public V1beta1RunAsGroupStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1RunAsGroupStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1RunAsGroupStrategyOptions(), validationEnabled); } - public V1beta1RunAsGroupStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions instance) { + + public V1beta1RunAsGroupStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions instance) { this(fluent, instance, false); } - public V1beta1RunAsGroupStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1RunAsGroupStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withRanges(instance.getRanges()); fluent.withRule(instance.getRule()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1RunAsGroupStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions instance) { - this(instance,false); + + public V1beta1RunAsGroupStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions instance) { + this(instance, false); } - public V1beta1RunAsGroupStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1RunAsGroupStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withRanges(instance.getRanges()); this.withRule(instance.getRule()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions build() { V1beta1RunAsGroupStrategyOptions buildable = new V1beta1RunAsGroupStrategyOptions(); buildable.setRanges(fluent.getRanges()); buildable.setRule(fluent.getRule()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1RunAsGroupStrategyOptionsBuilder that = (V1beta1RunAsGroupStrategyOptionsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsGroupStrategyOptionsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsGroupStrategyOptionsFluent.java index f516ab32e8..9cceecb844 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsGroupStrategyOptionsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsGroupStrategyOptionsFluent.java @@ -1,66 +1,113 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1RunAsGroupStrategyOptionsFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item); - public A setToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item); +/** Generated */ +public interface V1beta1RunAsGroupStrategyOptionsFluent< + A extends io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item); + + public A setToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item); + public A addToRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items); - public A addAllToRanges(java.util.Collection items); + + public A addAllToRanges( + java.util.Collection items); + public A removeFromRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items); - public A removeAllFromRanges(java.util.Collection items); - public A removeMatchingFromRanges(java.util.function.Predicate predicate); - + + public A removeAllFromRanges( + java.util.Collection items); + + public A removeMatchingFromRanges( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildRanges instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getRanges(); + public java.util.List buildRanges(); + public io.kubernetes.client.openapi.models.V1beta1IDRange buildRange(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1IDRange buildFirstRange(); + public io.kubernetes.client.openapi.models.V1beta1IDRange buildLastRange(); - public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRange(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingRange( + java.util.function.Predicate + predicate); + public A withRanges(java.util.List ranges); + public A withRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... ranges); + public java.lang.Boolean hasRanges(); - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested addNewRange(); - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item); - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested setNewRangeLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item); - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested editRange(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested editFirstRange(); - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested editLastRange(); - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested editMatchingRange(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + addNewRange(); + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item); + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + setNewRangeLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item); + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + editRange(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + editFirstRange(); + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + editLastRange(); + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + editMatchingRange( + java.util.function.Predicate + predicate); + public java.lang.String getRule(); + public A withRule(java.lang.String rule); + public java.lang.Boolean hasRule(); - - /** - * Method is deprecated. use withRule instead. - */ + + /** Method is deprecated. use withRule instead. */ @java.lang.Deprecated public A withNewRule(java.lang.String original); - public interface RangesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1IDRangeFluent>{ + + public interface RangesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1IDRangeFluent< + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent + .RangesNested< + N>> { public N and(); + public N endRange(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsGroupStrategyOptionsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsGroupStrategyOptionsFluentImpl.java index 29f197c788..f63f2b882f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsGroupStrategyOptionsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsGroupStrategyOptionsFluentImpl.java @@ -1,61 +1,131 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1beta1RunAsGroupStrategyOptionsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent{ - public V1beta1RunAsGroupStrategyOptionsFluentImpl() { - } - public V1beta1RunAsGroupStrategyOptionsFluentImpl(io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions instance) { +/** Generated */ +public class V1beta1RunAsGroupStrategyOptionsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent { + public V1beta1RunAsGroupStrategyOptionsFluentImpl() {} + + public V1beta1RunAsGroupStrategyOptionsFluentImpl( + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptions instance) { this.withRanges(instance.getRanges()); this.withRule(instance.getRule()); - } + private java.util.ArrayList ranges; private java.lang.String rule; - public A addToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").add(index >= 0 ? index : _visitables.get("ranges").size(), builder);this.ranges.add(index >= 0 ? index : ranges.size(), builder); return (A)this; + + public A addToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").add(index >= 0 ? index : _visitables.get("ranges").size(), builder); + this.ranges.add(index >= 0 ? index : ranges.size(), builder); + return (A) this; } - public A setToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); - if (index < 0 || index >= _visitables.get("ranges").size()) { _visitables.get("ranges").add(builder); } else { _visitables.get("ranges").set(index, builder);} - if (index < 0 || index >= ranges.size()) { ranges.add(builder); } else { ranges.set(index, builder);} - return (A)this; + + public A setToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + if (index < 0 || index >= _visitables.get("ranges").size()) { + _visitables.get("ranges").add(builder); + } else { + _visitables.get("ranges").set(index, builder); + } + if (index < 0 || index >= ranges.size()) { + ranges.add(builder); + } else { + ranges.set(index, builder); + } + return (A) this; } + public A addToRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").add(builder);this.ranges.add(builder);} return (A)this; + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").add(builder); + this.ranges.add(builder); + } + return (A) this; } - public A addAllToRanges(java.util.Collection items) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").add(builder);this.ranges.add(builder);} return (A)this; + + public A addAllToRanges( + java.util.Collection items) { + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").add(builder); + this.ranges.add(builder); + } + return (A) this; } + public A removeFromRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items) { - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").remove(builder);if (this.ranges != null) {this.ranges.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").remove(builder); + if (this.ranges != null) { + this.ranges.remove(builder); + } + } + return (A) this; } - public A removeAllFromRanges(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").remove(builder);if (this.ranges != null) {this.ranges.remove(builder);}} return (A)this; + + public A removeAllFromRanges( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").remove(builder); + if (this.ranges != null) { + this.ranges.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromRanges(java.util.function.Predicate predicate) { + + public A removeMatchingFromRanges( + java.util.function.Predicate + predicate) { if (ranges == null) return (A) this; - final Iterator each = ranges.iterator(); + final Iterator each = + ranges.iterator(); final List visitables = _visitables.get("ranges"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = each.next(); @@ -64,122 +134,205 @@ public A removeMatchingFromRanges(java.util.function.Predicate getRanges() { return ranges != null ? build(ranges) : null; } + public java.util.List buildRanges() { return ranges != null ? build(ranges) : null; } + public io.kubernetes.client.openapi.models.V1beta1IDRange buildRange(java.lang.Integer index) { return this.ranges.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1IDRange buildFirstRange() { return this.ranges.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1IDRange buildLastRange() { return this.ranges.get(ranges.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item: ranges) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item : ranges) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingRange(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item: ranges) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRange( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item : ranges) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withRanges(java.util.List ranges) { - if (this.ranges != null) { _visitables.get("ranges").removeAll(this.ranges);} - if (ranges != null) {this.ranges = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1IDRange item : ranges){this.addToRanges(item);}} else { this.ranges = null;} return (A) this; + if (this.ranges != null) { + _visitables.get("ranges").removeAll(this.ranges); + } + if (ranges != null) { + this.ranges = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : ranges) { + this.addToRanges(item); + } + } else { + this.ranges = null; + } + return (A) this; } + public A withRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... ranges) { - if (this.ranges != null) {this.ranges.clear();} - if (ranges != null) {for (io.kubernetes.client.openapi.models.V1beta1IDRange item :ranges){ this.addToRanges(item);}} return (A) this; + if (this.ranges != null) { + this.ranges.clear(); + } + if (ranges != null) { + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : ranges) { + this.addToRanges(item); + } + } + return (A) this; } + public java.lang.Boolean hasRanges() { return ranges != null && !ranges.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested addNewRange() { - return new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluentImpl.RangesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + addNewRange() { + return new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluentImpl + .RangesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item) { - return new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluentImpl.RangesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item) { + return new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluentImpl + .RangesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested setNewRangeLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { - return new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluentImpl.RangesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + setNewRangeLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { + return new io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluentImpl + .RangesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested editRange(java.lang.Integer index) { - if (ranges.size() <= index) throw new RuntimeException("Can't edit ranges. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + editRange(java.lang.Integer index) { + if (ranges.size() <= index) + throw new RuntimeException("Can't edit ranges. Index exceeds size."); return setNewRangeLike(index, buildRange(index)); } - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested editFirstRange() { - if (ranges.size() == 0) throw new RuntimeException("Can't edit first ranges. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + editFirstRange() { + if (ranges.size() == 0) + throw new RuntimeException("Can't edit first ranges. The list is empty."); return setNewRangeLike(0, buildRange(0)); } - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested editLastRange() { + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + editLastRange() { int index = ranges.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ranges. The list is empty."); return setNewRangeLike(index, buildRange(index)); } - public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested editMatchingRange(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested + editMatchingRange( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta1IDRangeFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested,io.kubernetes.client.fluent.Nested{ - RangesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { + + public class RangesNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1IDRangeFluentImpl< + io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent.RangesNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1RunAsGroupStrategyOptionsFluent + .RangesNested< + N>, + io.kubernetes.client.fluent.Nested { + RangesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(this, item); } + RangesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1RunAsGroupStrategyOptionsFluentImpl.this.setToRanges(index,builder.build()); + return (N) + V1beta1RunAsGroupStrategyOptionsFluentImpl.this.setToRanges(index, builder.build()); } + public N endRange() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsUserStrategyOptionsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsUserStrategyOptionsBuilder.java index 5ee60e05e3..beb5f0fbcc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsUserStrategyOptionsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsUserStrategyOptionsBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1RunAsUserStrategyOptionsBuilder extends io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1RunAsUserStrategyOptionsBuilder + extends io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions, + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsBuilder> { public V1beta1RunAsUserStrategyOptionsBuilder() { this(false); } + public V1beta1RunAsUserStrategyOptionsBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1RunAsUserStrategyOptions(), validationEnabled); } - public V1beta1RunAsUserStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent fluent) { + + public V1beta1RunAsUserStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent fluent) { this(fluent, false); } - public V1beta1RunAsUserStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1RunAsUserStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1RunAsUserStrategyOptions(), validationEnabled); } - public V1beta1RunAsUserStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions instance) { + + public V1beta1RunAsUserStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions instance) { this(fluent, instance, false); } - public V1beta1RunAsUserStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1RunAsUserStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withRanges(instance.getRanges()); fluent.withRule(instance.getRule()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1RunAsUserStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions instance) { - this(instance,false); + + public V1beta1RunAsUserStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions instance) { + this(instance, false); } - public V1beta1RunAsUserStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1RunAsUserStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withRanges(instance.getRanges()); this.withRule(instance.getRule()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions build() { V1beta1RunAsUserStrategyOptions buildable = new V1beta1RunAsUserStrategyOptions(); buildable.setRanges(fluent.getRanges()); buildable.setRule(fluent.getRule()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1RunAsUserStrategyOptionsBuilder that = (V1beta1RunAsUserStrategyOptionsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsUserStrategyOptionsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsUserStrategyOptionsFluent.java index 160fe4159d..ce3f70e336 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsUserStrategyOptionsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsUserStrategyOptionsFluent.java @@ -1,66 +1,113 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1RunAsUserStrategyOptionsFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item); - public A setToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item); +/** Generated */ +public interface V1beta1RunAsUserStrategyOptionsFluent< + A extends io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item); + + public A setToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item); + public A addToRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items); - public A addAllToRanges(java.util.Collection items); + + public A addAllToRanges( + java.util.Collection items); + public A removeFromRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items); - public A removeAllFromRanges(java.util.Collection items); - public A removeMatchingFromRanges(java.util.function.Predicate predicate); - + + public A removeAllFromRanges( + java.util.Collection items); + + public A removeMatchingFromRanges( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildRanges instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getRanges(); + public java.util.List buildRanges(); + public io.kubernetes.client.openapi.models.V1beta1IDRange buildRange(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1IDRange buildFirstRange(); + public io.kubernetes.client.openapi.models.V1beta1IDRange buildLastRange(); - public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRange(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingRange( + java.util.function.Predicate + predicate); + public A withRanges(java.util.List ranges); + public A withRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... ranges); + public java.lang.Boolean hasRanges(); - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested addNewRange(); - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item); - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested setNewRangeLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item); - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested editRange(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested editFirstRange(); - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested editLastRange(); - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested editMatchingRange(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + addNewRange(); + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item); + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + setNewRangeLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item); + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + editRange(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + editFirstRange(); + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + editLastRange(); + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + editMatchingRange( + java.util.function.Predicate + predicate); + public java.lang.String getRule(); + public A withRule(java.lang.String rule); + public java.lang.Boolean hasRule(); - - /** - * Method is deprecated. use withRule instead. - */ + + /** Method is deprecated. use withRule instead. */ @java.lang.Deprecated public A withNewRule(java.lang.String original); - public interface RangesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1IDRangeFluent>{ + + public interface RangesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1IDRangeFluent< + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent + .RangesNested< + N>> { public N and(); + public N endRange(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsUserStrategyOptionsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsUserStrategyOptionsFluentImpl.java index fcb6d93024..fcf2d99620 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsUserStrategyOptionsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RunAsUserStrategyOptionsFluentImpl.java @@ -1,61 +1,131 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1beta1RunAsUserStrategyOptionsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent{ - public V1beta1RunAsUserStrategyOptionsFluentImpl() { - } - public V1beta1RunAsUserStrategyOptionsFluentImpl(io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions instance) { +/** Generated */ +public class V1beta1RunAsUserStrategyOptionsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent { + public V1beta1RunAsUserStrategyOptionsFluentImpl() {} + + public V1beta1RunAsUserStrategyOptionsFluentImpl( + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptions instance) { this.withRanges(instance.getRanges()); this.withRule(instance.getRule()); - } + private java.util.ArrayList ranges; private java.lang.String rule; - public A addToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").add(index >= 0 ? index : _visitables.get("ranges").size(), builder);this.ranges.add(index >= 0 ? index : ranges.size(), builder); return (A)this; + + public A addToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").add(index >= 0 ? index : _visitables.get("ranges").size(), builder); + this.ranges.add(index >= 0 ? index : ranges.size(), builder); + return (A) this; } - public A setToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); - if (index < 0 || index >= _visitables.get("ranges").size()) { _visitables.get("ranges").add(builder); } else { _visitables.get("ranges").set(index, builder);} - if (index < 0 || index >= ranges.size()) { ranges.add(builder); } else { ranges.set(index, builder);} - return (A)this; + + public A setToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + if (index < 0 || index >= _visitables.get("ranges").size()) { + _visitables.get("ranges").add(builder); + } else { + _visitables.get("ranges").set(index, builder); + } + if (index < 0 || index >= ranges.size()) { + ranges.add(builder); + } else { + ranges.set(index, builder); + } + return (A) this; } + public A addToRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").add(builder);this.ranges.add(builder);} return (A)this; + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").add(builder); + this.ranges.add(builder); + } + return (A) this; } - public A addAllToRanges(java.util.Collection items) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").add(builder);this.ranges.add(builder);} return (A)this; + + public A addAllToRanges( + java.util.Collection items) { + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").add(builder); + this.ranges.add(builder); + } + return (A) this; } + public A removeFromRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items) { - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").remove(builder);if (this.ranges != null) {this.ranges.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").remove(builder); + if (this.ranges != null) { + this.ranges.remove(builder); + } + } + return (A) this; } - public A removeAllFromRanges(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").remove(builder);if (this.ranges != null) {this.ranges.remove(builder);}} return (A)this; + + public A removeAllFromRanges( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").remove(builder); + if (this.ranges != null) { + this.ranges.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromRanges(java.util.function.Predicate predicate) { + + public A removeMatchingFromRanges( + java.util.function.Predicate + predicate) { if (ranges == null) return (A) this; - final Iterator each = ranges.iterator(); + final Iterator each = + ranges.iterator(); final List visitables = _visitables.get("ranges"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = each.next(); @@ -64,122 +134,202 @@ public A removeMatchingFromRanges(java.util.function.Predicate getRanges() { return ranges != null ? build(ranges) : null; } + public java.util.List buildRanges() { return ranges != null ? build(ranges) : null; } + public io.kubernetes.client.openapi.models.V1beta1IDRange buildRange(java.lang.Integer index) { return this.ranges.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1IDRange buildFirstRange() { return this.ranges.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1IDRange buildLastRange() { return this.ranges.get(ranges.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item: ranges) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item : ranges) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingRange(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item: ranges) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRange( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item : ranges) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withRanges(java.util.List ranges) { - if (this.ranges != null) { _visitables.get("ranges").removeAll(this.ranges);} - if (ranges != null) {this.ranges = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1IDRange item : ranges){this.addToRanges(item);}} else { this.ranges = null;} return (A) this; + if (this.ranges != null) { + _visitables.get("ranges").removeAll(this.ranges); + } + if (ranges != null) { + this.ranges = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : ranges) { + this.addToRanges(item); + } + } else { + this.ranges = null; + } + return (A) this; } + public A withRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... ranges) { - if (this.ranges != null) {this.ranges.clear();} - if (ranges != null) {for (io.kubernetes.client.openapi.models.V1beta1IDRange item :ranges){ this.addToRanges(item);}} return (A) this; + if (this.ranges != null) { + this.ranges.clear(); + } + if (ranges != null) { + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : ranges) { + this.addToRanges(item); + } + } + return (A) this; } + public java.lang.Boolean hasRanges() { return ranges != null && !ranges.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested addNewRange() { - return new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluentImpl.RangesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + addNewRange() { + return new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluentImpl + .RangesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item) { - return new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluentImpl.RangesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item) { + return new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluentImpl + .RangesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested setNewRangeLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { - return new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluentImpl.RangesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + setNewRangeLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { + return new io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluentImpl + .RangesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested editRange(java.lang.Integer index) { - if (ranges.size() <= index) throw new RuntimeException("Can't edit ranges. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + editRange(java.lang.Integer index) { + if (ranges.size() <= index) + throw new RuntimeException("Can't edit ranges. Index exceeds size."); return setNewRangeLike(index, buildRange(index)); } - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested editFirstRange() { - if (ranges.size() == 0) throw new RuntimeException("Can't edit first ranges. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + editFirstRange() { + if (ranges.size() == 0) + throw new RuntimeException("Can't edit first ranges. The list is empty."); return setNewRangeLike(0, buildRange(0)); } - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested editLastRange() { + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + editLastRange() { int index = ranges.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ranges. The list is empty."); return setNewRangeLike(index, buildRange(index)); } - public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested editMatchingRange(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested + editMatchingRange( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta1IDRangeFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested,io.kubernetes.client.fluent.Nested{ - RangesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { + + public class RangesNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1IDRangeFluentImpl< + io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent.RangesNested> + implements io.kubernetes.client.openapi.models.V1beta1RunAsUserStrategyOptionsFluent + .RangesNested< + N>, + io.kubernetes.client.fluent.Nested { + RangesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(this, item); } + RangesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1RunAsUserStrategyOptionsFluentImpl.this.setToRanges(index,builder.build()); + return (N) V1beta1RunAsUserStrategyOptionsFluentImpl.this.setToRanges(index, builder.build()); } + public N endRange() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassBuilder.java index 2d943acfc1..87a6fbd46c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1RuntimeClassBuilder extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1RuntimeClassBuilder + extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1RuntimeClass, + io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder> { public V1beta1RuntimeClassBuilder() { this(false); } + public V1beta1RuntimeClassBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1RuntimeClass(), validationEnabled); } - public V1beta1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent fluent) { + + public V1beta1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent fluent) { this(fluent, false); } - public V1beta1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1RuntimeClass(), validationEnabled); } - public V1beta1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent fluent,io.kubernetes.client.openapi.models.V1beta1RuntimeClass instance) { + + public V1beta1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent fluent, + io.kubernetes.client.openapi.models.V1beta1RuntimeClass instance) { this(fluent, instance, false); } - public V1beta1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent fluent,io.kubernetes.client.openapi.models.V1beta1RuntimeClass instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent fluent, + io.kubernetes.client.openapi.models.V1beta1RuntimeClass instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withHandler(instance.getHandler()); @@ -33,13 +60,18 @@ public V1beta1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1beta1Run fluent.withScheduling(instance.getScheduling()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClass instance) { - this(instance,false); + + public V1beta1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClass instance) { + this(instance, false); } - public V1beta1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClass instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1RuntimeClassBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClass instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withHandler(instance.getHandler()); @@ -52,10 +84,12 @@ public V1beta1RuntimeClassBuilder(io.kubernetes.client.openapi.models.V1beta1Run this.withScheduling(instance.getScheduling()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1RuntimeClass build() { V1beta1RuntimeClass buildable = new V1beta1RuntimeClass(); buildable.setApiVersion(fluent.getApiVersion()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V1beta1RuntimeClass build() { buildable.setScheduling(fluent.getScheduling()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1RuntimeClassBuilder that = (V1beta1RuntimeClassBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassFluent.java index 20253d1e9b..2694648a06 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassFluent.java @@ -1,102 +1,162 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1RuntimeClassFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1RuntimeClassFluent< + A extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getHandler(); + public A withHandler(java.lang.String handler); + public java.lang.Boolean hasHandler(); - - /** - * Method is deprecated. use withHandler instead. - */ + + /** Method is deprecated. use withHandler instead. */ @java.lang.Deprecated public A withNewHandler(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildOverhead instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1Overhead getOverhead(); + public io.kubernetes.client.openapi.models.V1beta1Overhead buildOverhead(); + public A withOverhead(io.kubernetes.client.openapi.models.V1beta1Overhead overhead); + public java.lang.Boolean hasOverhead(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested withNewOverhead(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested withNewOverheadLike(io.kubernetes.client.openapi.models.V1beta1Overhead item); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested editOverhead(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested editOrNewOverhead(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested editOrNewOverheadLike(io.kubernetes.client.openapi.models.V1beta1Overhead item); - + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested + withNewOverhead(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested + withNewOverheadLike(io.kubernetes.client.openapi.models.V1beta1Overhead item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested + editOverhead(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested + editOrNewOverhead(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested + editOrNewOverheadLike(io.kubernetes.client.openapi.models.V1beta1Overhead item); + /** * This method has been deprecated, please use method buildScheduling instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1Scheduling getScheduling(); + public io.kubernetes.client.openapi.models.V1beta1Scheduling buildScheduling(); + public A withScheduling(io.kubernetes.client.openapi.models.V1beta1Scheduling scheduling); + public java.lang.Boolean hasScheduling(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested withNewScheduling(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested withNewSchedulingLike(io.kubernetes.client.openapi.models.V1beta1Scheduling item); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested editScheduling(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested editOrNewScheduling(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested editOrNewSchedulingLike(io.kubernetes.client.openapi.models.V1beta1Scheduling item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested + withNewScheduling(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested + withNewSchedulingLike(io.kubernetes.client.openapi.models.V1beta1Scheduling item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested + editScheduling(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested + editOrNewScheduling(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested + editOrNewSchedulingLike(io.kubernetes.client.openapi.models.V1beta1Scheduling item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface OverheadNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1OverheadFluent>{ + + public interface OverheadNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1OverheadFluent< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested> { public N and(); + public N endOverhead(); - } - public interface SchedulingNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1SchedulingFluent>{ + + public interface SchedulingNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1SchedulingFluent< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested> { public N and(); + public N endScheduling(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassFluentImpl.java index 524415e7f2..6bc6b97c86 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1RuntimeClassFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent { + public V1beta1RuntimeClassFluentImpl() {} - /** - * Generated - */ -public class V1beta1RuntimeClassFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent{ - public V1beta1RuntimeClassFluentImpl() { - } - public V1beta1RuntimeClassFluentImpl(io.kubernetes.client.openapi.models.V1beta1RuntimeClass instance) { + public V1beta1RuntimeClassFluentImpl( + io.kubernetes.client.openapi.models.V1beta1RuntimeClass instance) { this.withApiVersion(instance.getApiVersion()); this.withHandler(instance.getHandler()); @@ -25,229 +32,333 @@ public V1beta1RuntimeClassFluentImpl(io.kubernetes.client.openapi.models.V1beta1 this.withOverhead(instance.getOverhead()); this.withScheduling(instance.getScheduling()); - } + private java.lang.String apiVersion; private java.lang.String handler; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1beta1OverheadBuilder overhead; private io.kubernetes.client.openapi.models.V1beta1SchedulingBuilder scheduling; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getHandler() { return this.handler; } + public A withHandler(java.lang.String handler) { - this.handler=handler; return (A) this; + this.handler = handler; + return (A) this; } + public java.lang.Boolean hasHandler() { return this.handler != null; } - - /** - * Method is deprecated. use withHandler instead. - */ + + /** Method is deprecated. use withHandler instead. */ @java.lang.Deprecated public A withNewHandler(java.lang.String original) { - return (A)withHandler(new String(original)); + return (A) withHandler(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildOverhead instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1Overhead getOverhead() { - return this.overhead!=null ?this.overhead.build():null; + return this.overhead != null ? this.overhead.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1Overhead buildOverhead() { - return this.overhead!=null ?this.overhead.build():null; + return this.overhead != null ? this.overhead.build() : null; } + public A withOverhead(io.kubernetes.client.openapi.models.V1beta1Overhead overhead) { _visitables.get("overhead").remove(this.overhead); - if (overhead!=null){ this.overhead= new io.kubernetes.client.openapi.models.V1beta1OverheadBuilder(overhead); _visitables.get("overhead").add(this.overhead);} return (A) this; + if (overhead != null) { + this.overhead = new io.kubernetes.client.openapi.models.V1beta1OverheadBuilder(overhead); + _visitables.get("overhead").add(this.overhead); + } + return (A) this; } + public java.lang.Boolean hasOverhead() { return this.overhead != null; } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested withNewOverhead() { - return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl.OverheadNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested + withNewOverhead() { + return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl + .OverheadNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested withNewOverheadLike(io.kubernetes.client.openapi.models.V1beta1Overhead item) { - return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl.OverheadNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested + withNewOverheadLike(io.kubernetes.client.openapi.models.V1beta1Overhead item) { + return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl.OverheadNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested editOverhead() { + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested + editOverhead() { return withNewOverheadLike(getOverhead()); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested editOrNewOverhead() { - return withNewOverheadLike(getOverhead() != null ? getOverhead(): new io.kubernetes.client.openapi.models.V1beta1OverheadBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested + editOrNewOverhead() { + return withNewOverheadLike( + getOverhead() != null + ? getOverhead() + : new io.kubernetes.client.openapi.models.V1beta1OverheadBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested editOrNewOverheadLike(io.kubernetes.client.openapi.models.V1beta1Overhead item) { - return withNewOverheadLike(getOverhead() != null ? getOverhead(): item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested + editOrNewOverheadLike(io.kubernetes.client.openapi.models.V1beta1Overhead item) { + return withNewOverheadLike(getOverhead() != null ? getOverhead() : item); } - + /** * This method has been deprecated, please use method buildScheduling instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1Scheduling getScheduling() { - return this.scheduling!=null ?this.scheduling.build():null; + return this.scheduling != null ? this.scheduling.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1Scheduling buildScheduling() { - return this.scheduling!=null ?this.scheduling.build():null; + return this.scheduling != null ? this.scheduling.build() : null; } + public A withScheduling(io.kubernetes.client.openapi.models.V1beta1Scheduling scheduling) { _visitables.get("scheduling").remove(this.scheduling); - if (scheduling!=null){ this.scheduling= new io.kubernetes.client.openapi.models.V1beta1SchedulingBuilder(scheduling); _visitables.get("scheduling").add(this.scheduling);} return (A) this; + if (scheduling != null) { + this.scheduling = + new io.kubernetes.client.openapi.models.V1beta1SchedulingBuilder(scheduling); + _visitables.get("scheduling").add(this.scheduling); + } + return (A) this; } + public java.lang.Boolean hasScheduling() { return this.scheduling != null; } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested withNewScheduling() { - return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl.SchedulingNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested + withNewScheduling() { + return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl + .SchedulingNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested withNewSchedulingLike(io.kubernetes.client.openapi.models.V1beta1Scheduling item) { - return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl.SchedulingNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested + withNewSchedulingLike(io.kubernetes.client.openapi.models.V1beta1Scheduling item) { + return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl + .SchedulingNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested editScheduling() { + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested + editScheduling() { return withNewSchedulingLike(getScheduling()); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested editOrNewScheduling() { - return withNewSchedulingLike(getScheduling() != null ? getScheduling(): new io.kubernetes.client.openapi.models.V1beta1SchedulingBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested + editOrNewScheduling() { + return withNewSchedulingLike( + getScheduling() != null + ? getScheduling() + : new io.kubernetes.client.openapi.models.V1beta1SchedulingBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested editOrNewSchedulingLike(io.kubernetes.client.openapi.models.V1beta1Scheduling item) { - return withNewSchedulingLike(getScheduling() != null ? getScheduling(): item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested + editOrNewSchedulingLike(io.kubernetes.client.openapi.models.V1beta1Scheduling item) { + return withNewSchedulingLike(getScheduling() != null ? getScheduling() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1RuntimeClassFluentImpl that = (V1beta1RuntimeClassFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (handler != null ? !handler.equals(that.handler) :that.handler != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (overhead != null ? !overhead.equals(that.overhead) :that.overhead != null) return false; - if (scheduling != null ? !scheduling.equals(that.scheduling) :that.scheduling != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (handler != null ? !handler.equals(that.handler) : that.handler != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (overhead != null ? !overhead.equals(that.overhead) : that.overhead != null) return false; + if (scheduling != null ? !scheduling.equals(that.scheduling) : that.scheduling != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, handler, kind, metadata, overhead, scheduling, super.hashCode()); + return java.util.Objects.hash( + apiVersion, handler, kind, metadata, overhead, scheduling, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1beta1RuntimeClassFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class OverheadNestedImpl extends io.kubernetes.client.openapi.models.V1beta1OverheadFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested,io.kubernetes.client.fluent.Nested{ + + public class OverheadNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1OverheadFluentImpl< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested> + implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.OverheadNested, + io.kubernetes.client.fluent.Nested { OverheadNestedImpl(io.kubernetes.client.openapi.models.V1beta1Overhead item) { this.builder = new io.kubernetes.client.openapi.models.V1beta1OverheadBuilder(this, item); } + OverheadNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta1OverheadBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1OverheadBuilder builder; + public N and() { return (N) V1beta1RuntimeClassFluentImpl.this.withOverhead(builder.build()); } + public N endOverhead() { return and(); } - } - public class SchedulingNestedImpl extends io.kubernetes.client.openapi.models.V1beta1SchedulingFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested,io.kubernetes.client.fluent.Nested{ + + public class SchedulingNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1SchedulingFluentImpl< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested> + implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent.SchedulingNested, + io.kubernetes.client.fluent.Nested { SchedulingNestedImpl(io.kubernetes.client.openapi.models.V1beta1Scheduling item) { this.builder = new io.kubernetes.client.openapi.models.V1beta1SchedulingBuilder(this, item); } + SchedulingNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta1SchedulingBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1SchedulingBuilder builder; + public N and() { return (N) V1beta1RuntimeClassFluentImpl.this.withScheduling(builder.build()); } + public N endScheduling() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassListBuilder.java index d6c4688f4c..d195881b75 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1RuntimeClassListBuilder extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1RuntimeClassListBuilder + extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluentImpl< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassList, + io.kubernetes.client.openapi.models.V1beta1RuntimeClassListBuilder> { public V1beta1RuntimeClassListBuilder() { this(false); } + public V1beta1RuntimeClassListBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1RuntimeClassList(), validationEnabled); } - public V1beta1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent fluent) { + + public V1beta1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent fluent) { this(fluent, false); } - public V1beta1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1RuntimeClassList(), validationEnabled); } - public V1beta1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent fluent,io.kubernetes.client.openapi.models.V1beta1RuntimeClassList instance) { + + public V1beta1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1RuntimeClassList instance) { this(fluent, instance, false); } - public V1beta1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent fluent,io.kubernetes.client.openapi.models.V1beta1RuntimeClassList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent fluent, + io.kubernetes.client.openapi.models.V1beta1RuntimeClassList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1beta1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1beta fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassList instance) { - this(instance,false); + + public V1beta1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassList instance) { + this(instance, false); } - public V1beta1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1RuntimeClassListBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1beta1RuntimeClassListBuilder(io.kubernetes.client.openapi.models.V1beta this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassList build() { V1beta1RuntimeClassList buildable = new V1beta1RuntimeClassList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1beta1RuntimeClassList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1RuntimeClassListBuilder that = (V1beta1RuntimeClassListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassListFluent.java index 9ec2b5b4cf..f2be09ff2d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassListFluent.java @@ -1,95 +1,160 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1RuntimeClassListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1RuntimeClassListFluent< + A extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1RuntimeClass item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1RuntimeClass item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1RuntimeClass item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1RuntimeClass item); + public A addToItems(io.kubernetes.client.openapi.models.V1beta1RuntimeClass... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1RuntimeClass... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1beta1RuntimeClass buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1RuntimeClass buildFirstItem(); + public io.kubernetes.client.openapi.models.V1beta1RuntimeClass buildLastItem(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClass buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClass buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1beta1RuntimeClass... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1RuntimeClass item); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1RuntimeClass item); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1RuntimeClass item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1RuntimeClass item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluent< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassListFluentImpl.java index 84edf10218..dc969a8135 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta1RuntimeClassListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent{ - public V1beta1RuntimeClassListFluentImpl() { - } - public V1beta1RuntimeClassListFluentImpl(io.kubernetes.client.openapi.models.V1beta1RuntimeClassList instance) { + +/** Generated */ +public class V1beta1RuntimeClassListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent { + public V1beta1RuntimeClassListFluentImpl() {} + + public V1beta1RuntimeClassListFluentImpl( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1beta1RuntimeClassListFluentImpl(io.kubernetes.client.openapi.models.V1b this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1RuntimeClass item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1RuntimeClass item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1RuntimeClass item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1RuntimeClass item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1beta1RuntimeClass... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1RuntimeClass item : items) {io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1RuntimeClass item : items) { + io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1RuntimeClass item : items) {io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1RuntimeClass item : items) { + io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta1RuntimeClass... items) { - for (io.kubernetes.client.openapi.models.V1beta1RuntimeClass item : items) {io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1RuntimeClass item : items) { + io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1RuntimeClass item : items) {io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder = new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1RuntimeClass item : items) { + io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder = each.next(); @@ -87,174 +159,286 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClass buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClass buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1RuntimeClass buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1RuntimeClass buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClass buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClass buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1RuntimeClass item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1RuntimeClass item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1beta1RuntimeClass... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1beta1RuntimeClass item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1beta1RuntimeClass item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta1RuntimeClass item) { - return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta1RuntimeClass item) { + return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1RuntimeClass item) { - return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1RuntimeClass item) { + return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1RuntimeClassListFluentImpl that = (V1beta1RuntimeClassListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1RuntimeClass item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassFluentImpl< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1RuntimeClass item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1RuntimeClassBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1RuntimeClassListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1beta1RuntimeClassListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassListFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1beta1RuntimeClassListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassStrategyOptionsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassStrategyOptionsBuilder.java index 4ce94688c1..9bb2f5be1a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassStrategyOptionsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassStrategyOptionsBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1RuntimeClassStrategyOptionsBuilder extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1RuntimeClassStrategyOptionsBuilder + extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions, + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsBuilder> { public V1beta1RuntimeClassStrategyOptionsBuilder() { this(false); } + public V1beta1RuntimeClassStrategyOptionsBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1RuntimeClassStrategyOptions(), validationEnabled); } - public V1beta1RuntimeClassStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent fluent) { + + public V1beta1RuntimeClassStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent fluent) { this(fluent, false); } - public V1beta1RuntimeClassStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1RuntimeClassStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1RuntimeClassStrategyOptions(), validationEnabled); } - public V1beta1RuntimeClassStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions instance) { + + public V1beta1RuntimeClassStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions instance) { this(fluent, instance, false); } - public V1beta1RuntimeClassStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1RuntimeClassStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAllowedRuntimeClassNames(instance.getAllowedRuntimeClassNames()); fluent.withDefaultRuntimeClassName(instance.getDefaultRuntimeClassName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1RuntimeClassStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions instance) { - this(instance,false); + + public V1beta1RuntimeClassStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions instance) { + this(instance, false); } - public V1beta1RuntimeClassStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1RuntimeClassStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAllowedRuntimeClassNames(instance.getAllowedRuntimeClassNames()); this.withDefaultRuntimeClassName(instance.getDefaultRuntimeClassName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions build() { V1beta1RuntimeClassStrategyOptions buildable = new V1beta1RuntimeClassStrategyOptions(); buildable.setAllowedRuntimeClassNames(fluent.getAllowedRuntimeClassNames()); buildable.setDefaultRuntimeClassName(fluent.getDefaultRuntimeClassName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1RuntimeClassStrategyOptionsBuilder that = (V1beta1RuntimeClassStrategyOptionsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassStrategyOptionsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassStrategyOptionsFluent.java index 34190d4f90..defadcfb49 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassStrategyOptionsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassStrategyOptionsFluent.java @@ -1,44 +1,62 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1beta1RuntimeClassStrategyOptionsFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToAllowedRuntimeClassNames(java.lang.Integer index,java.lang.String item); - public A setToAllowedRuntimeClassNames(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1beta1RuntimeClassStrategyOptionsFluent< + A extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToAllowedRuntimeClassNames(java.lang.Integer index, java.lang.String item); + + public A setToAllowedRuntimeClassNames(java.lang.Integer index, java.lang.String item); + public A addToAllowedRuntimeClassNames(java.lang.String... items); + public A addAllToAllowedRuntimeClassNames(java.util.Collection items); + public A removeFromAllowedRuntimeClassNames(java.lang.String... items); + public A removeAllFromAllowedRuntimeClassNames(java.util.Collection items); + public java.util.List getAllowedRuntimeClassNames(); + public java.lang.String getAllowedRuntimeClassName(java.lang.Integer index); + public java.lang.String getFirstAllowedRuntimeClassName(); + public java.lang.String getLastAllowedRuntimeClassName(); - public java.lang.String getMatchingAllowedRuntimeClassName(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingAllowedRuntimeClassName(java.util.function.Predicate predicate); + + public java.lang.String getMatchingAllowedRuntimeClassName( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingAllowedRuntimeClassName( + java.util.function.Predicate predicate); + public A withAllowedRuntimeClassNames(java.util.List allowedRuntimeClassNames); + public A withAllowedRuntimeClassNames(java.lang.String... allowedRuntimeClassNames); + public java.lang.Boolean hasAllowedRuntimeClassNames(); + public A addNewAllowedRuntimeClassName(java.lang.String original); + public java.lang.String getDefaultRuntimeClassName(); + public A withDefaultRuntimeClassName(java.lang.String defaultRuntimeClassName); + public java.lang.Boolean hasDefaultRuntimeClassName(); - - /** - * Method is deprecated. use withDefaultRuntimeClassName instead. - */ + + /** Method is deprecated. use withDefaultRuntimeClassName instead. */ @java.lang.Deprecated public A withNewDefaultRuntimeClassName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassStrategyOptionsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassStrategyOptionsFluentImpl.java index f4ee241210..39e49f61b0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassStrategyOptionsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1RuntimeClassStrategyOptionsFluentImpl.java @@ -1,111 +1,191 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta1RuntimeClassStrategyOptionsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent{ - public V1beta1RuntimeClassStrategyOptionsFluentImpl() { - } - public V1beta1RuntimeClassStrategyOptionsFluentImpl(io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions instance) { +/** Generated */ +public class V1beta1RuntimeClassStrategyOptionsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptionsFluent { + public V1beta1RuntimeClassStrategyOptionsFluentImpl() {} + + public V1beta1RuntimeClassStrategyOptionsFluentImpl( + io.kubernetes.client.openapi.models.V1beta1RuntimeClassStrategyOptions instance) { this.withAllowedRuntimeClassNames(instance.getAllowedRuntimeClassNames()); this.withDefaultRuntimeClassName(instance.getDefaultRuntimeClassName()); - } + private java.util.List allowedRuntimeClassNames; private java.lang.String defaultRuntimeClassName; - public A addToAllowedRuntimeClassNames(java.lang.Integer index,java.lang.String item) { - if (this.allowedRuntimeClassNames == null) {this.allowedRuntimeClassNames = new java.util.ArrayList();} + + public A addToAllowedRuntimeClassNames(java.lang.Integer index, java.lang.String item) { + if (this.allowedRuntimeClassNames == null) { + this.allowedRuntimeClassNames = new java.util.ArrayList(); + } this.allowedRuntimeClassNames.add(index, item); - return (A)this; + return (A) this; } - public A setToAllowedRuntimeClassNames(java.lang.Integer index,java.lang.String item) { - if (this.allowedRuntimeClassNames == null) {this.allowedRuntimeClassNames = new java.util.ArrayList();} - this.allowedRuntimeClassNames.set(index, item); return (A)this; + + public A setToAllowedRuntimeClassNames(java.lang.Integer index, java.lang.String item) { + if (this.allowedRuntimeClassNames == null) { + this.allowedRuntimeClassNames = new java.util.ArrayList(); + } + this.allowedRuntimeClassNames.set(index, item); + return (A) this; } + public A addToAllowedRuntimeClassNames(java.lang.String... items) { - if (this.allowedRuntimeClassNames == null) {this.allowedRuntimeClassNames = new java.util.ArrayList();} - for (java.lang.String item : items) {this.allowedRuntimeClassNames.add(item);} return (A)this; + if (this.allowedRuntimeClassNames == null) { + this.allowedRuntimeClassNames = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.allowedRuntimeClassNames.add(item); + } + return (A) this; } + public A addAllToAllowedRuntimeClassNames(java.util.Collection items) { - if (this.allowedRuntimeClassNames == null) {this.allowedRuntimeClassNames = new java.util.ArrayList();} - for (java.lang.String item : items) {this.allowedRuntimeClassNames.add(item);} return (A)this; + if (this.allowedRuntimeClassNames == null) { + this.allowedRuntimeClassNames = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.allowedRuntimeClassNames.add(item); + } + return (A) this; } + public A removeFromAllowedRuntimeClassNames(java.lang.String... items) { - for (java.lang.String item : items) {if (this.allowedRuntimeClassNames!= null){ this.allowedRuntimeClassNames.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.allowedRuntimeClassNames != null) { + this.allowedRuntimeClassNames.remove(item); + } + } + return (A) this; } + public A removeAllFromAllowedRuntimeClassNames(java.util.Collection items) { - for (java.lang.String item : items) {if (this.allowedRuntimeClassNames!= null){ this.allowedRuntimeClassNames.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.allowedRuntimeClassNames != null) { + this.allowedRuntimeClassNames.remove(item); + } + } + return (A) this; } + public java.util.List getAllowedRuntimeClassNames() { return this.allowedRuntimeClassNames; } + public java.lang.String getAllowedRuntimeClassName(java.lang.Integer index) { return this.allowedRuntimeClassNames.get(index); } + public java.lang.String getFirstAllowedRuntimeClassName() { return this.allowedRuntimeClassNames.get(0); } + public java.lang.String getLastAllowedRuntimeClassName() { return this.allowedRuntimeClassNames.get(allowedRuntimeClassNames.size() - 1); } - public java.lang.String getMatchingAllowedRuntimeClassName(java.util.function.Predicate predicate) { - for (java.lang.String item: allowedRuntimeClassNames) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingAllowedRuntimeClassName( + java.util.function.Predicate predicate) { + for (java.lang.String item : allowedRuntimeClassNames) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingAllowedRuntimeClassName(java.util.function.Predicate predicate) { - for (java.lang.String item: allowedRuntimeClassNames) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingAllowedRuntimeClassName( + java.util.function.Predicate predicate) { + for (java.lang.String item : allowedRuntimeClassNames) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withAllowedRuntimeClassNames(java.util.List allowedRuntimeClassNames) { - if (allowedRuntimeClassNames != null) {this.allowedRuntimeClassNames = new java.util.ArrayList(); for (java.lang.String item : allowedRuntimeClassNames){this.addToAllowedRuntimeClassNames(item);}} else { this.allowedRuntimeClassNames = null;} return (A) this; + if (allowedRuntimeClassNames != null) { + this.allowedRuntimeClassNames = new java.util.ArrayList(); + for (java.lang.String item : allowedRuntimeClassNames) { + this.addToAllowedRuntimeClassNames(item); + } + } else { + this.allowedRuntimeClassNames = null; + } + return (A) this; } + public A withAllowedRuntimeClassNames(java.lang.String... allowedRuntimeClassNames) { - if (this.allowedRuntimeClassNames != null) {this.allowedRuntimeClassNames.clear();} - if (allowedRuntimeClassNames != null) {for (java.lang.String item :allowedRuntimeClassNames){ this.addToAllowedRuntimeClassNames(item);}} return (A) this; + if (this.allowedRuntimeClassNames != null) { + this.allowedRuntimeClassNames.clear(); + } + if (allowedRuntimeClassNames != null) { + for (java.lang.String item : allowedRuntimeClassNames) { + this.addToAllowedRuntimeClassNames(item); + } + } + return (A) this; } + public java.lang.Boolean hasAllowedRuntimeClassNames() { return allowedRuntimeClassNames != null && !allowedRuntimeClassNames.isEmpty(); } + public A addNewAllowedRuntimeClassName(java.lang.String original) { - return (A)addToAllowedRuntimeClassNames(new String(original)); + return (A) addToAllowedRuntimeClassNames(new String(original)); } + public java.lang.String getDefaultRuntimeClassName() { return this.defaultRuntimeClassName; } + public A withDefaultRuntimeClassName(java.lang.String defaultRuntimeClassName) { - this.defaultRuntimeClassName=defaultRuntimeClassName; return (A) this; + this.defaultRuntimeClassName = defaultRuntimeClassName; + return (A) this; } + public java.lang.Boolean hasDefaultRuntimeClassName() { return this.defaultRuntimeClassName != null; } - - /** - * Method is deprecated. use withDefaultRuntimeClassName instead. - */ + + /** Method is deprecated. use withDefaultRuntimeClassName instead. */ @java.lang.Deprecated public A withNewDefaultRuntimeClassName(java.lang.String original) { - return (A)withDefaultRuntimeClassName(new String(original)); + return (A) withDefaultRuntimeClassName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta1RuntimeClassStrategyOptionsFluentImpl that = (V1beta1RuntimeClassStrategyOptionsFluentImpl) o; - if (allowedRuntimeClassNames != null ? !allowedRuntimeClassNames.equals(that.allowedRuntimeClassNames) :that.allowedRuntimeClassNames != null) return false; - if (defaultRuntimeClassName != null ? !defaultRuntimeClassName.equals(that.defaultRuntimeClassName) :that.defaultRuntimeClassName != null) return false; + V1beta1RuntimeClassStrategyOptionsFluentImpl that = + (V1beta1RuntimeClassStrategyOptionsFluentImpl) o; + if (allowedRuntimeClassNames != null + ? !allowedRuntimeClassNames.equals(that.allowedRuntimeClassNames) + : that.allowedRuntimeClassNames != null) return false; + if (defaultRuntimeClassName != null + ? !defaultRuntimeClassName.equals(that.defaultRuntimeClassName) + : that.defaultRuntimeClassName != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(allowedRuntimeClassNames, defaultRuntimeClassName, super.hashCode()); + return java.util.Objects.hash( + allowedRuntimeClassNames, defaultRuntimeClassName, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SELinuxStrategyOptionsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SELinuxStrategyOptionsBuilder.java index 089aee734b..9ea0003574 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SELinuxStrategyOptionsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SELinuxStrategyOptionsBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1SELinuxStrategyOptionsBuilder extends io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1SELinuxStrategyOptionsBuilder + extends io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions, + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsBuilder> { public V1beta1SELinuxStrategyOptionsBuilder() { this(false); } + public V1beta1SELinuxStrategyOptionsBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1SELinuxStrategyOptions(), validationEnabled); } - public V1beta1SELinuxStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent fluent) { + + public V1beta1SELinuxStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent fluent) { this(fluent, false); } - public V1beta1SELinuxStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1SELinuxStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1SELinuxStrategyOptions(), validationEnabled); } - public V1beta1SELinuxStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions instance) { + + public V1beta1SELinuxStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions instance) { this(fluent, instance, false); } - public V1beta1SELinuxStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1SELinuxStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withRule(instance.getRule()); fluent.withSeLinuxOptions(instance.getSeLinuxOptions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1SELinuxStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions instance) { - this(instance,false); + + public V1beta1SELinuxStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions instance) { + this(instance, false); } - public V1beta1SELinuxStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1SELinuxStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withRule(instance.getRule()); this.withSeLinuxOptions(instance.getSeLinuxOptions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions build() { V1beta1SELinuxStrategyOptions buildable = new V1beta1SELinuxStrategyOptions(); buildable.setRule(fluent.getRule()); buildable.setSeLinuxOptions(fluent.getSeLinuxOptions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1SELinuxStrategyOptionsBuilder that = (V1beta1SELinuxStrategyOptionsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SELinuxStrategyOptionsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SELinuxStrategyOptionsFluent.java index 27d79cdf01..02b9e720fc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SELinuxStrategyOptionsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SELinuxStrategyOptionsFluent.java @@ -1,44 +1,78 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1SELinuxStrategyOptionsFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1SELinuxStrategyOptionsFluent< + A extends io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getRule(); + public A withRule(java.lang.String rule); + public java.lang.Boolean hasRule(); - - /** - * Method is deprecated. use withRule instead. - */ + + /** Method is deprecated. use withRule instead. */ @java.lang.Deprecated public A withNewRule(java.lang.String original); - + /** * This method has been deprecated, please use method buildSeLinuxOptions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SELinuxOptions getSeLinuxOptions(); + public io.kubernetes.client.openapi.models.V1SELinuxOptions buildSeLinuxOptions(); + public A withSeLinuxOptions(io.kubernetes.client.openapi.models.V1SELinuxOptions seLinuxOptions); + public java.lang.Boolean hasSeLinuxOptions(); - public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent.SeLinuxOptionsNested withNewSeLinuxOptions(); - public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent.SeLinuxOptionsNested withNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item); - public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent.SeLinuxOptionsNested editSeLinuxOptions(); - public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent.SeLinuxOptionsNested editOrNewSeLinuxOptions(); - public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent.SeLinuxOptionsNested editOrNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item); - public interface SeLinuxOptionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent + .SeLinuxOptionsNested< + A> + withNewSeLinuxOptions(); + + public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent + .SeLinuxOptionsNested< + A> + withNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item); + + public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent + .SeLinuxOptionsNested< + A> + editSeLinuxOptions(); + + public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent + .SeLinuxOptionsNested< + A> + editOrNewSeLinuxOptions(); + + public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent + .SeLinuxOptionsNested< + A> + editOrNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item); + + public interface SeLinuxOptionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1SELinuxOptionsFluent< + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent + .SeLinuxOptionsNested< + N>> { public N and(); + public N endSeLinuxOptions(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SELinuxStrategyOptionsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SELinuxStrategyOptionsFluentImpl.java index d46d584883..972db40dbf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SELinuxStrategyOptionsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SELinuxStrategyOptionsFluentImpl.java @@ -1,103 +1,161 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1SELinuxStrategyOptionsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent { + public V1beta1SELinuxStrategyOptionsFluentImpl() {} - /** - * Generated - */ -public class V1beta1SELinuxStrategyOptionsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent{ - public V1beta1SELinuxStrategyOptionsFluentImpl() { - } - public V1beta1SELinuxStrategyOptionsFluentImpl(io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions instance) { + public V1beta1SELinuxStrategyOptionsFluentImpl( + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptions instance) { this.withRule(instance.getRule()); this.withSeLinuxOptions(instance.getSeLinuxOptions()); - } + private java.lang.String rule; private io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder seLinuxOptions; + public java.lang.String getRule() { return this.rule; } + public A withRule(java.lang.String rule) { - this.rule=rule; return (A) this; + this.rule = rule; + return (A) this; } + public java.lang.Boolean hasRule() { return this.rule != null; } - - /** - * Method is deprecated. use withRule instead. - */ + + /** Method is deprecated. use withRule instead. */ @java.lang.Deprecated public A withNewRule(java.lang.String original) { - return (A)withRule(new String(original)); + return (A) withRule(new String(original)); } - + /** * This method has been deprecated, please use method buildSeLinuxOptions instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1SELinuxOptions getSeLinuxOptions() { - return this.seLinuxOptions!=null ?this.seLinuxOptions.build():null; + return this.seLinuxOptions != null ? this.seLinuxOptions.build() : null; } + public io.kubernetes.client.openapi.models.V1SELinuxOptions buildSeLinuxOptions() { - return this.seLinuxOptions!=null ?this.seLinuxOptions.build():null; + return this.seLinuxOptions != null ? this.seLinuxOptions.build() : null; } + public A withSeLinuxOptions(io.kubernetes.client.openapi.models.V1SELinuxOptions seLinuxOptions) { _visitables.get("seLinuxOptions").remove(this.seLinuxOptions); - if (seLinuxOptions!=null){ this.seLinuxOptions= new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder(seLinuxOptions); _visitables.get("seLinuxOptions").add(this.seLinuxOptions);} return (A) this; + if (seLinuxOptions != null) { + this.seLinuxOptions = + new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder(seLinuxOptions); + _visitables.get("seLinuxOptions").add(this.seLinuxOptions); + } + return (A) this; } + public java.lang.Boolean hasSeLinuxOptions() { return this.seLinuxOptions != null; } - public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent.SeLinuxOptionsNested withNewSeLinuxOptions() { - return new io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluentImpl.SeLinuxOptionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent + .SeLinuxOptionsNested< + A> + withNewSeLinuxOptions() { + return new io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluentImpl + .SeLinuxOptionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent.SeLinuxOptionsNested withNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { - return new io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluentImpl.SeLinuxOptionsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent + .SeLinuxOptionsNested< + A> + withNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { + return new io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluentImpl + .SeLinuxOptionsNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent.SeLinuxOptionsNested editSeLinuxOptions() { + + public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent + .SeLinuxOptionsNested< + A> + editSeLinuxOptions() { return withNewSeLinuxOptionsLike(getSeLinuxOptions()); } - public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent.SeLinuxOptionsNested editOrNewSeLinuxOptions() { - return withNewSeLinuxOptionsLike(getSeLinuxOptions() != null ? getSeLinuxOptions(): new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent + .SeLinuxOptionsNested< + A> + editOrNewSeLinuxOptions() { + return withNewSeLinuxOptionsLike( + getSeLinuxOptions() != null + ? getSeLinuxOptions() + : new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent.SeLinuxOptionsNested editOrNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { - return withNewSeLinuxOptionsLike(getSeLinuxOptions() != null ? getSeLinuxOptions(): item); + + public io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent + .SeLinuxOptionsNested< + A> + editOrNewSeLinuxOptionsLike(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { + return withNewSeLinuxOptionsLike(getSeLinuxOptions() != null ? getSeLinuxOptions() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1SELinuxStrategyOptionsFluentImpl that = (V1beta1SELinuxStrategyOptionsFluentImpl) o; - if (rule != null ? !rule.equals(that.rule) :that.rule != null) return false; - if (seLinuxOptions != null ? !seLinuxOptions.equals(that.seLinuxOptions) :that.seLinuxOptions != null) return false; + if (rule != null ? !rule.equals(that.rule) : that.rule != null) return false; + if (seLinuxOptions != null + ? !seLinuxOptions.equals(that.seLinuxOptions) + : that.seLinuxOptions != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(rule, seLinuxOptions, super.hashCode()); + return java.util.Objects.hash(rule, seLinuxOptions, super.hashCode()); } - public class SeLinuxOptionsNestedImpl extends io.kubernetes.client.openapi.models.V1SELinuxOptionsFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent.SeLinuxOptionsNested,io.kubernetes.client.fluent.Nested{ + + public class SeLinuxOptionsNestedImpl + extends io.kubernetes.client.openapi.models.V1SELinuxOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent + .SeLinuxOptionsNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1SELinuxStrategyOptionsFluent + .SeLinuxOptionsNested< + N>, + io.kubernetes.client.fluent.Nested { SeLinuxOptionsNestedImpl(io.kubernetes.client.openapi.models.V1SELinuxOptions item) { this.builder = new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder(this, item); } + SeLinuxOptionsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder(this); } + io.kubernetes.client.openapi.models.V1SELinuxOptionsBuilder builder; + public N and() { return (N) V1beta1SELinuxStrategyOptionsFluentImpl.this.withSeLinuxOptions(builder.build()); } + public N endSeLinuxOptions() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SchedulingBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SchedulingBuilder.java index 4b64f9d42a..c2b4c4994f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SchedulingBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SchedulingBuilder.java @@ -1,63 +1,101 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1SchedulingBuilder extends io.kubernetes.client.openapi.models.V1beta1SchedulingFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1SchedulingBuilder + extends io.kubernetes.client.openapi.models.V1beta1SchedulingFluentImpl< + io.kubernetes.client.openapi.models.V1beta1SchedulingBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1Scheduling, + io.kubernetes.client.openapi.models.V1beta1SchedulingBuilder> { public V1beta1SchedulingBuilder() { this(false); } + public V1beta1SchedulingBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1Scheduling(), validationEnabled); } - public V1beta1SchedulingBuilder(io.kubernetes.client.openapi.models.V1beta1SchedulingFluent fluent) { + + public V1beta1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1beta1SchedulingFluent fluent) { this(fluent, false); } - public V1beta1SchedulingBuilder(io.kubernetes.client.openapi.models.V1beta1SchedulingFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1beta1SchedulingFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1Scheduling(), validationEnabled); } - public V1beta1SchedulingBuilder(io.kubernetes.client.openapi.models.V1beta1SchedulingFluent fluent,io.kubernetes.client.openapi.models.V1beta1Scheduling instance) { + + public V1beta1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1beta1SchedulingFluent fluent, + io.kubernetes.client.openapi.models.V1beta1Scheduling instance) { this(fluent, instance, false); } - public V1beta1SchedulingBuilder(io.kubernetes.client.openapi.models.V1beta1SchedulingFluent fluent,io.kubernetes.client.openapi.models.V1beta1Scheduling instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1beta1SchedulingFluent fluent, + io.kubernetes.client.openapi.models.V1beta1Scheduling instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNodeSelector(instance.getNodeSelector()); fluent.withTolerations(instance.getTolerations()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1beta1SchedulingBuilder(io.kubernetes.client.openapi.models.V1beta1Scheduling instance) { - this(instance,false); + this(instance, false); } - public V1beta1SchedulingBuilder(io.kubernetes.client.openapi.models.V1beta1Scheduling instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1SchedulingBuilder( + io.kubernetes.client.openapi.models.V1beta1Scheduling instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNodeSelector(instance.getNodeSelector()); this.withTolerations(instance.getTolerations()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1SchedulingFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1Scheduling build() { V1beta1Scheduling buildable = new V1beta1Scheduling(); buildable.setNodeSelector(fluent.getNodeSelector()); buildable.setTolerations(fluent.getTolerations()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1SchedulingBuilder that = (V1beta1SchedulingBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SchedulingFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SchedulingFluent.java index 21439002f1..ae0914f8d3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SchedulingFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SchedulingFluent.java @@ -1,66 +1,116 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; -import java.util.Map; - - /** - * Generated - */ -public interface V1beta1SchedulingFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToNodeSelector(java.lang.String key,java.lang.String value); - public A addToNodeSelector(java.util.Map map); +/** Generated */ +public interface V1beta1SchedulingFluent< + A extends io.kubernetes.client.openapi.models.V1beta1SchedulingFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToNodeSelector(java.lang.String key, java.lang.String value); + + public A addToNodeSelector(java.util.Map map); + public A removeFromNodeSelector(java.lang.String key); - public A removeFromNodeSelector(java.util.Map map); - public java.util.Map getNodeSelector(); - public A withNodeSelector(java.util.Map nodeSelector); + + public A removeFromNodeSelector(java.util.Map map); + + public java.util.Map getNodeSelector(); + + public A withNodeSelector(java.util.Map nodeSelector); + public java.lang.Boolean hasNodeSelector(); - public A addToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item); - public A setToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item); + + public A addToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item); + + public A setToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item); + public A addToTolerations(io.kubernetes.client.openapi.models.V1Toleration... items); - public A addAllToTolerations(java.util.Collection items); + + public A addAllToTolerations( + java.util.Collection items); + public A removeFromTolerations(io.kubernetes.client.openapi.models.V1Toleration... items); - public A removeAllFromTolerations(java.util.Collection items); - public A removeMatchingFromTolerations(java.util.function.Predicate predicate); - + + public A removeAllFromTolerations( + java.util.Collection items); + + public A removeMatchingFromTolerations( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildTolerations instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getTolerations(); + public java.util.List buildTolerations(); + public io.kubernetes.client.openapi.models.V1Toleration buildToleration(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1Toleration buildFirstToleration(); + public io.kubernetes.client.openapi.models.V1Toleration buildLastToleration(); - public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingToleration(java.util.function.Predicate predicate); - public A withTolerations(java.util.List tolerations); + + public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingToleration( + java.util.function.Predicate + predicate); + + public A withTolerations( + java.util.List tolerations); + public A withTolerations(io.kubernetes.client.openapi.models.V1Toleration... tolerations); + public java.lang.Boolean hasTolerations(); - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested addNewToleration(); - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item); - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested setNewTolerationLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item); - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested editToleration(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested editFirstToleration(); - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested editLastToleration(); - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested editMatchingToleration(java.util.function.Predicate predicate); - public interface TolerationsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1TolerationFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + addNewToleration(); + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item); + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + setNewTolerationLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item); + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + editToleration(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + editFirstToleration(); + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + editLastToleration(); + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + editMatchingToleration( + java.util.function.Predicate + predicate); + + public interface TolerationsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1TolerationFluent< + io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested> { public N and(); + public N endToleration(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SchedulingFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SchedulingFluentImpl.java index 432093c86b..8bd6232d7e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SchedulingFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SchedulingFluentImpl.java @@ -1,88 +1,194 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.LinkedHashMap; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; -import java.util.Map; - /** - * Generated - */ -public class V1beta1SchedulingFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1SchedulingFluent{ - public V1beta1SchedulingFluentImpl() { - } - public V1beta1SchedulingFluentImpl(io.kubernetes.client.openapi.models.V1beta1Scheduling instance) { +/** Generated */ +public class V1beta1SchedulingFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1SchedulingFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1SchedulingFluent { + public V1beta1SchedulingFluentImpl() {} + + public V1beta1SchedulingFluentImpl( + io.kubernetes.client.openapi.models.V1beta1Scheduling instance) { this.withNodeSelector(instance.getNodeSelector()); this.withTolerations(instance.getTolerations()); - } - private java.util.Map nodeSelector; + + private java.util.Map nodeSelector; private java.util.ArrayList tolerations; - public A addToNodeSelector(java.lang.String key,java.lang.String value) { - if(this.nodeSelector == null && key != null && value != null) { this.nodeSelector = new java.util.LinkedHashMap(); } - if(key != null && value != null) {this.nodeSelector.put(key, value);} return (A)this; + + public A addToNodeSelector(java.lang.String key, java.lang.String value) { + if (this.nodeSelector == null && key != null && value != null) { + this.nodeSelector = new java.util.LinkedHashMap(); + } + if (key != null && value != null) { + this.nodeSelector.put(key, value); + } + return (A) this; } - public A addToNodeSelector(java.util.Map map) { - if(this.nodeSelector == null && map != null) { this.nodeSelector = new java.util.LinkedHashMap(); } - if(map != null) { this.nodeSelector.putAll(map);} return (A)this; + + public A addToNodeSelector(java.util.Map map) { + if (this.nodeSelector == null && map != null) { + this.nodeSelector = new java.util.LinkedHashMap(); + } + if (map != null) { + this.nodeSelector.putAll(map); + } + return (A) this; } + public A removeFromNodeSelector(java.lang.String key) { - if(this.nodeSelector == null) { return (A) this; } - if(key != null && this.nodeSelector != null) {this.nodeSelector.remove(key);} return (A)this; + if (this.nodeSelector == null) { + return (A) this; + } + if (key != null && this.nodeSelector != null) { + this.nodeSelector.remove(key); + } + return (A) this; } - public A removeFromNodeSelector(java.util.Map map) { - if(this.nodeSelector == null) { return (A) this; } - if(map != null) { for(Object key : map.keySet()) {if (this.nodeSelector != null){this.nodeSelector.remove(key);}}} return (A)this; + + public A removeFromNodeSelector(java.util.Map map) { + if (this.nodeSelector == null) { + return (A) this; + } + if (map != null) { + for (Object key : map.keySet()) { + if (this.nodeSelector != null) { + this.nodeSelector.remove(key); + } + } + } + return (A) this; } - public java.util.Map getNodeSelector() { + + public java.util.Map getNodeSelector() { return this.nodeSelector; } - public A withNodeSelector(java.util.Map nodeSelector) { - if (nodeSelector == null) { this.nodeSelector = null;} else {this.nodeSelector = new java.util.LinkedHashMap(nodeSelector);} return (A) this; + + public A withNodeSelector(java.util.Map nodeSelector) { + if (nodeSelector == null) { + this.nodeSelector = null; + } else { + this.nodeSelector = new java.util.LinkedHashMap(nodeSelector); + } + return (A) this; } + public java.lang.Boolean hasNodeSelector() { return this.nodeSelector != null; } - public A addToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").add(index >= 0 ? index : _visitables.get("tolerations").size(), builder);this.tolerations.add(index >= 0 ? index : tolerations.size(), builder); return (A)this; + + public A addToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables + .get("tolerations") + .add(index >= 0 ? index : _visitables.get("tolerations").size(), builder); + this.tolerations.add(index >= 0 ? index : tolerations.size(), builder); + return (A) this; } - public A setToTolerations(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); - if (index < 0 || index >= _visitables.get("tolerations").size()) { _visitables.get("tolerations").add(builder); } else { _visitables.get("tolerations").set(index, builder);} - if (index < 0 || index >= tolerations.size()) { tolerations.add(builder); } else { tolerations.set(index, builder);} - return (A)this; + + public A setToTolerations( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + if (index < 0 || index >= _visitables.get("tolerations").size()) { + _visitables.get("tolerations").add(builder); + } else { + _visitables.get("tolerations").set(index, builder); + } + if (index < 0 || index >= tolerations.size()) { + tolerations.add(builder); + } else { + tolerations.set(index, builder); + } + return (A) this; } + public A addToTolerations(io.kubernetes.client.openapi.models.V1Toleration... items) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").add(builder);this.tolerations.add(builder);} return (A)this; + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").add(builder); + this.tolerations.add(builder); + } + return (A) this; } - public A addAllToTolerations(java.util.Collection items) { - if (this.tolerations == null) {this.tolerations = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").add(builder);this.tolerations.add(builder);} return (A)this; + + public A addAllToTolerations( + java.util.Collection items) { + if (this.tolerations == null) { + this.tolerations = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").add(builder); + this.tolerations.add(builder); + } + return (A) this; } + public A removeFromTolerations(io.kubernetes.client.openapi.models.V1Toleration... items) { - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").remove(builder);if (this.tolerations != null) {this.tolerations.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").remove(builder); + if (this.tolerations != null) { + this.tolerations.remove(builder); + } + } + return (A) this; } - public A removeAllFromTolerations(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1Toleration item : items) {io.kubernetes.client.openapi.models.V1TolerationBuilder builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(item);_visitables.get("tolerations").remove(builder);if (this.tolerations != null) {this.tolerations.remove(builder);}} return (A)this; + + public A removeAllFromTolerations( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1Toleration item : items) { + io.kubernetes.client.openapi.models.V1TolerationBuilder builder = + new io.kubernetes.client.openapi.models.V1TolerationBuilder(item); + _visitables.get("tolerations").remove(builder); + if (this.tolerations != null) { + this.tolerations.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromTolerations(java.util.function.Predicate predicate) { + + public A removeMatchingFromTolerations( + java.util.function.Predicate + predicate) { if (tolerations == null) return (A) this; - final Iterator each = tolerations.iterator(); + final Iterator each = + tolerations.iterator(); final List visitables = _visitables.get("tolerations"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1TolerationBuilder builder = each.next(); @@ -91,105 +197,184 @@ public A removeMatchingFromTolerations(java.util.function.Predicate getTolerations() { return tolerations != null ? build(tolerations) : null; } + public java.util.List buildTolerations() { return tolerations != null ? build(tolerations) : null; } + public io.kubernetes.client.openapi.models.V1Toleration buildToleration(java.lang.Integer index) { return this.tolerations.get(index).build(); } + public io.kubernetes.client.openapi.models.V1Toleration buildFirstToleration() { return this.tolerations.get(0).build(); } + public io.kubernetes.client.openapi.models.V1Toleration buildLastToleration() { return this.tolerations.get(tolerations.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TolerationBuilder item: tolerations) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1Toleration buildMatchingToleration( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1TolerationBuilder item : tolerations) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingToleration(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1TolerationBuilder item: tolerations) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingToleration( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1TolerationBuilder item : tolerations) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withTolerations(java.util.List tolerations) { - if (this.tolerations != null) { _visitables.get("tolerations").removeAll(this.tolerations);} - if (tolerations != null) {this.tolerations = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1Toleration item : tolerations){this.addToTolerations(item);}} else { this.tolerations = null;} return (A) this; + + public A withTolerations( + java.util.List tolerations) { + if (this.tolerations != null) { + _visitables.get("tolerations").removeAll(this.tolerations); + } + if (tolerations != null) { + this.tolerations = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1Toleration item : tolerations) { + this.addToTolerations(item); + } + } else { + this.tolerations = null; + } + return (A) this; } + public A withTolerations(io.kubernetes.client.openapi.models.V1Toleration... tolerations) { - if (this.tolerations != null) {this.tolerations.clear();} - if (tolerations != null) {for (io.kubernetes.client.openapi.models.V1Toleration item :tolerations){ this.addToTolerations(item);}} return (A) this; + if (this.tolerations != null) { + this.tolerations.clear(); + } + if (tolerations != null) { + for (io.kubernetes.client.openapi.models.V1Toleration item : tolerations) { + this.addToTolerations(item); + } + } + return (A) this; } + public java.lang.Boolean hasTolerations() { return tolerations != null && !tolerations.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested addNewToleration() { - return new io.kubernetes.client.openapi.models.V1beta1SchedulingFluentImpl.TolerationsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + addNewToleration() { + return new io.kubernetes.client.openapi.models.V1beta1SchedulingFluentImpl + .TolerationsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item) { - return new io.kubernetes.client.openapi.models.V1beta1SchedulingFluentImpl.TolerationsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + addNewTolerationLike(io.kubernetes.client.openapi.models.V1Toleration item) { + return new io.kubernetes.client.openapi.models.V1beta1SchedulingFluentImpl + .TolerationsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested setNewTolerationLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { - return new io.kubernetes.client.openapi.models.V1beta1SchedulingFluentImpl.TolerationsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + setNewTolerationLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { + return new io.kubernetes.client.openapi.models.V1beta1SchedulingFluentImpl + .TolerationsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested editToleration(java.lang.Integer index) { - if (tolerations.size() <= index) throw new RuntimeException("Can't edit tolerations. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + editToleration(java.lang.Integer index) { + if (tolerations.size() <= index) + throw new RuntimeException("Can't edit tolerations. Index exceeds size."); return setNewTolerationLike(index, buildToleration(index)); } - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested editFirstToleration() { - if (tolerations.size() == 0) throw new RuntimeException("Can't edit first tolerations. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + editFirstToleration() { + if (tolerations.size() == 0) + throw new RuntimeException("Can't edit first tolerations. The list is empty."); return setNewTolerationLike(0, buildToleration(0)); } - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested editLastToleration() { + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + editLastToleration() { int index = tolerations.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last tolerations. The list is empty."); return setNewTolerationLike(index, buildToleration(index)); } - public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested editMatchingToleration(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested + editMatchingToleration( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1TolerationFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested,io.kubernetes.client.fluent.Nested{ - TolerationsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1Toleration item) { + + public class TolerationsNestedImpl + extends io.kubernetes.client.openapi.models.V1TolerationFluentImpl< + io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested> + implements io.kubernetes.client.openapi.models.V1beta1SchedulingFluent.TolerationsNested, + io.kubernetes.client.fluent.Nested { + TolerationsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1Toleration item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(this, item); } + TolerationsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1TolerationBuilder(this); } + io.kubernetes.client.openapi.models.V1TolerationBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1SchedulingFluentImpl.this.setToTolerations(index,builder.build()); + return (N) V1beta1SchedulingFluentImpl.this.setToTolerations(index, builder.build()); } + public N endToleration() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ServiceAccountSubjectBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ServiceAccountSubjectBuilder.java index 2505b51569..8a54819d39 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ServiceAccountSubjectBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ServiceAccountSubjectBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1ServiceAccountSubjectBuilder extends io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1ServiceAccountSubjectBuilder + extends io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject, + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectBuilder> { public V1beta1ServiceAccountSubjectBuilder() { this(false); } + public V1beta1ServiceAccountSubjectBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1ServiceAccountSubject(), validationEnabled); } - public V1beta1ServiceAccountSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent fluent) { + + public V1beta1ServiceAccountSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent fluent) { this(fluent, false); } - public V1beta1ServiceAccountSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1ServiceAccountSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1ServiceAccountSubject(), validationEnabled); } - public V1beta1ServiceAccountSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject instance) { + + public V1beta1ServiceAccountSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject instance) { this(fluent, instance, false); } - public V1beta1ServiceAccountSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1ServiceAccountSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withNamespace(instance.getNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1ServiceAccountSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject instance) { - this(instance,false); + + public V1beta1ServiceAccountSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject instance) { + this(instance, false); } - public V1beta1ServiceAccountSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1ServiceAccountSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withNamespace(instance.getNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject build() { V1beta1ServiceAccountSubject buildable = new V1beta1ServiceAccountSubject(); buildable.setName(fluent.getName()); buildable.setNamespace(fluent.getNamespace()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1ServiceAccountSubjectBuilder that = (V1beta1ServiceAccountSubjectBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ServiceAccountSubjectFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ServiceAccountSubjectFluent.java index 550c0b0640..980d099d53 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ServiceAccountSubjectFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ServiceAccountSubjectFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1ServiceAccountSubjectFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1ServiceAccountSubjectFluent< + A extends io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getNamespace(); + public A withNamespace(java.lang.String namespace); + public java.lang.Boolean hasNamespace(); - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ServiceAccountSubjectFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ServiceAccountSubjectFluentImpl.java index 403fc00b83..5a3e6473ec 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ServiceAccountSubjectFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1ServiceAccountSubjectFluentImpl.java @@ -1,69 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1beta1ServiceAccountSubjectFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent { + public V1beta1ServiceAccountSubjectFluentImpl() {} - /** - * Generated - */ -public class V1beta1ServiceAccountSubjectFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent{ - public V1beta1ServiceAccountSubjectFluentImpl() { - } - public V1beta1ServiceAccountSubjectFluentImpl(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject instance) { + public V1beta1ServiceAccountSubjectFluentImpl( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject instance) { this.withName(instance.getName()); this.withNamespace(instance.getNamespace()); - } + private java.lang.String name; private java.lang.String namespace; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getNamespace() { return this.namespace; } + public A withNamespace(java.lang.String namespace) { - this.namespace=namespace; return (A) this; + this.namespace = namespace; + return (A) this; } + public java.lang.Boolean hasNamespace() { return this.namespace != null; } - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original) { - return (A)withNamespace(new String(original)); + return (A) withNamespace(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1ServiceAccountSubjectFluentImpl that = (V1beta1ServiceAccountSubjectFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (namespace != null ? !namespace.equals(that.namespace) :that.namespace != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (namespace != null ? !namespace.equals(that.namespace) : that.namespace != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, namespace, super.hashCode()); + return java.util.Objects.hash(name, namespace, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SubjectBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SubjectBuilder.java index 45db23b301..532d24c3df 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SubjectBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SubjectBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1SubjectBuilder extends io.kubernetes.client.openapi.models.V1beta1SubjectFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1SubjectBuilder + extends io.kubernetes.client.openapi.models.V1beta1SubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta1SubjectBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1Subject, + io.kubernetes.client.openapi.models.V1beta1SubjectBuilder> { public V1beta1SubjectBuilder() { this(false); } + public V1beta1SubjectBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1Subject(), validationEnabled); } + public V1beta1SubjectBuilder(io.kubernetes.client.openapi.models.V1beta1SubjectFluent fluent) { this(fluent, false); } - public V1beta1SubjectBuilder(io.kubernetes.client.openapi.models.V1beta1SubjectFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1SubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1SubjectFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1Subject(), validationEnabled); } - public V1beta1SubjectBuilder(io.kubernetes.client.openapi.models.V1beta1SubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta1Subject instance) { + + public V1beta1SubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1SubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta1Subject instance) { this(fluent, instance, false); } - public V1beta1SubjectBuilder(io.kubernetes.client.openapi.models.V1beta1SubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta1Subject instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1SubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1SubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta1Subject instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withGroup(instance.getGroup()); fluent.withKind(instance.getKind()); @@ -29,13 +55,17 @@ public V1beta1SubjectBuilder(io.kubernetes.client.openapi.models.V1beta1SubjectF fluent.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1beta1SubjectBuilder(io.kubernetes.client.openapi.models.V1beta1Subject instance) { - this(instance,false); + this(instance, false); } - public V1beta1SubjectBuilder(io.kubernetes.client.openapi.models.V1beta1Subject instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1SubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1Subject instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withGroup(instance.getGroup()); this.withKind(instance.getKind()); @@ -44,10 +74,12 @@ public V1beta1SubjectBuilder(io.kubernetes.client.openapi.models.V1beta1Subject this.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1SubjectFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1Subject build() { V1beta1Subject buildable = new V1beta1Subject(); buildable.setGroup(fluent.getGroup()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1beta1Subject build() { buildable.setUser(fluent.getUser()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1SubjectBuilder that = (V1beta1SubjectBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SubjectFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SubjectFluent.java index 0bdafdd2b1..fa6c9e43bc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SubjectFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SubjectFluent.java @@ -1,84 +1,140 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1SubjectFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1beta1SubjectFluent< + A extends io.kubernetes.client.openapi.models.V1beta1SubjectFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildGroup instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1GroupSubject getGroup(); + public io.kubernetes.client.openapi.models.V1beta1GroupSubject buildGroup(); + public A withGroup(io.kubernetes.client.openapi.models.V1beta1GroupSubject group); + public java.lang.Boolean hasGroup(); + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested withNewGroup(); - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested withNewGroupLike(io.kubernetes.client.openapi.models.V1beta1GroupSubject item); + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested withNewGroupLike( + io.kubernetes.client.openapi.models.V1beta1GroupSubject item); + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested editGroup(); + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested editOrNewGroup(); - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested editOrNewGroupLike(io.kubernetes.client.openapi.models.V1beta1GroupSubject item); + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested editOrNewGroupLike( + io.kubernetes.client.openapi.models.V1beta1GroupSubject item); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildServiceAccount instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject getServiceAccount(); + public io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject buildServiceAccount(); - public A withServiceAccount(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject serviceAccount); + + public A withServiceAccount( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject serviceAccount); + public java.lang.Boolean hasServiceAccount(); - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested withNewServiceAccount(); - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested withNewServiceAccountLike(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject item); - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested editServiceAccount(); - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested editOrNewServiceAccount(); - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested editOrNewServiceAccountLike(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject item); - + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested + withNewServiceAccount(); + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested + withNewServiceAccountLike( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject item); + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested + editServiceAccount(); + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested + editOrNewServiceAccount(); + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested + editOrNewServiceAccountLike( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject item); + /** * This method has been deprecated, please use method buildUser instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1UserSubject getUser(); + public io.kubernetes.client.openapi.models.V1beta1UserSubject buildUser(); + public A withUser(io.kubernetes.client.openapi.models.V1beta1UserSubject user); + public java.lang.Boolean hasUser(); + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested withNewUser(); - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested withNewUserLike(io.kubernetes.client.openapi.models.V1beta1UserSubject item); + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested withNewUserLike( + io.kubernetes.client.openapi.models.V1beta1UserSubject item); + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested editUser(); + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested editOrNewUser(); - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested editOrNewUserLike(io.kubernetes.client.openapi.models.V1beta1UserSubject item); - public interface GroupNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent>{ + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested editOrNewUserLike( + io.kubernetes.client.openapi.models.V1beta1UserSubject item); + + public interface GroupNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluent< + io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested> { public N and(); + public N endGroup(); - } - public interface ServiceAccountNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent>{ + + public interface ServiceAccountNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluent< + io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested> { public N and(); + public N endServiceAccount(); - } - public interface UserNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent>{ + + public interface UserNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent< + io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested> { public N and(); + public N endUser(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SubjectFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SubjectFluentImpl.java index 951f8c1e0b..30ee6b5cbd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SubjectFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SubjectFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta1SubjectFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1SubjectFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1SubjectFluent { + public V1beta1SubjectFluentImpl() {} - /** - * Generated - */ -public class V1beta1SubjectFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1SubjectFluent{ - public V1beta1SubjectFluentImpl() { - } public V1beta1SubjectFluentImpl(io.kubernetes.client.openapi.models.V1beta1Subject instance) { this.withGroup(instance.getGroup()); @@ -21,191 +27,288 @@ public V1beta1SubjectFluentImpl(io.kubernetes.client.openapi.models.V1beta1Subje this.withServiceAccount(instance.getServiceAccount()); this.withUser(instance.getUser()); - } + private io.kubernetes.client.openapi.models.V1beta1GroupSubjectBuilder group; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectBuilder serviceAccount; private io.kubernetes.client.openapi.models.V1beta1UserSubjectBuilder user; - + /** * This method has been deprecated, please use method buildGroup instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1GroupSubject getGroup() { - return this.group!=null ?this.group.build():null; + return this.group != null ? this.group.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1GroupSubject buildGroup() { - return this.group!=null ?this.group.build():null; + return this.group != null ? this.group.build() : null; } + public A withGroup(io.kubernetes.client.openapi.models.V1beta1GroupSubject group) { _visitables.get("group").remove(this.group); - if (group!=null){ this.group= new io.kubernetes.client.openapi.models.V1beta1GroupSubjectBuilder(group); _visitables.get("group").add(this.group);} return (A) this; + if (group != null) { + this.group = new io.kubernetes.client.openapi.models.V1beta1GroupSubjectBuilder(group); + _visitables.get("group").add(this.group); + } + return (A) this; } + public java.lang.Boolean hasGroup() { return this.group != null; } + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested withNewGroup() { return new io.kubernetes.client.openapi.models.V1beta1SubjectFluentImpl.GroupNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested withNewGroupLike(io.kubernetes.client.openapi.models.V1beta1GroupSubject item) { + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested withNewGroupLike( + io.kubernetes.client.openapi.models.V1beta1GroupSubject item) { return new io.kubernetes.client.openapi.models.V1beta1SubjectFluentImpl.GroupNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested editGroup() { return withNewGroupLike(getGroup()); } + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested editOrNewGroup() { - return withNewGroupLike(getGroup() != null ? getGroup(): new io.kubernetes.client.openapi.models.V1beta1GroupSubjectBuilder().build()); + return withNewGroupLike( + getGroup() != null + ? getGroup() + : new io.kubernetes.client.openapi.models.V1beta1GroupSubjectBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested editOrNewGroupLike(io.kubernetes.client.openapi.models.V1beta1GroupSubject item) { - return withNewGroupLike(getGroup() != null ? getGroup(): item); + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested editOrNewGroupLike( + io.kubernetes.client.openapi.models.V1beta1GroupSubject item) { + return withNewGroupLike(getGroup() != null ? getGroup() : item); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildServiceAccount instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject getServiceAccount() { - return this.serviceAccount!=null ?this.serviceAccount.build():null; + return this.serviceAccount != null ? this.serviceAccount.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject buildServiceAccount() { - return this.serviceAccount!=null ?this.serviceAccount.build():null; + return this.serviceAccount != null ? this.serviceAccount.build() : null; } - public A withServiceAccount(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject serviceAccount) { + + public A withServiceAccount( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject serviceAccount) { _visitables.get("serviceAccount").remove(this.serviceAccount); - if (serviceAccount!=null){ this.serviceAccount= new io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectBuilder(serviceAccount); _visitables.get("serviceAccount").add(this.serviceAccount);} return (A) this; + if (serviceAccount != null) { + this.serviceAccount = + new io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectBuilder( + serviceAccount); + _visitables.get("serviceAccount").add(this.serviceAccount); + } + return (A) this; } + public java.lang.Boolean hasServiceAccount() { return this.serviceAccount != null; } - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested withNewServiceAccount() { - return new io.kubernetes.client.openapi.models.V1beta1SubjectFluentImpl.ServiceAccountNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested + withNewServiceAccount() { + return new io.kubernetes.client.openapi.models.V1beta1SubjectFluentImpl + .ServiceAccountNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested withNewServiceAccountLike(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject item) { - return new io.kubernetes.client.openapi.models.V1beta1SubjectFluentImpl.ServiceAccountNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested + withNewServiceAccountLike( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject item) { + return new io.kubernetes.client.openapi.models.V1beta1SubjectFluentImpl + .ServiceAccountNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested editServiceAccount() { + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested + editServiceAccount() { return withNewServiceAccountLike(getServiceAccount()); } - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested editOrNewServiceAccount() { - return withNewServiceAccountLike(getServiceAccount() != null ? getServiceAccount(): new io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested + editOrNewServiceAccount() { + return withNewServiceAccountLike( + getServiceAccount() != null + ? getServiceAccount() + : new io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested editOrNewServiceAccountLike(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject item) { - return withNewServiceAccountLike(getServiceAccount() != null ? getServiceAccount(): item); + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested + editOrNewServiceAccountLike( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject item) { + return withNewServiceAccountLike(getServiceAccount() != null ? getServiceAccount() : item); } - + /** * This method has been deprecated, please use method buildUser instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta1UserSubject getUser() { - return this.user!=null ?this.user.build():null; + return this.user != null ? this.user.build() : null; } + public io.kubernetes.client.openapi.models.V1beta1UserSubject buildUser() { - return this.user!=null ?this.user.build():null; + return this.user != null ? this.user.build() : null; } + public A withUser(io.kubernetes.client.openapi.models.V1beta1UserSubject user) { _visitables.get("user").remove(this.user); - if (user!=null){ this.user= new io.kubernetes.client.openapi.models.V1beta1UserSubjectBuilder(user); _visitables.get("user").add(this.user);} return (A) this; + if (user != null) { + this.user = new io.kubernetes.client.openapi.models.V1beta1UserSubjectBuilder(user); + _visitables.get("user").add(this.user); + } + return (A) this; } + public java.lang.Boolean hasUser() { return this.user != null; } + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested withNewUser() { return new io.kubernetes.client.openapi.models.V1beta1SubjectFluentImpl.UserNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested withNewUserLike(io.kubernetes.client.openapi.models.V1beta1UserSubject item) { + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested withNewUserLike( + io.kubernetes.client.openapi.models.V1beta1UserSubject item) { return new io.kubernetes.client.openapi.models.V1beta1SubjectFluentImpl.UserNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested editUser() { return withNewUserLike(getUser()); } + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested editOrNewUser() { - return withNewUserLike(getUser() != null ? getUser(): new io.kubernetes.client.openapi.models.V1beta1UserSubjectBuilder().build()); + return withNewUserLike( + getUser() != null + ? getUser() + : new io.kubernetes.client.openapi.models.V1beta1UserSubjectBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested editOrNewUserLike(io.kubernetes.client.openapi.models.V1beta1UserSubject item) { - return withNewUserLike(getUser() != null ? getUser(): item); + + public io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested editOrNewUserLike( + io.kubernetes.client.openapi.models.V1beta1UserSubject item) { + return withNewUserLike(getUser() != null ? getUser() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1SubjectFluentImpl that = (V1beta1SubjectFluentImpl) o; - if (group != null ? !group.equals(that.group) :that.group != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (serviceAccount != null ? !serviceAccount.equals(that.serviceAccount) :that.serviceAccount != null) return false; - if (user != null ? !user.equals(that.user) :that.user != null) return false; + if (group != null ? !group.equals(that.group) : that.group != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (serviceAccount != null + ? !serviceAccount.equals(that.serviceAccount) + : that.serviceAccount != null) return false; + if (user != null ? !user.equals(that.user) : that.user != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(group, kind, serviceAccount, user, super.hashCode()); + return java.util.Objects.hash(group, kind, serviceAccount, user, super.hashCode()); } - public class GroupNestedImpl extends io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested,io.kubernetes.client.fluent.Nested{ + + public class GroupNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1GroupSubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested> + implements io.kubernetes.client.openapi.models.V1beta1SubjectFluent.GroupNested, + io.kubernetes.client.fluent.Nested { GroupNestedImpl(io.kubernetes.client.openapi.models.V1beta1GroupSubject item) { this.builder = new io.kubernetes.client.openapi.models.V1beta1GroupSubjectBuilder(this, item); } + GroupNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta1GroupSubjectBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1GroupSubjectBuilder builder; + public N and() { return (N) V1beta1SubjectFluentImpl.this.withGroup(builder.build()); } + public N endGroup() { return and(); } - } - public class ServiceAccountNestedImpl extends io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested,io.kubernetes.client.fluent.Nested{ - ServiceAccountNestedImpl(io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectBuilder(this, item); + + public class ServiceAccountNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested> + implements io.kubernetes.client.openapi.models.V1beta1SubjectFluent.ServiceAccountNested, + io.kubernetes.client.fluent.Nested { + ServiceAccountNestedImpl( + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubject item) { + this.builder = + new io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectBuilder(this, item); } + ServiceAccountNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1ServiceAccountSubjectBuilder builder; + public N and() { return (N) V1beta1SubjectFluentImpl.this.withServiceAccount(builder.build()); } + public N endServiceAccount() { return and(); } - } - public class UserNestedImpl extends io.kubernetes.client.openapi.models.V1beta1UserSubjectFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested,io.kubernetes.client.fluent.Nested{ + + public class UserNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1UserSubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested> + implements io.kubernetes.client.openapi.models.V1beta1SubjectFluent.UserNested, + io.kubernetes.client.fluent.Nested { UserNestedImpl(io.kubernetes.client.openapi.models.V1beta1UserSubject item) { this.builder = new io.kubernetes.client.openapi.models.V1beta1UserSubjectBuilder(this, item); } + UserNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta1UserSubjectBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1UserSubjectBuilder builder; + public N and() { return (N) V1beta1SubjectFluentImpl.this.withUser(builder.build()); } + public N endUser() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SupplementalGroupsStrategyOptionsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SupplementalGroupsStrategyOptionsBuilder.java index 77f6fad2af..574fbe8161 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SupplementalGroupsStrategyOptionsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SupplementalGroupsStrategyOptionsBuilder.java @@ -1,63 +1,105 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1SupplementalGroupsStrategyOptionsBuilder extends io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1SupplementalGroupsStrategyOptionsBuilder + extends io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluentImpl< + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions, + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsBuilder> { public V1beta1SupplementalGroupsStrategyOptionsBuilder() { this(false); } + public V1beta1SupplementalGroupsStrategyOptionsBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1SupplementalGroupsStrategyOptions(), validationEnabled); } - public V1beta1SupplementalGroupsStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent fluent) { + + public V1beta1SupplementalGroupsStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + fluent) { this(fluent, false); } - public V1beta1SupplementalGroupsStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1SupplementalGroupsStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1SupplementalGroupsStrategyOptions(), validationEnabled); } - public V1beta1SupplementalGroupsStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions instance) { + + public V1beta1SupplementalGroupsStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions instance) { this(fluent, instance, false); } - public V1beta1SupplementalGroupsStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent fluent,io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1SupplementalGroupsStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent fluent, + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withRanges(instance.getRanges()); fluent.withRule(instance.getRule()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1SupplementalGroupsStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions instance) { - this(instance,false); + + public V1beta1SupplementalGroupsStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions instance) { + this(instance, false); } - public V1beta1SupplementalGroupsStrategyOptionsBuilder(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1SupplementalGroupsStrategyOptionsBuilder( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withRanges(instance.getRanges()); this.withRule(instance.getRule()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions build() { - V1beta1SupplementalGroupsStrategyOptions buildable = new V1beta1SupplementalGroupsStrategyOptions(); + V1beta1SupplementalGroupsStrategyOptions buildable = + new V1beta1SupplementalGroupsStrategyOptions(); buildable.setRanges(fluent.getRanges()); buildable.setRule(fluent.getRule()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1beta1SupplementalGroupsStrategyOptionsBuilder that = (V1beta1SupplementalGroupsStrategyOptionsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1beta1SupplementalGroupsStrategyOptionsBuilder that = + (V1beta1SupplementalGroupsStrategyOptionsBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SupplementalGroupsStrategyOptionsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SupplementalGroupsStrategyOptionsFluent.java index 59f99b898b..b42bffe4f4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SupplementalGroupsStrategyOptionsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SupplementalGroupsStrategyOptionsFluent.java @@ -1,66 +1,128 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1SupplementalGroupsStrategyOptionsFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item); - public A setToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item); +/** Generated */ +public interface V1beta1SupplementalGroupsStrategyOptionsFluent< + A extends + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item); + + public A setToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item); + public A addToRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items); - public A addAllToRanges(java.util.Collection items); + + public A addAllToRanges( + java.util.Collection items); + public A removeFromRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items); - public A removeAllFromRanges(java.util.Collection items); - public A removeMatchingFromRanges(java.util.function.Predicate predicate); - + + public A removeAllFromRanges( + java.util.Collection items); + + public A removeMatchingFromRanges( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildRanges instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getRanges(); + public java.util.List buildRanges(); + public io.kubernetes.client.openapi.models.V1beta1IDRange buildRange(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta1IDRange buildFirstRange(); + public io.kubernetes.client.openapi.models.V1beta1IDRange buildLastRange(); - public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRange(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingRange( + java.util.function.Predicate + predicate); + public A withRanges(java.util.List ranges); + public A withRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... ranges); + public java.lang.Boolean hasRanges(); - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested addNewRange(); - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item); - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested setNewRangeLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item); - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested editRange(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested editFirstRange(); - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested editLastRange(); - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested editMatchingRange(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + addNewRange(); + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item); + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + setNewRangeLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item); + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + editRange(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + editFirstRange(); + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + editLastRange(); + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + editMatchingRange( + java.util.function.Predicate + predicate); + public java.lang.String getRule(); + public A withRule(java.lang.String rule); + public java.lang.Boolean hasRule(); - - /** - * Method is deprecated. use withRule instead. - */ + + /** Method is deprecated. use withRule instead. */ @java.lang.Deprecated public A withNewRule(java.lang.String original); - public interface RangesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta1IDRangeFluent>{ + + public interface RangesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta1IDRangeFluent< + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + N>> { public N and(); + public N endRange(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SupplementalGroupsStrategyOptionsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SupplementalGroupsStrategyOptionsFluentImpl.java index c9fd9db5a1..a60fa7dda2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SupplementalGroupsStrategyOptionsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1SupplementalGroupsStrategyOptionsFluentImpl.java @@ -1,61 +1,133 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1beta1SupplementalGroupsStrategyOptionsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent{ - public V1beta1SupplementalGroupsStrategyOptionsFluentImpl() { - } - public V1beta1SupplementalGroupsStrategyOptionsFluentImpl(io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions instance) { +/** Generated */ +public class V1beta1SupplementalGroupsStrategyOptionsFluentImpl< + A extends + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent< + A> { + public V1beta1SupplementalGroupsStrategyOptionsFluentImpl() {} + + public V1beta1SupplementalGroupsStrategyOptionsFluentImpl( + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptions instance) { this.withRanges(instance.getRanges()); this.withRule(instance.getRule()); - } + private java.util.ArrayList ranges; private java.lang.String rule; - public A addToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").add(index >= 0 ? index : _visitables.get("ranges").size(), builder);this.ranges.add(index >= 0 ? index : ranges.size(), builder); return (A)this; + + public A addToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").add(index >= 0 ? index : _visitables.get("ranges").size(), builder); + this.ranges.add(index >= 0 ? index : ranges.size(), builder); + return (A) this; } - public A setToRanges(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); - if (index < 0 || index >= _visitables.get("ranges").size()) { _visitables.get("ranges").add(builder); } else { _visitables.get("ranges").set(index, builder);} - if (index < 0 || index >= ranges.size()) { ranges.add(builder); } else { ranges.set(index, builder);} - return (A)this; + + public A setToRanges( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + if (index < 0 || index >= _visitables.get("ranges").size()) { + _visitables.get("ranges").add(builder); + } else { + _visitables.get("ranges").set(index, builder); + } + if (index < 0 || index >= ranges.size()) { + ranges.add(builder); + } else { + ranges.set(index, builder); + } + return (A) this; } + public A addToRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").add(builder);this.ranges.add(builder);} return (A)this; + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").add(builder); + this.ranges.add(builder); + } + return (A) this; } - public A addAllToRanges(java.util.Collection items) { - if (this.ranges == null) {this.ranges = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").add(builder);this.ranges.add(builder);} return (A)this; + + public A addAllToRanges( + java.util.Collection items) { + if (this.ranges == null) { + this.ranges = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").add(builder); + this.ranges.add(builder); + } + return (A) this; } + public A removeFromRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... items) { - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").remove(builder);if (this.ranges != null) {this.ranges.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").remove(builder); + if (this.ranges != null) { + this.ranges.remove(builder); + } + } + return (A) this; } - public A removeAllFromRanges(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) {io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item);_visitables.get("ranges").remove(builder);if (this.ranges != null) {this.ranges.remove(builder);}} return (A)this; + + public A removeAllFromRanges( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : items) { + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = + new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(item); + _visitables.get("ranges").remove(builder); + if (this.ranges != null) { + this.ranges.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromRanges(java.util.function.Predicate predicate) { + + public A removeMatchingFromRanges( + java.util.function.Predicate + predicate) { if (ranges == null) return (A) this; - final Iterator each = ranges.iterator(); + final Iterator each = + ranges.iterator(); final List visitables = _visitables.get("ranges"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder = each.next(); @@ -64,122 +136,221 @@ public A removeMatchingFromRanges(java.util.function.Predicate getRanges() { return ranges != null ? build(ranges) : null; } + public java.util.List buildRanges() { return ranges != null ? build(ranges) : null; } + public io.kubernetes.client.openapi.models.V1beta1IDRange buildRange(java.lang.Integer index) { return this.ranges.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta1IDRange buildFirstRange() { return this.ranges.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta1IDRange buildLastRange() { return this.ranges.get(ranges.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item: ranges) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta1IDRange buildMatchingRange( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item : ranges) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingRange(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item: ranges) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRange( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder item : ranges) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withRanges(java.util.List ranges) { - if (this.ranges != null) { _visitables.get("ranges").removeAll(this.ranges);} - if (ranges != null) {this.ranges = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta1IDRange item : ranges){this.addToRanges(item);}} else { this.ranges = null;} return (A) this; + if (this.ranges != null) { + _visitables.get("ranges").removeAll(this.ranges); + } + if (ranges != null) { + this.ranges = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : ranges) { + this.addToRanges(item); + } + } else { + this.ranges = null; + } + return (A) this; } + public A withRanges(io.kubernetes.client.openapi.models.V1beta1IDRange... ranges) { - if (this.ranges != null) {this.ranges.clear();} - if (ranges != null) {for (io.kubernetes.client.openapi.models.V1beta1IDRange item :ranges){ this.addToRanges(item);}} return (A) this; + if (this.ranges != null) { + this.ranges.clear(); + } + if (ranges != null) { + for (io.kubernetes.client.openapi.models.V1beta1IDRange item : ranges) { + this.addToRanges(item); + } + } + return (A) this; } + public java.lang.Boolean hasRanges() { return ranges != null && !ranges.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested addNewRange() { - return new io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluentImpl.RangesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + addNewRange() { + return new io.kubernetes.client.openapi.models + .V1beta1SupplementalGroupsStrategyOptionsFluentImpl.RangesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item) { - return new io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluentImpl.RangesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + addNewRangeLike(io.kubernetes.client.openapi.models.V1beta1IDRange item) { + return new io.kubernetes.client.openapi.models + .V1beta1SupplementalGroupsStrategyOptionsFluentImpl.RangesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested setNewRangeLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { - return new io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluentImpl.RangesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + setNewRangeLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { + return new io.kubernetes.client.openapi.models + .V1beta1SupplementalGroupsStrategyOptionsFluentImpl.RangesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested editRange(java.lang.Integer index) { - if (ranges.size() <= index) throw new RuntimeException("Can't edit ranges. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + editRange(java.lang.Integer index) { + if (ranges.size() <= index) + throw new RuntimeException("Can't edit ranges. Index exceeds size."); return setNewRangeLike(index, buildRange(index)); } - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested editFirstRange() { - if (ranges.size() == 0) throw new RuntimeException("Can't edit first ranges. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + editFirstRange() { + if (ranges.size() == 0) + throw new RuntimeException("Can't edit first ranges. The list is empty."); return setNewRangeLike(0, buildRange(0)); } - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested editLastRange() { + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + editLastRange() { int index = ranges.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last ranges. The list is empty."); return setNewRangeLike(index, buildRange(index)); } - public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested editMatchingRange(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + A> + editMatchingRange( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta1IDRangeFluentImpl> implements io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent.RangesNested,io.kubernetes.client.fluent.Nested{ - RangesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta1IDRange item) { + + public class RangesNestedImpl + extends io.kubernetes.client.openapi.models.V1beta1IDRangeFluentImpl< + io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta1SupplementalGroupsStrategyOptionsFluent + .RangesNested< + N>, + io.kubernetes.client.fluent.Nested { + RangesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta1IDRange item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(this, item); } + RangesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder(this); } + io.kubernetes.client.openapi.models.V1beta1IDRangeBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta1SupplementalGroupsStrategyOptionsFluentImpl.this.setToRanges(index,builder.build()); + return (N) + V1beta1SupplementalGroupsStrategyOptionsFluentImpl.this.setToRanges( + index, builder.build()); } + public N endRange() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1UserSubjectBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1UserSubjectBuilder.java index de950e7af1..1996a57c4f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1UserSubjectBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1UserSubjectBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta1UserSubjectBuilder extends io.kubernetes.client.openapi.models.V1beta1UserSubjectFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta1UserSubjectBuilder + extends io.kubernetes.client.openapi.models.V1beta1UserSubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta1UserSubjectBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta1UserSubject, + io.kubernetes.client.openapi.models.V1beta1UserSubjectBuilder> { public V1beta1UserSubjectBuilder() { this(false); } + public V1beta1UserSubjectBuilder(java.lang.Boolean validationEnabled) { this(new V1beta1UserSubject(), validationEnabled); } - public V1beta1UserSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent fluent) { + + public V1beta1UserSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent fluent) { this(fluent, false); } - public V1beta1UserSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta1UserSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta1UserSubject(), validationEnabled); } - public V1beta1UserSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta1UserSubject instance) { + + public V1beta1UserSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta1UserSubject instance) { this(fluent, instance, false); } - public V1beta1UserSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta1UserSubject instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta1UserSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta1UserSubject instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta1UserSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1UserSubject instance) { - this(instance,false); + + public V1beta1UserSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1UserSubject instance) { + this(instance, false); } - public V1beta1UserSubjectBuilder(io.kubernetes.client.openapi.models.V1beta1UserSubject instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta1UserSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta1UserSubject instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta1UserSubject build() { V1beta1UserSubject buildable = new V1beta1UserSubject(); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta1UserSubjectBuilder that = (V1beta1UserSubjectBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1UserSubjectFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1UserSubjectFluent.java index 0c120c4ecc..e7c49f27a6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1UserSubjectFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1UserSubjectFluent.java @@ -1,23 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta1UserSubjectFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta1UserSubjectFluent< + A extends io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1UserSubjectFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1UserSubjectFluentImpl.java index 14e621a962..cdd6f7ce3f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1UserSubjectFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta1UserSubjectFluentImpl.java @@ -1,48 +1,59 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta1UserSubjectFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent{ - public V1beta1UserSubjectFluentImpl() { - } - public V1beta1UserSubjectFluentImpl(io.kubernetes.client.openapi.models.V1beta1UserSubject instance) { - this.withName(instance.getName()); +/** Generated */ +public class V1beta1UserSubjectFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta1UserSubjectFluent { + public V1beta1UserSubjectFluentImpl() {} + public V1beta1UserSubjectFluentImpl( + io.kubernetes.client.openapi.models.V1beta1UserSubject instance) { + this.withName(instance.getName()); } + private java.lang.String name; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta1UserSubjectFluentImpl that = (V1beta1UserSubjectFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, super.hashCode()); + return java.util.Objects.hash(name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowDistinguisherMethodBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowDistinguisherMethodBuilder.java index c8f13dc3d6..f54f00ec4c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowDistinguisherMethodBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowDistinguisherMethodBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2FlowDistinguisherMethodBuilder extends io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2FlowDistinguisherMethodBuilder + extends io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod, + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodBuilder> { public V1beta2FlowDistinguisherMethodBuilder() { this(false); } + public V1beta2FlowDistinguisherMethodBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2FlowDistinguisherMethod(), validationEnabled); } - public V1beta2FlowDistinguisherMethodBuilder(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent fluent) { + + public V1beta2FlowDistinguisherMethodBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent fluent) { this(fluent, false); } - public V1beta2FlowDistinguisherMethodBuilder(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2FlowDistinguisherMethodBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2FlowDistinguisherMethod(), validationEnabled); } - public V1beta2FlowDistinguisherMethodBuilder(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent fluent,io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod instance) { + + public V1beta2FlowDistinguisherMethodBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent fluent, + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod instance) { this(fluent, instance, false); } - public V1beta2FlowDistinguisherMethodBuilder(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent fluent,io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2FlowDistinguisherMethodBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent fluent, + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2FlowDistinguisherMethodBuilder(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod instance) { - this(instance,false); + + public V1beta2FlowDistinguisherMethodBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod instance) { + this(instance, false); } - public V1beta2FlowDistinguisherMethodBuilder(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2FlowDistinguisherMethodBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod build() { V1beta2FlowDistinguisherMethod buildable = new V1beta2FlowDistinguisherMethod(); buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2FlowDistinguisherMethodBuilder that = (V1beta2FlowDistinguisherMethodBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowDistinguisherMethodFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowDistinguisherMethodFluent.java index c3789463b7..0e2e58ee82 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowDistinguisherMethodFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowDistinguisherMethodFluent.java @@ -1,23 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2FlowDistinguisherMethodFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta2FlowDistinguisherMethodFluent< + A extends io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowDistinguisherMethodFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowDistinguisherMethodFluentImpl.java index e2279fd609..e94b1c67f4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowDistinguisherMethodFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowDistinguisherMethodFluentImpl.java @@ -1,48 +1,59 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta2FlowDistinguisherMethodFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent{ - public V1beta2FlowDistinguisherMethodFluentImpl() { - } - public V1beta2FlowDistinguisherMethodFluentImpl(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod instance) { - this.withType(instance.getType()); +/** Generated */ +public class V1beta2FlowDistinguisherMethodFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent { + public V1beta2FlowDistinguisherMethodFluentImpl() {} + public V1beta2FlowDistinguisherMethodFluentImpl( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod instance) { + this.withType(instance.getType()); } + private java.lang.String type; + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta2FlowDistinguisherMethodFluentImpl that = (V1beta2FlowDistinguisherMethodFluentImpl) o; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(type, super.hashCode()); + return java.util.Objects.hash(type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaBuilder.java index 97f5074d77..7e0e3aabbb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2FlowSchemaBuilder extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2FlowSchemaBuilder + extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2FlowSchema, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder> { public V1beta2FlowSchemaBuilder() { this(false); } + public V1beta2FlowSchemaBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2FlowSchema(), validationEnabled); } - public V1beta2FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent fluent) { + + public V1beta2FlowSchemaBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent fluent) { this(fluent, false); } - public V1beta2FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2FlowSchemaBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2FlowSchema(), validationEnabled); } - public V1beta2FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent fluent,io.kubernetes.client.openapi.models.V1beta2FlowSchema instance) { + + public V1beta2FlowSchemaBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent fluent, + io.kubernetes.client.openapi.models.V1beta2FlowSchema instance) { this(fluent, instance, false); } - public V1beta2FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent fluent,io.kubernetes.client.openapi.models.V1beta2FlowSchema instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2FlowSchemaBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent fluent, + io.kubernetes.client.openapi.models.V1beta2FlowSchema instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,17 @@ public V1beta2FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta2FlowS fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1beta2FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchema instance) { - this(instance,false); + this(instance, false); } - public V1beta2FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchema instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2FlowSchemaBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchema instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +79,12 @@ public V1beta2FlowSchemaBuilder(io.kubernetes.client.openapi.models.V1beta2FlowS this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2FlowSchema build() { V1beta2FlowSchema buildable = new V1beta2FlowSchema(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +94,23 @@ public io.kubernetes.client.openapi.models.V1beta2FlowSchema build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2FlowSchemaBuilder that = (V1beta2FlowSchemaBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaConditionBuilder.java index 1d04bf5f6c..8e9b7b1ede 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2FlowSchemaConditionBuilder extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2FlowSchemaConditionBuilder + extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder> { public V1beta2FlowSchemaConditionBuilder() { this(false); } + public V1beta2FlowSchemaConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2FlowSchemaCondition(), validationEnabled); } - public V1beta2FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent fluent) { + + public V1beta2FlowSchemaConditionBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent fluent) { this(fluent, false); } - public V1beta2FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2FlowSchemaConditionBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2FlowSchemaCondition(), validationEnabled); } - public V1beta2FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent fluent,io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition instance) { + + public V1beta2FlowSchemaConditionBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent fluent, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition instance) { this(fluent, instance, false); } - public V1beta2FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent fluent,io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2FlowSchemaConditionBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent fluent, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +58,18 @@ public V1beta2FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1b fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition instance) { - this(instance,false); + + public V1beta2FlowSchemaConditionBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition instance) { + this(instance, false); } - public V1beta2FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2FlowSchemaConditionBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,10 +80,12 @@ public V1beta2FlowSchemaConditionBuilder(io.kubernetes.client.openapi.models.V1b this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition build() { V1beta2FlowSchemaCondition buildable = new V1beta2FlowSchemaCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2FlowSchemaConditionBuilder that = (V1beta2FlowSchemaConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaConditionFluent.java index 6479ab4975..d1f753766a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaConditionFluent.java @@ -1,54 +1,64 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2FlowSchemaConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta2FlowSchemaConditionFluent< + A extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaConditionFluentImpl.java index a393e683e8..3ef8643694 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaConditionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1beta2FlowSchemaConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent { + public V1beta2FlowSchemaConditionFluentImpl() {} - /** - * Generated - */ -public class V1beta2FlowSchemaConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent{ - public V1beta2FlowSchemaConditionFluentImpl() { - } - public V1beta2FlowSchemaConditionFluentImpl(io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition instance) { + public V1beta2FlowSchemaConditionFluentImpl( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,103 +30,119 @@ public V1beta2FlowSchemaConditionFluentImpl(io.kubernetes.client.openapi.models. this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta2FlowSchemaConditionFluentImpl that = (V1beta2FlowSchemaConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaFluent.java index d847d821ce..c1712e6756 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaFluent.java @@ -1,93 +1,148 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2FlowSchemaFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta2FlowSchemaFluent< + A extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec getSpec(); + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec spec); + public java.lang.Boolean hasSpec(); + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec item); + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested editSpec(); + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec item); - + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus getStatus(); + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus item); + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaFluentImpl.java index a520a105d1..1ea8919b16 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta2FlowSchemaFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent { + public V1beta2FlowSchemaFluentImpl() {} - /** - * Generated - */ -public class V1beta2FlowSchemaFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent{ - public V1beta2FlowSchemaFluentImpl() { - } - public V1beta2FlowSchemaFluentImpl(io.kubernetes.client.openapi.models.V1beta2FlowSchema instance) { + public V1beta2FlowSchemaFluentImpl( + io.kubernetes.client.openapi.models.V1beta2FlowSchema instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,303 @@ public V1beta2FlowSchemaFluentImpl(io.kubernetes.client.openapi.models.V1beta2Fl this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecBuilder spec; private io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested withNewMetadata() { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested + withNewMetadata() { return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluentImpl.MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluentImpl.MetadataNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested withNewSpec() { return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluentImpl.SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec item) { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested withNewSpecLike( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec item) { return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluentImpl.SpecNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested editSpec() { return withNewSpecLike(getSpec()); } + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecBuilder().build()); + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested withNewStatus() { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested + withNewStatus() { return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluentImpl.StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus item) { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus item) { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluentImpl.StatusNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta2FlowSchemaFluentImpl that = (V1beta2FlowSchemaFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1beta2FlowSchemaFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecBuilder(this, item); } + SpecNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecBuilder builder; + public N and() { return (N) V1beta2FlowSchemaFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent.StatusNested, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusBuilder(this, item); } + StatusNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusBuilder builder; + public N and() { return (N) V1beta2FlowSchemaFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaListBuilder.java index 0c7d98366d..44c125c528 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2FlowSchemaListBuilder extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2FlowSchemaListBuilder + extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaList, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaListBuilder> { public V1beta2FlowSchemaListBuilder() { this(false); } + public V1beta2FlowSchemaListBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2FlowSchemaList(), validationEnabled); } - public V1beta2FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent fluent) { + + public V1beta2FlowSchemaListBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent fluent) { this(fluent, false); } - public V1beta2FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2FlowSchemaListBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2FlowSchemaList(), validationEnabled); } - public V1beta2FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent fluent,io.kubernetes.client.openapi.models.V1beta2FlowSchemaList instance) { + + public V1beta2FlowSchemaListBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent fluent, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaList instance) { this(fluent, instance, false); } - public V1beta2FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent fluent,io.kubernetes.client.openapi.models.V1beta2FlowSchemaList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2FlowSchemaListBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent fluent, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1beta2FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta2F fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaList instance) { - this(instance,false); + + public V1beta2FlowSchemaListBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaList instance) { + this(instance, false); } - public V1beta2FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2FlowSchemaListBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1beta2FlowSchemaListBuilder(io.kubernetes.client.openapi.models.V1beta2F this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaList build() { V1beta2FlowSchemaList buildable = new V1beta2FlowSchemaList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1beta2FlowSchemaList build() { buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2FlowSchemaListBuilder that = (V1beta2FlowSchemaListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaListFluent.java index be01a1cf1f..694f2b5760 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaListFluent.java @@ -1,95 +1,159 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2FlowSchemaListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta2FlowSchemaListFluent< + A extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchema item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchema item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2FlowSchema item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2FlowSchema item); + public A addToItems(io.kubernetes.client.openapi.models.V1beta2FlowSchema... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta2FlowSchema... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); + public io.kubernetes.client.openapi.models.V1beta2FlowSchema buildItem(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta2FlowSchema buildFirstItem(); + public io.kubernetes.client.openapi.models.V1beta2FlowSchema buildLastItem(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchema buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchema buildMatchingItem( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate); + public A withItems(java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V1beta2FlowSchema... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta2FlowSchema item); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchema item); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta2FlowSchema item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2FlowSchema item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested editItem( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent>{ + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluent< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaListFluentImpl.java index e20cae26a7..98fb0310c8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta2FlowSchemaListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent{ - public V1beta2FlowSchemaListFluentImpl() { - } - public V1beta2FlowSchemaListFluentImpl(io.kubernetes.client.openapi.models.V1beta2FlowSchemaList instance) { + +/** Generated */ +public class V1beta2FlowSchemaListFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent { + public V1beta2FlowSchemaListFluentImpl() {} + + public V1beta2FlowSchemaListFluentImpl( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,126 @@ public V1beta2FlowSchemaListFluentImpl(io.kubernetes.client.openapi.models.V1bet this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; private java.util.ArrayList items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchema item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2FlowSchema item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchema item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2FlowSchema item) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V1beta2FlowSchema... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2FlowSchema item : items) {io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta2FlowSchema item : items) { + io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2FlowSchema item : items) {io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta2FlowSchema item : items) { + io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V1beta2FlowSchema... items) { - for (io.kubernetes.client.openapi.models.V1beta2FlowSchema item : items) {io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta2FlowSchema item : items) { + io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta2FlowSchema item : items) {io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta2FlowSchema item : items) { + io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder = each.next(); @@ -87,174 +159,282 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } + public java.util.List buildItems() { return items != null ? build(items) : null; } + public io.kubernetes.client.openapi.models.V1beta2FlowSchema buildItem(java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta2FlowSchema buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta2FlowSchema buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchema buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta2FlowSchema buildMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta2FlowSchema item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta2FlowSchema item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V1beta2FlowSchema... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1beta2FlowSchema item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1beta2FlowSchema item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta2FlowSchema item) { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V1beta2FlowSchema item) { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluentImpl.ItemsNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchema item) { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2FlowSchema item) { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluentImpl.ItemsNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested editItem( + java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta2FlowSchemaListFluentImpl that = (V1beta2FlowSchemaListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchema item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.ItemsNested, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2FlowSchema item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2FlowSchemaBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta2FlowSchemaListFluentImpl.this.setToItems(index,builder.build()); + return (N) V1beta2FlowSchemaListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaListFluent.MetadataNested, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1beta2FlowSchemaListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaSpecBuilder.java index f48fedb2a8..5cecec5be8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2FlowSchemaSpecBuilder extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2FlowSchemaSpecBuilder + extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecBuilder> { public V1beta2FlowSchemaSpecBuilder() { this(false); } + public V1beta2FlowSchemaSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2FlowSchemaSpec(), validationEnabled); } - public V1beta2FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent fluent) { + + public V1beta2FlowSchemaSpecBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent fluent) { this(fluent, false); } - public V1beta2FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2FlowSchemaSpecBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2FlowSchemaSpec(), validationEnabled); } - public V1beta2FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec instance) { + + public V1beta2FlowSchemaSpecBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec instance) { this(fluent, instance, false); } - public V1beta2FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2FlowSchemaSpecBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDistinguisherMethod(instance.getDistinguisherMethod()); fluent.withMatchingPrecedence(instance.getMatchingPrecedence()); @@ -29,13 +56,18 @@ public V1beta2FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta2F fluent.withRules(instance.getRules()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec instance) { - this(instance,false); + + public V1beta2FlowSchemaSpecBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec instance) { + this(instance, false); } - public V1beta2FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2FlowSchemaSpecBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDistinguisherMethod(instance.getDistinguisherMethod()); this.withMatchingPrecedence(instance.getMatchingPrecedence()); @@ -44,10 +76,12 @@ public V1beta2FlowSchemaSpecBuilder(io.kubernetes.client.openapi.models.V1beta2F this.withRules(instance.getRules()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec build() { V1beta2FlowSchemaSpec buildable = new V1beta2FlowSchemaSpec(); buildable.setDistinguisherMethod(fluent.getDistinguisherMethod()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec build() { buildable.setRules(fluent.getRules()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2FlowSchemaSpecBuilder that = (V1beta2FlowSchemaSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaSpecFluent.java index c9cd7125d6..a8446fd22e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaSpecFluent.java @@ -1,100 +1,228 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1beta2FlowSchemaSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1beta2FlowSchemaSpecFluent< + A extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildDistinguisherMethod instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod getDistinguisherMethod(); - public io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod buildDistinguisherMethod(); - public A withDistinguisherMethod(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod distinguisherMethod); + public io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod + getDistinguisherMethod(); + + public io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod + buildDistinguisherMethod(); + + public A withDistinguisherMethod( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod distinguisherMethod); + public java.lang.Boolean hasDistinguisherMethod(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested withNewDistinguisherMethod(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested withNewDistinguisherMethodLike(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod item); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested editDistinguisherMethod(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested editOrNewDistinguisherMethod(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested editOrNewDistinguisherMethodLike(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + withNewDistinguisherMethod(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + withNewDistinguisherMethodLike( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + editDistinguisherMethod(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + editOrNewDistinguisherMethod(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + editOrNewDistinguisherMethodLike( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod item); + public java.lang.Integer getMatchingPrecedence(); + public A withMatchingPrecedence(java.lang.Integer matchingPrecedence); + public java.lang.Boolean hasMatchingPrecedence(); - + /** * This method has been deprecated, please use method buildPriorityLevelConfiguration instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference getPriorityLevelConfiguration(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference buildPriorityLevelConfiguration(); - public A withPriorityLevelConfiguration(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference priorityLevelConfiguration); + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference + getPriorityLevelConfiguration(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference + buildPriorityLevelConfiguration(); + + public A withPriorityLevelConfiguration( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference + priorityLevelConfiguration); + public java.lang.Boolean hasPriorityLevelConfiguration(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.PriorityLevelConfigurationNested withNewPriorityLevelConfiguration(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.PriorityLevelConfigurationNested withNewPriorityLevelConfigurationLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference item); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.PriorityLevelConfigurationNested editPriorityLevelConfiguration(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.PriorityLevelConfigurationNested editOrNewPriorityLevelConfiguration(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.PriorityLevelConfigurationNested editOrNewPriorityLevelConfigurationLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference item); - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item); - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + withNewPriorityLevelConfiguration(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + withNewPriorityLevelConfigurationLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + editPriorityLevelConfiguration(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + editOrNewPriorityLevelConfiguration(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + editOrNewPriorityLevelConfigurationLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference item); + + public A addToRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item); + + public A setToRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item); + public A addToRules(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects... items); - public A addAllToRules(java.util.Collection items); - public A removeFromRules(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects... items); - public A removeAllFromRules(java.util.Collection items); - public A removeMatchingFromRules(java.util.function.Predicate predicate); - + + public A addAllToRules( + java.util.Collection + items); + + public A removeFromRules( + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects... items); + + public A removeAllFromRules( + java.util.Collection + items); + + public A removeMatchingFromRules( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder> + predicate); + /** * This method has been deprecated, please use method buildRules instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getRules(); - public java.util.List buildRules(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects buildRule(java.lang.Integer index); + public java.util.List + getRules(); + + public java.util.List + buildRules(); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects buildRule( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects buildFirstRule(); + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects buildLastRule(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects buildMatchingRule(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate); - public A withRules(java.util.List rules); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects buildMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder> + predicate); + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder> + predicate); + + public A withRules( + java.util.List rules); + public A withRules(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects... rules); + public java.lang.Boolean hasRules(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested addNewRule(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested editRule(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested editFirstRule(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested editLastRule(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate); - public interface DistinguisherMethodNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent>{ + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested + addNewRule(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested + addNewRuleLike(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested + setNewRuleLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested editRule( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested + editFirstRule(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested + editLastRule(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested + editMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder> + predicate); + + public interface DistinguisherMethodNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluent< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .DistinguisherMethodNested< + N>> { public N and(); + public N endDistinguisherMethod(); - } - public interface PriorityLevelConfigurationNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent>{ + + public interface PriorityLevelConfigurationNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + N>> { public N and(); + public N endPriorityLevelConfiguration(); - } - public interface RulesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent>{ + + public interface RulesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested> { public N and(); + public N endRule(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaSpecFluentImpl.java index 134a2878af..04a1ed4a15 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaSpecFluentImpl.java @@ -1,25 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta2FlowSchemaSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent{ - public V1beta2FlowSchemaSpecFluentImpl() { - } - public V1beta2FlowSchemaSpecFluentImpl(io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec instance) { + +/** Generated */ +public class V1beta2FlowSchemaSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent { + public V1beta2FlowSchemaSpecFluentImpl() {} + + public V1beta2FlowSchemaSpecFluentImpl( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpec instance) { this.withDistinguisherMethod(instance.getDistinguisherMethod()); this.withMatchingPrecedence(instance.getMatchingPrecedence()); @@ -27,258 +31,554 @@ public V1beta2FlowSchemaSpecFluentImpl(io.kubernetes.client.openapi.models.V1bet this.withPriorityLevelConfiguration(instance.getPriorityLevelConfiguration()); this.withRules(instance.getRules()); - } - private io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodBuilder distinguisherMethod; + + private io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodBuilder + distinguisherMethod; private java.lang.Integer matchingPrecedence; - private io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceBuilder priorityLevelConfiguration; - private java.util.ArrayList rules; - + private io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceBuilder + priorityLevelConfiguration; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder> + rules; + /** * This method has been deprecated, please use method buildDistinguisherMethod instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod getDistinguisherMethod() { - return this.distinguisherMethod!=null ?this.distinguisherMethod.build():null; + public io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod + getDistinguisherMethod() { + return this.distinguisherMethod != null ? this.distinguisherMethod.build() : null; } - public io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod buildDistinguisherMethod() { - return this.distinguisherMethod!=null ?this.distinguisherMethod.build():null; + + public io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod + buildDistinguisherMethod() { + return this.distinguisherMethod != null ? this.distinguisherMethod.build() : null; } - public A withDistinguisherMethod(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod distinguisherMethod) { + + public A withDistinguisherMethod( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod distinguisherMethod) { _visitables.get("distinguisherMethod").remove(this.distinguisherMethod); - if (distinguisherMethod!=null){ this.distinguisherMethod= new io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodBuilder(distinguisherMethod); _visitables.get("distinguisherMethod").add(this.distinguisherMethod);} return (A) this; + if (distinguisherMethod != null) { + this.distinguisherMethod = + new io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodBuilder( + distinguisherMethod); + _visitables.get("distinguisherMethod").add(this.distinguisherMethod); + } + return (A) this; } + public java.lang.Boolean hasDistinguisherMethod() { return this.distinguisherMethod != null; } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested withNewDistinguisherMethod() { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl.DistinguisherMethodNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + withNewDistinguisherMethod() { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl + .DistinguisherMethodNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested withNewDistinguisherMethodLike(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod item) { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl.DistinguisherMethodNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + withNewDistinguisherMethodLike( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod item) { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl + .DistinguisherMethodNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested editDistinguisherMethod() { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + editDistinguisherMethod() { return withNewDistinguisherMethodLike(getDistinguisherMethod()); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested editOrNewDistinguisherMethod() { - return withNewDistinguisherMethodLike(getDistinguisherMethod() != null ? getDistinguisherMethod(): new io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + editOrNewDistinguisherMethod() { + return withNewDistinguisherMethodLike( + getDistinguisherMethod() != null + ? getDistinguisherMethod() + : new io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested editOrNewDistinguisherMethodLike(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod item) { - return withNewDistinguisherMethodLike(getDistinguisherMethod() != null ? getDistinguisherMethod(): item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested< + A> + editOrNewDistinguisherMethodLike( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod item) { + return withNewDistinguisherMethodLike( + getDistinguisherMethod() != null ? getDistinguisherMethod() : item); } + public java.lang.Integer getMatchingPrecedence() { return this.matchingPrecedence; } + public A withMatchingPrecedence(java.lang.Integer matchingPrecedence) { - this.matchingPrecedence=matchingPrecedence; return (A) this; + this.matchingPrecedence = matchingPrecedence; + return (A) this; } + public java.lang.Boolean hasMatchingPrecedence() { return this.matchingPrecedence != null; } - + /** * This method has been deprecated, please use method buildPriorityLevelConfiguration instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference getPriorityLevelConfiguration() { - return this.priorityLevelConfiguration!=null ?this.priorityLevelConfiguration.build():null; + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference + getPriorityLevelConfiguration() { + return this.priorityLevelConfiguration != null ? this.priorityLevelConfiguration.build() : null; } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference buildPriorityLevelConfiguration() { - return this.priorityLevelConfiguration!=null ?this.priorityLevelConfiguration.build():null; + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference + buildPriorityLevelConfiguration() { + return this.priorityLevelConfiguration != null ? this.priorityLevelConfiguration.build() : null; } - public A withPriorityLevelConfiguration(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference priorityLevelConfiguration) { + + public A withPriorityLevelConfiguration( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference + priorityLevelConfiguration) { _visitables.get("priorityLevelConfiguration").remove(this.priorityLevelConfiguration); - if (priorityLevelConfiguration!=null){ this.priorityLevelConfiguration= new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceBuilder(priorityLevelConfiguration); _visitables.get("priorityLevelConfiguration").add(this.priorityLevelConfiguration);} return (A) this; + if (priorityLevelConfiguration != null) { + this.priorityLevelConfiguration = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceBuilder( + priorityLevelConfiguration); + _visitables.get("priorityLevelConfiguration").add(this.priorityLevelConfiguration); + } + return (A) this; } + public java.lang.Boolean hasPriorityLevelConfiguration() { return this.priorityLevelConfiguration != null; } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.PriorityLevelConfigurationNested withNewPriorityLevelConfiguration() { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl.PriorityLevelConfigurationNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + withNewPriorityLevelConfiguration() { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl + .PriorityLevelConfigurationNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.PriorityLevelConfigurationNested withNewPriorityLevelConfigurationLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference item) { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl.PriorityLevelConfigurationNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + withNewPriorityLevelConfigurationLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference item) { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl + .PriorityLevelConfigurationNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.PriorityLevelConfigurationNested editPriorityLevelConfiguration() { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + editPriorityLevelConfiguration() { return withNewPriorityLevelConfigurationLike(getPriorityLevelConfiguration()); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.PriorityLevelConfigurationNested editOrNewPriorityLevelConfiguration() { - return withNewPriorityLevelConfigurationLike(getPriorityLevelConfiguration() != null ? getPriorityLevelConfiguration(): new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + editOrNewPriorityLevelConfiguration() { + return withNewPriorityLevelConfigurationLike( + getPriorityLevelConfiguration() != null + ? getPriorityLevelConfiguration() + : new io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.PriorityLevelConfigurationNested editOrNewPriorityLevelConfigurationLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference item) { - return withNewPriorityLevelConfigurationLike(getPriorityLevelConfiguration() != null ? getPriorityLevelConfiguration(): item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + A> + editOrNewPriorityLevelConfigurationLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference item) { + return withNewPriorityLevelConfigurationLike( + getPriorityLevelConfiguration() != null ? getPriorityLevelConfiguration() : item); } - public A addToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(item);_visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder);this.rules.add(index >= 0 ? index : rules.size(), builder); return (A)this; + + public A addToRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(item); + _visitables.get("rules").add(index >= 0 ? index : _visitables.get("rules").size(), builder); + this.rules.add(index >= 0 ? index : rules.size(), builder); + return (A) this; } - public A setToRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(item); - if (index < 0 || index >= _visitables.get("rules").size()) { _visitables.get("rules").add(builder); } else { _visitables.get("rules").set(index, builder);} - if (index < 0 || index >= rules.size()) { rules.add(builder); } else { rules.set(index, builder);} - return (A)this; + + public A setToRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(item); + if (index < 0 || index >= _visitables.get("rules").size()) { + _visitables.get("rules").add(builder); + } else { + _visitables.get("rules").set(index, builder); + } + if (index < 0 || index >= rules.size()) { + rules.add(builder); + } else { + rules.set(index, builder); + } + return (A) this; } + public A addToRules(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects... items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item : items) {io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item : items) { + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } - public A addAllToRules(java.util.Collection items) { - if (this.rules == null) {this.rules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item : items) {io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(item);_visitables.get("rules").add(builder);this.rules.add(builder);} return (A)this; + + public A addAllToRules( + java.util.Collection + items) { + if (this.rules == null) { + this.rules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item : items) { + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(item); + _visitables.get("rules").add(builder); + this.rules.add(builder); + } + return (A) this; } - public A removeFromRules(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects... items) { - for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item : items) {io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + + public A removeFromRules( + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects... items) { + for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item : items) { + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeAllFromRules(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item : items) {io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(item);_visitables.get("rules").remove(builder);if (this.rules != null) {this.rules.remove(builder);}} return (A)this; + + public A removeAllFromRules( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item : items) { + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(item); + _visitables.get("rules").remove(builder); + if (this.rules != null) { + this.rules.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromRules(java.util.function.Predicate predicate) { + + public A removeMatchingFromRules( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder> + predicate) { if (rules == null) return (A) this; - final Iterator each = rules.iterator(); + final Iterator each = + rules.iterator(); final List visitables = _visitables.get("rules"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildRules instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getRules() { + public java.util.List + getRules() { return rules != null ? build(rules) : null; } - public java.util.List buildRules() { + + public java.util.List + buildRules() { return rules != null ? build(rules) : null; } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects buildRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects buildRule( + java.lang.Integer index) { return this.rules.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects buildFirstRule() { return this.rules.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects buildLastRule() { return this.rules.get(rules.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects buildMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder item: rules) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects buildMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder item : rules) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder item: rules) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder item : rules) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withRules(java.util.List rules) { - if (this.rules != null) { _visitables.get("rules").removeAll(this.rules);} - if (rules != null) {this.rules = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item : rules){this.addToRules(item);}} else { this.rules = null;} return (A) this; + + public A withRules( + java.util.List rules) { + if (this.rules != null) { + _visitables.get("rules").removeAll(this.rules); + } + if (rules != null) { + this.rules = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item : rules) { + this.addToRules(item); + } + } else { + this.rules = null; + } + return (A) this; } + public A withRules(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects... rules) { - if (this.rules != null) {this.rules.clear();} - if (rules != null) {for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item :rules){ this.addToRules(item);}} return (A) this; + if (this.rules != null) { + this.rules.clear(); + } + if (rules != null) { + for (io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item : rules) { + this.addToRules(item); + } + } + return (A) this; } + public java.lang.Boolean hasRules() { return rules != null && !rules.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested addNewRule() { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl.RulesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested + addNewRule() { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl + .RulesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested addNewRuleLike(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item) { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl.RulesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested + addNewRuleLike(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item) { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl.RulesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested setNewRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item) { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl.RulesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested + setNewRuleLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item) { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluentImpl.RulesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested editRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested editRule( + java.lang.Integer index) { if (rules.size() <= index) throw new RuntimeException("Can't edit rules. Index exceeds size."); return setNewRuleLike(index, buildRule(index)); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested editFirstRule() { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested + editFirstRule() { if (rules.size() == 0) throw new RuntimeException("Can't edit first rules. The list is empty."); return setNewRuleLike(0, buildRule(0)); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested editLastRule() { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested + editLastRule() { int index = rules.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last rules. The list is empty."); return setNewRuleLike(index, buildRule(index)); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested editMatchingRule(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested + editMatchingRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested,io.kubernetes.client.fluent.Nested{ - DistinguisherMethodNestedImpl(io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodBuilder(this, item); + + public class DistinguisherMethodNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.DistinguisherMethodNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .DistinguisherMethodNested< + N>, + io.kubernetes.client.fluent.Nested { + DistinguisherMethodNestedImpl( + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethod item) { + this.builder = + new io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodBuilder(this, item); } + DistinguisherMethodNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2FlowDistinguisherMethodBuilder builder; + public N and() { return (N) V1beta2FlowSchemaSpecFluentImpl.this.withDistinguisherMethod(builder.build()); } + public N endDistinguisherMethod() { return and(); } - } - public class PriorityLevelConfigurationNestedImpl extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.PriorityLevelConfigurationNested,io.kubernetes.client.fluent.Nested{ - PriorityLevelConfigurationNestedImpl(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceBuilder(this, item); + + public class PriorityLevelConfigurationNestedImpl + extends io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent + .PriorityLevelConfigurationNested< + N>, + io.kubernetes.client.fluent.Nested { + PriorityLevelConfigurationNestedImpl( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference item) { + this.builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceBuilder( + this, item); } + PriorityLevelConfigurationNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceBuilder( + this); } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceBuilder builder; + public N and() { - return (N) V1beta2FlowSchemaSpecFluentImpl.this.withPriorityLevelConfiguration(builder.build()); + return (N) + V1beta2FlowSchemaSpecFluentImpl.this.withPriorityLevelConfiguration(builder.build()); } + public N endPriorityLevelConfiguration() { return and(); } - } - public class RulesNestedImpl extends io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested,io.kubernetes.client.fluent.Nested{ - RulesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item) { + + public class RulesNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested> + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaSpecFluent.RulesNested, + io.kubernetes.client.fluent.Nested { + RulesNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(this, item); } + RulesNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta2FlowSchemaSpecFluentImpl.this.setToRules(index,builder.build()); + return (N) V1beta2FlowSchemaSpecFluentImpl.this.setToRules(index, builder.build()); } + public N endRule() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaStatusBuilder.java index e020f00616..9ba2e75fb3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaStatusBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2FlowSchemaStatusBuilder extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2FlowSchemaStatusBuilder + extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusBuilder> { public V1beta2FlowSchemaStatusBuilder() { this(false); } + public V1beta2FlowSchemaStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2FlowSchemaStatus(), validationEnabled); } - public V1beta2FlowSchemaStatusBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent fluent) { + + public V1beta2FlowSchemaStatusBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent fluent) { this(fluent, false); } - public V1beta2FlowSchemaStatusBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2FlowSchemaStatusBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2FlowSchemaStatus(), validationEnabled); } - public V1beta2FlowSchemaStatusBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent fluent,io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus instance) { + + public V1beta2FlowSchemaStatusBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent fluent, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus instance) { this(fluent, instance, false); } - public V1beta2FlowSchemaStatusBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent fluent,io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2FlowSchemaStatusBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent fluent, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditions(instance.getConditions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2FlowSchemaStatusBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus instance) { - this(instance,false); + + public V1beta2FlowSchemaStatusBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus instance) { + this(instance, false); } - public V1beta2FlowSchemaStatusBuilder(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2FlowSchemaStatusBuilder( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditions(instance.getConditions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus build() { V1beta2FlowSchemaStatus buildable = new V1beta2FlowSchemaStatus(); buildable.setConditions(fluent.getConditions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2FlowSchemaStatusBuilder that = (V1beta2FlowSchemaStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaStatusFluent.java index e7f871b601..d561798a25 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaStatusFluent.java @@ -1,57 +1,113 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2FlowSchemaStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item); +/** Generated */ +public interface V1beta2FlowSchemaStatusFluent< + A extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item); + + public A setToConditions( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item); + public A addToConditions(io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition... items); - public A addAllToConditions(java.util.Collection items); - public A removeFromConditions(io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - + + public A addAllToConditions( + java.util.Collection items); + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition... items); + + public A removeAllFromConditions( + java.util.Collection items); + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder> + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition buildCondition(java.lang.Integer index); + public java.util.List + getConditions(); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition buildCondition( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition buildFirstCondition(); + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); - public A withConditions(io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition... conditions); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder> + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder> + predicate); + + public A withConditions( + java.util.List conditions); + + public A withConditions( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent>{ + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder> + predicate); + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluent< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaStatusFluentImpl.java index ce3810270b..583d114a55 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2FlowSchemaStatusFluentImpl.java @@ -1,57 +1,140 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1beta2FlowSchemaStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent{ - public V1beta2FlowSchemaStatusFluentImpl() { - } - public V1beta2FlowSchemaStatusFluentImpl(io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus instance) { - this.withConditions(instance.getConditions()); +/** Generated */ +public class V1beta2FlowSchemaStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent { + public V1beta2FlowSchemaStatusFluentImpl() {} + public V1beta2FlowSchemaStatusFluentImpl( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatus instance) { + this.withConditions(instance.getConditions()); } - private java.util.ArrayList conditions; - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + private java.util.ArrayList + conditions; + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } - public A addToConditions(io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item : items) {io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addToConditions( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition... items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item : items) { + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item : items) {io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item : items) { + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition... items) { - for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item : items) {io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition... items) { + for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item : items) { + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item : items) {io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item : items) { + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder> + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator each = + conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder = each.next(); @@ -60,104 +143,194 @@ public A removeMatchingFromConditions(java.util.function.Predicate getConditions() { + public java.util.List + getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition buildFirstCondition() { return this.conditions.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item : conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } - public A withConditions(io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item :conditions){ this.addToConditions(item);}} return (A) this; + + public A withConditions( + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition... conditions) { + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item : conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item) { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + addNewConditionLike(io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item) { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item) { - return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item) { + return new io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionFluentImpl< + io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested> + implements io.kubernetes.client.openapi.models.V1beta2FlowSchemaStatusFluent.ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2FlowSchemaCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(this, item); } + ConditionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2FlowSchemaConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta2FlowSchemaStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) V1beta2FlowSchemaStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2GroupSubjectBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2GroupSubjectBuilder.java index baafd44da9..3e897db515 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2GroupSubjectBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2GroupSubjectBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2GroupSubjectBuilder extends io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2GroupSubjectBuilder + extends io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta2GroupSubjectBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2GroupSubject, + io.kubernetes.client.openapi.models.V1beta2GroupSubjectBuilder> { public V1beta2GroupSubjectBuilder() { this(false); } + public V1beta2GroupSubjectBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2GroupSubject(), validationEnabled); } - public V1beta2GroupSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent fluent) { + + public V1beta2GroupSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent fluent) { this(fluent, false); } - public V1beta2GroupSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2GroupSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2GroupSubject(), validationEnabled); } - public V1beta2GroupSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta2GroupSubject instance) { + + public V1beta2GroupSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta2GroupSubject instance) { this(fluent, instance, false); } - public V1beta2GroupSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta2GroupSubject instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2GroupSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta2GroupSubject instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2GroupSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2GroupSubject instance) { - this(instance,false); + + public V1beta2GroupSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2GroupSubject instance) { + this(instance, false); } - public V1beta2GroupSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2GroupSubject instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2GroupSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2GroupSubject instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2GroupSubject build() { V1beta2GroupSubject buildable = new V1beta2GroupSubject(); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2GroupSubjectBuilder that = (V1beta2GroupSubjectBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2GroupSubjectFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2GroupSubjectFluent.java index 89938ff069..e6dec5d67d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2GroupSubjectFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2GroupSubjectFluent.java @@ -1,23 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2GroupSubjectFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta2GroupSubjectFluent< + A extends io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2GroupSubjectFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2GroupSubjectFluentImpl.java index 72a29a312a..03577cd012 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2GroupSubjectFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2GroupSubjectFluentImpl.java @@ -1,48 +1,59 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta2GroupSubjectFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent{ - public V1beta2GroupSubjectFluentImpl() { - } - public V1beta2GroupSubjectFluentImpl(io.kubernetes.client.openapi.models.V1beta2GroupSubject instance) { - this.withName(instance.getName()); +/** Generated */ +public class V1beta2GroupSubjectFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent { + public V1beta2GroupSubjectFluentImpl() {} + public V1beta2GroupSubjectFluentImpl( + io.kubernetes.client.openapi.models.V1beta2GroupSubject instance) { + this.withName(instance.getName()); } + private java.lang.String name; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta2GroupSubjectFluentImpl that = (V1beta2GroupSubjectFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, super.hashCode()); + return java.util.Objects.hash(name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitResponseBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitResponseBuilder.java index e6f5b8d815..67a3127f80 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitResponseBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitResponseBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2LimitResponseBuilder extends io.kubernetes.client.openapi.models.V1beta2LimitResponseFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2LimitResponseBuilder + extends io.kubernetes.client.openapi.models.V1beta2LimitResponseFluentImpl< + io.kubernetes.client.openapi.models.V1beta2LimitResponseBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2LimitResponse, + io.kubernetes.client.openapi.models.V1beta2LimitResponseBuilder> { public V1beta2LimitResponseBuilder() { this(false); } + public V1beta2LimitResponseBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2LimitResponse(), validationEnabled); } - public V1beta2LimitResponseBuilder(io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent fluent) { + + public V1beta2LimitResponseBuilder( + io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent fluent) { this(fluent, false); } - public V1beta2LimitResponseBuilder(io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2LimitResponseBuilder( + io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2LimitResponse(), validationEnabled); } - public V1beta2LimitResponseBuilder(io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent fluent,io.kubernetes.client.openapi.models.V1beta2LimitResponse instance) { + + public V1beta2LimitResponseBuilder( + io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent fluent, + io.kubernetes.client.openapi.models.V1beta2LimitResponse instance) { this(fluent, instance, false); } - public V1beta2LimitResponseBuilder(io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent fluent,io.kubernetes.client.openapi.models.V1beta2LimitResponse instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2LimitResponseBuilder( + io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent fluent, + io.kubernetes.client.openapi.models.V1beta2LimitResponse instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withQueuing(instance.getQueuing()); fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2LimitResponseBuilder(io.kubernetes.client.openapi.models.V1beta2LimitResponse instance) { - this(instance,false); + + public V1beta2LimitResponseBuilder( + io.kubernetes.client.openapi.models.V1beta2LimitResponse instance) { + this(instance, false); } - public V1beta2LimitResponseBuilder(io.kubernetes.client.openapi.models.V1beta2LimitResponse instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2LimitResponseBuilder( + io.kubernetes.client.openapi.models.V1beta2LimitResponse instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withQueuing(instance.getQueuing()); this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2LimitResponse build() { V1beta2LimitResponse buildable = new V1beta2LimitResponse(); buildable.setQueuing(fluent.getQueuing()); buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2LimitResponseBuilder that = (V1beta2LimitResponseBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitResponseFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitResponseFluent.java index 550090fcdc..6373338d65 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitResponseFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitResponseFluent.java @@ -1,44 +1,67 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2LimitResponseFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1beta2LimitResponseFluent< + A extends io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildQueuing instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration getQueuing(); + public io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration buildQueuing(); + public A withQueuing(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration queuing); + public java.lang.Boolean hasQueuing(); - public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested withNewQueuing(); - public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested withNewQueuingLike(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration item); - public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested editQueuing(); - public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested editOrNewQueuing(); - public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested editOrNewQueuingLike(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration item); + + public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested + withNewQueuing(); + + public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested + withNewQueuingLike(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration item); + + public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested + editQueuing(); + + public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested + editOrNewQueuing(); + + public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested + editOrNewQueuingLike(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration item); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface QueuingNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent>{ + + public interface QueuingNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent< + io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested> { public N and(); + public N endQueuing(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitResponseFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitResponseFluentImpl.java index efa1b9331c..059949c75f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitResponseFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitResponseFluentImpl.java @@ -1,103 +1,147 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta2LimitResponseFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent { + public V1beta2LimitResponseFluentImpl() {} - /** - * Generated - */ -public class V1beta2LimitResponseFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent{ - public V1beta2LimitResponseFluentImpl() { - } - public V1beta2LimitResponseFluentImpl(io.kubernetes.client.openapi.models.V1beta2LimitResponse instance) { + public V1beta2LimitResponseFluentImpl( + io.kubernetes.client.openapi.models.V1beta2LimitResponse instance) { this.withQueuing(instance.getQueuing()); this.withType(instance.getType()); - } + private io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationBuilder queuing; private java.lang.String type; - + /** * This method has been deprecated, please use method buildQueuing instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration getQueuing() { - return this.queuing!=null ?this.queuing.build():null; + return this.queuing != null ? this.queuing.build() : null; } + public io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration buildQueuing() { - return this.queuing!=null ?this.queuing.build():null; + return this.queuing != null ? this.queuing.build() : null; } + public A withQueuing(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration queuing) { _visitables.get("queuing").remove(this.queuing); - if (queuing!=null){ this.queuing= new io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationBuilder(queuing); _visitables.get("queuing").add(this.queuing);} return (A) this; + if (queuing != null) { + this.queuing = + new io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationBuilder(queuing); + _visitables.get("queuing").add(this.queuing); + } + return (A) this; } + public java.lang.Boolean hasQueuing() { return this.queuing != null; } - public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested withNewQueuing() { - return new io.kubernetes.client.openapi.models.V1beta2LimitResponseFluentImpl.QueuingNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested + withNewQueuing() { + return new io.kubernetes.client.openapi.models.V1beta2LimitResponseFluentImpl + .QueuingNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested withNewQueuingLike(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration item) { - return new io.kubernetes.client.openapi.models.V1beta2LimitResponseFluentImpl.QueuingNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested + withNewQueuingLike(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration item) { + return new io.kubernetes.client.openapi.models.V1beta2LimitResponseFluentImpl.QueuingNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested editQueuing() { + + public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested + editQueuing() { return withNewQueuingLike(getQueuing()); } - public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested editOrNewQueuing() { - return withNewQueuingLike(getQueuing() != null ? getQueuing(): new io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested + editOrNewQueuing() { + return withNewQueuingLike( + getQueuing() != null + ? getQueuing() + : new io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested editOrNewQueuingLike(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration item) { - return withNewQueuingLike(getQueuing() != null ? getQueuing(): item); + + public io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested + editOrNewQueuingLike(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration item) { + return withNewQueuingLike(getQueuing() != null ? getQueuing() : item); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta2LimitResponseFluentImpl that = (V1beta2LimitResponseFluentImpl) o; - if (queuing != null ? !queuing.equals(that.queuing) :that.queuing != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (queuing != null ? !queuing.equals(that.queuing) : that.queuing != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(queuing, type, super.hashCode()); + return java.util.Objects.hash(queuing, type, super.hashCode()); } - public class QueuingNestedImpl extends io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested,io.kubernetes.client.fluent.Nested{ + + public class QueuingNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested> + implements io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent.QueuingNested, + io.kubernetes.client.fluent.Nested { QueuingNestedImpl(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationBuilder(this, item); } + QueuingNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationBuilder builder; + public N and() { return (N) V1beta2LimitResponseFluentImpl.this.withQueuing(builder.build()); } + public N endQueuing() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitedPriorityLevelConfigurationBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitedPriorityLevelConfigurationBuilder.java index 7cc20c869f..624845dbfe 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitedPriorityLevelConfigurationBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitedPriorityLevelConfigurationBuilder.java @@ -1,63 +1,105 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2LimitedPriorityLevelConfigurationBuilder extends io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2LimitedPriorityLevelConfigurationBuilder + extends io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration, + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationBuilder> { public V1beta2LimitedPriorityLevelConfigurationBuilder() { this(false); } + public V1beta2LimitedPriorityLevelConfigurationBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2LimitedPriorityLevelConfiguration(), validationEnabled); } - public V1beta2LimitedPriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent fluent) { + + public V1beta2LimitedPriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + fluent) { this(fluent, false); } - public V1beta2LimitedPriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2LimitedPriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2LimitedPriorityLevelConfiguration(), validationEnabled); } - public V1beta2LimitedPriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration instance) { + + public V1beta2LimitedPriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration instance) { this(fluent, instance, false); } - public V1beta2LimitedPriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2LimitedPriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAssuredConcurrencyShares(instance.getAssuredConcurrencyShares()); fluent.withLimitResponse(instance.getLimitResponse()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2LimitedPriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration instance) { - this(instance,false); + + public V1beta2LimitedPriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration instance) { + this(instance, false); } - public V1beta2LimitedPriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2LimitedPriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAssuredConcurrencyShares(instance.getAssuredConcurrencyShares()); this.withLimitResponse(instance.getLimitResponse()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration build() { - V1beta2LimitedPriorityLevelConfiguration buildable = new V1beta2LimitedPriorityLevelConfiguration(); + V1beta2LimitedPriorityLevelConfiguration buildable = + new V1beta2LimitedPriorityLevelConfiguration(); buildable.setAssuredConcurrencyShares(fluent.getAssuredConcurrencyShares()); buildable.setLimitResponse(fluent.getLimitResponse()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1beta2LimitedPriorityLevelConfigurationBuilder that = (V1beta2LimitedPriorityLevelConfigurationBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1beta2LimitedPriorityLevelConfigurationBuilder that = + (V1beta2LimitedPriorityLevelConfigurationBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitedPriorityLevelConfigurationFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitedPriorityLevelConfigurationFluent.java index 5b0d0aeb03..65c0795f88 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitedPriorityLevelConfigurationFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitedPriorityLevelConfigurationFluent.java @@ -1,39 +1,76 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Integer; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2LimitedPriorityLevelConfigurationFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta2LimitedPriorityLevelConfigurationFluent< + A extends + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getAssuredConcurrencyShares(); + public A withAssuredConcurrencyShares(java.lang.Integer assuredConcurrencyShares); + public java.lang.Boolean hasAssuredConcurrencyShares(); - + /** * This method has been deprecated, please use method buildLimitResponse instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2LimitResponse getLimitResponse(); + public io.kubernetes.client.openapi.models.V1beta2LimitResponse buildLimitResponse(); - public A withLimitResponse(io.kubernetes.client.openapi.models.V1beta2LimitResponse limitResponse); + + public A withLimitResponse( + io.kubernetes.client.openapi.models.V1beta2LimitResponse limitResponse); + public java.lang.Boolean hasLimitResponse(); - public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent.LimitResponseNested withNewLimitResponse(); - public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent.LimitResponseNested withNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta2LimitResponse item); - public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent.LimitResponseNested editLimitResponse(); - public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent.LimitResponseNested editOrNewLimitResponse(); - public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent.LimitResponseNested editOrNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta2LimitResponse item); - public interface LimitResponseNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent>{ + + public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + withNewLimitResponse(); + + public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + withNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta2LimitResponse item); + + public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + editLimitResponse(); + + public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + editOrNewLimitResponse(); + + public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + editOrNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta2LimitResponse item); + + public interface LimitResponseNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2LimitResponseFluent< + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + N>> { public N and(); + public N endLimitResponse(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitedPriorityLevelConfigurationFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitedPriorityLevelConfigurationFluentImpl.java index 3b19144011..8e9463b87f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitedPriorityLevelConfigurationFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2LimitedPriorityLevelConfigurationFluentImpl.java @@ -1,95 +1,164 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta2LimitedPriorityLevelConfigurationFluentImpl< + A extends + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent< + A> { + public V1beta2LimitedPriorityLevelConfigurationFluentImpl() {} - /** - * Generated - */ -public class V1beta2LimitedPriorityLevelConfigurationFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent{ - public V1beta2LimitedPriorityLevelConfigurationFluentImpl() { - } - public V1beta2LimitedPriorityLevelConfigurationFluentImpl(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration instance) { + public V1beta2LimitedPriorityLevelConfigurationFluentImpl( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration instance) { this.withAssuredConcurrencyShares(instance.getAssuredConcurrencyShares()); this.withLimitResponse(instance.getLimitResponse()); - } + private java.lang.Integer assuredConcurrencyShares; private io.kubernetes.client.openapi.models.V1beta2LimitResponseBuilder limitResponse; + public java.lang.Integer getAssuredConcurrencyShares() { return this.assuredConcurrencyShares; } + public A withAssuredConcurrencyShares(java.lang.Integer assuredConcurrencyShares) { - this.assuredConcurrencyShares=assuredConcurrencyShares; return (A) this; + this.assuredConcurrencyShares = assuredConcurrencyShares; + return (A) this; } + public java.lang.Boolean hasAssuredConcurrencyShares() { return this.assuredConcurrencyShares != null; } - + /** * This method has been deprecated, please use method buildLimitResponse instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2LimitResponse getLimitResponse() { - return this.limitResponse!=null ?this.limitResponse.build():null; + return this.limitResponse != null ? this.limitResponse.build() : null; } + public io.kubernetes.client.openapi.models.V1beta2LimitResponse buildLimitResponse() { - return this.limitResponse!=null ?this.limitResponse.build():null; + return this.limitResponse != null ? this.limitResponse.build() : null; } - public A withLimitResponse(io.kubernetes.client.openapi.models.V1beta2LimitResponse limitResponse) { + + public A withLimitResponse( + io.kubernetes.client.openapi.models.V1beta2LimitResponse limitResponse) { _visitables.get("limitResponse").remove(this.limitResponse); - if (limitResponse!=null){ this.limitResponse= new io.kubernetes.client.openapi.models.V1beta2LimitResponseBuilder(limitResponse); _visitables.get("limitResponse").add(this.limitResponse);} return (A) this; + if (limitResponse != null) { + this.limitResponse = + new io.kubernetes.client.openapi.models.V1beta2LimitResponseBuilder(limitResponse); + _visitables.get("limitResponse").add(this.limitResponse); + } + return (A) this; } + public java.lang.Boolean hasLimitResponse() { return this.limitResponse != null; } - public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent.LimitResponseNested withNewLimitResponse() { - return new io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluentImpl.LimitResponseNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + withNewLimitResponse() { + return new io.kubernetes.client.openapi.models + .V1beta2LimitedPriorityLevelConfigurationFluentImpl.LimitResponseNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent.LimitResponseNested withNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta2LimitResponse item) { - return new io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluentImpl.LimitResponseNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + withNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta2LimitResponse item) { + return new io.kubernetes.client.openapi.models + .V1beta2LimitedPriorityLevelConfigurationFluentImpl.LimitResponseNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent.LimitResponseNested editLimitResponse() { + + public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + editLimitResponse() { return withNewLimitResponseLike(getLimitResponse()); } - public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent.LimitResponseNested editOrNewLimitResponse() { - return withNewLimitResponseLike(getLimitResponse() != null ? getLimitResponse(): new io.kubernetes.client.openapi.models.V1beta2LimitResponseBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + editOrNewLimitResponse() { + return withNewLimitResponseLike( + getLimitResponse() != null + ? getLimitResponse() + : new io.kubernetes.client.openapi.models.V1beta2LimitResponseBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent.LimitResponseNested editOrNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta2LimitResponse item) { - return withNewLimitResponseLike(getLimitResponse() != null ? getLimitResponse(): item); + + public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + A> + editOrNewLimitResponseLike(io.kubernetes.client.openapi.models.V1beta2LimitResponse item) { + return withNewLimitResponseLike(getLimitResponse() != null ? getLimitResponse() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta2LimitedPriorityLevelConfigurationFluentImpl that = (V1beta2LimitedPriorityLevelConfigurationFluentImpl) o; - if (assuredConcurrencyShares != null ? !assuredConcurrencyShares.equals(that.assuredConcurrencyShares) :that.assuredConcurrencyShares != null) return false; - if (limitResponse != null ? !limitResponse.equals(that.limitResponse) :that.limitResponse != null) return false; + V1beta2LimitedPriorityLevelConfigurationFluentImpl that = + (V1beta2LimitedPriorityLevelConfigurationFluentImpl) o; + if (assuredConcurrencyShares != null + ? !assuredConcurrencyShares.equals(that.assuredConcurrencyShares) + : that.assuredConcurrencyShares != null) return false; + if (limitResponse != null + ? !limitResponse.equals(that.limitResponse) + : that.limitResponse != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(assuredConcurrencyShares, limitResponse, super.hashCode()); + return java.util.Objects.hash(assuredConcurrencyShares, limitResponse, super.hashCode()); } - public class LimitResponseNestedImpl extends io.kubernetes.client.openapi.models.V1beta2LimitResponseFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent.LimitResponseNested,io.kubernetes.client.fluent.Nested{ + + public class LimitResponseNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2LimitResponseFluentImpl< + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent + .LimitResponseNested< + N>, + io.kubernetes.client.fluent.Nested { LimitResponseNestedImpl(io.kubernetes.client.openapi.models.V1beta2LimitResponse item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta2LimitResponseBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2LimitResponseBuilder(this, item); } + LimitResponseNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta2LimitResponseBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2LimitResponseBuilder builder; + public N and() { - return (N) V1beta2LimitedPriorityLevelConfigurationFluentImpl.this.withLimitResponse(builder.build()); + return (N) + V1beta2LimitedPriorityLevelConfigurationFluentImpl.this.withLimitResponse( + builder.build()); } + public N endLimitResponse() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2NonResourcePolicyRuleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2NonResourcePolicyRuleBuilder.java index e0d94f21e1..ba55aadfd4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2NonResourcePolicyRuleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2NonResourcePolicyRuleBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2NonResourcePolicyRuleBuilder extends io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2NonResourcePolicyRuleBuilder + extends io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluentImpl< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule, + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder> { public V1beta2NonResourcePolicyRuleBuilder() { this(false); } + public V1beta2NonResourcePolicyRuleBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2NonResourcePolicyRule(), validationEnabled); } - public V1beta2NonResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent fluent) { + + public V1beta2NonResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent fluent) { this(fluent, false); } - public V1beta2NonResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2NonResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2NonResourcePolicyRule(), validationEnabled); } - public V1beta2NonResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent fluent,io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule instance) { + + public V1beta2NonResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent fluent, + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule instance) { this(fluent, instance, false); } - public V1beta2NonResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent fluent,io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2NonResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent fluent, + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNonResourceURLs(instance.getNonResourceURLs()); fluent.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2NonResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule instance) { - this(instance,false); + + public V1beta2NonResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule instance) { + this(instance, false); } - public V1beta2NonResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2NonResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNonResourceURLs(instance.getNonResourceURLs()); this.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule build() { V1beta2NonResourcePolicyRule buildable = new V1beta2NonResourcePolicyRule(); buildable.setNonResourceURLs(fluent.getNonResourceURLs()); buildable.setVerbs(fluent.getVerbs()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2NonResourcePolicyRuleBuilder that = (V1beta2NonResourcePolicyRuleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2NonResourcePolicyRuleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2NonResourcePolicyRuleFluent.java index f4c6f9b52f..42046f9c4d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2NonResourcePolicyRuleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2NonResourcePolicyRuleFluent.java @@ -1,50 +1,85 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1beta2NonResourcePolicyRuleFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToNonResourceURLs(java.lang.Integer index,java.lang.String item); - public A setToNonResourceURLs(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1beta2NonResourcePolicyRuleFluent< + A extends io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToNonResourceURLs(java.lang.Integer index, java.lang.String item); + + public A setToNonResourceURLs(java.lang.Integer index, java.lang.String item); + public A addToNonResourceURLs(java.lang.String... items); + public A addAllToNonResourceURLs(java.util.Collection items); + public A removeFromNonResourceURLs(java.lang.String... items); + public A removeAllFromNonResourceURLs(java.util.Collection items); + public java.util.List getNonResourceURLs(); + public java.lang.String getNonResourceURL(java.lang.Integer index); + public java.lang.String getFirstNonResourceURL(); + public java.lang.String getLastNonResourceURL(); - public java.lang.String getMatchingNonResourceURL(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingNonResourceURL(java.util.function.Predicate predicate); + + public java.lang.String getMatchingNonResourceURL( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingNonResourceURL( + java.util.function.Predicate predicate); + public A withNonResourceURLs(java.util.List nonResourceURLs); + public A withNonResourceURLs(java.lang.String... nonResourceURLs); + public java.lang.Boolean hasNonResourceURLs(); + public A addNewNonResourceURL(java.lang.String original); - public A addToVerbs(java.lang.Integer index,java.lang.String item); - public A setToVerbs(java.lang.Integer index,java.lang.String item); + + public A addToVerbs(java.lang.Integer index, java.lang.String item); + + public A setToVerbs(java.lang.Integer index, java.lang.String item); + public A addToVerbs(java.lang.String... items); + public A addAllToVerbs(java.util.Collection items); + public A removeFromVerbs(java.lang.String... items); + public A removeAllFromVerbs(java.util.Collection items); + public java.util.List getVerbs(); + public java.lang.String getVerb(java.lang.Integer index); + public java.lang.String getFirstVerb(); + public java.lang.String getLastVerb(); + public java.lang.String getMatchingVerb(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate); + public A withVerbs(java.util.List verbs); + public A withVerbs(java.lang.String... verbs); + public java.lang.Boolean hasVerbs(); + public A addNewVerb(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2NonResourcePolicyRuleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2NonResourcePolicyRuleFluentImpl.java index aec0d58475..c7a1cffa63 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2NonResourcePolicyRuleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2NonResourcePolicyRuleFluentImpl.java @@ -1,147 +1,290 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.ArrayList; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public class V1beta2NonResourcePolicyRuleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent{ - public V1beta2NonResourcePolicyRuleFluentImpl() { - } - public V1beta2NonResourcePolicyRuleFluentImpl(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule instance) { +/** Generated */ +public class V1beta2NonResourcePolicyRuleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent { + public V1beta2NonResourcePolicyRuleFluentImpl() {} + + public V1beta2NonResourcePolicyRuleFluentImpl( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule instance) { this.withNonResourceURLs(instance.getNonResourceURLs()); this.withVerbs(instance.getVerbs()); - } + private java.util.List nonResourceURLs; private java.util.List verbs; - public A addToNonResourceURLs(java.lang.Integer index,java.lang.String item) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} + + public A addToNonResourceURLs(java.lang.Integer index, java.lang.String item) { + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } this.nonResourceURLs.add(index, item); - return (A)this; + return (A) this; } - public A setToNonResourceURLs(java.lang.Integer index,java.lang.String item) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} - this.nonResourceURLs.set(index, item); return (A)this; + + public A setToNonResourceURLs(java.lang.Integer index, java.lang.String item) { + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } + this.nonResourceURLs.set(index, item); + return (A) this; } + public A addToNonResourceURLs(java.lang.String... items) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.nonResourceURLs.add(item);} return (A)this; + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.nonResourceURLs.add(item); + } + return (A) this; } + public A addAllToNonResourceURLs(java.util.Collection items) { - if (this.nonResourceURLs == null) {this.nonResourceURLs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.nonResourceURLs.add(item);} return (A)this; + if (this.nonResourceURLs == null) { + this.nonResourceURLs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.nonResourceURLs.add(item); + } + return (A) this; } + public A removeFromNonResourceURLs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.nonResourceURLs!= null){ this.nonResourceURLs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.nonResourceURLs != null) { + this.nonResourceURLs.remove(item); + } + } + return (A) this; } + public A removeAllFromNonResourceURLs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.nonResourceURLs!= null){ this.nonResourceURLs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.nonResourceURLs != null) { + this.nonResourceURLs.remove(item); + } + } + return (A) this; } + public java.util.List getNonResourceURLs() { return this.nonResourceURLs; } + public java.lang.String getNonResourceURL(java.lang.Integer index) { return this.nonResourceURLs.get(index); } + public java.lang.String getFirstNonResourceURL() { return this.nonResourceURLs.get(0); } + public java.lang.String getLastNonResourceURL() { return this.nonResourceURLs.get(nonResourceURLs.size() - 1); } - public java.lang.String getMatchingNonResourceURL(java.util.function.Predicate predicate) { - for (java.lang.String item: nonResourceURLs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingNonResourceURL( + java.util.function.Predicate predicate) { + for (java.lang.String item : nonResourceURLs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingNonResourceURL(java.util.function.Predicate predicate) { - for (java.lang.String item: nonResourceURLs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingNonResourceURL( + java.util.function.Predicate predicate) { + for (java.lang.String item : nonResourceURLs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withNonResourceURLs(java.util.List nonResourceURLs) { - if (nonResourceURLs != null) {this.nonResourceURLs = new java.util.ArrayList(); for (java.lang.String item : nonResourceURLs){this.addToNonResourceURLs(item);}} else { this.nonResourceURLs = null;} return (A) this; + if (nonResourceURLs != null) { + this.nonResourceURLs = new java.util.ArrayList(); + for (java.lang.String item : nonResourceURLs) { + this.addToNonResourceURLs(item); + } + } else { + this.nonResourceURLs = null; + } + return (A) this; } + public A withNonResourceURLs(java.lang.String... nonResourceURLs) { - if (this.nonResourceURLs != null) {this.nonResourceURLs.clear();} - if (nonResourceURLs != null) {for (java.lang.String item :nonResourceURLs){ this.addToNonResourceURLs(item);}} return (A) this; + if (this.nonResourceURLs != null) { + this.nonResourceURLs.clear(); + } + if (nonResourceURLs != null) { + for (java.lang.String item : nonResourceURLs) { + this.addToNonResourceURLs(item); + } + } + return (A) this; } + public java.lang.Boolean hasNonResourceURLs() { return nonResourceURLs != null && !nonResourceURLs.isEmpty(); } + public A addNewNonResourceURL(java.lang.String original) { - return (A)addToNonResourceURLs(new String(original)); + return (A) addToNonResourceURLs(new String(original)); } - public A addToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} + + public A addToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } this.verbs.add(index, item); - return (A)this; + return (A) this; } - public A setToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - this.verbs.set(index, item); return (A)this; + + public A setToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + this.verbs.set(index, item); + return (A) this; } + public A addToVerbs(java.lang.String... items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A addAllToVerbs(java.util.Collection items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A removeFromVerbs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public A removeAllFromVerbs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public java.util.List getVerbs() { return this.verbs; } + public java.lang.String getVerb(java.lang.Integer index) { return this.verbs.get(index); } + public java.lang.String getFirstVerb() { return this.verbs.get(0); } + public java.lang.String getLastVerb() { return this.verbs.get(verbs.size() - 1); } - public java.lang.String getMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withVerbs(java.util.List verbs) { - if (verbs != null) {this.verbs = new java.util.ArrayList(); for (java.lang.String item : verbs){this.addToVerbs(item);}} else { this.verbs = null;} return (A) this; + if (verbs != null) { + this.verbs = new java.util.ArrayList(); + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } else { + this.verbs = null; + } + return (A) this; } + public A withVerbs(java.lang.String... verbs) { - if (this.verbs != null) {this.verbs.clear();} - if (verbs != null) {for (java.lang.String item :verbs){ this.addToVerbs(item);}} return (A) this; + if (this.verbs != null) { + this.verbs.clear(); + } + if (verbs != null) { + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } + return (A) this; } + public java.lang.Boolean hasVerbs() { return verbs != null && !verbs.isEmpty(); } + public A addNewVerb(java.lang.String original) { - return (A)addToVerbs(new String(original)); + return (A) addToVerbs(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta2NonResourcePolicyRuleFluentImpl that = (V1beta2NonResourcePolicyRuleFluentImpl) o; - if (nonResourceURLs != null ? !nonResourceURLs.equals(that.nonResourceURLs) :that.nonResourceURLs != null) return false; - if (verbs != null ? !verbs.equals(that.verbs) :that.verbs != null) return false; + if (nonResourceURLs != null + ? !nonResourceURLs.equals(that.nonResourceURLs) + : that.nonResourceURLs != null) return false; + if (verbs != null ? !verbs.equals(that.verbs) : that.verbs != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(nonResourceURLs, verbs, super.hashCode()); + return java.util.Objects.hash(nonResourceURLs, verbs, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PolicyRulesWithSubjectsBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PolicyRulesWithSubjectsBuilder.java index 33ba28acd4..b253200973 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PolicyRulesWithSubjectsBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PolicyRulesWithSubjectsBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2PolicyRulesWithSubjectsBuilder extends io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2PolicyRulesWithSubjectsBuilder + extends io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects, + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsBuilder> { public V1beta2PolicyRulesWithSubjectsBuilder() { this(false); } + public V1beta2PolicyRulesWithSubjectsBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2PolicyRulesWithSubjects(), validationEnabled); } - public V1beta2PolicyRulesWithSubjectsBuilder(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent fluent) { + + public V1beta2PolicyRulesWithSubjectsBuilder( + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent fluent) { this(fluent, false); } - public V1beta2PolicyRulesWithSubjectsBuilder(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2PolicyRulesWithSubjectsBuilder( + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2PolicyRulesWithSubjects(), validationEnabled); } - public V1beta2PolicyRulesWithSubjectsBuilder(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent fluent,io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects instance) { + + public V1beta2PolicyRulesWithSubjectsBuilder( + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent fluent, + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects instance) { this(fluent, instance, false); } - public V1beta2PolicyRulesWithSubjectsBuilder(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent fluent,io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2PolicyRulesWithSubjectsBuilder( + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent fluent, + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withNonResourceRules(instance.getNonResourceRules()); fluent.withResourceRules(instance.getResourceRules()); fluent.withSubjects(instance.getSubjects()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2PolicyRulesWithSubjectsBuilder(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects instance) { - this(instance,false); + + public V1beta2PolicyRulesWithSubjectsBuilder( + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects instance) { + this(instance, false); } - public V1beta2PolicyRulesWithSubjectsBuilder(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2PolicyRulesWithSubjectsBuilder( + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withNonResourceRules(instance.getNonResourceRules()); this.withResourceRules(instance.getResourceRules()); this.withSubjects(instance.getSubjects()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects build() { V1beta2PolicyRulesWithSubjects buildable = new V1beta2PolicyRulesWithSubjects(); buildable.setNonResourceRules(fluent.getNonResourceRules()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects build( buildable.setSubjects(fluent.getSubjects()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2PolicyRulesWithSubjectsBuilder that = (V1beta2PolicyRulesWithSubjectsBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PolicyRulesWithSubjectsFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PolicyRulesWithSubjectsFluent.java index 039eed017b..f05d5ab523 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PolicyRulesWithSubjectsFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PolicyRulesWithSubjectsFluent.java @@ -1,127 +1,333 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V1beta2PolicyRulesWithSubjectsFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToNonResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item); - public A setToNonResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item); - public A addToNonResourceRules(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule... items); - public A addAllToNonResourceRules(java.util.Collection items); - public A removeFromNonResourceRules(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule... items); - public A removeAllFromNonResourceRules(java.util.Collection items); - public A removeMatchingFromNonResourceRules(java.util.function.Predicate predicate); - +/** Generated */ +public interface V1beta2PolicyRulesWithSubjectsFluent< + A extends io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToNonResourceRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item); + + public A setToNonResourceRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item); + + public A addToNonResourceRules( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule... items); + + public A addAllToNonResourceRules( + java.util.Collection items); + + public A removeFromNonResourceRules( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule... items); + + public A removeAllFromNonResourceRules( + java.util.Collection items); + + public A removeMatchingFromNonResourceRules( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder> + predicate); + /** * This method has been deprecated, please use method buildNonResourceRules instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getNonResourceRules(); - public java.util.List buildNonResourceRules(); - public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule buildNonResourceRule(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule buildFirstNonResourceRule(); - public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule buildLastNonResourceRule(); - public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule buildMatchingNonResourceRule(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingNonResourceRule(java.util.function.Predicate predicate); - public A withNonResourceRules(java.util.List nonResourceRules); - public A withNonResourceRules(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule... nonResourceRules); + public java.util.List + getNonResourceRules(); + + public java.util.List + buildNonResourceRules(); + + public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule buildNonResourceRule( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule + buildFirstNonResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule + buildLastNonResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule + buildMatchingNonResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder> + predicate); + + public java.lang.Boolean hasMatchingNonResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder> + predicate); + + public A withNonResourceRules( + java.util.List + nonResourceRules); + + public A withNonResourceRules( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule... nonResourceRules); + public java.lang.Boolean hasNonResourceRules(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested addNewNonResourceRule(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested addNewNonResourceRuleLike(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested setNewNonResourceRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested editNonResourceRule(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested editFirstNonResourceRule(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested editLastNonResourceRule(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested editMatchingNonResourceRule(java.util.function.Predicate predicate); - public A addToResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item); - public A setToResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item); - public A addToResourceRules(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule... items); - public A addAllToResourceRules(java.util.Collection items); - public A removeFromResourceRules(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule... items); - public A removeAllFromResourceRules(java.util.Collection items); - public A removeMatchingFromResourceRules(java.util.function.Predicate predicate); - + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + addNewNonResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + addNewNonResourceRuleLike( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + setNewNonResourceRuleLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editNonResourceRule(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editFirstNonResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editLastNonResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editMatchingNonResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder> + predicate); + + public A addToResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item); + + public A setToResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item); + + public A addToResourceRules( + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule... items); + + public A addAllToResourceRules( + java.util.Collection items); + + public A removeFromResourceRules( + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule... items); + + public A removeAllFromResourceRules( + java.util.Collection items); + + public A removeMatchingFromResourceRules( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder> + predicate); + /** * This method has been deprecated, please use method buildResourceRules instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getResourceRules(); - public java.util.List buildResourceRules(); - public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule buildResourceRule(java.lang.Integer index); + public java.util.List + getResourceRules(); + + public java.util.List + buildResourceRules(); + + public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule buildResourceRule( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule buildFirstResourceRule(); + public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule buildLastResourceRule(); - public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule buildMatchingResourceRule(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingResourceRule(java.util.function.Predicate predicate); - public A withResourceRules(java.util.List resourceRules); - public A withResourceRules(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule... resourceRules); + + public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule buildMatchingResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder> + predicate); + + public java.lang.Boolean hasMatchingResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder> + predicate); + + public A withResourceRules( + java.util.List resourceRules); + + public A withResourceRules( + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule... resourceRules); + public java.lang.Boolean hasResourceRules(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested addNewResourceRule(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested addNewResourceRuleLike(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested setNewResourceRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested editResourceRule(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested editFirstResourceRule(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested editLastResourceRule(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested editMatchingResourceRule(java.util.function.Predicate predicate); - public A addToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2Subject item); - public A setToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2Subject item); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + addNewResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + addNewResourceRuleLike(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + setNewResourceRuleLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editResourceRule(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editFirstResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editLastResourceRule(); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editMatchingResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder> + predicate); + + public A addToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2Subject item); + + public A setToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2Subject item); + public A addToSubjects(io.kubernetes.client.openapi.models.V1beta2Subject... items); - public A addAllToSubjects(java.util.Collection items); + + public A addAllToSubjects( + java.util.Collection items); + public A removeFromSubjects(io.kubernetes.client.openapi.models.V1beta2Subject... items); - public A removeAllFromSubjects(java.util.Collection items); - public A removeMatchingFromSubjects(java.util.function.Predicate predicate); - + + public A removeAllFromSubjects( + java.util.Collection items); + + public A removeMatchingFromSubjects( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildSubjects instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getSubjects(); + public java.util.List buildSubjects(); + public io.kubernetes.client.openapi.models.V1beta2Subject buildSubject(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta2Subject buildFirstSubject(); + public io.kubernetes.client.openapi.models.V1beta2Subject buildLastSubject(); - public io.kubernetes.client.openapi.models.V1beta2Subject buildMatchingSubject(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingSubject(java.util.function.Predicate predicate); - public A withSubjects(java.util.List subjects); + + public io.kubernetes.client.openapi.models.V1beta2Subject buildMatchingSubject( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingSubject( + java.util.function.Predicate + predicate); + + public A withSubjects( + java.util.List subjects); + public A withSubjects(io.kubernetes.client.openapi.models.V1beta2Subject... subjects); + public java.lang.Boolean hasSubjects(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested addNewSubject(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested addNewSubjectLike(io.kubernetes.client.openapi.models.V1beta2Subject item); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested setNewSubjectLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2Subject item); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested editSubject(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested editFirstSubject(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested editLastSubject(); - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested editMatchingSubject(java.util.function.Predicate predicate); - public interface NonResourceRulesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent>{ + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + addNewSubject(); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + addNewSubjectLike(io.kubernetes.client.openapi.models.V1beta2Subject item); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + setNewSubjectLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2Subject item); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + editSubject(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + editFirstSubject(); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + editLastSubject(); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + editMatchingSubject( + java.util.function.Predicate + predicate); + + public interface NonResourceRulesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluent< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + N>> { public N and(); + public N endNonResourceRule(); - } - public interface ResourceRulesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent>{ + + public interface ResourceRulesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + N>> { public N and(); + public N endResourceRule(); - } - public interface SubjectsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2SubjectFluent>{ + + public interface SubjectsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2SubjectFluent< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .SubjectsNested< + N>> { public N and(); + public N endSubject(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PolicyRulesWithSubjectsFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PolicyRulesWithSubjectsFluentImpl.java index 7227a93def..ddec4babf6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PolicyRulesWithSubjectsFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PolicyRulesWithSubjectsFluentImpl.java @@ -1,63 +1,150 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta2PolicyRulesWithSubjectsFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent{ - public V1beta2PolicyRulesWithSubjectsFluentImpl() { - } - public V1beta2PolicyRulesWithSubjectsFluentImpl(io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects instance) { + +/** Generated */ +public class V1beta2PolicyRulesWithSubjectsFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent { + public V1beta2PolicyRulesWithSubjectsFluentImpl() {} + + public V1beta2PolicyRulesWithSubjectsFluentImpl( + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjects instance) { this.withNonResourceRules(instance.getNonResourceRules()); this.withResourceRules(instance.getResourceRules()); this.withSubjects(instance.getSubjects()); - } - private java.util.ArrayList nonResourceRules; - private java.util.ArrayList resourceRules; + + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder> + nonResourceRules; + private java.util.ArrayList + resourceRules; private java.util.ArrayList subjects; - public A addToNonResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item) { - if (this.nonResourceRules == null) {this.nonResourceRules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(item);_visitables.get("nonResourceRules").add(index >= 0 ? index : _visitables.get("nonResourceRules").size(), builder);this.nonResourceRules.add(index >= 0 ? index : nonResourceRules.size(), builder); return (A)this; + + public A addToNonResourceRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item) { + if (this.nonResourceRules == null) { + this.nonResourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(item); + _visitables + .get("nonResourceRules") + .add(index >= 0 ? index : _visitables.get("nonResourceRules").size(), builder); + this.nonResourceRules.add(index >= 0 ? index : nonResourceRules.size(), builder); + return (A) this; } - public A setToNonResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item) { - if (this.nonResourceRules == null) {this.nonResourceRules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(item); - if (index < 0 || index >= _visitables.get("nonResourceRules").size()) { _visitables.get("nonResourceRules").add(builder); } else { _visitables.get("nonResourceRules").set(index, builder);} - if (index < 0 || index >= nonResourceRules.size()) { nonResourceRules.add(builder); } else { nonResourceRules.set(index, builder);} - return (A)this; + + public A setToNonResourceRules( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item) { + if (this.nonResourceRules == null) { + this.nonResourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(item); + if (index < 0 || index >= _visitables.get("nonResourceRules").size()) { + _visitables.get("nonResourceRules").add(builder); + } else { + _visitables.get("nonResourceRules").set(index, builder); + } + if (index < 0 || index >= nonResourceRules.size()) { + nonResourceRules.add(builder); + } else { + nonResourceRules.set(index, builder); + } + return (A) this; } - public A addToNonResourceRules(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule... items) { - if (this.nonResourceRules == null) {this.nonResourceRules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(item);_visitables.get("nonResourceRules").add(builder);this.nonResourceRules.add(builder);} return (A)this; + + public A addToNonResourceRules( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule... items) { + if (this.nonResourceRules == null) { + this.nonResourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(item); + _visitables.get("nonResourceRules").add(builder); + this.nonResourceRules.add(builder); + } + return (A) this; } - public A addAllToNonResourceRules(java.util.Collection items) { - if (this.nonResourceRules == null) {this.nonResourceRules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(item);_visitables.get("nonResourceRules").add(builder);this.nonResourceRules.add(builder);} return (A)this; + + public A addAllToNonResourceRules( + java.util.Collection + items) { + if (this.nonResourceRules == null) { + this.nonResourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(item); + _visitables.get("nonResourceRules").add(builder); + this.nonResourceRules.add(builder); + } + return (A) this; } - public A removeFromNonResourceRules(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule... items) { - for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(item);_visitables.get("nonResourceRules").remove(builder);if (this.nonResourceRules != null) {this.nonResourceRules.remove(builder);}} return (A)this; + + public A removeFromNonResourceRules( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule... items) { + for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(item); + _visitables.get("nonResourceRules").remove(builder); + if (this.nonResourceRules != null) { + this.nonResourceRules.remove(builder); + } + } + return (A) this; } - public A removeAllFromNonResourceRules(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(item);_visitables.get("nonResourceRules").remove(builder);if (this.nonResourceRules != null) {this.nonResourceRules.remove(builder);}} return (A)this; + + public A removeAllFromNonResourceRules( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(item); + _visitables.get("nonResourceRules").remove(builder); + if (this.nonResourceRules != null) { + this.nonResourceRules.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromNonResourceRules(java.util.function.Predicate predicate) { + + public A removeMatchingFromNonResourceRules( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder> + predicate) { if (nonResourceRules == null) return (A) this; - final Iterator each = nonResourceRules.iterator(); + final Iterator each = + nonResourceRules.iterator(); final List visitables = _visitables.get("nonResourceRules"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder = each.next(); @@ -66,104 +153,280 @@ public A removeMatchingFromNonResourceRules(java.util.function.Predicate getNonResourceRules() { + public java.util.List + getNonResourceRules() { return nonResourceRules != null ? build(nonResourceRules) : null; } - public java.util.List buildNonResourceRules() { + + public java.util.List + buildNonResourceRules() { return nonResourceRules != null ? build(nonResourceRules) : null; } - public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule buildNonResourceRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule buildNonResourceRule( + java.lang.Integer index) { return this.nonResourceRules.get(index).build(); } - public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule buildFirstNonResourceRule() { + + public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule + buildFirstNonResourceRule() { return this.nonResourceRules.get(0).build(); } - public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule buildLastNonResourceRule() { + + public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule + buildLastNonResourceRule() { return this.nonResourceRules.get(nonResourceRules.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule buildMatchingNonResourceRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder item: nonResourceRules) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule + buildMatchingNonResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder item : + nonResourceRules) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingNonResourceRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder item: nonResourceRules) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingNonResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder item : + nonResourceRules) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withNonResourceRules(java.util.List nonResourceRules) { - if (this.nonResourceRules != null) { _visitables.get("nonResourceRules").removeAll(this.nonResourceRules);} - if (nonResourceRules != null) {this.nonResourceRules = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item : nonResourceRules){this.addToNonResourceRules(item);}} else { this.nonResourceRules = null;} return (A) this; + + public A withNonResourceRules( + java.util.List + nonResourceRules) { + if (this.nonResourceRules != null) { + _visitables.get("nonResourceRules").removeAll(this.nonResourceRules); + } + if (nonResourceRules != null) { + this.nonResourceRules = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item : + nonResourceRules) { + this.addToNonResourceRules(item); + } + } else { + this.nonResourceRules = null; + } + return (A) this; } - public A withNonResourceRules(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule... nonResourceRules) { - if (this.nonResourceRules != null) {this.nonResourceRules.clear();} - if (nonResourceRules != null) {for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item :nonResourceRules){ this.addToNonResourceRules(item);}} return (A) this; + + public A withNonResourceRules( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule... nonResourceRules) { + if (this.nonResourceRules != null) { + this.nonResourceRules.clear(); + } + if (nonResourceRules != null) { + for (io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item : + nonResourceRules) { + this.addToNonResourceRules(item); + } + } + return (A) this; } + public java.lang.Boolean hasNonResourceRules() { return nonResourceRules != null && !nonResourceRules.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested addNewNonResourceRule() { - return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl.NonResourceRulesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + addNewNonResourceRule() { + return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl + .NonResourceRulesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested addNewNonResourceRuleLike(io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item) { - return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl.NonResourceRulesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + addNewNonResourceRuleLike( + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item) { + return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl + .NonResourceRulesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested setNewNonResourceRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item) { - return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl.NonResourceRulesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + setNewNonResourceRuleLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item) { + return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl + .NonResourceRulesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested editNonResourceRule(java.lang.Integer index) { - if (nonResourceRules.size() <= index) throw new RuntimeException("Can't edit nonResourceRules. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editNonResourceRule(java.lang.Integer index) { + if (nonResourceRules.size() <= index) + throw new RuntimeException("Can't edit nonResourceRules. Index exceeds size."); return setNewNonResourceRuleLike(index, buildNonResourceRule(index)); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested editFirstNonResourceRule() { - if (nonResourceRules.size() == 0) throw new RuntimeException("Can't edit first nonResourceRules. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editFirstNonResourceRule() { + if (nonResourceRules.size() == 0) + throw new RuntimeException("Can't edit first nonResourceRules. The list is empty."); return setNewNonResourceRuleLike(0, buildNonResourceRule(0)); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested editLastNonResourceRule() { + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editLastNonResourceRule() { int index = nonResourceRules.size() - 1; - if (index < 0) throw new RuntimeException("Can't edit last nonResourceRules. The list is empty."); + if (index < 0) + throw new RuntimeException("Can't edit last nonResourceRules. The list is empty."); return setNewNonResourceRuleLike(index, buildNonResourceRule(index)); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested editMatchingNonResourceRule(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + A> + editMatchingNonResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(item);_visitables.get("resourceRules").add(index >= 0 ? index : _visitables.get("resourceRules").size(), builder);this.resourceRules.add(index >= 0 ? index : resourceRules.size(), builder); return (A)this; + + public A addToResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item) { + if (this.resourceRules == null) { + this.resourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(item); + _visitables + .get("resourceRules") + .add(index >= 0 ? index : _visitables.get("resourceRules").size(), builder); + this.resourceRules.add(index >= 0 ? index : resourceRules.size(), builder); + return (A) this; } - public A setToResourceRules(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item) { - if (this.resourceRules == null) {this.resourceRules = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(item); - if (index < 0 || index >= _visitables.get("resourceRules").size()) { _visitables.get("resourceRules").add(builder); } else { _visitables.get("resourceRules").set(index, builder);} - if (index < 0 || index >= resourceRules.size()) { resourceRules.add(builder); } else { resourceRules.set(index, builder);} - return (A)this; + + public A setToResourceRules( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item) { + if (this.resourceRules == null) { + this.resourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(item); + if (index < 0 || index >= _visitables.get("resourceRules").size()) { + _visitables.get("resourceRules").add(builder); + } else { + _visitables.get("resourceRules").set(index, builder); + } + if (index < 0 || index >= resourceRules.size()) { + resourceRules.add(builder); + } else { + resourceRules.set(index, builder); + } + return (A) this; } - public A addToResourceRules(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule... items) { - if (this.resourceRules == null) {this.resourceRules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(item);_visitables.get("resourceRules").add(builder);this.resourceRules.add(builder);} return (A)this; + + public A addToResourceRules( + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule... items) { + if (this.resourceRules == null) { + this.resourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(item); + _visitables.get("resourceRules").add(builder); + this.resourceRules.add(builder); + } + return (A) this; } - public A addAllToResourceRules(java.util.Collection items) { - if (this.resourceRules == null) {this.resourceRules = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(item);_visitables.get("resourceRules").add(builder);this.resourceRules.add(builder);} return (A)this; + + public A addAllToResourceRules( + java.util.Collection items) { + if (this.resourceRules == null) { + this.resourceRules = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(item); + _visitables.get("resourceRules").add(builder); + this.resourceRules.add(builder); + } + return (A) this; } - public A removeFromResourceRules(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule... items) { - for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(item);_visitables.get("resourceRules").remove(builder);if (this.resourceRules != null) {this.resourceRules.remove(builder);}} return (A)this; + + public A removeFromResourceRules( + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule... items) { + for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(item); + _visitables.get("resourceRules").remove(builder); + if (this.resourceRules != null) { + this.resourceRules.remove(builder); + } + } + return (A) this; } - public A removeAllFromResourceRules(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item : items) {io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder = new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(item);_visitables.get("resourceRules").remove(builder);if (this.resourceRules != null) {this.resourceRules.remove(builder);}} return (A)this; + + public A removeAllFromResourceRules( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item : items) { + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(item); + _visitables.get("resourceRules").remove(builder); + if (this.resourceRules != null) { + this.resourceRules.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromResourceRules(java.util.function.Predicate predicate) { + + public A removeMatchingFromResourceRules( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder> + predicate) { if (resourceRules == null) return (A) this; - final Iterator each = resourceRules.iterator(); + final Iterator each = + resourceRules.iterator(); final List visitables = _visitables.get("resourceRules"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder = each.next(); @@ -172,104 +435,264 @@ public A removeMatchingFromResourceRules(java.util.function.Predicate getResourceRules() { + public java.util.List + getResourceRules() { return resourceRules != null ? build(resourceRules) : null; } - public java.util.List buildResourceRules() { + + public java.util.List + buildResourceRules() { return resourceRules != null ? build(resourceRules) : null; } - public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule buildResourceRule(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule buildResourceRule( + java.lang.Integer index) { return this.resourceRules.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule buildFirstResourceRule() { return this.resourceRules.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule buildLastResourceRule() { return this.resourceRules.get(resourceRules.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule buildMatchingResourceRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder item: resourceRules) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule buildMatchingResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder item : + resourceRules) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingResourceRule(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder item: resourceRules) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder item : + resourceRules) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withResourceRules(java.util.List resourceRules) { - if (this.resourceRules != null) { _visitables.get("resourceRules").removeAll(this.resourceRules);} - if (resourceRules != null) {this.resourceRules = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item : resourceRules){this.addToResourceRules(item);}} else { this.resourceRules = null;} return (A) this; + + public A withResourceRules( + java.util.List resourceRules) { + if (this.resourceRules != null) { + _visitables.get("resourceRules").removeAll(this.resourceRules); + } + if (resourceRules != null) { + this.resourceRules = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item : resourceRules) { + this.addToResourceRules(item); + } + } else { + this.resourceRules = null; + } + return (A) this; } - public A withResourceRules(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule... resourceRules) { - if (this.resourceRules != null) {this.resourceRules.clear();} - if (resourceRules != null) {for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item :resourceRules){ this.addToResourceRules(item);}} return (A) this; + + public A withResourceRules( + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule... resourceRules) { + if (this.resourceRules != null) { + this.resourceRules.clear(); + } + if (resourceRules != null) { + for (io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item : resourceRules) { + this.addToResourceRules(item); + } + } + return (A) this; } + public java.lang.Boolean hasResourceRules() { return resourceRules != null && !resourceRules.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested addNewResourceRule() { - return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl.ResourceRulesNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + addNewResourceRule() { + return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl + .ResourceRulesNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested addNewResourceRuleLike(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item) { - return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl.ResourceRulesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + addNewResourceRuleLike(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item) { + return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl + .ResourceRulesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested setNewResourceRuleLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item) { - return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl.ResourceRulesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + setNewResourceRuleLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item) { + return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl + .ResourceRulesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested editResourceRule(java.lang.Integer index) { - if (resourceRules.size() <= index) throw new RuntimeException("Can't edit resourceRules. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editResourceRule(java.lang.Integer index) { + if (resourceRules.size() <= index) + throw new RuntimeException("Can't edit resourceRules. Index exceeds size."); return setNewResourceRuleLike(index, buildResourceRule(index)); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested editFirstResourceRule() { - if (resourceRules.size() == 0) throw new RuntimeException("Can't edit first resourceRules. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editFirstResourceRule() { + if (resourceRules.size() == 0) + throw new RuntimeException("Can't edit first resourceRules. The list is empty."); return setNewResourceRuleLike(0, buildResourceRule(0)); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested editLastResourceRule() { + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editLastResourceRule() { int index = resourceRules.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last resourceRules. The list is empty."); return setNewResourceRuleLike(index, buildResourceRule(index)); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested editMatchingResourceRule(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + A> + editMatchingResourceRule( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(item);_visitables.get("subjects").add(index >= 0 ? index : _visitables.get("subjects").size(), builder);this.subjects.add(index >= 0 ? index : subjects.size(), builder); return (A)this; + + public A addToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2Subject item) { + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(item); + _visitables + .get("subjects") + .add(index >= 0 ? index : _visitables.get("subjects").size(), builder); + this.subjects.add(index >= 0 ? index : subjects.size(), builder); + return (A) this; } - public A setToSubjects(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2Subject item) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(item); - if (index < 0 || index >= _visitables.get("subjects").size()) { _visitables.get("subjects").add(builder); } else { _visitables.get("subjects").set(index, builder);} - if (index < 0 || index >= subjects.size()) { subjects.add(builder); } else { subjects.set(index, builder);} - return (A)this; + + public A setToSubjects( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2Subject item) { + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(item); + if (index < 0 || index >= _visitables.get("subjects").size()) { + _visitables.get("subjects").add(builder); + } else { + _visitables.get("subjects").set(index, builder); + } + if (index < 0 || index >= subjects.size()) { + subjects.add(builder); + } else { + subjects.set(index, builder); + } + return (A) this; } + public A addToSubjects(io.kubernetes.client.openapi.models.V1beta2Subject... items) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2Subject item : items) {io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(item);_visitables.get("subjects").add(builder);this.subjects.add(builder);} return (A)this; + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta2Subject item : items) { + io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(item); + _visitables.get("subjects").add(builder); + this.subjects.add(builder); + } + return (A) this; } - public A addAllToSubjects(java.util.Collection items) { - if (this.subjects == null) {this.subjects = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2Subject item : items) {io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(item);_visitables.get("subjects").add(builder);this.subjects.add(builder);} return (A)this; + + public A addAllToSubjects( + java.util.Collection items) { + if (this.subjects == null) { + this.subjects = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V1beta2Subject item : items) { + io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(item); + _visitables.get("subjects").add(builder); + this.subjects.add(builder); + } + return (A) this; } + public A removeFromSubjects(io.kubernetes.client.openapi.models.V1beta2Subject... items) { - for (io.kubernetes.client.openapi.models.V1beta2Subject item : items) {io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(item);_visitables.get("subjects").remove(builder);if (this.subjects != null) {this.subjects.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V1beta2Subject item : items) { + io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(item); + _visitables.get("subjects").remove(builder); + if (this.subjects != null) { + this.subjects.remove(builder); + } + } + return (A) this; } - public A removeAllFromSubjects(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta2Subject item : items) {io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder = new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(item);_visitables.get("subjects").remove(builder);if (this.subjects != null) {this.subjects.remove(builder);}} return (A)this; + + public A removeAllFromSubjects( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V1beta2Subject item : items) { + io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(item); + _visitables.get("subjects").remove(builder); + if (this.subjects != null) { + this.subjects.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromSubjects(java.util.function.Predicate predicate) { + + public A removeMatchingFromSubjects( + java.util.function.Predicate + predicate) { if (subjects == null) return (A) this; - final Iterator each = subjects.iterator(); + final Iterator each = + subjects.iterator(); final List visitables = _visitables.get("subjects"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder = each.next(); @@ -278,144 +701,263 @@ public A removeMatchingFromSubjects(java.util.function.Predicate getSubjects() { return subjects != null ? build(subjects) : null; } + public java.util.List buildSubjects() { return subjects != null ? build(subjects) : null; } + public io.kubernetes.client.openapi.models.V1beta2Subject buildSubject(java.lang.Integer index) { return this.subjects.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta2Subject buildFirstSubject() { return this.subjects.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta2Subject buildLastSubject() { return this.subjects.get(subjects.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta2Subject buildMatchingSubject(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2SubjectBuilder item: subjects) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta2Subject buildMatchingSubject( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2SubjectBuilder item : subjects) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingSubject(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2SubjectBuilder item: subjects) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingSubject( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2SubjectBuilder item : subjects) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withSubjects(java.util.List subjects) { - if (this.subjects != null) { _visitables.get("subjects").removeAll(this.subjects);} - if (subjects != null) {this.subjects = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta2Subject item : subjects){this.addToSubjects(item);}} else { this.subjects = null;} return (A) this; + + public A withSubjects( + java.util.List subjects) { + if (this.subjects != null) { + _visitables.get("subjects").removeAll(this.subjects); + } + if (subjects != null) { + this.subjects = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta2Subject item : subjects) { + this.addToSubjects(item); + } + } else { + this.subjects = null; + } + return (A) this; } + public A withSubjects(io.kubernetes.client.openapi.models.V1beta2Subject... subjects) { - if (this.subjects != null) {this.subjects.clear();} - if (subjects != null) {for (io.kubernetes.client.openapi.models.V1beta2Subject item :subjects){ this.addToSubjects(item);}} return (A) this; + if (this.subjects != null) { + this.subjects.clear(); + } + if (subjects != null) { + for (io.kubernetes.client.openapi.models.V1beta2Subject item : subjects) { + this.addToSubjects(item); + } + } + return (A) this; } + public java.lang.Boolean hasSubjects() { return subjects != null && !subjects.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested addNewSubject() { - return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl.SubjectsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + addNewSubject() { + return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl + .SubjectsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested addNewSubjectLike(io.kubernetes.client.openapi.models.V1beta2Subject item) { - return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl.SubjectsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + addNewSubjectLike(io.kubernetes.client.openapi.models.V1beta2Subject item) { + return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl + .SubjectsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested setNewSubjectLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2Subject item) { - return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl.SubjectsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + setNewSubjectLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2Subject item) { + return new io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluentImpl + .SubjectsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested editSubject(java.lang.Integer index) { - if (subjects.size() <= index) throw new RuntimeException("Can't edit subjects. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + editSubject(java.lang.Integer index) { + if (subjects.size() <= index) + throw new RuntimeException("Can't edit subjects. Index exceeds size."); return setNewSubjectLike(index, buildSubject(index)); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested editFirstSubject() { - if (subjects.size() == 0) throw new RuntimeException("Can't edit first subjects. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + editFirstSubject() { + if (subjects.size() == 0) + throw new RuntimeException("Can't edit first subjects. The list is empty."); return setNewSubjectLike(0, buildSubject(0)); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested editLastSubject() { + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + editLastSubject() { int index = subjects.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last subjects. The list is empty."); return setNewSubjectLike(index, buildSubject(index)); } - public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested editMatchingSubject(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested + editMatchingSubject( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.NonResourceRulesNested,io.kubernetes.client.fluent.Nested{ - NonResourceRulesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item) { + + public class NonResourceRulesNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .NonResourceRulesNested< + N>, + io.kubernetes.client.fluent.Nested { + NonResourceRulesNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRule item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(this, item); } + NonResourceRulesNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2NonResourcePolicyRuleBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta2PolicyRulesWithSubjectsFluentImpl.this.setToNonResourceRules(index,builder.build()); + return (N) + V1beta2PolicyRulesWithSubjectsFluentImpl.this.setToNonResourceRules( + index, builder.build()); } + public N endNonResourceRule() { return and(); } - } - public class ResourceRulesNestedImpl extends io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.ResourceRulesNested,io.kubernetes.client.fluent.Nested{ - ResourceRulesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item) { + + public class ResourceRulesNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .ResourceRulesNested< + N>, + io.kubernetes.client.fluent.Nested { + ResourceRulesNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(this, item); } + ResourceRulesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta2PolicyRulesWithSubjectsFluentImpl.this.setToResourceRules(index,builder.build()); + return (N) + V1beta2PolicyRulesWithSubjectsFluentImpl.this.setToResourceRules(index, builder.build()); } + public N endResourceRule() { return and(); } - } - public class SubjectsNestedImpl extends io.kubernetes.client.openapi.models.V1beta2SubjectFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested,io.kubernetes.client.fluent.Nested{ - SubjectsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2Subject item) { + + public class SubjectsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2SubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent.SubjectsNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta2PolicyRulesWithSubjectsFluent + .SubjectsNested< + N>, + io.kubernetes.client.fluent.Nested { + SubjectsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V1beta2Subject item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(this, item); } + SubjectsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V1beta2SubjectBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2SubjectBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta2PolicyRulesWithSubjectsFluentImpl.this.setToSubjects(index,builder.build()); + return (N) + V1beta2PolicyRulesWithSubjectsFluentImpl.this.setToSubjects(index, builder.build()); } + public N endSubject() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationBuilder.java index 7570251430..7f079af5fe 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2PriorityLevelConfigurationBuilder extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2PriorityLevelConfigurationBuilder + extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder> { public V1beta2PriorityLevelConfigurationBuilder() { this(false); } + public V1beta2PriorityLevelConfigurationBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2PriorityLevelConfiguration(), validationEnabled); } - public V1beta2PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent fluent) { + + public V1beta2PriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent fluent) { this(fluent, false); } - public V1beta2PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2PriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2PriorityLevelConfiguration(), validationEnabled); } - public V1beta2PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration instance) { + + public V1beta2PriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration instance) { this(fluent, instance, false); } - public V1beta2PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2PriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V1beta2PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.mod fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration instance) { - this(instance,false); + + public V1beta2PriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration instance) { + this(instance, false); } - public V1beta2PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2PriorityLevelConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V1beta2PriorityLevelConfigurationBuilder(io.kubernetes.client.openapi.mod this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration build() { V1beta2PriorityLevelConfiguration buildable = new V1beta2PriorityLevelConfiguration(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration bui buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2PriorityLevelConfigurationBuilder that = (V1beta2PriorityLevelConfigurationBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationConditionBuilder.java index d3564df987..41956c922e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationConditionBuilder.java @@ -1,26 +1,58 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2PriorityLevelConfigurationConditionBuilder extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2PriorityLevelConfigurationConditionBuilder + extends io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder> { public V1beta2PriorityLevelConfigurationConditionBuilder() { this(false); } + public V1beta2PriorityLevelConfigurationConditionBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2PriorityLevelConfigurationCondition(), validationEnabled); } - public V1beta2PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent fluent) { + + public V1beta2PriorityLevelConfigurationConditionBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent + fluent) { this(fluent, false); } - public V1beta2PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2PriorityLevelConfigurationConditionBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent + fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2PriorityLevelConfigurationCondition(), validationEnabled); } - public V1beta2PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent fluent,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition instance) { + + public V1beta2PriorityLevelConfigurationConditionBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent + fluent, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition instance) { this(fluent, instance, false); } - public V1beta2PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent fluent,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2PriorityLevelConfigurationConditionBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent + fluent, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +63,18 @@ public V1beta2PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.op fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition instance) { - this(instance,false); + + public V1beta2PriorityLevelConfigurationConditionBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition instance) { + this(instance, false); } - public V1beta2PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2PriorityLevelConfigurationConditionBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,12 +85,15 @@ public V1beta2PriorityLevelConfigurationConditionBuilder(io.kubernetes.client.op this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition build() { - V1beta2PriorityLevelConfigurationCondition buildable = new V1beta2PriorityLevelConfigurationCondition(); + V1beta2PriorityLevelConfigurationCondition buildable = + new V1beta2PriorityLevelConfigurationCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); buildable.setMessage(fluent.getMessage()); buildable.setReason(fluent.getReason()); @@ -61,18 +101,24 @@ public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCond buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1beta2PriorityLevelConfigurationConditionBuilder that = (V1beta2PriorityLevelConfigurationConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1beta2PriorityLevelConfigurationConditionBuilder that = + (V1beta2PriorityLevelConfigurationConditionBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationConditionFluent.java index abc99d90a5..2472675221 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationConditionFluent.java @@ -1,54 +1,65 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2PriorityLevelConfigurationConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta2PriorityLevelConfigurationConditionFluent< + A extends + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationConditionFluentImpl.java index 56c652d8f8..673be5d37b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationConditionFluentImpl.java @@ -1,19 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1beta2PriorityLevelConfigurationConditionFluentImpl< + A extends + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent< + A> { + public V1beta2PriorityLevelConfigurationConditionFluentImpl() {} - /** - * Generated - */ -public class V1beta2PriorityLevelConfigurationConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent{ - public V1beta2PriorityLevelConfigurationConditionFluentImpl() { - } - public V1beta2PriorityLevelConfigurationConditionFluentImpl(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition instance) { + public V1beta2PriorityLevelConfigurationConditionFluentImpl( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,103 +32,120 @@ public V1beta2PriorityLevelConfigurationConditionFluentImpl(io.kubernetes.client this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta2PriorityLevelConfigurationConditionFluentImpl that = (V1beta2PriorityLevelConfigurationConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + V1beta2PriorityLevelConfigurationConditionFluentImpl that = + (V1beta2PriorityLevelConfigurationConditionFluentImpl) o; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationFluent.java index 11ee427a85..3a244eead5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationFluent.java @@ -1,93 +1,168 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2PriorityLevelConfigurationFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta2PriorityLevelConfigurationFluent< + A extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested< + A> + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested< + A> + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested< + A> + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec getSpec(); + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec item); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec item); - + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested + withNewSpecLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested + editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus getStatus(); + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus buildStatus(); - public A withStatus(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus status); + + public A withStatus( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus item); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested + withNewStatusLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent + .SpecNested< + N>> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent + .StatusNested< + N>> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationFluentImpl.java index 89c641919f..20fef74ba5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta2PriorityLevelConfigurationFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent { + public V1beta2PriorityLevelConfigurationFluentImpl() {} - /** - * Generated - */ -public class V1beta2PriorityLevelConfigurationFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent{ - public V1beta2PriorityLevelConfigurationFluentImpl() { - } - public V1beta2PriorityLevelConfigurationFluentImpl(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration instance) { + public V1beta2PriorityLevelConfigurationFluentImpl( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,346 @@ public V1beta2PriorityLevelConfigurationFluentImpl(io.kubernetes.client.openapi. this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecBuilder spec; private io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested< + A> + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested< + A> + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested< + A> + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } - public A withSpec(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec spec) { + + public A withSpec( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecBuilder( + spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec item) { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested + withNewSpecLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec item) { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested + editOrNewSpecLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } - public A withStatus(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus status) { + + public A withStatus( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusBuilder( + status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus item) { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested + withNewStatusLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus item) { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta2PriorityLevelConfigurationFluentImpl that = (V1beta2PriorityLevelConfigurationFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + V1beta2PriorityLevelConfigurationFluentImpl that = + (V1beta2PriorityLevelConfigurationFluentImpl) o; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent + .MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V1beta2PriorityLevelConfigurationFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent + .SpecNested< + N>, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecBuilder( + this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecBuilder( + this); } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecBuilder builder; + public N and() { return (N) V1beta2PriorityLevelConfigurationFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested,io.kubernetes.client.fluent.Nested{ - StatusNestedImpl(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusBuilder(this, item); + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent.StatusNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent + .StatusNested< + N>, + io.kubernetes.client.fluent.Nested { + StatusNestedImpl( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus item) { + this.builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusBuilder( + this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusBuilder( + this); } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusBuilder builder; + public N and() { return (N) V1beta2PriorityLevelConfigurationFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationListBuilder.java index f47557701f..a58c542864 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2PriorityLevelConfigurationListBuilder extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2PriorityLevelConfigurationListBuilder + extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationList, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListBuilder> { public V1beta2PriorityLevelConfigurationListBuilder() { this(false); } + public V1beta2PriorityLevelConfigurationListBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2PriorityLevelConfigurationList(), validationEnabled); } - public V1beta2PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent fluent) { + + public V1beta2PriorityLevelConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent fluent) { this(fluent, false); } - public V1beta2PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2PriorityLevelConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2PriorityLevelConfigurationList(), validationEnabled); } - public V1beta2PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent fluent,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationList instance) { + + public V1beta2PriorityLevelConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent fluent, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationList instance) { this(fluent, instance, false); } - public V1beta2PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent fluent,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2PriorityLevelConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent fluent, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V1beta2PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationList instance) { - this(instance,false); + + public V1beta2PriorityLevelConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationList instance) { + this(instance, false); } - public V1beta2PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2PriorityLevelConfigurationListBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V1beta2PriorityLevelConfigurationListBuilder(io.kubernetes.client.openapi this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationList build() { V1beta2PriorityLevelConfigurationList buildable = new V1beta2PriorityLevelConfigurationList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,24 @@ public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationList buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1beta2PriorityLevelConfigurationListBuilder that = (V1beta2PriorityLevelConfigurationListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1beta2PriorityLevelConfigurationListBuilder that = + (V1beta2PriorityLevelConfigurationListBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationListFluent.java index 58feee6f6f..c93e782938 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationListFluent.java @@ -1,95 +1,204 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2PriorityLevelConfigurationListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta2PriorityLevelConfigurationListFluent< + A extends + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item); - public A addToItems(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration... items); - public A addAllToItems(java.util.Collection items); - public A removeFromItems(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item); + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item); + + public A addToItems( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration... items); + + public A addAllToItems( + java.util.Collection + items); + + public A removeFromItems( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration... items); + + public A removeAllFromItems( + java.util.Collection + items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getItems(); - public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration buildItem(java.lang.Integer index); + public java.util.List + getItems(); + + public java.util.List + buildItems(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration buildFirstItem(); + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration buildLastItem(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); - public A withItems(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration... items); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder> + predicate); + + public A withItems( + java.util.List items); + + public A withItems( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + addNewItem(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + addNewItemLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editFirstItem(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editLastItem(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent>{ + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .MetadataNested< + A> + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .MetadataNested< + A> + editMetadata(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluent< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationListFluentImpl.java index ac700ab4ed..595ff49656 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationListFluentImpl.java @@ -1,26 +1,30 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V1beta2PriorityLevelConfigurationListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent{ - public V1beta2PriorityLevelConfigurationListFluentImpl() { - } - public V1beta2PriorityLevelConfigurationListFluentImpl(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationList instance) { + +/** Generated */ +public class V1beta2PriorityLevelConfigurationListFluentImpl< + A extends + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent { + public V1beta2PriorityLevelConfigurationListFluentImpl() {} + + public V1beta2PriorityLevelConfigurationListFluentImpl( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,233 +32,473 @@ public V1beta2PriorityLevelConfigurationListFluentImpl(io.kubernetes.client.open this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder> + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } - public A addToItems(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item : items) {io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addToItems( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration... items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item : items) { + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item : items) {io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection + items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item : items) { + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A removeFromItems(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration... items) { - for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item : items) {io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeFromItems( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration... items) { + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item : items) { + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item : items) {io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item : items) { + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator + each = items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getItems() { + public java.util.List + getItems() { return items != null ? build(items) : null; } - public java.util.List buildItems() { + + public java.util.List + buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder item : + items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder item : + items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } - public A withItems(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item :items){ this.addToItems(item);}} return (A) this; + + public A withItems( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration... items) { + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + addNewItem() { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item) { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + addNewItemLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item) { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item) { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item) { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + A> + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .MetadataNested< + A> + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .MetadataNested< + A> + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta2PriorityLevelConfigurationListFluentImpl that = (V1beta2PriorityLevelConfigurationListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + V1beta2PriorityLevelConfigurationListFluentImpl that = + (V1beta2PriorityLevelConfigurationListFluentImpl) o; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfiguration item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder( + this, item); } + ItemsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta2PriorityLevelConfigurationListFluentImpl.this.setToItems(index,builder.build()); + return (N) + V1beta2PriorityLevelConfigurationListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V1beta2PriorityLevelConfigurationListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationReferenceBuilder.java index fcef6cc36f..be97891de2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationReferenceBuilder.java @@ -1,58 +1,104 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2PriorityLevelConfigurationReferenceBuilder extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2PriorityLevelConfigurationReferenceBuilder + extends io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationReferenceFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceBuilder> { public V1beta2PriorityLevelConfigurationReferenceBuilder() { this(false); } + public V1beta2PriorityLevelConfigurationReferenceBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2PriorityLevelConfigurationReference(), validationEnabled); } - public V1beta2PriorityLevelConfigurationReferenceBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent fluent) { + + public V1beta2PriorityLevelConfigurationReferenceBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent + fluent) { this(fluent, false); } - public V1beta2PriorityLevelConfigurationReferenceBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2PriorityLevelConfigurationReferenceBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent + fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2PriorityLevelConfigurationReference(), validationEnabled); } - public V1beta2PriorityLevelConfigurationReferenceBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent fluent,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference instance) { + + public V1beta2PriorityLevelConfigurationReferenceBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent + fluent, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference instance) { this(fluent, instance, false); } - public V1beta2PriorityLevelConfigurationReferenceBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent fluent,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2PriorityLevelConfigurationReferenceBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent + fluent, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2PriorityLevelConfigurationReferenceBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference instance) { - this(instance,false); + + public V1beta2PriorityLevelConfigurationReferenceBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference instance) { + this(instance, false); } - public V1beta2PriorityLevelConfigurationReferenceBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2PriorityLevelConfigurationReferenceBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference build() { - V1beta2PriorityLevelConfigurationReference buildable = new V1beta2PriorityLevelConfigurationReference(); + V1beta2PriorityLevelConfigurationReference buildable = + new V1beta2PriorityLevelConfigurationReference(); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1beta2PriorityLevelConfigurationReferenceBuilder that = (V1beta2PriorityLevelConfigurationReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1beta2PriorityLevelConfigurationReferenceBuilder that = + (V1beta2PriorityLevelConfigurationReferenceBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationReferenceFluent.java index f7d6b8a71b..8d27168088 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationReferenceFluent.java @@ -1,23 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2PriorityLevelConfigurationReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta2PriorityLevelConfigurationReferenceFluent< + A extends + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationReferenceFluentImpl.java index b87da39221..71186ece79 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationReferenceFluentImpl.java @@ -1,48 +1,62 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta2PriorityLevelConfigurationReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent{ - public V1beta2PriorityLevelConfigurationReferenceFluentImpl() { - } - public V1beta2PriorityLevelConfigurationReferenceFluentImpl(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference instance) { - this.withName(instance.getName()); +/** Generated */ +public class V1beta2PriorityLevelConfigurationReferenceFluentImpl< + A extends + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReferenceFluent< + A> { + public V1beta2PriorityLevelConfigurationReferenceFluentImpl() {} + public V1beta2PriorityLevelConfigurationReferenceFluentImpl( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationReference instance) { + this.withName(instance.getName()); } + private java.lang.String name; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta2PriorityLevelConfigurationReferenceFluentImpl that = (V1beta2PriorityLevelConfigurationReferenceFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + V1beta2PriorityLevelConfigurationReferenceFluentImpl that = + (V1beta2PriorityLevelConfigurationReferenceFluentImpl) o; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, super.hashCode()); + return java.util.Objects.hash(name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationSpecBuilder.java index 5158ac62cd..f32b1bb0ce 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationSpecBuilder.java @@ -1,63 +1,103 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2PriorityLevelConfigurationSpecBuilder extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2PriorityLevelConfigurationSpecBuilder + extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecBuilder> { public V1beta2PriorityLevelConfigurationSpecBuilder() { this(false); } + public V1beta2PriorityLevelConfigurationSpecBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2PriorityLevelConfigurationSpec(), validationEnabled); } - public V1beta2PriorityLevelConfigurationSpecBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent fluent) { + + public V1beta2PriorityLevelConfigurationSpecBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent fluent) { this(fluent, false); } - public V1beta2PriorityLevelConfigurationSpecBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2PriorityLevelConfigurationSpecBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2PriorityLevelConfigurationSpec(), validationEnabled); } - public V1beta2PriorityLevelConfigurationSpecBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec instance) { + + public V1beta2PriorityLevelConfigurationSpecBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec instance) { this(fluent, instance, false); } - public V1beta2PriorityLevelConfigurationSpecBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent fluent,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2PriorityLevelConfigurationSpecBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent fluent, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLimited(instance.getLimited()); fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2PriorityLevelConfigurationSpecBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec instance) { - this(instance,false); + + public V1beta2PriorityLevelConfigurationSpecBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec instance) { + this(instance, false); } - public V1beta2PriorityLevelConfigurationSpecBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2PriorityLevelConfigurationSpecBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLimited(instance.getLimited()); this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec build() { V1beta2PriorityLevelConfigurationSpec buildable = new V1beta2PriorityLevelConfigurationSpec(); buildable.setLimited(fluent.getLimited()); buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1beta2PriorityLevelConfigurationSpecBuilder that = (V1beta2PriorityLevelConfigurationSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1beta2PriorityLevelConfigurationSpecBuilder that = + (V1beta2PriorityLevelConfigurationSpecBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationSpecFluent.java index d91a0160d6..f408e89ff5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationSpecFluent.java @@ -1,44 +1,84 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2PriorityLevelConfigurationSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1beta2PriorityLevelConfigurationSpecFluent< + A extends + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildLimited instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration getLimited(); - public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration buildLimited(); - public A withLimited(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration limited); + + public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration + buildLimited(); + + public A withLimited( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration limited); + public java.lang.Boolean hasLimited(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent.LimitedNested withNewLimited(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent.LimitedNested withNewLimitedLike(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration item); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent.LimitedNested editLimited(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent.LimitedNested editOrNewLimited(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent.LimitedNested editOrNewLimitedLike(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + withNewLimited(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + withNewLimitedLike( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + editLimited(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + editOrNewLimited(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + editOrNewLimitedLike( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration item); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface LimitedNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent>{ + + public interface LimitedNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluent< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent + .LimitedNested< + N>> { public N and(); + public N endLimited(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationSpecFluentImpl.java index afe15c7d3f..4c59ea72c3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationSpecFluentImpl.java @@ -1,103 +1,175 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta2PriorityLevelConfigurationSpecFluentImpl< + A extends + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent { + public V1beta2PriorityLevelConfigurationSpecFluentImpl() {} - /** - * Generated - */ -public class V1beta2PriorityLevelConfigurationSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent{ - public V1beta2PriorityLevelConfigurationSpecFluentImpl() { - } - public V1beta2PriorityLevelConfigurationSpecFluentImpl(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec instance) { + public V1beta2PriorityLevelConfigurationSpecFluentImpl( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpec instance) { this.withLimited(instance.getLimited()); this.withType(instance.getType()); - } - private io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationBuilder limited; + + private io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationBuilder + limited; private java.lang.String type; - + /** * This method has been deprecated, please use method buildLimited instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration getLimited() { - return this.limited!=null ?this.limited.build():null; + return this.limited != null ? this.limited.build() : null; } - public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration buildLimited() { - return this.limited!=null ?this.limited.build():null; + + public io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration + buildLimited() { + return this.limited != null ? this.limited.build() : null; } - public A withLimited(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration limited) { + + public A withLimited( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration limited) { _visitables.get("limited").remove(this.limited); - if (limited!=null){ this.limited= new io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationBuilder(limited); _visitables.get("limited").add(this.limited);} return (A) this; + if (limited != null) { + this.limited = + new io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationBuilder( + limited); + _visitables.get("limited").add(this.limited); + } + return (A) this; } + public java.lang.Boolean hasLimited() { return this.limited != null; } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent.LimitedNested withNewLimited() { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluentImpl.LimitedNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + withNewLimited() { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluentImpl + .LimitedNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent.LimitedNested withNewLimitedLike(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration item) { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluentImpl.LimitedNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + withNewLimitedLike( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration item) { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluentImpl + .LimitedNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent.LimitedNested editLimited() { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + editLimited() { return withNewLimitedLike(getLimited()); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent.LimitedNested editOrNewLimited() { - return withNewLimitedLike(getLimited() != null ? getLimited(): new io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + editOrNewLimited() { + return withNewLimitedLike( + getLimited() != null + ? getLimited() + : new io.kubernetes.client.openapi.models + .V1beta2LimitedPriorityLevelConfigurationBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent.LimitedNested editOrNewLimitedLike(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration item) { - return withNewLimitedLike(getLimited() != null ? getLimited(): item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent + .LimitedNested< + A> + editOrNewLimitedLike( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration item) { + return withNewLimitedLike(getLimited() != null ? getLimited() : item); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V1beta2PriorityLevelConfigurationSpecFluentImpl that = (V1beta2PriorityLevelConfigurationSpecFluentImpl) o; - if (limited != null ? !limited.equals(that.limited) :that.limited != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + V1beta2PriorityLevelConfigurationSpecFluentImpl that = + (V1beta2PriorityLevelConfigurationSpecFluentImpl) o; + if (limited != null ? !limited.equals(that.limited) : that.limited != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(limited, type, super.hashCode()); + return java.util.Objects.hash(limited, type, super.hashCode()); } - public class LimitedNestedImpl extends io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent.LimitedNested,io.kubernetes.client.fluent.Nested{ - LimitedNestedImpl(io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationBuilder(this, item); + + public class LimitedNestedImpl + extends io.kubernetes.client.openapi.models + .V1beta2LimitedPriorityLevelConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent + .LimitedNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationSpecFluent + .LimitedNested< + N>, + io.kubernetes.client.fluent.Nested { + LimitedNestedImpl( + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfiguration item) { + this.builder = + new io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationBuilder( + this, item); } + LimitedNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationBuilder( + this); } + io.kubernetes.client.openapi.models.V1beta2LimitedPriorityLevelConfigurationBuilder builder; + public N and() { return (N) V1beta2PriorityLevelConfigurationSpecFluentImpl.this.withLimited(builder.build()); } + public N endLimited() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationStatusBuilder.java index d75b7d3dbe..5910ccc1ab 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationStatusBuilder.java @@ -1,58 +1,99 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2PriorityLevelConfigurationStatusBuilder extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2PriorityLevelConfigurationStatusBuilder + extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusBuilder> { public V1beta2PriorityLevelConfigurationStatusBuilder() { this(false); } + public V1beta2PriorityLevelConfigurationStatusBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2PriorityLevelConfigurationStatus(), validationEnabled); } - public V1beta2PriorityLevelConfigurationStatusBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent fluent) { + + public V1beta2PriorityLevelConfigurationStatusBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent fluent) { this(fluent, false); } - public V1beta2PriorityLevelConfigurationStatusBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2PriorityLevelConfigurationStatusBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2PriorityLevelConfigurationStatus(), validationEnabled); } - public V1beta2PriorityLevelConfigurationStatusBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent fluent,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus instance) { + + public V1beta2PriorityLevelConfigurationStatusBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent fluent, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus instance) { this(fluent, instance, false); } - public V1beta2PriorityLevelConfigurationStatusBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent fluent,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2PriorityLevelConfigurationStatusBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent fluent, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditions(instance.getConditions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2PriorityLevelConfigurationStatusBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus instance) { - this(instance,false); + + public V1beta2PriorityLevelConfigurationStatusBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus instance) { + this(instance, false); } - public V1beta2PriorityLevelConfigurationStatusBuilder(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2PriorityLevelConfigurationStatusBuilder( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditions(instance.getConditions()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus build() { - V1beta2PriorityLevelConfigurationStatus buildable = new V1beta2PriorityLevelConfigurationStatus(); + V1beta2PriorityLevelConfigurationStatus buildable = + new V1beta2PriorityLevelConfigurationStatus(); buildable.setConditions(fluent.getConditions()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V1beta2PriorityLevelConfigurationStatusBuilder that = (V1beta2PriorityLevelConfigurationStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V1beta2PriorityLevelConfigurationStatusBuilder that = + (V1beta2PriorityLevelConfigurationStatusBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationStatusFluent.java index 47b5e62740..36cccda488 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationStatusFluent.java @@ -1,57 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2PriorityLevelConfigurationStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item); - public A addToConditions(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition... items); - public A addAllToConditions(java.util.Collection items); - public A removeFromConditions(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - +/** Generated */ +public interface V1beta2PriorityLevelConfigurationStatusFluent< + A extends + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item); + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item); + + public A addToConditions( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition... items); + + public A addAllToConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition> + items); + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition... items); + + public A removeAllFromConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition> + items); + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder> + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition buildCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition buildFirstCondition(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); - public A withConditions(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition... conditions); + public java.util.List< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition> + getConditions(); + + public java.util.List< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition> + buildConditions(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition + buildCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition + buildFirstCondition(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition + buildLastCondition(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionBuilder> + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder> + predicate); + + public A withConditions( + java.util.List + conditions); + + public A withConditions( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent>{ + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + addNewCondition(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editLastCondition(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionBuilder> + predicate); + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluent< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationStatusFluentImpl.java index 6c5562b849..32bf016465 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2PriorityLevelConfigurationStatusFluentImpl.java @@ -1,163 +1,400 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V1beta2PriorityLevelConfigurationStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent{ - public V1beta2PriorityLevelConfigurationStatusFluentImpl() { - } - public V1beta2PriorityLevelConfigurationStatusFluentImpl(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus instance) { - this.withConditions(instance.getConditions()); +/** Generated */ +public class V1beta2PriorityLevelConfigurationStatusFluentImpl< + A extends + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent< + A> { + public V1beta2PriorityLevelConfigurationStatusFluentImpl() {} + public V1beta2PriorityLevelConfigurationStatusFluentImpl( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatus instance) { + this.withConditions(instance.getConditions()); } - private java.util.ArrayList conditions; - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder> + conditions; + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder( + item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder( + item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } - public A addToConditions(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item : items) {io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addToConditions( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition... items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item : + items) { + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder + builder = + new io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item : items) {io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition> + items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item : + items) { + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder + builder = + new io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition... items) { - for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item : items) {io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition... items) { + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item : + items) { + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder + builder = + new io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item : items) {io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition> + items) { + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item : + items) { + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder + builder = + new io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder> + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder> + each = conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder + builder = each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions() { + public java.util.List< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition> + getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition> + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition + buildCondition(java.lang.Integer index) { return this.conditions.get(index).build(); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition buildFirstCondition() { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition + buildFirstCondition() { return this.conditions.get(0).build(); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition buildLastCondition() { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition + buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder + item : conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder + item : conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List + conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item : + conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } - public A withConditions(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item :conditions){ this.addToConditions(item);}} return (A) this; + + public A withConditions( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition... + conditions) { + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item : + conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + addNewCondition() { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item) { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item) { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item) { - return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item) { + return new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models + .V1beta2PriorityLevelConfigurationConditionFluentImpl< + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + N>> + implements io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationStatusFluent + .ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder( + this, item); } + ConditionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder( + this); } + io.kubernetes.client.openapi.models.V1beta2PriorityLevelConfigurationConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V1beta2PriorityLevelConfigurationStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) + V1beta2PriorityLevelConfigurationStatusFluentImpl.this.setToConditions( + index, builder.build()); } + public N endCondition() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2QueuingConfigurationBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2QueuingConfigurationBuilder.java index d724896bb6..6b4b3ebf5c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2QueuingConfigurationBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2QueuingConfigurationBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2QueuingConfigurationBuilder extends io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2QueuingConfigurationBuilder + extends io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluentImpl< + io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration, + io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationBuilder> { public V1beta2QueuingConfigurationBuilder() { this(false); } + public V1beta2QueuingConfigurationBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2QueuingConfiguration(), validationEnabled); } - public V1beta2QueuingConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent fluent) { + + public V1beta2QueuingConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent fluent) { this(fluent, false); } - public V1beta2QueuingConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2QueuingConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2QueuingConfiguration(), validationEnabled); } - public V1beta2QueuingConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration instance) { + + public V1beta2QueuingConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration instance) { this(fluent, instance, false); } - public V1beta2QueuingConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent fluent,io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2QueuingConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent fluent, + io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withHandSize(instance.getHandSize()); fluent.withQueueLengthLimit(instance.getQueueLengthLimit()); fluent.withQueues(instance.getQueues()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2QueuingConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration instance) { - this(instance,false); + + public V1beta2QueuingConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration instance) { + this(instance, false); } - public V1beta2QueuingConfigurationBuilder(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2QueuingConfigurationBuilder( + io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withHandSize(instance.getHandSize()); this.withQueueLengthLimit(instance.getQueueLengthLimit()); this.withQueues(instance.getQueues()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration build() { V1beta2QueuingConfiguration buildable = new V1beta2QueuingConfiguration(); buildable.setHandSize(fluent.getHandSize()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration build() { buildable.setQueues(fluent.getQueues()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2QueuingConfigurationBuilder that = (V1beta2QueuingConfigurationBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2QueuingConfigurationFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2QueuingConfigurationFluent.java index c6dd3d467f..5ddef2e046 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2QueuingConfigurationFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2QueuingConfigurationFluent.java @@ -1,23 +1,36 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2QueuingConfigurationFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta2QueuingConfigurationFluent< + A extends io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getHandSize(); + public A withHandSize(java.lang.Integer handSize); + public java.lang.Boolean hasHandSize(); + public java.lang.Integer getQueueLengthLimit(); + public A withQueueLengthLimit(java.lang.Integer queueLengthLimit); + public java.lang.Boolean hasQueueLengthLimit(); + public java.lang.Integer getQueues(); + public A withQueues(java.lang.Integer queues); + public java.lang.Boolean hasQueues(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2QueuingConfigurationFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2QueuingConfigurationFluentImpl.java index 70d04f9134..fca5405b1d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2QueuingConfigurationFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2QueuingConfigurationFluentImpl.java @@ -1,65 +1,89 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta2QueuingConfigurationFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent { + public V1beta2QueuingConfigurationFluentImpl() {} - /** - * Generated - */ -public class V1beta2QueuingConfigurationFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2QueuingConfigurationFluent{ - public V1beta2QueuingConfigurationFluentImpl() { - } - public V1beta2QueuingConfigurationFluentImpl(io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration instance) { + public V1beta2QueuingConfigurationFluentImpl( + io.kubernetes.client.openapi.models.V1beta2QueuingConfiguration instance) { this.withHandSize(instance.getHandSize()); this.withQueueLengthLimit(instance.getQueueLengthLimit()); this.withQueues(instance.getQueues()); - } + private java.lang.Integer handSize; private java.lang.Integer queueLengthLimit; private java.lang.Integer queues; + public java.lang.Integer getHandSize() { return this.handSize; } + public A withHandSize(java.lang.Integer handSize) { - this.handSize=handSize; return (A) this; + this.handSize = handSize; + return (A) this; } + public java.lang.Boolean hasHandSize() { return this.handSize != null; } + public java.lang.Integer getQueueLengthLimit() { return this.queueLengthLimit; } + public A withQueueLengthLimit(java.lang.Integer queueLengthLimit) { - this.queueLengthLimit=queueLengthLimit; return (A) this; + this.queueLengthLimit = queueLengthLimit; + return (A) this; } + public java.lang.Boolean hasQueueLengthLimit() { return this.queueLengthLimit != null; } + public java.lang.Integer getQueues() { return this.queues; } + public A withQueues(java.lang.Integer queues) { - this.queues=queues; return (A) this; + this.queues = queues; + return (A) this; } + public java.lang.Boolean hasQueues() { return this.queues != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta2QueuingConfigurationFluentImpl that = (V1beta2QueuingConfigurationFluentImpl) o; - if (handSize != null ? !handSize.equals(that.handSize) :that.handSize != null) return false; - if (queueLengthLimit != null ? !queueLengthLimit.equals(that.queueLengthLimit) :that.queueLengthLimit != null) return false; - if (queues != null ? !queues.equals(that.queues) :that.queues != null) return false; + if (handSize != null ? !handSize.equals(that.handSize) : that.handSize != null) return false; + if (queueLengthLimit != null + ? !queueLengthLimit.equals(that.queueLengthLimit) + : that.queueLengthLimit != null) return false; + if (queues != null ? !queues.equals(that.queues) : that.queues != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(handSize, queueLengthLimit, queues, super.hashCode()); + return java.util.Objects.hash(handSize, queueLengthLimit, queues, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ResourcePolicyRuleBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ResourcePolicyRuleBuilder.java index 3f95724a38..48df505658 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ResourcePolicyRuleBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ResourcePolicyRuleBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2ResourcePolicyRuleBuilder extends io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2ResourcePolicyRuleBuilder + extends io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluentImpl< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule, + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleBuilder> { public V1beta2ResourcePolicyRuleBuilder() { this(false); } + public V1beta2ResourcePolicyRuleBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2ResourcePolicyRule(), validationEnabled); } - public V1beta2ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent fluent) { + + public V1beta2ResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent fluent) { this(fluent, false); } - public V1beta2ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2ResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2ResourcePolicyRule(), validationEnabled); } - public V1beta2ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent fluent,io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule instance) { + + public V1beta2ResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent fluent, + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule instance) { this(fluent, instance, false); } - public V1beta2ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent fluent,io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2ResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent fluent, + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiGroups(instance.getApiGroups()); fluent.withClusterScope(instance.getClusterScope()); @@ -31,13 +58,18 @@ public V1beta2ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1be fluent.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule instance) { - this(instance,false); + + public V1beta2ResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule instance) { + this(instance, false); } - public V1beta2ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2ResourcePolicyRuleBuilder( + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiGroups(instance.getApiGroups()); this.withClusterScope(instance.getClusterScope()); @@ -48,10 +80,12 @@ public V1beta2ResourcePolicyRuleBuilder(io.kubernetes.client.openapi.models.V1be this.withVerbs(instance.getVerbs()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule build() { V1beta2ResourcePolicyRule buildable = new V1beta2ResourcePolicyRule(); buildable.setApiGroups(fluent.getApiGroups()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule build() { buildable.setVerbs(fluent.getVerbs()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2ResourcePolicyRuleBuilder that = (V1beta2ResourcePolicyRuleBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ResourcePolicyRuleFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ResourcePolicyRuleFluent.java index 84e17b2db1..f5180bc5db 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ResourcePolicyRuleFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ResourcePolicyRuleFluent.java @@ -1,85 +1,159 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.util.ArrayList; -import java.util.Collection; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public interface V1beta2ResourcePolicyRuleFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToApiGroups(java.lang.Integer index,java.lang.String item); - public A setToApiGroups(java.lang.Integer index,java.lang.String item); +/** Generated */ +public interface V1beta2ResourcePolicyRuleFluent< + A extends io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToApiGroups(java.lang.Integer index, java.lang.String item); + + public A setToApiGroups(java.lang.Integer index, java.lang.String item); + public A addToApiGroups(java.lang.String... items); + public A addAllToApiGroups(java.util.Collection items); + public A removeFromApiGroups(java.lang.String... items); + public A removeAllFromApiGroups(java.util.Collection items); + public java.util.List getApiGroups(); + public java.lang.String getApiGroup(java.lang.Integer index); + public java.lang.String getFirstApiGroup(); + public java.lang.String getLastApiGroup(); - public java.lang.String getMatchingApiGroup(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingApiGroup(java.util.function.Predicate predicate); + + public java.lang.String getMatchingApiGroup( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingApiGroup( + java.util.function.Predicate predicate); + public A withApiGroups(java.util.List apiGroups); + public A withApiGroups(java.lang.String... apiGroups); + public java.lang.Boolean hasApiGroups(); + public A addNewApiGroup(java.lang.String original); + public java.lang.Boolean getClusterScope(); + public A withClusterScope(java.lang.Boolean clusterScope); + public java.lang.Boolean hasClusterScope(); - public A addToNamespaces(java.lang.Integer index,java.lang.String item); - public A setToNamespaces(java.lang.Integer index,java.lang.String item); + + public A addToNamespaces(java.lang.Integer index, java.lang.String item); + + public A setToNamespaces(java.lang.Integer index, java.lang.String item); + public A addToNamespaces(java.lang.String... items); + public A addAllToNamespaces(java.util.Collection items); + public A removeFromNamespaces(java.lang.String... items); + public A removeAllFromNamespaces(java.util.Collection items); + public java.util.List getNamespaces(); + public java.lang.String getNamespace(java.lang.Integer index); + public java.lang.String getFirstNamespace(); + public java.lang.String getLastNamespace(); - public java.lang.String getMatchingNamespace(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingNamespace(java.util.function.Predicate predicate); + + public java.lang.String getMatchingNamespace( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingNamespace( + java.util.function.Predicate predicate); + public A withNamespaces(java.util.List namespaces); + public A withNamespaces(java.lang.String... namespaces); + public java.lang.Boolean hasNamespaces(); + public A addNewNamespace(java.lang.String original); - public A addToResources(java.lang.Integer index,java.lang.String item); - public A setToResources(java.lang.Integer index,java.lang.String item); + + public A addToResources(java.lang.Integer index, java.lang.String item); + + public A setToResources(java.lang.Integer index, java.lang.String item); + public A addToResources(java.lang.String... items); + public A addAllToResources(java.util.Collection items); + public A removeFromResources(java.lang.String... items); + public A removeAllFromResources(java.util.Collection items); + public java.util.List getResources(); + public java.lang.String getResource(java.lang.Integer index); + public java.lang.String getFirstResource(); + public java.lang.String getLastResource(); - public java.lang.String getMatchingResource(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingResource(java.util.function.Predicate predicate); + + public java.lang.String getMatchingResource( + java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingResource( + java.util.function.Predicate predicate); + public A withResources(java.util.List resources); + public A withResources(java.lang.String... resources); + public java.lang.Boolean hasResources(); + public A addNewResource(java.lang.String original); - public A addToVerbs(java.lang.Integer index,java.lang.String item); - public A setToVerbs(java.lang.Integer index,java.lang.String item); + + public A addToVerbs(java.lang.Integer index, java.lang.String item); + + public A setToVerbs(java.lang.Integer index, java.lang.String item); + public A addToVerbs(java.lang.String... items); + public A addAllToVerbs(java.util.Collection items); + public A removeFromVerbs(java.lang.String... items); + public A removeAllFromVerbs(java.util.Collection items); + public java.util.List getVerbs(); + public java.lang.String getVerb(java.lang.Integer index); + public java.lang.String getFirstVerb(); + public java.lang.String getLastVerb(); + public java.lang.String getMatchingVerb(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate); + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate); + public A withVerbs(java.util.List verbs); + public A withVerbs(java.lang.String... verbs); + public java.lang.Boolean hasVerbs(); + public A addNewVerb(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ResourcePolicyRuleFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ResourcePolicyRuleFluentImpl.java index b1a0210e48..b14d9108c3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ResourcePolicyRuleFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ResourcePolicyRuleFluentImpl.java @@ -1,22 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; -import java.util.ArrayList; -import java.util.Collection; -import java.lang.Object; -import java.util.List; -import java.lang.String; -import java.lang.Boolean; -import java.util.function.Predicate; - - /** - * Generated - */ -public class V1beta2ResourcePolicyRuleFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent{ - public V1beta2ResourcePolicyRuleFluentImpl() { - } - public V1beta2ResourcePolicyRuleFluentImpl(io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule instance) { +/** Generated */ +public class V1beta2ResourcePolicyRuleFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRuleFluent { + public V1beta2ResourcePolicyRuleFluentImpl() {} + + public V1beta2ResourcePolicyRuleFluentImpl( + io.kubernetes.client.openapi.models.V1beta2ResourcePolicyRule instance) { this.withApiGroups(instance.getApiGroups()); this.withClusterScope(instance.getClusterScope()); @@ -26,251 +30,533 @@ public V1beta2ResourcePolicyRuleFluentImpl(io.kubernetes.client.openapi.models.V this.withResources(instance.getResources()); this.withVerbs(instance.getVerbs()); - } + private java.util.List apiGroups; private java.lang.Boolean clusterScope; private java.util.List namespaces; private java.util.List resources; private java.util.List verbs; - public A addToApiGroups(java.lang.Integer index,java.lang.String item) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} + + public A addToApiGroups(java.lang.Integer index, java.lang.String item) { + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } this.apiGroups.add(index, item); - return (A)this; + return (A) this; } - public A setToApiGroups(java.lang.Integer index,java.lang.String item) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - this.apiGroups.set(index, item); return (A)this; + + public A setToApiGroups(java.lang.Integer index, java.lang.String item) { + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + this.apiGroups.set(index, item); + return (A) this; } + public A addToApiGroups(java.lang.String... items) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.apiGroups.add(item);} return (A)this; + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.apiGroups.add(item); + } + return (A) this; } + public A addAllToApiGroups(java.util.Collection items) { - if (this.apiGroups == null) {this.apiGroups = new java.util.ArrayList();} - for (java.lang.String item : items) {this.apiGroups.add(item);} return (A)this; + if (this.apiGroups == null) { + this.apiGroups = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.apiGroups.add(item); + } + return (A) this; } + public A removeFromApiGroups(java.lang.String... items) { - for (java.lang.String item : items) {if (this.apiGroups!= null){ this.apiGroups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.apiGroups != null) { + this.apiGroups.remove(item); + } + } + return (A) this; } + public A removeAllFromApiGroups(java.util.Collection items) { - for (java.lang.String item : items) {if (this.apiGroups!= null){ this.apiGroups.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.apiGroups != null) { + this.apiGroups.remove(item); + } + } + return (A) this; } + public java.util.List getApiGroups() { return this.apiGroups; } + public java.lang.String getApiGroup(java.lang.Integer index) { return this.apiGroups.get(index); } + public java.lang.String getFirstApiGroup() { return this.apiGroups.get(0); } + public java.lang.String getLastApiGroup() { return this.apiGroups.get(apiGroups.size() - 1); } - public java.lang.String getMatchingApiGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: apiGroups) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingApiGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : apiGroups) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingApiGroup(java.util.function.Predicate predicate) { - for (java.lang.String item: apiGroups) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingApiGroup( + java.util.function.Predicate predicate) { + for (java.lang.String item : apiGroups) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withApiGroups(java.util.List apiGroups) { - if (apiGroups != null) {this.apiGroups = new java.util.ArrayList(); for (java.lang.String item : apiGroups){this.addToApiGroups(item);}} else { this.apiGroups = null;} return (A) this; + if (apiGroups != null) { + this.apiGroups = new java.util.ArrayList(); + for (java.lang.String item : apiGroups) { + this.addToApiGroups(item); + } + } else { + this.apiGroups = null; + } + return (A) this; } + public A withApiGroups(java.lang.String... apiGroups) { - if (this.apiGroups != null) {this.apiGroups.clear();} - if (apiGroups != null) {for (java.lang.String item :apiGroups){ this.addToApiGroups(item);}} return (A) this; + if (this.apiGroups != null) { + this.apiGroups.clear(); + } + if (apiGroups != null) { + for (java.lang.String item : apiGroups) { + this.addToApiGroups(item); + } + } + return (A) this; } + public java.lang.Boolean hasApiGroups() { return apiGroups != null && !apiGroups.isEmpty(); } + public A addNewApiGroup(java.lang.String original) { - return (A)addToApiGroups(new String(original)); + return (A) addToApiGroups(new String(original)); } + public java.lang.Boolean getClusterScope() { return this.clusterScope; } + public A withClusterScope(java.lang.Boolean clusterScope) { - this.clusterScope=clusterScope; return (A) this; + this.clusterScope = clusterScope; + return (A) this; } + public java.lang.Boolean hasClusterScope() { return this.clusterScope != null; } - public A addToNamespaces(java.lang.Integer index,java.lang.String item) { - if (this.namespaces == null) {this.namespaces = new java.util.ArrayList();} + + public A addToNamespaces(java.lang.Integer index, java.lang.String item) { + if (this.namespaces == null) { + this.namespaces = new java.util.ArrayList(); + } this.namespaces.add(index, item); - return (A)this; + return (A) this; } - public A setToNamespaces(java.lang.Integer index,java.lang.String item) { - if (this.namespaces == null) {this.namespaces = new java.util.ArrayList();} - this.namespaces.set(index, item); return (A)this; + + public A setToNamespaces(java.lang.Integer index, java.lang.String item) { + if (this.namespaces == null) { + this.namespaces = new java.util.ArrayList(); + } + this.namespaces.set(index, item); + return (A) this; } + public A addToNamespaces(java.lang.String... items) { - if (this.namespaces == null) {this.namespaces = new java.util.ArrayList();} - for (java.lang.String item : items) {this.namespaces.add(item);} return (A)this; + if (this.namespaces == null) { + this.namespaces = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.namespaces.add(item); + } + return (A) this; } + public A addAllToNamespaces(java.util.Collection items) { - if (this.namespaces == null) {this.namespaces = new java.util.ArrayList();} - for (java.lang.String item : items) {this.namespaces.add(item);} return (A)this; + if (this.namespaces == null) { + this.namespaces = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.namespaces.add(item); + } + return (A) this; } + public A removeFromNamespaces(java.lang.String... items) { - for (java.lang.String item : items) {if (this.namespaces!= null){ this.namespaces.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.namespaces != null) { + this.namespaces.remove(item); + } + } + return (A) this; } + public A removeAllFromNamespaces(java.util.Collection items) { - for (java.lang.String item : items) {if (this.namespaces!= null){ this.namespaces.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.namespaces != null) { + this.namespaces.remove(item); + } + } + return (A) this; } + public java.util.List getNamespaces() { return this.namespaces; } + public java.lang.String getNamespace(java.lang.Integer index) { return this.namespaces.get(index); } + public java.lang.String getFirstNamespace() { return this.namespaces.get(0); } + public java.lang.String getLastNamespace() { return this.namespaces.get(namespaces.size() - 1); } - public java.lang.String getMatchingNamespace(java.util.function.Predicate predicate) { - for (java.lang.String item: namespaces) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingNamespace( + java.util.function.Predicate predicate) { + for (java.lang.String item : namespaces) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingNamespace(java.util.function.Predicate predicate) { - for (java.lang.String item: namespaces) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingNamespace( + java.util.function.Predicate predicate) { + for (java.lang.String item : namespaces) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withNamespaces(java.util.List namespaces) { - if (namespaces != null) {this.namespaces = new java.util.ArrayList(); for (java.lang.String item : namespaces){this.addToNamespaces(item);}} else { this.namespaces = null;} return (A) this; + if (namespaces != null) { + this.namespaces = new java.util.ArrayList(); + for (java.lang.String item : namespaces) { + this.addToNamespaces(item); + } + } else { + this.namespaces = null; + } + return (A) this; } + public A withNamespaces(java.lang.String... namespaces) { - if (this.namespaces != null) {this.namespaces.clear();} - if (namespaces != null) {for (java.lang.String item :namespaces){ this.addToNamespaces(item);}} return (A) this; + if (this.namespaces != null) { + this.namespaces.clear(); + } + if (namespaces != null) { + for (java.lang.String item : namespaces) { + this.addToNamespaces(item); + } + } + return (A) this; } + public java.lang.Boolean hasNamespaces() { return namespaces != null && !namespaces.isEmpty(); } + public A addNewNamespace(java.lang.String original) { - return (A)addToNamespaces(new String(original)); + return (A) addToNamespaces(new String(original)); } - public A addToResources(java.lang.Integer index,java.lang.String item) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} + + public A addToResources(java.lang.Integer index, java.lang.String item) { + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } this.resources.add(index, item); - return (A)this; + return (A) this; } - public A setToResources(java.lang.Integer index,java.lang.String item) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - this.resources.set(index, item); return (A)this; + + public A setToResources(java.lang.Integer index, java.lang.String item) { + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + this.resources.set(index, item); + return (A) this; } + public A addToResources(java.lang.String... items) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resources.add(item);} return (A)this; + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resources.add(item); + } + return (A) this; } + public A addAllToResources(java.util.Collection items) { - if (this.resources == null) {this.resources = new java.util.ArrayList();} - for (java.lang.String item : items) {this.resources.add(item);} return (A)this; + if (this.resources == null) { + this.resources = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.resources.add(item); + } + return (A) this; } + public A removeFromResources(java.lang.String... items) { - for (java.lang.String item : items) {if (this.resources!= null){ this.resources.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resources != null) { + this.resources.remove(item); + } + } + return (A) this; } + public A removeAllFromResources(java.util.Collection items) { - for (java.lang.String item : items) {if (this.resources!= null){ this.resources.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.resources != null) { + this.resources.remove(item); + } + } + return (A) this; } + public java.util.List getResources() { return this.resources; } + public java.lang.String getResource(java.lang.Integer index) { return this.resources.get(index); } + public java.lang.String getFirstResource() { return this.resources.get(0); } + public java.lang.String getLastResource() { return this.resources.get(resources.size() - 1); } - public java.lang.String getMatchingResource(java.util.function.Predicate predicate) { - for (java.lang.String item: resources) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingResource( + java.util.function.Predicate predicate) { + for (java.lang.String item : resources) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingResource(java.util.function.Predicate predicate) { - for (java.lang.String item: resources) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingResource( + java.util.function.Predicate predicate) { + for (java.lang.String item : resources) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withResources(java.util.List resources) { - if (resources != null) {this.resources = new java.util.ArrayList(); for (java.lang.String item : resources){this.addToResources(item);}} else { this.resources = null;} return (A) this; + if (resources != null) { + this.resources = new java.util.ArrayList(); + for (java.lang.String item : resources) { + this.addToResources(item); + } + } else { + this.resources = null; + } + return (A) this; } + public A withResources(java.lang.String... resources) { - if (this.resources != null) {this.resources.clear();} - if (resources != null) {for (java.lang.String item :resources){ this.addToResources(item);}} return (A) this; + if (this.resources != null) { + this.resources.clear(); + } + if (resources != null) { + for (java.lang.String item : resources) { + this.addToResources(item); + } + } + return (A) this; } + public java.lang.Boolean hasResources() { return resources != null && !resources.isEmpty(); } + public A addNewResource(java.lang.String original) { - return (A)addToResources(new String(original)); + return (A) addToResources(new String(original)); } - public A addToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} + + public A addToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } this.verbs.add(index, item); - return (A)this; + return (A) this; } - public A setToVerbs(java.lang.Integer index,java.lang.String item) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - this.verbs.set(index, item); return (A)this; + + public A setToVerbs(java.lang.Integer index, java.lang.String item) { + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + this.verbs.set(index, item); + return (A) this; } + public A addToVerbs(java.lang.String... items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A addAllToVerbs(java.util.Collection items) { - if (this.verbs == null) {this.verbs = new java.util.ArrayList();} - for (java.lang.String item : items) {this.verbs.add(item);} return (A)this; + if (this.verbs == null) { + this.verbs = new java.util.ArrayList(); + } + for (java.lang.String item : items) { + this.verbs.add(item); + } + return (A) this; } + public A removeFromVerbs(java.lang.String... items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public A removeAllFromVerbs(java.util.Collection items) { - for (java.lang.String item : items) {if (this.verbs!= null){ this.verbs.remove(item);}} return (A)this; + for (java.lang.String item : items) { + if (this.verbs != null) { + this.verbs.remove(item); + } + } + return (A) this; } + public java.util.List getVerbs() { return this.verbs; } + public java.lang.String getVerb(java.lang.Integer index) { return this.verbs.get(index); } + public java.lang.String getFirstVerb() { return this.verbs.get(0); } + public java.lang.String getLastVerb() { return this.verbs.get(verbs.size() - 1); } - public java.lang.String getMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return item;} } return null; + + public java.lang.String getMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return item; + } + } + return null; } - public java.lang.Boolean hasMatchingVerb(java.util.function.Predicate predicate) { - for (java.lang.String item: verbs) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingVerb( + java.util.function.Predicate predicate) { + for (java.lang.String item : verbs) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withVerbs(java.util.List verbs) { - if (verbs != null) {this.verbs = new java.util.ArrayList(); for (java.lang.String item : verbs){this.addToVerbs(item);}} else { this.verbs = null;} return (A) this; + if (verbs != null) { + this.verbs = new java.util.ArrayList(); + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } else { + this.verbs = null; + } + return (A) this; } + public A withVerbs(java.lang.String... verbs) { - if (this.verbs != null) {this.verbs.clear();} - if (verbs != null) {for (java.lang.String item :verbs){ this.addToVerbs(item);}} return (A) this; + if (this.verbs != null) { + this.verbs.clear(); + } + if (verbs != null) { + for (java.lang.String item : verbs) { + this.addToVerbs(item); + } + } + return (A) this; } + public java.lang.Boolean hasVerbs() { return verbs != null && !verbs.isEmpty(); } + public A addNewVerb(java.lang.String original) { - return (A)addToVerbs(new String(original)); + return (A) addToVerbs(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta2ResourcePolicyRuleFluentImpl that = (V1beta2ResourcePolicyRuleFluentImpl) o; - if (apiGroups != null ? !apiGroups.equals(that.apiGroups) :that.apiGroups != null) return false; - if (clusterScope != null ? !clusterScope.equals(that.clusterScope) :that.clusterScope != null) return false; - if (namespaces != null ? !namespaces.equals(that.namespaces) :that.namespaces != null) return false; - if (resources != null ? !resources.equals(that.resources) :that.resources != null) return false; - if (verbs != null ? !verbs.equals(that.verbs) :that.verbs != null) return false; + if (apiGroups != null ? !apiGroups.equals(that.apiGroups) : that.apiGroups != null) + return false; + if (clusterScope != null ? !clusterScope.equals(that.clusterScope) : that.clusterScope != null) + return false; + if (namespaces != null ? !namespaces.equals(that.namespaces) : that.namespaces != null) + return false; + if (resources != null ? !resources.equals(that.resources) : that.resources != null) + return false; + if (verbs != null ? !verbs.equals(that.verbs) : that.verbs != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiGroups, clusterScope, namespaces, resources, verbs, super.hashCode()); + return java.util.Objects.hash( + apiGroups, clusterScope, namespaces, resources, verbs, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ServiceAccountSubjectBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ServiceAccountSubjectBuilder.java index 5feba628fb..574c55028e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ServiceAccountSubjectBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ServiceAccountSubjectBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2ServiceAccountSubjectBuilder extends io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2ServiceAccountSubjectBuilder + extends io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject, + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectBuilder> { public V1beta2ServiceAccountSubjectBuilder() { this(false); } + public V1beta2ServiceAccountSubjectBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2ServiceAccountSubject(), validationEnabled); } - public V1beta2ServiceAccountSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent fluent) { + + public V1beta2ServiceAccountSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent fluent) { this(fluent, false); } - public V1beta2ServiceAccountSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2ServiceAccountSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2ServiceAccountSubject(), validationEnabled); } - public V1beta2ServiceAccountSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject instance) { + + public V1beta2ServiceAccountSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject instance) { this(fluent, instance, false); } - public V1beta2ServiceAccountSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2ServiceAccountSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withNamespace(instance.getNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2ServiceAccountSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject instance) { - this(instance,false); + + public V1beta2ServiceAccountSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject instance) { + this(instance, false); } - public V1beta2ServiceAccountSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2ServiceAccountSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withNamespace(instance.getNamespace()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject build() { V1beta2ServiceAccountSubject buildable = new V1beta2ServiceAccountSubject(); buildable.setName(fluent.getName()); buildable.setNamespace(fluent.getNamespace()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2ServiceAccountSubjectBuilder that = (V1beta2ServiceAccountSubjectBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ServiceAccountSubjectFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ServiceAccountSubjectFluent.java index 631f127da7..0391d52a33 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ServiceAccountSubjectFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ServiceAccountSubjectFluent.java @@ -1,32 +1,38 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2ServiceAccountSubjectFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta2ServiceAccountSubjectFluent< + A extends io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.String getNamespace(); + public A withNamespace(java.lang.String namespace); + public java.lang.Boolean hasNamespace(); - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ServiceAccountSubjectFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ServiceAccountSubjectFluentImpl.java index a0d55df275..9116e87c0e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ServiceAccountSubjectFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2ServiceAccountSubjectFluentImpl.java @@ -1,69 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V1beta2ServiceAccountSubjectFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent { + public V1beta2ServiceAccountSubjectFluentImpl() {} - /** - * Generated - */ -public class V1beta2ServiceAccountSubjectFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent{ - public V1beta2ServiceAccountSubjectFluentImpl() { - } - public V1beta2ServiceAccountSubjectFluentImpl(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject instance) { + public V1beta2ServiceAccountSubjectFluentImpl( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject instance) { this.withName(instance.getName()); this.withNamespace(instance.getNamespace()); - } + private java.lang.String name; private java.lang.String namespace; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.String getNamespace() { return this.namespace; } + public A withNamespace(java.lang.String namespace) { - this.namespace=namespace; return (A) this; + this.namespace = namespace; + return (A) this; } + public java.lang.Boolean hasNamespace() { return this.namespace != null; } - - /** - * Method is deprecated. use withNamespace instead. - */ + + /** Method is deprecated. use withNamespace instead. */ @java.lang.Deprecated public A withNewNamespace(java.lang.String original) { - return (A)withNamespace(new String(original)); + return (A) withNamespace(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta2ServiceAccountSubjectFluentImpl that = (V1beta2ServiceAccountSubjectFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (namespace != null ? !namespace.equals(that.namespace) :that.namespace != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (namespace != null ? !namespace.equals(that.namespace) : that.namespace != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, namespace, super.hashCode()); + return java.util.Objects.hash(name, namespace, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2SubjectBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2SubjectBuilder.java index 4f66b93066..166b157cb0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2SubjectBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2SubjectBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2SubjectBuilder extends io.kubernetes.client.openapi.models.V1beta2SubjectFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2SubjectBuilder + extends io.kubernetes.client.openapi.models.V1beta2SubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta2SubjectBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2Subject, + io.kubernetes.client.openapi.models.V1beta2SubjectBuilder> { public V1beta2SubjectBuilder() { this(false); } + public V1beta2SubjectBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2Subject(), validationEnabled); } + public V1beta2SubjectBuilder(io.kubernetes.client.openapi.models.V1beta2SubjectFluent fluent) { this(fluent, false); } - public V1beta2SubjectBuilder(io.kubernetes.client.openapi.models.V1beta2SubjectFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2SubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2SubjectFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2Subject(), validationEnabled); } - public V1beta2SubjectBuilder(io.kubernetes.client.openapi.models.V1beta2SubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta2Subject instance) { + + public V1beta2SubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2SubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta2Subject instance) { this(fluent, instance, false); } - public V1beta2SubjectBuilder(io.kubernetes.client.openapi.models.V1beta2SubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta2Subject instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2SubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2SubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta2Subject instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withGroup(instance.getGroup()); fluent.withKind(instance.getKind()); @@ -29,13 +55,17 @@ public V1beta2SubjectBuilder(io.kubernetes.client.openapi.models.V1beta2SubjectF fluent.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V1beta2SubjectBuilder(io.kubernetes.client.openapi.models.V1beta2Subject instance) { - this(instance,false); + this(instance, false); } - public V1beta2SubjectBuilder(io.kubernetes.client.openapi.models.V1beta2Subject instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2SubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2Subject instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withGroup(instance.getGroup()); this.withKind(instance.getKind()); @@ -44,10 +74,12 @@ public V1beta2SubjectBuilder(io.kubernetes.client.openapi.models.V1beta2Subject this.withUser(instance.getUser()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2SubjectFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2Subject build() { V1beta2Subject buildable = new V1beta2Subject(); buildable.setGroup(fluent.getGroup()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V1beta2Subject build() { buildable.setUser(fluent.getUser()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2SubjectBuilder that = (V1beta2SubjectBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2SubjectFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2SubjectFluent.java index 8c2fc22c61..0b5cb0585b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2SubjectFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2SubjectFluent.java @@ -1,84 +1,140 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2SubjectFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V1beta2SubjectFluent< + A extends io.kubernetes.client.openapi.models.V1beta2SubjectFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildGroup instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2GroupSubject getGroup(); + public io.kubernetes.client.openapi.models.V1beta2GroupSubject buildGroup(); + public A withGroup(io.kubernetes.client.openapi.models.V1beta2GroupSubject group); + public java.lang.Boolean hasGroup(); + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested withNewGroup(); - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested withNewGroupLike(io.kubernetes.client.openapi.models.V1beta2GroupSubject item); + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested withNewGroupLike( + io.kubernetes.client.openapi.models.V1beta2GroupSubject item); + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested editGroup(); + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested editOrNewGroup(); - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested editOrNewGroupLike(io.kubernetes.client.openapi.models.V1beta2GroupSubject item); + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested editOrNewGroupLike( + io.kubernetes.client.openapi.models.V1beta2GroupSubject item); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildServiceAccount instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject getServiceAccount(); + public io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject buildServiceAccount(); - public A withServiceAccount(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject serviceAccount); + + public A withServiceAccount( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject serviceAccount); + public java.lang.Boolean hasServiceAccount(); - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested withNewServiceAccount(); - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested withNewServiceAccountLike(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject item); - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested editServiceAccount(); - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested editOrNewServiceAccount(); - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested editOrNewServiceAccountLike(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject item); - + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested + withNewServiceAccount(); + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested + withNewServiceAccountLike( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject item); + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested + editServiceAccount(); + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested + editOrNewServiceAccount(); + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested + editOrNewServiceAccountLike( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject item); + /** * This method has been deprecated, please use method buildUser instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2UserSubject getUser(); + public io.kubernetes.client.openapi.models.V1beta2UserSubject buildUser(); + public A withUser(io.kubernetes.client.openapi.models.V1beta2UserSubject user); + public java.lang.Boolean hasUser(); + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested withNewUser(); - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested withNewUserLike(io.kubernetes.client.openapi.models.V1beta2UserSubject item); + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested withNewUserLike( + io.kubernetes.client.openapi.models.V1beta2UserSubject item); + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested editUser(); + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested editOrNewUser(); - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested editOrNewUserLike(io.kubernetes.client.openapi.models.V1beta2UserSubject item); - public interface GroupNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent>{ + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested editOrNewUserLike( + io.kubernetes.client.openapi.models.V1beta2UserSubject item); + + public interface GroupNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluent< + io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested> { public N and(); + public N endGroup(); - } - public interface ServiceAccountNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent>{ + + public interface ServiceAccountNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluent< + io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested> { public N and(); + public N endServiceAccount(); - } - public interface UserNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent>{ + + public interface UserNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent< + io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested> { public N and(); + public N endUser(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2SubjectFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2SubjectFluentImpl.java index 7c86ed64eb..87c68eec33 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2SubjectFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2SubjectFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V1beta2SubjectFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2SubjectFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2SubjectFluent { + public V1beta2SubjectFluentImpl() {} - /** - * Generated - */ -public class V1beta2SubjectFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2SubjectFluent{ - public V1beta2SubjectFluentImpl() { - } public V1beta2SubjectFluentImpl(io.kubernetes.client.openapi.models.V1beta2Subject instance) { this.withGroup(instance.getGroup()); @@ -21,191 +27,288 @@ public V1beta2SubjectFluentImpl(io.kubernetes.client.openapi.models.V1beta2Subje this.withServiceAccount(instance.getServiceAccount()); this.withUser(instance.getUser()); - } + private io.kubernetes.client.openapi.models.V1beta2GroupSubjectBuilder group; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectBuilder serviceAccount; private io.kubernetes.client.openapi.models.V1beta2UserSubjectBuilder user; - + /** * This method has been deprecated, please use method buildGroup instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2GroupSubject getGroup() { - return this.group!=null ?this.group.build():null; + return this.group != null ? this.group.build() : null; } + public io.kubernetes.client.openapi.models.V1beta2GroupSubject buildGroup() { - return this.group!=null ?this.group.build():null; + return this.group != null ? this.group.build() : null; } + public A withGroup(io.kubernetes.client.openapi.models.V1beta2GroupSubject group) { _visitables.get("group").remove(this.group); - if (group!=null){ this.group= new io.kubernetes.client.openapi.models.V1beta2GroupSubjectBuilder(group); _visitables.get("group").add(this.group);} return (A) this; + if (group != null) { + this.group = new io.kubernetes.client.openapi.models.V1beta2GroupSubjectBuilder(group); + _visitables.get("group").add(this.group); + } + return (A) this; } + public java.lang.Boolean hasGroup() { return this.group != null; } + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested withNewGroup() { return new io.kubernetes.client.openapi.models.V1beta2SubjectFluentImpl.GroupNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested withNewGroupLike(io.kubernetes.client.openapi.models.V1beta2GroupSubject item) { + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested withNewGroupLike( + io.kubernetes.client.openapi.models.V1beta2GroupSubject item) { return new io.kubernetes.client.openapi.models.V1beta2SubjectFluentImpl.GroupNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested editGroup() { return withNewGroupLike(getGroup()); } + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested editOrNewGroup() { - return withNewGroupLike(getGroup() != null ? getGroup(): new io.kubernetes.client.openapi.models.V1beta2GroupSubjectBuilder().build()); + return withNewGroupLike( + getGroup() != null + ? getGroup() + : new io.kubernetes.client.openapi.models.V1beta2GroupSubjectBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested editOrNewGroupLike(io.kubernetes.client.openapi.models.V1beta2GroupSubject item) { - return withNewGroupLike(getGroup() != null ? getGroup(): item); + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested editOrNewGroupLike( + io.kubernetes.client.openapi.models.V1beta2GroupSubject item) { + return withNewGroupLike(getGroup() != null ? getGroup() : item); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildServiceAccount instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject getServiceAccount() { - return this.serviceAccount!=null ?this.serviceAccount.build():null; + return this.serviceAccount != null ? this.serviceAccount.build() : null; } + public io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject buildServiceAccount() { - return this.serviceAccount!=null ?this.serviceAccount.build():null; + return this.serviceAccount != null ? this.serviceAccount.build() : null; } - public A withServiceAccount(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject serviceAccount) { + + public A withServiceAccount( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject serviceAccount) { _visitables.get("serviceAccount").remove(this.serviceAccount); - if (serviceAccount!=null){ this.serviceAccount= new io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectBuilder(serviceAccount); _visitables.get("serviceAccount").add(this.serviceAccount);} return (A) this; + if (serviceAccount != null) { + this.serviceAccount = + new io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectBuilder( + serviceAccount); + _visitables.get("serviceAccount").add(this.serviceAccount); + } + return (A) this; } + public java.lang.Boolean hasServiceAccount() { return this.serviceAccount != null; } - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested withNewServiceAccount() { - return new io.kubernetes.client.openapi.models.V1beta2SubjectFluentImpl.ServiceAccountNestedImpl(); + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested + withNewServiceAccount() { + return new io.kubernetes.client.openapi.models.V1beta2SubjectFluentImpl + .ServiceAccountNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested withNewServiceAccountLike(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject item) { - return new io.kubernetes.client.openapi.models.V1beta2SubjectFluentImpl.ServiceAccountNestedImpl(item); + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested + withNewServiceAccountLike( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject item) { + return new io.kubernetes.client.openapi.models.V1beta2SubjectFluentImpl + .ServiceAccountNestedImpl(item); } - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested editServiceAccount() { + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested + editServiceAccount() { return withNewServiceAccountLike(getServiceAccount()); } - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested editOrNewServiceAccount() { - return withNewServiceAccountLike(getServiceAccount() != null ? getServiceAccount(): new io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectBuilder().build()); + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested + editOrNewServiceAccount() { + return withNewServiceAccountLike( + getServiceAccount() != null + ? getServiceAccount() + : new io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested editOrNewServiceAccountLike(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject item) { - return withNewServiceAccountLike(getServiceAccount() != null ? getServiceAccount(): item); + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested + editOrNewServiceAccountLike( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject item) { + return withNewServiceAccountLike(getServiceAccount() != null ? getServiceAccount() : item); } - + /** * This method has been deprecated, please use method buildUser instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1beta2UserSubject getUser() { - return this.user!=null ?this.user.build():null; + return this.user != null ? this.user.build() : null; } + public io.kubernetes.client.openapi.models.V1beta2UserSubject buildUser() { - return this.user!=null ?this.user.build():null; + return this.user != null ? this.user.build() : null; } + public A withUser(io.kubernetes.client.openapi.models.V1beta2UserSubject user) { _visitables.get("user").remove(this.user); - if (user!=null){ this.user= new io.kubernetes.client.openapi.models.V1beta2UserSubjectBuilder(user); _visitables.get("user").add(this.user);} return (A) this; + if (user != null) { + this.user = new io.kubernetes.client.openapi.models.V1beta2UserSubjectBuilder(user); + _visitables.get("user").add(this.user); + } + return (A) this; } + public java.lang.Boolean hasUser() { return this.user != null; } + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested withNewUser() { return new io.kubernetes.client.openapi.models.V1beta2SubjectFluentImpl.UserNestedImpl(); } - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested withNewUserLike(io.kubernetes.client.openapi.models.V1beta2UserSubject item) { + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested withNewUserLike( + io.kubernetes.client.openapi.models.V1beta2UserSubject item) { return new io.kubernetes.client.openapi.models.V1beta2SubjectFluentImpl.UserNestedImpl(item); } + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested editUser() { return withNewUserLike(getUser()); } + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested editOrNewUser() { - return withNewUserLike(getUser() != null ? getUser(): new io.kubernetes.client.openapi.models.V1beta2UserSubjectBuilder().build()); + return withNewUserLike( + getUser() != null + ? getUser() + : new io.kubernetes.client.openapi.models.V1beta2UserSubjectBuilder().build()); } - public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested editOrNewUserLike(io.kubernetes.client.openapi.models.V1beta2UserSubject item) { - return withNewUserLike(getUser() != null ? getUser(): item); + + public io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested editOrNewUserLike( + io.kubernetes.client.openapi.models.V1beta2UserSubject item) { + return withNewUserLike(getUser() != null ? getUser() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta2SubjectFluentImpl that = (V1beta2SubjectFluentImpl) o; - if (group != null ? !group.equals(that.group) :that.group != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (serviceAccount != null ? !serviceAccount.equals(that.serviceAccount) :that.serviceAccount != null) return false; - if (user != null ? !user.equals(that.user) :that.user != null) return false; + if (group != null ? !group.equals(that.group) : that.group != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (serviceAccount != null + ? !serviceAccount.equals(that.serviceAccount) + : that.serviceAccount != null) return false; + if (user != null ? !user.equals(that.user) : that.user != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(group, kind, serviceAccount, user, super.hashCode()); + return java.util.Objects.hash(group, kind, serviceAccount, user, super.hashCode()); } - public class GroupNestedImpl extends io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested,io.kubernetes.client.fluent.Nested{ + + public class GroupNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2GroupSubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested> + implements io.kubernetes.client.openapi.models.V1beta2SubjectFluent.GroupNested, + io.kubernetes.client.fluent.Nested { GroupNestedImpl(io.kubernetes.client.openapi.models.V1beta2GroupSubject item) { this.builder = new io.kubernetes.client.openapi.models.V1beta2GroupSubjectBuilder(this, item); } + GroupNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta2GroupSubjectBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2GroupSubjectBuilder builder; + public N and() { return (N) V1beta2SubjectFluentImpl.this.withGroup(builder.build()); } + public N endGroup() { return and(); } - } - public class ServiceAccountNestedImpl extends io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested,io.kubernetes.client.fluent.Nested{ - ServiceAccountNestedImpl(io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject item) { - this.builder = new io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectBuilder(this, item); + + public class ServiceAccountNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested> + implements io.kubernetes.client.openapi.models.V1beta2SubjectFluent.ServiceAccountNested, + io.kubernetes.client.fluent.Nested { + ServiceAccountNestedImpl( + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubject item) { + this.builder = + new io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectBuilder(this, item); } + ServiceAccountNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2ServiceAccountSubjectBuilder builder; + public N and() { return (N) V1beta2SubjectFluentImpl.this.withServiceAccount(builder.build()); } + public N endServiceAccount() { return and(); } - } - public class UserNestedImpl extends io.kubernetes.client.openapi.models.V1beta2UserSubjectFluentImpl> implements io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested,io.kubernetes.client.fluent.Nested{ + + public class UserNestedImpl + extends io.kubernetes.client.openapi.models.V1beta2UserSubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested> + implements io.kubernetes.client.openapi.models.V1beta2SubjectFluent.UserNested, + io.kubernetes.client.fluent.Nested { UserNestedImpl(io.kubernetes.client.openapi.models.V1beta2UserSubject item) { this.builder = new io.kubernetes.client.openapi.models.V1beta2UserSubjectBuilder(this, item); } + UserNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1beta2UserSubjectBuilder(this); } + io.kubernetes.client.openapi.models.V1beta2UserSubjectBuilder builder; + public N and() { return (N) V1beta2SubjectFluentImpl.this.withUser(builder.build()); } + public N endUser() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2UserSubjectBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2UserSubjectBuilder.java index 23d77ebb3b..64d1a125d5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2UserSubjectBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2UserSubjectBuilder.java @@ -1,58 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V1beta2UserSubjectBuilder extends io.kubernetes.client.openapi.models.V1beta2UserSubjectFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V1beta2UserSubjectBuilder + extends io.kubernetes.client.openapi.models.V1beta2UserSubjectFluentImpl< + io.kubernetes.client.openapi.models.V1beta2UserSubjectBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V1beta2UserSubject, + io.kubernetes.client.openapi.models.V1beta2UserSubjectBuilder> { public V1beta2UserSubjectBuilder() { this(false); } + public V1beta2UserSubjectBuilder(java.lang.Boolean validationEnabled) { this(new V1beta2UserSubject(), validationEnabled); } - public V1beta2UserSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent fluent) { + + public V1beta2UserSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent fluent) { this(fluent, false); } - public V1beta2UserSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent fluent,java.lang.Boolean validationEnabled) { + + public V1beta2UserSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V1beta2UserSubject(), validationEnabled); } - public V1beta2UserSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta2UserSubject instance) { + + public V1beta2UserSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta2UserSubject instance) { this(fluent, instance, false); } - public V1beta2UserSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent fluent,io.kubernetes.client.openapi.models.V1beta2UserSubject instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V1beta2UserSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent fluent, + io.kubernetes.client.openapi.models.V1beta2UserSubject instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V1beta2UserSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2UserSubject instance) { - this(instance,false); + + public V1beta2UserSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2UserSubject instance) { + this(instance, false); } - public V1beta2UserSubjectBuilder(io.kubernetes.client.openapi.models.V1beta2UserSubject instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V1beta2UserSubjectBuilder( + io.kubernetes.client.openapi.models.V1beta2UserSubject instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V1beta2UserSubject build() { V1beta2UserSubject buildable = new V1beta2UserSubject(); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V1beta2UserSubjectBuilder that = (V1beta2UserSubjectBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2UserSubjectFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2UserSubjectFluent.java index 8fee5a9766..22d70fc57e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2UserSubjectFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2UserSubjectFluent.java @@ -1,23 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V1beta2UserSubjectFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V1beta2UserSubjectFluent< + A extends io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2UserSubjectFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2UserSubjectFluentImpl.java index 9050ee7976..c33d660b4e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2UserSubjectFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V1beta2UserSubjectFluentImpl.java @@ -1,48 +1,59 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V1beta2UserSubjectFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent{ - public V1beta2UserSubjectFluentImpl() { - } - public V1beta2UserSubjectFluentImpl(io.kubernetes.client.openapi.models.V1beta2UserSubject instance) { - this.withName(instance.getName()); +/** Generated */ +public class V1beta2UserSubjectFluentImpl< + A extends io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V1beta2UserSubjectFluent { + public V1beta2UserSubjectFluentImpl() {} + public V1beta2UserSubjectFluentImpl( + io.kubernetes.client.openapi.models.V1beta2UserSubject instance) { + this.withName(instance.getName()); } + private java.lang.String name; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V1beta2UserSubjectFluentImpl that = (V1beta2UserSubjectFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, super.hashCode()); + return java.util.Objects.hash(name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricSourceBuilder.java index d1cfe8023c..2199b235ca 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricSourceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2ContainerResourceMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2ContainerResourceMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource, + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceBuilder> { public V2ContainerResourceMetricSourceBuilder() { this(false); } + public V2ContainerResourceMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2ContainerResourceMetricSource(), validationEnabled); } - public V2ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent fluent) { + + public V2ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent fluent) { this(fluent, false); } - public V2ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2ContainerResourceMetricSource(), validationEnabled); } - public V2ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource instance) { + + public V2ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource instance) { this(fluent, instance, false); } - public V2ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainer(instance.getContainer()); fluent.withName(instance.getName()); fluent.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource instance) { - this(instance,false); + + public V2ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource instance) { + this(instance, false); } - public V2ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainer(instance.getContainer()); this.withName(instance.getName()); this.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource build() { V2ContainerResourceMetricSource buildable = new V2ContainerResourceMetricSource(); buildable.setContainer(fluent.getContainer()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource build buildable.setTarget(fluent.getTarget()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2ContainerResourceMetricSourceBuilder that = (V2ContainerResourceMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricSourceFluent.java index b1052b1a70..2403f30021 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricSourceFluent.java @@ -1,53 +1,78 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2ContainerResourceMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2ContainerResourceMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getContainer(); + public A withContainer(java.lang.String container); + public java.lang.Boolean hasContainer(); - - /** - * Method is deprecated. use withContainer instead. - */ + + /** Method is deprecated. use withContainer instead. */ @java.lang.Deprecated public A withNewContainer(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricTarget getTarget(); + public io.kubernetes.client.openapi.models.V2MetricTarget buildTarget(); + public A withTarget(io.kubernetes.client.openapi.models.V2MetricTarget target); + public java.lang.Boolean hasTarget(); - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested withNewTarget(); - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested editTarget(); - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested editOrNewTarget(); - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); - public interface TargetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricTargetFluent>{ + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested + withNewTarget(); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested + editTarget(); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested + editOrNewTarget(); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); + + public interface TargetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricTargetFluent< + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent + .TargetNested< + N>> { public N and(); + public N endTarget(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricSourceFluentImpl.java index b3a9cca7f6..b8981c621d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricSourceFluentImpl.java @@ -1,124 +1,170 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2ContainerResourceMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent { + public V2ContainerResourceMetricSourceFluentImpl() {} - /** - * Generated - */ -public class V2ContainerResourceMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent{ - public V2ContainerResourceMetricSourceFluentImpl() { - } - public V2ContainerResourceMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource instance) { + public V2ContainerResourceMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource instance) { this.withContainer(instance.getContainer()); this.withName(instance.getName()); this.withTarget(instance.getTarget()); - } + private java.lang.String container; private java.lang.String name; private io.kubernetes.client.openapi.models.V2MetricTargetBuilder target; + public java.lang.String getContainer() { return this.container; } + public A withContainer(java.lang.String container) { - this.container=container; return (A) this; + this.container = container; + return (A) this; } + public java.lang.Boolean hasContainer() { return this.container != null; } - - /** - * Method is deprecated. use withContainer instead. - */ + + /** Method is deprecated. use withContainer instead. */ @java.lang.Deprecated public A withNewContainer(java.lang.String original) { - return (A)withContainer(new String(original)); + return (A) withContainer(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricTarget getTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricTarget buildTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public A withTarget(io.kubernetes.client.openapi.models.V2MetricTarget target) { _visitables.get("target").remove(this.target); - if (target!=null){ this.target= new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(target); _visitables.get("target").add(this.target);} return (A) this; + if (target != null) { + this.target = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(target); + _visitables.get("target").add(this.target); + } + return (A) this; } + public java.lang.Boolean hasTarget() { return this.target != null; } - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested withNewTarget() { - return new io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluentImpl.TargetNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested + withNewTarget() { + return new io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluentImpl + .TargetNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { - return new io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluentImpl.TargetNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { + return new io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluentImpl + .TargetNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested editTarget() { + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested + editTarget() { return withNewTargetLike(getTarget()); } - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested editOrNewTarget() { - return withNewTargetLike(getTarget() != null ? getTarget(): new io.kubernetes.client.openapi.models.V2MetricTargetBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested + editOrNewTarget() { + return withNewTargetLike( + getTarget() != null + ? getTarget() + : new io.kubernetes.client.openapi.models.V2MetricTargetBuilder().build()); } - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { - return withNewTargetLike(getTarget() != null ? getTarget(): item); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { + return withNewTargetLike(getTarget() != null ? getTarget() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2ContainerResourceMetricSourceFluentImpl that = (V2ContainerResourceMetricSourceFluentImpl) o; - if (container != null ? !container.equals(that.container) :that.container != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (target != null ? !target.equals(that.target) :that.target != null) return false; + if (container != null ? !container.equals(that.container) : that.container != null) + return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (target != null ? !target.equals(that.target) : that.target != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(container, name, target, super.hashCode()); + return java.util.Objects.hash(container, name, target, super.hashCode()); } - public class TargetNestedImpl extends io.kubernetes.client.openapi.models.V2MetricTargetFluentImpl> implements io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested,io.kubernetes.client.fluent.Nested{ + + public class TargetNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricTargetFluentImpl< + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent.TargetNested> + implements io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent + .TargetNested< + N>, + io.kubernetes.client.fluent.Nested { TargetNestedImpl(io.kubernetes.client.openapi.models.V2MetricTarget item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(this, item); } + TargetNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricTargetBuilder builder; + public N and() { return (N) V2ContainerResourceMetricSourceFluentImpl.this.withTarget(builder.build()); } + public N endTarget() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricStatusBuilder.java index c589ff788a..1f9a5ebb26 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricStatusBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2ContainerResourceMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2ContainerResourceMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus, + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusBuilder> { public V2ContainerResourceMetricStatusBuilder() { this(false); } + public V2ContainerResourceMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2ContainerResourceMetricStatus(), validationEnabled); } - public V2ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent fluent) { + + public V2ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent fluent) { this(fluent, false); } - public V2ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2ContainerResourceMetricStatus(), validationEnabled); } - public V2ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus instance) { + + public V2ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus instance) { this(fluent, instance, false); } - public V2ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainer(instance.getContainer()); fluent.withCurrent(instance.getCurrent()); fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus instance) { - this(instance,false); + + public V2ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus instance) { + this(instance, false); } - public V2ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainer(instance.getContainer()); this.withCurrent(instance.getCurrent()); this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus build() { V2ContainerResourceMetricStatus buildable = new V2ContainerResourceMetricStatus(); buildable.setContainer(fluent.getContainer()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus build buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2ContainerResourceMetricStatusBuilder that = (V2ContainerResourceMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricStatusFluent.java index ba63e8f6b0..1efc58ea72 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricStatusFluent.java @@ -1,53 +1,78 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2ContainerResourceMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2ContainerResourceMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getContainer(); + public A withContainer(java.lang.String container); + public java.lang.Boolean hasContainer(); - - /** - * Method is deprecated. use withContainer instead. - */ + + /** Method is deprecated. use withContainer instead. */ @java.lang.Deprecated public A withNewContainer(java.lang.String original); - + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricValueStatus getCurrent(); + public io.kubernetes.client.openapi.models.V2MetricValueStatus buildCurrent(); + public A withCurrent(io.kubernetes.client.openapi.models.V2MetricValueStatus current); + public java.lang.Boolean hasCurrent(); - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested withNewCurrent(); - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested editCurrent(); - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested editOrNewCurrent(); - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested + withNewCurrent(); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested + editCurrent(); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested + editOrNewCurrent(); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - public interface CurrentNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricValueStatusFluent>{ + + public interface CurrentNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricValueStatusFluent< + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent + .CurrentNested< + N>> { public N and(); + public N endCurrent(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricStatusFluentImpl.java index 6562703365..d6d8c1a5c7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ContainerResourceMetricStatusFluentImpl.java @@ -1,124 +1,171 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2ContainerResourceMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent { + public V2ContainerResourceMetricStatusFluentImpl() {} - /** - * Generated - */ -public class V2ContainerResourceMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent{ - public V2ContainerResourceMetricStatusFluentImpl() { - } - public V2ContainerResourceMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus instance) { + public V2ContainerResourceMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus instance) { this.withContainer(instance.getContainer()); this.withCurrent(instance.getCurrent()); this.withName(instance.getName()); - } + private java.lang.String container; private io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder current; private java.lang.String name; + public java.lang.String getContainer() { return this.container; } + public A withContainer(java.lang.String container) { - this.container=container; return (A) this; + this.container = container; + return (A) this; } + public java.lang.Boolean hasContainer() { return this.container != null; } - - /** - * Method is deprecated. use withContainer instead. - */ + + /** Method is deprecated. use withContainer instead. */ @java.lang.Deprecated public A withNewContainer(java.lang.String original) { - return (A)withContainer(new String(original)); + return (A) withContainer(new String(original)); } - + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricValueStatus getCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricValueStatus buildCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public A withCurrent(io.kubernetes.client.openapi.models.V2MetricValueStatus current) { _visitables.get("current").remove(this.current); - if (current!=null){ this.current= new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(current); _visitables.get("current").add(this.current);} return (A) this; + if (current != null) { + this.current = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(current); + _visitables.get("current").add(this.current); + } + return (A) this; } + public java.lang.Boolean hasCurrent() { return this.current != null; } - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested withNewCurrent() { - return new io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluentImpl.CurrentNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested + withNewCurrent() { + return new io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluentImpl + .CurrentNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { - return new io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluentImpl.CurrentNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { + return new io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluentImpl + .CurrentNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested editCurrent() { + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested + editCurrent() { return withNewCurrentLike(getCurrent()); } - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested editOrNewCurrent() { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested + editOrNewCurrent() { + return withNewCurrentLike( + getCurrent() != null + ? getCurrent() + : new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): item); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { + return withNewCurrentLike(getCurrent() != null ? getCurrent() : item); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2ContainerResourceMetricStatusFluentImpl that = (V2ContainerResourceMetricStatusFluentImpl) o; - if (container != null ? !container.equals(that.container) :that.container != null) return false; - if (current != null ? !current.equals(that.current) :that.current != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (container != null ? !container.equals(that.container) : that.container != null) + return false; + if (current != null ? !current.equals(that.current) : that.current != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(container, current, name, super.hashCode()); + return java.util.Objects.hash(container, current, name, super.hashCode()); } - public class CurrentNestedImpl extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested,io.kubernetes.client.fluent.Nested{ + + public class CurrentNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluentImpl< + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent.CurrentNested< + N>> + implements io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent + .CurrentNested< + N>, + io.kubernetes.client.fluent.Nested { CurrentNestedImpl(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(this, item); } + CurrentNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder builder; + public N and() { return (N) V2ContainerResourceMetricStatusFluentImpl.this.withCurrent(builder.build()); } + public N endCurrent() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2CrossVersionObjectReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2CrossVersionObjectReferenceBuilder.java index 1ea6a0aed1..4981d117dd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2CrossVersionObjectReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2CrossVersionObjectReferenceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2CrossVersionObjectReferenceBuilder extends io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2CrossVersionObjectReferenceBuilder + extends io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference, + io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder> { public V2CrossVersionObjectReferenceBuilder() { this(false); } + public V2CrossVersionObjectReferenceBuilder(java.lang.Boolean validationEnabled) { this(new V2CrossVersionObjectReference(), validationEnabled); } - public V2CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent fluent) { + + public V2CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent fluent) { this(fluent, false); } - public V2CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2CrossVersionObjectReference(), validationEnabled); } - public V2CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V2CrossVersionObjectReference instance) { + + public V2CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference instance) { this(fluent, instance, false); } - public V2CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V2CrossVersionObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference instance) { - this(instance,false); + + public V2CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference instance) { + this(instance, false); } - public V2CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2CrossVersionObjectReference build() { V2CrossVersionObjectReference buildable = new V2CrossVersionObjectReference(); buildable.setApiVersion(fluent.getApiVersion()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2CrossVersionObjectReference build() buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2CrossVersionObjectReferenceBuilder that = (V2CrossVersionObjectReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2CrossVersionObjectReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2CrossVersionObjectReferenceFluent.java index 126249baf2..126e64a36a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2CrossVersionObjectReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2CrossVersionObjectReferenceFluent.java @@ -1,41 +1,48 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2CrossVersionObjectReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2CrossVersionObjectReferenceFluent< + A extends io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2CrossVersionObjectReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2CrossVersionObjectReferenceFluentImpl.java index 810b114e03..d2de8ac59f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2CrossVersionObjectReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2CrossVersionObjectReferenceFluentImpl.java @@ -1,90 +1,106 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2CrossVersionObjectReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent{ - public V2CrossVersionObjectReferenceFluentImpl() { - } - public V2CrossVersionObjectReferenceFluentImpl(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference instance) { +/** Generated */ +public class V2CrossVersionObjectReferenceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent { + public V2CrossVersionObjectReferenceFluentImpl() {} + + public V2CrossVersionObjectReferenceFluentImpl( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); this.withName(instance.getName()); - } + private java.lang.String apiVersion; private java.lang.String kind; private java.lang.String name; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2CrossVersionObjectReferenceFluentImpl that = (V2CrossVersionObjectReferenceFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, name, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricSourceBuilder.java index e7989b5690..1203195de7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2ExternalMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2ExternalMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2ExternalMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2ExternalMetricSource, + io.kubernetes.client.openapi.models.V2ExternalMetricSourceBuilder> { public V2ExternalMetricSourceBuilder() { this(false); } + public V2ExternalMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2ExternalMetricSource(), validationEnabled); } - public V2ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent fluent) { + + public V2ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent fluent) { this(fluent, false); } - public V2ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2ExternalMetricSource(), validationEnabled); } - public V2ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2ExternalMetricSource instance) { + + public V2ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2ExternalMetricSource instance) { this(fluent, instance, false); } - public V2ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2ExternalMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2ExternalMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMetric(instance.getMetric()); fluent.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ExternalMetricSource instance) { - this(instance,false); + + public V2ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ExternalMetricSource instance) { + this(instance, false); } - public V2ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ExternalMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ExternalMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMetric(instance.getMetric()); this.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2ExternalMetricSource build() { V2ExternalMetricSource buildable = new V2ExternalMetricSource(); buildable.setMetric(fluent.getMetric()); buildable.setTarget(fluent.getTarget()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2ExternalMetricSourceBuilder that = (V2ExternalMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricSourceFluent.java index 90f7e5593d..c18795906a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricSourceFluent.java @@ -1,55 +1,95 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2ExternalMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2ExternalMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricIdentifier getMetric(); + public io.kubernetes.client.openapi.models.V2MetricIdentifier buildMetric(); + public A withMetric(io.kubernetes.client.openapi.models.V2MetricIdentifier metric); + public java.lang.Boolean hasMetric(); - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested withNewMetric(); - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested editMetric(); - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested editOrNewMetric(); - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); - + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested + withNewMetric(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested + editMetric(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested + editOrNewMetric(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricTarget getTarget(); + public io.kubernetes.client.openapi.models.V2MetricTarget buildTarget(); + public A withTarget(io.kubernetes.client.openapi.models.V2MetricTarget target); + public java.lang.Boolean hasTarget(); - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested withNewTarget(); - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested editTarget(); - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested editOrNewTarget(); - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); - public interface MetricNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricIdentifierFluent>{ + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested + withNewTarget(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested + editTarget(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested + editOrNewTarget(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); + + public interface MetricNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricIdentifierFluent< + io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested> { public N and(); + public N endMetric(); - } - public interface TargetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricTargetFluent>{ + + public interface TargetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricTargetFluent< + io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested> { public N and(); + public N endTarget(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricSourceFluentImpl.java index bbc214f808..ddcf9a85d2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricSourceFluentImpl.java @@ -1,135 +1,206 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2ExternalMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent { + public V2ExternalMetricSourceFluentImpl() {} - /** - * Generated - */ -public class V2ExternalMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent{ - public V2ExternalMetricSourceFluentImpl() { - } - public V2ExternalMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2ExternalMetricSource instance) { + public V2ExternalMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2ExternalMetricSource instance) { this.withMetric(instance.getMetric()); this.withTarget(instance.getTarget()); - } + private io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder metric; private io.kubernetes.client.openapi.models.V2MetricTargetBuilder target; - + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricIdentifier getMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricIdentifier buildMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public A withMetric(io.kubernetes.client.openapi.models.V2MetricIdentifier metric) { _visitables.get("metric").remove(this.metric); - if (metric!=null){ this.metric= new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(metric); _visitables.get("metric").add(this.metric);} return (A) this; + if (metric != null) { + this.metric = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(metric); + _visitables.get("metric").add(this.metric); + } + return (A) this; } + public java.lang.Boolean hasMetric() { return this.metric != null; } - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested withNewMetric() { - return new io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluentImpl.MetricNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested + withNewMetric() { + return new io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluentImpl + .MetricNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { - return new io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluentImpl.MetricNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { + return new io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluentImpl + .MetricNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested editMetric() { + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested + editMetric() { return withNewMetricLike(getMetric()); } - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested editOrNewMetric() { - return withNewMetricLike(getMetric() != null ? getMetric(): new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested + editOrNewMetric() { + return withNewMetricLike( + getMetric() != null + ? getMetric() + : new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder().build()); } - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { - return withNewMetricLike(getMetric() != null ? getMetric(): item); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { + return withNewMetricLike(getMetric() != null ? getMetric() : item); } - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricTarget getTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricTarget buildTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public A withTarget(io.kubernetes.client.openapi.models.V2MetricTarget target) { _visitables.get("target").remove(this.target); - if (target!=null){ this.target= new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(target); _visitables.get("target").add(this.target);} return (A) this; + if (target != null) { + this.target = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(target); + _visitables.get("target").add(this.target); + } + return (A) this; } + public java.lang.Boolean hasTarget() { return this.target != null; } - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested withNewTarget() { - return new io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluentImpl.TargetNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested + withNewTarget() { + return new io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluentImpl + .TargetNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { - return new io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluentImpl.TargetNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { + return new io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluentImpl + .TargetNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested editTarget() { + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested + editTarget() { return withNewTargetLike(getTarget()); } - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested editOrNewTarget() { - return withNewTargetLike(getTarget() != null ? getTarget(): new io.kubernetes.client.openapi.models.V2MetricTargetBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested + editOrNewTarget() { + return withNewTargetLike( + getTarget() != null + ? getTarget() + : new io.kubernetes.client.openapi.models.V2MetricTargetBuilder().build()); } - public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { - return withNewTargetLike(getTarget() != null ? getTarget(): item); + + public io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { + return withNewTargetLike(getTarget() != null ? getTarget() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2ExternalMetricSourceFluentImpl that = (V2ExternalMetricSourceFluentImpl) o; - if (metric != null ? !metric.equals(that.metric) :that.metric != null) return false; - if (target != null ? !target.equals(that.target) :that.target != null) return false; + if (metric != null ? !metric.equals(that.metric) : that.metric != null) return false; + if (target != null ? !target.equals(that.target) : that.target != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(metric, target, super.hashCode()); + return java.util.Objects.hash(metric, target, super.hashCode()); } - public class MetricNestedImpl extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl> implements io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested,io.kubernetes.client.fluent.Nested{ + + public class MetricNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested> + implements io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.MetricNested, + io.kubernetes.client.fluent.Nested { MetricNestedImpl(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(this, item); } + MetricNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder builder; + public N and() { return (N) V2ExternalMetricSourceFluentImpl.this.withMetric(builder.build()); } + public N endMetric() { return and(); } - } - public class TargetNestedImpl extends io.kubernetes.client.openapi.models.V2MetricTargetFluentImpl> implements io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested,io.kubernetes.client.fluent.Nested{ + + public class TargetNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricTargetFluentImpl< + io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested> + implements io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent.TargetNested, + io.kubernetes.client.fluent.Nested { TargetNestedImpl(io.kubernetes.client.openapi.models.V2MetricTarget item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(this, item); } + TargetNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricTargetBuilder builder; + public N and() { return (N) V2ExternalMetricSourceFluentImpl.this.withTarget(builder.build()); } + public N endTarget() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricStatusBuilder.java index 174f84b9ad..2381b2946c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricStatusBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2ExternalMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2ExternalMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2ExternalMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2ExternalMetricStatus, + io.kubernetes.client.openapi.models.V2ExternalMetricStatusBuilder> { public V2ExternalMetricStatusBuilder() { this(false); } + public V2ExternalMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2ExternalMetricStatus(), validationEnabled); } - public V2ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent fluent) { + + public V2ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent fluent) { this(fluent, false); } - public V2ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2ExternalMetricStatus(), validationEnabled); } - public V2ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2ExternalMetricStatus instance) { + + public V2ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2ExternalMetricStatus instance) { this(fluent, instance, false); } - public V2ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2ExternalMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2ExternalMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCurrent(instance.getCurrent()); fluent.withMetric(instance.getMetric()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ExternalMetricStatus instance) { - this(instance,false); + + public V2ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ExternalMetricStatus instance) { + this(instance, false); } - public V2ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ExternalMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ExternalMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCurrent(instance.getCurrent()); this.withMetric(instance.getMetric()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2ExternalMetricStatus build() { V2ExternalMetricStatus buildable = new V2ExternalMetricStatus(); buildable.setCurrent(fluent.getCurrent()); buildable.setMetric(fluent.getMetric()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2ExternalMetricStatusBuilder that = (V2ExternalMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricStatusFluent.java index 1dff45ea93..520f656f8b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricStatusFluent.java @@ -1,55 +1,95 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2ExternalMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2ExternalMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricValueStatus getCurrent(); + public io.kubernetes.client.openapi.models.V2MetricValueStatus buildCurrent(); + public A withCurrent(io.kubernetes.client.openapi.models.V2MetricValueStatus current); + public java.lang.Boolean hasCurrent(); - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested withNewCurrent(); - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested editCurrent(); - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested editOrNewCurrent(); - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); - + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested + withNewCurrent(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested + editCurrent(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested + editOrNewCurrent(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricIdentifier getMetric(); + public io.kubernetes.client.openapi.models.V2MetricIdentifier buildMetric(); + public A withMetric(io.kubernetes.client.openapi.models.V2MetricIdentifier metric); + public java.lang.Boolean hasMetric(); - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested withNewMetric(); - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested editMetric(); - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested editOrNewMetric(); - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); - public interface CurrentNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricValueStatusFluent>{ + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested + withNewMetric(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested + editMetric(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested + editOrNewMetric(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + + public interface CurrentNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricValueStatusFluent< + io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested> { public N and(); + public N endCurrent(); - } - public interface MetricNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricIdentifierFluent>{ + + public interface MetricNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricIdentifierFluent< + io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested> { public N and(); + public N endMetric(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricStatusFluentImpl.java index ff7245a72c..4dcda17ef1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ExternalMetricStatusFluentImpl.java @@ -1,135 +1,206 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2ExternalMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent { + public V2ExternalMetricStatusFluentImpl() {} - /** - * Generated - */ -public class V2ExternalMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent{ - public V2ExternalMetricStatusFluentImpl() { - } - public V2ExternalMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2ExternalMetricStatus instance) { + public V2ExternalMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2ExternalMetricStatus instance) { this.withCurrent(instance.getCurrent()); this.withMetric(instance.getMetric()); - } + private io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder current; private io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder metric; - + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricValueStatus getCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricValueStatus buildCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public A withCurrent(io.kubernetes.client.openapi.models.V2MetricValueStatus current) { _visitables.get("current").remove(this.current); - if (current!=null){ this.current= new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(current); _visitables.get("current").add(this.current);} return (A) this; + if (current != null) { + this.current = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(current); + _visitables.get("current").add(this.current); + } + return (A) this; } + public java.lang.Boolean hasCurrent() { return this.current != null; } - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested withNewCurrent() { - return new io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluentImpl.CurrentNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested + withNewCurrent() { + return new io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluentImpl + .CurrentNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { - return new io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluentImpl.CurrentNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { + return new io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluentImpl + .CurrentNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested editCurrent() { + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested + editCurrent() { return withNewCurrentLike(getCurrent()); } - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested editOrNewCurrent() { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested + editOrNewCurrent() { + return withNewCurrentLike( + getCurrent() != null + ? getCurrent() + : new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): item); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { + return withNewCurrentLike(getCurrent() != null ? getCurrent() : item); } - + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricIdentifier getMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricIdentifier buildMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public A withMetric(io.kubernetes.client.openapi.models.V2MetricIdentifier metric) { _visitables.get("metric").remove(this.metric); - if (metric!=null){ this.metric= new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(metric); _visitables.get("metric").add(this.metric);} return (A) this; + if (metric != null) { + this.metric = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(metric); + _visitables.get("metric").add(this.metric); + } + return (A) this; } + public java.lang.Boolean hasMetric() { return this.metric != null; } - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested withNewMetric() { - return new io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluentImpl.MetricNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested + withNewMetric() { + return new io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluentImpl + .MetricNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { - return new io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluentImpl.MetricNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { + return new io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluentImpl + .MetricNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested editMetric() { + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested + editMetric() { return withNewMetricLike(getMetric()); } - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested editOrNewMetric() { - return withNewMetricLike(getMetric() != null ? getMetric(): new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested + editOrNewMetric() { + return withNewMetricLike( + getMetric() != null + ? getMetric() + : new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder().build()); } - public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { - return withNewMetricLike(getMetric() != null ? getMetric(): item); + + public io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { + return withNewMetricLike(getMetric() != null ? getMetric() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2ExternalMetricStatusFluentImpl that = (V2ExternalMetricStatusFluentImpl) o; - if (current != null ? !current.equals(that.current) :that.current != null) return false; - if (metric != null ? !metric.equals(that.metric) :that.metric != null) return false; + if (current != null ? !current.equals(that.current) : that.current != null) return false; + if (metric != null ? !metric.equals(that.metric) : that.metric != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(current, metric, super.hashCode()); + return java.util.Objects.hash(current, metric, super.hashCode()); } - public class CurrentNestedImpl extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested,io.kubernetes.client.fluent.Nested{ + + public class CurrentNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluentImpl< + io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested> + implements io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.CurrentNested, + io.kubernetes.client.fluent.Nested { CurrentNestedImpl(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(this, item); } + CurrentNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder builder; + public N and() { return (N) V2ExternalMetricStatusFluentImpl.this.withCurrent(builder.build()); } + public N endCurrent() { return and(); } - } - public class MetricNestedImpl extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl> implements io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested,io.kubernetes.client.fluent.Nested{ + + public class MetricNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested> + implements io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent.MetricNested, + io.kubernetes.client.fluent.Nested { MetricNestedImpl(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(this, item); } + MetricNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder builder; + public N and() { return (N) V2ExternalMetricStatusFluentImpl.this.withMetric(builder.build()); } + public N endMetric() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingPolicyBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingPolicyBuilder.java index 1df4fffdd5..e963c2725c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingPolicyBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingPolicyBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2HPAScalingPolicyBuilder extends io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2HPAScalingPolicyBuilder + extends io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluentImpl< + io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2HPAScalingPolicy, + io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder> { public V2HPAScalingPolicyBuilder() { this(false); } + public V2HPAScalingPolicyBuilder(java.lang.Boolean validationEnabled) { this(new V2HPAScalingPolicy(), validationEnabled); } - public V2HPAScalingPolicyBuilder(io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent fluent) { + + public V2HPAScalingPolicyBuilder( + io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent fluent) { this(fluent, false); } - public V2HPAScalingPolicyBuilder(io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent fluent,java.lang.Boolean validationEnabled) { + + public V2HPAScalingPolicyBuilder( + io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2HPAScalingPolicy(), validationEnabled); } - public V2HPAScalingPolicyBuilder(io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent fluent,io.kubernetes.client.openapi.models.V2HPAScalingPolicy instance) { + + public V2HPAScalingPolicyBuilder( + io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent fluent, + io.kubernetes.client.openapi.models.V2HPAScalingPolicy instance) { this(fluent, instance, false); } - public V2HPAScalingPolicyBuilder(io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent fluent,io.kubernetes.client.openapi.models.V2HPAScalingPolicy instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2HPAScalingPolicyBuilder( + io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent fluent, + io.kubernetes.client.openapi.models.V2HPAScalingPolicy instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPeriodSeconds(instance.getPeriodSeconds()); fluent.withType(instance.getType()); fluent.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2HPAScalingPolicyBuilder(io.kubernetes.client.openapi.models.V2HPAScalingPolicy instance) { - this(instance,false); + + public V2HPAScalingPolicyBuilder( + io.kubernetes.client.openapi.models.V2HPAScalingPolicy instance) { + this(instance, false); } - public V2HPAScalingPolicyBuilder(io.kubernetes.client.openapi.models.V2HPAScalingPolicy instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2HPAScalingPolicyBuilder( + io.kubernetes.client.openapi.models.V2HPAScalingPolicy instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPeriodSeconds(instance.getPeriodSeconds()); this.withType(instance.getType()); this.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2HPAScalingPolicy build() { V2HPAScalingPolicy buildable = new V2HPAScalingPolicy(); buildable.setPeriodSeconds(fluent.getPeriodSeconds()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2HPAScalingPolicy build() { buildable.setValue(fluent.getValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2HPAScalingPolicyBuilder that = (V2HPAScalingPolicyBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingPolicyFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingPolicyFluent.java index c026725010..53045884ed 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingPolicyFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingPolicyFluent.java @@ -1,30 +1,40 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2HPAScalingPolicyFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2HPAScalingPolicyFluent< + A extends io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getPeriodSeconds(); + public A withPeriodSeconds(java.lang.Integer periodSeconds); + public java.lang.Boolean hasPeriodSeconds(); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); + public java.lang.Integer getValue(); + public A withValue(java.lang.Integer value); + public java.lang.Boolean hasValue(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingPolicyFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingPolicyFluentImpl.java index 58c4b68ae4..452a4bf08a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingPolicyFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingPolicyFluentImpl.java @@ -1,75 +1,95 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2HPAScalingPolicyFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent{ - public V2HPAScalingPolicyFluentImpl() { - } - public V2HPAScalingPolicyFluentImpl(io.kubernetes.client.openapi.models.V2HPAScalingPolicy instance) { +/** Generated */ +public class V2HPAScalingPolicyFluentImpl< + A extends io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent { + public V2HPAScalingPolicyFluentImpl() {} + + public V2HPAScalingPolicyFluentImpl( + io.kubernetes.client.openapi.models.V2HPAScalingPolicy instance) { this.withPeriodSeconds(instance.getPeriodSeconds()); this.withType(instance.getType()); this.withValue(instance.getValue()); - } + private java.lang.Integer periodSeconds; private java.lang.String type; private java.lang.Integer value; + public java.lang.Integer getPeriodSeconds() { return this.periodSeconds; } + public A withPeriodSeconds(java.lang.Integer periodSeconds) { - this.periodSeconds=periodSeconds; return (A) this; + this.periodSeconds = periodSeconds; + return (A) this; } + public java.lang.Boolean hasPeriodSeconds() { return this.periodSeconds != null; } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public java.lang.Integer getValue() { return this.value; } + public A withValue(java.lang.Integer value) { - this.value=value; return (A) this; + this.value = value; + return (A) this; } + public java.lang.Boolean hasValue() { return this.value != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2HPAScalingPolicyFluentImpl that = (V2HPAScalingPolicyFluentImpl) o; - if (periodSeconds != null ? !periodSeconds.equals(that.periodSeconds) :that.periodSeconds != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; - if (value != null ? !value.equals(that.value) :that.value != null) return false; + if (periodSeconds != null + ? !periodSeconds.equals(that.periodSeconds) + : that.periodSeconds != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; + if (value != null ? !value.equals(that.value) : that.value != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(periodSeconds, type, value, super.hashCode()); + return java.util.Objects.hash(periodSeconds, type, value, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingRulesBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingRulesBuilder.java index 897fd7531f..8569afa8e2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingRulesBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingRulesBuilder.java @@ -1,49 +1,82 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2HPAScalingRulesBuilder extends io.kubernetes.client.openapi.models.V2HPAScalingRulesFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2HPAScalingRulesBuilder + extends io.kubernetes.client.openapi.models.V2HPAScalingRulesFluentImpl< + io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2HPAScalingRules, + io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder> { public V2HPAScalingRulesBuilder() { this(false); } + public V2HPAScalingRulesBuilder(java.lang.Boolean validationEnabled) { this(new V2HPAScalingRules(), validationEnabled); } - public V2HPAScalingRulesBuilder(io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent fluent) { + + public V2HPAScalingRulesBuilder( + io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent fluent) { this(fluent, false); } - public V2HPAScalingRulesBuilder(io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent fluent,java.lang.Boolean validationEnabled) { + + public V2HPAScalingRulesBuilder( + io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2HPAScalingRules(), validationEnabled); } - public V2HPAScalingRulesBuilder(io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent fluent,io.kubernetes.client.openapi.models.V2HPAScalingRules instance) { + + public V2HPAScalingRulesBuilder( + io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent fluent, + io.kubernetes.client.openapi.models.V2HPAScalingRules instance) { this(fluent, instance, false); } - public V2HPAScalingRulesBuilder(io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent fluent,io.kubernetes.client.openapi.models.V2HPAScalingRules instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2HPAScalingRulesBuilder( + io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent fluent, + io.kubernetes.client.openapi.models.V2HPAScalingRules instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPolicies(instance.getPolicies()); fluent.withSelectPolicy(instance.getSelectPolicy()); fluent.withStabilizationWindowSeconds(instance.getStabilizationWindowSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V2HPAScalingRulesBuilder(io.kubernetes.client.openapi.models.V2HPAScalingRules instance) { - this(instance,false); + this(instance, false); } - public V2HPAScalingRulesBuilder(io.kubernetes.client.openapi.models.V2HPAScalingRules instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2HPAScalingRulesBuilder( + io.kubernetes.client.openapi.models.V2HPAScalingRules instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPolicies(instance.getPolicies()); this.withSelectPolicy(instance.getSelectPolicy()); this.withStabilizationWindowSeconds(instance.getStabilizationWindowSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2HPAScalingRules build() { V2HPAScalingRules buildable = new V2HPAScalingRules(); buildable.setPolicies(fluent.getPolicies()); @@ -51,18 +84,23 @@ public io.kubernetes.client.openapi.models.V2HPAScalingRules build() { buildable.setStabilizationWindowSeconds(fluent.getStabilizationWindowSeconds()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2HPAScalingRulesBuilder that = (V2HPAScalingRulesBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingRulesFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingRulesFluent.java index 646ef710af..1a043ec5aa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingRulesFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingRulesFluent.java @@ -1,69 +1,120 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2HPAScalingRulesFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToPolicies(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HPAScalingPolicy item); - public A setToPolicies(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HPAScalingPolicy item); +/** Generated */ +public interface V2HPAScalingRulesFluent< + A extends io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToPolicies( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2HPAScalingPolicy item); + + public A setToPolicies( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2HPAScalingPolicy item); + public A addToPolicies(io.kubernetes.client.openapi.models.V2HPAScalingPolicy... items); - public A addAllToPolicies(java.util.Collection items); + + public A addAllToPolicies( + java.util.Collection items); + public A removeFromPolicies(io.kubernetes.client.openapi.models.V2HPAScalingPolicy... items); - public A removeAllFromPolicies(java.util.Collection items); - public A removeMatchingFromPolicies(java.util.function.Predicate predicate); - + + public A removeAllFromPolicies( + java.util.Collection items); + + public A removeMatchingFromPolicies( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildPolicies instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getPolicies(); + public java.util.List buildPolicies(); - public io.kubernetes.client.openapi.models.V2HPAScalingPolicy buildPolicy(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2HPAScalingPolicy buildPolicy( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V2HPAScalingPolicy buildFirstPolicy(); + public io.kubernetes.client.openapi.models.V2HPAScalingPolicy buildLastPolicy(); - public io.kubernetes.client.openapi.models.V2HPAScalingPolicy buildMatchingPolicy(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPolicy(java.util.function.Predicate predicate); - public A withPolicies(java.util.List policies); + + public io.kubernetes.client.openapi.models.V2HPAScalingPolicy buildMatchingPolicy( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingPolicy( + java.util.function.Predicate + predicate); + + public A withPolicies( + java.util.List policies); + public A withPolicies(io.kubernetes.client.openapi.models.V2HPAScalingPolicy... policies); + public java.lang.Boolean hasPolicies(); - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested addNewPolicy(); - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested addNewPolicyLike(io.kubernetes.client.openapi.models.V2HPAScalingPolicy item); - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested setNewPolicyLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HPAScalingPolicy item); - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested editPolicy(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested editFirstPolicy(); - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested editLastPolicy(); - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested editMatchingPolicy(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested + addNewPolicy(); + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested + addNewPolicyLike(io.kubernetes.client.openapi.models.V2HPAScalingPolicy item); + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested + setNewPolicyLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2HPAScalingPolicy item); + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested editPolicy( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested + editFirstPolicy(); + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested + editLastPolicy(); + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested + editMatchingPolicy( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder> + predicate); + public java.lang.String getSelectPolicy(); + public A withSelectPolicy(java.lang.String selectPolicy); + public java.lang.Boolean hasSelectPolicy(); - - /** - * Method is deprecated. use withSelectPolicy instead. - */ + + /** Method is deprecated. use withSelectPolicy instead. */ @java.lang.Deprecated public A withNewSelectPolicy(java.lang.String original); + public java.lang.Integer getStabilizationWindowSeconds(); + public A withStabilizationWindowSeconds(java.lang.Integer stabilizationWindowSeconds); + public java.lang.Boolean hasStabilizationWindowSeconds(); - public interface PoliciesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent>{ + + public interface PoliciesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluent< + io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested> { public N and(); + public N endPolicy(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingRulesFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingRulesFluentImpl.java index 88244c9673..62d9cc9be0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingRulesFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HPAScalingRulesFluentImpl.java @@ -1,64 +1,137 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V2HPAScalingRulesFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent{ - public V2HPAScalingRulesFluentImpl() { - } - public V2HPAScalingRulesFluentImpl(io.kubernetes.client.openapi.models.V2HPAScalingRules instance) { +/** Generated */ +public class V2HPAScalingRulesFluentImpl< + A extends io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent { + public V2HPAScalingRulesFluentImpl() {} + + public V2HPAScalingRulesFluentImpl( + io.kubernetes.client.openapi.models.V2HPAScalingRules instance) { this.withPolicies(instance.getPolicies()); this.withSelectPolicy(instance.getSelectPolicy()); this.withStabilizationWindowSeconds(instance.getStabilizationWindowSeconds()); - } - private java.util.ArrayList policies; + + private java.util.ArrayList + policies; private java.lang.String selectPolicy; private java.lang.Integer stabilizationWindowSeconds; - public A addToPolicies(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HPAScalingPolicy item) { - if (this.policies == null) {this.policies = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder = new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(item);_visitables.get("policies").add(index >= 0 ? index : _visitables.get("policies").size(), builder);this.policies.add(index >= 0 ? index : policies.size(), builder); return (A)this; + + public A addToPolicies( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2HPAScalingPolicy item) { + if (this.policies == null) { + this.policies = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(item); + _visitables + .get("policies") + .add(index >= 0 ? index : _visitables.get("policies").size(), builder); + this.policies.add(index >= 0 ? index : policies.size(), builder); + return (A) this; } - public A setToPolicies(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HPAScalingPolicy item) { - if (this.policies == null) {this.policies = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder = new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(item); - if (index < 0 || index >= _visitables.get("policies").size()) { _visitables.get("policies").add(builder); } else { _visitables.get("policies").set(index, builder);} - if (index < 0 || index >= policies.size()) { policies.add(builder); } else { policies.set(index, builder);} - return (A)this; + + public A setToPolicies( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2HPAScalingPolicy item) { + if (this.policies == null) { + this.policies = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(item); + if (index < 0 || index >= _visitables.get("policies").size()) { + _visitables.get("policies").add(builder); + } else { + _visitables.get("policies").set(index, builder); + } + if (index < 0 || index >= policies.size()) { + policies.add(builder); + } else { + policies.set(index, builder); + } + return (A) this; } + public A addToPolicies(io.kubernetes.client.openapi.models.V2HPAScalingPolicy... items) { - if (this.policies == null) {this.policies = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2HPAScalingPolicy item : items) {io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder = new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(item);_visitables.get("policies").add(builder);this.policies.add(builder);} return (A)this; + if (this.policies == null) { + this.policies = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2HPAScalingPolicy item : items) { + io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(item); + _visitables.get("policies").add(builder); + this.policies.add(builder); + } + return (A) this; } - public A addAllToPolicies(java.util.Collection items) { - if (this.policies == null) {this.policies = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2HPAScalingPolicy item : items) {io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder = new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(item);_visitables.get("policies").add(builder);this.policies.add(builder);} return (A)this; + + public A addAllToPolicies( + java.util.Collection items) { + if (this.policies == null) { + this.policies = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2HPAScalingPolicy item : items) { + io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(item); + _visitables.get("policies").add(builder); + this.policies.add(builder); + } + return (A) this; } + public A removeFromPolicies(io.kubernetes.client.openapi.models.V2HPAScalingPolicy... items) { - for (io.kubernetes.client.openapi.models.V2HPAScalingPolicy item : items) {io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder = new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(item);_visitables.get("policies").remove(builder);if (this.policies != null) {this.policies.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V2HPAScalingPolicy item : items) { + io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(item); + _visitables.get("policies").remove(builder); + if (this.policies != null) { + this.policies.remove(builder); + } + } + return (A) this; } - public A removeAllFromPolicies(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2HPAScalingPolicy item : items) {io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder = new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(item);_visitables.get("policies").remove(builder);if (this.policies != null) {this.policies.remove(builder);}} return (A)this; + + public A removeAllFromPolicies( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V2HPAScalingPolicy item : items) { + io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(item); + _visitables.get("policies").remove(builder); + if (this.policies != null) { + this.policies.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPolicies(java.util.function.Predicate predicate) { + + public A removeMatchingFromPolicies( + java.util.function.Predicate + predicate) { if (policies == null) return (A) this; - final Iterator each = policies.iterator(); + final Iterator each = + policies.iterator(); final List visitables = _visitables.get("policies"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder = each.next(); @@ -67,132 +140,220 @@ public A removeMatchingFromPolicies(java.util.function.Predicate getPolicies() { return policies != null ? build(policies) : null; } + public java.util.List buildPolicies() { return policies != null ? build(policies) : null; } - public io.kubernetes.client.openapi.models.V2HPAScalingPolicy buildPolicy(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2HPAScalingPolicy buildPolicy( + java.lang.Integer index) { return this.policies.get(index).build(); } + public io.kubernetes.client.openapi.models.V2HPAScalingPolicy buildFirstPolicy() { return this.policies.get(0).build(); } + public io.kubernetes.client.openapi.models.V2HPAScalingPolicy buildLastPolicy() { return this.policies.get(policies.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2HPAScalingPolicy buildMatchingPolicy(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder item: policies) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2HPAScalingPolicy buildMatchingPolicy( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder item : policies) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPolicy(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder item: policies) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPolicy( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder item : policies) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withPolicies(java.util.List policies) { - if (this.policies != null) { _visitables.get("policies").removeAll(this.policies);} - if (policies != null) {this.policies = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2HPAScalingPolicy item : policies){this.addToPolicies(item);}} else { this.policies = null;} return (A) this; + + public A withPolicies( + java.util.List policies) { + if (this.policies != null) { + _visitables.get("policies").removeAll(this.policies); + } + if (policies != null) { + this.policies = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2HPAScalingPolicy item : policies) { + this.addToPolicies(item); + } + } else { + this.policies = null; + } + return (A) this; } + public A withPolicies(io.kubernetes.client.openapi.models.V2HPAScalingPolicy... policies) { - if (this.policies != null) {this.policies.clear();} - if (policies != null) {for (io.kubernetes.client.openapi.models.V2HPAScalingPolicy item :policies){ this.addToPolicies(item);}} return (A) this; + if (this.policies != null) { + this.policies.clear(); + } + if (policies != null) { + for (io.kubernetes.client.openapi.models.V2HPAScalingPolicy item : policies) { + this.addToPolicies(item); + } + } + return (A) this; } + public java.lang.Boolean hasPolicies() { return policies != null && !policies.isEmpty(); } - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested addNewPolicy() { + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested + addNewPolicy() { return new io.kubernetes.client.openapi.models.V2HPAScalingRulesFluentImpl.PoliciesNestedImpl(); } - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested addNewPolicyLike(io.kubernetes.client.openapi.models.V2HPAScalingPolicy item) { - return new io.kubernetes.client.openapi.models.V2HPAScalingRulesFluentImpl.PoliciesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested + addNewPolicyLike(io.kubernetes.client.openapi.models.V2HPAScalingPolicy item) { + return new io.kubernetes.client.openapi.models.V2HPAScalingRulesFluentImpl.PoliciesNestedImpl( + -1, item); } - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested setNewPolicyLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HPAScalingPolicy item) { - return new io.kubernetes.client.openapi.models.V2HPAScalingRulesFluentImpl.PoliciesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested + setNewPolicyLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2HPAScalingPolicy item) { + return new io.kubernetes.client.openapi.models.V2HPAScalingRulesFluentImpl.PoliciesNestedImpl( + index, item); } - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested editPolicy(java.lang.Integer index) { - if (policies.size() <= index) throw new RuntimeException("Can't edit policies. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested editPolicy( + java.lang.Integer index) { + if (policies.size() <= index) + throw new RuntimeException("Can't edit policies. Index exceeds size."); return setNewPolicyLike(index, buildPolicy(index)); } - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested editFirstPolicy() { - if (policies.size() == 0) throw new RuntimeException("Can't edit first policies. The list is empty."); + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested + editFirstPolicy() { + if (policies.size() == 0) + throw new RuntimeException("Can't edit first policies. The list is empty."); return setNewPolicyLike(0, buildPolicy(0)); } - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested editLastPolicy() { + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested + editLastPolicy() { int index = policies.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last policies. The list is empty."); return setNewPolicyLike(index, buildPolicy(index)); } - public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested editMatchingPolicy(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested + editMatchingPolicy( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluentImpl> implements io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested,io.kubernetes.client.fluent.Nested{ - PoliciesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HPAScalingPolicy item) { + + public class PoliciesNestedImpl + extends io.kubernetes.client.openapi.models.V2HPAScalingPolicyFluentImpl< + io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested> + implements io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent.PoliciesNested, + io.kubernetes.client.fluent.Nested { + PoliciesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2HPAScalingPolicy item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(this, item); } + PoliciesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder(this); } + io.kubernetes.client.openapi.models.V2HPAScalingPolicyBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2HPAScalingRulesFluentImpl.this.setToPolicies(index,builder.build()); + return (N) V2HPAScalingRulesFluentImpl.this.setToPolicies(index, builder.build()); } + public N endPolicy() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBehaviorBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBehaviorBuilder.java index 3e8876a6a2..340b2cf92c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBehaviorBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBehaviorBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2HorizontalPodAutoscalerBehaviorBuilder extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2HorizontalPodAutoscalerBehaviorBuilder + extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorBuilder> { public V2HorizontalPodAutoscalerBehaviorBuilder() { this(false); } + public V2HorizontalPodAutoscalerBehaviorBuilder(java.lang.Boolean validationEnabled) { this(new V2HorizontalPodAutoscalerBehavior(), validationEnabled); } - public V2HorizontalPodAutoscalerBehaviorBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent fluent) { + + public V2HorizontalPodAutoscalerBehaviorBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent fluent) { this(fluent, false); } - public V2HorizontalPodAutoscalerBehaviorBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent fluent,java.lang.Boolean validationEnabled) { + + public V2HorizontalPodAutoscalerBehaviorBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2HorizontalPodAutoscalerBehavior(), validationEnabled); } - public V2HorizontalPodAutoscalerBehaviorBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent fluent,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior instance) { + + public V2HorizontalPodAutoscalerBehaviorBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent fluent, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior instance) { this(fluent, instance, false); } - public V2HorizontalPodAutoscalerBehaviorBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent fluent,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2HorizontalPodAutoscalerBehaviorBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent fluent, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withScaleDown(instance.getScaleDown()); fluent.withScaleUp(instance.getScaleUp()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2HorizontalPodAutoscalerBehaviorBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior instance) { - this(instance,false); + + public V2HorizontalPodAutoscalerBehaviorBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior instance) { + this(instance, false); } - public V2HorizontalPodAutoscalerBehaviorBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2HorizontalPodAutoscalerBehaviorBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withScaleDown(instance.getScaleDown()); this.withScaleUp(instance.getScaleUp()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior build() { V2HorizontalPodAutoscalerBehavior buildable = new V2HorizontalPodAutoscalerBehavior(); buildable.setScaleDown(fluent.getScaleDown()); buildable.setScaleUp(fluent.getScaleUp()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2HorizontalPodAutoscalerBehaviorBuilder that = (V2HorizontalPodAutoscalerBehaviorBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBehaviorFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBehaviorFluent.java index df6707c609..1f6ef78fcb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBehaviorFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBehaviorFluent.java @@ -1,55 +1,114 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2HorizontalPodAutoscalerBehaviorFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2HorizontalPodAutoscalerBehaviorFluent< + A extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildScaleDown instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2HPAScalingRules getScaleDown(); + public io.kubernetes.client.openapi.models.V2HPAScalingRules buildScaleDown(); + public A withScaleDown(io.kubernetes.client.openapi.models.V2HPAScalingRules scaleDown); + public java.lang.Boolean hasScaleDown(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested withNewScaleDown(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested withNewScaleDownLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested editScaleDown(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested editOrNewScaleDown(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested editOrNewScaleDownLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item); - + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + withNewScaleDown(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + withNewScaleDownLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + editScaleDown(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + editOrNewScaleDown(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + editOrNewScaleDownLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item); + /** * This method has been deprecated, please use method buildScaleUp instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2HPAScalingRules getScaleUp(); + public io.kubernetes.client.openapi.models.V2HPAScalingRules buildScaleUp(); + public A withScaleUp(io.kubernetes.client.openapi.models.V2HPAScalingRules scaleUp); + public java.lang.Boolean hasScaleUp(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested withNewScaleUp(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested withNewScaleUpLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested editScaleUp(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested editOrNewScaleUp(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested editOrNewScaleUpLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item); - public interface ScaleDownNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent>{ + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested< + A> + withNewScaleUp(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested< + A> + withNewScaleUpLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested< + A> + editScaleUp(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested< + A> + editOrNewScaleUp(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested< + A> + editOrNewScaleUpLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item); + + public interface ScaleDownNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + N>> { public N and(); + public N endScaleDown(); - } - public interface ScaleUpNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent>{ + + public interface ScaleUpNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2HPAScalingRulesFluent< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + N>> { public N and(); + public N endScaleUp(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBehaviorFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBehaviorFluentImpl.java index b6a1327b83..211f2ae351 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBehaviorFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBehaviorFluentImpl.java @@ -1,135 +1,230 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2HorizontalPodAutoscalerBehaviorFluentImpl< + A extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent { + public V2HorizontalPodAutoscalerBehaviorFluentImpl() {} - /** - * Generated - */ -public class V2HorizontalPodAutoscalerBehaviorFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent{ - public V2HorizontalPodAutoscalerBehaviorFluentImpl() { - } - public V2HorizontalPodAutoscalerBehaviorFluentImpl(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior instance) { + public V2HorizontalPodAutoscalerBehaviorFluentImpl( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior instance) { this.withScaleDown(instance.getScaleDown()); this.withScaleUp(instance.getScaleUp()); - } + private io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder scaleDown; private io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder scaleUp; - + /** * This method has been deprecated, please use method buildScaleDown instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2HPAScalingRules getScaleDown() { - return this.scaleDown!=null ?this.scaleDown.build():null; + return this.scaleDown != null ? this.scaleDown.build() : null; } + public io.kubernetes.client.openapi.models.V2HPAScalingRules buildScaleDown() { - return this.scaleDown!=null ?this.scaleDown.build():null; + return this.scaleDown != null ? this.scaleDown.build() : null; } + public A withScaleDown(io.kubernetes.client.openapi.models.V2HPAScalingRules scaleDown) { _visitables.get("scaleDown").remove(this.scaleDown); - if (scaleDown!=null){ this.scaleDown= new io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder(scaleDown); _visitables.get("scaleDown").add(this.scaleDown);} return (A) this; + if (scaleDown != null) { + this.scaleDown = new io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder(scaleDown); + _visitables.get("scaleDown").add(this.scaleDown); + } + return (A) this; } + public java.lang.Boolean hasScaleDown() { return this.scaleDown != null; } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested withNewScaleDown() { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluentImpl.ScaleDownNestedImpl(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + withNewScaleDown() { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluentImpl + .ScaleDownNestedImpl(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested withNewScaleDownLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluentImpl.ScaleDownNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + withNewScaleDownLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluentImpl + .ScaleDownNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested editScaleDown() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + editScaleDown() { return withNewScaleDownLike(getScaleDown()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested editOrNewScaleDown() { - return withNewScaleDownLike(getScaleDown() != null ? getScaleDown(): new io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder().build()); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + editOrNewScaleDown() { + return withNewScaleDownLike( + getScaleDown() != null + ? getScaleDown() + : new io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder().build()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested editOrNewScaleDownLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item) { - return withNewScaleDownLike(getScaleDown() != null ? getScaleDown(): item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + editOrNewScaleDownLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item) { + return withNewScaleDownLike(getScaleDown() != null ? getScaleDown() : item); } - + /** * This method has been deprecated, please use method buildScaleUp instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2HPAScalingRules getScaleUp() { - return this.scaleUp!=null ?this.scaleUp.build():null; + return this.scaleUp != null ? this.scaleUp.build() : null; } + public io.kubernetes.client.openapi.models.V2HPAScalingRules buildScaleUp() { - return this.scaleUp!=null ?this.scaleUp.build():null; + return this.scaleUp != null ? this.scaleUp.build() : null; } + public A withScaleUp(io.kubernetes.client.openapi.models.V2HPAScalingRules scaleUp) { _visitables.get("scaleUp").remove(this.scaleUp); - if (scaleUp!=null){ this.scaleUp= new io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder(scaleUp); _visitables.get("scaleUp").add(this.scaleUp);} return (A) this; + if (scaleUp != null) { + this.scaleUp = new io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder(scaleUp); + _visitables.get("scaleUp").add(this.scaleUp); + } + return (A) this; } + public java.lang.Boolean hasScaleUp() { return this.scaleUp != null; } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested withNewScaleUp() { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluentImpl.ScaleUpNestedImpl(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested< + A> + withNewScaleUp() { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluentImpl + .ScaleUpNestedImpl(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested withNewScaleUpLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluentImpl.ScaleUpNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested< + A> + withNewScaleUpLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluentImpl + .ScaleUpNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested editScaleUp() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested< + A> + editScaleUp() { return withNewScaleUpLike(getScaleUp()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested editOrNewScaleUp() { - return withNewScaleUpLike(getScaleUp() != null ? getScaleUp(): new io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder().build()); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested< + A> + editOrNewScaleUp() { + return withNewScaleUpLike( + getScaleUp() != null + ? getScaleUp() + : new io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder().build()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested editOrNewScaleUpLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item) { - return withNewScaleUpLike(getScaleUp() != null ? getScaleUp(): item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested< + A> + editOrNewScaleUpLike(io.kubernetes.client.openapi.models.V2HPAScalingRules item) { + return withNewScaleUpLike(getScaleUp() != null ? getScaleUp() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2HorizontalPodAutoscalerBehaviorFluentImpl that = (V2HorizontalPodAutoscalerBehaviorFluentImpl) o; - if (scaleDown != null ? !scaleDown.equals(that.scaleDown) :that.scaleDown != null) return false; - if (scaleUp != null ? !scaleUp.equals(that.scaleUp) :that.scaleUp != null) return false; + V2HorizontalPodAutoscalerBehaviorFluentImpl that = + (V2HorizontalPodAutoscalerBehaviorFluentImpl) o; + if (scaleDown != null ? !scaleDown.equals(that.scaleDown) : that.scaleDown != null) + return false; + if (scaleUp != null ? !scaleUp.equals(that.scaleUp) : that.scaleUp != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(scaleDown, scaleUp, super.hashCode()); + return java.util.Objects.hash(scaleDown, scaleUp, super.hashCode()); } - public class ScaleDownNestedImpl extends io.kubernetes.client.openapi.models.V2HPAScalingRulesFluentImpl> implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested,io.kubernetes.client.fluent.Nested{ + + public class ScaleDownNestedImpl + extends io.kubernetes.client.openapi.models.V2HPAScalingRulesFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + N>> + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + N>, + io.kubernetes.client.fluent.Nested { ScaleDownNestedImpl(io.kubernetes.client.openapi.models.V2HPAScalingRules item) { this.builder = new io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder(this, item); } + ScaleDownNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder(this); } + io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder builder; + public N and() { return (N) V2HorizontalPodAutoscalerBehaviorFluentImpl.this.withScaleDown(builder.build()); } + public N endScaleDown() { return and(); } - } - public class ScaleUpNestedImpl extends io.kubernetes.client.openapi.models.V2HPAScalingRulesFluentImpl> implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested,io.kubernetes.client.fluent.Nested{ + + public class ScaleUpNestedImpl + extends io.kubernetes.client.openapi.models.V2HPAScalingRulesFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested< + N>> + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + N>, + io.kubernetes.client.fluent.Nested { ScaleUpNestedImpl(io.kubernetes.client.openapi.models.V2HPAScalingRules item) { this.builder = new io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder(this, item); } + ScaleUpNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder(this); } + io.kubernetes.client.openapi.models.V2HPAScalingRulesBuilder builder; + public N and() { return (N) V2HorizontalPodAutoscalerBehaviorFluentImpl.this.withScaleUp(builder.build()); } + public N endScaleUp() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBuilder.java index 7f28cde5ec..2397d742dd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2HorizontalPodAutoscalerBuilder extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2HorizontalPodAutoscalerBuilder + extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder> { public V2HorizontalPodAutoscalerBuilder() { this(false); } + public V2HorizontalPodAutoscalerBuilder(java.lang.Boolean validationEnabled) { this(new V2HorizontalPodAutoscaler(), validationEnabled); } - public V2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent fluent) { + + public V2HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent fluent) { this(fluent, false); } - public V2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent fluent,java.lang.Boolean validationEnabled) { + + public V2HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2HorizontalPodAutoscaler(), validationEnabled); } - public V2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent fluent,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler instance) { + + public V2HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent fluent, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler instance) { this(fluent, instance, false); } - public V2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent fluent,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent fluent, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2Ho fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler instance) { - this(instance,false); + + public V2HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler instance) { + this(instance, false); } - public V2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2Ho this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler build() { V2HorizontalPodAutoscaler buildable = new V2HorizontalPodAutoscaler(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler build() { buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2HorizontalPodAutoscalerBuilder that = (V2HorizontalPodAutoscalerBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerConditionBuilder.java index 5fd5d905c2..5f555d1a66 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2HorizontalPodAutoscalerConditionBuilder extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2HorizontalPodAutoscalerConditionBuilder + extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder> { public V2HorizontalPodAutoscalerConditionBuilder() { this(false); } + public V2HorizontalPodAutoscalerConditionBuilder(java.lang.Boolean validationEnabled) { this(new V2HorizontalPodAutoscalerCondition(), validationEnabled); } - public V2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent fluent) { + + public V2HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent fluent) { this(fluent, false); } - public V2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V2HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2HorizontalPodAutoscalerCondition(), validationEnabled); } - public V2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent fluent,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition instance) { + + public V2HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent fluent, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition instance) { this(fluent, instance, false); } - public V2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent fluent,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent fluent, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +58,18 @@ public V2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.mo fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition instance) { - this(instance,false); + + public V2HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition instance) { + this(instance, false); } - public V2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,10 +80,12 @@ public V2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.mo this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition build() { V2HorizontalPodAutoscalerCondition buildable = new V2HorizontalPodAutoscalerCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition bu buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2HorizontalPodAutoscalerConditionBuilder that = (V2HorizontalPodAutoscalerConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerConditionFluent.java index e02c58af00..73d26a99fc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerConditionFluent.java @@ -1,54 +1,64 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2HorizontalPodAutoscalerConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2HorizontalPodAutoscalerConditionFluent< + A extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerConditionFluentImpl.java index 0da6f353a7..5c90c104a4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerConditionFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V2HorizontalPodAutoscalerConditionFluentImpl< + A extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent { + public V2HorizontalPodAutoscalerConditionFluentImpl() {} - /** - * Generated - */ -public class V2HorizontalPodAutoscalerConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent{ - public V2HorizontalPodAutoscalerConditionFluentImpl() { - } - public V2HorizontalPodAutoscalerConditionFluentImpl(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition instance) { + public V2HorizontalPodAutoscalerConditionFluentImpl( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,103 +30,120 @@ public V2HorizontalPodAutoscalerConditionFluentImpl(io.kubernetes.client.openapi this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2HorizontalPodAutoscalerConditionFluentImpl that = (V2HorizontalPodAutoscalerConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + V2HorizontalPodAutoscalerConditionFluentImpl that = + (V2HorizontalPodAutoscalerConditionFluentImpl) o; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerFluent.java index 180998c2e0..323ee63a45 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerFluent.java @@ -1,93 +1,153 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2HorizontalPodAutoscalerFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2HorizontalPodAutoscalerFluent< + A extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec getSpec(); + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec item); - + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus getStatus(); + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus buildStatus(); + public A withStatus(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatusLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerFluentImpl.java index abc0b6e0f2..774c4a1a4d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2HorizontalPodAutoscalerFluentImpl< + A extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent { + public V2HorizontalPodAutoscalerFluentImpl() {} - /** - * Generated - */ -public class V2HorizontalPodAutoscalerFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent{ - public V2HorizontalPodAutoscalerFluentImpl() { - } - public V2HorizontalPodAutoscalerFluentImpl(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler instance) { + public V2HorizontalPodAutoscalerFluentImpl( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,321 @@ public V2HorizontalPodAutoscalerFluentImpl(io.kubernetes.client.openapi.models.V this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecBuilder spec; private io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpecLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public A withStatus(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusBuilder(status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested + withNewStatusLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2HorizontalPodAutoscalerFluentImpl that = (V2HorizontalPodAutoscalerFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V2HorizontalPodAutoscalerFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl> implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.SpecNested, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecBuilder(this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecBuilder(this); } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecBuilder builder; + public N and() { return (N) V2HorizontalPodAutoscalerFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested,io.kubernetes.client.fluent.Nested{ + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent.StatusNested< + N>, + io.kubernetes.client.fluent.Nested { StatusNestedImpl(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusBuilder( + this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusBuilder builder; + public N and() { return (N) V2HorizontalPodAutoscalerFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerListBuilder.java index 9a3893d78f..e7e169ed9a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2HorizontalPodAutoscalerListBuilder extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2HorizontalPodAutoscalerListBuilder + extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerList, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListBuilder> { public V2HorizontalPodAutoscalerListBuilder() { this(false); } + public V2HorizontalPodAutoscalerListBuilder(java.lang.Boolean validationEnabled) { this(new V2HorizontalPodAutoscalerList(), validationEnabled); } - public V2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent fluent) { + + public V2HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent fluent) { this(fluent, false); } - public V2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent fluent,java.lang.Boolean validationEnabled) { + + public V2HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2HorizontalPodAutoscalerList(), validationEnabled); } - public V2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent fluent,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerList instance) { + + public V2HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent fluent, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerList instance) { this(fluent, instance, false); } - public V2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent fluent,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent fluent, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models. fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerList instance) { - this(instance,false); + + public V2HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerList instance) { + this(instance, false); } - public V2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models. this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerList build() { V2HorizontalPodAutoscalerList buildable = new V2HorizontalPodAutoscalerList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerList build() buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2HorizontalPodAutoscalerListBuilder that = (V2HorizontalPodAutoscalerListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerListFluent.java index 9365adff95..cc6a0a0663 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerListFluent.java @@ -1,95 +1,169 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2HorizontalPodAutoscalerListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2HorizontalPodAutoscalerListFluent< + A extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item); + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item); + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item); + public A addToItems(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler... items); - public A addAllToItems(java.util.Collection items); + + public A addAllToItems( + java.util.Collection items); + public A removeFromItems(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A removeAllFromItems( + java.util.Collection items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getItems(); + public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler buildItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler buildFirstItem(); + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler buildLastItem(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent>{ + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluent< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerListFluentImpl.java index 73e503cc9a..3bf7fe8298 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V2HorizontalPodAutoscalerListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent{ - public V2HorizontalPodAutoscalerListFluentImpl() { - } - public V2HorizontalPodAutoscalerListFluentImpl(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerList instance) { + +/** Generated */ +public class V2HorizontalPodAutoscalerListFluentImpl< + A extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent { + public V2HorizontalPodAutoscalerListFluentImpl() {} + + public V2HorizontalPodAutoscalerListFluentImpl( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,57 +31,132 @@ public V2HorizontalPodAutoscalerListFluentImpl(io.kubernetes.client.openapi.mode this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder>(); + } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder>(); + } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } + public A removeFromItems(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler... items) { - for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder = each.next(); @@ -87,174 +165,295 @@ public A removeMatchingFromItems(java.util.function.Predicate getItems() { return items != null ? build(items) : null; } - public java.util.List buildItems() { + + public java.util.List + buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2HorizontalPodAutoscalerListFluentImpl that = (V2HorizontalPodAutoscalerListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl> implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.ItemsNested> + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent + .ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscaler item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder(this); } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2HorizontalPodAutoscalerListFluentImpl.this.setToItems(index,builder.build()); + return (N) V2HorizontalPodAutoscalerListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent.MetadataNested> + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V2HorizontalPodAutoscalerListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerSpecBuilder.java index 273a40938a..9179c47728 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2HorizontalPodAutoscalerSpecBuilder extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2HorizontalPodAutoscalerSpecBuilder + extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecBuilder> { public V2HorizontalPodAutoscalerSpecBuilder() { this(false); } + public V2HorizontalPodAutoscalerSpecBuilder(java.lang.Boolean validationEnabled) { this(new V2HorizontalPodAutoscalerSpec(), validationEnabled); } - public V2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent fluent) { + + public V2HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent fluent) { this(fluent, false); } - public V2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V2HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2HorizontalPodAutoscalerSpec(), validationEnabled); } - public V2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent fluent,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec instance) { + + public V2HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent fluent, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec instance) { this(fluent, instance, false); } - public V2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent fluent,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent fluent, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withBehavior(instance.getBehavior()); fluent.withMaxReplicas(instance.getMaxReplicas()); @@ -31,13 +58,18 @@ public V2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models. fluent.withScaleTargetRef(instance.getScaleTargetRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec instance) { - this(instance,false); + + public V2HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec instance) { + this(instance, false); } - public V2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withBehavior(instance.getBehavior()); this.withMaxReplicas(instance.getMaxReplicas()); @@ -48,10 +80,12 @@ public V2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models. this.withScaleTargetRef(instance.getScaleTargetRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec build() { V2HorizontalPodAutoscalerSpec buildable = new V2HorizontalPodAutoscalerSpec(); buildable.setBehavior(fluent.getBehavior()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec build() buildable.setScaleTargetRef(fluent.getScaleTargetRef()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2HorizontalPodAutoscalerSpecBuilder that = (V2HorizontalPodAutoscalerSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerSpecFluent.java index 7f636d72e1..c7be711dbb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerSpecFluent.java @@ -1,103 +1,211 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V2HorizontalPodAutoscalerSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2HorizontalPodAutoscalerSpecFluent< + A extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildBehavior instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior getBehavior(); + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior buildBehavior(); - public A withBehavior(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior behavior); + + public A withBehavior( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior behavior); + public java.lang.Boolean hasBehavior(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested withNewBehavior(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested withNewBehaviorLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested editBehavior(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested editOrNewBehavior(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested editOrNewBehaviorLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested + withNewBehavior(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested + withNewBehaviorLike( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested + editBehavior(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested + editOrNewBehavior(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested + editOrNewBehaviorLike( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior item); + public java.lang.Integer getMaxReplicas(); + public A withMaxReplicas(java.lang.Integer maxReplicas); + public java.lang.Boolean hasMaxReplicas(); - public A addToMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2MetricSpec item); - public A setToMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2MetricSpec item); + + public A addToMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricSpec item); + + public A setToMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricSpec item); + public A addToMetrics(io.kubernetes.client.openapi.models.V2MetricSpec... items); - public A addAllToMetrics(java.util.Collection items); + + public A addAllToMetrics( + java.util.Collection items); + public A removeFromMetrics(io.kubernetes.client.openapi.models.V2MetricSpec... items); - public A removeAllFromMetrics(java.util.Collection items); - public A removeMatchingFromMetrics(java.util.function.Predicate predicate); - + + public A removeAllFromMetrics( + java.util.Collection items); + + public A removeMatchingFromMetrics( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildMetrics instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getMetrics(); + public java.util.List buildMetrics(); + public io.kubernetes.client.openapi.models.V2MetricSpec buildMetric(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V2MetricSpec buildFirstMetric(); + public io.kubernetes.client.openapi.models.V2MetricSpec buildLastMetric(); - public io.kubernetes.client.openapi.models.V2MetricSpec buildMatchingMetric(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMetric(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V2MetricSpec buildMatchingMetric( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingMetric( + java.util.function.Predicate + predicate); + public A withMetrics(java.util.List metrics); + public A withMetrics(io.kubernetes.client.openapi.models.V2MetricSpec... metrics); + public java.lang.Boolean hasMetrics(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested addNewMetric(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested addNewMetricLike(io.kubernetes.client.openapi.models.V2MetricSpec item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested setNewMetricLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2MetricSpec item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested editMetric(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested editFirstMetric(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested editLastMetric(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested editMatchingMetric(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + addNewMetric(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + addNewMetricLike(io.kubernetes.client.openapi.models.V2MetricSpec item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + setNewMetricLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricSpec item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + editMetric(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + editFirstMetric(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + editLastMetric(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + editMatchingMetric( + java.util.function.Predicate + predicate); + public java.lang.Integer getMinReplicas(); + public A withMinReplicas(java.lang.Integer minReplicas); + public java.lang.Boolean hasMinReplicas(); - + /** * This method has been deprecated, please use method buildScaleTargetRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2CrossVersionObjectReference getScaleTargetRef(); + public io.kubernetes.client.openapi.models.V2CrossVersionObjectReference buildScaleTargetRef(); - public A withScaleTargetRef(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference scaleTargetRef); + + public A withScaleTargetRef( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference scaleTargetRef); + public java.lang.Boolean hasScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested withNewScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested withNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item); - public interface BehaviorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent>{ + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRef(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editScaleTargetRef(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRef(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item); + + public interface BehaviorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluent< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + N>> { public N and(); + public N endBehavior(); - } - public interface MetricsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricSpecFluent>{ + + public interface MetricsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricSpecFluent< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested< + N>> { public N and(); + public N endMetric(); - } - public interface ScaleTargetRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent>{ + + public interface ScaleTargetRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + N>> { public N and(); + public N endScaleTargetRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerSpecFluentImpl.java index 7b92398f7b..981dad4c1e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerSpecFluentImpl.java @@ -1,25 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V2HorizontalPodAutoscalerSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent{ - public V2HorizontalPodAutoscalerSpecFluentImpl() { - } - public V2HorizontalPodAutoscalerSpecFluentImpl(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec instance) { + +/** Generated */ +public class V2HorizontalPodAutoscalerSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent { + public V2HorizontalPodAutoscalerSpecFluentImpl() {} + + public V2HorizontalPodAutoscalerSpecFluentImpl( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpec instance) { this.withBehavior(instance.getBehavior()); this.withMaxReplicas(instance.getMaxReplicas()); @@ -29,84 +33,184 @@ public V2HorizontalPodAutoscalerSpecFluentImpl(io.kubernetes.client.openapi.mode this.withMinReplicas(instance.getMinReplicas()); this.withScaleTargetRef(instance.getScaleTargetRef()); - } + private io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorBuilder behavior; private java.lang.Integer maxReplicas; private java.util.ArrayList metrics; private java.lang.Integer minReplicas; private io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder scaleTargetRef; - + /** * This method has been deprecated, please use method buildBehavior instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior getBehavior() { - return this.behavior!=null ?this.behavior.build():null; + return this.behavior != null ? this.behavior.build() : null; } + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior buildBehavior() { - return this.behavior!=null ?this.behavior.build():null; + return this.behavior != null ? this.behavior.build() : null; } - public A withBehavior(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior behavior) { + + public A withBehavior( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior behavior) { _visitables.get("behavior").remove(this.behavior); - if (behavior!=null){ this.behavior= new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorBuilder(behavior); _visitables.get("behavior").add(this.behavior);} return (A) this; + if (behavior != null) { + this.behavior = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorBuilder( + behavior); + _visitables.get("behavior").add(this.behavior); + } + return (A) this; } + public java.lang.Boolean hasBehavior() { return this.behavior != null; } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested withNewBehavior() { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl.BehaviorNestedImpl(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested + withNewBehavior() { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl + .BehaviorNestedImpl(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested withNewBehaviorLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl.BehaviorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested + withNewBehaviorLike( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl + .BehaviorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested editBehavior() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested + editBehavior() { return withNewBehaviorLike(getBehavior()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested editOrNewBehavior() { - return withNewBehaviorLike(getBehavior() != null ? getBehavior(): new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorBuilder().build()); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested + editOrNewBehavior() { + return withNewBehaviorLike( + getBehavior() != null + ? getBehavior() + : new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested editOrNewBehaviorLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior item) { - return withNewBehaviorLike(getBehavior() != null ? getBehavior(): item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested + editOrNewBehaviorLike( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior item) { + return withNewBehaviorLike(getBehavior() != null ? getBehavior() : item); } + public java.lang.Integer getMaxReplicas() { return this.maxReplicas; } + public A withMaxReplicas(java.lang.Integer maxReplicas) { - this.maxReplicas=maxReplicas; return (A) this; + this.maxReplicas = maxReplicas; + return (A) this; } + public java.lang.Boolean hasMaxReplicas() { return this.maxReplicas != null; } - public A addToMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2MetricSpec item) { - if (this.metrics == null) {this.metrics = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(item);_visitables.get("metrics").add(index >= 0 ? index : _visitables.get("metrics").size(), builder);this.metrics.add(index >= 0 ? index : metrics.size(), builder); return (A)this; + + public A addToMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricSpec item) { + if (this.metrics == null) { + this.metrics = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(item); + _visitables.get("metrics").add(index >= 0 ? index : _visitables.get("metrics").size(), builder); + this.metrics.add(index >= 0 ? index : metrics.size(), builder); + return (A) this; } - public A setToMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2MetricSpec item) { - if (this.metrics == null) {this.metrics = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(item); - if (index < 0 || index >= _visitables.get("metrics").size()) { _visitables.get("metrics").add(builder); } else { _visitables.get("metrics").set(index, builder);} - if (index < 0 || index >= metrics.size()) { metrics.add(builder); } else { metrics.set(index, builder);} - return (A)this; + + public A setToMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricSpec item) { + if (this.metrics == null) { + this.metrics = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(item); + if (index < 0 || index >= _visitables.get("metrics").size()) { + _visitables.get("metrics").add(builder); + } else { + _visitables.get("metrics").set(index, builder); + } + if (index < 0 || index >= metrics.size()) { + metrics.add(builder); + } else { + metrics.set(index, builder); + } + return (A) this; } + public A addToMetrics(io.kubernetes.client.openapi.models.V2MetricSpec... items) { - if (this.metrics == null) {this.metrics = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2MetricSpec item : items) {io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(item);_visitables.get("metrics").add(builder);this.metrics.add(builder);} return (A)this; + if (this.metrics == null) { + this.metrics = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2MetricSpec item : items) { + io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(item); + _visitables.get("metrics").add(builder); + this.metrics.add(builder); + } + return (A) this; } - public A addAllToMetrics(java.util.Collection items) { - if (this.metrics == null) {this.metrics = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2MetricSpec item : items) {io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(item);_visitables.get("metrics").add(builder);this.metrics.add(builder);} return (A)this; + + public A addAllToMetrics( + java.util.Collection items) { + if (this.metrics == null) { + this.metrics = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2MetricSpec item : items) { + io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(item); + _visitables.get("metrics").add(builder); + this.metrics.add(builder); + } + return (A) this; } + public A removeFromMetrics(io.kubernetes.client.openapi.models.V2MetricSpec... items) { - for (io.kubernetes.client.openapi.models.V2MetricSpec item : items) {io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(item);_visitables.get("metrics").remove(builder);if (this.metrics != null) {this.metrics.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V2MetricSpec item : items) { + io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(item); + _visitables.get("metrics").remove(builder); + if (this.metrics != null) { + this.metrics.remove(builder); + } + } + return (A) this; } - public A removeAllFromMetrics(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2MetricSpec item : items) {io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(item);_visitables.get("metrics").remove(builder);if (this.metrics != null) {this.metrics.remove(builder);}} return (A)this; + + public A removeAllFromMetrics( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V2MetricSpec item : items) { + io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(item); + _visitables.get("metrics").remove(builder); + if (this.metrics != null) { + this.metrics.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromMetrics(java.util.function.Predicate predicate) { + + public A removeMatchingFromMetrics( + java.util.function.Predicate + predicate) { if (metrics == null) return (A) this; - final Iterator each = metrics.iterator(); + final Iterator each = + metrics.iterator(); final List visitables = _visitables.get("metrics"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder = each.next(); @@ -115,183 +219,337 @@ public A removeMatchingFromMetrics(java.util.function.Predicate getMetrics() { return metrics != null ? build(metrics) : null; } + public java.util.List buildMetrics() { return metrics != null ? build(metrics) : null; } + public io.kubernetes.client.openapi.models.V2MetricSpec buildMetric(java.lang.Integer index) { return this.metrics.get(index).build(); } + public io.kubernetes.client.openapi.models.V2MetricSpec buildFirstMetric() { return this.metrics.get(0).build(); } + public io.kubernetes.client.openapi.models.V2MetricSpec buildLastMetric() { return this.metrics.get(metrics.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2MetricSpec buildMatchingMetric(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2MetricSpecBuilder item: metrics) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2MetricSpec buildMatchingMetric( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2MetricSpecBuilder item : metrics) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingMetric(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2MetricSpecBuilder item: metrics) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMetric( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2MetricSpecBuilder item : metrics) { + if (predicate.test(item)) { + return true; + } + } + return false; } + public A withMetrics(java.util.List metrics) { - if (this.metrics != null) { _visitables.get("metrics").removeAll(this.metrics);} - if (metrics != null) {this.metrics = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2MetricSpec item : metrics){this.addToMetrics(item);}} else { this.metrics = null;} return (A) this; + if (this.metrics != null) { + _visitables.get("metrics").removeAll(this.metrics); + } + if (metrics != null) { + this.metrics = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2MetricSpec item : metrics) { + this.addToMetrics(item); + } + } else { + this.metrics = null; + } + return (A) this; } + public A withMetrics(io.kubernetes.client.openapi.models.V2MetricSpec... metrics) { - if (this.metrics != null) {this.metrics.clear();} - if (metrics != null) {for (io.kubernetes.client.openapi.models.V2MetricSpec item :metrics){ this.addToMetrics(item);}} return (A) this; + if (this.metrics != null) { + this.metrics.clear(); + } + if (metrics != null) { + for (io.kubernetes.client.openapi.models.V2MetricSpec item : metrics) { + this.addToMetrics(item); + } + } + return (A) this; } + public java.lang.Boolean hasMetrics() { return metrics != null && !metrics.isEmpty(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested addNewMetric() { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl.MetricsNestedImpl(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + addNewMetric() { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl + .MetricsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested addNewMetricLike(io.kubernetes.client.openapi.models.V2MetricSpec item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl.MetricsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + addNewMetricLike(io.kubernetes.client.openapi.models.V2MetricSpec item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl + .MetricsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested setNewMetricLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2MetricSpec item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl.MetricsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + setNewMetricLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricSpec item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl + .MetricsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested editMetric(java.lang.Integer index) { - if (metrics.size() <= index) throw new RuntimeException("Can't edit metrics. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + editMetric(java.lang.Integer index) { + if (metrics.size() <= index) + throw new RuntimeException("Can't edit metrics. Index exceeds size."); return setNewMetricLike(index, buildMetric(index)); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested editFirstMetric() { - if (metrics.size() == 0) throw new RuntimeException("Can't edit first metrics. The list is empty."); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + editFirstMetric() { + if (metrics.size() == 0) + throw new RuntimeException("Can't edit first metrics. The list is empty."); return setNewMetricLike(0, buildMetric(0)); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested editLastMetric() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + editLastMetric() { int index = metrics.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last metrics. The list is empty."); return setNewMetricLike(index, buildMetric(index)); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested editMatchingMetric(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested + editMatchingMetric( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewScaleTargetRef() { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl.ScaleTargetRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRef() { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl + .ScaleTargetRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested withNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl.ScaleTargetRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluentImpl + .ScaleTargetRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editScaleTargetRef() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editScaleTargetRef() { return withNewScaleTargetRefLike(getScaleTargetRef()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRef() { - return withNewScaleTargetRefLike(getScaleTargetRef() != null ? getScaleTargetRef(): new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRef() { + return withNewScaleTargetRefLike( + getScaleTargetRef() != null + ? getScaleTargetRef() + : new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { - return withNewScaleTargetRefLike(getScaleTargetRef() != null ? getScaleTargetRef(): item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { + return withNewScaleTargetRefLike(getScaleTargetRef() != null ? getScaleTargetRef() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2HorizontalPodAutoscalerSpecFluentImpl that = (V2HorizontalPodAutoscalerSpecFluentImpl) o; - if (behavior != null ? !behavior.equals(that.behavior) :that.behavior != null) return false; - if (maxReplicas != null ? !maxReplicas.equals(that.maxReplicas) :that.maxReplicas != null) return false; - if (metrics != null ? !metrics.equals(that.metrics) :that.metrics != null) return false; - if (minReplicas != null ? !minReplicas.equals(that.minReplicas) :that.minReplicas != null) return false; - if (scaleTargetRef != null ? !scaleTargetRef.equals(that.scaleTargetRef) :that.scaleTargetRef != null) return false; + if (behavior != null ? !behavior.equals(that.behavior) : that.behavior != null) return false; + if (maxReplicas != null ? !maxReplicas.equals(that.maxReplicas) : that.maxReplicas != null) + return false; + if (metrics != null ? !metrics.equals(that.metrics) : that.metrics != null) return false; + if (minReplicas != null ? !minReplicas.equals(that.minReplicas) : that.minReplicas != null) + return false; + if (scaleTargetRef != null + ? !scaleTargetRef.equals(that.scaleTargetRef) + : that.scaleTargetRef != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(behavior, maxReplicas, metrics, minReplicas, scaleTargetRef, super.hashCode()); + return java.util.Objects.hash( + behavior, maxReplicas, metrics, minReplicas, scaleTargetRef, super.hashCode()); } - public class BehaviorNestedImpl extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluentImpl> implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested,io.kubernetes.client.fluent.Nested{ + + public class BehaviorNestedImpl + extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.BehaviorNested> + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + N>, + io.kubernetes.client.fluent.Nested { BehaviorNestedImpl(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehavior item) { - this.builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorBuilder( + this, item); } + BehaviorNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorBuilder(this); } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerBehaviorBuilder builder; + public N and() { return (N) V2HorizontalPodAutoscalerSpecFluentImpl.this.withBehavior(builder.build()); } + public N endBehavior() { return and(); } - } - public class MetricsNestedImpl extends io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl> implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested,io.kubernetes.client.fluent.Nested{ - MetricsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2MetricSpec item) { + + public class MetricsNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.MetricsNested> + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .MetricsNested< + N>, + io.kubernetes.client.fluent.Nested { + MetricsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricSpec item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(this, item); } + MetricsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V2MetricSpecBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricSpecBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2HorizontalPodAutoscalerSpecFluentImpl.this.setToMetrics(index,builder.build()); + return (N) V2HorizontalPodAutoscalerSpecFluentImpl.this.setToMetrics(index, builder.build()); } + public N endMetric() { return and(); } - } - public class ScaleTargetRefNestedImpl extends io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested,io.kubernetes.client.fluent.Nested{ - ScaleTargetRefNestedImpl(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(this, item); + + public class ScaleTargetRefNestedImpl + extends io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + N>> + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + N>, + io.kubernetes.client.fluent.Nested { + ScaleTargetRefNestedImpl( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { + this.builder = + new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(this, item); } + ScaleTargetRefNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder builder; + public N and() { return (N) V2HorizontalPodAutoscalerSpecFluentImpl.this.withScaleTargetRef(builder.build()); } + public N endScaleTargetRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerStatusBuilder.java index 01745eeb35..3894d4c068 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2HorizontalPodAutoscalerStatusBuilder extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2HorizontalPodAutoscalerStatusBuilder + extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusBuilder> { public V2HorizontalPodAutoscalerStatusBuilder() { this(false); } + public V2HorizontalPodAutoscalerStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2HorizontalPodAutoscalerStatus(), validationEnabled); } - public V2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent fluent) { + + public V2HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent fluent) { this(fluent, false); } - public V2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2HorizontalPodAutoscalerStatus(), validationEnabled); } - public V2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent fluent,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus instance) { + + public V2HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent fluent, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus instance) { this(fluent, instance, false); } - public V2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent fluent,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent fluent, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditions(instance.getConditions()); fluent.withCurrentMetrics(instance.getCurrentMetrics()); @@ -33,13 +60,18 @@ public V2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.model fluent.withObservedGeneration(instance.getObservedGeneration()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus instance) { - this(instance,false); + + public V2HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus instance) { + this(instance, false); } - public V2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditions(instance.getConditions()); this.withCurrentMetrics(instance.getCurrentMetrics()); @@ -52,10 +84,12 @@ public V2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.model this.withObservedGeneration(instance.getObservedGeneration()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus build() { V2HorizontalPodAutoscalerStatus buildable = new V2HorizontalPodAutoscalerStatus(); buildable.setConditions(fluent.getConditions()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus build buildable.setObservedGeneration(fluent.getObservedGeneration()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2HorizontalPodAutoscalerStatusBuilder that = (V2HorizontalPodAutoscalerStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerStatusFluent.java index 6cf4d75c92..1a5917ab4c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerStatusFluent.java @@ -1,106 +1,256 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.lang.Long; -import java.util.Collection; - - /** - * Generated - */ -public interface V2HorizontalPodAutoscalerStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item); - public A addToConditions(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition... items); - public A addAllToConditions(java.util.Collection items); - public A removeFromConditions(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - +/** Generated */ +public interface V2HorizontalPodAutoscalerStatusFluent< + A extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item); + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item); + + public A addToConditions( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition... items); + + public A addAllToConditions( + java.util.Collection + items); + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition... items); + + public A removeAllFromConditions( + java.util.Collection + items); + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder> + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition buildCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition buildFirstCondition(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); - public A withConditions(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition... conditions); + public java.util.List + getConditions(); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition buildCondition( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition + buildFirstCondition(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition + buildLastCondition(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder> + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder> + predicate); + + public A withConditions( + java.util.List + conditions); + + public A withConditions( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - public A addToCurrentMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2MetricStatus item); - public A setToCurrentMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2MetricStatus item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + addNewCondition(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + editLastCondition(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder> + predicate); + + public A addToCurrentMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricStatus item); + + public A setToCurrentMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricStatus item); + public A addToCurrentMetrics(io.kubernetes.client.openapi.models.V2MetricStatus... items); - public A addAllToCurrentMetrics(java.util.Collection items); + + public A addAllToCurrentMetrics( + java.util.Collection items); + public A removeFromCurrentMetrics(io.kubernetes.client.openapi.models.V2MetricStatus... items); - public A removeAllFromCurrentMetrics(java.util.Collection items); - public A removeMatchingFromCurrentMetrics(java.util.function.Predicate predicate); - + + public A removeAllFromCurrentMetrics( + java.util.Collection items); + + public A removeMatchingFromCurrentMetrics( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildCurrentMetrics instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getCurrentMetrics(); + public java.util.List buildCurrentMetrics(); - public io.kubernetes.client.openapi.models.V2MetricStatus buildCurrentMetric(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2MetricStatus buildCurrentMetric( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V2MetricStatus buildFirstCurrentMetric(); + public io.kubernetes.client.openapi.models.V2MetricStatus buildLastCurrentMetric(); - public io.kubernetes.client.openapi.models.V2MetricStatus buildMatchingCurrentMetric(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCurrentMetric(java.util.function.Predicate predicate); - public A withCurrentMetrics(java.util.List currentMetrics); + + public io.kubernetes.client.openapi.models.V2MetricStatus buildMatchingCurrentMetric( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCurrentMetric( + java.util.function.Predicate + predicate); + + public A withCurrentMetrics( + java.util.List currentMetrics); + public A withCurrentMetrics(io.kubernetes.client.openapi.models.V2MetricStatus... currentMetrics); + public java.lang.Boolean hasCurrentMetrics(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested addNewCurrentMetric(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested addNewCurrentMetricLike(io.kubernetes.client.openapi.models.V2MetricStatus item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested setNewCurrentMetricLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2MetricStatus item); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editCurrentMetric(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editFirstCurrentMetric(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editLastCurrentMetric(); - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editMatchingCurrentMetric(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + addNewCurrentMetric(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + addNewCurrentMetricLike(io.kubernetes.client.openapi.models.V2MetricStatus item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + setNewCurrentMetricLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricStatus item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editCurrentMetric(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editFirstCurrentMetric(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editLastCurrentMetric(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editMatchingCurrentMetric( + java.util.function.Predicate + predicate); + public java.lang.Integer getCurrentReplicas(); + public A withCurrentReplicas(java.lang.Integer currentReplicas); + public java.lang.Boolean hasCurrentReplicas(); + public java.lang.Integer getDesiredReplicas(); + public A withDesiredReplicas(java.lang.Integer desiredReplicas); + public java.lang.Boolean hasDesiredReplicas(); + public java.time.OffsetDateTime getLastScaleTime(); + public A withLastScaleTime(java.time.OffsetDateTime lastScaleTime); + public java.lang.Boolean hasLastScaleTime(); + public java.lang.Long getObservedGeneration(); + public A withObservedGeneration(java.lang.Long observedGeneration); + public java.lang.Boolean hasObservedGeneration(); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluent< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - public interface CurrentMetricsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricStatusFluent>{ + + public interface CurrentMetricsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricStatusFluent< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + N>> { public N and(); + public N endCurrentMetric(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerStatusFluentImpl.java index cfd6a6af3d..1b8d34477a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2HorizontalPodAutoscalerStatusFluentImpl.java @@ -1,27 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.lang.Long; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V2HorizontalPodAutoscalerStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent{ - public V2HorizontalPodAutoscalerStatusFluentImpl() { - } - public V2HorizontalPodAutoscalerStatusFluentImpl(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus instance) { + +/** Generated */ +public class V2HorizontalPodAutoscalerStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent { + public V2HorizontalPodAutoscalerStatusFluentImpl() {} + + public V2HorizontalPodAutoscalerStatusFluentImpl( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatus instance) { this.withConditions(instance.getConditions()); this.withCurrentMetrics(instance.getCurrentMetrics()); @@ -33,148 +35,392 @@ public V2HorizontalPodAutoscalerStatusFluentImpl(io.kubernetes.client.openapi.mo this.withLastScaleTime(instance.getLastScaleTime()); this.withObservedGeneration(instance.getObservedGeneration()); - } - private java.util.ArrayList conditions; - private java.util.ArrayList currentMetrics; + + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder> + conditions; + private java.util.ArrayList + currentMetrics; private java.lang.Integer currentReplicas; private java.lang.Integer desiredReplicas; private java.time.OffsetDateTime lastScaleTime; private java.lang.Long observedGeneration; - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } - public A addToConditions(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item : items) {io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addToConditions( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition... items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item : items) { + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item : items) {io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection + items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item : items) { + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition... items) { - for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item : items) {io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition... items) { + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item : items) { + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item : items) {io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item : items) { + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder> + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator + each = conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions() { + public java.util.List + getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition buildFirstCondition() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition + buildFirstCondition() { return this.conditions.get(0).build(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition buildLastCondition() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition + buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List + conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item : + conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } - public A withConditions(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item :conditions){ this.addToConditions(item);}} return (A) this; + + public A withConditions( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition... conditions) { + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item : + conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + addNewCondition() { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(item);_visitables.get("currentMetrics").add(index >= 0 ? index : _visitables.get("currentMetrics").size(), builder);this.currentMetrics.add(index >= 0 ? index : currentMetrics.size(), builder); return (A)this; + + public A addToCurrentMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricStatus item) { + if (this.currentMetrics == null) { + this.currentMetrics = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(item); + _visitables + .get("currentMetrics") + .add(index >= 0 ? index : _visitables.get("currentMetrics").size(), builder); + this.currentMetrics.add(index >= 0 ? index : currentMetrics.size(), builder); + return (A) this; } - public A setToCurrentMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2MetricStatus item) { - if (this.currentMetrics == null) {this.currentMetrics = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(item); - if (index < 0 || index >= _visitables.get("currentMetrics").size()) { _visitables.get("currentMetrics").add(builder); } else { _visitables.get("currentMetrics").set(index, builder);} - if (index < 0 || index >= currentMetrics.size()) { currentMetrics.add(builder); } else { currentMetrics.set(index, builder);} - return (A)this; + + public A setToCurrentMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricStatus item) { + if (this.currentMetrics == null) { + this.currentMetrics = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(item); + if (index < 0 || index >= _visitables.get("currentMetrics").size()) { + _visitables.get("currentMetrics").add(builder); + } else { + _visitables.get("currentMetrics").set(index, builder); + } + if (index < 0 || index >= currentMetrics.size()) { + currentMetrics.add(builder); + } else { + currentMetrics.set(index, builder); + } + return (A) this; } + public A addToCurrentMetrics(io.kubernetes.client.openapi.models.V2MetricStatus... items) { - if (this.currentMetrics == null) {this.currentMetrics = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2MetricStatus item : items) {io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(item);_visitables.get("currentMetrics").add(builder);this.currentMetrics.add(builder);} return (A)this; + if (this.currentMetrics == null) { + this.currentMetrics = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2MetricStatus item : items) { + io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(item); + _visitables.get("currentMetrics").add(builder); + this.currentMetrics.add(builder); + } + return (A) this; } - public A addAllToCurrentMetrics(java.util.Collection items) { - if (this.currentMetrics == null) {this.currentMetrics = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2MetricStatus item : items) {io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(item);_visitables.get("currentMetrics").add(builder);this.currentMetrics.add(builder);} return (A)this; + + public A addAllToCurrentMetrics( + java.util.Collection items) { + if (this.currentMetrics == null) { + this.currentMetrics = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2MetricStatus item : items) { + io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(item); + _visitables.get("currentMetrics").add(builder); + this.currentMetrics.add(builder); + } + return (A) this; } + public A removeFromCurrentMetrics(io.kubernetes.client.openapi.models.V2MetricStatus... items) { - for (io.kubernetes.client.openapi.models.V2MetricStatus item : items) {io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(item);_visitables.get("currentMetrics").remove(builder);if (this.currentMetrics != null) {this.currentMetrics.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V2MetricStatus item : items) { + io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(item); + _visitables.get("currentMetrics").remove(builder); + if (this.currentMetrics != null) { + this.currentMetrics.remove(builder); + } + } + return (A) this; } - public A removeAllFromCurrentMetrics(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2MetricStatus item : items) {io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(item);_visitables.get("currentMetrics").remove(builder);if (this.currentMetrics != null) {this.currentMetrics.remove(builder);}} return (A)this; + + public A removeAllFromCurrentMetrics( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V2MetricStatus item : items) { + io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(item); + _visitables.get("currentMetrics").remove(builder); + if (this.currentMetrics != null) { + this.currentMetrics.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromCurrentMetrics(java.util.function.Predicate predicate) { + + public A removeMatchingFromCurrentMetrics( + java.util.function.Predicate + predicate) { if (currentMetrics == null) return (A) this; - final Iterator each = currentMetrics.iterator(); + final Iterator each = + currentMetrics.iterator(); final List visitables = _visitables.get("currentMetrics"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder = each.next(); @@ -183,164 +429,316 @@ public A removeMatchingFromCurrentMetrics(java.util.function.Predicate getCurrentMetrics() { return currentMetrics != null ? build(currentMetrics) : null; } + public java.util.List buildCurrentMetrics() { return currentMetrics != null ? build(currentMetrics) : null; } - public io.kubernetes.client.openapi.models.V2MetricStatus buildCurrentMetric(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2MetricStatus buildCurrentMetric( + java.lang.Integer index) { return this.currentMetrics.get(index).build(); } + public io.kubernetes.client.openapi.models.V2MetricStatus buildFirstCurrentMetric() { return this.currentMetrics.get(0).build(); } + public io.kubernetes.client.openapi.models.V2MetricStatus buildLastCurrentMetric() { return this.currentMetrics.get(currentMetrics.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2MetricStatus buildMatchingCurrentMetric(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2MetricStatusBuilder item: currentMetrics) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2MetricStatus buildMatchingCurrentMetric( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2MetricStatusBuilder item : currentMetrics) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCurrentMetric(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2MetricStatusBuilder item: currentMetrics) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCurrentMetric( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2MetricStatusBuilder item : currentMetrics) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withCurrentMetrics(java.util.List currentMetrics) { - if (this.currentMetrics != null) { _visitables.get("currentMetrics").removeAll(this.currentMetrics);} - if (currentMetrics != null) {this.currentMetrics = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2MetricStatus item : currentMetrics){this.addToCurrentMetrics(item);}} else { this.currentMetrics = null;} return (A) this; + + public A withCurrentMetrics( + java.util.List currentMetrics) { + if (this.currentMetrics != null) { + _visitables.get("currentMetrics").removeAll(this.currentMetrics); + } + if (currentMetrics != null) { + this.currentMetrics = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2MetricStatus item : currentMetrics) { + this.addToCurrentMetrics(item); + } + } else { + this.currentMetrics = null; + } + return (A) this; } - public A withCurrentMetrics(io.kubernetes.client.openapi.models.V2MetricStatus... currentMetrics) { - if (this.currentMetrics != null) {this.currentMetrics.clear();} - if (currentMetrics != null) {for (io.kubernetes.client.openapi.models.V2MetricStatus item :currentMetrics){ this.addToCurrentMetrics(item);}} return (A) this; + + public A withCurrentMetrics( + io.kubernetes.client.openapi.models.V2MetricStatus... currentMetrics) { + if (this.currentMetrics != null) { + this.currentMetrics.clear(); + } + if (currentMetrics != null) { + for (io.kubernetes.client.openapi.models.V2MetricStatus item : currentMetrics) { + this.addToCurrentMetrics(item); + } + } + return (A) this; } + public java.lang.Boolean hasCurrentMetrics() { return currentMetrics != null && !currentMetrics.isEmpty(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested addNewCurrentMetric() { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl.CurrentMetricsNestedImpl(); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + addNewCurrentMetric() { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl + .CurrentMetricsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested addNewCurrentMetricLike(io.kubernetes.client.openapi.models.V2MetricStatus item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl.CurrentMetricsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + addNewCurrentMetricLike(io.kubernetes.client.openapi.models.V2MetricStatus item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl + .CurrentMetricsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested setNewCurrentMetricLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2MetricStatus item) { - return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl.CurrentMetricsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + setNewCurrentMetricLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricStatus item) { + return new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluentImpl + .CurrentMetricsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editCurrentMetric(java.lang.Integer index) { - if (currentMetrics.size() <= index) throw new RuntimeException("Can't edit currentMetrics. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editCurrentMetric(java.lang.Integer index) { + if (currentMetrics.size() <= index) + throw new RuntimeException("Can't edit currentMetrics. Index exceeds size."); return setNewCurrentMetricLike(index, buildCurrentMetric(index)); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editFirstCurrentMetric() { - if (currentMetrics.size() == 0) throw new RuntimeException("Can't edit first currentMetrics. The list is empty."); + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editFirstCurrentMetric() { + if (currentMetrics.size() == 0) + throw new RuntimeException("Can't edit first currentMetrics. The list is empty."); return setNewCurrentMetricLike(0, buildCurrentMetric(0)); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editLastCurrentMetric() { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editLastCurrentMetric() { int index = currentMetrics.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last currentMetrics. The list is empty."); return setNewCurrentMetricLike(index, buildCurrentMetric(index)); } - public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editMatchingCurrentMetric(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editMatchingCurrentMetric( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluentImpl> implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + N>> + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder( + this, item); } + ConditionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder(this); } + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2HorizontalPodAutoscalerStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) + V2HorizontalPodAutoscalerStatusFluentImpl.this.setToConditions(index, builder.build()); } + public N endCondition() { return and(); } - } - public class CurrentMetricsNestedImpl extends io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested,io.kubernetes.client.fluent.Nested{ - CurrentMetricsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2MetricStatus item) { + + public class CurrentMetricsNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + N>> + implements io.kubernetes.client.openapi.models.V2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + N>, + io.kubernetes.client.fluent.Nested { + CurrentMetricsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2MetricStatus item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(this, item); } + CurrentMetricsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V2MetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricStatusBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2HorizontalPodAutoscalerStatusFluentImpl.this.setToCurrentMetrics(index,builder.build()); + return (N) + V2HorizontalPodAutoscalerStatusFluentImpl.this.setToCurrentMetrics( + index, builder.build()); } + public N endCurrentMetric() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricIdentifierBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricIdentifierBuilder.java index 4f7e1dba99..f676369aba 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricIdentifierBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricIdentifierBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2MetricIdentifierBuilder extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2MetricIdentifierBuilder + extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2MetricIdentifier, + io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder> { public V2MetricIdentifierBuilder() { this(false); } + public V2MetricIdentifierBuilder(java.lang.Boolean validationEnabled) { this(new V2MetricIdentifier(), validationEnabled); } - public V2MetricIdentifierBuilder(io.kubernetes.client.openapi.models.V2MetricIdentifierFluent fluent) { + + public V2MetricIdentifierBuilder( + io.kubernetes.client.openapi.models.V2MetricIdentifierFluent fluent) { this(fluent, false); } - public V2MetricIdentifierBuilder(io.kubernetes.client.openapi.models.V2MetricIdentifierFluent fluent,java.lang.Boolean validationEnabled) { + + public V2MetricIdentifierBuilder( + io.kubernetes.client.openapi.models.V2MetricIdentifierFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2MetricIdentifier(), validationEnabled); } - public V2MetricIdentifierBuilder(io.kubernetes.client.openapi.models.V2MetricIdentifierFluent fluent,io.kubernetes.client.openapi.models.V2MetricIdentifier instance) { + + public V2MetricIdentifierBuilder( + io.kubernetes.client.openapi.models.V2MetricIdentifierFluent fluent, + io.kubernetes.client.openapi.models.V2MetricIdentifier instance) { this(fluent, instance, false); } - public V2MetricIdentifierBuilder(io.kubernetes.client.openapi.models.V2MetricIdentifierFluent fluent,io.kubernetes.client.openapi.models.V2MetricIdentifier instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2MetricIdentifierBuilder( + io.kubernetes.client.openapi.models.V2MetricIdentifierFluent fluent, + io.kubernetes.client.openapi.models.V2MetricIdentifier instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withSelector(instance.getSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2MetricIdentifierBuilder(io.kubernetes.client.openapi.models.V2MetricIdentifier instance) { - this(instance,false); + + public V2MetricIdentifierBuilder( + io.kubernetes.client.openapi.models.V2MetricIdentifier instance) { + this(instance, false); } - public V2MetricIdentifierBuilder(io.kubernetes.client.openapi.models.V2MetricIdentifier instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2MetricIdentifierBuilder( + io.kubernetes.client.openapi.models.V2MetricIdentifier instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withSelector(instance.getSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2MetricIdentifierFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2MetricIdentifier build() { V2MetricIdentifier buildable = new V2MetricIdentifier(); buildable.setName(fluent.getName()); buildable.setSelector(fluent.getSelector()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2MetricIdentifierBuilder that = (V2MetricIdentifierBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricIdentifierFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricIdentifierFluent.java index c77fe4fb78..293d2440df 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricIdentifierFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricIdentifierFluent.java @@ -1,44 +1,66 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2MetricIdentifierFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2MetricIdentifierFluent< + A extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); - public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested editSelector(); - public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested + withNewSelector(); + + public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested + editSelector(); + + public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested + editOrNewSelector(); + + public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested> { public N and(); + public N endSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricIdentifierFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricIdentifierFluentImpl.java index 108c694b98..8a2a46b497 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricIdentifierFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricIdentifierFluentImpl.java @@ -1,103 +1,144 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2MetricIdentifierFluentImpl< + A extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2MetricIdentifierFluent { + public V2MetricIdentifierFluentImpl() {} - /** - * Generated - */ -public class V2MetricIdentifierFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2MetricIdentifierFluent{ - public V2MetricIdentifierFluentImpl() { - } - public V2MetricIdentifierFluentImpl(io.kubernetes.client.openapi.models.V2MetricIdentifier instance) { + public V2MetricIdentifierFluentImpl( + io.kubernetes.client.openapi.models.V2MetricIdentifier instance) { this.withName(instance.getName()); this.withSelector(instance.getSelector()); - } + private java.lang.String name; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder selector; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested withNewSelector() { - return new io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl.SelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested + withNewSelector() { + return new io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl + .SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl.SelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl.SelectorNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested editSelector() { + + public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested + editSelector() { return withNewSelectorLike(getSelector()); } - public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested + editOrNewSelector() { + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2MetricIdentifierFluentImpl that = (V2MetricIdentifierFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, selector, super.hashCode()); + return java.util.Objects.hash(name, selector, super.hashCode()); } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested> + implements io.kubernetes.client.openapi.models.V2MetricIdentifierFluent.SelectorNested, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V2MetricIdentifierFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricSpecBuilder.java index 35df399a55..befdde1514 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricSpecBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2MetricSpecBuilder extends io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2MetricSpecBuilder + extends io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl< + io.kubernetes.client.openapi.models.V2MetricSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2MetricSpec, + io.kubernetes.client.openapi.models.V2MetricSpecBuilder> { public V2MetricSpecBuilder() { this(false); } + public V2MetricSpecBuilder(java.lang.Boolean validationEnabled) { this(new V2MetricSpec(), validationEnabled); } + public V2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2MetricSpecFluent fluent) { this(fluent, false); } - public V2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2MetricSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V2MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2MetricSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2MetricSpec(), validationEnabled); } - public V2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2MetricSpecFluent fluent,io.kubernetes.client.openapi.models.V2MetricSpec instance) { + + public V2MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2MetricSpecFluent fluent, + io.kubernetes.client.openapi.models.V2MetricSpec instance) { this(fluent, instance, false); } - public V2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2MetricSpecFluent fluent,io.kubernetes.client.openapi.models.V2MetricSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2MetricSpecFluent fluent, + io.kubernetes.client.openapi.models.V2MetricSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainerResource(instance.getContainerResource()); fluent.withExternal(instance.getExternal()); @@ -33,13 +59,17 @@ public V2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2MetricSpecFluen fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2MetricSpec instance) { - this(instance,false); + this(instance, false); } - public V2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2MetricSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2MetricSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainerResource(instance.getContainerResource()); this.withExternal(instance.getExternal()); @@ -52,10 +82,12 @@ public V2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2MetricSpec inst this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2MetricSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2MetricSpec build() { V2MetricSpec buildable = new V2MetricSpec(); buildable.setContainerResource(fluent.getContainerResource()); @@ -66,18 +98,23 @@ public io.kubernetes.client.openapi.models.V2MetricSpec build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2MetricSpecBuilder that = (V2MetricSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricSpecFluent.java index 654ca56263..1aba433a2e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricSpecFluent.java @@ -1,124 +1,213 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; - - /** - * Generated - */ -public interface V2MetricSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2MetricSpecFluent< + A extends io.kubernetes.client.openapi.models.V2MetricSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildContainerResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource getContainerResource(); - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource buildContainerResource(); - public A withContainerResource(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource containerResource); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource + buildContainerResource(); + + public A withContainerResource( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource containerResource); + public java.lang.Boolean hasContainerResource(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested withNewContainerResource(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested withNewContainerResourceLike(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource item); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested editContainerResource(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested editOrNewContainerResource(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested editOrNewContainerResourceLike(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource item); - + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested + withNewContainerResource(); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested + withNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource item); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested + editContainerResource(); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested + editOrNewContainerResource(); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested + editOrNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource item); + /** * This method has been deprecated, please use method buildExternal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ExternalMetricSource getExternal(); + public io.kubernetes.client.openapi.models.V2ExternalMetricSource buildExternal(); + public A withExternal(io.kubernetes.client.openapi.models.V2ExternalMetricSource external); + public java.lang.Boolean hasExternal(); + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested withNewExternal(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested withNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricSource item); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested + withNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricSource item); + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested editExternal(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested editOrNewExternal(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested editOrNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricSource item); - + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested + editOrNewExternal(); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested + editOrNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricSource item); + /** * This method has been deprecated, please use method buildObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ObjectMetricSource getObject(); + public io.kubernetes.client.openapi.models.V2ObjectMetricSource buildObject(); + public A withObject(io.kubernetes.client.openapi.models.V2ObjectMetricSource _object); + public java.lang.Boolean hasObject(); + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested withNewObject(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested withNewObjectLike(io.kubernetes.client.openapi.models.V2ObjectMetricSource item); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested withNewObjectLike( + io.kubernetes.client.openapi.models.V2ObjectMetricSource item); + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested editObject(); + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested editOrNewObject(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested editOrNewObjectLike(io.kubernetes.client.openapi.models.V2ObjectMetricSource item); - + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested editOrNewObjectLike( + io.kubernetes.client.openapi.models.V2ObjectMetricSource item); + /** * This method has been deprecated, please use method buildPods instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2PodsMetricSource getPods(); + public io.kubernetes.client.openapi.models.V2PodsMetricSource buildPods(); + public A withPods(io.kubernetes.client.openapi.models.V2PodsMetricSource pods); + public java.lang.Boolean hasPods(); + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested withNewPods(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested withNewPodsLike(io.kubernetes.client.openapi.models.V2PodsMetricSource item); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested withNewPodsLike( + io.kubernetes.client.openapi.models.V2PodsMetricSource item); + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested editPods(); + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested editOrNewPods(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested editOrNewPodsLike(io.kubernetes.client.openapi.models.V2PodsMetricSource item); - + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested editOrNewPodsLike( + io.kubernetes.client.openapi.models.V2PodsMetricSource item); + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ResourceMetricSource getResource(); + public io.kubernetes.client.openapi.models.V2ResourceMetricSource buildResource(); + public A withResource(io.kubernetes.client.openapi.models.V2ResourceMetricSource resource); + public java.lang.Boolean hasResource(); + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested withNewResource(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricSource item); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricSource item); + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested editResource(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested editOrNewResource(); - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricSource item); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested + editOrNewResource(); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricSource item); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface ContainerResourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent>{ + + public interface ContainerResourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluent< + io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested> { public N and(); + public N endContainerResource(); - } - public interface ExternalNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent>{ + + public interface ExternalNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluent< + io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested> { public N and(); + public N endExternal(); - } - public interface ObjectNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent>{ + + public interface ObjectNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent< + io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested> { public N and(); + public N endObject(); - } - public interface PodsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent>{ + + public interface PodsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent< + io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested> { public N and(); + public N endPods(); - } - public interface ResourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent>{ + + public interface ResourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent< + io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested> { public N and(); + public N endResource(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricSpecFluentImpl.java index 2b5538bb0d..f7d6209eef 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricSpecFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Object; +/** Generated */ +public class V2MetricSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V2MetricSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2MetricSpecFluent { + public V2MetricSpecFluentImpl() {} - /** - * Generated - */ -public class V2MetricSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2MetricSpecFluent{ - public V2MetricSpecFluentImpl() { - } public V2MetricSpecFluentImpl(io.kubernetes.client.openapi.models.V2MetricSpec instance) { this.withContainerResource(instance.getContainerResource()); @@ -25,295 +31,459 @@ public V2MetricSpecFluentImpl(io.kubernetes.client.openapi.models.V2MetricSpec i this.withResource(instance.getResource()); this.withType(instance.getType()); - } - private io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceBuilder containerResource; + + private io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceBuilder + containerResource; private io.kubernetes.client.openapi.models.V2ExternalMetricSourceBuilder external; private io.kubernetes.client.openapi.models.V2ObjectMetricSourceBuilder _object; private io.kubernetes.client.openapi.models.V2PodsMetricSourceBuilder pods; private io.kubernetes.client.openapi.models.V2ResourceMetricSourceBuilder resource; private java.lang.String type; - + /** * This method has been deprecated, please use method buildContainerResource instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource getContainerResource() { - return this.containerResource!=null ?this.containerResource.build():null; + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource + getContainerResource() { + return this.containerResource != null ? this.containerResource.build() : null; } - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource buildContainerResource() { - return this.containerResource!=null ?this.containerResource.build():null; + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource + buildContainerResource() { + return this.containerResource != null ? this.containerResource.build() : null; } - public A withContainerResource(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource containerResource) { + + public A withContainerResource( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource containerResource) { _visitables.get("containerResource").remove(this.containerResource); - if (containerResource!=null){ this.containerResource= new io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceBuilder(containerResource); _visitables.get("containerResource").add(this.containerResource);} return (A) this; + if (containerResource != null) { + this.containerResource = + new io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceBuilder( + containerResource); + _visitables.get("containerResource").add(this.containerResource); + } + return (A) this; } + public java.lang.Boolean hasContainerResource() { return this.containerResource != null; } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested withNewContainerResource() { - return new io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl.ContainerResourceNestedImpl(); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested + withNewContainerResource() { + return new io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl + .ContainerResourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested withNewContainerResourceLike(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource item) { - return new io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl.ContainerResourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested + withNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource item) { + return new io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl + .ContainerResourceNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested editContainerResource() { + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested + editContainerResource() { return withNewContainerResourceLike(getContainerResource()); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested editOrNewContainerResource() { - return withNewContainerResourceLike(getContainerResource() != null ? getContainerResource(): new io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested + editOrNewContainerResource() { + return withNewContainerResourceLike( + getContainerResource() != null + ? getContainerResource() + : new io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested editOrNewContainerResourceLike(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource item) { - return withNewContainerResourceLike(getContainerResource() != null ? getContainerResource(): item); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested + editOrNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource item) { + return withNewContainerResourceLike( + getContainerResource() != null ? getContainerResource() : item); } - + /** * This method has been deprecated, please use method buildExternal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ExternalMetricSource getExternal() { - return this.external!=null ?this.external.build():null; + return this.external != null ? this.external.build() : null; } + public io.kubernetes.client.openapi.models.V2ExternalMetricSource buildExternal() { - return this.external!=null ?this.external.build():null; + return this.external != null ? this.external.build() : null; } + public A withExternal(io.kubernetes.client.openapi.models.V2ExternalMetricSource external) { _visitables.get("external").remove(this.external); - if (external!=null){ this.external= new io.kubernetes.client.openapi.models.V2ExternalMetricSourceBuilder(external); _visitables.get("external").add(this.external);} return (A) this; + if (external != null) { + this.external = + new io.kubernetes.client.openapi.models.V2ExternalMetricSourceBuilder(external); + _visitables.get("external").add(this.external); + } + return (A) this; } + public java.lang.Boolean hasExternal() { return this.external != null; } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested withNewExternal() { + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested + withNewExternal() { return new io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl.ExternalNestedImpl(); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested withNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricSource item) { + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested + withNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricSource item) { return new io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl.ExternalNestedImpl(item); } + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested editExternal() { return withNewExternalLike(getExternal()); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested editOrNewExternal() { - return withNewExternalLike(getExternal() != null ? getExternal(): new io.kubernetes.client.openapi.models.V2ExternalMetricSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested + editOrNewExternal() { + return withNewExternalLike( + getExternal() != null + ? getExternal() + : new io.kubernetes.client.openapi.models.V2ExternalMetricSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested editOrNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricSource item) { - return withNewExternalLike(getExternal() != null ? getExternal(): item); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested + editOrNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricSource item) { + return withNewExternalLike(getExternal() != null ? getExternal() : item); } - + /** * This method has been deprecated, please use method buildObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ObjectMetricSource getObject() { - return this._object!=null ?this._object.build():null; + return this._object != null ? this._object.build() : null; } + public io.kubernetes.client.openapi.models.V2ObjectMetricSource buildObject() { - return this._object!=null ?this._object.build():null; + return this._object != null ? this._object.build() : null; } + public A withObject(io.kubernetes.client.openapi.models.V2ObjectMetricSource _object) { _visitables.get("_object").remove(this._object); - if (_object!=null){ this._object= new io.kubernetes.client.openapi.models.V2ObjectMetricSourceBuilder(_object); _visitables.get("_object").add(this._object);} return (A) this; + if (_object != null) { + this._object = new io.kubernetes.client.openapi.models.V2ObjectMetricSourceBuilder(_object); + _visitables.get("_object").add(this._object); + } + return (A) this; } + public java.lang.Boolean hasObject() { return this._object != null; } + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested withNewObject() { return new io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl.ObjectNestedImpl(); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested withNewObjectLike(io.kubernetes.client.openapi.models.V2ObjectMetricSource item) { + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested withNewObjectLike( + io.kubernetes.client.openapi.models.V2ObjectMetricSource item) { return new io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl.ObjectNestedImpl(item); } + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested editObject() { return withNewObjectLike(getObject()); } + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested editOrNewObject() { - return withNewObjectLike(getObject() != null ? getObject(): new io.kubernetes.client.openapi.models.V2ObjectMetricSourceBuilder().build()); + return withNewObjectLike( + getObject() != null + ? getObject() + : new io.kubernetes.client.openapi.models.V2ObjectMetricSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested editOrNewObjectLike(io.kubernetes.client.openapi.models.V2ObjectMetricSource item) { - return withNewObjectLike(getObject() != null ? getObject(): item); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested editOrNewObjectLike( + io.kubernetes.client.openapi.models.V2ObjectMetricSource item) { + return withNewObjectLike(getObject() != null ? getObject() : item); } - + /** * This method has been deprecated, please use method buildPods instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2PodsMetricSource getPods() { - return this.pods!=null ?this.pods.build():null; + return this.pods != null ? this.pods.build() : null; } + public io.kubernetes.client.openapi.models.V2PodsMetricSource buildPods() { - return this.pods!=null ?this.pods.build():null; + return this.pods != null ? this.pods.build() : null; } + public A withPods(io.kubernetes.client.openapi.models.V2PodsMetricSource pods) { _visitables.get("pods").remove(this.pods); - if (pods!=null){ this.pods= new io.kubernetes.client.openapi.models.V2PodsMetricSourceBuilder(pods); _visitables.get("pods").add(this.pods);} return (A) this; + if (pods != null) { + this.pods = new io.kubernetes.client.openapi.models.V2PodsMetricSourceBuilder(pods); + _visitables.get("pods").add(this.pods); + } + return (A) this; } + public java.lang.Boolean hasPods() { return this.pods != null; } + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested withNewPods() { return new io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl.PodsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested withNewPodsLike(io.kubernetes.client.openapi.models.V2PodsMetricSource item) { + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested withNewPodsLike( + io.kubernetes.client.openapi.models.V2PodsMetricSource item) { return new io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl.PodsNestedImpl(item); } + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested editPods() { return withNewPodsLike(getPods()); } + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested editOrNewPods() { - return withNewPodsLike(getPods() != null ? getPods(): new io.kubernetes.client.openapi.models.V2PodsMetricSourceBuilder().build()); + return withNewPodsLike( + getPods() != null + ? getPods() + : new io.kubernetes.client.openapi.models.V2PodsMetricSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested editOrNewPodsLike(io.kubernetes.client.openapi.models.V2PodsMetricSource item) { - return withNewPodsLike(getPods() != null ? getPods(): item); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested editOrNewPodsLike( + io.kubernetes.client.openapi.models.V2PodsMetricSource item) { + return withNewPodsLike(getPods() != null ? getPods() : item); } - + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ResourceMetricSource getResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public io.kubernetes.client.openapi.models.V2ResourceMetricSource buildResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public A withResource(io.kubernetes.client.openapi.models.V2ResourceMetricSource resource) { _visitables.get("resource").remove(this.resource); - if (resource!=null){ this.resource= new io.kubernetes.client.openapi.models.V2ResourceMetricSourceBuilder(resource); _visitables.get("resource").add(this.resource);} return (A) this; + if (resource != null) { + this.resource = + new io.kubernetes.client.openapi.models.V2ResourceMetricSourceBuilder(resource); + _visitables.get("resource").add(this.resource); + } + return (A) this; } + public java.lang.Boolean hasResource() { return this.resource != null; } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested withNewResource() { + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested + withNewResource() { return new io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl.ResourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricSource item) { + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricSource item) { return new io.kubernetes.client.openapi.models.V2MetricSpecFluentImpl.ResourceNestedImpl(item); } + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested editResource() { return withNewResourceLike(getResource()); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested editOrNewResource() { - return withNewResourceLike(getResource() != null ? getResource(): new io.kubernetes.client.openapi.models.V2ResourceMetricSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested + editOrNewResource() { + return withNewResourceLike( + getResource() != null + ? getResource() + : new io.kubernetes.client.openapi.models.V2ResourceMetricSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricSource item) { - return withNewResourceLike(getResource() != null ? getResource(): item); + + public io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricSource item) { + return withNewResourceLike(getResource() != null ? getResource() : item); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2MetricSpecFluentImpl that = (V2MetricSpecFluentImpl) o; - if (containerResource != null ? !containerResource.equals(that.containerResource) :that.containerResource != null) return false; - if (external != null ? !external.equals(that.external) :that.external != null) return false; - if (_object != null ? !_object.equals(that._object) :that._object != null) return false; - if (pods != null ? !pods.equals(that.pods) :that.pods != null) return false; - if (resource != null ? !resource.equals(that.resource) :that.resource != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (containerResource != null + ? !containerResource.equals(that.containerResource) + : that.containerResource != null) return false; + if (external != null ? !external.equals(that.external) : that.external != null) return false; + if (_object != null ? !_object.equals(that._object) : that._object != null) return false; + if (pods != null ? !pods.equals(that.pods) : that.pods != null) return false; + if (resource != null ? !resource.equals(that.resource) : that.resource != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(containerResource, external, _object, pods, resource, type, super.hashCode()); + return java.util.Objects.hash( + containerResource, external, _object, pods, resource, type, super.hashCode()); } - public class ContainerResourceNestedImpl extends io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested,io.kubernetes.client.fluent.Nested{ - ContainerResourceNestedImpl(io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceBuilder(this, item); + + public class ContainerResourceNestedImpl + extends io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested> + implements io.kubernetes.client.openapi.models.V2MetricSpecFluent.ContainerResourceNested, + io.kubernetes.client.fluent.Nested { + ContainerResourceNestedImpl( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceBuilder( + this, item); } + ContainerResourceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2ContainerResourceMetricSourceBuilder builder; + public N and() { return (N) V2MetricSpecFluentImpl.this.withContainerResource(builder.build()); } + public N endContainerResource() { return and(); } - } - public class ExternalNestedImpl extends io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested,io.kubernetes.client.fluent.Nested{ + + public class ExternalNestedImpl + extends io.kubernetes.client.openapi.models.V2ExternalMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested> + implements io.kubernetes.client.openapi.models.V2MetricSpecFluent.ExternalNested, + io.kubernetes.client.fluent.Nested { ExternalNestedImpl(io.kubernetes.client.openapi.models.V2ExternalMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2ExternalMetricSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2ExternalMetricSourceBuilder(this, item); } + ExternalNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2ExternalMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2ExternalMetricSourceBuilder builder; + public N and() { return (N) V2MetricSpecFluentImpl.this.withExternal(builder.build()); } + public N endExternal() { return and(); } - } - public class ObjectNestedImpl extends io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested,io.kubernetes.client.fluent.Nested{ + + public class ObjectNestedImpl + extends io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested> + implements io.kubernetes.client.openapi.models.V2MetricSpecFluent.ObjectNested, + io.kubernetes.client.fluent.Nested { ObjectNestedImpl(io.kubernetes.client.openapi.models.V2ObjectMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2ObjectMetricSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2ObjectMetricSourceBuilder(this, item); } + ObjectNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2ObjectMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2ObjectMetricSourceBuilder builder; + public N and() { return (N) V2MetricSpecFluentImpl.this.withObject(builder.build()); } + public N endObject() { return and(); } - } - public class PodsNestedImpl extends io.kubernetes.client.openapi.models.V2PodsMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested,io.kubernetes.client.fluent.Nested{ + + public class PodsNestedImpl + extends io.kubernetes.client.openapi.models.V2PodsMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested> + implements io.kubernetes.client.openapi.models.V2MetricSpecFluent.PodsNested, + io.kubernetes.client.fluent.Nested { PodsNestedImpl(io.kubernetes.client.openapi.models.V2PodsMetricSource item) { this.builder = new io.kubernetes.client.openapi.models.V2PodsMetricSourceBuilder(this, item); } + PodsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2PodsMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2PodsMetricSourceBuilder builder; + public N and() { return (N) V2MetricSpecFluentImpl.this.withPods(builder.build()); } + public N endPods() { return and(); } - } - public class ResourceNestedImpl extends io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested,io.kubernetes.client.fluent.Nested{ + + public class ResourceNestedImpl + extends io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested> + implements io.kubernetes.client.openapi.models.V2MetricSpecFluent.ResourceNested, + io.kubernetes.client.fluent.Nested { ResourceNestedImpl(io.kubernetes.client.openapi.models.V2ResourceMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2ResourceMetricSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2ResourceMetricSourceBuilder(this, item); } + ResourceNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2ResourceMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2ResourceMetricSourceBuilder builder; + public N and() { return (N) V2MetricSpecFluentImpl.this.withResource(builder.build()); } + public N endResource() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricStatusBuilder.java index 8121990e52..84aa85e673 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricStatusBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2MetricStatusBuilder extends io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2MetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2MetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2MetricStatus, + io.kubernetes.client.openapi.models.V2MetricStatusBuilder> { public V2MetricStatusBuilder() { this(false); } + public V2MetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2MetricStatus(), validationEnabled); } + public V2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2MetricStatusFluent fluent) { this(fluent, false); } - public V2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2MetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2MetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2MetricStatus(), validationEnabled); } - public V2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2MetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2MetricStatus instance) { + + public V2MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2MetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2MetricStatus instance) { this(fluent, instance, false); } - public V2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2MetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2MetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2MetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2MetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainerResource(instance.getContainerResource()); fluent.withExternal(instance.getExternal()); @@ -33,13 +59,17 @@ public V2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2MetricStatusF fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2MetricStatus instance) { - this(instance,false); + this(instance, false); } - public V2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2MetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2MetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainerResource(instance.getContainerResource()); this.withExternal(instance.getExternal()); @@ -52,10 +82,12 @@ public V2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2MetricStatus this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2MetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2MetricStatus build() { V2MetricStatus buildable = new V2MetricStatus(); buildable.setContainerResource(fluent.getContainerResource()); @@ -66,18 +98,23 @@ public io.kubernetes.client.openapi.models.V2MetricStatus build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2MetricStatusBuilder that = (V2MetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricStatusFluent.java index 2886d37b77..46a84fa94f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricStatusFluent.java @@ -1,124 +1,215 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; - - /** - * Generated - */ -public interface V2MetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2MetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2MetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildContainerResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus getContainerResource(); - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus buildContainerResource(); - public A withContainerResource(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus containerResource); + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus + buildContainerResource(); + + public A withContainerResource( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus containerResource); + public java.lang.Boolean hasContainerResource(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested withNewContainerResource(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested withNewContainerResourceLike(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus item); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested editContainerResource(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested editOrNewContainerResource(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested editOrNewContainerResourceLike(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus item); - + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested + withNewContainerResource(); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested + withNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested + editContainerResource(); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested + editOrNewContainerResource(); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested + editOrNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus item); + /** * This method has been deprecated, please use method buildExternal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ExternalMetricStatus getExternal(); + public io.kubernetes.client.openapi.models.V2ExternalMetricStatus buildExternal(); + public A withExternal(io.kubernetes.client.openapi.models.V2ExternalMetricStatus external); + public java.lang.Boolean hasExternal(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested withNewExternal(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested withNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricStatus item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested + withNewExternal(); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested + withNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricStatus item); + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested editExternal(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested editOrNewExternal(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested editOrNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricStatus item); - + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested + editOrNewExternal(); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested + editOrNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricStatus item); + /** * This method has been deprecated, please use method buildObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ObjectMetricStatus getObject(); + public io.kubernetes.client.openapi.models.V2ObjectMetricStatus buildObject(); + public A withObject(io.kubernetes.client.openapi.models.V2ObjectMetricStatus _object); + public java.lang.Boolean hasObject(); + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested withNewObject(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested withNewObjectLike(io.kubernetes.client.openapi.models.V2ObjectMetricStatus item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested withNewObjectLike( + io.kubernetes.client.openapi.models.V2ObjectMetricStatus item); + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested editObject(); + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested editOrNewObject(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested editOrNewObjectLike(io.kubernetes.client.openapi.models.V2ObjectMetricStatus item); - + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested + editOrNewObjectLike(io.kubernetes.client.openapi.models.V2ObjectMetricStatus item); + /** * This method has been deprecated, please use method buildPods instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2PodsMetricStatus getPods(); + public io.kubernetes.client.openapi.models.V2PodsMetricStatus buildPods(); + public A withPods(io.kubernetes.client.openapi.models.V2PodsMetricStatus pods); + public java.lang.Boolean hasPods(); + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested withNewPods(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested withNewPodsLike(io.kubernetes.client.openapi.models.V2PodsMetricStatus item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested withNewPodsLike( + io.kubernetes.client.openapi.models.V2PodsMetricStatus item); + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested editPods(); + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested editOrNewPods(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested editOrNewPodsLike(io.kubernetes.client.openapi.models.V2PodsMetricStatus item); - + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested editOrNewPodsLike( + io.kubernetes.client.openapi.models.V2PodsMetricStatus item); + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ResourceMetricStatus getResource(); + public io.kubernetes.client.openapi.models.V2ResourceMetricStatus buildResource(); + public A withResource(io.kubernetes.client.openapi.models.V2ResourceMetricStatus resource); + public java.lang.Boolean hasResource(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested withNewResource(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricStatus item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested + withNewResource(); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricStatus item); + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested editResource(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested editOrNewResource(); - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricStatus item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested + editOrNewResource(); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricStatus item); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface ContainerResourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent>{ + + public interface ContainerResourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluent< + io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested> { public N and(); + public N endContainerResource(); - } - public interface ExternalNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent>{ + + public interface ExternalNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluent< + io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested> { public N and(); + public N endExternal(); - } - public interface ObjectNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent>{ + + public interface ObjectNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent< + io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested> { public N and(); + public N endObject(); - } - public interface PodsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent>{ + + public interface PodsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent< + io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested> { public N and(); + public N endPods(); - } - public interface ResourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent>{ + + public interface ResourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent< + io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested> { public N and(); + public N endResource(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricStatusFluentImpl.java index 6303d611c6..57e0965ca9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricStatusFluentImpl.java @@ -1,18 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Object; +/** Generated */ +public class V2MetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2MetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2MetricStatusFluent { + public V2MetricStatusFluentImpl() {} - /** - * Generated - */ -public class V2MetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2MetricStatusFluent{ - public V2MetricStatusFluentImpl() { - } public V2MetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2MetricStatus instance) { this.withContainerResource(instance.getContainerResource()); @@ -25,295 +31,463 @@ public V2MetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2MetricStat this.withResource(instance.getResource()); this.withType(instance.getType()); - } - private io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusBuilder containerResource; + + private io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusBuilder + containerResource; private io.kubernetes.client.openapi.models.V2ExternalMetricStatusBuilder external; private io.kubernetes.client.openapi.models.V2ObjectMetricStatusBuilder _object; private io.kubernetes.client.openapi.models.V2PodsMetricStatusBuilder pods; private io.kubernetes.client.openapi.models.V2ResourceMetricStatusBuilder resource; private java.lang.String type; - + /** * This method has been deprecated, please use method buildContainerResource instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus getContainerResource() { - return this.containerResource!=null ?this.containerResource.build():null; + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus + getContainerResource() { + return this.containerResource != null ? this.containerResource.build() : null; } - public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus buildContainerResource() { - return this.containerResource!=null ?this.containerResource.build():null; + + public io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus + buildContainerResource() { + return this.containerResource != null ? this.containerResource.build() : null; } - public A withContainerResource(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus containerResource) { + + public A withContainerResource( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus containerResource) { _visitables.get("containerResource").remove(this.containerResource); - if (containerResource!=null){ this.containerResource= new io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusBuilder(containerResource); _visitables.get("containerResource").add(this.containerResource);} return (A) this; + if (containerResource != null) { + this.containerResource = + new io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusBuilder( + containerResource); + _visitables.get("containerResource").add(this.containerResource); + } + return (A) this; } + public java.lang.Boolean hasContainerResource() { return this.containerResource != null; } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested withNewContainerResource() { - return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl.ContainerResourceNestedImpl(); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested + withNewContainerResource() { + return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl + .ContainerResourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested withNewContainerResourceLike(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus item) { - return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl.ContainerResourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested + withNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus item) { + return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl + .ContainerResourceNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested editContainerResource() { + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested + editContainerResource() { return withNewContainerResourceLike(getContainerResource()); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested editOrNewContainerResource() { - return withNewContainerResourceLike(getContainerResource() != null ? getContainerResource(): new io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested + editOrNewContainerResource() { + return withNewContainerResourceLike( + getContainerResource() != null + ? getContainerResource() + : new io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested editOrNewContainerResourceLike(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus item) { - return withNewContainerResourceLike(getContainerResource() != null ? getContainerResource(): item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested + editOrNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus item) { + return withNewContainerResourceLike( + getContainerResource() != null ? getContainerResource() : item); } - + /** * This method has been deprecated, please use method buildExternal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ExternalMetricStatus getExternal() { - return this.external!=null ?this.external.build():null; + return this.external != null ? this.external.build() : null; } + public io.kubernetes.client.openapi.models.V2ExternalMetricStatus buildExternal() { - return this.external!=null ?this.external.build():null; + return this.external != null ? this.external.build() : null; } + public A withExternal(io.kubernetes.client.openapi.models.V2ExternalMetricStatus external) { _visitables.get("external").remove(this.external); - if (external!=null){ this.external= new io.kubernetes.client.openapi.models.V2ExternalMetricStatusBuilder(external); _visitables.get("external").add(this.external);} return (A) this; + if (external != null) { + this.external = + new io.kubernetes.client.openapi.models.V2ExternalMetricStatusBuilder(external); + _visitables.get("external").add(this.external); + } + return (A) this; } + public java.lang.Boolean hasExternal() { return this.external != null; } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested withNewExternal() { + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested + withNewExternal() { return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl.ExternalNestedImpl(); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested withNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricStatus item) { - return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl.ExternalNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested + withNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricStatus item) { + return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl.ExternalNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested editExternal() { return withNewExternalLike(getExternal()); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested editOrNewExternal() { - return withNewExternalLike(getExternal() != null ? getExternal(): new io.kubernetes.client.openapi.models.V2ExternalMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested + editOrNewExternal() { + return withNewExternalLike( + getExternal() != null + ? getExternal() + : new io.kubernetes.client.openapi.models.V2ExternalMetricStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested editOrNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricStatus item) { - return withNewExternalLike(getExternal() != null ? getExternal(): item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested + editOrNewExternalLike(io.kubernetes.client.openapi.models.V2ExternalMetricStatus item) { + return withNewExternalLike(getExternal() != null ? getExternal() : item); } - + /** * This method has been deprecated, please use method buildObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ObjectMetricStatus getObject() { - return this._object!=null ?this._object.build():null; + return this._object != null ? this._object.build() : null; } + public io.kubernetes.client.openapi.models.V2ObjectMetricStatus buildObject() { - return this._object!=null ?this._object.build():null; + return this._object != null ? this._object.build() : null; } + public A withObject(io.kubernetes.client.openapi.models.V2ObjectMetricStatus _object) { _visitables.get("_object").remove(this._object); - if (_object!=null){ this._object= new io.kubernetes.client.openapi.models.V2ObjectMetricStatusBuilder(_object); _visitables.get("_object").add(this._object);} return (A) this; + if (_object != null) { + this._object = new io.kubernetes.client.openapi.models.V2ObjectMetricStatusBuilder(_object); + _visitables.get("_object").add(this._object); + } + return (A) this; } + public java.lang.Boolean hasObject() { return this._object != null; } + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested withNewObject() { return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl.ObjectNestedImpl(); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested withNewObjectLike(io.kubernetes.client.openapi.models.V2ObjectMetricStatus item) { + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested withNewObjectLike( + io.kubernetes.client.openapi.models.V2ObjectMetricStatus item) { return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl.ObjectNestedImpl(item); } + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested editObject() { return withNewObjectLike(getObject()); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested editOrNewObject() { - return withNewObjectLike(getObject() != null ? getObject(): new io.kubernetes.client.openapi.models.V2ObjectMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested + editOrNewObject() { + return withNewObjectLike( + getObject() != null + ? getObject() + : new io.kubernetes.client.openapi.models.V2ObjectMetricStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested editOrNewObjectLike(io.kubernetes.client.openapi.models.V2ObjectMetricStatus item) { - return withNewObjectLike(getObject() != null ? getObject(): item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested + editOrNewObjectLike(io.kubernetes.client.openapi.models.V2ObjectMetricStatus item) { + return withNewObjectLike(getObject() != null ? getObject() : item); } - + /** * This method has been deprecated, please use method buildPods instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2PodsMetricStatus getPods() { - return this.pods!=null ?this.pods.build():null; + return this.pods != null ? this.pods.build() : null; } + public io.kubernetes.client.openapi.models.V2PodsMetricStatus buildPods() { - return this.pods!=null ?this.pods.build():null; + return this.pods != null ? this.pods.build() : null; } + public A withPods(io.kubernetes.client.openapi.models.V2PodsMetricStatus pods) { _visitables.get("pods").remove(this.pods); - if (pods!=null){ this.pods= new io.kubernetes.client.openapi.models.V2PodsMetricStatusBuilder(pods); _visitables.get("pods").add(this.pods);} return (A) this; + if (pods != null) { + this.pods = new io.kubernetes.client.openapi.models.V2PodsMetricStatusBuilder(pods); + _visitables.get("pods").add(this.pods); + } + return (A) this; } + public java.lang.Boolean hasPods() { return this.pods != null; } + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested withNewPods() { return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl.PodsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested withNewPodsLike(io.kubernetes.client.openapi.models.V2PodsMetricStatus item) { + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested withNewPodsLike( + io.kubernetes.client.openapi.models.V2PodsMetricStatus item) { return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl.PodsNestedImpl(item); } + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested editPods() { return withNewPodsLike(getPods()); } + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested editOrNewPods() { - return withNewPodsLike(getPods() != null ? getPods(): new io.kubernetes.client.openapi.models.V2PodsMetricStatusBuilder().build()); + return withNewPodsLike( + getPods() != null + ? getPods() + : new io.kubernetes.client.openapi.models.V2PodsMetricStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested editOrNewPodsLike(io.kubernetes.client.openapi.models.V2PodsMetricStatus item) { - return withNewPodsLike(getPods() != null ? getPods(): item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested editOrNewPodsLike( + io.kubernetes.client.openapi.models.V2PodsMetricStatus item) { + return withNewPodsLike(getPods() != null ? getPods() : item); } - + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2ResourceMetricStatus getResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public io.kubernetes.client.openapi.models.V2ResourceMetricStatus buildResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public A withResource(io.kubernetes.client.openapi.models.V2ResourceMetricStatus resource) { _visitables.get("resource").remove(this.resource); - if (resource!=null){ this.resource= new io.kubernetes.client.openapi.models.V2ResourceMetricStatusBuilder(resource); _visitables.get("resource").add(this.resource);} return (A) this; + if (resource != null) { + this.resource = + new io.kubernetes.client.openapi.models.V2ResourceMetricStatusBuilder(resource); + _visitables.get("resource").add(this.resource); + } + return (A) this; } + public java.lang.Boolean hasResource() { return this.resource != null; } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested withNewResource() { + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested + withNewResource() { return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl.ResourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricStatus item) { - return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl.ResourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricStatus item) { + return new io.kubernetes.client.openapi.models.V2MetricStatusFluentImpl.ResourceNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested editResource() { return withNewResourceLike(getResource()); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested editOrNewResource() { - return withNewResourceLike(getResource() != null ? getResource(): new io.kubernetes.client.openapi.models.V2ResourceMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested + editOrNewResource() { + return withNewResourceLike( + getResource() != null + ? getResource() + : new io.kubernetes.client.openapi.models.V2ResourceMetricStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricStatus item) { - return withNewResourceLike(getResource() != null ? getResource(): item); + + public io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V2ResourceMetricStatus item) { + return withNewResourceLike(getResource() != null ? getResource() : item); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2MetricStatusFluentImpl that = (V2MetricStatusFluentImpl) o; - if (containerResource != null ? !containerResource.equals(that.containerResource) :that.containerResource != null) return false; - if (external != null ? !external.equals(that.external) :that.external != null) return false; - if (_object != null ? !_object.equals(that._object) :that._object != null) return false; - if (pods != null ? !pods.equals(that.pods) :that.pods != null) return false; - if (resource != null ? !resource.equals(that.resource) :that.resource != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (containerResource != null + ? !containerResource.equals(that.containerResource) + : that.containerResource != null) return false; + if (external != null ? !external.equals(that.external) : that.external != null) return false; + if (_object != null ? !_object.equals(that._object) : that._object != null) return false; + if (pods != null ? !pods.equals(that.pods) : that.pods != null) return false; + if (resource != null ? !resource.equals(that.resource) : that.resource != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(containerResource, external, _object, pods, resource, type, super.hashCode()); + return java.util.Objects.hash( + containerResource, external, _object, pods, resource, type, super.hashCode()); } - public class ContainerResourceNestedImpl extends io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested,io.kubernetes.client.fluent.Nested{ - ContainerResourceNestedImpl(io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusBuilder(this, item); + + public class ContainerResourceNestedImpl + extends io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested> + implements io.kubernetes.client.openapi.models.V2MetricStatusFluent.ContainerResourceNested< + N>, + io.kubernetes.client.fluent.Nested { + ContainerResourceNestedImpl( + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatus item) { + this.builder = + new io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusBuilder( + this, item); } + ContainerResourceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2ContainerResourceMetricStatusBuilder builder; + public N and() { return (N) V2MetricStatusFluentImpl.this.withContainerResource(builder.build()); } + public N endContainerResource() { return and(); } - } - public class ExternalNestedImpl extends io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested,io.kubernetes.client.fluent.Nested{ + + public class ExternalNestedImpl + extends io.kubernetes.client.openapi.models.V2ExternalMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested> + implements io.kubernetes.client.openapi.models.V2MetricStatusFluent.ExternalNested, + io.kubernetes.client.fluent.Nested { ExternalNestedImpl(io.kubernetes.client.openapi.models.V2ExternalMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2ExternalMetricStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2ExternalMetricStatusBuilder(this, item); } + ExternalNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2ExternalMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2ExternalMetricStatusBuilder builder; + public N and() { return (N) V2MetricStatusFluentImpl.this.withExternal(builder.build()); } + public N endExternal() { return and(); } - } - public class ObjectNestedImpl extends io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested,io.kubernetes.client.fluent.Nested{ + + public class ObjectNestedImpl + extends io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested> + implements io.kubernetes.client.openapi.models.V2MetricStatusFluent.ObjectNested, + io.kubernetes.client.fluent.Nested { ObjectNestedImpl(io.kubernetes.client.openapi.models.V2ObjectMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2ObjectMetricStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2ObjectMetricStatusBuilder(this, item); } + ObjectNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2ObjectMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2ObjectMetricStatusBuilder builder; + public N and() { return (N) V2MetricStatusFluentImpl.this.withObject(builder.build()); } + public N endObject() { return and(); } - } - public class PodsNestedImpl extends io.kubernetes.client.openapi.models.V2PodsMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested,io.kubernetes.client.fluent.Nested{ + + public class PodsNestedImpl + extends io.kubernetes.client.openapi.models.V2PodsMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested> + implements io.kubernetes.client.openapi.models.V2MetricStatusFluent.PodsNested, + io.kubernetes.client.fluent.Nested { PodsNestedImpl(io.kubernetes.client.openapi.models.V2PodsMetricStatus item) { this.builder = new io.kubernetes.client.openapi.models.V2PodsMetricStatusBuilder(this, item); } + PodsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2PodsMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2PodsMetricStatusBuilder builder; + public N and() { return (N) V2MetricStatusFluentImpl.this.withPods(builder.build()); } + public N endPods() { return and(); } - } - public class ResourceNestedImpl extends io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested,io.kubernetes.client.fluent.Nested{ + + public class ResourceNestedImpl + extends io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested> + implements io.kubernetes.client.openapi.models.V2MetricStatusFluent.ResourceNested, + io.kubernetes.client.fluent.Nested { ResourceNestedImpl(io.kubernetes.client.openapi.models.V2ResourceMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2ResourceMetricStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2ResourceMetricStatusBuilder(this, item); } + ResourceNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2ResourceMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2ResourceMetricStatusBuilder builder; + public N and() { return (N) V2MetricStatusFluentImpl.this.withResource(builder.build()); } + public N endResource() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricTargetBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricTargetBuilder.java index 7214f4d152..d5d39a1494 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricTargetBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricTargetBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2MetricTargetBuilder extends io.kubernetes.client.openapi.models.V2MetricTargetFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2MetricTargetBuilder + extends io.kubernetes.client.openapi.models.V2MetricTargetFluentImpl< + io.kubernetes.client.openapi.models.V2MetricTargetBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2MetricTarget, + io.kubernetes.client.openapi.models.V2MetricTargetBuilder> { public V2MetricTargetBuilder() { this(false); } + public V2MetricTargetBuilder(java.lang.Boolean validationEnabled) { this(new V2MetricTarget(), validationEnabled); } + public V2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2MetricTargetFluent fluent) { this(fluent, false); } - public V2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2MetricTargetFluent fluent,java.lang.Boolean validationEnabled) { + + public V2MetricTargetBuilder( + io.kubernetes.client.openapi.models.V2MetricTargetFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2MetricTarget(), validationEnabled); } - public V2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2MetricTargetFluent fluent,io.kubernetes.client.openapi.models.V2MetricTarget instance) { + + public V2MetricTargetBuilder( + io.kubernetes.client.openapi.models.V2MetricTargetFluent fluent, + io.kubernetes.client.openapi.models.V2MetricTarget instance) { this(fluent, instance, false); } - public V2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2MetricTargetFluent fluent,io.kubernetes.client.openapi.models.V2MetricTarget instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2MetricTargetBuilder( + io.kubernetes.client.openapi.models.V2MetricTargetFluent fluent, + io.kubernetes.client.openapi.models.V2MetricTarget instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAverageUtilization(instance.getAverageUtilization()); fluent.withAverageValue(instance.getAverageValue()); @@ -29,13 +55,17 @@ public V2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2MetricTargetF fluent.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2MetricTarget instance) { - this(instance,false); + this(instance, false); } - public V2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2MetricTarget instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2MetricTargetBuilder( + io.kubernetes.client.openapi.models.V2MetricTarget instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAverageUtilization(instance.getAverageUtilization()); this.withAverageValue(instance.getAverageValue()); @@ -44,10 +74,12 @@ public V2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2MetricTarget this.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2MetricTargetFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2MetricTarget build() { V2MetricTarget buildable = new V2MetricTarget(); buildable.setAverageUtilization(fluent.getAverageUtilization()); @@ -56,18 +88,23 @@ public io.kubernetes.client.openapi.models.V2MetricTarget build() { buildable.setValue(fluent.getValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2MetricTargetBuilder that = (V2MetricTargetBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricTargetFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricTargetFluent.java index 58e9bb0ff0..9833825a7a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricTargetFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricTargetFluent.java @@ -1,36 +1,50 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2MetricTargetFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2MetricTargetFluent< + A extends io.kubernetes.client.openapi.models.V2MetricTargetFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getAverageUtilization(); + public A withAverageUtilization(java.lang.Integer averageUtilization); + public java.lang.Boolean hasAverageUtilization(); + public io.kubernetes.client.custom.Quantity getAverageValue(); + public A withAverageValue(io.kubernetes.client.custom.Quantity averageValue); + public java.lang.Boolean hasAverageValue(); + public A withNewAverageValue(java.lang.String value); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); + public io.kubernetes.client.custom.Quantity getValue(); + public A withValue(io.kubernetes.client.custom.Quantity value); + public java.lang.Boolean hasValue(); + public A withNewValue(java.lang.String value); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricTargetFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricTargetFluentImpl.java index 377b701e90..9ecd0ee13c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricTargetFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricTargetFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - /** - * Generated - */ -public class V2MetricTargetFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2MetricTargetFluent{ - public V2MetricTargetFluentImpl() { - } +/** Generated */ +public class V2MetricTargetFluentImpl< + A extends io.kubernetes.client.openapi.models.V2MetricTargetFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2MetricTargetFluent { + public V2MetricTargetFluentImpl() {} + public V2MetricTargetFluentImpl(io.kubernetes.client.openapi.models.V2MetricTarget instance) { this.withAverageUtilization(instance.getAverageUtilization()); @@ -22,74 +29,94 @@ public V2MetricTargetFluentImpl(io.kubernetes.client.openapi.models.V2MetricTarg this.withType(instance.getType()); this.withValue(instance.getValue()); - } + private java.lang.Integer averageUtilization; private io.kubernetes.client.custom.Quantity averageValue; private java.lang.String type; private io.kubernetes.client.custom.Quantity value; + public java.lang.Integer getAverageUtilization() { return this.averageUtilization; } + public A withAverageUtilization(java.lang.Integer averageUtilization) { - this.averageUtilization=averageUtilization; return (A) this; + this.averageUtilization = averageUtilization; + return (A) this; } + public java.lang.Boolean hasAverageUtilization() { return this.averageUtilization != null; } + public io.kubernetes.client.custom.Quantity getAverageValue() { return this.averageValue; } + public A withAverageValue(io.kubernetes.client.custom.Quantity averageValue) { - this.averageValue=averageValue; return (A) this; + this.averageValue = averageValue; + return (A) this; } + public java.lang.Boolean hasAverageValue() { return this.averageValue != null; } + public A withNewAverageValue(java.lang.String value) { - return (A)withAverageValue(new Quantity(value)); + return (A) withAverageValue(new Quantity(value)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public io.kubernetes.client.custom.Quantity getValue() { return this.value; } + public A withValue(io.kubernetes.client.custom.Quantity value) { - this.value=value; return (A) this; + this.value = value; + return (A) this; } + public java.lang.Boolean hasValue() { return this.value != null; } + public A withNewValue(java.lang.String value) { - return (A)withValue(new Quantity(value)); + return (A) withValue(new Quantity(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2MetricTargetFluentImpl that = (V2MetricTargetFluentImpl) o; - if (averageUtilization != null ? !averageUtilization.equals(that.averageUtilization) :that.averageUtilization != null) return false; - if (averageValue != null ? !averageValue.equals(that.averageValue) :that.averageValue != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; - if (value != null ? !value.equals(that.value) :that.value != null) return false; + if (averageUtilization != null + ? !averageUtilization.equals(that.averageUtilization) + : that.averageUtilization != null) return false; + if (averageValue != null ? !averageValue.equals(that.averageValue) : that.averageValue != null) + return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; + if (value != null ? !value.equals(that.value) : that.value != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(averageUtilization, averageValue, type, value, super.hashCode()); + return java.util.Objects.hash(averageUtilization, averageValue, type, value, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricValueStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricValueStatusBuilder.java index ba61bb4ba2..ad502b9264 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricValueStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricValueStatusBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2MetricValueStatusBuilder extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2MetricValueStatusBuilder + extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluentImpl< + io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2MetricValueStatus, + io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder> { public V2MetricValueStatusBuilder() { this(false); } + public V2MetricValueStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2MetricValueStatus(), validationEnabled); } - public V2MetricValueStatusBuilder(io.kubernetes.client.openapi.models.V2MetricValueStatusFluent fluent) { + + public V2MetricValueStatusBuilder( + io.kubernetes.client.openapi.models.V2MetricValueStatusFluent fluent) { this(fluent, false); } - public V2MetricValueStatusBuilder(io.kubernetes.client.openapi.models.V2MetricValueStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2MetricValueStatusBuilder( + io.kubernetes.client.openapi.models.V2MetricValueStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2MetricValueStatus(), validationEnabled); } - public V2MetricValueStatusBuilder(io.kubernetes.client.openapi.models.V2MetricValueStatusFluent fluent,io.kubernetes.client.openapi.models.V2MetricValueStatus instance) { + + public V2MetricValueStatusBuilder( + io.kubernetes.client.openapi.models.V2MetricValueStatusFluent fluent, + io.kubernetes.client.openapi.models.V2MetricValueStatus instance) { this(fluent, instance, false); } - public V2MetricValueStatusBuilder(io.kubernetes.client.openapi.models.V2MetricValueStatusFluent fluent,io.kubernetes.client.openapi.models.V2MetricValueStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2MetricValueStatusBuilder( + io.kubernetes.client.openapi.models.V2MetricValueStatusFluent fluent, + io.kubernetes.client.openapi.models.V2MetricValueStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAverageUtilization(instance.getAverageUtilization()); fluent.withAverageValue(instance.getAverageValue()); fluent.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2MetricValueStatusBuilder(io.kubernetes.client.openapi.models.V2MetricValueStatus instance) { - this(instance,false); + + public V2MetricValueStatusBuilder( + io.kubernetes.client.openapi.models.V2MetricValueStatus instance) { + this(instance, false); } - public V2MetricValueStatusBuilder(io.kubernetes.client.openapi.models.V2MetricValueStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2MetricValueStatusBuilder( + io.kubernetes.client.openapi.models.V2MetricValueStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAverageUtilization(instance.getAverageUtilization()); this.withAverageValue(instance.getAverageValue()); this.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2MetricValueStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2MetricValueStatus build() { V2MetricValueStatus buildable = new V2MetricValueStatus(); buildable.setAverageUtilization(fluent.getAverageUtilization()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2MetricValueStatus build() { buildable.setValue(fluent.getValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2MetricValueStatusBuilder that = (V2MetricValueStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricValueStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricValueStatusFluent.java index a950b11fc1..ef6e96b7c3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricValueStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricValueStatusFluent.java @@ -1,26 +1,40 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2MetricValueStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2MetricValueStatusFluent< + A extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getAverageUtilization(); + public A withAverageUtilization(java.lang.Integer averageUtilization); + public java.lang.Boolean hasAverageUtilization(); + public io.kubernetes.client.custom.Quantity getAverageValue(); + public A withAverageValue(io.kubernetes.client.custom.Quantity averageValue); + public java.lang.Boolean hasAverageValue(); + public A withNewAverageValue(java.lang.String value); + public io.kubernetes.client.custom.Quantity getValue(); + public A withValue(io.kubernetes.client.custom.Quantity value); + public java.lang.Boolean hasValue(); + public A withNewValue(java.lang.String value); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricValueStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricValueStatusFluentImpl.java index e1942b1f9e..94e22ac1a0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricValueStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2MetricValueStatusFluentImpl.java @@ -1,73 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2MetricValueStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2MetricValueStatusFluent{ - public V2MetricValueStatusFluentImpl() { - } - public V2MetricValueStatusFluentImpl(io.kubernetes.client.openapi.models.V2MetricValueStatus instance) { + +/** Generated */ +public class V2MetricValueStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2MetricValueStatusFluent { + public V2MetricValueStatusFluentImpl() {} + + public V2MetricValueStatusFluentImpl( + io.kubernetes.client.openapi.models.V2MetricValueStatus instance) { this.withAverageUtilization(instance.getAverageUtilization()); this.withAverageValue(instance.getAverageValue()); this.withValue(instance.getValue()); - } + private java.lang.Integer averageUtilization; private io.kubernetes.client.custom.Quantity averageValue; private io.kubernetes.client.custom.Quantity value; + public java.lang.Integer getAverageUtilization() { return this.averageUtilization; } + public A withAverageUtilization(java.lang.Integer averageUtilization) { - this.averageUtilization=averageUtilization; return (A) this; + this.averageUtilization = averageUtilization; + return (A) this; } + public java.lang.Boolean hasAverageUtilization() { return this.averageUtilization != null; } + public io.kubernetes.client.custom.Quantity getAverageValue() { return this.averageValue; } + public A withAverageValue(io.kubernetes.client.custom.Quantity averageValue) { - this.averageValue=averageValue; return (A) this; + this.averageValue = averageValue; + return (A) this; } + public java.lang.Boolean hasAverageValue() { return this.averageValue != null; } + public A withNewAverageValue(java.lang.String value) { - return (A)withAverageValue(new Quantity(value)); + return (A) withAverageValue(new Quantity(value)); } + public io.kubernetes.client.custom.Quantity getValue() { return this.value; } + public A withValue(io.kubernetes.client.custom.Quantity value) { - this.value=value; return (A) this; + this.value = value; + return (A) this; } + public java.lang.Boolean hasValue() { return this.value != null; } + public A withNewValue(java.lang.String value) { - return (A)withValue(new Quantity(value)); + return (A) withValue(new Quantity(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2MetricValueStatusFluentImpl that = (V2MetricValueStatusFluentImpl) o; - if (averageUtilization != null ? !averageUtilization.equals(that.averageUtilization) :that.averageUtilization != null) return false; - if (averageValue != null ? !averageValue.equals(that.averageValue) :that.averageValue != null) return false; - if (value != null ? !value.equals(that.value) :that.value != null) return false; + if (averageUtilization != null + ? !averageUtilization.equals(that.averageUtilization) + : that.averageUtilization != null) return false; + if (averageValue != null ? !averageValue.equals(that.averageValue) : that.averageValue != null) + return false; + if (value != null ? !value.equals(that.value) : that.value != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(averageUtilization, averageValue, value, super.hashCode()); + return java.util.Objects.hash(averageUtilization, averageValue, value, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricSourceBuilder.java index b52667d88f..46cac93e33 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricSourceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2ObjectMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2ObjectMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2ObjectMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2ObjectMetricSource, + io.kubernetes.client.openapi.models.V2ObjectMetricSourceBuilder> { public V2ObjectMetricSourceBuilder() { this(false); } + public V2ObjectMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2ObjectMetricSource(), validationEnabled); } - public V2ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent fluent) { + + public V2ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent fluent) { this(fluent, false); } - public V2ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2ObjectMetricSource(), validationEnabled); } - public V2ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2ObjectMetricSource instance) { + + public V2ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2ObjectMetricSource instance) { this(fluent, instance, false); } - public V2ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2ObjectMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2ObjectMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDescribedObject(instance.getDescribedObject()); fluent.withMetric(instance.getMetric()); fluent.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ObjectMetricSource instance) { - this(instance,false); + + public V2ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ObjectMetricSource instance) { + this(instance, false); } - public V2ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ObjectMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ObjectMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDescribedObject(instance.getDescribedObject()); this.withMetric(instance.getMetric()); this.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2ObjectMetricSource build() { V2ObjectMetricSource buildable = new V2ObjectMetricSource(); buildable.setDescribedObject(fluent.getDescribedObject()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2ObjectMetricSource build() { buildable.setTarget(fluent.getTarget()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2ObjectMetricSourceBuilder that = (V2ObjectMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricSourceFluent.java index 3ac69f4557..6fdc1d29ad 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricSourceFluent.java @@ -1,75 +1,137 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2ObjectMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2ObjectMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildDescribedObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2CrossVersionObjectReference getDescribedObject(); + public io.kubernetes.client.openapi.models.V2CrossVersionObjectReference buildDescribedObject(); - public A withDescribedObject(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference describedObject); + + public A withDescribedObject( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference describedObject); + public java.lang.Boolean hasDescribedObject(); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested withNewDescribedObject(); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested withNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested editDescribedObject(); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested editOrNewDescribedObject(); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested editOrNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item); - + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested + withNewDescribedObject(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested + withNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested + editDescribedObject(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested + editOrNewDescribedObject(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested + editOrNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item); + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricIdentifier getMetric(); + public io.kubernetes.client.openapi.models.V2MetricIdentifier buildMetric(); + public A withMetric(io.kubernetes.client.openapi.models.V2MetricIdentifier metric); + public java.lang.Boolean hasMetric(); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested withNewMetric(); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested editMetric(); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested editOrNewMetric(); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); - + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested + withNewMetric(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested + editMetric(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested + editOrNewMetric(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricTarget getTarget(); + public io.kubernetes.client.openapi.models.V2MetricTarget buildTarget(); + public A withTarget(io.kubernetes.client.openapi.models.V2MetricTarget target); + public java.lang.Boolean hasTarget(); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested withNewTarget(); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested editTarget(); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested editOrNewTarget(); - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); - public interface DescribedObjectNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent>{ + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested + withNewTarget(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested + editTarget(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested + editOrNewTarget(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); + + public interface DescribedObjectNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent< + io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested< + N>> { public N and(); + public N endDescribedObject(); - } - public interface MetricNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricIdentifierFluent>{ + + public interface MetricNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricIdentifierFluent< + io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested> { public N and(); + public N endMetric(); - } - public interface TargetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricTargetFluent>{ + + public interface TargetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricTargetFluent< + io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested> { public N and(); + public N endTarget(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricSourceFluentImpl.java index 6100a01de5..66dc866977 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricSourceFluentImpl.java @@ -1,189 +1,304 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2ObjectMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent { + public V2ObjectMetricSourceFluentImpl() {} - /** - * Generated - */ -public class V2ObjectMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent{ - public V2ObjectMetricSourceFluentImpl() { - } - public V2ObjectMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2ObjectMetricSource instance) { + public V2ObjectMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2ObjectMetricSource instance) { this.withDescribedObject(instance.getDescribedObject()); this.withMetric(instance.getMetric()); this.withTarget(instance.getTarget()); - } + private io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder describedObject; private io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder metric; private io.kubernetes.client.openapi.models.V2MetricTargetBuilder target; - + /** * This method has been deprecated, please use method buildDescribedObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2CrossVersionObjectReference getDescribedObject() { - return this.describedObject!=null ?this.describedObject.build():null; + return this.describedObject != null ? this.describedObject.build() : null; } + public io.kubernetes.client.openapi.models.V2CrossVersionObjectReference buildDescribedObject() { - return this.describedObject!=null ?this.describedObject.build():null; + return this.describedObject != null ? this.describedObject.build() : null; } - public A withDescribedObject(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference describedObject) { + + public A withDescribedObject( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference describedObject) { _visitables.get("describedObject").remove(this.describedObject); - if (describedObject!=null){ this.describedObject= new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(describedObject); _visitables.get("describedObject").add(this.describedObject);} return (A) this; + if (describedObject != null) { + this.describedObject = + new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder( + describedObject); + _visitables.get("describedObject").add(this.describedObject); + } + return (A) this; } + public java.lang.Boolean hasDescribedObject() { return this.describedObject != null; } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested withNewDescribedObject() { - return new io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl.DescribedObjectNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested + withNewDescribedObject() { + return new io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl + .DescribedObjectNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested withNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { - return new io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl.DescribedObjectNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested + withNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { + return new io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl + .DescribedObjectNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested editDescribedObject() { + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested + editDescribedObject() { return withNewDescribedObjectLike(getDescribedObject()); } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested editOrNewDescribedObject() { - return withNewDescribedObjectLike(getDescribedObject() != null ? getDescribedObject(): new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested + editOrNewDescribedObject() { + return withNewDescribedObjectLike( + getDescribedObject() != null + ? getDescribedObject() + : new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested editOrNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { - return withNewDescribedObjectLike(getDescribedObject() != null ? getDescribedObject(): item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested + editOrNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { + return withNewDescribedObjectLike(getDescribedObject() != null ? getDescribedObject() : item); } - + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricIdentifier getMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricIdentifier buildMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public A withMetric(io.kubernetes.client.openapi.models.V2MetricIdentifier metric) { _visitables.get("metric").remove(this.metric); - if (metric!=null){ this.metric= new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(metric); _visitables.get("metric").add(this.metric);} return (A) this; + if (metric != null) { + this.metric = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(metric); + _visitables.get("metric").add(this.metric); + } + return (A) this; } + public java.lang.Boolean hasMetric() { return this.metric != null; } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested withNewMetric() { - return new io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl.MetricNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested + withNewMetric() { + return new io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl + .MetricNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { - return new io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl.MetricNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { + return new io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl.MetricNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested editMetric() { + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested + editMetric() { return withNewMetricLike(getMetric()); } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested editOrNewMetric() { - return withNewMetricLike(getMetric() != null ? getMetric(): new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested + editOrNewMetric() { + return withNewMetricLike( + getMetric() != null + ? getMetric() + : new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder().build()); } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { - return withNewMetricLike(getMetric() != null ? getMetric(): item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { + return withNewMetricLike(getMetric() != null ? getMetric() : item); } - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricTarget getTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricTarget buildTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public A withTarget(io.kubernetes.client.openapi.models.V2MetricTarget target) { _visitables.get("target").remove(this.target); - if (target!=null){ this.target= new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(target); _visitables.get("target").add(this.target);} return (A) this; + if (target != null) { + this.target = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(target); + _visitables.get("target").add(this.target); + } + return (A) this; } + public java.lang.Boolean hasTarget() { return this.target != null; } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested withNewTarget() { - return new io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl.TargetNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested + withNewTarget() { + return new io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl + .TargetNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { - return new io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl.TargetNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { + return new io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluentImpl.TargetNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested editTarget() { + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested + editTarget() { return withNewTargetLike(getTarget()); } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested editOrNewTarget() { - return withNewTargetLike(getTarget() != null ? getTarget(): new io.kubernetes.client.openapi.models.V2MetricTargetBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested + editOrNewTarget() { + return withNewTargetLike( + getTarget() != null + ? getTarget() + : new io.kubernetes.client.openapi.models.V2MetricTargetBuilder().build()); } - public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { - return withNewTargetLike(getTarget() != null ? getTarget(): item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { + return withNewTargetLike(getTarget() != null ? getTarget() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2ObjectMetricSourceFluentImpl that = (V2ObjectMetricSourceFluentImpl) o; - if (describedObject != null ? !describedObject.equals(that.describedObject) :that.describedObject != null) return false; - if (metric != null ? !metric.equals(that.metric) :that.metric != null) return false; - if (target != null ? !target.equals(that.target) :that.target != null) return false; + if (describedObject != null + ? !describedObject.equals(that.describedObject) + : that.describedObject != null) return false; + if (metric != null ? !metric.equals(that.metric) : that.metric != null) return false; + if (target != null ? !target.equals(that.target) : that.target != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(describedObject, metric, target, super.hashCode()); + return java.util.Objects.hash(describedObject, metric, target, super.hashCode()); } - public class DescribedObjectNestedImpl extends io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested,io.kubernetes.client.fluent.Nested{ - DescribedObjectNestedImpl(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(this, item); + + public class DescribedObjectNestedImpl + extends io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.DescribedObjectNested> + implements io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent + .DescribedObjectNested< + N>, + io.kubernetes.client.fluent.Nested { + DescribedObjectNestedImpl( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { + this.builder = + new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(this, item); } + DescribedObjectNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder builder; + public N and() { return (N) V2ObjectMetricSourceFluentImpl.this.withDescribedObject(builder.build()); } + public N endDescribedObject() { return and(); } - } - public class MetricNestedImpl extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl> implements io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested,io.kubernetes.client.fluent.Nested{ + + public class MetricNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested> + implements io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.MetricNested, + io.kubernetes.client.fluent.Nested { MetricNestedImpl(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(this, item); } + MetricNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder builder; + public N and() { return (N) V2ObjectMetricSourceFluentImpl.this.withMetric(builder.build()); } + public N endMetric() { return and(); } - } - public class TargetNestedImpl extends io.kubernetes.client.openapi.models.V2MetricTargetFluentImpl> implements io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested,io.kubernetes.client.fluent.Nested{ + + public class TargetNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricTargetFluentImpl< + io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested> + implements io.kubernetes.client.openapi.models.V2ObjectMetricSourceFluent.TargetNested, + io.kubernetes.client.fluent.Nested { TargetNestedImpl(io.kubernetes.client.openapi.models.V2MetricTarget item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(this, item); } + TargetNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricTargetBuilder builder; + public N and() { return (N) V2ObjectMetricSourceFluentImpl.this.withTarget(builder.build()); } + public N endTarget() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricStatusBuilder.java index 3438ce3363..1b624f2c1d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricStatusBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2ObjectMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2ObjectMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2ObjectMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2ObjectMetricStatus, + io.kubernetes.client.openapi.models.V2ObjectMetricStatusBuilder> { public V2ObjectMetricStatusBuilder() { this(false); } + public V2ObjectMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2ObjectMetricStatus(), validationEnabled); } - public V2ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent fluent) { + + public V2ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent fluent) { this(fluent, false); } - public V2ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2ObjectMetricStatus(), validationEnabled); } - public V2ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2ObjectMetricStatus instance) { + + public V2ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2ObjectMetricStatus instance) { this(fluent, instance, false); } - public V2ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2ObjectMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2ObjectMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCurrent(instance.getCurrent()); fluent.withDescribedObject(instance.getDescribedObject()); fluent.withMetric(instance.getMetric()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ObjectMetricStatus instance) { - this(instance,false); + + public V2ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ObjectMetricStatus instance) { + this(instance, false); } - public V2ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ObjectMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ObjectMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCurrent(instance.getCurrent()); this.withDescribedObject(instance.getDescribedObject()); this.withMetric(instance.getMetric()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2ObjectMetricStatus build() { V2ObjectMetricStatus buildable = new V2ObjectMetricStatus(); buildable.setCurrent(fluent.getCurrent()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2ObjectMetricStatus build() { buildable.setMetric(fluent.getMetric()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2ObjectMetricStatusBuilder that = (V2ObjectMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricStatusFluent.java index 900e0850cc..67bef77cd6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricStatusFluent.java @@ -1,75 +1,137 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2ObjectMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2ObjectMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricValueStatus getCurrent(); + public io.kubernetes.client.openapi.models.V2MetricValueStatus buildCurrent(); + public A withCurrent(io.kubernetes.client.openapi.models.V2MetricValueStatus current); + public java.lang.Boolean hasCurrent(); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested withNewCurrent(); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested editCurrent(); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested editOrNewCurrent(); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); - + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested + withNewCurrent(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested + editCurrent(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested + editOrNewCurrent(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); + /** * This method has been deprecated, please use method buildDescribedObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2CrossVersionObjectReference getDescribedObject(); + public io.kubernetes.client.openapi.models.V2CrossVersionObjectReference buildDescribedObject(); - public A withDescribedObject(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference describedObject); + + public A withDescribedObject( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference describedObject); + public java.lang.Boolean hasDescribedObject(); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested withNewDescribedObject(); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested withNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested editDescribedObject(); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested editOrNewDescribedObject(); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested editOrNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item); - + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested + withNewDescribedObject(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested + withNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested + editDescribedObject(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested + editOrNewDescribedObject(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested + editOrNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item); + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricIdentifier getMetric(); + public io.kubernetes.client.openapi.models.V2MetricIdentifier buildMetric(); + public A withMetric(io.kubernetes.client.openapi.models.V2MetricIdentifier metric); + public java.lang.Boolean hasMetric(); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested withNewMetric(); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested editMetric(); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested editOrNewMetric(); - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); - public interface CurrentNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricValueStatusFluent>{ + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested + withNewMetric(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested + editMetric(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested + editOrNewMetric(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + + public interface CurrentNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricValueStatusFluent< + io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested> { public N and(); + public N endCurrent(); - } - public interface DescribedObjectNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent>{ + + public interface DescribedObjectNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluent< + io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested< + N>> { public N and(); + public N endDescribedObject(); - } - public interface MetricNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricIdentifierFluent>{ + + public interface MetricNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricIdentifierFluent< + io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested> { public N and(); + public N endMetric(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricStatusFluentImpl.java index 623f1c003a..88b5b28354 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ObjectMetricStatusFluentImpl.java @@ -1,189 +1,304 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2ObjectMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent { + public V2ObjectMetricStatusFluentImpl() {} - /** - * Generated - */ -public class V2ObjectMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent{ - public V2ObjectMetricStatusFluentImpl() { - } - public V2ObjectMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2ObjectMetricStatus instance) { + public V2ObjectMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2ObjectMetricStatus instance) { this.withCurrent(instance.getCurrent()); this.withDescribedObject(instance.getDescribedObject()); this.withMetric(instance.getMetric()); - } + private io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder current; private io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder describedObject; private io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder metric; - + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricValueStatus getCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricValueStatus buildCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public A withCurrent(io.kubernetes.client.openapi.models.V2MetricValueStatus current) { _visitables.get("current").remove(this.current); - if (current!=null){ this.current= new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(current); _visitables.get("current").add(this.current);} return (A) this; + if (current != null) { + this.current = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(current); + _visitables.get("current").add(this.current); + } + return (A) this; } + public java.lang.Boolean hasCurrent() { return this.current != null; } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested withNewCurrent() { - return new io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl.CurrentNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested + withNewCurrent() { + return new io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl + .CurrentNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { - return new io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl.CurrentNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { + return new io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl.CurrentNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested editCurrent() { + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested + editCurrent() { return withNewCurrentLike(getCurrent()); } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested editOrNewCurrent() { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested + editOrNewCurrent() { + return withNewCurrentLike( + getCurrent() != null + ? getCurrent() + : new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { + return withNewCurrentLike(getCurrent() != null ? getCurrent() : item); } - + /** * This method has been deprecated, please use method buildDescribedObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2CrossVersionObjectReference getDescribedObject() { - return this.describedObject!=null ?this.describedObject.build():null; + return this.describedObject != null ? this.describedObject.build() : null; } + public io.kubernetes.client.openapi.models.V2CrossVersionObjectReference buildDescribedObject() { - return this.describedObject!=null ?this.describedObject.build():null; + return this.describedObject != null ? this.describedObject.build() : null; } - public A withDescribedObject(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference describedObject) { + + public A withDescribedObject( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference describedObject) { _visitables.get("describedObject").remove(this.describedObject); - if (describedObject!=null){ this.describedObject= new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(describedObject); _visitables.get("describedObject").add(this.describedObject);} return (A) this; + if (describedObject != null) { + this.describedObject = + new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder( + describedObject); + _visitables.get("describedObject").add(this.describedObject); + } + return (A) this; } + public java.lang.Boolean hasDescribedObject() { return this.describedObject != null; } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested withNewDescribedObject() { - return new io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl.DescribedObjectNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested + withNewDescribedObject() { + return new io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl + .DescribedObjectNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested withNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { - return new io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl.DescribedObjectNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested + withNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { + return new io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl + .DescribedObjectNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested editDescribedObject() { + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested + editDescribedObject() { return withNewDescribedObjectLike(getDescribedObject()); } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested editOrNewDescribedObject() { - return withNewDescribedObjectLike(getDescribedObject() != null ? getDescribedObject(): new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested + editOrNewDescribedObject() { + return withNewDescribedObjectLike( + getDescribedObject() != null + ? getDescribedObject() + : new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested editOrNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { - return withNewDescribedObjectLike(getDescribedObject() != null ? getDescribedObject(): item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested + editOrNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { + return withNewDescribedObjectLike(getDescribedObject() != null ? getDescribedObject() : item); } - + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricIdentifier getMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricIdentifier buildMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public A withMetric(io.kubernetes.client.openapi.models.V2MetricIdentifier metric) { _visitables.get("metric").remove(this.metric); - if (metric!=null){ this.metric= new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(metric); _visitables.get("metric").add(this.metric);} return (A) this; + if (metric != null) { + this.metric = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(metric); + _visitables.get("metric").add(this.metric); + } + return (A) this; } + public java.lang.Boolean hasMetric() { return this.metric != null; } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested withNewMetric() { - return new io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl.MetricNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested + withNewMetric() { + return new io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl + .MetricNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { - return new io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl.MetricNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { + return new io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluentImpl.MetricNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested editMetric() { + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested + editMetric() { return withNewMetricLike(getMetric()); } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested editOrNewMetric() { - return withNewMetricLike(getMetric() != null ? getMetric(): new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested + editOrNewMetric() { + return withNewMetricLike( + getMetric() != null + ? getMetric() + : new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder().build()); } - public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { - return withNewMetricLike(getMetric() != null ? getMetric(): item); + + public io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { + return withNewMetricLike(getMetric() != null ? getMetric() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2ObjectMetricStatusFluentImpl that = (V2ObjectMetricStatusFluentImpl) o; - if (current != null ? !current.equals(that.current) :that.current != null) return false; - if (describedObject != null ? !describedObject.equals(that.describedObject) :that.describedObject != null) return false; - if (metric != null ? !metric.equals(that.metric) :that.metric != null) return false; + if (current != null ? !current.equals(that.current) : that.current != null) return false; + if (describedObject != null + ? !describedObject.equals(that.describedObject) + : that.describedObject != null) return false; + if (metric != null ? !metric.equals(that.metric) : that.metric != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(current, describedObject, metric, super.hashCode()); + return java.util.Objects.hash(current, describedObject, metric, super.hashCode()); } - public class CurrentNestedImpl extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested,io.kubernetes.client.fluent.Nested{ + + public class CurrentNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluentImpl< + io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested> + implements io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.CurrentNested, + io.kubernetes.client.fluent.Nested { CurrentNestedImpl(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(this, item); } + CurrentNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder builder; + public N and() { return (N) V2ObjectMetricStatusFluentImpl.this.withCurrent(builder.build()); } + public N endCurrent() { return and(); } - } - public class DescribedObjectNestedImpl extends io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested,io.kubernetes.client.fluent.Nested{ - DescribedObjectNestedImpl(io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(this, item); + + public class DescribedObjectNestedImpl + extends io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.DescribedObjectNested> + implements io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent + .DescribedObjectNested< + N>, + io.kubernetes.client.fluent.Nested { + DescribedObjectNestedImpl( + io.kubernetes.client.openapi.models.V2CrossVersionObjectReference item) { + this.builder = + new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(this, item); } + DescribedObjectNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V2CrossVersionObjectReferenceBuilder builder; + public N and() { return (N) V2ObjectMetricStatusFluentImpl.this.withDescribedObject(builder.build()); } + public N endDescribedObject() { return and(); } - } - public class MetricNestedImpl extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl> implements io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested,io.kubernetes.client.fluent.Nested{ + + public class MetricNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested> + implements io.kubernetes.client.openapi.models.V2ObjectMetricStatusFluent.MetricNested, + io.kubernetes.client.fluent.Nested { MetricNestedImpl(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(this, item); } + MetricNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder builder; + public N and() { return (N) V2ObjectMetricStatusFluentImpl.this.withMetric(builder.build()); } + public N endMetric() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricSourceBuilder.java index f11fe912b9..b2cb75fada 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2PodsMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2PodsMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2PodsMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2PodsMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2PodsMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2PodsMetricSource, + io.kubernetes.client.openapi.models.V2PodsMetricSourceBuilder> { public V2PodsMetricSourceBuilder() { this(false); } + public V2PodsMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2PodsMetricSource(), validationEnabled); } - public V2PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent fluent) { + + public V2PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent fluent) { this(fluent, false); } - public V2PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2PodsMetricSource(), validationEnabled); } - public V2PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2PodsMetricSource instance) { + + public V2PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2PodsMetricSource instance) { this(fluent, instance, false); } - public V2PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2PodsMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2PodsMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMetric(instance.getMetric()); fluent.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2PodsMetricSource instance) { - this(instance,false); + + public V2PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2PodsMetricSource instance) { + this(instance, false); } - public V2PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2PodsMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2PodsMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMetric(instance.getMetric()); this.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2PodsMetricSource build() { V2PodsMetricSource buildable = new V2PodsMetricSource(); buildable.setMetric(fluent.getMetric()); buildable.setTarget(fluent.getTarget()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2PodsMetricSourceBuilder that = (V2PodsMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricSourceFluent.java index 29ffe1eba8..3608994825 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricSourceFluent.java @@ -1,55 +1,93 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2PodsMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2PodsMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricIdentifier getMetric(); + public io.kubernetes.client.openapi.models.V2MetricIdentifier buildMetric(); + public A withMetric(io.kubernetes.client.openapi.models.V2MetricIdentifier metric); + public java.lang.Boolean hasMetric(); - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested withNewMetric(); - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested + withNewMetric(); + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested editMetric(); - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested editOrNewMetric(); - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); - + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested + editOrNewMetric(); + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricTarget getTarget(); + public io.kubernetes.client.openapi.models.V2MetricTarget buildTarget(); + public A withTarget(io.kubernetes.client.openapi.models.V2MetricTarget target); + public java.lang.Boolean hasTarget(); - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested withNewTarget(); - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested + withNewTarget(); + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested editTarget(); - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested editOrNewTarget(); - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); - public interface MetricNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricIdentifierFluent>{ + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested + editOrNewTarget(); + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); + + public interface MetricNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricIdentifierFluent< + io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested> { public N and(); + public N endMetric(); - } - public interface TargetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricTargetFluent>{ + + public interface TargetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricTargetFluent< + io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested> { public N and(); + public N endTarget(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricSourceFluentImpl.java index e1d147bb7b..2e88842ebc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricSourceFluentImpl.java @@ -1,135 +1,202 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2PodsMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent { + public V2PodsMetricSourceFluentImpl() {} - /** - * Generated - */ -public class V2PodsMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent{ - public V2PodsMetricSourceFluentImpl() { - } - public V2PodsMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2PodsMetricSource instance) { + public V2PodsMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2PodsMetricSource instance) { this.withMetric(instance.getMetric()); this.withTarget(instance.getTarget()); - } + private io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder metric; private io.kubernetes.client.openapi.models.V2MetricTargetBuilder target; - + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricIdentifier getMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricIdentifier buildMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public A withMetric(io.kubernetes.client.openapi.models.V2MetricIdentifier metric) { _visitables.get("metric").remove(this.metric); - if (metric!=null){ this.metric= new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(metric); _visitables.get("metric").add(this.metric);} return (A) this; + if (metric != null) { + this.metric = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(metric); + _visitables.get("metric").add(this.metric); + } + return (A) this; } + public java.lang.Boolean hasMetric() { return this.metric != null; } - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested withNewMetric() { + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested + withNewMetric() { return new io.kubernetes.client.openapi.models.V2PodsMetricSourceFluentImpl.MetricNestedImpl(); } - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { - return new io.kubernetes.client.openapi.models.V2PodsMetricSourceFluentImpl.MetricNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { + return new io.kubernetes.client.openapi.models.V2PodsMetricSourceFluentImpl.MetricNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested editMetric() { return withNewMetricLike(getMetric()); } - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested editOrNewMetric() { - return withNewMetricLike(getMetric() != null ? getMetric(): new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder().build()); + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested + editOrNewMetric() { + return withNewMetricLike( + getMetric() != null + ? getMetric() + : new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder().build()); } - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { - return withNewMetricLike(getMetric() != null ? getMetric(): item); + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { + return withNewMetricLike(getMetric() != null ? getMetric() : item); } - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricTarget getTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricTarget buildTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public A withTarget(io.kubernetes.client.openapi.models.V2MetricTarget target) { _visitables.get("target").remove(this.target); - if (target!=null){ this.target= new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(target); _visitables.get("target").add(this.target);} return (A) this; + if (target != null) { + this.target = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(target); + _visitables.get("target").add(this.target); + } + return (A) this; } + public java.lang.Boolean hasTarget() { return this.target != null; } - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested withNewTarget() { + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested + withNewTarget() { return new io.kubernetes.client.openapi.models.V2PodsMetricSourceFluentImpl.TargetNestedImpl(); } - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { - return new io.kubernetes.client.openapi.models.V2PodsMetricSourceFluentImpl.TargetNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { + return new io.kubernetes.client.openapi.models.V2PodsMetricSourceFluentImpl.TargetNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested editTarget() { return withNewTargetLike(getTarget()); } - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested editOrNewTarget() { - return withNewTargetLike(getTarget() != null ? getTarget(): new io.kubernetes.client.openapi.models.V2MetricTargetBuilder().build()); + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested + editOrNewTarget() { + return withNewTargetLike( + getTarget() != null + ? getTarget() + : new io.kubernetes.client.openapi.models.V2MetricTargetBuilder().build()); } - public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { - return withNewTargetLike(getTarget() != null ? getTarget(): item); + + public io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { + return withNewTargetLike(getTarget() != null ? getTarget() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2PodsMetricSourceFluentImpl that = (V2PodsMetricSourceFluentImpl) o; - if (metric != null ? !metric.equals(that.metric) :that.metric != null) return false; - if (target != null ? !target.equals(that.target) :that.target != null) return false; + if (metric != null ? !metric.equals(that.metric) : that.metric != null) return false; + if (target != null ? !target.equals(that.target) : that.target != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(metric, target, super.hashCode()); + return java.util.Objects.hash(metric, target, super.hashCode()); } - public class MetricNestedImpl extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl> implements io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested,io.kubernetes.client.fluent.Nested{ + + public class MetricNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested> + implements io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.MetricNested, + io.kubernetes.client.fluent.Nested { MetricNestedImpl(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(this, item); } + MetricNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder builder; + public N and() { return (N) V2PodsMetricSourceFluentImpl.this.withMetric(builder.build()); } + public N endMetric() { return and(); } - } - public class TargetNestedImpl extends io.kubernetes.client.openapi.models.V2MetricTargetFluentImpl> implements io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested,io.kubernetes.client.fluent.Nested{ + + public class TargetNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricTargetFluentImpl< + io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested> + implements io.kubernetes.client.openapi.models.V2PodsMetricSourceFluent.TargetNested, + io.kubernetes.client.fluent.Nested { TargetNestedImpl(io.kubernetes.client.openapi.models.V2MetricTarget item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(this, item); } + TargetNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricTargetBuilder builder; + public N and() { return (N) V2PodsMetricSourceFluentImpl.this.withTarget(builder.build()); } + public N endTarget() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricStatusBuilder.java index 58ed1d35ea..603220a0a5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricStatusBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2PodsMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2PodsMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2PodsMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2PodsMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2PodsMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2PodsMetricStatus, + io.kubernetes.client.openapi.models.V2PodsMetricStatusBuilder> { public V2PodsMetricStatusBuilder() { this(false); } + public V2PodsMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2PodsMetricStatus(), validationEnabled); } - public V2PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent fluent) { + + public V2PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent fluent) { this(fluent, false); } - public V2PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2PodsMetricStatus(), validationEnabled); } - public V2PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2PodsMetricStatus instance) { + + public V2PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2PodsMetricStatus instance) { this(fluent, instance, false); } - public V2PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2PodsMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2PodsMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCurrent(instance.getCurrent()); fluent.withMetric(instance.getMetric()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2PodsMetricStatus instance) { - this(instance,false); + + public V2PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2PodsMetricStatus instance) { + this(instance, false); } - public V2PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2PodsMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2PodsMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCurrent(instance.getCurrent()); this.withMetric(instance.getMetric()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2PodsMetricStatus build() { V2PodsMetricStatus buildable = new V2PodsMetricStatus(); buildable.setCurrent(fluent.getCurrent()); buildable.setMetric(fluent.getMetric()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2PodsMetricStatusBuilder that = (V2PodsMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricStatusFluent.java index bdc4737ccb..e2896c0b1e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricStatusFluent.java @@ -1,55 +1,94 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2PodsMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2PodsMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricValueStatus getCurrent(); + public io.kubernetes.client.openapi.models.V2MetricValueStatus buildCurrent(); + public A withCurrent(io.kubernetes.client.openapi.models.V2MetricValueStatus current); + public java.lang.Boolean hasCurrent(); - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested withNewCurrent(); - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested editCurrent(); - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested editOrNewCurrent(); - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); - + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested + withNewCurrent(); + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested + editCurrent(); + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested + editOrNewCurrent(); + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricIdentifier getMetric(); + public io.kubernetes.client.openapi.models.V2MetricIdentifier buildMetric(); + public A withMetric(io.kubernetes.client.openapi.models.V2MetricIdentifier metric); + public java.lang.Boolean hasMetric(); - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested withNewMetric(); - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested + withNewMetric(); + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested editMetric(); - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested editOrNewMetric(); - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); - public interface CurrentNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricValueStatusFluent>{ + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested + editOrNewMetric(); + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item); + + public interface CurrentNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricValueStatusFluent< + io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested> { public N and(); + public N endCurrent(); - } - public interface MetricNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricIdentifierFluent>{ + + public interface MetricNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricIdentifierFluent< + io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested> { public N and(); + public N endMetric(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricStatusFluentImpl.java index 2af20eecf4..027c8d7bca 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2PodsMetricStatusFluentImpl.java @@ -1,135 +1,203 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2PodsMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent { + public V2PodsMetricStatusFluentImpl() {} - /** - * Generated - */ -public class V2PodsMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent{ - public V2PodsMetricStatusFluentImpl() { - } - public V2PodsMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2PodsMetricStatus instance) { + public V2PodsMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2PodsMetricStatus instance) { this.withCurrent(instance.getCurrent()); this.withMetric(instance.getMetric()); - } + private io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder current; private io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder metric; - + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricValueStatus getCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricValueStatus buildCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public A withCurrent(io.kubernetes.client.openapi.models.V2MetricValueStatus current) { _visitables.get("current").remove(this.current); - if (current!=null){ this.current= new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(current); _visitables.get("current").add(this.current);} return (A) this; + if (current != null) { + this.current = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(current); + _visitables.get("current").add(this.current); + } + return (A) this; } + public java.lang.Boolean hasCurrent() { return this.current != null; } - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested withNewCurrent() { + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested + withNewCurrent() { return new io.kubernetes.client.openapi.models.V2PodsMetricStatusFluentImpl.CurrentNestedImpl(); } - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { - return new io.kubernetes.client.openapi.models.V2PodsMetricStatusFluentImpl.CurrentNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { + return new io.kubernetes.client.openapi.models.V2PodsMetricStatusFluentImpl.CurrentNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested editCurrent() { + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested + editCurrent() { return withNewCurrentLike(getCurrent()); } - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested editOrNewCurrent() { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested + editOrNewCurrent() { + return withNewCurrentLike( + getCurrent() != null + ? getCurrent() + : new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): item); + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { + return withNewCurrentLike(getCurrent() != null ? getCurrent() : item); } - + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricIdentifier getMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricIdentifier buildMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public A withMetric(io.kubernetes.client.openapi.models.V2MetricIdentifier metric) { _visitables.get("metric").remove(this.metric); - if (metric!=null){ this.metric= new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(metric); _visitables.get("metric").add(this.metric);} return (A) this; + if (metric != null) { + this.metric = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(metric); + _visitables.get("metric").add(this.metric); + } + return (A) this; } + public java.lang.Boolean hasMetric() { return this.metric != null; } - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested withNewMetric() { + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested + withNewMetric() { return new io.kubernetes.client.openapi.models.V2PodsMetricStatusFluentImpl.MetricNestedImpl(); } - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { - return new io.kubernetes.client.openapi.models.V2PodsMetricStatusFluentImpl.MetricNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { + return new io.kubernetes.client.openapi.models.V2PodsMetricStatusFluentImpl.MetricNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested editMetric() { return withNewMetricLike(getMetric()); } - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested editOrNewMetric() { - return withNewMetricLike(getMetric() != null ? getMetric(): new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder().build()); + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested + editOrNewMetric() { + return withNewMetricLike( + getMetric() != null + ? getMetric() + : new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder().build()); } - public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { - return withNewMetricLike(getMetric() != null ? getMetric(): item); + + public io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { + return withNewMetricLike(getMetric() != null ? getMetric() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2PodsMetricStatusFluentImpl that = (V2PodsMetricStatusFluentImpl) o; - if (current != null ? !current.equals(that.current) :that.current != null) return false; - if (metric != null ? !metric.equals(that.metric) :that.metric != null) return false; + if (current != null ? !current.equals(that.current) : that.current != null) return false; + if (metric != null ? !metric.equals(that.metric) : that.metric != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(current, metric, super.hashCode()); + return java.util.Objects.hash(current, metric, super.hashCode()); } - public class CurrentNestedImpl extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested,io.kubernetes.client.fluent.Nested{ + + public class CurrentNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluentImpl< + io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested> + implements io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.CurrentNested, + io.kubernetes.client.fluent.Nested { CurrentNestedImpl(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(this, item); } + CurrentNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder builder; + public N and() { return (N) V2PodsMetricStatusFluentImpl.this.withCurrent(builder.build()); } + public N endCurrent() { return and(); } - } - public class MetricNestedImpl extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl> implements io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested,io.kubernetes.client.fluent.Nested{ + + public class MetricNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested> + implements io.kubernetes.client.openapi.models.V2PodsMetricStatusFluent.MetricNested, + io.kubernetes.client.fluent.Nested { MetricNestedImpl(io.kubernetes.client.openapi.models.V2MetricIdentifier item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(this, item); } + MetricNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricIdentifierBuilder builder; + public N and() { return (N) V2PodsMetricStatusFluentImpl.this.withMetric(builder.build()); } + public N endMetric() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricSourceBuilder.java index 199bef79d8..46e4e382d4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2ResourceMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2ResourceMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2ResourceMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2ResourceMetricSource, + io.kubernetes.client.openapi.models.V2ResourceMetricSourceBuilder> { public V2ResourceMetricSourceBuilder() { this(false); } + public V2ResourceMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2ResourceMetricSource(), validationEnabled); } - public V2ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent fluent) { + + public V2ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent fluent) { this(fluent, false); } - public V2ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2ResourceMetricSource(), validationEnabled); } - public V2ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2ResourceMetricSource instance) { + + public V2ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2ResourceMetricSource instance) { this(fluent, instance, false); } - public V2ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2ResourceMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2ResourceMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ResourceMetricSource instance) { - this(instance,false); + + public V2ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ResourceMetricSource instance) { + this(instance, false); } - public V2ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2ResourceMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2ResourceMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2ResourceMetricSource build() { V2ResourceMetricSource buildable = new V2ResourceMetricSource(); buildable.setName(fluent.getName()); buildable.setTarget(fluent.getTarget()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2ResourceMetricSourceBuilder that = (V2ResourceMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricSourceFluent.java index f840c43684..f510a7b6c5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricSourceFluent.java @@ -1,44 +1,66 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2ResourceMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2ResourceMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricTarget getTarget(); + public io.kubernetes.client.openapi.models.V2MetricTarget buildTarget(); + public A withTarget(io.kubernetes.client.openapi.models.V2MetricTarget target); + public java.lang.Boolean hasTarget(); - public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested withNewTarget(); - public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); - public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested editTarget(); - public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested editOrNewTarget(); - public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); - public interface TargetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricTargetFluent>{ + + public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested + withNewTarget(); + + public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); + + public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested + editTarget(); + + public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested + editOrNewTarget(); + + public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item); + + public interface TargetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricTargetFluent< + io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested> { public N and(); + public N endTarget(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricSourceFluentImpl.java index 9fbdca82f4..9a1a89bb24 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricSourceFluentImpl.java @@ -1,103 +1,144 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2ResourceMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent { + public V2ResourceMetricSourceFluentImpl() {} - /** - * Generated - */ -public class V2ResourceMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent{ - public V2ResourceMetricSourceFluentImpl() { - } - public V2ResourceMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2ResourceMetricSource instance) { + public V2ResourceMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2ResourceMetricSource instance) { this.withName(instance.getName()); this.withTarget(instance.getTarget()); - } + private java.lang.String name; private io.kubernetes.client.openapi.models.V2MetricTargetBuilder target; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricTarget getTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricTarget buildTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public A withTarget(io.kubernetes.client.openapi.models.V2MetricTarget target) { _visitables.get("target").remove(this.target); - if (target!=null){ this.target= new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(target); _visitables.get("target").add(this.target);} return (A) this; + if (target != null) { + this.target = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(target); + _visitables.get("target").add(this.target); + } + return (A) this; } + public java.lang.Boolean hasTarget() { return this.target != null; } - public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested withNewTarget() { - return new io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluentImpl.TargetNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested + withNewTarget() { + return new io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluentImpl + .TargetNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { - return new io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluentImpl.TargetNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { + return new io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluentImpl + .TargetNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested editTarget() { + + public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested + editTarget() { return withNewTargetLike(getTarget()); } - public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested editOrNewTarget() { - return withNewTargetLike(getTarget() != null ? getTarget(): new io.kubernetes.client.openapi.models.V2MetricTargetBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested + editOrNewTarget() { + return withNewTargetLike( + getTarget() != null + ? getTarget() + : new io.kubernetes.client.openapi.models.V2MetricTargetBuilder().build()); } - public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { - return withNewTargetLike(getTarget() != null ? getTarget(): item); + + public io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2MetricTarget item) { + return withNewTargetLike(getTarget() != null ? getTarget() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2ResourceMetricSourceFluentImpl that = (V2ResourceMetricSourceFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (target != null ? !target.equals(that.target) :that.target != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (target != null ? !target.equals(that.target) : that.target != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, target, super.hashCode()); + return java.util.Objects.hash(name, target, super.hashCode()); } - public class TargetNestedImpl extends io.kubernetes.client.openapi.models.V2MetricTargetFluentImpl> implements io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested,io.kubernetes.client.fluent.Nested{ + + public class TargetNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricTargetFluentImpl< + io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested> + implements io.kubernetes.client.openapi.models.V2ResourceMetricSourceFluent.TargetNested, + io.kubernetes.client.fluent.Nested { TargetNestedImpl(io.kubernetes.client.openapi.models.V2MetricTarget item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(this, item); } + TargetNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricTargetBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricTargetBuilder builder; + public N and() { return (N) V2ResourceMetricSourceFluentImpl.this.withTarget(builder.build()); } + public N endTarget() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricStatusBuilder.java index c65b96ef4b..2f4bf3c87a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricStatusBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2ResourceMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2ResourceMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2ResourceMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2ResourceMetricStatus, + io.kubernetes.client.openapi.models.V2ResourceMetricStatusBuilder> { public V2ResourceMetricStatusBuilder() { this(false); } + public V2ResourceMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2ResourceMetricStatus(), validationEnabled); } - public V2ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent fluent) { + + public V2ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent fluent) { this(fluent, false); } - public V2ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2ResourceMetricStatus(), validationEnabled); } - public V2ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2ResourceMetricStatus instance) { + + public V2ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2ResourceMetricStatus instance) { this(fluent, instance, false); } - public V2ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2ResourceMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2ResourceMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCurrent(instance.getCurrent()); fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ResourceMetricStatus instance) { - this(instance,false); + + public V2ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ResourceMetricStatus instance) { + this(instance, false); } - public V2ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2ResourceMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2ResourceMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCurrent(instance.getCurrent()); this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2ResourceMetricStatus build() { V2ResourceMetricStatus buildable = new V2ResourceMetricStatus(); buildable.setCurrent(fluent.getCurrent()); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2ResourceMetricStatusBuilder that = (V2ResourceMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricStatusFluent.java index f70fc344b7..d9fa01a6f5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricStatusFluent.java @@ -1,44 +1,67 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2ResourceMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2ResourceMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricValueStatus getCurrent(); + public io.kubernetes.client.openapi.models.V2MetricValueStatus buildCurrent(); + public A withCurrent(io.kubernetes.client.openapi.models.V2MetricValueStatus current); + public java.lang.Boolean hasCurrent(); - public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested withNewCurrent(); - public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); - public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested editCurrent(); - public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested editOrNewCurrent(); - public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested + withNewCurrent(); + + public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested + editCurrent(); + + public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested + editOrNewCurrent(); + + public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - public interface CurrentNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2MetricValueStatusFluent>{ + + public interface CurrentNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2MetricValueStatusFluent< + io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested> { public N and(); + public N endCurrent(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricStatusFluentImpl.java index 400f892090..4e3348fe3a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2ResourceMetricStatusFluentImpl.java @@ -1,103 +1,144 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2ResourceMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent { + public V2ResourceMetricStatusFluentImpl() {} - /** - * Generated - */ -public class V2ResourceMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent{ - public V2ResourceMetricStatusFluentImpl() { - } - public V2ResourceMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2ResourceMetricStatus instance) { + public V2ResourceMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2ResourceMetricStatus instance) { this.withCurrent(instance.getCurrent()); this.withName(instance.getName()); - } + private io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder current; private java.lang.String name; - + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2MetricValueStatus getCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public io.kubernetes.client.openapi.models.V2MetricValueStatus buildCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public A withCurrent(io.kubernetes.client.openapi.models.V2MetricValueStatus current) { _visitables.get("current").remove(this.current); - if (current!=null){ this.current= new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(current); _visitables.get("current").add(this.current);} return (A) this; + if (current != null) { + this.current = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(current); + _visitables.get("current").add(this.current); + } + return (A) this; } + public java.lang.Boolean hasCurrent() { return this.current != null; } - public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested withNewCurrent() { - return new io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluentImpl.CurrentNestedImpl(); + + public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested + withNewCurrent() { + return new io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluentImpl + .CurrentNestedImpl(); } - public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { - return new io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluentImpl.CurrentNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { + return new io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluentImpl + .CurrentNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested editCurrent() { + + public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested + editCurrent() { return withNewCurrentLike(getCurrent()); } - public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested editOrNewCurrent() { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested + editOrNewCurrent() { + return withNewCurrentLike( + getCurrent() != null + ? getCurrent() + : new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): item); + + public io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { + return withNewCurrentLike(getCurrent() != null ? getCurrent() : item); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2ResourceMetricStatusFluentImpl that = (V2ResourceMetricStatusFluentImpl) o; - if (current != null ? !current.equals(that.current) :that.current != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (current != null ? !current.equals(that.current) : that.current != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(current, name, super.hashCode()); + return java.util.Objects.hash(current, name, super.hashCode()); } - public class CurrentNestedImpl extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested,io.kubernetes.client.fluent.Nested{ + + public class CurrentNestedImpl + extends io.kubernetes.client.openapi.models.V2MetricValueStatusFluentImpl< + io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested> + implements io.kubernetes.client.openapi.models.V2ResourceMetricStatusFluent.CurrentNested, + io.kubernetes.client.fluent.Nested { CurrentNestedImpl(io.kubernetes.client.openapi.models.V2MetricValueStatus item) { this.builder = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(this, item); } + CurrentNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2MetricValueStatusBuilder builder; + public N and() { return (N) V2ResourceMetricStatusFluentImpl.this.withCurrent(builder.build()); } + public N endCurrent() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricSourceBuilder.java index c967bf6208..60efd292a5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1ContainerResourceMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1ContainerResourceMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource, + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceBuilder> { public V2beta1ContainerResourceMetricSourceBuilder() { this(false); } + public V2beta1ContainerResourceMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1ContainerResourceMetricSource(), validationEnabled); } - public V2beta1ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent fluent) { + + public V2beta1ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent fluent) { this(fluent, false); } - public V2beta1ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1ContainerResourceMetricSource(), validationEnabled); } - public V2beta1ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource instance) { + + public V2beta1ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource instance) { this(fluent, instance, false); } - public V2beta1ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainer(instance.getContainer()); fluent.withName(instance.getName()); @@ -29,13 +56,18 @@ public V2beta1ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi. fluent.withTargetAverageValue(instance.getTargetAverageValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource instance) { - this(instance,false); + + public V2beta1ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource instance) { + this(instance, false); } - public V2beta1ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainer(instance.getContainer()); this.withName(instance.getName()); @@ -44,10 +76,12 @@ public V2beta1ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi. this.withTargetAverageValue(instance.getTargetAverageValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource build() { V2beta1ContainerResourceMetricSource buildable = new V2beta1ContainerResourceMetricSource(); buildable.setContainer(fluent.getContainer()); @@ -56,18 +90,24 @@ public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource buildable.setTargetAverageValue(fluent.getTargetAverageValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V2beta1ContainerResourceMetricSourceBuilder that = (V2beta1ContainerResourceMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V2beta1ContainerResourceMetricSourceBuilder that = + (V2beta1ContainerResourceMetricSourceBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricSourceFluent.java index e211bda8bb..96dec37132 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricSourceFluent.java @@ -1,41 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1ContainerResourceMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1ContainerResourceMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getContainer(); + public A withContainer(java.lang.String container); + public java.lang.Boolean hasContainer(); - - /** - * Method is deprecated. use withContainer instead. - */ + + /** Method is deprecated. use withContainer instead. */ @java.lang.Deprecated public A withNewContainer(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Integer getTargetAverageUtilization(); + public A withTargetAverageUtilization(java.lang.Integer targetAverageUtilization); + public java.lang.Boolean hasTargetAverageUtilization(); + public io.kubernetes.client.custom.Quantity getTargetAverageValue(); + public A withTargetAverageValue(io.kubernetes.client.custom.Quantity targetAverageValue); + public java.lang.Boolean hasTargetAverageValue(); + public A withNewTargetAverageValue(java.lang.String value); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricSourceFluentImpl.java index 025a7296b2..10c96501db 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricSourceFluentImpl.java @@ -1,20 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - /** - * Generated - */ -public class V2beta1ContainerResourceMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent{ - public V2beta1ContainerResourceMetricSourceFluentImpl() { - } - public V2beta1ContainerResourceMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource instance) { +/** Generated */ +public class V2beta1ContainerResourceMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent { + public V2beta1ContainerResourceMetricSourceFluentImpl() {} + + public V2beta1ContainerResourceMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource instance) { this.withContainer(instance.getContainer()); this.withName(instance.getName()); @@ -22,79 +30,100 @@ public V2beta1ContainerResourceMetricSourceFluentImpl(io.kubernetes.client.opena this.withTargetAverageUtilization(instance.getTargetAverageUtilization()); this.withTargetAverageValue(instance.getTargetAverageValue()); - } + private java.lang.String container; private java.lang.String name; private java.lang.Integer targetAverageUtilization; private io.kubernetes.client.custom.Quantity targetAverageValue; + public java.lang.String getContainer() { return this.container; } + public A withContainer(java.lang.String container) { - this.container=container; return (A) this; + this.container = container; + return (A) this; } + public java.lang.Boolean hasContainer() { return this.container != null; } - - /** - * Method is deprecated. use withContainer instead. - */ + + /** Method is deprecated. use withContainer instead. */ @java.lang.Deprecated public A withNewContainer(java.lang.String original) { - return (A)withContainer(new String(original)); + return (A) withContainer(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Integer getTargetAverageUtilization() { return this.targetAverageUtilization; } + public A withTargetAverageUtilization(java.lang.Integer targetAverageUtilization) { - this.targetAverageUtilization=targetAverageUtilization; return (A) this; + this.targetAverageUtilization = targetAverageUtilization; + return (A) this; } + public java.lang.Boolean hasTargetAverageUtilization() { return this.targetAverageUtilization != null; } + public io.kubernetes.client.custom.Quantity getTargetAverageValue() { return this.targetAverageValue; } + public A withTargetAverageValue(io.kubernetes.client.custom.Quantity targetAverageValue) { - this.targetAverageValue=targetAverageValue; return (A) this; + this.targetAverageValue = targetAverageValue; + return (A) this; } + public java.lang.Boolean hasTargetAverageValue() { return this.targetAverageValue != null; } + public A withNewTargetAverageValue(java.lang.String value) { - return (A)withTargetAverageValue(new Quantity(value)); + return (A) withTargetAverageValue(new Quantity(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2beta1ContainerResourceMetricSourceFluentImpl that = (V2beta1ContainerResourceMetricSourceFluentImpl) o; - if (container != null ? !container.equals(that.container) :that.container != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (targetAverageUtilization != null ? !targetAverageUtilization.equals(that.targetAverageUtilization) :that.targetAverageUtilization != null) return false; - if (targetAverageValue != null ? !targetAverageValue.equals(that.targetAverageValue) :that.targetAverageValue != null) return false; + V2beta1ContainerResourceMetricSourceFluentImpl that = + (V2beta1ContainerResourceMetricSourceFluentImpl) o; + if (container != null ? !container.equals(that.container) : that.container != null) + return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (targetAverageUtilization != null + ? !targetAverageUtilization.equals(that.targetAverageUtilization) + : that.targetAverageUtilization != null) return false; + if (targetAverageValue != null + ? !targetAverageValue.equals(that.targetAverageValue) + : that.targetAverageValue != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(container, name, targetAverageUtilization, targetAverageValue, super.hashCode()); + return java.util.Objects.hash( + container, name, targetAverageUtilization, targetAverageValue, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricStatusBuilder.java index d4a9ea9934..9179c38765 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1ContainerResourceMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1ContainerResourceMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus, + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusBuilder> { public V2beta1ContainerResourceMetricStatusBuilder() { this(false); } + public V2beta1ContainerResourceMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1ContainerResourceMetricStatus(), validationEnabled); } - public V2beta1ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent fluent) { + + public V2beta1ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent fluent) { this(fluent, false); } - public V2beta1ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1ContainerResourceMetricStatus(), validationEnabled); } - public V2beta1ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus instance) { + + public V2beta1ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus instance) { this(fluent, instance, false); } - public V2beta1ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainer(instance.getContainer()); fluent.withCurrentAverageUtilization(instance.getCurrentAverageUtilization()); @@ -29,13 +56,18 @@ public V2beta1ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi. fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus instance) { - this(instance,false); + + public V2beta1ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus instance) { + this(instance, false); } - public V2beta1ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainer(instance.getContainer()); this.withCurrentAverageUtilization(instance.getCurrentAverageUtilization()); @@ -44,10 +76,12 @@ public V2beta1ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi. this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus build() { V2beta1ContainerResourceMetricStatus buildable = new V2beta1ContainerResourceMetricStatus(); buildable.setContainer(fluent.getContainer()); @@ -56,18 +90,24 @@ public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V2beta1ContainerResourceMetricStatusBuilder that = (V2beta1ContainerResourceMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V2beta1ContainerResourceMetricStatusBuilder that = + (V2beta1ContainerResourceMetricStatusBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricStatusFluent.java index 2295840170..fa5d829777 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricStatusFluent.java @@ -1,41 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1ContainerResourceMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1ContainerResourceMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getContainer(); + public A withContainer(java.lang.String container); + public java.lang.Boolean hasContainer(); - - /** - * Method is deprecated. use withContainer instead. - */ + + /** Method is deprecated. use withContainer instead. */ @java.lang.Deprecated public A withNewContainer(java.lang.String original); + public java.lang.Integer getCurrentAverageUtilization(); + public A withCurrentAverageUtilization(java.lang.Integer currentAverageUtilization); + public java.lang.Boolean hasCurrentAverageUtilization(); + public io.kubernetes.client.custom.Quantity getCurrentAverageValue(); + public A withCurrentAverageValue(io.kubernetes.client.custom.Quantity currentAverageValue); + public java.lang.Boolean hasCurrentAverageValue(); + public A withNewCurrentAverageValue(java.lang.String value); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricStatusFluentImpl.java index dd4300d375..a033434fa8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ContainerResourceMetricStatusFluentImpl.java @@ -1,20 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - /** - * Generated - */ -public class V2beta1ContainerResourceMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent{ - public V2beta1ContainerResourceMetricStatusFluentImpl() { - } - public V2beta1ContainerResourceMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus instance) { +/** Generated */ +public class V2beta1ContainerResourceMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent { + public V2beta1ContainerResourceMetricStatusFluentImpl() {} + + public V2beta1ContainerResourceMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus instance) { this.withContainer(instance.getContainer()); this.withCurrentAverageUtilization(instance.getCurrentAverageUtilization()); @@ -22,79 +30,100 @@ public V2beta1ContainerResourceMetricStatusFluentImpl(io.kubernetes.client.opena this.withCurrentAverageValue(instance.getCurrentAverageValue()); this.withName(instance.getName()); - } + private java.lang.String container; private java.lang.Integer currentAverageUtilization; private io.kubernetes.client.custom.Quantity currentAverageValue; private java.lang.String name; + public java.lang.String getContainer() { return this.container; } + public A withContainer(java.lang.String container) { - this.container=container; return (A) this; + this.container = container; + return (A) this; } + public java.lang.Boolean hasContainer() { return this.container != null; } - - /** - * Method is deprecated. use withContainer instead. - */ + + /** Method is deprecated. use withContainer instead. */ @java.lang.Deprecated public A withNewContainer(java.lang.String original) { - return (A)withContainer(new String(original)); + return (A) withContainer(new String(original)); } + public java.lang.Integer getCurrentAverageUtilization() { return this.currentAverageUtilization; } + public A withCurrentAverageUtilization(java.lang.Integer currentAverageUtilization) { - this.currentAverageUtilization=currentAverageUtilization; return (A) this; + this.currentAverageUtilization = currentAverageUtilization; + return (A) this; } + public java.lang.Boolean hasCurrentAverageUtilization() { return this.currentAverageUtilization != null; } + public io.kubernetes.client.custom.Quantity getCurrentAverageValue() { return this.currentAverageValue; } + public A withCurrentAverageValue(io.kubernetes.client.custom.Quantity currentAverageValue) { - this.currentAverageValue=currentAverageValue; return (A) this; + this.currentAverageValue = currentAverageValue; + return (A) this; } + public java.lang.Boolean hasCurrentAverageValue() { return this.currentAverageValue != null; } + public A withNewCurrentAverageValue(java.lang.String value) { - return (A)withCurrentAverageValue(new Quantity(value)); + return (A) withCurrentAverageValue(new Quantity(value)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2beta1ContainerResourceMetricStatusFluentImpl that = (V2beta1ContainerResourceMetricStatusFluentImpl) o; - if (container != null ? !container.equals(that.container) :that.container != null) return false; - if (currentAverageUtilization != null ? !currentAverageUtilization.equals(that.currentAverageUtilization) :that.currentAverageUtilization != null) return false; - if (currentAverageValue != null ? !currentAverageValue.equals(that.currentAverageValue) :that.currentAverageValue != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + V2beta1ContainerResourceMetricStatusFluentImpl that = + (V2beta1ContainerResourceMetricStatusFluentImpl) o; + if (container != null ? !container.equals(that.container) : that.container != null) + return false; + if (currentAverageUtilization != null + ? !currentAverageUtilization.equals(that.currentAverageUtilization) + : that.currentAverageUtilization != null) return false; + if (currentAverageValue != null + ? !currentAverageValue.equals(that.currentAverageValue) + : that.currentAverageValue != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(container, currentAverageUtilization, currentAverageValue, name, super.hashCode()); + return java.util.Objects.hash( + container, currentAverageUtilization, currentAverageValue, name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1CrossVersionObjectReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1CrossVersionObjectReferenceBuilder.java index d87520892d..43a91607ee 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1CrossVersionObjectReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1CrossVersionObjectReferenceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1CrossVersionObjectReferenceBuilder extends io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1CrossVersionObjectReferenceBuilder + extends io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference, + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder> { public V2beta1CrossVersionObjectReferenceBuilder() { this(false); } + public V2beta1CrossVersionObjectReferenceBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1CrossVersionObjectReference(), validationEnabled); } - public V2beta1CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent fluent) { + + public V2beta1CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent fluent) { this(fluent, false); } - public V2beta1CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1CrossVersionObjectReference(), validationEnabled); } - public V2beta1CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference instance) { + + public V2beta1CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference instance) { this(fluent, instance, false); } - public V2beta1CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference instance) { - this(instance,false); + + public V2beta1CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference instance) { + this(instance, false); } - public V2beta1CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference build() { V2beta1CrossVersionObjectReference buildable = new V2beta1CrossVersionObjectReference(); buildable.setApiVersion(fluent.getApiVersion()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference bu buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1CrossVersionObjectReferenceBuilder that = (V2beta1CrossVersionObjectReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1CrossVersionObjectReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1CrossVersionObjectReferenceFluent.java index 6938cf4ac7..a355893140 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1CrossVersionObjectReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1CrossVersionObjectReferenceFluent.java @@ -1,41 +1,48 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1CrossVersionObjectReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1CrossVersionObjectReferenceFluent< + A extends io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1CrossVersionObjectReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1CrossVersionObjectReferenceFluentImpl.java index 25b6ca780e..0b0a8d7fda 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1CrossVersionObjectReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1CrossVersionObjectReferenceFluentImpl.java @@ -1,90 +1,107 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2beta1CrossVersionObjectReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent{ - public V2beta1CrossVersionObjectReferenceFluentImpl() { - } - public V2beta1CrossVersionObjectReferenceFluentImpl(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference instance) { +/** Generated */ +public class V2beta1CrossVersionObjectReferenceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent { + public V2beta1CrossVersionObjectReferenceFluentImpl() {} + + public V2beta1CrossVersionObjectReferenceFluentImpl( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); this.withName(instance.getName()); - } + private java.lang.String apiVersion; private java.lang.String kind; private java.lang.String name; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2beta1CrossVersionObjectReferenceFluentImpl that = (V2beta1CrossVersionObjectReferenceFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + V2beta1CrossVersionObjectReferenceFluentImpl that = + (V2beta1CrossVersionObjectReferenceFluentImpl) o; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, name, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricSourceBuilder.java index f00d9d1738..bf7c2100f8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1ExternalMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1ExternalMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource, + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceBuilder> { public V2beta1ExternalMetricSourceBuilder() { this(false); } + public V2beta1ExternalMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1ExternalMetricSource(), validationEnabled); } - public V2beta1ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent fluent) { + + public V2beta1ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent fluent) { this(fluent, false); } - public V2beta1ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1ExternalMetricSource(), validationEnabled); } - public V2beta1ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource instance) { + + public V2beta1ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource instance) { this(fluent, instance, false); } - public V2beta1ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMetricName(instance.getMetricName()); fluent.withMetricSelector(instance.getMetricSelector()); @@ -29,13 +56,18 @@ public V2beta1ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2 fluent.withTargetValue(instance.getTargetValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource instance) { - this(instance,false); + + public V2beta1ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource instance) { + this(instance, false); } - public V2beta1ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMetricName(instance.getMetricName()); this.withMetricSelector(instance.getMetricSelector()); @@ -44,10 +76,12 @@ public V2beta1ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2 this.withTargetValue(instance.getTargetValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource build() { V2beta1ExternalMetricSource buildable = new V2beta1ExternalMetricSource(); buildable.setMetricName(fluent.getMetricName()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource build() { buildable.setTargetValue(fluent.getTargetValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1ExternalMetricSourceBuilder that = (V2beta1ExternalMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricSourceFluent.java index 29a5dbdba4..dc8d164fad 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricSourceFluent.java @@ -1,53 +1,89 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1ExternalMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1ExternalMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getMetricName(); + public A withMetricName(java.lang.String metricName); + public java.lang.Boolean hasMetricName(); - - /** - * Method is deprecated. use withMetricName instead. - */ + + /** Method is deprecated. use withMetricName instead. */ @java.lang.Deprecated public A withNewMetricName(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetricSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getMetricSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildMetricSelector(); + public A withMetricSelector(io.kubernetes.client.openapi.models.V1LabelSelector metricSelector); + public java.lang.Boolean hasMetricSelector(); - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested withNewMetricSelector(); - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested withNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested editMetricSelector(); - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested editOrNewMetricSelector(); - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested editOrNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested< + A> + withNewMetricSelector(); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested< + A> + withNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested< + A> + editMetricSelector(); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested< + A> + editOrNewMetricSelector(); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested< + A> + editOrNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + public io.kubernetes.client.custom.Quantity getTargetAverageValue(); + public A withTargetAverageValue(io.kubernetes.client.custom.Quantity targetAverageValue); + public java.lang.Boolean hasTargetAverageValue(); + public A withNewTargetAverageValue(java.lang.String value); + public io.kubernetes.client.custom.Quantity getTargetValue(); + public A withTargetValue(io.kubernetes.client.custom.Quantity targetValue); + public java.lang.Boolean hasTargetValue(); + public A withNewTargetValue(java.lang.String value); - public interface MetricSelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface MetricSelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent + .MetricSelectorNested< + N>> { public N and(); + public N endMetricSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricSourceFluentImpl.java index 1d3e6eb9b4..6a187b2a08 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricSourceFluentImpl.java @@ -1,20 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2beta1ExternalMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent{ - public V2beta1ExternalMetricSourceFluentImpl() { - } - public V2beta1ExternalMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource instance) { + +/** Generated */ +public class V2beta1ExternalMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent { + public V2beta1ExternalMetricSourceFluentImpl() {} + + public V2beta1ExternalMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource instance) { this.withMetricName(instance.getMetricName()); this.withMetricSelector(instance.getMetricSelector()); @@ -22,115 +30,176 @@ public V2beta1ExternalMetricSourceFluentImpl(io.kubernetes.client.openapi.models this.withTargetAverageValue(instance.getTargetAverageValue()); this.withTargetValue(instance.getTargetValue()); - } + private java.lang.String metricName; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder metricSelector; private io.kubernetes.client.custom.Quantity targetAverageValue; private io.kubernetes.client.custom.Quantity targetValue; + public java.lang.String getMetricName() { return this.metricName; } + public A withMetricName(java.lang.String metricName) { - this.metricName=metricName; return (A) this; + this.metricName = metricName; + return (A) this; } + public java.lang.Boolean hasMetricName() { return this.metricName != null; } - - /** - * Method is deprecated. use withMetricName instead. - */ + + /** Method is deprecated. use withMetricName instead. */ @java.lang.Deprecated public A withNewMetricName(java.lang.String original) { - return (A)withMetricName(new String(original)); + return (A) withMetricName(new String(original)); } - + /** * This method has been deprecated, please use method buildMetricSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getMetricSelector() { - return this.metricSelector!=null ?this.metricSelector.build():null; + return this.metricSelector != null ? this.metricSelector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildMetricSelector() { - return this.metricSelector!=null ?this.metricSelector.build():null; + return this.metricSelector != null ? this.metricSelector.build() : null; } + public A withMetricSelector(io.kubernetes.client.openapi.models.V1LabelSelector metricSelector) { _visitables.get("metricSelector").remove(this.metricSelector); - if (metricSelector!=null){ this.metricSelector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(metricSelector); _visitables.get("metricSelector").add(this.metricSelector);} return (A) this; + if (metricSelector != null) { + this.metricSelector = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(metricSelector); + _visitables.get("metricSelector").add(this.metricSelector); + } + return (A) this; } + public java.lang.Boolean hasMetricSelector() { return this.metricSelector != null; } - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested withNewMetricSelector() { - return new io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluentImpl.MetricSelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested< + A> + withNewMetricSelector() { + return new io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluentImpl + .MetricSelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested withNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluentImpl.MetricSelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested< + A> + withNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluentImpl + .MetricSelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested editMetricSelector() { + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested< + A> + editMetricSelector() { return withNewMetricSelectorLike(getMetricSelector()); } - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested editOrNewMetricSelector() { - return withNewMetricSelectorLike(getMetricSelector() != null ? getMetricSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested< + A> + editOrNewMetricSelector() { + return withNewMetricSelectorLike( + getMetricSelector() != null + ? getMetricSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested editOrNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewMetricSelectorLike(getMetricSelector() != null ? getMetricSelector(): item); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested< + A> + editOrNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewMetricSelectorLike(getMetricSelector() != null ? getMetricSelector() : item); } + public io.kubernetes.client.custom.Quantity getTargetAverageValue() { return this.targetAverageValue; } + public A withTargetAverageValue(io.kubernetes.client.custom.Quantity targetAverageValue) { - this.targetAverageValue=targetAverageValue; return (A) this; + this.targetAverageValue = targetAverageValue; + return (A) this; } + public java.lang.Boolean hasTargetAverageValue() { return this.targetAverageValue != null; } + public A withNewTargetAverageValue(java.lang.String value) { - return (A)withTargetAverageValue(new Quantity(value)); + return (A) withTargetAverageValue(new Quantity(value)); } + public io.kubernetes.client.custom.Quantity getTargetValue() { return this.targetValue; } + public A withTargetValue(io.kubernetes.client.custom.Quantity targetValue) { - this.targetValue=targetValue; return (A) this; + this.targetValue = targetValue; + return (A) this; } + public java.lang.Boolean hasTargetValue() { return this.targetValue != null; } + public A withNewTargetValue(java.lang.String value) { - return (A)withTargetValue(new Quantity(value)); + return (A) withTargetValue(new Quantity(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta1ExternalMetricSourceFluentImpl that = (V2beta1ExternalMetricSourceFluentImpl) o; - if (metricName != null ? !metricName.equals(that.metricName) :that.metricName != null) return false; - if (metricSelector != null ? !metricSelector.equals(that.metricSelector) :that.metricSelector != null) return false; - if (targetAverageValue != null ? !targetAverageValue.equals(that.targetAverageValue) :that.targetAverageValue != null) return false; - if (targetValue != null ? !targetValue.equals(that.targetValue) :that.targetValue != null) return false; + if (metricName != null ? !metricName.equals(that.metricName) : that.metricName != null) + return false; + if (metricSelector != null + ? !metricSelector.equals(that.metricSelector) + : that.metricSelector != null) return false; + if (targetAverageValue != null + ? !targetAverageValue.equals(that.targetAverageValue) + : that.targetAverageValue != null) return false; + if (targetValue != null ? !targetValue.equals(that.targetValue) : that.targetValue != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(metricName, metricSelector, targetAverageValue, targetValue, super.hashCode()); + return java.util.Objects.hash( + metricName, metricSelector, targetAverageValue, targetValue, super.hashCode()); } - public class MetricSelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent.MetricSelectorNested,io.kubernetes.client.fluent.Nested{ + + public class MetricSelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent + .MetricSelectorNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent + .MetricSelectorNested< + N>, + io.kubernetes.client.fluent.Nested { MetricSelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + MetricSelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V2beta1ExternalMetricSourceFluentImpl.this.withMetricSelector(builder.build()); } + public N endMetricSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricStatusBuilder.java index 7be2a916f2..1f48e59fcf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1ExternalMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1ExternalMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus, + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusBuilder> { public V2beta1ExternalMetricStatusBuilder() { this(false); } + public V2beta1ExternalMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1ExternalMetricStatus(), validationEnabled); } - public V2beta1ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent fluent) { + + public V2beta1ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent fluent) { this(fluent, false); } - public V2beta1ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1ExternalMetricStatus(), validationEnabled); } - public V2beta1ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus instance) { + + public V2beta1ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus instance) { this(fluent, instance, false); } - public V2beta1ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCurrentAverageValue(instance.getCurrentAverageValue()); fluent.withCurrentValue(instance.getCurrentValue()); @@ -29,13 +56,18 @@ public V2beta1ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2 fluent.withMetricSelector(instance.getMetricSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus instance) { - this(instance,false); + + public V2beta1ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus instance) { + this(instance, false); } - public V2beta1ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCurrentAverageValue(instance.getCurrentAverageValue()); this.withCurrentValue(instance.getCurrentValue()); @@ -44,10 +76,12 @@ public V2beta1ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2 this.withMetricSelector(instance.getMetricSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus build() { V2beta1ExternalMetricStatus buildable = new V2beta1ExternalMetricStatus(); buildable.setCurrentAverageValue(fluent.getCurrentAverageValue()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus build() { buildable.setMetricSelector(fluent.getMetricSelector()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1ExternalMetricStatusBuilder that = (V2beta1ExternalMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricStatusFluent.java index e461520d20..608cb283c0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricStatusFluent.java @@ -1,53 +1,89 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1ExternalMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1ExternalMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public io.kubernetes.client.custom.Quantity getCurrentAverageValue(); + public A withCurrentAverageValue(io.kubernetes.client.custom.Quantity currentAverageValue); + public java.lang.Boolean hasCurrentAverageValue(); + public A withNewCurrentAverageValue(java.lang.String value); + public io.kubernetes.client.custom.Quantity getCurrentValue(); + public A withCurrentValue(io.kubernetes.client.custom.Quantity currentValue); + public java.lang.Boolean hasCurrentValue(); + public A withNewCurrentValue(java.lang.String value); + public java.lang.String getMetricName(); + public A withMetricName(java.lang.String metricName); + public java.lang.Boolean hasMetricName(); - - /** - * Method is deprecated. use withMetricName instead. - */ + + /** Method is deprecated. use withMetricName instead. */ @java.lang.Deprecated public A withNewMetricName(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetricSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getMetricSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildMetricSelector(); + public A withMetricSelector(io.kubernetes.client.openapi.models.V1LabelSelector metricSelector); + public java.lang.Boolean hasMetricSelector(); - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested withNewMetricSelector(); - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested withNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested editMetricSelector(); - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested editOrNewMetricSelector(); - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested editOrNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public interface MetricSelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested< + A> + withNewMetricSelector(); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested< + A> + withNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested< + A> + editMetricSelector(); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested< + A> + editOrNewMetricSelector(); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested< + A> + editOrNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public interface MetricSelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent + .MetricSelectorNested< + N>> { public N and(); + public N endMetricSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricStatusFluentImpl.java index 50cecca919..7e676af645 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ExternalMetricStatusFluentImpl.java @@ -1,20 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2beta1ExternalMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent{ - public V2beta1ExternalMetricStatusFluentImpl() { - } - public V2beta1ExternalMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus instance) { + +/** Generated */ +public class V2beta1ExternalMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent { + public V2beta1ExternalMetricStatusFluentImpl() {} + + public V2beta1ExternalMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus instance) { this.withCurrentAverageValue(instance.getCurrentAverageValue()); this.withCurrentValue(instance.getCurrentValue()); @@ -22,115 +30,176 @@ public V2beta1ExternalMetricStatusFluentImpl(io.kubernetes.client.openapi.models this.withMetricName(instance.getMetricName()); this.withMetricSelector(instance.getMetricSelector()); - } + private io.kubernetes.client.custom.Quantity currentAverageValue; private io.kubernetes.client.custom.Quantity currentValue; private java.lang.String metricName; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder metricSelector; + public io.kubernetes.client.custom.Quantity getCurrentAverageValue() { return this.currentAverageValue; } + public A withCurrentAverageValue(io.kubernetes.client.custom.Quantity currentAverageValue) { - this.currentAverageValue=currentAverageValue; return (A) this; + this.currentAverageValue = currentAverageValue; + return (A) this; } + public java.lang.Boolean hasCurrentAverageValue() { return this.currentAverageValue != null; } + public A withNewCurrentAverageValue(java.lang.String value) { - return (A)withCurrentAverageValue(new Quantity(value)); + return (A) withCurrentAverageValue(new Quantity(value)); } + public io.kubernetes.client.custom.Quantity getCurrentValue() { return this.currentValue; } + public A withCurrentValue(io.kubernetes.client.custom.Quantity currentValue) { - this.currentValue=currentValue; return (A) this; + this.currentValue = currentValue; + return (A) this; } + public java.lang.Boolean hasCurrentValue() { return this.currentValue != null; } + public A withNewCurrentValue(java.lang.String value) { - return (A)withCurrentValue(new Quantity(value)); + return (A) withCurrentValue(new Quantity(value)); } + public java.lang.String getMetricName() { return this.metricName; } + public A withMetricName(java.lang.String metricName) { - this.metricName=metricName; return (A) this; + this.metricName = metricName; + return (A) this; } + public java.lang.Boolean hasMetricName() { return this.metricName != null; } - - /** - * Method is deprecated. use withMetricName instead. - */ + + /** Method is deprecated. use withMetricName instead. */ @java.lang.Deprecated public A withNewMetricName(java.lang.String original) { - return (A)withMetricName(new String(original)); + return (A) withMetricName(new String(original)); } - + /** * This method has been deprecated, please use method buildMetricSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getMetricSelector() { - return this.metricSelector!=null ?this.metricSelector.build():null; + return this.metricSelector != null ? this.metricSelector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildMetricSelector() { - return this.metricSelector!=null ?this.metricSelector.build():null; + return this.metricSelector != null ? this.metricSelector.build() : null; } + public A withMetricSelector(io.kubernetes.client.openapi.models.V1LabelSelector metricSelector) { _visitables.get("metricSelector").remove(this.metricSelector); - if (metricSelector!=null){ this.metricSelector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(metricSelector); _visitables.get("metricSelector").add(this.metricSelector);} return (A) this; + if (metricSelector != null) { + this.metricSelector = + new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(metricSelector); + _visitables.get("metricSelector").add(this.metricSelector); + } + return (A) this; } + public java.lang.Boolean hasMetricSelector() { return this.metricSelector != null; } - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested withNewMetricSelector() { - return new io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluentImpl.MetricSelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested< + A> + withNewMetricSelector() { + return new io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluentImpl + .MetricSelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested withNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluentImpl.MetricSelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested< + A> + withNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluentImpl + .MetricSelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested editMetricSelector() { + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested< + A> + editMetricSelector() { return withNewMetricSelectorLike(getMetricSelector()); } - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested editOrNewMetricSelector() { - return withNewMetricSelectorLike(getMetricSelector() != null ? getMetricSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested< + A> + editOrNewMetricSelector() { + return withNewMetricSelectorLike( + getMetricSelector() != null + ? getMetricSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested editOrNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewMetricSelectorLike(getMetricSelector() != null ? getMetricSelector(): item); + + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested< + A> + editOrNewMetricSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewMetricSelectorLike(getMetricSelector() != null ? getMetricSelector() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta1ExternalMetricStatusFluentImpl that = (V2beta1ExternalMetricStatusFluentImpl) o; - if (currentAverageValue != null ? !currentAverageValue.equals(that.currentAverageValue) :that.currentAverageValue != null) return false; - if (currentValue != null ? !currentValue.equals(that.currentValue) :that.currentValue != null) return false; - if (metricName != null ? !metricName.equals(that.metricName) :that.metricName != null) return false; - if (metricSelector != null ? !metricSelector.equals(that.metricSelector) :that.metricSelector != null) return false; + if (currentAverageValue != null + ? !currentAverageValue.equals(that.currentAverageValue) + : that.currentAverageValue != null) return false; + if (currentValue != null ? !currentValue.equals(that.currentValue) : that.currentValue != null) + return false; + if (metricName != null ? !metricName.equals(that.metricName) : that.metricName != null) + return false; + if (metricSelector != null + ? !metricSelector.equals(that.metricSelector) + : that.metricSelector != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(currentAverageValue, currentValue, metricName, metricSelector, super.hashCode()); + return java.util.Objects.hash( + currentAverageValue, currentValue, metricName, metricSelector, super.hashCode()); } - public class MetricSelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent.MetricSelectorNested,io.kubernetes.client.fluent.Nested{ + + public class MetricSelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent + .MetricSelectorNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent + .MetricSelectorNested< + N>, + io.kubernetes.client.fluent.Nested { MetricSelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + MetricSelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V2beta1ExternalMetricStatusFluentImpl.this.withMetricSelector(builder.build()); } + public N endMetricSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerBuilder.java index c329fca27f..271a187ed5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1HorizontalPodAutoscalerBuilder extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1HorizontalPodAutoscalerBuilder + extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder> { public V2beta1HorizontalPodAutoscalerBuilder() { this(false); } + public V2beta1HorizontalPodAutoscalerBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1HorizontalPodAutoscaler(), validationEnabled); } - public V2beta1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent fluent) { + + public V2beta1HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent fluent) { this(fluent, false); } - public V2beta1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1HorizontalPodAutoscaler(), validationEnabled); } - public V2beta1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent fluent,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler instance) { + + public V2beta1HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent fluent, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler instance) { this(fluent, instance, false); } - public V2beta1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent fluent,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent fluent, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V2beta1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler instance) { - this(instance,false); + + public V2beta1HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler instance) { + this(instance, false); } - public V2beta1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V2beta1HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler build() { V2beta1HorizontalPodAutoscaler buildable = new V2beta1HorizontalPodAutoscaler(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler build( buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1HorizontalPodAutoscalerBuilder that = (V2beta1HorizontalPodAutoscalerBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerConditionBuilder.java index d9489596f9..26b797808a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1HorizontalPodAutoscalerConditionBuilder extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1HorizontalPodAutoscalerConditionBuilder + extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder> { public V2beta1HorizontalPodAutoscalerConditionBuilder() { this(false); } + public V2beta1HorizontalPodAutoscalerConditionBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1HorizontalPodAutoscalerCondition(), validationEnabled); } - public V2beta1HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent fluent) { + + public V2beta1HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent fluent) { this(fluent, false); } - public V2beta1HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1HorizontalPodAutoscalerCondition(), validationEnabled); } - public V2beta1HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent fluent,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition instance) { + + public V2beta1HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent fluent, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition instance) { this(fluent, instance, false); } - public V2beta1HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent fluent,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent fluent, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +58,18 @@ public V2beta1HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.opena fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition instance) { - this(instance,false); + + public V2beta1HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition instance) { + this(instance, false); } - public V2beta1HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,12 +80,15 @@ public V2beta1HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.opena this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition build() { - V2beta1HorizontalPodAutoscalerCondition buildable = new V2beta1HorizontalPodAutoscalerCondition(); + V2beta1HorizontalPodAutoscalerCondition buildable = + new V2beta1HorizontalPodAutoscalerCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); buildable.setMessage(fluent.getMessage()); buildable.setReason(fluent.getReason()); @@ -61,18 +96,24 @@ public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditi buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V2beta1HorizontalPodAutoscalerConditionBuilder that = (V2beta1HorizontalPodAutoscalerConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V2beta1HorizontalPodAutoscalerConditionBuilder that = + (V2beta1HorizontalPodAutoscalerConditionBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerConditionFluent.java index e498cff037..2e082215cb 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerConditionFluent.java @@ -1,54 +1,65 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1HorizontalPodAutoscalerConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1HorizontalPodAutoscalerConditionFluent< + A extends + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerConditionFluentImpl.java index e659a385b7..8db83fd278 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerConditionFluentImpl.java @@ -1,19 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V2beta1HorizontalPodAutoscalerConditionFluentImpl< + A extends + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent< + A> { + public V2beta1HorizontalPodAutoscalerConditionFluentImpl() {} - /** - * Generated - */ -public class V2beta1HorizontalPodAutoscalerConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent{ - public V2beta1HorizontalPodAutoscalerConditionFluentImpl() { - } - public V2beta1HorizontalPodAutoscalerConditionFluentImpl(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition instance) { + public V2beta1HorizontalPodAutoscalerConditionFluentImpl( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,103 +32,120 @@ public V2beta1HorizontalPodAutoscalerConditionFluentImpl(io.kubernetes.client.op this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2beta1HorizontalPodAutoscalerConditionFluentImpl that = (V2beta1HorizontalPodAutoscalerConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + V2beta1HorizontalPodAutoscalerConditionFluentImpl that = + (V2beta1HorizontalPodAutoscalerConditionFluentImpl) o; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerFluent.java index 7289d7220b..099468fbf9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerFluent.java @@ -1,93 +1,160 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1HorizontalPodAutoscalerFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1HorizontalPodAutoscalerFluent< + A extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec getSpec(); + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec item); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec item); - + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpecLike( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus getStatus(); + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus buildStatus(); - public A withStatus(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus status); + + public A withStatus( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus item); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested + withNewStatusLike( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested< + N>> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested< + N>> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerFluentImpl.java index d2dfbfa22e..96b3310520 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta1HorizontalPodAutoscalerFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent { + public V2beta1HorizontalPodAutoscalerFluentImpl() {} - /** - * Generated - */ -public class V2beta1HorizontalPodAutoscalerFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent{ - public V2beta1HorizontalPodAutoscalerFluentImpl() { - } - public V2beta1HorizontalPodAutoscalerFluentImpl(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler instance) { + public V2beta1HorizontalPodAutoscalerFluentImpl( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,332 @@ public V2beta1HorizontalPodAutoscalerFluentImpl(io.kubernetes.client.openapi.mod this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecBuilder spec; private io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec item) { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec item) { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpecLike( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } - public A withStatus(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus status) { + + public A withStatus( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusBuilder( + status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus item) { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested + withNewStatusLike( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus item) { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta1HorizontalPodAutoscalerFluentImpl that = (V2beta1HorizontalPodAutoscalerFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V2beta1HorizontalPodAutoscalerFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent + .SpecNested< + N>, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecBuilder( + this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecBuilder builder; + public N and() { return (N) V2beta1HorizontalPodAutoscalerFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested,io.kubernetes.client.fluent.Nested{ - StatusNestedImpl(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusBuilder(this, item); + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent + .StatusNested< + N>, + io.kubernetes.client.fluent.Nested { + StatusNestedImpl( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus item) { + this.builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusBuilder( + this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusBuilder builder; + public N and() { return (N) V2beta1HorizontalPodAutoscalerFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerListBuilder.java index 2a5f2a53b7..b4b409256b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1HorizontalPodAutoscalerListBuilder extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1HorizontalPodAutoscalerListBuilder + extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerList, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListBuilder> { public V2beta1HorizontalPodAutoscalerListBuilder() { this(false); } + public V2beta1HorizontalPodAutoscalerListBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1HorizontalPodAutoscalerList(), validationEnabled); } - public V2beta1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent fluent) { + + public V2beta1HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent fluent) { this(fluent, false); } - public V2beta1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1HorizontalPodAutoscalerList(), validationEnabled); } - public V2beta1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent fluent,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerList instance) { + + public V2beta1HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent fluent, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerList instance) { this(fluent, instance, false); } - public V2beta1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent fluent,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent fluent, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V2beta1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.mo fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerList instance) { - this(instance,false); + + public V2beta1HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerList instance) { + this(instance, false); } - public V2beta1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V2beta1HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.mo this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerList build() { V2beta1HorizontalPodAutoscalerList buildable = new V2beta1HorizontalPodAutoscalerList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerList bu buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1HorizontalPodAutoscalerListBuilder that = (V2beta1HorizontalPodAutoscalerListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerListFluent.java index 5dc0fba501..6db74a5e87 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerListFluent.java @@ -1,95 +1,187 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1HorizontalPodAutoscalerListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1HorizontalPodAutoscalerListFluent< + A extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item); + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item); + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item); + public A addToItems(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler... items); - public A addAllToItems(java.util.Collection items); - public A removeFromItems(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A addAllToItems( + java.util.Collection + items); + + public A removeFromItems( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler... items); + + public A removeAllFromItems( + java.util.Collection + items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getItems(); - public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler buildItem(java.lang.Integer index); + public java.util.List + getItems(); + + public java.util.List + buildItems(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler buildFirstItem(); + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler buildLastItem(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent>{ + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + editMetadata(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluent< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerListFluentImpl.java index e41d604652..4041701b19 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V2beta1HorizontalPodAutoscalerListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent{ - public V2beta1HorizontalPodAutoscalerListFluentImpl() { - } - public V2beta1HorizontalPodAutoscalerListFluentImpl(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerList instance) { + +/** Generated */ +public class V2beta1HorizontalPodAutoscalerListFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent { + public V2beta1HorizontalPodAutoscalerListFluentImpl() {} + + public V2beta1HorizontalPodAutoscalerListFluentImpl( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,233 +31,453 @@ public V2beta1HorizontalPodAutoscalerListFluentImpl(io.kubernetes.client.openapi this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder> + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder>(); + } + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder>(); + } + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection + items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A removeFromItems(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler... items) { - for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeFromItems( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler... items) { + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getItems() { + public java.util.List + getItems() { return items != null ? build(items) : null; } - public java.util.List buildItems() { + + public java.util.List + buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item) { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item) { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item) { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item) { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2beta1HorizontalPodAutoscalerListFluentImpl that = (V2beta1HorizontalPodAutoscalerListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + V2beta1HorizontalPodAutoscalerListFluentImpl that = + (V2beta1HorizontalPodAutoscalerListFluentImpl) o; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.ItemsNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscaler item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2beta1HorizontalPodAutoscalerListFluentImpl.this.setToItems(index,builder.build()); + return (N) + V2beta1HorizontalPodAutoscalerListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V2beta1HorizontalPodAutoscalerListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerSpecBuilder.java index 0240a80111..12ebde9513 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1HorizontalPodAutoscalerSpecBuilder extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1HorizontalPodAutoscalerSpecBuilder + extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecBuilder> { public V2beta1HorizontalPodAutoscalerSpecBuilder() { this(false); } + public V2beta1HorizontalPodAutoscalerSpecBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1HorizontalPodAutoscalerSpec(), validationEnabled); } - public V2beta1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent fluent) { + + public V2beta1HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent fluent) { this(fluent, false); } - public V2beta1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1HorizontalPodAutoscalerSpec(), validationEnabled); } - public V2beta1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent fluent,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec instance) { + + public V2beta1HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent fluent, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec instance) { this(fluent, instance, false); } - public V2beta1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent fluent,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent fluent, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMaxReplicas(instance.getMaxReplicas()); fluent.withMetrics(instance.getMetrics()); @@ -29,13 +56,18 @@ public V2beta1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.mo fluent.withScaleTargetRef(instance.getScaleTargetRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec instance) { - this(instance,false); + + public V2beta1HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec instance) { + this(instance, false); } - public V2beta1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMaxReplicas(instance.getMaxReplicas()); this.withMetrics(instance.getMetrics()); @@ -44,10 +76,12 @@ public V2beta1HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.mo this.withScaleTargetRef(instance.getScaleTargetRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec build() { V2beta1HorizontalPodAutoscalerSpec buildable = new V2beta1HorizontalPodAutoscalerSpec(); buildable.setMaxReplicas(fluent.getMaxReplicas()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec bu buildable.setScaleTargetRef(fluent.getScaleTargetRef()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1HorizontalPodAutoscalerSpecBuilder that = (V2beta1HorizontalPodAutoscalerSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerSpecFluent.java index 6a93a1c3c5..1872647bc2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerSpecFluent.java @@ -1,83 +1,177 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1HorizontalPodAutoscalerSpecFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1HorizontalPodAutoscalerSpecFluent< + A extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getMaxReplicas(); + public A withMaxReplicas(java.lang.Integer maxReplicas); + public java.lang.Boolean hasMaxReplicas(); - public A addToMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1MetricSpec item); - public A setToMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1MetricSpec item); + + public A addToMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricSpec item); + + public A setToMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricSpec item); + public A addToMetrics(io.kubernetes.client.openapi.models.V2beta1MetricSpec... items); - public A addAllToMetrics(java.util.Collection items); + + public A addAllToMetrics( + java.util.Collection items); + public A removeFromMetrics(io.kubernetes.client.openapi.models.V2beta1MetricSpec... items); - public A removeAllFromMetrics(java.util.Collection items); - public A removeMatchingFromMetrics(java.util.function.Predicate predicate); - + + public A removeAllFromMetrics( + java.util.Collection items); + + public A removeMatchingFromMetrics( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildMetrics instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getMetrics(); + public java.util.List buildMetrics(); + public io.kubernetes.client.openapi.models.V2beta1MetricSpec buildMetric(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V2beta1MetricSpec buildFirstMetric(); + public io.kubernetes.client.openapi.models.V2beta1MetricSpec buildLastMetric(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpec buildMatchingMetric(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMetric(java.util.function.Predicate predicate); - public A withMetrics(java.util.List metrics); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpec buildMatchingMetric( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingMetric( + java.util.function.Predicate + predicate); + + public A withMetrics( + java.util.List metrics); + public A withMetrics(io.kubernetes.client.openapi.models.V2beta1MetricSpec... metrics); + public java.lang.Boolean hasMetrics(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested addNewMetric(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested addNewMetricLike(io.kubernetes.client.openapi.models.V2beta1MetricSpec item); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested setNewMetricLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1MetricSpec item); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested editMetric(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested editFirstMetric(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested editLastMetric(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested editMatchingMetric(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + addNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + addNewMetricLike(io.kubernetes.client.openapi.models.V2beta1MetricSpec item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + setNewMetricLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricSpec item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editMetric(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editFirstMetric(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editLastMetric(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editMatchingMetric( + java.util.function.Predicate + predicate); + public java.lang.Integer getMinReplicas(); + public A withMinReplicas(java.lang.Integer minReplicas); + public java.lang.Boolean hasMinReplicas(); - + /** * This method has been deprecated, please use method buildScaleTargetRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference getScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference buildScaleTargetRef(); - public A withScaleTargetRef(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference scaleTargetRef); + + public io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference + buildScaleTargetRef(); + + public A withScaleTargetRef( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference scaleTargetRef); + public java.lang.Boolean hasScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested withNewScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested withNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item); - public interface MetricsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent>{ + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRef(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editScaleTargetRef(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRef(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item); + + public interface MetricsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .MetricsNested< + N>> { public N and(); + public N endMetric(); - } - public interface ScaleTargetRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent>{ + + public interface ScaleTargetRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + N>> { public N and(); + public N endScaleTargetRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerSpecFluentImpl.java index b074e3a4f8..b082880dbf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerSpecFluentImpl.java @@ -1,25 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V2beta1HorizontalPodAutoscalerSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent{ - public V2beta1HorizontalPodAutoscalerSpecFluentImpl() { - } - public V2beta1HorizontalPodAutoscalerSpecFluentImpl(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec instance) { + +/** Generated */ +public class V2beta1HorizontalPodAutoscalerSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent { + public V2beta1HorizontalPodAutoscalerSpecFluentImpl() {} + + public V2beta1HorizontalPodAutoscalerSpecFluentImpl( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpec instance) { this.withMaxReplicas(instance.getMaxReplicas()); this.withMetrics(instance.getMetrics()); @@ -27,49 +31,121 @@ public V2beta1HorizontalPodAutoscalerSpecFluentImpl(io.kubernetes.client.openapi this.withMinReplicas(instance.getMinReplicas()); this.withScaleTargetRef(instance.getScaleTargetRef()); - } + private java.lang.Integer maxReplicas; private java.util.ArrayList metrics; private java.lang.Integer minReplicas; - private io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder scaleTargetRef; + private io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder + scaleTargetRef; + public java.lang.Integer getMaxReplicas() { return this.maxReplicas; } + public A withMaxReplicas(java.lang.Integer maxReplicas) { - this.maxReplicas=maxReplicas; return (A) this; + this.maxReplicas = maxReplicas; + return (A) this; } + public java.lang.Boolean hasMaxReplicas() { return this.maxReplicas != null; } - public A addToMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1MetricSpec item) { - if (this.metrics == null) {this.metrics = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(item);_visitables.get("metrics").add(index >= 0 ? index : _visitables.get("metrics").size(), builder);this.metrics.add(index >= 0 ? index : metrics.size(), builder); return (A)this; + + public A addToMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricSpec item) { + if (this.metrics == null) { + this.metrics = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(item); + _visitables.get("metrics").add(index >= 0 ? index : _visitables.get("metrics").size(), builder); + this.metrics.add(index >= 0 ? index : metrics.size(), builder); + return (A) this; } - public A setToMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1MetricSpec item) { - if (this.metrics == null) {this.metrics = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(item); - if (index < 0 || index >= _visitables.get("metrics").size()) { _visitables.get("metrics").add(builder); } else { _visitables.get("metrics").set(index, builder);} - if (index < 0 || index >= metrics.size()) { metrics.add(builder); } else { metrics.set(index, builder);} - return (A)this; + + public A setToMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricSpec item) { + if (this.metrics == null) { + this.metrics = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(item); + if (index < 0 || index >= _visitables.get("metrics").size()) { + _visitables.get("metrics").add(builder); + } else { + _visitables.get("metrics").set(index, builder); + } + if (index < 0 || index >= metrics.size()) { + metrics.add(builder); + } else { + metrics.set(index, builder); + } + return (A) this; } + public A addToMetrics(io.kubernetes.client.openapi.models.V2beta1MetricSpec... items) { - if (this.metrics == null) {this.metrics = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta1MetricSpec item : items) {io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(item);_visitables.get("metrics").add(builder);this.metrics.add(builder);} return (A)this; + if (this.metrics == null) { + this.metrics = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2beta1MetricSpec item : items) { + io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(item); + _visitables.get("metrics").add(builder); + this.metrics.add(builder); + } + return (A) this; } - public A addAllToMetrics(java.util.Collection items) { - if (this.metrics == null) {this.metrics = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta1MetricSpec item : items) {io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(item);_visitables.get("metrics").add(builder);this.metrics.add(builder);} return (A)this; + + public A addAllToMetrics( + java.util.Collection items) { + if (this.metrics == null) { + this.metrics = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2beta1MetricSpec item : items) { + io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(item); + _visitables.get("metrics").add(builder); + this.metrics.add(builder); + } + return (A) this; } + public A removeFromMetrics(io.kubernetes.client.openapi.models.V2beta1MetricSpec... items) { - for (io.kubernetes.client.openapi.models.V2beta1MetricSpec item : items) {io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(item);_visitables.get("metrics").remove(builder);if (this.metrics != null) {this.metrics.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V2beta1MetricSpec item : items) { + io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(item); + _visitables.get("metrics").remove(builder); + if (this.metrics != null) { + this.metrics.remove(builder); + } + } + return (A) this; } - public A removeAllFromMetrics(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2beta1MetricSpec item : items) {io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(item);_visitables.get("metrics").remove(builder);if (this.metrics != null) {this.metrics.remove(builder);}} return (A)this; + + public A removeAllFromMetrics( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V2beta1MetricSpec item : items) { + io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(item); + _visitables.get("metrics").remove(builder); + if (this.metrics != null) { + this.metrics.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromMetrics(java.util.function.Predicate predicate) { + + public A removeMatchingFromMetrics( + java.util.function.Predicate + predicate) { if (metrics == null) return (A) this; - final Iterator each = metrics.iterator(); + final Iterator each = + metrics.iterator(); final List visitables = _visitables.get("metrics"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder = each.next(); @@ -78,166 +154,324 @@ public A removeMatchingFromMetrics(java.util.function.Predicate getMetrics() { return metrics != null ? build(metrics) : null; } + public java.util.List buildMetrics() { return metrics != null ? build(metrics) : null; } - public io.kubernetes.client.openapi.models.V2beta1MetricSpec buildMetric(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2beta1MetricSpec buildMetric( + java.lang.Integer index) { return this.metrics.get(index).build(); } + public io.kubernetes.client.openapi.models.V2beta1MetricSpec buildFirstMetric() { return this.metrics.get(0).build(); } + public io.kubernetes.client.openapi.models.V2beta1MetricSpec buildLastMetric() { return this.metrics.get(metrics.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpec buildMatchingMetric(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder item: metrics) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2beta1MetricSpec buildMatchingMetric( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder item : metrics) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingMetric(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder item: metrics) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMetric( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder item : metrics) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withMetrics(java.util.List metrics) { - if (this.metrics != null) { _visitables.get("metrics").removeAll(this.metrics);} - if (metrics != null) {this.metrics = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2beta1MetricSpec item : metrics){this.addToMetrics(item);}} else { this.metrics = null;} return (A) this; + + public A withMetrics( + java.util.List metrics) { + if (this.metrics != null) { + _visitables.get("metrics").removeAll(this.metrics); + } + if (metrics != null) { + this.metrics = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2beta1MetricSpec item : metrics) { + this.addToMetrics(item); + } + } else { + this.metrics = null; + } + return (A) this; } + public A withMetrics(io.kubernetes.client.openapi.models.V2beta1MetricSpec... metrics) { - if (this.metrics != null) {this.metrics.clear();} - if (metrics != null) {for (io.kubernetes.client.openapi.models.V2beta1MetricSpec item :metrics){ this.addToMetrics(item);}} return (A) this; + if (this.metrics != null) { + this.metrics.clear(); + } + if (metrics != null) { + for (io.kubernetes.client.openapi.models.V2beta1MetricSpec item : metrics) { + this.addToMetrics(item); + } + } + return (A) this; } + public java.lang.Boolean hasMetrics() { return metrics != null && !metrics.isEmpty(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested addNewMetric() { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl.MetricsNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + addNewMetric() { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl + .MetricsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested addNewMetricLike(io.kubernetes.client.openapi.models.V2beta1MetricSpec item) { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl.MetricsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + addNewMetricLike(io.kubernetes.client.openapi.models.V2beta1MetricSpec item) { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl + .MetricsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested setNewMetricLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1MetricSpec item) { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl.MetricsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + setNewMetricLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricSpec item) { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl + .MetricsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested editMetric(java.lang.Integer index) { - if (metrics.size() <= index) throw new RuntimeException("Can't edit metrics. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editMetric(java.lang.Integer index) { + if (metrics.size() <= index) + throw new RuntimeException("Can't edit metrics. Index exceeds size."); return setNewMetricLike(index, buildMetric(index)); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested editFirstMetric() { - if (metrics.size() == 0) throw new RuntimeException("Can't edit first metrics. The list is empty."); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editFirstMetric() { + if (metrics.size() == 0) + throw new RuntimeException("Can't edit first metrics. The list is empty."); return setNewMetricLike(0, buildMetric(0)); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested editLastMetric() { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editLastMetric() { int index = metrics.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last metrics. The list is empty."); return setNewMetricLike(index, buildMetric(index)); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested editMatchingMetric(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editMatchingMetric( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewScaleTargetRef() { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl.ScaleTargetRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRef() { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl + .ScaleTargetRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested withNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl.ScaleTargetRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluentImpl + .ScaleTargetRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editScaleTargetRef() { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editScaleTargetRef() { return withNewScaleTargetRefLike(getScaleTargetRef()); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRef() { - return withNewScaleTargetRefLike(getScaleTargetRef() != null ? getScaleTargetRef(): new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRef() { + return withNewScaleTargetRefLike( + getScaleTargetRef() != null + ? getScaleTargetRef() + : new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { - return withNewScaleTargetRefLike(getScaleTargetRef() != null ? getScaleTargetRef(): item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { + return withNewScaleTargetRefLike(getScaleTargetRef() != null ? getScaleTargetRef() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2beta1HorizontalPodAutoscalerSpecFluentImpl that = (V2beta1HorizontalPodAutoscalerSpecFluentImpl) o; - if (maxReplicas != null ? !maxReplicas.equals(that.maxReplicas) :that.maxReplicas != null) return false; - if (metrics != null ? !metrics.equals(that.metrics) :that.metrics != null) return false; - if (minReplicas != null ? !minReplicas.equals(that.minReplicas) :that.minReplicas != null) return false; - if (scaleTargetRef != null ? !scaleTargetRef.equals(that.scaleTargetRef) :that.scaleTargetRef != null) return false; + V2beta1HorizontalPodAutoscalerSpecFluentImpl that = + (V2beta1HorizontalPodAutoscalerSpecFluentImpl) o; + if (maxReplicas != null ? !maxReplicas.equals(that.maxReplicas) : that.maxReplicas != null) + return false; + if (metrics != null ? !metrics.equals(that.metrics) : that.metrics != null) return false; + if (minReplicas != null ? !minReplicas.equals(that.minReplicas) : that.minReplicas != null) + return false; + if (scaleTargetRef != null + ? !scaleTargetRef.equals(that.scaleTargetRef) + : that.scaleTargetRef != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(maxReplicas, metrics, minReplicas, scaleTargetRef, super.hashCode()); + return java.util.Objects.hash( + maxReplicas, metrics, minReplicas, scaleTargetRef, super.hashCode()); } - public class MetricsNestedImpl extends io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.MetricsNested,io.kubernetes.client.fluent.Nested{ - MetricsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1MetricSpec item) { + + public class MetricsNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .MetricsNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .MetricsNested< + N>, + io.kubernetes.client.fluent.Nested { + MetricsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricSpec item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(this, item); } + MetricsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2beta1HorizontalPodAutoscalerSpecFluentImpl.this.setToMetrics(index,builder.build()); + return (N) + V2beta1HorizontalPodAutoscalerSpecFluentImpl.this.setToMetrics(index, builder.build()); } + public N endMetric() { return and(); } - } - public class ScaleTargetRefNestedImpl extends io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested,io.kubernetes.client.fluent.Nested{ - ScaleTargetRefNestedImpl(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder(this, item); + + public class ScaleTargetRefNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + N>, + io.kubernetes.client.fluent.Nested { + ScaleTargetRefNestedImpl( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { + this.builder = + new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder( + this, item); } + ScaleTargetRefNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder builder; + public N and() { - return (N) V2beta1HorizontalPodAutoscalerSpecFluentImpl.this.withScaleTargetRef(builder.build()); + return (N) + V2beta1HorizontalPodAutoscalerSpecFluentImpl.this.withScaleTargetRef(builder.build()); } + public N endScaleTargetRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerStatusBuilder.java index 8fb4980b61..1150450605 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1HorizontalPodAutoscalerStatusBuilder extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1HorizontalPodAutoscalerStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusBuilder> { public V2beta1HorizontalPodAutoscalerStatusBuilder() { this(false); } + public V2beta1HorizontalPodAutoscalerStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1HorizontalPodAutoscalerStatus(), validationEnabled); } - public V2beta1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent fluent) { + + public V2beta1HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent fluent) { this(fluent, false); } - public V2beta1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1HorizontalPodAutoscalerStatus(), validationEnabled); } - public V2beta1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus instance) { + + public V2beta1HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus instance) { this(fluent, instance, false); } - public V2beta1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditions(instance.getConditions()); fluent.withCurrentMetrics(instance.getCurrentMetrics()); @@ -33,13 +60,18 @@ public V2beta1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi. fluent.withObservedGeneration(instance.getObservedGeneration()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus instance) { - this(instance,false); + + public V2beta1HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus instance) { + this(instance, false); } - public V2beta1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditions(instance.getConditions()); this.withCurrentMetrics(instance.getCurrentMetrics()); @@ -52,10 +84,12 @@ public V2beta1HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi. this.withObservedGeneration(instance.getObservedGeneration()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus build() { V2beta1HorizontalPodAutoscalerStatus buildable = new V2beta1HorizontalPodAutoscalerStatus(); buildable.setConditions(fluent.getConditions()); @@ -66,18 +100,24 @@ public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus buildable.setObservedGeneration(fluent.getObservedGeneration()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V2beta1HorizontalPodAutoscalerStatusBuilder that = (V2beta1HorizontalPodAutoscalerStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V2beta1HorizontalPodAutoscalerStatusBuilder that = + (V2beta1HorizontalPodAutoscalerStatusBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerStatusFluent.java index efc10eaee6..5d205af961 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerStatusFluent.java @@ -1,106 +1,272 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.lang.Long; -import java.util.Collection; - - /** - * Generated - */ -public interface V2beta1HorizontalPodAutoscalerStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item); - public A addToConditions(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition... items); - public A addAllToConditions(java.util.Collection items); - public A removeFromConditions(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - +/** Generated */ +public interface V2beta1HorizontalPodAutoscalerStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item); + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item); + + public A addToConditions( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition... items); + + public A addAllToConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition> + items); + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition... items); + + public A removeAllFromConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition> + items); + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder> + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition buildCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition buildFirstCondition(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); - public A withConditions(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition... conditions); + public java.util.List + getConditions(); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition buildCondition( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition + buildFirstCondition(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition + buildLastCondition(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V2beta1HorizontalPodAutoscalerConditionBuilder> + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder> + predicate); + + public A withConditions( + java.util.List + conditions); + + public A withConditions( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - public A addToCurrentMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1MetricStatus item); - public A setToCurrentMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1MetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + addNewCondition(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editLastCondition(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V2beta1HorizontalPodAutoscalerConditionBuilder> + predicate); + + public A addToCurrentMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricStatus item); + + public A setToCurrentMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricStatus item); + public A addToCurrentMetrics(io.kubernetes.client.openapi.models.V2beta1MetricStatus... items); - public A addAllToCurrentMetrics(java.util.Collection items); - public A removeFromCurrentMetrics(io.kubernetes.client.openapi.models.V2beta1MetricStatus... items); - public A removeAllFromCurrentMetrics(java.util.Collection items); - public A removeMatchingFromCurrentMetrics(java.util.function.Predicate predicate); - + + public A addAllToCurrentMetrics( + java.util.Collection items); + + public A removeFromCurrentMetrics( + io.kubernetes.client.openapi.models.V2beta1MetricStatus... items); + + public A removeAllFromCurrentMetrics( + java.util.Collection items); + + public A removeMatchingFromCurrentMetrics( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildCurrentMetrics instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getCurrentMetrics(); - public java.util.List buildCurrentMetrics(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatus buildCurrentMetric(java.lang.Integer index); + public java.util.List + getCurrentMetrics(); + + public java.util.List + buildCurrentMetrics(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatus buildCurrentMetric( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V2beta1MetricStatus buildFirstCurrentMetric(); + public io.kubernetes.client.openapi.models.V2beta1MetricStatus buildLastCurrentMetric(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatus buildMatchingCurrentMetric(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCurrentMetric(java.util.function.Predicate predicate); - public A withCurrentMetrics(java.util.List currentMetrics); - public A withCurrentMetrics(io.kubernetes.client.openapi.models.V2beta1MetricStatus... currentMetrics); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatus buildMatchingCurrentMetric( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCurrentMetric( + java.util.function.Predicate + predicate); + + public A withCurrentMetrics( + java.util.List currentMetrics); + + public A withCurrentMetrics( + io.kubernetes.client.openapi.models.V2beta1MetricStatus... currentMetrics); + public java.lang.Boolean hasCurrentMetrics(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested addNewCurrentMetric(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested addNewCurrentMetricLike(io.kubernetes.client.openapi.models.V2beta1MetricStatus item); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested setNewCurrentMetricLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1MetricStatus item); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editCurrentMetric(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editFirstCurrentMetric(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editLastCurrentMetric(); - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editMatchingCurrentMetric(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + addNewCurrentMetric(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + addNewCurrentMetricLike(io.kubernetes.client.openapi.models.V2beta1MetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + setNewCurrentMetricLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editCurrentMetric(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editFirstCurrentMetric(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editLastCurrentMetric(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editMatchingCurrentMetric( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder> + predicate); + public java.lang.Integer getCurrentReplicas(); + public A withCurrentReplicas(java.lang.Integer currentReplicas); + public java.lang.Boolean hasCurrentReplicas(); + public java.lang.Integer getDesiredReplicas(); + public A withDesiredReplicas(java.lang.Integer desiredReplicas); + public java.lang.Boolean hasDesiredReplicas(); + public java.time.OffsetDateTime getLastScaleTime(); + public A withLastScaleTime(java.time.OffsetDateTime lastScaleTime); + public java.lang.Boolean hasLastScaleTime(); + public java.lang.Long getObservedGeneration(); + public A withObservedGeneration(java.lang.Long observedGeneration); + public java.lang.Boolean hasObservedGeneration(); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluent< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - public interface CurrentMetricsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent>{ + + public interface CurrentMetricsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + N>> { public N and(); + public N endCurrentMetric(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerStatusFluentImpl.java index d49d060d18..92fb8b9d33 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1HorizontalPodAutoscalerStatusFluentImpl.java @@ -1,27 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.lang.Long; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V2beta1HorizontalPodAutoscalerStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent{ - public V2beta1HorizontalPodAutoscalerStatusFluentImpl() { - } - public V2beta1HorizontalPodAutoscalerStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus instance) { + +/** Generated */ +public class V2beta1HorizontalPodAutoscalerStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent { + public V2beta1HorizontalPodAutoscalerStatusFluentImpl() {} + + public V2beta1HorizontalPodAutoscalerStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatus instance) { this.withConditions(instance.getConditions()); this.withCurrentMetrics(instance.getCurrentMetrics()); @@ -33,148 +35,411 @@ public V2beta1HorizontalPodAutoscalerStatusFluentImpl(io.kubernetes.client.opena this.withLastScaleTime(instance.getLastScaleTime()); this.withObservedGeneration(instance.getObservedGeneration()); - } - private java.util.ArrayList conditions; - private java.util.ArrayList currentMetrics; + + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder> + conditions; + private java.util.ArrayList + currentMetrics; private java.lang.Integer currentReplicas; private java.lang.Integer desiredReplicas; private java.time.OffsetDateTime lastScaleTime; private java.lang.Long observedGeneration; - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder( + item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder( + item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } - public A addToConditions(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item : items) {io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addToConditions( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition... items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item : items) { + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder( + item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item : items) {io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition> + items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item : items) { + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder( + item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition... items) { - for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item : items) {io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition... items) { + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item : items) { + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder( + item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item : items) {io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition> + items) { + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item : items) { + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder( + item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder> + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder> + each = conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions() { + public java.util.List + getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition buildFirstCondition() { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition + buildFirstCondition() { return this.conditions.get(0).build(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition buildLastCondition() { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition + buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V2beta1HorizontalPodAutoscalerConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List + conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item : + conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } - public A withConditions(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item :conditions){ this.addToConditions(item);}} return (A) this; + + public A withConditions( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition... conditions) { + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item : + conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + addNewCondition() { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item) { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item) { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item) { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item) { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V2beta1HorizontalPodAutoscalerConditionBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(item);_visitables.get("currentMetrics").add(index >= 0 ? index : _visitables.get("currentMetrics").size(), builder);this.currentMetrics.add(index >= 0 ? index : currentMetrics.size(), builder); return (A)this; + + public A addToCurrentMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricStatus item) { + if (this.currentMetrics == null) { + this.currentMetrics = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(item); + _visitables + .get("currentMetrics") + .add(index >= 0 ? index : _visitables.get("currentMetrics").size(), builder); + this.currentMetrics.add(index >= 0 ? index : currentMetrics.size(), builder); + return (A) this; } - public A setToCurrentMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1MetricStatus item) { - if (this.currentMetrics == null) {this.currentMetrics = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(item); - if (index < 0 || index >= _visitables.get("currentMetrics").size()) { _visitables.get("currentMetrics").add(builder); } else { _visitables.get("currentMetrics").set(index, builder);} - if (index < 0 || index >= currentMetrics.size()) { currentMetrics.add(builder); } else { currentMetrics.set(index, builder);} - return (A)this; + + public A setToCurrentMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricStatus item) { + if (this.currentMetrics == null) { + this.currentMetrics = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(item); + if (index < 0 || index >= _visitables.get("currentMetrics").size()) { + _visitables.get("currentMetrics").add(builder); + } else { + _visitables.get("currentMetrics").set(index, builder); + } + if (index < 0 || index >= currentMetrics.size()) { + currentMetrics.add(builder); + } else { + currentMetrics.set(index, builder); + } + return (A) this; } + public A addToCurrentMetrics(io.kubernetes.client.openapi.models.V2beta1MetricStatus... items) { - if (this.currentMetrics == null) {this.currentMetrics = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta1MetricStatus item : items) {io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(item);_visitables.get("currentMetrics").add(builder);this.currentMetrics.add(builder);} return (A)this; + if (this.currentMetrics == null) { + this.currentMetrics = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2beta1MetricStatus item : items) { + io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(item); + _visitables.get("currentMetrics").add(builder); + this.currentMetrics.add(builder); + } + return (A) this; } - public A addAllToCurrentMetrics(java.util.Collection items) { - if (this.currentMetrics == null) {this.currentMetrics = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta1MetricStatus item : items) {io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(item);_visitables.get("currentMetrics").add(builder);this.currentMetrics.add(builder);} return (A)this; + + public A addAllToCurrentMetrics( + java.util.Collection items) { + if (this.currentMetrics == null) { + this.currentMetrics = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2beta1MetricStatus item : items) { + io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(item); + _visitables.get("currentMetrics").add(builder); + this.currentMetrics.add(builder); + } + return (A) this; } - public A removeFromCurrentMetrics(io.kubernetes.client.openapi.models.V2beta1MetricStatus... items) { - for (io.kubernetes.client.openapi.models.V2beta1MetricStatus item : items) {io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(item);_visitables.get("currentMetrics").remove(builder);if (this.currentMetrics != null) {this.currentMetrics.remove(builder);}} return (A)this; + + public A removeFromCurrentMetrics( + io.kubernetes.client.openapi.models.V2beta1MetricStatus... items) { + for (io.kubernetes.client.openapi.models.V2beta1MetricStatus item : items) { + io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(item); + _visitables.get("currentMetrics").remove(builder); + if (this.currentMetrics != null) { + this.currentMetrics.remove(builder); + } + } + return (A) this; } - public A removeAllFromCurrentMetrics(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2beta1MetricStatus item : items) {io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(item);_visitables.get("currentMetrics").remove(builder);if (this.currentMetrics != null) {this.currentMetrics.remove(builder);}} return (A)this; + + public A removeAllFromCurrentMetrics( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V2beta1MetricStatus item : items) { + io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(item); + _visitables.get("currentMetrics").remove(builder); + if (this.currentMetrics != null) { + this.currentMetrics.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromCurrentMetrics(java.util.function.Predicate predicate) { + + public A removeMatchingFromCurrentMetrics( + java.util.function.Predicate + predicate) { if (currentMetrics == null) return (A) this; - final Iterator each = currentMetrics.iterator(); + final Iterator each = + currentMetrics.iterator(); final List visitables = _visitables.get("currentMetrics"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder = each.next(); @@ -183,164 +448,322 @@ public A removeMatchingFromCurrentMetrics(java.util.function.Predicate getCurrentMetrics() { + public java.util.List + getCurrentMetrics() { return currentMetrics != null ? build(currentMetrics) : null; } - public java.util.List buildCurrentMetrics() { + + public java.util.List + buildCurrentMetrics() { return currentMetrics != null ? build(currentMetrics) : null; } - public io.kubernetes.client.openapi.models.V2beta1MetricStatus buildCurrentMetric(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2beta1MetricStatus buildCurrentMetric( + java.lang.Integer index) { return this.currentMetrics.get(index).build(); } + public io.kubernetes.client.openapi.models.V2beta1MetricStatus buildFirstCurrentMetric() { return this.currentMetrics.get(0).build(); } + public io.kubernetes.client.openapi.models.V2beta1MetricStatus buildLastCurrentMetric() { return this.currentMetrics.get(currentMetrics.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatus buildMatchingCurrentMetric(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder item: currentMetrics) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2beta1MetricStatus buildMatchingCurrentMetric( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder item : currentMetrics) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCurrentMetric(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder item: currentMetrics) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCurrentMetric( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder item : currentMetrics) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withCurrentMetrics(java.util.List currentMetrics) { - if (this.currentMetrics != null) { _visitables.get("currentMetrics").removeAll(this.currentMetrics);} - if (currentMetrics != null) {this.currentMetrics = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2beta1MetricStatus item : currentMetrics){this.addToCurrentMetrics(item);}} else { this.currentMetrics = null;} return (A) this; + + public A withCurrentMetrics( + java.util.List currentMetrics) { + if (this.currentMetrics != null) { + _visitables.get("currentMetrics").removeAll(this.currentMetrics); + } + if (currentMetrics != null) { + this.currentMetrics = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2beta1MetricStatus item : currentMetrics) { + this.addToCurrentMetrics(item); + } + } else { + this.currentMetrics = null; + } + return (A) this; } - public A withCurrentMetrics(io.kubernetes.client.openapi.models.V2beta1MetricStatus... currentMetrics) { - if (this.currentMetrics != null) {this.currentMetrics.clear();} - if (currentMetrics != null) {for (io.kubernetes.client.openapi.models.V2beta1MetricStatus item :currentMetrics){ this.addToCurrentMetrics(item);}} return (A) this; + + public A withCurrentMetrics( + io.kubernetes.client.openapi.models.V2beta1MetricStatus... currentMetrics) { + if (this.currentMetrics != null) { + this.currentMetrics.clear(); + } + if (currentMetrics != null) { + for (io.kubernetes.client.openapi.models.V2beta1MetricStatus item : currentMetrics) { + this.addToCurrentMetrics(item); + } + } + return (A) this; } + public java.lang.Boolean hasCurrentMetrics() { return currentMetrics != null && !currentMetrics.isEmpty(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested addNewCurrentMetric() { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl.CurrentMetricsNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + addNewCurrentMetric() { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl + .CurrentMetricsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested addNewCurrentMetricLike(io.kubernetes.client.openapi.models.V2beta1MetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl.CurrentMetricsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + addNewCurrentMetricLike(io.kubernetes.client.openapi.models.V2beta1MetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl + .CurrentMetricsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested setNewCurrentMetricLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1MetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl.CurrentMetricsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + setNewCurrentMetricLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluentImpl + .CurrentMetricsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editCurrentMetric(java.lang.Integer index) { - if (currentMetrics.size() <= index) throw new RuntimeException("Can't edit currentMetrics. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editCurrentMetric(java.lang.Integer index) { + if (currentMetrics.size() <= index) + throw new RuntimeException("Can't edit currentMetrics. Index exceeds size."); return setNewCurrentMetricLike(index, buildCurrentMetric(index)); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editFirstCurrentMetric() { - if (currentMetrics.size() == 0) throw new RuntimeException("Can't edit first currentMetrics. The list is empty."); + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editFirstCurrentMetric() { + if (currentMetrics.size() == 0) + throw new RuntimeException("Can't edit first currentMetrics. The list is empty."); return setNewCurrentMetricLike(0, buildCurrentMetric(0)); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editLastCurrentMetric() { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editLastCurrentMetric() { int index = currentMetrics.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last currentMetrics. The list is empty."); return setNewCurrentMetricLike(index, buildCurrentMetric(index)); } - public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editMatchingCurrentMetric(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editMatchingCurrentMetric( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder( + this, item); } + ConditionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder( + this); } + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2beta1HorizontalPodAutoscalerStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) + V2beta1HorizontalPodAutoscalerStatusFluentImpl.this.setToConditions( + index, builder.build()); } + public N endCondition() { return and(); } - } - public class CurrentMetricsNestedImpl extends io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested,io.kubernetes.client.fluent.Nested{ - CurrentMetricsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta1MetricStatus item) { + + public class CurrentMetricsNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta1HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + N>, + io.kubernetes.client.fluent.Nested { + CurrentMetricsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta1MetricStatus item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(this, item); } + CurrentMetricsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2beta1HorizontalPodAutoscalerStatusFluentImpl.this.setToCurrentMetrics(index,builder.build()); + return (N) + V2beta1HorizontalPodAutoscalerStatusFluentImpl.this.setToCurrentMetrics( + index, builder.build()); } + public N endCurrentMetric() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricSpecBuilder.java index 22e194a104..beaf69d42d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1MetricSpecBuilder extends io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1MetricSpecBuilder + extends io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl< + io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1MetricSpec, + io.kubernetes.client.openapi.models.V2beta1MetricSpecBuilder> { public V2beta1MetricSpecBuilder() { this(false); } + public V2beta1MetricSpecBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1MetricSpec(), validationEnabled); } - public V2beta1MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent fluent) { + + public V2beta1MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent fluent) { this(fluent, false); } - public V2beta1MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1MetricSpec(), validationEnabled); } - public V2beta1MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent fluent,io.kubernetes.client.openapi.models.V2beta1MetricSpec instance) { + + public V2beta1MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent fluent, + io.kubernetes.client.openapi.models.V2beta1MetricSpec instance) { this(fluent, instance, false); } - public V2beta1MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent fluent,io.kubernetes.client.openapi.models.V2beta1MetricSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent fluent, + io.kubernetes.client.openapi.models.V2beta1MetricSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainerResource(instance.getContainerResource()); fluent.withExternal(instance.getExternal()); @@ -33,13 +60,17 @@ public V2beta1MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta1Metri fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V2beta1MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta1MetricSpec instance) { - this(instance,false); + this(instance, false); } - public V2beta1MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta1MetricSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2beta1MetricSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainerResource(instance.getContainerResource()); this.withExternal(instance.getExternal()); @@ -52,10 +83,12 @@ public V2beta1MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta1Metri this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1MetricSpec build() { V2beta1MetricSpec buildable = new V2beta1MetricSpec(); buildable.setContainerResource(fluent.getContainerResource()); @@ -66,18 +99,23 @@ public io.kubernetes.client.openapi.models.V2beta1MetricSpec build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1MetricSpecBuilder that = (V2beta1MetricSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricSpecFluent.java index f49d7adf4d..323c9a8606 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricSpecFluent.java @@ -1,124 +1,221 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; - - /** - * Generated - */ -public interface V2beta1MetricSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2beta1MetricSpecFluent< + A extends io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildContainerResource instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource getContainerResource(); - public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource buildContainerResource(); - public A withContainerResource(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource containerResource); + public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource + getContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource + buildContainerResource(); + + public A withContainerResource( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource containerResource); + public java.lang.Boolean hasContainerResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested withNewContainerResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested withNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource item); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested editContainerResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested editOrNewContainerResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested editOrNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource item); - + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested + withNewContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested + withNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested + editContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested + editOrNewContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested + editOrNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource item); + /** * This method has been deprecated, please use method buildExternal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource getExternal(); + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource buildExternal(); + public A withExternal(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource external); + public java.lang.Boolean hasExternal(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested withNewExternal(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested withNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource item); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested editExternal(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested editOrNewExternal(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource item); - + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested + withNewExternal(); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested + withNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested + editExternal(); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested + editOrNewExternal(); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested + editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource item); + /** * This method has been deprecated, please use method buildObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource getObject(); + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource buildObject(); + public A withObject(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource _object); + public java.lang.Boolean hasObject(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested withNewObject(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested withNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested + withNewObject(); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested + withNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource item); + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested editObject(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested editOrNewObject(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource item); - + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested + editOrNewObject(); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested + editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource item); + /** * This method has been deprecated, please use method buildPods instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1PodsMetricSource getPods(); + public io.kubernetes.client.openapi.models.V2beta1PodsMetricSource buildPods(); + public A withPods(io.kubernetes.client.openapi.models.V2beta1PodsMetricSource pods); + public java.lang.Boolean hasPods(); + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested withNewPods(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested withNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricSource item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested withNewPodsLike( + io.kubernetes.client.openapi.models.V2beta1PodsMetricSource item); + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested editPods(); + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested editOrNewPods(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricSource item); - + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested + editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricSource item); + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource getResource(); + public io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource buildResource(); + public A withResource(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource resource); + public java.lang.Boolean hasResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested withNewResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource item); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested editResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested editOrNewResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested + withNewResource(); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested + editResource(); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested + editOrNewResource(); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource item); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface ContainerResourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent>{ + + public interface ContainerResourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluent< + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested< + N>> { public N and(); + public N endContainerResource(); - } - public interface ExternalNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent>{ + + public interface ExternalNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluent< + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested> { public N and(); + public N endExternal(); - } - public interface ObjectNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent>{ + + public interface ObjectNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent< + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested> { public N and(); + public N endObject(); - } - public interface PodsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent>{ + + public interface PodsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent< + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested> { public N and(); + public N endPods(); - } - public interface ResourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent>{ + + public interface ResourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent< + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested> { public N and(); + public N endResource(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricSpecFluentImpl.java index a701490958..0e4d95e493 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricSpecFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Object; +/** Generated */ +public class V2beta1MetricSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent { + public V2beta1MetricSpecFluentImpl() {} - /** - * Generated - */ -public class V2beta1MetricSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent{ - public V2beta1MetricSpecFluentImpl() { - } - public V2beta1MetricSpecFluentImpl(io.kubernetes.client.openapi.models.V2beta1MetricSpec instance) { + public V2beta1MetricSpecFluentImpl( + io.kubernetes.client.openapi.models.V2beta1MetricSpec instance) { this.withContainerResource(instance.getContainerResource()); this.withExternal(instance.getExternal()); @@ -25,295 +32,472 @@ public V2beta1MetricSpecFluentImpl(io.kubernetes.client.openapi.models.V2beta1Me this.withResource(instance.getResource()); this.withType(instance.getType()); - } - private io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceBuilder containerResource; + + private io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceBuilder + containerResource; private io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceBuilder external; private io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceBuilder _object; private io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceBuilder pods; private io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceBuilder resource; private java.lang.String type; - + /** * This method has been deprecated, please use method buildContainerResource instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource getContainerResource() { - return this.containerResource!=null ?this.containerResource.build():null; + public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource + getContainerResource() { + return this.containerResource != null ? this.containerResource.build() : null; } - public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource buildContainerResource() { - return this.containerResource!=null ?this.containerResource.build():null; + + public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource + buildContainerResource() { + return this.containerResource != null ? this.containerResource.build() : null; } - public A withContainerResource(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource containerResource) { + + public A withContainerResource( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource containerResource) { _visitables.get("containerResource").remove(this.containerResource); - if (containerResource!=null){ this.containerResource= new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceBuilder(containerResource); _visitables.get("containerResource").add(this.containerResource);} return (A) this; + if (containerResource != null) { + this.containerResource = + new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceBuilder( + containerResource); + _visitables.get("containerResource").add(this.containerResource); + } + return (A) this; } + public java.lang.Boolean hasContainerResource() { return this.containerResource != null; } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested withNewContainerResource() { - return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl.ContainerResourceNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested + withNewContainerResource() { + return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl + .ContainerResourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested withNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource item) { - return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl.ContainerResourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested + withNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource item) { + return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl + .ContainerResourceNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested editContainerResource() { + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested + editContainerResource() { return withNewContainerResourceLike(getContainerResource()); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested editOrNewContainerResource() { - return withNewContainerResourceLike(getContainerResource() != null ? getContainerResource(): new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested + editOrNewContainerResource() { + return withNewContainerResourceLike( + getContainerResource() != null + ? getContainerResource() + : new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested editOrNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource item) { - return withNewContainerResourceLike(getContainerResource() != null ? getContainerResource(): item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested + editOrNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource item) { + return withNewContainerResourceLike( + getContainerResource() != null ? getContainerResource() : item); } - + /** * This method has been deprecated, please use method buildExternal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource getExternal() { - return this.external!=null ?this.external.build():null; + return this.external != null ? this.external.build() : null; } + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource buildExternal() { - return this.external!=null ?this.external.build():null; + return this.external != null ? this.external.build() : null; } + public A withExternal(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource external) { _visitables.get("external").remove(this.external); - if (external!=null){ this.external= new io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceBuilder(external); _visitables.get("external").add(this.external);} return (A) this; + if (external != null) { + this.external = + new io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceBuilder(external); + _visitables.get("external").add(this.external); + } + return (A) this; } + public java.lang.Boolean hasExternal() { return this.external != null; } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested withNewExternal() { + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested + withNewExternal() { return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl.ExternalNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested withNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource item) { - return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl.ExternalNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested + withNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource item) { + return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl.ExternalNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested editExternal() { + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested + editExternal() { return withNewExternalLike(getExternal()); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested editOrNewExternal() { - return withNewExternalLike(getExternal() != null ? getExternal(): new io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested + editOrNewExternal() { + return withNewExternalLike( + getExternal() != null + ? getExternal() + : new io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource item) { - return withNewExternalLike(getExternal() != null ? getExternal(): item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested + editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource item) { + return withNewExternalLike(getExternal() != null ? getExternal() : item); } - + /** * This method has been deprecated, please use method buildObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource getObject() { - return this._object!=null ?this._object.build():null; + return this._object != null ? this._object.build() : null; } + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource buildObject() { - return this._object!=null ?this._object.build():null; + return this._object != null ? this._object.build() : null; } + public A withObject(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource _object) { _visitables.get("_object").remove(this._object); - if (_object!=null){ this._object= new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceBuilder(_object); _visitables.get("_object").add(this._object);} return (A) this; + if (_object != null) { + this._object = + new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceBuilder(_object); + _visitables.get("_object").add(this._object); + } + return (A) this; } + public java.lang.Boolean hasObject() { return this._object != null; } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested withNewObject() { + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested + withNewObject() { return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl.ObjectNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested withNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource item) { - return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl.ObjectNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested + withNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource item) { + return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl.ObjectNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested editObject() { return withNewObjectLike(getObject()); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested editOrNewObject() { - return withNewObjectLike(getObject() != null ? getObject(): new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested + editOrNewObject() { + return withNewObjectLike( + getObject() != null + ? getObject() + : new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource item) { - return withNewObjectLike(getObject() != null ? getObject(): item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested + editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource item) { + return withNewObjectLike(getObject() != null ? getObject() : item); } - + /** * This method has been deprecated, please use method buildPods instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1PodsMetricSource getPods() { - return this.pods!=null ?this.pods.build():null; + return this.pods != null ? this.pods.build() : null; } + public io.kubernetes.client.openapi.models.V2beta1PodsMetricSource buildPods() { - return this.pods!=null ?this.pods.build():null; + return this.pods != null ? this.pods.build() : null; } + public A withPods(io.kubernetes.client.openapi.models.V2beta1PodsMetricSource pods) { _visitables.get("pods").remove(this.pods); - if (pods!=null){ this.pods= new io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceBuilder(pods); _visitables.get("pods").add(this.pods);} return (A) this; + if (pods != null) { + this.pods = new io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceBuilder(pods); + _visitables.get("pods").add(this.pods); + } + return (A) this; } + public java.lang.Boolean hasPods() { return this.pods != null; } + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested withNewPods() { return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl.PodsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested withNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricSource item) { + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested withNewPodsLike( + io.kubernetes.client.openapi.models.V2beta1PodsMetricSource item) { return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl.PodsNestedImpl(item); } + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested editPods() { return withNewPodsLike(getPods()); } + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested editOrNewPods() { - return withNewPodsLike(getPods() != null ? getPods(): new io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceBuilder().build()); + return withNewPodsLike( + getPods() != null + ? getPods() + : new io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricSource item) { - return withNewPodsLike(getPods() != null ? getPods(): item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested + editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricSource item) { + return withNewPodsLike(getPods() != null ? getPods() : item); } - + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource getResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource buildResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public A withResource(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource resource) { _visitables.get("resource").remove(this.resource); - if (resource!=null){ this.resource= new io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceBuilder(resource); _visitables.get("resource").add(this.resource);} return (A) this; + if (resource != null) { + this.resource = + new io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceBuilder(resource); + _visitables.get("resource").add(this.resource); + } + return (A) this; } + public java.lang.Boolean hasResource() { return this.resource != null; } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested withNewResource() { + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested + withNewResource() { return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl.ResourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource item) { - return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl.ResourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource item) { + return new io.kubernetes.client.openapi.models.V2beta1MetricSpecFluentImpl.ResourceNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested editResource() { + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested + editResource() { return withNewResourceLike(getResource()); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested editOrNewResource() { - return withNewResourceLike(getResource() != null ? getResource(): new io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested + editOrNewResource() { + return withNewResourceLike( + getResource() != null + ? getResource() + : new io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource item) { - return withNewResourceLike(getResource() != null ? getResource(): item); + + public io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource item) { + return withNewResourceLike(getResource() != null ? getResource() : item); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta1MetricSpecFluentImpl that = (V2beta1MetricSpecFluentImpl) o; - if (containerResource != null ? !containerResource.equals(that.containerResource) :that.containerResource != null) return false; - if (external != null ? !external.equals(that.external) :that.external != null) return false; - if (_object != null ? !_object.equals(that._object) :that._object != null) return false; - if (pods != null ? !pods.equals(that.pods) :that.pods != null) return false; - if (resource != null ? !resource.equals(that.resource) :that.resource != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (containerResource != null + ? !containerResource.equals(that.containerResource) + : that.containerResource != null) return false; + if (external != null ? !external.equals(that.external) : that.external != null) return false; + if (_object != null ? !_object.equals(that._object) : that._object != null) return false; + if (pods != null ? !pods.equals(that.pods) : that.pods != null) return false; + if (resource != null ? !resource.equals(that.resource) : that.resource != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(containerResource, external, _object, pods, resource, type, super.hashCode()); + return java.util.Objects.hash( + containerResource, external, _object, pods, resource, type, super.hashCode()); } - public class ContainerResourceNestedImpl extends io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested,io.kubernetes.client.fluent.Nested{ - ContainerResourceNestedImpl(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceBuilder(this, item); + + public class ContainerResourceNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ContainerResourceNested> + implements io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent + .ContainerResourceNested< + N>, + io.kubernetes.client.fluent.Nested { + ContainerResourceNestedImpl( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceBuilder( + this, item); } + ContainerResourceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricSourceBuilder builder; + public N and() { return (N) V2beta1MetricSpecFluentImpl.this.withContainerResource(builder.build()); } + public N endContainerResource() { return and(); } - } - public class ExternalNestedImpl extends io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested,io.kubernetes.client.fluent.Nested{ + + public class ExternalNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested> + implements io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ExternalNested, + io.kubernetes.client.fluent.Nested { ExternalNestedImpl(io.kubernetes.client.openapi.models.V2beta1ExternalMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceBuilder(this, item); } + ExternalNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1ExternalMetricSourceBuilder builder; + public N and() { return (N) V2beta1MetricSpecFluentImpl.this.withExternal(builder.build()); } + public N endExternal() { return and(); } - } - public class ObjectNestedImpl extends io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested,io.kubernetes.client.fluent.Nested{ + + public class ObjectNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested> + implements io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ObjectNested, + io.kubernetes.client.fluent.Nested { ObjectNestedImpl(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceBuilder(this, item); } + ObjectNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceBuilder builder; + public N and() { return (N) V2beta1MetricSpecFluentImpl.this.withObject(builder.build()); } + public N endObject() { return and(); } - } - public class PodsNestedImpl extends io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested,io.kubernetes.client.fluent.Nested{ + + public class PodsNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested> + implements io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.PodsNested, + io.kubernetes.client.fluent.Nested { PodsNestedImpl(io.kubernetes.client.openapi.models.V2beta1PodsMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceBuilder(this, item); } + PodsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceBuilder builder; + public N and() { return (N) V2beta1MetricSpecFluentImpl.this.withPods(builder.build()); } + public N endPods() { return and(); } - } - public class ResourceNestedImpl extends io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested,io.kubernetes.client.fluent.Nested{ + + public class ResourceNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested> + implements io.kubernetes.client.openapi.models.V2beta1MetricSpecFluent.ResourceNested, + io.kubernetes.client.fluent.Nested { ResourceNestedImpl(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceBuilder(this, item); } + ResourceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceBuilder builder; + public N and() { return (N) V2beta1MetricSpecFluentImpl.this.withResource(builder.build()); } + public N endResource() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricStatusBuilder.java index ee012b688e..69169d8c57 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1MetricStatusBuilder extends io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1MetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1MetricStatus, + io.kubernetes.client.openapi.models.V2beta1MetricStatusBuilder> { public V2beta1MetricStatusBuilder() { this(false); } + public V2beta1MetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1MetricStatus(), validationEnabled); } - public V2beta1MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent fluent) { + + public V2beta1MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent fluent) { this(fluent, false); } - public V2beta1MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1MetricStatus(), validationEnabled); } - public V2beta1MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1MetricStatus instance) { + + public V2beta1MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1MetricStatus instance) { this(fluent, instance, false); } - public V2beta1MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1MetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1MetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainerResource(instance.getContainerResource()); fluent.withExternal(instance.getExternal()); @@ -33,13 +60,18 @@ public V2beta1MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1Met fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1MetricStatus instance) { - this(instance,false); + + public V2beta1MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1MetricStatus instance) { + this(instance, false); } - public V2beta1MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1MetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1MetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainerResource(instance.getContainerResource()); this.withExternal(instance.getExternal()); @@ -52,10 +84,12 @@ public V2beta1MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1Met this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1MetricStatus build() { V2beta1MetricStatus buildable = new V2beta1MetricStatus(); buildable.setContainerResource(fluent.getContainerResource()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V2beta1MetricStatus build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1MetricStatusBuilder that = (V2beta1MetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricStatusFluent.java index 6b71a5ba84..503f77e766 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricStatusFluent.java @@ -1,124 +1,222 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; - - /** - * Generated - */ -public interface V2beta1MetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2beta1MetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildContainerResource instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus getContainerResource(); - public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus buildContainerResource(); - public A withContainerResource(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus containerResource); + public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus + getContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus + buildContainerResource(); + + public A withContainerResource( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus containerResource); + public java.lang.Boolean hasContainerResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested withNewContainerResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested withNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus item); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested editContainerResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested editOrNewContainerResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested editOrNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus item); - + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested + withNewContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested + withNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested + editContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested + editOrNewContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested + editOrNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus item); + /** * This method has been deprecated, please use method buildExternal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus getExternal(); + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus buildExternal(); + public A withExternal(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus external); + public java.lang.Boolean hasExternal(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested withNewExternal(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested withNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus item); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested editExternal(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested editOrNewExternal(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus item); - + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested + withNewExternal(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested + withNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested + editExternal(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested + editOrNewExternal(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested + editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus item); + /** * This method has been deprecated, please use method buildObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus getObject(); + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus buildObject(); + public A withObject(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus _object); + public java.lang.Boolean hasObject(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested withNewObject(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested withNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested + withNewObject(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested + withNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus item); + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested editObject(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested editOrNewObject(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus item); - + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested + editOrNewObject(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested + editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus item); + /** * This method has been deprecated, please use method buildPods instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus getPods(); + public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus buildPods(); + public A withPods(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus pods); + public java.lang.Boolean hasPods(); + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested withNewPods(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested withNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested + withNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus item); + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested editPods(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested editOrNewPods(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus item); - + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested + editOrNewPods(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested + editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus item); + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus getResource(); + public io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus buildResource(); + public A withResource(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus resource); + public java.lang.Boolean hasResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested withNewResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus item); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested editResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested editOrNewResource(); - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested + withNewResource(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested + editResource(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested + editOrNewResource(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus item); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface ContainerResourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent>{ + + public interface ContainerResourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluent< + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested< + N>> { public N and(); + public N endContainerResource(); - } - public interface ExternalNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent>{ + + public interface ExternalNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluent< + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested> { public N and(); + public N endExternal(); - } - public interface ObjectNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent>{ + + public interface ObjectNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent< + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested> { public N and(); + public N endObject(); - } - public interface PodsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent>{ + + public interface PodsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent< + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested> { public N and(); + public N endPods(); - } - public interface ResourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent>{ + + public interface ResourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent< + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested> { public N and(); + public N endResource(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricStatusFluentImpl.java index d15e941d74..6208464e6f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1MetricStatusFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Object; +/** Generated */ +public class V2beta1MetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent { + public V2beta1MetricStatusFluentImpl() {} - /** - * Generated - */ -public class V2beta1MetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent{ - public V2beta1MetricStatusFluentImpl() { - } - public V2beta1MetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta1MetricStatus instance) { + public V2beta1MetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta1MetricStatus instance) { this.withContainerResource(instance.getContainerResource()); this.withExternal(instance.getExternal()); @@ -25,295 +32,477 @@ public V2beta1MetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta1 this.withResource(instance.getResource()); this.withType(instance.getType()); - } - private io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusBuilder containerResource; + + private io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusBuilder + containerResource; private io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusBuilder external; private io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusBuilder _object; private io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusBuilder pods; private io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusBuilder resource; private java.lang.String type; - + /** * This method has been deprecated, please use method buildContainerResource instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus getContainerResource() { - return this.containerResource!=null ?this.containerResource.build():null; + public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus + getContainerResource() { + return this.containerResource != null ? this.containerResource.build() : null; } - public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus buildContainerResource() { - return this.containerResource!=null ?this.containerResource.build():null; + + public io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus + buildContainerResource() { + return this.containerResource != null ? this.containerResource.build() : null; } - public A withContainerResource(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus containerResource) { + + public A withContainerResource( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus containerResource) { _visitables.get("containerResource").remove(this.containerResource); - if (containerResource!=null){ this.containerResource= new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusBuilder(containerResource); _visitables.get("containerResource").add(this.containerResource);} return (A) this; + if (containerResource != null) { + this.containerResource = + new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusBuilder( + containerResource); + _visitables.get("containerResource").add(this.containerResource); + } + return (A) this; } + public java.lang.Boolean hasContainerResource() { return this.containerResource != null; } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested withNewContainerResource() { - return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.ContainerResourceNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested + withNewContainerResource() { + return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl + .ContainerResourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested withNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.ContainerResourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested + withNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl + .ContainerResourceNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested editContainerResource() { + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested + editContainerResource() { return withNewContainerResourceLike(getContainerResource()); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested editOrNewContainerResource() { - return withNewContainerResourceLike(getContainerResource() != null ? getContainerResource(): new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested + editOrNewContainerResource() { + return withNewContainerResourceLike( + getContainerResource() != null + ? getContainerResource() + : new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested editOrNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus item) { - return withNewContainerResourceLike(getContainerResource() != null ? getContainerResource(): item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested + editOrNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus item) { + return withNewContainerResourceLike( + getContainerResource() != null ? getContainerResource() : item); } - + /** * This method has been deprecated, please use method buildExternal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus getExternal() { - return this.external!=null ?this.external.build():null; + return this.external != null ? this.external.build() : null; } + public io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus buildExternal() { - return this.external!=null ?this.external.build():null; + return this.external != null ? this.external.build() : null; } + public A withExternal(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus external) { _visitables.get("external").remove(this.external); - if (external!=null){ this.external= new io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusBuilder(external); _visitables.get("external").add(this.external);} return (A) this; + if (external != null) { + this.external = + new io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusBuilder(external); + _visitables.get("external").add(this.external); + } + return (A) this; } + public java.lang.Boolean hasExternal() { return this.external != null; } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested withNewExternal() { - return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.ExternalNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested + withNewExternal() { + return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl + .ExternalNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested withNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.ExternalNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested + withNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.ExternalNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested editExternal() { + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested + editExternal() { return withNewExternalLike(getExternal()); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested editOrNewExternal() { - return withNewExternalLike(getExternal() != null ? getExternal(): new io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested + editOrNewExternal() { + return withNewExternalLike( + getExternal() != null + ? getExternal() + : new io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus item) { - return withNewExternalLike(getExternal() != null ? getExternal(): item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested + editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus item) { + return withNewExternalLike(getExternal() != null ? getExternal() : item); } - + /** * This method has been deprecated, please use method buildObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus getObject() { - return this._object!=null ?this._object.build():null; + return this._object != null ? this._object.build() : null; } + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus buildObject() { - return this._object!=null ?this._object.build():null; + return this._object != null ? this._object.build() : null; } + public A withObject(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus _object) { _visitables.get("_object").remove(this._object); - if (_object!=null){ this._object= new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusBuilder(_object); _visitables.get("_object").add(this._object);} return (A) this; + if (_object != null) { + this._object = + new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusBuilder(_object); + _visitables.get("_object").add(this._object); + } + return (A) this; } + public java.lang.Boolean hasObject() { return this._object != null; } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested withNewObject() { + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested + withNewObject() { return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.ObjectNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested withNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.ObjectNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested + withNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.ObjectNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested editObject() { + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested + editObject() { return withNewObjectLike(getObject()); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested editOrNewObject() { - return withNewObjectLike(getObject() != null ? getObject(): new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested + editOrNewObject() { + return withNewObjectLike( + getObject() != null + ? getObject() + : new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus item) { - return withNewObjectLike(getObject() != null ? getObject(): item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested + editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus item) { + return withNewObjectLike(getObject() != null ? getObject() : item); } - + /** * This method has been deprecated, please use method buildPods instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus getPods() { - return this.pods!=null ?this.pods.build():null; + return this.pods != null ? this.pods.build() : null; } + public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus buildPods() { - return this.pods!=null ?this.pods.build():null; + return this.pods != null ? this.pods.build() : null; } + public A withPods(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus pods) { _visitables.get("pods").remove(this.pods); - if (pods!=null){ this.pods= new io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusBuilder(pods); _visitables.get("pods").add(this.pods);} return (A) this; + if (pods != null) { + this.pods = new io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusBuilder(pods); + _visitables.get("pods").add(this.pods); + } + return (A) this; } + public java.lang.Boolean hasPods() { return this.pods != null; } + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested withNewPods() { return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.PodsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested withNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.PodsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested + withNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.PodsNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested editPods() { return withNewPodsLike(getPods()); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested editOrNewPods() { - return withNewPodsLike(getPods() != null ? getPods(): new io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested + editOrNewPods() { + return withNewPodsLike( + getPods() != null + ? getPods() + : new io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus item) { - return withNewPodsLike(getPods() != null ? getPods(): item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested + editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus item) { + return withNewPodsLike(getPods() != null ? getPods() : item); } - + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus getResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus buildResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public A withResource(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus resource) { _visitables.get("resource").remove(this.resource); - if (resource!=null){ this.resource= new io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusBuilder(resource); _visitables.get("resource").add(this.resource);} return (A) this; + if (resource != null) { + this.resource = + new io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusBuilder(resource); + _visitables.get("resource").add(this.resource); + } + return (A) this; } + public java.lang.Boolean hasResource() { return this.resource != null; } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested withNewResource() { - return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.ResourceNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested + withNewResource() { + return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl + .ResourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.ResourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta1MetricStatusFluentImpl.ResourceNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested editResource() { + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested + editResource() { return withNewResourceLike(getResource()); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested editOrNewResource() { - return withNewResourceLike(getResource() != null ? getResource(): new io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested + editOrNewResource() { + return withNewResourceLike( + getResource() != null + ? getResource() + : new io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus item) { - return withNewResourceLike(getResource() != null ? getResource(): item); + + public io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus item) { + return withNewResourceLike(getResource() != null ? getResource() : item); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta1MetricStatusFluentImpl that = (V2beta1MetricStatusFluentImpl) o; - if (containerResource != null ? !containerResource.equals(that.containerResource) :that.containerResource != null) return false; - if (external != null ? !external.equals(that.external) :that.external != null) return false; - if (_object != null ? !_object.equals(that._object) :that._object != null) return false; - if (pods != null ? !pods.equals(that.pods) :that.pods != null) return false; - if (resource != null ? !resource.equals(that.resource) :that.resource != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (containerResource != null + ? !containerResource.equals(that.containerResource) + : that.containerResource != null) return false; + if (external != null ? !external.equals(that.external) : that.external != null) return false; + if (_object != null ? !_object.equals(that._object) : that._object != null) return false; + if (pods != null ? !pods.equals(that.pods) : that.pods != null) return false; + if (resource != null ? !resource.equals(that.resource) : that.resource != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(containerResource, external, _object, pods, resource, type, super.hashCode()); + return java.util.Objects.hash( + containerResource, external, _object, pods, resource, type, super.hashCode()); } - public class ContainerResourceNestedImpl extends io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested,io.kubernetes.client.fluent.Nested{ - ContainerResourceNestedImpl(io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusBuilder(this, item); + + public class ContainerResourceNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ContainerResourceNested> + implements io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent + .ContainerResourceNested< + N>, + io.kubernetes.client.fluent.Nested { + ContainerResourceNestedImpl( + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatus item) { + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusBuilder( + this, item); } + ContainerResourceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1ContainerResourceMetricStatusBuilder builder; + public N and() { return (N) V2beta1MetricStatusFluentImpl.this.withContainerResource(builder.build()); } + public N endContainerResource() { return and(); } - } - public class ExternalNestedImpl extends io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested,io.kubernetes.client.fluent.Nested{ + + public class ExternalNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested> + implements io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ExternalNested, + io.kubernetes.client.fluent.Nested { ExternalNestedImpl(io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusBuilder(this, item); } + ExternalNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1ExternalMetricStatusBuilder builder; + public N and() { return (N) V2beta1MetricStatusFluentImpl.this.withExternal(builder.build()); } + public N endExternal() { return and(); } - } - public class ObjectNestedImpl extends io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested,io.kubernetes.client.fluent.Nested{ + + public class ObjectNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested> + implements io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ObjectNested, + io.kubernetes.client.fluent.Nested { ObjectNestedImpl(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusBuilder(this, item); } + ObjectNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusBuilder builder; + public N and() { return (N) V2beta1MetricStatusFluentImpl.this.withObject(builder.build()); } + public N endObject() { return and(); } - } - public class PodsNestedImpl extends io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested,io.kubernetes.client.fluent.Nested{ + + public class PodsNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested> + implements io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.PodsNested, + io.kubernetes.client.fluent.Nested { PodsNestedImpl(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusBuilder(this, item); } + PodsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusBuilder builder; + public N and() { return (N) V2beta1MetricStatusFluentImpl.this.withPods(builder.build()); } + public N endPods() { return and(); } - } - public class ResourceNestedImpl extends io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested,io.kubernetes.client.fluent.Nested{ + + public class ResourceNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested> + implements io.kubernetes.client.openapi.models.V2beta1MetricStatusFluent.ResourceNested, + io.kubernetes.client.fluent.Nested { ResourceNestedImpl(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusBuilder(this, item); } + ResourceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusBuilder builder; + public N and() { return (N) V2beta1MetricStatusFluentImpl.this.withResource(builder.build()); } + public N endResource() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricSourceBuilder.java index 71601db430..8966883f10 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricSourceBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1ObjectMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1ObjectMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource, + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceBuilder> { public V2beta1ObjectMetricSourceBuilder() { this(false); } + public V2beta1ObjectMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1ObjectMetricSource(), validationEnabled); } - public V2beta1ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent fluent) { + + public V2beta1ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent fluent) { this(fluent, false); } - public V2beta1ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1ObjectMetricSource(), validationEnabled); } - public V2beta1ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource instance) { + + public V2beta1ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource instance) { this(fluent, instance, false); } - public V2beta1ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAverageValue(instance.getAverageValue()); fluent.withMetricName(instance.getMetricName()); @@ -31,13 +58,18 @@ public V2beta1ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2be fluent.withTargetValue(instance.getTargetValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource instance) { - this(instance,false); + + public V2beta1ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource instance) { + this(instance, false); } - public V2beta1ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAverageValue(instance.getAverageValue()); this.withMetricName(instance.getMetricName()); @@ -48,10 +80,12 @@ public V2beta1ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2be this.withTargetValue(instance.getTargetValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource build() { V2beta1ObjectMetricSource buildable = new V2beta1ObjectMetricSource(); buildable.setAverageValue(fluent.getAverageValue()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource build() { buildable.setTargetValue(fluent.getTargetValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1ObjectMetricSourceBuilder that = (V2beta1ObjectMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricSourceFluent.java index f6e77dce49..7c6019899c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricSourceFluent.java @@ -1,73 +1,124 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1ObjectMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1ObjectMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public io.kubernetes.client.custom.Quantity getAverageValue(); + public A withAverageValue(io.kubernetes.client.custom.Quantity averageValue); + public java.lang.Boolean hasAverageValue(); + public A withNewAverageValue(java.lang.String value); + public java.lang.String getMetricName(); + public A withMetricName(java.lang.String metricName); + public java.lang.Boolean hasMetricName(); - - /** - * Method is deprecated. use withMetricName instead. - */ + + /** Method is deprecated. use withMetricName instead. */ @java.lang.Deprecated public A withNewMetricName(java.lang.String original); - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested editSelector(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested + withNewSelector(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested + editSelector(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested + editOrNewSelector(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference getTarget(); + public io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference buildTarget(); - public A withTarget(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference target); + + public A withTarget( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference target); + public java.lang.Boolean hasTarget(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested withNewTarget(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested editTarget(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested editOrNewTarget(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested + withNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested + withNewTargetLike( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested + editTarget(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested + editOrNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested + editOrNewTargetLike( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item); + public io.kubernetes.client.custom.Quantity getTargetValue(); + public A withTargetValue(io.kubernetes.client.custom.Quantity targetValue); + public java.lang.Boolean hasTargetValue(); + public A withNewTargetValue(java.lang.String value); - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested< + N>> { public N and(); + public N endSelector(); - } - public interface TargetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent>{ + + public interface TargetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent< + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested> { public N and(); + public N endTarget(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricSourceFluentImpl.java index 7b0557064b..660d60b01c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricSourceFluentImpl.java @@ -1,20 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2beta1ObjectMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent{ - public V2beta1ObjectMetricSourceFluentImpl() { - } - public V2beta1ObjectMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource instance) { + +/** Generated */ +public class V2beta1ObjectMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent { + public V2beta1ObjectMetricSourceFluentImpl() {} + + public V2beta1ObjectMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSource instance) { this.withAverageValue(instance.getAverageValue()); this.withMetricName(instance.getMetricName()); @@ -24,167 +32,256 @@ public V2beta1ObjectMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V this.withTarget(instance.getTarget()); this.withTargetValue(instance.getTargetValue()); - } + private io.kubernetes.client.custom.Quantity averageValue; private java.lang.String metricName; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder selector; private io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder target; private io.kubernetes.client.custom.Quantity targetValue; + public io.kubernetes.client.custom.Quantity getAverageValue() { return this.averageValue; } + public A withAverageValue(io.kubernetes.client.custom.Quantity averageValue) { - this.averageValue=averageValue; return (A) this; + this.averageValue = averageValue; + return (A) this; } + public java.lang.Boolean hasAverageValue() { return this.averageValue != null; } + public A withNewAverageValue(java.lang.String value) { - return (A)withAverageValue(new Quantity(value)); + return (A) withAverageValue(new Quantity(value)); } + public java.lang.String getMetricName() { return this.metricName; } + public A withMetricName(java.lang.String metricName) { - this.metricName=metricName; return (A) this; + this.metricName = metricName; + return (A) this; } + public java.lang.Boolean hasMetricName() { return this.metricName != null; } - - /** - * Method is deprecated. use withMetricName instead. - */ + + /** Method is deprecated. use withMetricName instead. */ @java.lang.Deprecated public A withNewMetricName(java.lang.String original) { - return (A)withMetricName(new String(original)); + return (A) withMetricName(new String(original)); } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested withNewSelector() { - return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluentImpl.SelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested + withNewSelector() { + return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluentImpl + .SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluentImpl.SelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluentImpl + .SelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested editSelector() { + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested + editSelector() { return withNewSelectorLike(getSelector()); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested + editOrNewSelector() { + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference getTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference buildTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } - public A withTarget(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference target) { + + public A withTarget( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference target) { _visitables.get("target").remove(this.target); - if (target!=null){ this.target= new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder(target); _visitables.get("target").add(this.target);} return (A) this; + if (target != null) { + this.target = + new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder(target); + _visitables.get("target").add(this.target); + } + return (A) this; } + public java.lang.Boolean hasTarget() { return this.target != null; } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested withNewTarget() { - return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluentImpl.TargetNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested + withNewTarget() { + return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluentImpl + .TargetNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { - return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluentImpl.TargetNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested + withNewTargetLike( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { + return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluentImpl + .TargetNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested editTarget() { + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested + editTarget() { return withNewTargetLike(getTarget()); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested editOrNewTarget() { - return withNewTargetLike(getTarget() != null ? getTarget(): new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested + editOrNewTarget() { + return withNewTargetLike( + getTarget() != null + ? getTarget() + : new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { - return withNewTargetLike(getTarget() != null ? getTarget(): item); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested + editOrNewTargetLike( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { + return withNewTargetLike(getTarget() != null ? getTarget() : item); } + public io.kubernetes.client.custom.Quantity getTargetValue() { return this.targetValue; } + public A withTargetValue(io.kubernetes.client.custom.Quantity targetValue) { - this.targetValue=targetValue; return (A) this; + this.targetValue = targetValue; + return (A) this; } + public java.lang.Boolean hasTargetValue() { return this.targetValue != null; } + public A withNewTargetValue(java.lang.String value) { - return (A)withTargetValue(new Quantity(value)); + return (A) withTargetValue(new Quantity(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta1ObjectMetricSourceFluentImpl that = (V2beta1ObjectMetricSourceFluentImpl) o; - if (averageValue != null ? !averageValue.equals(that.averageValue) :that.averageValue != null) return false; - if (metricName != null ? !metricName.equals(that.metricName) :that.metricName != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; - if (target != null ? !target.equals(that.target) :that.target != null) return false; - if (targetValue != null ? !targetValue.equals(that.targetValue) :that.targetValue != null) return false; + if (averageValue != null ? !averageValue.equals(that.averageValue) : that.averageValue != null) + return false; + if (metricName != null ? !metricName.equals(that.metricName) : that.metricName != null) + return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; + if (target != null ? !target.equals(that.target) : that.target != null) return false; + if (targetValue != null ? !targetValue.equals(that.targetValue) : that.targetValue != null) + return false; return true; } + public int hashCode() { - return java.util.Objects.hash(averageValue, metricName, selector, target, targetValue, super.hashCode()); + return java.util.Objects.hash( + averageValue, metricName, selector, target, targetValue, super.hashCode()); } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested> + implements io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.SelectorNested< + N>, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V2beta1ObjectMetricSourceFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - public class TargetNestedImpl extends io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested,io.kubernetes.client.fluent.Nested{ + + public class TargetNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested> + implements io.kubernetes.client.openapi.models.V2beta1ObjectMetricSourceFluent.TargetNested< + N>, + io.kubernetes.client.fluent.Nested { TargetNestedImpl(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder( + this, item); } + TargetNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder builder; + public N and() { return (N) V2beta1ObjectMetricSourceFluentImpl.this.withTarget(builder.build()); } + public N endTarget() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricStatusBuilder.java index 58ce9a6f4d..e4102dd0d1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1ObjectMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1ObjectMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus, + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusBuilder> { public V2beta1ObjectMetricStatusBuilder() { this(false); } + public V2beta1ObjectMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1ObjectMetricStatus(), validationEnabled); } - public V2beta1ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent fluent) { + + public V2beta1ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent fluent) { this(fluent, false); } - public V2beta1ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1ObjectMetricStatus(), validationEnabled); } - public V2beta1ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus instance) { + + public V2beta1ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus instance) { this(fluent, instance, false); } - public V2beta1ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAverageValue(instance.getAverageValue()); fluent.withCurrentValue(instance.getCurrentValue()); @@ -31,13 +58,18 @@ public V2beta1ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2be fluent.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus instance) { - this(instance,false); + + public V2beta1ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus instance) { + this(instance, false); } - public V2beta1ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAverageValue(instance.getAverageValue()); this.withCurrentValue(instance.getCurrentValue()); @@ -48,10 +80,12 @@ public V2beta1ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2be this.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus build() { V2beta1ObjectMetricStatus buildable = new V2beta1ObjectMetricStatus(); buildable.setAverageValue(fluent.getAverageValue()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus build() { buildable.setTarget(fluent.getTarget()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1ObjectMetricStatusBuilder that = (V2beta1ObjectMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricStatusFluent.java index 50682811df..d4af712e60 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricStatusFluent.java @@ -1,73 +1,124 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1ObjectMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1ObjectMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public io.kubernetes.client.custom.Quantity getAverageValue(); + public A withAverageValue(io.kubernetes.client.custom.Quantity averageValue); + public java.lang.Boolean hasAverageValue(); + public A withNewAverageValue(java.lang.String value); + public io.kubernetes.client.custom.Quantity getCurrentValue(); + public A withCurrentValue(io.kubernetes.client.custom.Quantity currentValue); + public java.lang.Boolean hasCurrentValue(); + public A withNewCurrentValue(java.lang.String value); + public java.lang.String getMetricName(); + public A withMetricName(java.lang.String metricName); + public java.lang.Boolean hasMetricName(); - - /** - * Method is deprecated. use withMetricName instead. - */ + + /** Method is deprecated. use withMetricName instead. */ @java.lang.Deprecated public A withNewMetricName(java.lang.String original); - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested editSelector(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested + withNewSelector(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested + editSelector(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested + editOrNewSelector(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference getTarget(); + public io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference buildTarget(); - public A withTarget(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference target); + + public A withTarget( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference target); + public java.lang.Boolean hasTarget(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested withNewTarget(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested editTarget(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested editOrNewTarget(); - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item); - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested + withNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested + withNewTargetLike( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested + editTarget(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested + editOrNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested + editOrNewTargetLike( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item); + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested< + N>> { public N and(); + public N endSelector(); - } - public interface TargetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent>{ + + public interface TargetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluent< + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested> { public N and(); + public N endTarget(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricStatusFluentImpl.java index 8f18f90797..325e9fd684 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ObjectMetricStatusFluentImpl.java @@ -1,20 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2beta1ObjectMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent{ - public V2beta1ObjectMetricStatusFluentImpl() { - } - public V2beta1ObjectMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus instance) { + +/** Generated */ +public class V2beta1ObjectMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent { + public V2beta1ObjectMetricStatusFluentImpl() {} + + public V2beta1ObjectMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatus instance) { this.withAverageValue(instance.getAverageValue()); this.withCurrentValue(instance.getCurrentValue()); @@ -24,167 +32,256 @@ public V2beta1ObjectMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V this.withSelector(instance.getSelector()); this.withTarget(instance.getTarget()); - } + private io.kubernetes.client.custom.Quantity averageValue; private io.kubernetes.client.custom.Quantity currentValue; private java.lang.String metricName; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder selector; private io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder target; + public io.kubernetes.client.custom.Quantity getAverageValue() { return this.averageValue; } + public A withAverageValue(io.kubernetes.client.custom.Quantity averageValue) { - this.averageValue=averageValue; return (A) this; + this.averageValue = averageValue; + return (A) this; } + public java.lang.Boolean hasAverageValue() { return this.averageValue != null; } + public A withNewAverageValue(java.lang.String value) { - return (A)withAverageValue(new Quantity(value)); + return (A) withAverageValue(new Quantity(value)); } + public io.kubernetes.client.custom.Quantity getCurrentValue() { return this.currentValue; } + public A withCurrentValue(io.kubernetes.client.custom.Quantity currentValue) { - this.currentValue=currentValue; return (A) this; + this.currentValue = currentValue; + return (A) this; } + public java.lang.Boolean hasCurrentValue() { return this.currentValue != null; } + public A withNewCurrentValue(java.lang.String value) { - return (A)withCurrentValue(new Quantity(value)); + return (A) withCurrentValue(new Quantity(value)); } + public java.lang.String getMetricName() { return this.metricName; } + public A withMetricName(java.lang.String metricName) { - this.metricName=metricName; return (A) this; + this.metricName = metricName; + return (A) this; } + public java.lang.Boolean hasMetricName() { return this.metricName != null; } - - /** - * Method is deprecated. use withMetricName instead. - */ + + /** Method is deprecated. use withMetricName instead. */ @java.lang.Deprecated public A withNewMetricName(java.lang.String original) { - return (A)withMetricName(new String(original)); + return (A) withMetricName(new String(original)); } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested withNewSelector() { - return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluentImpl.SelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested + withNewSelector() { + return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluentImpl + .SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluentImpl.SelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluentImpl + .SelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested editSelector() { + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested + editSelector() { return withNewSelectorLike(getSelector()); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested + editOrNewSelector() { + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference getTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference buildTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } - public A withTarget(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference target) { + + public A withTarget( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference target) { _visitables.get("target").remove(this.target); - if (target!=null){ this.target= new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder(target); _visitables.get("target").add(this.target);} return (A) this; + if (target != null) { + this.target = + new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder(target); + _visitables.get("target").add(this.target); + } + return (A) this; } + public java.lang.Boolean hasTarget() { return this.target != null; } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested withNewTarget() { - return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluentImpl.TargetNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested + withNewTarget() { + return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluentImpl + .TargetNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { - return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluentImpl.TargetNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested + withNewTargetLike( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { + return new io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluentImpl + .TargetNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested editTarget() { + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested + editTarget() { return withNewTargetLike(getTarget()); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested editOrNewTarget() { - return withNewTargetLike(getTarget() != null ? getTarget(): new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested + editOrNewTarget() { + return withNewTargetLike( + getTarget() != null + ? getTarget() + : new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { - return withNewTargetLike(getTarget() != null ? getTarget(): item); + + public io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested + editOrNewTargetLike( + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { + return withNewTargetLike(getTarget() != null ? getTarget() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta1ObjectMetricStatusFluentImpl that = (V2beta1ObjectMetricStatusFluentImpl) o; - if (averageValue != null ? !averageValue.equals(that.averageValue) :that.averageValue != null) return false; - if (currentValue != null ? !currentValue.equals(that.currentValue) :that.currentValue != null) return false; - if (metricName != null ? !metricName.equals(that.metricName) :that.metricName != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; - if (target != null ? !target.equals(that.target) :that.target != null) return false; + if (averageValue != null ? !averageValue.equals(that.averageValue) : that.averageValue != null) + return false; + if (currentValue != null ? !currentValue.equals(that.currentValue) : that.currentValue != null) + return false; + if (metricName != null ? !metricName.equals(that.metricName) : that.metricName != null) + return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; + if (target != null ? !target.equals(that.target) : that.target != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(averageValue, currentValue, metricName, selector, target, super.hashCode()); + return java.util.Objects.hash( + averageValue, currentValue, metricName, selector, target, super.hashCode()); } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested> + implements io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.SelectorNested< + N>, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V2beta1ObjectMetricStatusFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - public class TargetNestedImpl extends io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested,io.kubernetes.client.fluent.Nested{ + + public class TargetNestedImpl + extends io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested> + implements io.kubernetes.client.openapi.models.V2beta1ObjectMetricStatusFluent.TargetNested< + N>, + io.kubernetes.client.fluent.Nested { TargetNestedImpl(io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder( + this, item); } + TargetNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta1CrossVersionObjectReferenceBuilder builder; + public N and() { return (N) V2beta1ObjectMetricStatusFluentImpl.this.withTarget(builder.build()); } + public N endTarget() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricSourceBuilder.java index a81f05f1c4..0c24afe7e6 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricSourceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1PodsMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1PodsMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1PodsMetricSource, + io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceBuilder> { public V2beta1PodsMetricSourceBuilder() { this(false); } + public V2beta1PodsMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1PodsMetricSource(), validationEnabled); } - public V2beta1PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent fluent) { + + public V2beta1PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent fluent) { this(fluent, false); } - public V2beta1PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1PodsMetricSource(), validationEnabled); } - public V2beta1PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta1PodsMetricSource instance) { + + public V2beta1PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta1PodsMetricSource instance) { this(fluent, instance, false); } - public V2beta1PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta1PodsMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta1PodsMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMetricName(instance.getMetricName()); fluent.withSelector(instance.getSelector()); fluent.withTargetAverageValue(instance.getTargetAverageValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1PodsMetricSource instance) { - this(instance,false); + + public V2beta1PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1PodsMetricSource instance) { + this(instance, false); } - public V2beta1PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1PodsMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1PodsMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMetricName(instance.getMetricName()); this.withSelector(instance.getSelector()); this.withTargetAverageValue(instance.getTargetAverageValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1PodsMetricSource build() { V2beta1PodsMetricSource buildable = new V2beta1PodsMetricSource(); buildable.setMetricName(fluent.getMetricName()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2beta1PodsMetricSource build() { buildable.setTargetAverageValue(fluent.getTargetAverageValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1PodsMetricSourceBuilder that = (V2beta1PodsMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricSourceFluent.java index 092f5e272b..4b8b33f167 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricSourceFluent.java @@ -1,49 +1,74 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1PodsMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1PodsMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getMetricName(); + public A withMetricName(java.lang.String metricName); + public java.lang.Boolean hasMetricName(); - - /** - * Method is deprecated. use withMetricName instead. - */ + + /** Method is deprecated. use withMetricName instead. */ @java.lang.Deprecated public A withNewMetricName(java.lang.String original); - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); - public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested editSelector(); - public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested + withNewSelector(); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested + editSelector(); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested + editOrNewSelector(); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + public io.kubernetes.client.custom.Quantity getTargetAverageValue(); + public A withTargetAverageValue(io.kubernetes.client.custom.Quantity targetAverageValue); + public java.lang.Boolean hasTargetAverageValue(); + public A withNewTargetAverageValue(java.lang.String value); - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested> { public N and(); + public N endSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricSourceFluentImpl.java index 6dd7a0f7d4..e759621713 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricSourceFluentImpl.java @@ -1,120 +1,171 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2beta1PodsMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent{ - public V2beta1PodsMetricSourceFluentImpl() { - } - public V2beta1PodsMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2beta1PodsMetricSource instance) { + +/** Generated */ +public class V2beta1PodsMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent { + public V2beta1PodsMetricSourceFluentImpl() {} + + public V2beta1PodsMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2beta1PodsMetricSource instance) { this.withMetricName(instance.getMetricName()); this.withSelector(instance.getSelector()); this.withTargetAverageValue(instance.getTargetAverageValue()); - } + private java.lang.String metricName; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder selector; private io.kubernetes.client.custom.Quantity targetAverageValue; + public java.lang.String getMetricName() { return this.metricName; } + public A withMetricName(java.lang.String metricName) { - this.metricName=metricName; return (A) this; + this.metricName = metricName; + return (A) this; } + public java.lang.Boolean hasMetricName() { return this.metricName != null; } - - /** - * Method is deprecated. use withMetricName instead. - */ + + /** Method is deprecated. use withMetricName instead. */ @java.lang.Deprecated public A withNewMetricName(java.lang.String original) { - return (A)withMetricName(new String(original)); + return (A) withMetricName(new String(original)); } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested withNewSelector() { - return new io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluentImpl.SelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested + withNewSelector() { + return new io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluentImpl + .SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluentImpl.SelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluentImpl + .SelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested editSelector() { + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested + editSelector() { return withNewSelectorLike(getSelector()); } - public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested + editOrNewSelector() { + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } + public io.kubernetes.client.custom.Quantity getTargetAverageValue() { return this.targetAverageValue; } + public A withTargetAverageValue(io.kubernetes.client.custom.Quantity targetAverageValue) { - this.targetAverageValue=targetAverageValue; return (A) this; + this.targetAverageValue = targetAverageValue; + return (A) this; } + public java.lang.Boolean hasTargetAverageValue() { return this.targetAverageValue != null; } + public A withNewTargetAverageValue(java.lang.String value) { - return (A)withTargetAverageValue(new Quantity(value)); + return (A) withTargetAverageValue(new Quantity(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta1PodsMetricSourceFluentImpl that = (V2beta1PodsMetricSourceFluentImpl) o; - if (metricName != null ? !metricName.equals(that.metricName) :that.metricName != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; - if (targetAverageValue != null ? !targetAverageValue.equals(that.targetAverageValue) :that.targetAverageValue != null) return false; + if (metricName != null ? !metricName.equals(that.metricName) : that.metricName != null) + return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; + if (targetAverageValue != null + ? !targetAverageValue.equals(that.targetAverageValue) + : that.targetAverageValue != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(metricName, selector, targetAverageValue, super.hashCode()); + return java.util.Objects.hash(metricName, selector, targetAverageValue, super.hashCode()); } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested> + implements io.kubernetes.client.openapi.models.V2beta1PodsMetricSourceFluent.SelectorNested< + N>, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V2beta1PodsMetricSourceFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricStatusBuilder.java index 50107a18e5..4055696e35 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricStatusBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1PodsMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1PodsMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus, + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusBuilder> { public V2beta1PodsMetricStatusBuilder() { this(false); } + public V2beta1PodsMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1PodsMetricStatus(), validationEnabled); } - public V2beta1PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent fluent) { + + public V2beta1PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent fluent) { this(fluent, false); } - public V2beta1PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1PodsMetricStatus(), validationEnabled); } - public V2beta1PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus instance) { + + public V2beta1PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus instance) { this(fluent, instance, false); } - public V2beta1PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCurrentAverageValue(instance.getCurrentAverageValue()); fluent.withMetricName(instance.getMetricName()); fluent.withSelector(instance.getSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus instance) { - this(instance,false); + + public V2beta1PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus instance) { + this(instance, false); } - public V2beta1PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCurrentAverageValue(instance.getCurrentAverageValue()); this.withMetricName(instance.getMetricName()); this.withSelector(instance.getSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus build() { V2beta1PodsMetricStatus buildable = new V2beta1PodsMetricStatus(); buildable.setCurrentAverageValue(fluent.getCurrentAverageValue()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus build() { buildable.setSelector(fluent.getSelector()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1PodsMetricStatusBuilder that = (V2beta1PodsMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricStatusFluent.java index 31016c6386..de1da3977b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricStatusFluent.java @@ -1,49 +1,74 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1PodsMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1PodsMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public io.kubernetes.client.custom.Quantity getCurrentAverageValue(); + public A withCurrentAverageValue(io.kubernetes.client.custom.Quantity currentAverageValue); + public java.lang.Boolean hasCurrentAverageValue(); + public A withNewCurrentAverageValue(java.lang.String value); + public java.lang.String getMetricName(); + public A withMetricName(java.lang.String metricName); + public java.lang.Boolean hasMetricName(); - - /** - * Method is deprecated. use withMetricName instead. - */ + + /** Method is deprecated. use withMetricName instead. */ @java.lang.Deprecated public A withNewMetricName(java.lang.String original); - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); - public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested editSelector(); - public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested + withNewSelector(); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested + editSelector(); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested + editOrNewSelector(); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested> { public N and(); + public N endSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricStatusFluentImpl.java index e9be71dc21..ebec8ae1dc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1PodsMetricStatusFluentImpl.java @@ -1,120 +1,171 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2beta1PodsMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent{ - public V2beta1PodsMetricStatusFluentImpl() { - } - public V2beta1PodsMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus instance) { + +/** Generated */ +public class V2beta1PodsMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent { + public V2beta1PodsMetricStatusFluentImpl() {} + + public V2beta1PodsMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatus instance) { this.withCurrentAverageValue(instance.getCurrentAverageValue()); this.withMetricName(instance.getMetricName()); this.withSelector(instance.getSelector()); - } + private io.kubernetes.client.custom.Quantity currentAverageValue; private java.lang.String metricName; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder selector; + public io.kubernetes.client.custom.Quantity getCurrentAverageValue() { return this.currentAverageValue; } + public A withCurrentAverageValue(io.kubernetes.client.custom.Quantity currentAverageValue) { - this.currentAverageValue=currentAverageValue; return (A) this; + this.currentAverageValue = currentAverageValue; + return (A) this; } + public java.lang.Boolean hasCurrentAverageValue() { return this.currentAverageValue != null; } + public A withNewCurrentAverageValue(java.lang.String value) { - return (A)withCurrentAverageValue(new Quantity(value)); + return (A) withCurrentAverageValue(new Quantity(value)); } + public java.lang.String getMetricName() { return this.metricName; } + public A withMetricName(java.lang.String metricName) { - this.metricName=metricName; return (A) this; + this.metricName = metricName; + return (A) this; } + public java.lang.Boolean hasMetricName() { return this.metricName != null; } - - /** - * Method is deprecated. use withMetricName instead. - */ + + /** Method is deprecated. use withMetricName instead. */ @java.lang.Deprecated public A withNewMetricName(java.lang.String original) { - return (A)withMetricName(new String(original)); + return (A) withMetricName(new String(original)); } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested withNewSelector() { - return new io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluentImpl.SelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested + withNewSelector() { + return new io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluentImpl + .SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluentImpl.SelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluentImpl + .SelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested editSelector() { + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested + editSelector() { return withNewSelectorLike(getSelector()); } - public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested + editOrNewSelector() { + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta1PodsMetricStatusFluentImpl that = (V2beta1PodsMetricStatusFluentImpl) o; - if (currentAverageValue != null ? !currentAverageValue.equals(that.currentAverageValue) :that.currentAverageValue != null) return false; - if (metricName != null ? !metricName.equals(that.metricName) :that.metricName != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; + if (currentAverageValue != null + ? !currentAverageValue.equals(that.currentAverageValue) + : that.currentAverageValue != null) return false; + if (metricName != null ? !metricName.equals(that.metricName) : that.metricName != null) + return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(currentAverageValue, metricName, selector, super.hashCode()); + return java.util.Objects.hash(currentAverageValue, metricName, selector, super.hashCode()); } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested> + implements io.kubernetes.client.openapi.models.V2beta1PodsMetricStatusFluent.SelectorNested< + N>, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V2beta1PodsMetricStatusFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricSourceBuilder.java index f379b66df2..fc9db82760 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricSourceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1ResourceMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1ResourceMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource, + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceBuilder> { public V2beta1ResourceMetricSourceBuilder() { this(false); } + public V2beta1ResourceMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1ResourceMetricSource(), validationEnabled); } - public V2beta1ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent fluent) { + + public V2beta1ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent fluent) { this(fluent, false); } - public V2beta1ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1ResourceMetricSource(), validationEnabled); } - public V2beta1ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource instance) { + + public V2beta1ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource instance) { this(fluent, instance, false); } - public V2beta1ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withTargetAverageUtilization(instance.getTargetAverageUtilization()); fluent.withTargetAverageValue(instance.getTargetAverageValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource instance) { - this(instance,false); + + public V2beta1ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource instance) { + this(instance, false); } - public V2beta1ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withTargetAverageUtilization(instance.getTargetAverageUtilization()); this.withTargetAverageValue(instance.getTargetAverageValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource build() { V2beta1ResourceMetricSource buildable = new V2beta1ResourceMetricSource(); buildable.setName(fluent.getName()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource build() { buildable.setTargetAverageValue(fluent.getTargetAverageValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1ResourceMetricSourceBuilder that = (V2beta1ResourceMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricSourceFluent.java index 63d1526bbc..78adff8719 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricSourceFluent.java @@ -1,32 +1,42 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1ResourceMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1ResourceMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); + public java.lang.Integer getTargetAverageUtilization(); + public A withTargetAverageUtilization(java.lang.Integer targetAverageUtilization); + public java.lang.Boolean hasTargetAverageUtilization(); + public io.kubernetes.client.custom.Quantity getTargetAverageValue(); + public A withTargetAverageValue(io.kubernetes.client.custom.Quantity targetAverageValue); + public java.lang.Boolean hasTargetAverageValue(); + public A withNewTargetAverageValue(java.lang.String value); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricSourceFluentImpl.java index 86d6d69f6a..2dfbf10d7f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricSourceFluentImpl.java @@ -1,79 +1,104 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2beta1ResourceMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent{ - public V2beta1ResourceMetricSourceFluentImpl() { - } - public V2beta1ResourceMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource instance) { + +/** Generated */ +public class V2beta1ResourceMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1ResourceMetricSourceFluent { + public V2beta1ResourceMetricSourceFluentImpl() {} + + public V2beta1ResourceMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricSource instance) { this.withName(instance.getName()); this.withTargetAverageUtilization(instance.getTargetAverageUtilization()); this.withTargetAverageValue(instance.getTargetAverageValue()); - } + private java.lang.String name; private java.lang.Integer targetAverageUtilization; private io.kubernetes.client.custom.Quantity targetAverageValue; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public java.lang.Integer getTargetAverageUtilization() { return this.targetAverageUtilization; } + public A withTargetAverageUtilization(java.lang.Integer targetAverageUtilization) { - this.targetAverageUtilization=targetAverageUtilization; return (A) this; + this.targetAverageUtilization = targetAverageUtilization; + return (A) this; } + public java.lang.Boolean hasTargetAverageUtilization() { return this.targetAverageUtilization != null; } + public io.kubernetes.client.custom.Quantity getTargetAverageValue() { return this.targetAverageValue; } + public A withTargetAverageValue(io.kubernetes.client.custom.Quantity targetAverageValue) { - this.targetAverageValue=targetAverageValue; return (A) this; + this.targetAverageValue = targetAverageValue; + return (A) this; } + public java.lang.Boolean hasTargetAverageValue() { return this.targetAverageValue != null; } + public A withNewTargetAverageValue(java.lang.String value) { - return (A)withTargetAverageValue(new Quantity(value)); + return (A) withTargetAverageValue(new Quantity(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta1ResourceMetricSourceFluentImpl that = (V2beta1ResourceMetricSourceFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (targetAverageUtilization != null ? !targetAverageUtilization.equals(that.targetAverageUtilization) :that.targetAverageUtilization != null) return false; - if (targetAverageValue != null ? !targetAverageValue.equals(that.targetAverageValue) :that.targetAverageValue != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (targetAverageUtilization != null + ? !targetAverageUtilization.equals(that.targetAverageUtilization) + : that.targetAverageUtilization != null) return false; + if (targetAverageValue != null + ? !targetAverageValue.equals(that.targetAverageValue) + : that.targetAverageValue != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, targetAverageUtilization, targetAverageValue, super.hashCode()); + return java.util.Objects.hash( + name, targetAverageUtilization, targetAverageValue, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricStatusBuilder.java index 36b0e1c13b..9cd8b0de27 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricStatusBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta1ResourceMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta1ResourceMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus, + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusBuilder> { public V2beta1ResourceMetricStatusBuilder() { this(false); } + public V2beta1ResourceMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta1ResourceMetricStatus(), validationEnabled); } - public V2beta1ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent fluent) { + + public V2beta1ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent fluent) { this(fluent, false); } - public V2beta1ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta1ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta1ResourceMetricStatus(), validationEnabled); } - public V2beta1ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus instance) { + + public V2beta1ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus instance) { this(fluent, instance, false); } - public V2beta1ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta1ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCurrentAverageUtilization(instance.getCurrentAverageUtilization()); fluent.withCurrentAverageValue(instance.getCurrentAverageValue()); fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta1ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus instance) { - this(instance,false); + + public V2beta1ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus instance) { + this(instance, false); } - public V2beta1ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta1ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCurrentAverageUtilization(instance.getCurrentAverageUtilization()); this.withCurrentAverageValue(instance.getCurrentAverageValue()); this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus build() { V2beta1ResourceMetricStatus buildable = new V2beta1ResourceMetricStatus(); buildable.setCurrentAverageUtilization(fluent.getCurrentAverageUtilization()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus build() { buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta1ResourceMetricStatusBuilder that = (V2beta1ResourceMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricStatusFluent.java index 0aff3fb784..4ac607197d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricStatusFluent.java @@ -1,32 +1,42 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta1ResourceMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta1ResourceMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getCurrentAverageUtilization(); + public A withCurrentAverageUtilization(java.lang.Integer currentAverageUtilization); + public java.lang.Boolean hasCurrentAverageUtilization(); + public io.kubernetes.client.custom.Quantity getCurrentAverageValue(); + public A withCurrentAverageValue(io.kubernetes.client.custom.Quantity currentAverageValue); + public java.lang.Boolean hasCurrentAverageValue(); + public A withNewCurrentAverageValue(java.lang.String value); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricStatusFluentImpl.java index 8e19cf9fe5..4b1b9d83f0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta1ResourceMetricStatusFluentImpl.java @@ -1,79 +1,104 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2beta1ResourceMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent{ - public V2beta1ResourceMetricStatusFluentImpl() { - } - public V2beta1ResourceMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus instance) { + +/** Generated */ +public class V2beta1ResourceMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatusFluent { + public V2beta1ResourceMetricStatusFluentImpl() {} + + public V2beta1ResourceMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta1ResourceMetricStatus instance) { this.withCurrentAverageUtilization(instance.getCurrentAverageUtilization()); this.withCurrentAverageValue(instance.getCurrentAverageValue()); this.withName(instance.getName()); - } + private java.lang.Integer currentAverageUtilization; private io.kubernetes.client.custom.Quantity currentAverageValue; private java.lang.String name; + public java.lang.Integer getCurrentAverageUtilization() { return this.currentAverageUtilization; } + public A withCurrentAverageUtilization(java.lang.Integer currentAverageUtilization) { - this.currentAverageUtilization=currentAverageUtilization; return (A) this; + this.currentAverageUtilization = currentAverageUtilization; + return (A) this; } + public java.lang.Boolean hasCurrentAverageUtilization() { return this.currentAverageUtilization != null; } + public io.kubernetes.client.custom.Quantity getCurrentAverageValue() { return this.currentAverageValue; } + public A withCurrentAverageValue(io.kubernetes.client.custom.Quantity currentAverageValue) { - this.currentAverageValue=currentAverageValue; return (A) this; + this.currentAverageValue = currentAverageValue; + return (A) this; } + public java.lang.Boolean hasCurrentAverageValue() { return this.currentAverageValue != null; } + public A withNewCurrentAverageValue(java.lang.String value) { - return (A)withCurrentAverageValue(new Quantity(value)); + return (A) withCurrentAverageValue(new Quantity(value)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta1ResourceMetricStatusFluentImpl that = (V2beta1ResourceMetricStatusFluentImpl) o; - if (currentAverageUtilization != null ? !currentAverageUtilization.equals(that.currentAverageUtilization) :that.currentAverageUtilization != null) return false; - if (currentAverageValue != null ? !currentAverageValue.equals(that.currentAverageValue) :that.currentAverageValue != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (currentAverageUtilization != null + ? !currentAverageUtilization.equals(that.currentAverageUtilization) + : that.currentAverageUtilization != null) return false; + if (currentAverageValue != null + ? !currentAverageValue.equals(that.currentAverageValue) + : that.currentAverageValue != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(currentAverageUtilization, currentAverageValue, name, super.hashCode()); + return java.util.Objects.hash( + currentAverageUtilization, currentAverageValue, name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricSourceBuilder.java index 76a6f5b742..c01e33c1bc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricSourceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2ContainerResourceMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2ContainerResourceMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource, + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceBuilder> { public V2beta2ContainerResourceMetricSourceBuilder() { this(false); } + public V2beta2ContainerResourceMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2ContainerResourceMetricSource(), validationEnabled); } - public V2beta2ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent fluent) { + + public V2beta2ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent fluent) { this(fluent, false); } - public V2beta2ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2ContainerResourceMetricSource(), validationEnabled); } - public V2beta2ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource instance) { + + public V2beta2ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource instance) { this(fluent, instance, false); } - public V2beta2ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainer(instance.getContainer()); fluent.withName(instance.getName()); fluent.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource instance) { - this(instance,false); + + public V2beta2ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource instance) { + this(instance, false); } - public V2beta2ContainerResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2ContainerResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainer(instance.getContainer()); this.withName(instance.getName()); this.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource build() { V2beta2ContainerResourceMetricSource buildable = new V2beta2ContainerResourceMetricSource(); buildable.setContainer(fluent.getContainer()); @@ -51,18 +85,24 @@ public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource buildable.setTarget(fluent.getTarget()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V2beta2ContainerResourceMetricSourceBuilder that = (V2beta2ContainerResourceMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V2beta2ContainerResourceMetricSourceBuilder that = + (V2beta2ContainerResourceMetricSourceBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricSourceFluent.java index 80b4a878da..a25d9e8f32 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricSourceFluent.java @@ -1,53 +1,88 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2ContainerResourceMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta2ContainerResourceMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getContainer(); + public A withContainer(java.lang.String container); + public java.lang.Boolean hasContainer(); - - /** - * Method is deprecated. use withContainer instead. - */ + + /** Method is deprecated. use withContainer instead. */ @java.lang.Deprecated public A withNewContainer(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricTarget getTarget(); + public io.kubernetes.client.openapi.models.V2beta2MetricTarget buildTarget(); + public A withTarget(io.kubernetes.client.openapi.models.V2beta2MetricTarget target); + public java.lang.Boolean hasTarget(); - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent.TargetNested withNewTarget(); - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent.TargetNested editTarget(); - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent.TargetNested editOrNewTarget(); - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); - public interface TargetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent>{ + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent + .TargetNested< + A> + withNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent + .TargetNested< + A> + withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent + .TargetNested< + A> + editTarget(); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent + .TargetNested< + A> + editOrNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent + .TargetNested< + A> + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); + + public interface TargetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent< + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent + .TargetNested< + N>> { public N and(); + public N endTarget(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricSourceFluentImpl.java index 573e24b8d3..cb62594b6c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricSourceFluentImpl.java @@ -1,124 +1,183 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta2ContainerResourceMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent { + public V2beta2ContainerResourceMetricSourceFluentImpl() {} - /** - * Generated - */ -public class V2beta2ContainerResourceMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent{ - public V2beta2ContainerResourceMetricSourceFluentImpl() { - } - public V2beta2ContainerResourceMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource instance) { + public V2beta2ContainerResourceMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource instance) { this.withContainer(instance.getContainer()); this.withName(instance.getName()); this.withTarget(instance.getTarget()); - } + private java.lang.String container; private java.lang.String name; private io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder target; + public java.lang.String getContainer() { return this.container; } + public A withContainer(java.lang.String container) { - this.container=container; return (A) this; + this.container = container; + return (A) this; } + public java.lang.Boolean hasContainer() { return this.container != null; } - - /** - * Method is deprecated. use withContainer instead. - */ + + /** Method is deprecated. use withContainer instead. */ @java.lang.Deprecated public A withNewContainer(java.lang.String original) { - return (A)withContainer(new String(original)); + return (A) withContainer(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricTarget getTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricTarget buildTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public A withTarget(io.kubernetes.client.openapi.models.V2beta2MetricTarget target) { _visitables.get("target").remove(this.target); - if (target!=null){ this.target= new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(target); _visitables.get("target").add(this.target);} return (A) this; + if (target != null) { + this.target = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(target); + _visitables.get("target").add(this.target); + } + return (A) this; } + public java.lang.Boolean hasTarget() { return this.target != null; } - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent.TargetNested withNewTarget() { - return new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluentImpl.TargetNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent + .TargetNested< + A> + withNewTarget() { + return new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluentImpl + .TargetNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { - return new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluentImpl.TargetNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent + .TargetNested< + A> + withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { + return new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluentImpl + .TargetNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent.TargetNested editTarget() { + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent + .TargetNested< + A> + editTarget() { return withNewTargetLike(getTarget()); } - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent.TargetNested editOrNewTarget() { - return withNewTargetLike(getTarget() != null ? getTarget(): new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent + .TargetNested< + A> + editOrNewTarget() { + return withNewTargetLike( + getTarget() != null + ? getTarget() + : new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { - return withNewTargetLike(getTarget() != null ? getTarget(): item); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent + .TargetNested< + A> + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { + return withNewTargetLike(getTarget() != null ? getTarget() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2beta2ContainerResourceMetricSourceFluentImpl that = (V2beta2ContainerResourceMetricSourceFluentImpl) o; - if (container != null ? !container.equals(that.container) :that.container != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (target != null ? !target.equals(that.target) :that.target != null) return false; + V2beta2ContainerResourceMetricSourceFluentImpl that = + (V2beta2ContainerResourceMetricSourceFluentImpl) o; + if (container != null ? !container.equals(that.container) : that.container != null) + return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (target != null ? !target.equals(that.target) : that.target != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(container, name, target, super.hashCode()); + return java.util.Objects.hash(container, name, target, super.hashCode()); } - public class TargetNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent.TargetNested,io.kubernetes.client.fluent.Nested{ + + public class TargetNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent + .TargetNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent + .TargetNested< + N>, + io.kubernetes.client.fluent.Nested { TargetNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(this, item); } + TargetNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder builder; + public N and() { return (N) V2beta2ContainerResourceMetricSourceFluentImpl.this.withTarget(builder.build()); } + public N endTarget() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricStatusBuilder.java index 9f70a2fc25..01f47f7e56 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricStatusBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2ContainerResourceMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2ContainerResourceMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus, + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusBuilder> { public V2beta2ContainerResourceMetricStatusBuilder() { this(false); } + public V2beta2ContainerResourceMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2ContainerResourceMetricStatus(), validationEnabled); } - public V2beta2ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent fluent) { + + public V2beta2ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent fluent) { this(fluent, false); } - public V2beta2ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2ContainerResourceMetricStatus(), validationEnabled); } - public V2beta2ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus instance) { + + public V2beta2ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus instance) { this(fluent, instance, false); } - public V2beta2ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainer(instance.getContainer()); fluent.withCurrent(instance.getCurrent()); fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus instance) { - this(instance,false); + + public V2beta2ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus instance) { + this(instance, false); } - public V2beta2ContainerResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2ContainerResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainer(instance.getContainer()); this.withCurrent(instance.getCurrent()); this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus build() { V2beta2ContainerResourceMetricStatus buildable = new V2beta2ContainerResourceMetricStatus(); buildable.setContainer(fluent.getContainer()); @@ -51,18 +85,24 @@ public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V2beta2ContainerResourceMetricStatusBuilder that = (V2beta2ContainerResourceMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V2beta2ContainerResourceMetricStatusBuilder that = + (V2beta2ContainerResourceMetricStatusBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricStatusFluent.java index 311e3239a0..3de988f053 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricStatusFluent.java @@ -1,53 +1,88 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2ContainerResourceMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta2ContainerResourceMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getContainer(); + public A withContainer(java.lang.String container); + public java.lang.Boolean hasContainer(); - - /** - * Method is deprecated. use withContainer instead. - */ + + /** Method is deprecated. use withContainer instead. */ @java.lang.Deprecated public A withNewContainer(java.lang.String original); - + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus getCurrent(); + public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus buildCurrent(); + public A withCurrent(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus current); + public java.lang.Boolean hasCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent.CurrentNested withNewCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent.CurrentNested editCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent.CurrentNested editOrNewCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent + .CurrentNested< + A> + withNewCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent + .CurrentNested< + A> + withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent + .CurrentNested< + A> + editCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent + .CurrentNested< + A> + editOrNewCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent + .CurrentNested< + A> + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - public interface CurrentNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent>{ + + public interface CurrentNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent< + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent + .CurrentNested< + N>> { public N and(); + public N endCurrent(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricStatusFluentImpl.java index b51b2cfdca..eade136fb3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ContainerResourceMetricStatusFluentImpl.java @@ -1,124 +1,185 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta2ContainerResourceMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent { + public V2beta2ContainerResourceMetricStatusFluentImpl() {} - /** - * Generated - */ -public class V2beta2ContainerResourceMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent{ - public V2beta2ContainerResourceMetricStatusFluentImpl() { - } - public V2beta2ContainerResourceMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus instance) { + public V2beta2ContainerResourceMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus instance) { this.withContainer(instance.getContainer()); this.withCurrent(instance.getCurrent()); this.withName(instance.getName()); - } + private java.lang.String container; private io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder current; private java.lang.String name; + public java.lang.String getContainer() { return this.container; } + public A withContainer(java.lang.String container) { - this.container=container; return (A) this; + this.container = container; + return (A) this; } + public java.lang.Boolean hasContainer() { return this.container != null; } - - /** - * Method is deprecated. use withContainer instead. - */ + + /** Method is deprecated. use withContainer instead. */ @java.lang.Deprecated public A withNewContainer(java.lang.String original) { - return (A)withContainer(new String(original)); + return (A) withContainer(new String(original)); } - + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus getCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus buildCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public A withCurrent(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus current) { _visitables.get("current").remove(this.current); - if (current!=null){ this.current= new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(current); _visitables.get("current").add(this.current);} return (A) this; + if (current != null) { + this.current = + new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(current); + _visitables.get("current").add(this.current); + } + return (A) this; } + public java.lang.Boolean hasCurrent() { return this.current != null; } - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent.CurrentNested withNewCurrent() { - return new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluentImpl.CurrentNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent + .CurrentNested< + A> + withNewCurrent() { + return new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluentImpl + .CurrentNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - return new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluentImpl.CurrentNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent + .CurrentNested< + A> + withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { + return new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluentImpl + .CurrentNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent.CurrentNested editCurrent() { + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent + .CurrentNested< + A> + editCurrent() { return withNewCurrentLike(getCurrent()); } - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent.CurrentNested editOrNewCurrent() { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent + .CurrentNested< + A> + editOrNewCurrent() { + return withNewCurrentLike( + getCurrent() != null + ? getCurrent() + : new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): item); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent + .CurrentNested< + A> + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { + return withNewCurrentLike(getCurrent() != null ? getCurrent() : item); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2beta2ContainerResourceMetricStatusFluentImpl that = (V2beta2ContainerResourceMetricStatusFluentImpl) o; - if (container != null ? !container.equals(that.container) :that.container != null) return false; - if (current != null ? !current.equals(that.current) :that.current != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + V2beta2ContainerResourceMetricStatusFluentImpl that = + (V2beta2ContainerResourceMetricStatusFluentImpl) o; + if (container != null ? !container.equals(that.container) : that.container != null) + return false; + if (current != null ? !current.equals(that.current) : that.current != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(container, current, name, super.hashCode()); + return java.util.Objects.hash(container, current, name, super.hashCode()); } - public class CurrentNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent.CurrentNested,io.kubernetes.client.fluent.Nested{ + + public class CurrentNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent + .CurrentNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent + .CurrentNested< + N>, + io.kubernetes.client.fluent.Nested { CurrentNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this, item); } + CurrentNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder builder; + public N and() { return (N) V2beta2ContainerResourceMetricStatusFluentImpl.this.withCurrent(builder.build()); } + public N endCurrent() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2CrossVersionObjectReferenceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2CrossVersionObjectReferenceBuilder.java index 783297eb60..82deb6f95f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2CrossVersionObjectReferenceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2CrossVersionObjectReferenceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2CrossVersionObjectReferenceBuilder extends io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2CrossVersionObjectReferenceBuilder + extends io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference, + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder> { public V2beta2CrossVersionObjectReferenceBuilder() { this(false); } + public V2beta2CrossVersionObjectReferenceBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2CrossVersionObjectReference(), validationEnabled); } - public V2beta2CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent fluent) { + + public V2beta2CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent fluent) { this(fluent, false); } - public V2beta2CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2CrossVersionObjectReference(), validationEnabled); } - public V2beta2CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference instance) { + + public V2beta2CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference instance) { this(fluent, instance, false); } - public V2beta2CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent fluent,io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent fluent, + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference instance) { - this(instance,false); + + public V2beta2CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference instance) { + this(instance, false); } - public V2beta2CrossVersionObjectReferenceBuilder(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2CrossVersionObjectReferenceBuilder( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference build() { V2beta2CrossVersionObjectReference buildable = new V2beta2CrossVersionObjectReference(); buildable.setApiVersion(fluent.getApiVersion()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference bu buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2CrossVersionObjectReferenceBuilder that = (V2beta2CrossVersionObjectReferenceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2CrossVersionObjectReferenceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2CrossVersionObjectReferenceFluent.java index 10f5acfa3b..1c6373246a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2CrossVersionObjectReferenceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2CrossVersionObjectReferenceFluent.java @@ -1,41 +1,48 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2CrossVersionObjectReferenceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta2CrossVersionObjectReferenceFluent< + A extends io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2CrossVersionObjectReferenceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2CrossVersionObjectReferenceFluentImpl.java index 14cf455714..67ee575af3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2CrossVersionObjectReferenceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2CrossVersionObjectReferenceFluentImpl.java @@ -1,90 +1,107 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2beta2CrossVersionObjectReferenceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent{ - public V2beta2CrossVersionObjectReferenceFluentImpl() { - } - public V2beta2CrossVersionObjectReferenceFluentImpl(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference instance) { +/** Generated */ +public class V2beta2CrossVersionObjectReferenceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent { + public V2beta2CrossVersionObjectReferenceFluentImpl() {} + + public V2beta2CrossVersionObjectReferenceFluentImpl( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); this.withName(instance.getName()); - } + private java.lang.String apiVersion; private java.lang.String kind; private java.lang.String name; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2beta2CrossVersionObjectReferenceFluentImpl that = (V2beta2CrossVersionObjectReferenceFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + V2beta2CrossVersionObjectReferenceFluentImpl that = + (V2beta2CrossVersionObjectReferenceFluentImpl) o; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, name, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, name, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricSourceBuilder.java index 6341ccef03..3886b6df23 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2ExternalMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2ExternalMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource, + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceBuilder> { public V2beta2ExternalMetricSourceBuilder() { this(false); } + public V2beta2ExternalMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2ExternalMetricSource(), validationEnabled); } - public V2beta2ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent fluent) { + + public V2beta2ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent fluent) { this(fluent, false); } - public V2beta2ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2ExternalMetricSource(), validationEnabled); } - public V2beta2ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource instance) { + + public V2beta2ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource instance) { this(fluent, instance, false); } - public V2beta2ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMetric(instance.getMetric()); fluent.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource instance) { - this(instance,false); + + public V2beta2ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource instance) { + this(instance, false); } - public V2beta2ExternalMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2ExternalMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMetric(instance.getMetric()); this.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource build() { V2beta2ExternalMetricSource buildable = new V2beta2ExternalMetricSource(); buildable.setMetric(fluent.getMetric()); buildable.setTarget(fluent.getTarget()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2ExternalMetricSourceBuilder that = (V2beta2ExternalMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricSourceFluent.java index e8c952f663..3fd0b51ed2 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricSourceFluent.java @@ -1,55 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2ExternalMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2beta2ExternalMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier getMetric(); + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier buildMetric(); + public A withMetric(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier metric); + public java.lang.Boolean hasMetric(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested withNewMetric(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested editMetric(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested editOrNewMetric(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); - + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested + withNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested + editMetric(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested + editOrNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricTarget getTarget(); + public io.kubernetes.client.openapi.models.V2beta2MetricTarget buildTarget(); + public A withTarget(io.kubernetes.client.openapi.models.V2beta2MetricTarget target); + public java.lang.Boolean hasTarget(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested withNewTarget(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested editTarget(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested editOrNewTarget(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); - public interface MetricNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent>{ + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested + withNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested + editTarget(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested + editOrNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); + + public interface MetricNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent< + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested< + N>> { public N and(); + public N endMetric(); - } - public interface TargetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent>{ + + public interface TargetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent< + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested< + N>> { public N and(); + public N endTarget(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricSourceFluentImpl.java index 62bc1e8b9c..4a7e987d6a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricSourceFluentImpl.java @@ -1,135 +1,209 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta2ExternalMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent { + public V2beta2ExternalMetricSourceFluentImpl() {} - /** - * Generated - */ -public class V2beta2ExternalMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent{ - public V2beta2ExternalMetricSourceFluentImpl() { - } - public V2beta2ExternalMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource instance) { + public V2beta2ExternalMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource instance) { this.withMetric(instance.getMetric()); this.withTarget(instance.getTarget()); - } + private io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder metric; private io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder target; - + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier getMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier buildMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public A withMetric(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier metric) { _visitables.get("metric").remove(this.metric); - if (metric!=null){ this.metric= new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(metric); _visitables.get("metric").add(this.metric);} return (A) this; + if (metric != null) { + this.metric = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(metric); + _visitables.get("metric").add(this.metric); + } + return (A) this; } + public java.lang.Boolean hasMetric() { return this.metric != null; } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested withNewMetric() { - return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluentImpl.MetricNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested + withNewMetric() { + return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluentImpl + .MetricNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluentImpl.MetricNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { + return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluentImpl + .MetricNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested editMetric() { + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested + editMetric() { return withNewMetricLike(getMetric()); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested editOrNewMetric() { - return withNewMetricLike(getMetric() != null ? getMetric(): new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested + editOrNewMetric() { + return withNewMetricLike( + getMetric() != null + ? getMetric() + : new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - return withNewMetricLike(getMetric() != null ? getMetric(): item); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { + return withNewMetricLike(getMetric() != null ? getMetric() : item); } - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricTarget getTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricTarget buildTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public A withTarget(io.kubernetes.client.openapi.models.V2beta2MetricTarget target) { _visitables.get("target").remove(this.target); - if (target!=null){ this.target= new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(target); _visitables.get("target").add(this.target);} return (A) this; + if (target != null) { + this.target = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(target); + _visitables.get("target").add(this.target); + } + return (A) this; } + public java.lang.Boolean hasTarget() { return this.target != null; } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested withNewTarget() { - return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluentImpl.TargetNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested + withNewTarget() { + return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluentImpl + .TargetNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { - return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluentImpl.TargetNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { + return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluentImpl + .TargetNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested editTarget() { + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested + editTarget() { return withNewTargetLike(getTarget()); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested editOrNewTarget() { - return withNewTargetLike(getTarget() != null ? getTarget(): new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested + editOrNewTarget() { + return withNewTargetLike( + getTarget() != null + ? getTarget() + : new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { - return withNewTargetLike(getTarget() != null ? getTarget(): item); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { + return withNewTargetLike(getTarget() != null ? getTarget() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2ExternalMetricSourceFluentImpl that = (V2beta2ExternalMetricSourceFluentImpl) o; - if (metric != null ? !metric.equals(that.metric) :that.metric != null) return false; - if (target != null ? !target.equals(that.target) :that.target != null) return false; + if (metric != null ? !metric.equals(that.metric) : that.metric != null) return false; + if (target != null ? !target.equals(that.target) : that.target != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(metric, target, super.hashCode()); + return java.util.Objects.hash(metric, target, super.hashCode()); } - public class MetricNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested,io.kubernetes.client.fluent.Nested{ + + public class MetricNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested> + implements io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.MetricNested< + N>, + io.kubernetes.client.fluent.Nested { MetricNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this, item); } + MetricNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder builder; + public N and() { return (N) V2beta2ExternalMetricSourceFluentImpl.this.withMetric(builder.build()); } + public N endMetric() { return and(); } - } - public class TargetNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested,io.kubernetes.client.fluent.Nested{ + + public class TargetNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested> + implements io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent.TargetNested< + N>, + io.kubernetes.client.fluent.Nested { TargetNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(this, item); } + TargetNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder builder; + public N and() { return (N) V2beta2ExternalMetricSourceFluentImpl.this.withTarget(builder.build()); } + public N endTarget() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricStatusBuilder.java index 7258bcedf7..a778e428f0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricStatusBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2ExternalMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2ExternalMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus, + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusBuilder> { public V2beta2ExternalMetricStatusBuilder() { this(false); } + public V2beta2ExternalMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2ExternalMetricStatus(), validationEnabled); } - public V2beta2ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent fluent) { + + public V2beta2ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent fluent) { this(fluent, false); } - public V2beta2ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2ExternalMetricStatus(), validationEnabled); } - public V2beta2ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus instance) { + + public V2beta2ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus instance) { this(fluent, instance, false); } - public V2beta2ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCurrent(instance.getCurrent()); fluent.withMetric(instance.getMetric()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus instance) { - this(instance,false); + + public V2beta2ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus instance) { + this(instance, false); } - public V2beta2ExternalMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2ExternalMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCurrent(instance.getCurrent()); this.withMetric(instance.getMetric()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus build() { V2beta2ExternalMetricStatus buildable = new V2beta2ExternalMetricStatus(); buildable.setCurrent(fluent.getCurrent()); buildable.setMetric(fluent.getMetric()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2ExternalMetricStatusBuilder that = (V2beta2ExternalMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricStatusFluent.java index f1e03e0e6d..a3f6484b33 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricStatusFluent.java @@ -1,55 +1,97 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2ExternalMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2beta2ExternalMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus getCurrent(); + public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus buildCurrent(); + public A withCurrent(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus current); + public java.lang.Boolean hasCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested withNewCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested editCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested editOrNewCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); - + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested + withNewCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested + editCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested + editOrNewCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier getMetric(); + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier buildMetric(); + public A withMetric(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier metric); + public java.lang.Boolean hasMetric(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested withNewMetric(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested editMetric(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested editOrNewMetric(); - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); - public interface CurrentNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent>{ + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested + withNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested + editMetric(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested + editOrNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); + + public interface CurrentNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent< + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested< + N>> { public N and(); + public N endCurrent(); - } - public interface MetricNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent>{ + + public interface MetricNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent< + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested< + N>> { public N and(); + public N endMetric(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricStatusFluentImpl.java index 96c15075af..fe5913f2cd 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ExternalMetricStatusFluentImpl.java @@ -1,135 +1,212 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta2ExternalMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent { + public V2beta2ExternalMetricStatusFluentImpl() {} - /** - * Generated - */ -public class V2beta2ExternalMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent{ - public V2beta2ExternalMetricStatusFluentImpl() { - } - public V2beta2ExternalMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus instance) { + public V2beta2ExternalMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus instance) { this.withCurrent(instance.getCurrent()); this.withMetric(instance.getMetric()); - } + private io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder current; private io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder metric; - + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus getCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus buildCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public A withCurrent(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus current) { _visitables.get("current").remove(this.current); - if (current!=null){ this.current= new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(current); _visitables.get("current").add(this.current);} return (A) this; + if (current != null) { + this.current = + new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(current); + _visitables.get("current").add(this.current); + } + return (A) this; } + public java.lang.Boolean hasCurrent() { return this.current != null; } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested withNewCurrent() { - return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluentImpl.CurrentNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested + withNewCurrent() { + return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluentImpl + .CurrentNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluentImpl.CurrentNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { + return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluentImpl + .CurrentNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested editCurrent() { + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested + editCurrent() { return withNewCurrentLike(getCurrent()); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested editOrNewCurrent() { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested + editOrNewCurrent() { + return withNewCurrentLike( + getCurrent() != null + ? getCurrent() + : new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): item); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { + return withNewCurrentLike(getCurrent() != null ? getCurrent() : item); } - + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier getMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier buildMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public A withMetric(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier metric) { _visitables.get("metric").remove(this.metric); - if (metric!=null){ this.metric= new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(metric); _visitables.get("metric").add(this.metric);} return (A) this; + if (metric != null) { + this.metric = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(metric); + _visitables.get("metric").add(this.metric); + } + return (A) this; } + public java.lang.Boolean hasMetric() { return this.metric != null; } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested withNewMetric() { - return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluentImpl.MetricNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested + withNewMetric() { + return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluentImpl + .MetricNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluentImpl.MetricNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { + return new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluentImpl + .MetricNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested editMetric() { + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested + editMetric() { return withNewMetricLike(getMetric()); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested editOrNewMetric() { - return withNewMetricLike(getMetric() != null ? getMetric(): new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested + editOrNewMetric() { + return withNewMetricLike( + getMetric() != null + ? getMetric() + : new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - return withNewMetricLike(getMetric() != null ? getMetric(): item); + + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { + return withNewMetricLike(getMetric() != null ? getMetric() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2ExternalMetricStatusFluentImpl that = (V2beta2ExternalMetricStatusFluentImpl) o; - if (current != null ? !current.equals(that.current) :that.current != null) return false; - if (metric != null ? !metric.equals(that.metric) :that.metric != null) return false; + if (current != null ? !current.equals(that.current) : that.current != null) return false; + if (metric != null ? !metric.equals(that.metric) : that.metric != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(current, metric, super.hashCode()); + return java.util.Objects.hash(current, metric, super.hashCode()); } - public class CurrentNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested,io.kubernetes.client.fluent.Nested{ + + public class CurrentNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.CurrentNested> + implements io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent + .CurrentNested< + N>, + io.kubernetes.client.fluent.Nested { CurrentNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this, item); } + CurrentNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder builder; + public N and() { return (N) V2beta2ExternalMetricStatusFluentImpl.this.withCurrent(builder.build()); } + public N endCurrent() { return and(); } - } - public class MetricNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested,io.kubernetes.client.fluent.Nested{ + + public class MetricNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested> + implements io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent.MetricNested< + N>, + io.kubernetes.client.fluent.Nested { MetricNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this, item); } + MetricNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder builder; + public N and() { return (N) V2beta2ExternalMetricStatusFluentImpl.this.withMetric(builder.build()); } + public N endMetric() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingPolicyBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingPolicyBuilder.java index 1611fc0975..a44b16c57a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingPolicyBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingPolicyBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2HPAScalingPolicyBuilder extends io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2HPAScalingPolicyBuilder + extends io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy, + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder> { public V2beta2HPAScalingPolicyBuilder() { this(false); } + public V2beta2HPAScalingPolicyBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2HPAScalingPolicy(), validationEnabled); } - public V2beta2HPAScalingPolicyBuilder(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent fluent) { + + public V2beta2HPAScalingPolicyBuilder( + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent fluent) { this(fluent, false); } - public V2beta2HPAScalingPolicyBuilder(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2HPAScalingPolicyBuilder( + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2HPAScalingPolicy(), validationEnabled); } - public V2beta2HPAScalingPolicyBuilder(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent fluent,io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy instance) { + + public V2beta2HPAScalingPolicyBuilder( + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy instance) { this(fluent, instance, false); } - public V2beta2HPAScalingPolicyBuilder(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent fluent,io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2HPAScalingPolicyBuilder( + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPeriodSeconds(instance.getPeriodSeconds()); fluent.withType(instance.getType()); fluent.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2HPAScalingPolicyBuilder(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy instance) { - this(instance,false); + + public V2beta2HPAScalingPolicyBuilder( + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy instance) { + this(instance, false); } - public V2beta2HPAScalingPolicyBuilder(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2HPAScalingPolicyBuilder( + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPeriodSeconds(instance.getPeriodSeconds()); this.withType(instance.getType()); this.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy build() { V2beta2HPAScalingPolicy buildable = new V2beta2HPAScalingPolicy(); buildable.setPeriodSeconds(fluent.getPeriodSeconds()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy build() { buildable.setValue(fluent.getValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2HPAScalingPolicyBuilder that = (V2beta2HPAScalingPolicyBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingPolicyFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingPolicyFluent.java index ad8bc73925..2d92262851 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingPolicyFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingPolicyFluent.java @@ -1,30 +1,40 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2HPAScalingPolicyFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta2HPAScalingPolicyFluent< + A extends io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getPeriodSeconds(); + public A withPeriodSeconds(java.lang.Integer periodSeconds); + public java.lang.Boolean hasPeriodSeconds(); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); + public java.lang.Integer getValue(); + public A withValue(java.lang.Integer value); + public java.lang.Boolean hasValue(); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingPolicyFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingPolicyFluentImpl.java index e14f1c5f3c..2cb87160f8 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingPolicyFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingPolicyFluentImpl.java @@ -1,75 +1,95 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2beta2HPAScalingPolicyFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent{ - public V2beta2HPAScalingPolicyFluentImpl() { - } - public V2beta2HPAScalingPolicyFluentImpl(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy instance) { +/** Generated */ +public class V2beta2HPAScalingPolicyFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent { + public V2beta2HPAScalingPolicyFluentImpl() {} + + public V2beta2HPAScalingPolicyFluentImpl( + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy instance) { this.withPeriodSeconds(instance.getPeriodSeconds()); this.withType(instance.getType()); this.withValue(instance.getValue()); - } + private java.lang.Integer periodSeconds; private java.lang.String type; private java.lang.Integer value; + public java.lang.Integer getPeriodSeconds() { return this.periodSeconds; } + public A withPeriodSeconds(java.lang.Integer periodSeconds) { - this.periodSeconds=periodSeconds; return (A) this; + this.periodSeconds = periodSeconds; + return (A) this; } + public java.lang.Boolean hasPeriodSeconds() { return this.periodSeconds != null; } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public java.lang.Integer getValue() { return this.value; } + public A withValue(java.lang.Integer value) { - this.value=value; return (A) this; + this.value = value; + return (A) this; } + public java.lang.Boolean hasValue() { return this.value != null; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2HPAScalingPolicyFluentImpl that = (V2beta2HPAScalingPolicyFluentImpl) o; - if (periodSeconds != null ? !periodSeconds.equals(that.periodSeconds) :that.periodSeconds != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; - if (value != null ? !value.equals(that.value) :that.value != null) return false; + if (periodSeconds != null + ? !periodSeconds.equals(that.periodSeconds) + : that.periodSeconds != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; + if (value != null ? !value.equals(that.value) : that.value != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(periodSeconds, type, value, super.hashCode()); + return java.util.Objects.hash(periodSeconds, type, value, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingRulesBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingRulesBuilder.java index 779e51067b..6fd19466fe 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingRulesBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingRulesBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2HPAScalingRulesBuilder extends io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2HPAScalingRulesBuilder + extends io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2HPAScalingRules, + io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder> { public V2beta2HPAScalingRulesBuilder() { this(false); } + public V2beta2HPAScalingRulesBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2HPAScalingRules(), validationEnabled); } - public V2beta2HPAScalingRulesBuilder(io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent fluent) { + + public V2beta2HPAScalingRulesBuilder( + io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent fluent) { this(fluent, false); } - public V2beta2HPAScalingRulesBuilder(io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2HPAScalingRulesBuilder( + io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2HPAScalingRules(), validationEnabled); } - public V2beta2HPAScalingRulesBuilder(io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent fluent,io.kubernetes.client.openapi.models.V2beta2HPAScalingRules instance) { + + public V2beta2HPAScalingRulesBuilder( + io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HPAScalingRules instance) { this(fluent, instance, false); } - public V2beta2HPAScalingRulesBuilder(io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent fluent,io.kubernetes.client.openapi.models.V2beta2HPAScalingRules instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2HPAScalingRulesBuilder( + io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HPAScalingRules instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withPolicies(instance.getPolicies()); fluent.withSelectPolicy(instance.getSelectPolicy()); fluent.withStabilizationWindowSeconds(instance.getStabilizationWindowSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2HPAScalingRulesBuilder(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules instance) { - this(instance,false); + + public V2beta2HPAScalingRulesBuilder( + io.kubernetes.client.openapi.models.V2beta2HPAScalingRules instance) { + this(instance, false); } - public V2beta2HPAScalingRulesBuilder(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2HPAScalingRulesBuilder( + io.kubernetes.client.openapi.models.V2beta2HPAScalingRules instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withPolicies(instance.getPolicies()); this.withSelectPolicy(instance.getSelectPolicy()); this.withStabilizationWindowSeconds(instance.getStabilizationWindowSeconds()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRules build() { V2beta2HPAScalingRules buildable = new V2beta2HPAScalingRules(); buildable.setPolicies(fluent.getPolicies()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2beta2HPAScalingRules build() { buildable.setStabilizationWindowSeconds(fluent.getStabilizationWindowSeconds()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2HPAScalingRulesBuilder that = (V2beta2HPAScalingRulesBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingRulesFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingRulesFluent.java index 152a42718a..ef62f3b9fa 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingRulesFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingRulesFluent.java @@ -1,69 +1,125 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2HPAScalingRulesFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToPolicies(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item); - public A setToPolicies(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item); +/** Generated */ +public interface V2beta2HPAScalingRulesFluent< + A extends io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToPolicies( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item); + + public A setToPolicies( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item); + public A addToPolicies(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy... items); - public A addAllToPolicies(java.util.Collection items); + + public A addAllToPolicies( + java.util.Collection items); + public A removeFromPolicies(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy... items); - public A removeAllFromPolicies(java.util.Collection items); - public A removeMatchingFromPolicies(java.util.function.Predicate predicate); - + + public A removeAllFromPolicies( + java.util.Collection items); + + public A removeMatchingFromPolicies( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder> + predicate); + /** * This method has been deprecated, please use method buildPolicies instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getPolicies(); - public java.util.List buildPolicies(); - public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy buildPolicy(java.lang.Integer index); + + public java.util.List + buildPolicies(); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy buildPolicy( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy buildFirstPolicy(); + public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy buildLastPolicy(); - public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy buildMatchingPolicy(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingPolicy(java.util.function.Predicate predicate); - public A withPolicies(java.util.List policies); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy buildMatchingPolicy( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder> + predicate); + + public java.lang.Boolean hasMatchingPolicy( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder> + predicate); + + public A withPolicies( + java.util.List policies); + public A withPolicies(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy... policies); + public java.lang.Boolean hasPolicies(); - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested addNewPolicy(); - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested addNewPolicyLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item); - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested setNewPolicyLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item); - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested editPolicy(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested editFirstPolicy(); - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested editLastPolicy(); - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested editMatchingPolicy(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + addNewPolicy(); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + addNewPolicyLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + setNewPolicyLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + editPolicy(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + editFirstPolicy(); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + editLastPolicy(); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + editMatchingPolicy( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder> + predicate); + public java.lang.String getSelectPolicy(); + public A withSelectPolicy(java.lang.String selectPolicy); + public java.lang.Boolean hasSelectPolicy(); - - /** - * Method is deprecated. use withSelectPolicy instead. - */ + + /** Method is deprecated. use withSelectPolicy instead. */ @java.lang.Deprecated public A withNewSelectPolicy(java.lang.String original); + public java.lang.Integer getStabilizationWindowSeconds(); + public A withStabilizationWindowSeconds(java.lang.Integer stabilizationWindowSeconds); + public java.lang.Boolean hasStabilizationWindowSeconds(); - public interface PoliciesNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent>{ + + public interface PoliciesNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluent< + io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested> { public N and(); + public N endPolicy(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingRulesFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingRulesFluentImpl.java index 7ab87bd017..286441edba 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingRulesFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HPAScalingRulesFluentImpl.java @@ -1,64 +1,143 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; -import java.util.Collection; -import java.lang.Object; import java.util.List; -import java.lang.Boolean; - /** - * Generated - */ -public class V2beta2HPAScalingRulesFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent{ - public V2beta2HPAScalingRulesFluentImpl() { - } - public V2beta2HPAScalingRulesFluentImpl(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules instance) { +/** Generated */ +public class V2beta2HPAScalingRulesFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent { + public V2beta2HPAScalingRulesFluentImpl() {} + + public V2beta2HPAScalingRulesFluentImpl( + io.kubernetes.client.openapi.models.V2beta2HPAScalingRules instance) { this.withPolicies(instance.getPolicies()); this.withSelectPolicy(instance.getSelectPolicy()); this.withStabilizationWindowSeconds(instance.getStabilizationWindowSeconds()); - } - private java.util.ArrayList policies; + + private java.util.ArrayList + policies; private java.lang.String selectPolicy; private java.lang.Integer stabilizationWindowSeconds; - public A addToPolicies(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item) { - if (this.policies == null) {this.policies = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(item);_visitables.get("policies").add(index >= 0 ? index : _visitables.get("policies").size(), builder);this.policies.add(index >= 0 ? index : policies.size(), builder); return (A)this; + + public A addToPolicies( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item) { + if (this.policies == null) { + this.policies = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder>(); + } + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(item); + _visitables + .get("policies") + .add(index >= 0 ? index : _visitables.get("policies").size(), builder); + this.policies.add(index >= 0 ? index : policies.size(), builder); + return (A) this; } - public A setToPolicies(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item) { - if (this.policies == null) {this.policies = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(item); - if (index < 0 || index >= _visitables.get("policies").size()) { _visitables.get("policies").add(builder); } else { _visitables.get("policies").set(index, builder);} - if (index < 0 || index >= policies.size()) { policies.add(builder); } else { policies.set(index, builder);} - return (A)this; + + public A setToPolicies( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item) { + if (this.policies == null) { + this.policies = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder>(); + } + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(item); + if (index < 0 || index >= _visitables.get("policies").size()) { + _visitables.get("policies").add(builder); + } else { + _visitables.get("policies").set(index, builder); + } + if (index < 0 || index >= policies.size()) { + policies.add(builder); + } else { + policies.set(index, builder); + } + return (A) this; } + public A addToPolicies(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy... items) { - if (this.policies == null) {this.policies = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item : items) {io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(item);_visitables.get("policies").add(builder);this.policies.add(builder);} return (A)this; + if (this.policies == null) { + this.policies = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item : items) { + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(item); + _visitables.get("policies").add(builder); + this.policies.add(builder); + } + return (A) this; } - public A addAllToPolicies(java.util.Collection items) { - if (this.policies == null) {this.policies = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item : items) {io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(item);_visitables.get("policies").add(builder);this.policies.add(builder);} return (A)this; + + public A addAllToPolicies( + java.util.Collection items) { + if (this.policies == null) { + this.policies = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item : items) { + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(item); + _visitables.get("policies").add(builder); + this.policies.add(builder); + } + return (A) this; } - public A removeFromPolicies(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy... items) { - for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item : items) {io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(item);_visitables.get("policies").remove(builder);if (this.policies != null) {this.policies.remove(builder);}} return (A)this; + + public A removeFromPolicies( + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy... items) { + for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item : items) { + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(item); + _visitables.get("policies").remove(builder); + if (this.policies != null) { + this.policies.remove(builder); + } + } + return (A) this; } - public A removeAllFromPolicies(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item : items) {io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(item);_visitables.get("policies").remove(builder);if (this.policies != null) {this.policies.remove(builder);}} return (A)this; + + public A removeAllFromPolicies( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item : items) { + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(item); + _visitables.get("policies").remove(builder); + if (this.policies != null) { + this.policies.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromPolicies(java.util.function.Predicate predicate) { + + public A removeMatchingFromPolicies( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder> + predicate) { if (policies == null) return (A) this; - final Iterator each = policies.iterator(); + final Iterator each = + policies.iterator(); final List visitables = _visitables.get("policies"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder = each.next(); @@ -67,132 +146,226 @@ public A removeMatchingFromPolicies(java.util.function.Predicate getPolicies() { return policies != null ? build(policies) : null; } - public java.util.List buildPolicies() { + + public java.util.List + buildPolicies() { return policies != null ? build(policies) : null; } - public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy buildPolicy(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy buildPolicy( + java.lang.Integer index) { return this.policies.get(index).build(); } + public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy buildFirstPolicy() { return this.policies.get(0).build(); } + public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy buildLastPolicy() { return this.policies.get(policies.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy buildMatchingPolicy(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder item: policies) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy buildMatchingPolicy( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder item : policies) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingPolicy(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder item: policies) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingPolicy( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder item : policies) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withPolicies(java.util.List policies) { - if (this.policies != null) { _visitables.get("policies").removeAll(this.policies);} - if (policies != null) {this.policies = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item : policies){this.addToPolicies(item);}} else { this.policies = null;} return (A) this; + + public A withPolicies( + java.util.List policies) { + if (this.policies != null) { + _visitables.get("policies").removeAll(this.policies); + } + if (policies != null) { + this.policies = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item : policies) { + this.addToPolicies(item); + } + } else { + this.policies = null; + } + return (A) this; } + public A withPolicies(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy... policies) { - if (this.policies != null) {this.policies.clear();} - if (policies != null) {for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item :policies){ this.addToPolicies(item);}} return (A) this; + if (this.policies != null) { + this.policies.clear(); + } + if (policies != null) { + for (io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item : policies) { + this.addToPolicies(item); + } + } + return (A) this; } + public java.lang.Boolean hasPolicies() { return policies != null && !policies.isEmpty(); } - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested addNewPolicy() { - return new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluentImpl.PoliciesNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + addNewPolicy() { + return new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluentImpl + .PoliciesNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested addNewPolicyLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item) { - return new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluentImpl.PoliciesNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + addNewPolicyLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item) { + return new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluentImpl + .PoliciesNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested setNewPolicyLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item) { - return new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluentImpl.PoliciesNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + setNewPolicyLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item) { + return new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluentImpl + .PoliciesNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested editPolicy(java.lang.Integer index) { - if (policies.size() <= index) throw new RuntimeException("Can't edit policies. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + editPolicy(java.lang.Integer index) { + if (policies.size() <= index) + throw new RuntimeException("Can't edit policies. Index exceeds size."); return setNewPolicyLike(index, buildPolicy(index)); } - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested editFirstPolicy() { - if (policies.size() == 0) throw new RuntimeException("Can't edit first policies. The list is empty."); + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + editFirstPolicy() { + if (policies.size() == 0) + throw new RuntimeException("Can't edit first policies. The list is empty."); return setNewPolicyLike(0, buildPolicy(0)); } - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested editLastPolicy() { + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + editLastPolicy() { int index = policies.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last policies. The list is empty."); return setNewPolicyLike(index, buildPolicy(index)); } - public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested editMatchingPolicy(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested + editMatchingPolicy( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested,io.kubernetes.client.fluent.Nested{ - PoliciesNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item) { + + public class PoliciesNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested> + implements io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent.PoliciesNested, + io.kubernetes.client.fluent.Nested { + PoliciesNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicy item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(this, item); } + PoliciesNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2HPAScalingPolicyBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2beta2HPAScalingRulesFluentImpl.this.setToPolicies(index,builder.build()); + return (N) V2beta2HPAScalingRulesFluentImpl.this.setToPolicies(index, builder.build()); } + public N endPolicy() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBehaviorBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBehaviorBuilder.java index 97aaf0f386..eb85c8ed0c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBehaviorBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBehaviorBuilder.java @@ -1,63 +1,103 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2HorizontalPodAutoscalerBehaviorBuilder extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2HorizontalPodAutoscalerBehaviorBuilder + extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorBuilder> { public V2beta2HorizontalPodAutoscalerBehaviorBuilder() { this(false); } + public V2beta2HorizontalPodAutoscalerBehaviorBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2HorizontalPodAutoscalerBehavior(), validationEnabled); } - public V2beta2HorizontalPodAutoscalerBehaviorBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent fluent) { + + public V2beta2HorizontalPodAutoscalerBehaviorBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent fluent) { this(fluent, false); } - public V2beta2HorizontalPodAutoscalerBehaviorBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2HorizontalPodAutoscalerBehaviorBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2HorizontalPodAutoscalerBehavior(), validationEnabled); } - public V2beta2HorizontalPodAutoscalerBehaviorBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent fluent,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior instance) { + + public V2beta2HorizontalPodAutoscalerBehaviorBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior instance) { this(fluent, instance, false); } - public V2beta2HorizontalPodAutoscalerBehaviorBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent fluent,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2HorizontalPodAutoscalerBehaviorBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withScaleDown(instance.getScaleDown()); fluent.withScaleUp(instance.getScaleUp()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2HorizontalPodAutoscalerBehaviorBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior instance) { - this(instance,false); + + public V2beta2HorizontalPodAutoscalerBehaviorBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior instance) { + this(instance, false); } - public V2beta2HorizontalPodAutoscalerBehaviorBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2HorizontalPodAutoscalerBehaviorBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withScaleDown(instance.getScaleDown()); this.withScaleUp(instance.getScaleUp()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior build() { V2beta2HorizontalPodAutoscalerBehavior buildable = new V2beta2HorizontalPodAutoscalerBehavior(); buildable.setScaleDown(fluent.getScaleDown()); buildable.setScaleUp(fluent.getScaleUp()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V2beta2HorizontalPodAutoscalerBehaviorBuilder that = (V2beta2HorizontalPodAutoscalerBehaviorBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V2beta2HorizontalPodAutoscalerBehaviorBuilder that = + (V2beta2HorizontalPodAutoscalerBehaviorBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBehaviorFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBehaviorFluent.java index d3cd28d127..edadc9ad0e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBehaviorFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBehaviorFluent.java @@ -1,55 +1,120 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2HorizontalPodAutoscalerBehaviorFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2beta2HorizontalPodAutoscalerBehaviorFluent< + A extends + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildScaleDown instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2HPAScalingRules getScaleDown(); + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRules buildScaleDown(); + public A withScaleDown(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules scaleDown); + public java.lang.Boolean hasScaleDown(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested withNewScaleDown(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested withNewScaleDownLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested editScaleDown(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested editOrNewScaleDown(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested editOrNewScaleDownLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item); - + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + withNewScaleDown(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + withNewScaleDownLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + editScaleDown(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + editOrNewScaleDown(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + editOrNewScaleDownLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item); + /** * This method has been deprecated, please use method buildScaleUp instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2HPAScalingRules getScaleUp(); + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRules buildScaleUp(); + public A withScaleUp(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules scaleUp); + public java.lang.Boolean hasScaleUp(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested withNewScaleUp(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested withNewScaleUpLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested editScaleUp(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested editOrNewScaleUp(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested editOrNewScaleUpLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item); - public interface ScaleDownNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent>{ + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + A> + withNewScaleUp(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + A> + withNewScaleUpLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + A> + editScaleUp(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + A> + editOrNewScaleUp(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + A> + editOrNewScaleUpLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item); + + public interface ScaleDownNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + N>> { public N and(); + public N endScaleDown(); - } - public interface ScaleUpNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent>{ + + public interface ScaleUpNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluent< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + N>> { public N and(); + public N endScaleUp(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBehaviorFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBehaviorFluentImpl.java index fe0f72531b..e76935b7fc 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBehaviorFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBehaviorFluentImpl.java @@ -1,135 +1,241 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta2HorizontalPodAutoscalerBehaviorFluentImpl< + A extends + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent { + public V2beta2HorizontalPodAutoscalerBehaviorFluentImpl() {} - /** - * Generated - */ -public class V2beta2HorizontalPodAutoscalerBehaviorFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent{ - public V2beta2HorizontalPodAutoscalerBehaviorFluentImpl() { - } - public V2beta2HorizontalPodAutoscalerBehaviorFluentImpl(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior instance) { + public V2beta2HorizontalPodAutoscalerBehaviorFluentImpl( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior instance) { this.withScaleDown(instance.getScaleDown()); this.withScaleUp(instance.getScaleUp()); - } + private io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder scaleDown; private io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder scaleUp; - + /** * This method has been deprecated, please use method buildScaleDown instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2HPAScalingRules getScaleDown() { - return this.scaleDown!=null ?this.scaleDown.build():null; + return this.scaleDown != null ? this.scaleDown.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRules buildScaleDown() { - return this.scaleDown!=null ?this.scaleDown.build():null; + return this.scaleDown != null ? this.scaleDown.build() : null; } + public A withScaleDown(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules scaleDown) { _visitables.get("scaleDown").remove(this.scaleDown); - if (scaleDown!=null){ this.scaleDown= new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder(scaleDown); _visitables.get("scaleDown").add(this.scaleDown);} return (A) this; + if (scaleDown != null) { + this.scaleDown = + new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder(scaleDown); + _visitables.get("scaleDown").add(this.scaleDown); + } + return (A) this; } + public java.lang.Boolean hasScaleDown() { return this.scaleDown != null; } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested withNewScaleDown() { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluentImpl.ScaleDownNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + withNewScaleDown() { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluentImpl + .ScaleDownNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested withNewScaleDownLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluentImpl.ScaleDownNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + withNewScaleDownLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluentImpl + .ScaleDownNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested editScaleDown() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + editScaleDown() { return withNewScaleDownLike(getScaleDown()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested editOrNewScaleDown() { - return withNewScaleDownLike(getScaleDown() != null ? getScaleDown(): new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + editOrNewScaleDown() { + return withNewScaleDownLike( + getScaleDown() != null + ? getScaleDown() + : new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested editOrNewScaleDownLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item) { - return withNewScaleDownLike(getScaleDown() != null ? getScaleDown(): item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + A> + editOrNewScaleDownLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item) { + return withNewScaleDownLike(getScaleDown() != null ? getScaleDown() : item); } - + /** * This method has been deprecated, please use method buildScaleUp instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2HPAScalingRules getScaleUp() { - return this.scaleUp!=null ?this.scaleUp.build():null; + return this.scaleUp != null ? this.scaleUp.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2HPAScalingRules buildScaleUp() { - return this.scaleUp!=null ?this.scaleUp.build():null; + return this.scaleUp != null ? this.scaleUp.build() : null; } + public A withScaleUp(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules scaleUp) { _visitables.get("scaleUp").remove(this.scaleUp); - if (scaleUp!=null){ this.scaleUp= new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder(scaleUp); _visitables.get("scaleUp").add(this.scaleUp);} return (A) this; + if (scaleUp != null) { + this.scaleUp = new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder(scaleUp); + _visitables.get("scaleUp").add(this.scaleUp); + } + return (A) this; } + public java.lang.Boolean hasScaleUp() { return this.scaleUp != null; } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested withNewScaleUp() { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluentImpl.ScaleUpNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + A> + withNewScaleUp() { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluentImpl + .ScaleUpNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested withNewScaleUpLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluentImpl.ScaleUpNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + A> + withNewScaleUpLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluentImpl + .ScaleUpNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested editScaleUp() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + A> + editScaleUp() { return withNewScaleUpLike(getScaleUp()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested editOrNewScaleUp() { - return withNewScaleUpLike(getScaleUp() != null ? getScaleUp(): new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + A> + editOrNewScaleUp() { + return withNewScaleUpLike( + getScaleUp() != null + ? getScaleUp() + : new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested editOrNewScaleUpLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item) { - return withNewScaleUpLike(getScaleUp() != null ? getScaleUp(): item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + A> + editOrNewScaleUpLike(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item) { + return withNewScaleUpLike(getScaleUp() != null ? getScaleUp() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2beta2HorizontalPodAutoscalerBehaviorFluentImpl that = (V2beta2HorizontalPodAutoscalerBehaviorFluentImpl) o; - if (scaleDown != null ? !scaleDown.equals(that.scaleDown) :that.scaleDown != null) return false; - if (scaleUp != null ? !scaleUp.equals(that.scaleUp) :that.scaleUp != null) return false; + V2beta2HorizontalPodAutoscalerBehaviorFluentImpl that = + (V2beta2HorizontalPodAutoscalerBehaviorFluentImpl) o; + if (scaleDown != null ? !scaleDown.equals(that.scaleDown) : that.scaleDown != null) + return false; + if (scaleUp != null ? !scaleUp.equals(that.scaleUp) : that.scaleUp != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(scaleDown, scaleUp, super.hashCode()); + return java.util.Objects.hash(scaleDown, scaleUp, super.hashCode()); } - public class ScaleDownNestedImpl extends io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleDownNested,io.kubernetes.client.fluent.Nested{ + + public class ScaleDownNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleDownNested< + N>, + io.kubernetes.client.fluent.Nested { ScaleDownNestedImpl(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder(this, item); } + ScaleDownNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder builder; + public N and() { - return (N) V2beta2HorizontalPodAutoscalerBehaviorFluentImpl.this.withScaleDown(builder.build()); + return (N) + V2beta2HorizontalPodAutoscalerBehaviorFluentImpl.this.withScaleDown(builder.build()); } + public N endScaleDown() { return and(); } - } - public class ScaleUpNestedImpl extends io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent.ScaleUpNested,io.kubernetes.client.fluent.Nested{ + + public class ScaleUpNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent + .ScaleUpNested< + N>, + io.kubernetes.client.fluent.Nested { ScaleUpNestedImpl(io.kubernetes.client.openapi.models.V2beta2HPAScalingRules item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder(this, item); } + ScaleUpNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2HPAScalingRulesBuilder builder; + public N and() { return (N) V2beta2HorizontalPodAutoscalerBehaviorFluentImpl.this.withScaleUp(builder.build()); } + public N endScaleUp() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBuilder.java index 5567e486cf..556e796835 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2HorizontalPodAutoscalerBuilder extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2HorizontalPodAutoscalerBuilder + extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder> { public V2beta2HorizontalPodAutoscalerBuilder() { this(false); } + public V2beta2HorizontalPodAutoscalerBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2HorizontalPodAutoscaler(), validationEnabled); } - public V2beta2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent fluent) { + + public V2beta2HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent fluent) { this(fluent, false); } - public V2beta2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2HorizontalPodAutoscaler(), validationEnabled); } - public V2beta2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent fluent,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler instance) { + + public V2beta2HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler instance) { this(fluent, instance, false); } - public V2beta2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent fluent,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withKind(instance.getKind()); @@ -31,13 +58,18 @@ public V2beta2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models fluent.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler instance) { - this(instance,false); + + public V2beta2HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler instance) { + this(instance, false); } - public V2beta2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2HorizontalPodAutoscalerBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -48,10 +80,12 @@ public V2beta2HorizontalPodAutoscalerBuilder(io.kubernetes.client.openapi.models this.withStatus(instance.getStatus()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler build() { V2beta2HorizontalPodAutoscaler buildable = new V2beta2HorizontalPodAutoscaler(); buildable.setApiVersion(fluent.getApiVersion()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler build( buildable.setStatus(fluent.getStatus()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2HorizontalPodAutoscalerBuilder that = (V2beta2HorizontalPodAutoscalerBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerConditionBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerConditionBuilder.java index 352cc29379..7280d59358 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerConditionBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerConditionBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2HorizontalPodAutoscalerConditionBuilder extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2HorizontalPodAutoscalerConditionBuilder + extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder> { public V2beta2HorizontalPodAutoscalerConditionBuilder() { this(false); } + public V2beta2HorizontalPodAutoscalerConditionBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2HorizontalPodAutoscalerCondition(), validationEnabled); } - public V2beta2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent fluent) { + + public V2beta2HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent fluent) { this(fluent, false); } - public V2beta2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2HorizontalPodAutoscalerCondition(), validationEnabled); } - public V2beta2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent fluent,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition instance) { + + public V2beta2HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition instance) { this(fluent, instance, false); } - public V2beta2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent fluent,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withLastTransitionTime(instance.getLastTransitionTime()); fluent.withMessage(instance.getMessage()); @@ -31,13 +58,18 @@ public V2beta2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.opena fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition instance) { - this(instance,false); + + public V2beta2HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition instance) { + this(instance, false); } - public V2beta2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2HorizontalPodAutoscalerConditionBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -48,12 +80,15 @@ public V2beta2HorizontalPodAutoscalerConditionBuilder(io.kubernetes.client.opena this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition build() { - V2beta2HorizontalPodAutoscalerCondition buildable = new V2beta2HorizontalPodAutoscalerCondition(); + V2beta2HorizontalPodAutoscalerCondition buildable = + new V2beta2HorizontalPodAutoscalerCondition(); buildable.setLastTransitionTime(fluent.getLastTransitionTime()); buildable.setMessage(fluent.getMessage()); buildable.setReason(fluent.getReason()); @@ -61,18 +96,24 @@ public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditi buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V2beta2HorizontalPodAutoscalerConditionBuilder that = (V2beta2HorizontalPodAutoscalerConditionBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V2beta2HorizontalPodAutoscalerConditionBuilder that = + (V2beta2HorizontalPodAutoscalerConditionBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerConditionFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerConditionFluent.java index b9aeb44c95..64e2b53f8e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerConditionFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerConditionFluent.java @@ -1,54 +1,65 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2HorizontalPodAutoscalerConditionFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta2HorizontalPodAutoscalerConditionFluent< + A extends + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent> + extends io.kubernetes.client.fluent.Fluent { public java.time.OffsetDateTime getLastTransitionTime(); + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime); + public java.lang.Boolean hasLastTransitionTime(); + public java.lang.String getMessage(); + public A withMessage(java.lang.String message); + public java.lang.Boolean hasMessage(); - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original); + public java.lang.String getReason(); + public A withReason(java.lang.String reason); + public java.lang.Boolean hasReason(); - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original); + public java.lang.String getStatus(); + public A withStatus(java.lang.String status); + public java.lang.Boolean hasStatus(); - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerConditionFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerConditionFluentImpl.java index 315610a747..47167d648f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerConditionFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerConditionFluentImpl.java @@ -1,19 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import java.time.OffsetDateTime; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class V2beta2HorizontalPodAutoscalerConditionFluentImpl< + A extends + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent< + A> { + public V2beta2HorizontalPodAutoscalerConditionFluentImpl() {} - /** - * Generated - */ -public class V2beta2HorizontalPodAutoscalerConditionFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent{ - public V2beta2HorizontalPodAutoscalerConditionFluentImpl() { - } - public V2beta2HorizontalPodAutoscalerConditionFluentImpl(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition instance) { + public V2beta2HorizontalPodAutoscalerConditionFluentImpl( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition instance) { this.withLastTransitionTime(instance.getLastTransitionTime()); this.withMessage(instance.getMessage()); @@ -23,103 +32,120 @@ public V2beta2HorizontalPodAutoscalerConditionFluentImpl(io.kubernetes.client.op this.withStatus(instance.getStatus()); this.withType(instance.getType()); - } + private java.time.OffsetDateTime lastTransitionTime; private java.lang.String message; private java.lang.String reason; private java.lang.String status; private java.lang.String type; + public java.time.OffsetDateTime getLastTransitionTime() { return this.lastTransitionTime; } + public A withLastTransitionTime(java.time.OffsetDateTime lastTransitionTime) { - this.lastTransitionTime=lastTransitionTime; return (A) this; + this.lastTransitionTime = lastTransitionTime; + return (A) this; } + public java.lang.Boolean hasLastTransitionTime() { return this.lastTransitionTime != null; } + public java.lang.String getMessage() { return this.message; } + public A withMessage(java.lang.String message) { - this.message=message; return (A) this; + this.message = message; + return (A) this; } + public java.lang.Boolean hasMessage() { return this.message != null; } - - /** - * Method is deprecated. use withMessage instead. - */ + + /** Method is deprecated. use withMessage instead. */ @java.lang.Deprecated public A withNewMessage(java.lang.String original) { - return (A)withMessage(new String(original)); + return (A) withMessage(new String(original)); } + public java.lang.String getReason() { return this.reason; } + public A withReason(java.lang.String reason) { - this.reason=reason; return (A) this; + this.reason = reason; + return (A) this; } + public java.lang.Boolean hasReason() { return this.reason != null; } - - /** - * Method is deprecated. use withReason instead. - */ + + /** Method is deprecated. use withReason instead. */ @java.lang.Deprecated public A withNewReason(java.lang.String original) { - return (A)withReason(new String(original)); + return (A) withReason(new String(original)); } + public java.lang.String getStatus() { return this.status; } + public A withStatus(java.lang.String status) { - this.status=status; return (A) this; + this.status = status; + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - - /** - * Method is deprecated. use withStatus instead. - */ + + /** Method is deprecated. use withStatus instead. */ @java.lang.Deprecated public A withNewStatus(java.lang.String original) { - return (A)withStatus(new String(original)); + return (A) withStatus(new String(original)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2beta2HorizontalPodAutoscalerConditionFluentImpl that = (V2beta2HorizontalPodAutoscalerConditionFluentImpl) o; - if (lastTransitionTime != null ? !lastTransitionTime.equals(that.lastTransitionTime) :that.lastTransitionTime != null) return false; - if (message != null ? !message.equals(that.message) :that.message != null) return false; - if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + V2beta2HorizontalPodAutoscalerConditionFluentImpl that = + (V2beta2HorizontalPodAutoscalerConditionFluentImpl) o; + if (lastTransitionTime != null + ? !lastTransitionTime.equals(that.lastTransitionTime) + : that.lastTransitionTime != null) return false; + if (message != null ? !message.equals(that.message) : that.message != null) return false; + if (reason != null ? !reason.equals(that.reason) : that.reason != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(lastTransitionTime, message, reason, status, type, super.hashCode()); + return java.util.Objects.hash( + lastTransitionTime, message, reason, status, type, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerFluent.java index 7304481004..a24b21d5de 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerFluent.java @@ -1,93 +1,160 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2HorizontalPodAutoscalerFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta2HorizontalPodAutoscalerFluent< + A extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); - + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested + editMetadata(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item); + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec getSpec(); + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec buildSpec(); + public A withSpec(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec spec); + public java.lang.Boolean hasSpec(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested withNewSpec(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested editSpec(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested editOrNewSpec(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec item); - + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested + withNewSpec(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested + editSpec(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpec(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpecLike( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec item); + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus getStatus(); + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus buildStatus(); - public A withStatus(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus status); + + public A withStatus( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus status); + public java.lang.Boolean hasStatus(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested withNewStatus(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested editStatus(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested editOrNewStatus(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus item); - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ObjectMetaFluent>{ + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested + withNewStatus(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested + withNewStatusLike( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested + editStatus(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatus(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus item); + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ObjectMetaFluent< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - public interface SpecNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent>{ + + public interface SpecNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested< + N>> { public N and(); + public N endSpec(); - } - public interface StatusNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent>{ + + public interface StatusNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested< + N>> { public N and(); + public N endStatus(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerFluentImpl.java index 3cc32a320f..743cd1a2da 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta2HorizontalPodAutoscalerFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent { + public V2beta2HorizontalPodAutoscalerFluentImpl() {} - /** - * Generated - */ -public class V2beta2HorizontalPodAutoscalerFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent{ - public V2beta2HorizontalPodAutoscalerFluentImpl() { - } - public V2beta2HorizontalPodAutoscalerFluentImpl(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler instance) { + public V2beta2HorizontalPodAutoscalerFluentImpl( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler instance) { this.withApiVersion(instance.getApiVersion()); this.withKind(instance.getKind()); @@ -23,210 +30,332 @@ public V2beta2HorizontalPodAutoscalerFluentImpl(io.kubernetes.client.openapi.mod this.withSpec(instance.getSpec()); this.withStatus(instance.getStatus()); - } + private java.lang.String apiVersion; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ObjectMetaBuilder metadata; private io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecBuilder spec; private io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusBuilder status; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } + public java.lang.String getKind() { return this.kind; } + public A withKind(java.lang.String kind) { - this.kind=kind; return (A) this; + this.kind = kind; + return (A) this; } + public java.lang.Boolean hasKind() { return this.kind != null; } - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original) { - return (A)withKind(new String(original)); + return (A) withKind(new String(original)); } - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public io.kubernetes.client.openapi.models.V1ObjectMeta buildMetadata() { - return this.metadata!=null ?this.metadata.build():null; + return this.metadata != null ? this.metadata.build() : null; } + public A withMetadata(io.kubernetes.client.openapi.models.V1ObjectMeta metadata) { _visitables.get("metadata").remove(this.metadata); - if (metadata!=null){ this.metadata= new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this; + if (metadata != null) { + this.metadata = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(metadata); + _visitables.get("metadata").add(this.metadata); + } + return (A) this; } + public java.lang.Boolean hasMetadata() { return this.metadata != null; } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested withNewMetadata() { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ObjectMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } - + /** * This method has been deprecated, please use method buildSpec instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec getSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec buildSpec() { - return this.spec!=null ?this.spec.build():null; + return this.spec != null ? this.spec.build() : null; } + public A withSpec(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec spec) { _visitables.get("spec").remove(this.spec); - if (spec!=null){ this.spec= new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecBuilder(spec); _visitables.get("spec").add(this.spec);} return (A) this; + if (spec != null) { + this.spec = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecBuilder(spec); + _visitables.get("spec").add(this.spec); + } + return (A) this; } + public java.lang.Boolean hasSpec() { return this.spec != null; } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested withNewSpec() { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl.SpecNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested + withNewSpec() { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl + .SpecNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested withNewSpecLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl.SpecNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested + withNewSpecLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl + .SpecNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested editSpec() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested + editSpec() { return withNewSpecLike(getSpec()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested editOrNewSpec() { - return withNewSpecLike(getSpec() != null ? getSpec(): new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpec() { + return withNewSpecLike( + getSpec() != null + ? getSpec() + : new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested editOrNewSpecLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec item) { - return withNewSpecLike(getSpec() != null ? getSpec(): item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested + editOrNewSpecLike( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec item) { + return withNewSpecLike(getSpec() != null ? getSpec() : item); } - + /** * This method has been deprecated, please use method buildStatus instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus getStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus buildStatus() { - return this.status!=null ?this.status.build():null; + return this.status != null ? this.status.build() : null; } - public A withStatus(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus status) { + + public A withStatus( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus status) { _visitables.get("status").remove(this.status); - if (status!=null){ this.status= new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusBuilder(status); _visitables.get("status").add(this.status);} return (A) this; + if (status != null) { + this.status = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusBuilder( + status); + _visitables.get("status").add(this.status); + } + return (A) this; } + public java.lang.Boolean hasStatus() { return this.status != null; } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested withNewStatus() { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl.StatusNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested + withNewStatus() { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl + .StatusNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested withNewStatusLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl.StatusNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested + withNewStatusLike( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl + .StatusNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested editStatus() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested + editStatus() { return withNewStatusLike(getStatus()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested editOrNewStatus() { - return withNewStatusLike(getStatus() != null ? getStatus(): new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatus() { + return withNewStatusLike( + getStatus() != null + ? getStatus() + : new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested editOrNewStatusLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus item) { - return withNewStatusLike(getStatus() != null ? getStatus(): item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested + editOrNewStatusLike( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus item) { + return withNewStatusLike(getStatus() != null ? getStatus() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2HorizontalPodAutoscalerFluentImpl that = (V2beta2HorizontalPodAutoscalerFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; - if (spec != null ? !spec.equals(that.spec) :that.spec != null) return false; - if (status != null ? !status.equals(that.status) :that.status != null) return false; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; + if (spec != null ? !spec.equals(that.spec) : that.spec != null) return false; + if (status != null ? !status.equals(that.status) : that.status != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); + return java.util.Objects.hash(apiVersion, kind, metadata, spec, status, super.hashCode()); } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ObjectMetaFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ObjectMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ObjectMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ObjectMetaBuilder builder; + public N and() { return (N) V2beta2HorizontalPodAutoscalerFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - public class SpecNestedImpl extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested,io.kubernetes.client.fluent.Nested{ + + public class SpecNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.SpecNested> + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent + .SpecNested< + N>, + io.kubernetes.client.fluent.Nested { SpecNestedImpl(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecBuilder( + this, item); } + SpecNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecBuilder builder; + public N and() { return (N) V2beta2HorizontalPodAutoscalerFluentImpl.this.withSpec(builder.build()); } + public N endSpec() { return and(); } - } - public class StatusNestedImpl extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested,io.kubernetes.client.fluent.Nested{ - StatusNestedImpl(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusBuilder(this, item); + + public class StatusNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent.StatusNested> + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent + .StatusNested< + N>, + io.kubernetes.client.fluent.Nested { + StatusNestedImpl( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus item) { + this.builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusBuilder( + this, item); } + StatusNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusBuilder builder; + public N and() { return (N) V2beta2HorizontalPodAutoscalerFluentImpl.this.withStatus(builder.build()); } + public N endStatus() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerListBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerListBuilder.java index 0289378efe..0f788e1116 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerListBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerListBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2HorizontalPodAutoscalerListBuilder extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2HorizontalPodAutoscalerListBuilder + extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerList, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListBuilder> { public V2beta2HorizontalPodAutoscalerListBuilder() { this(false); } + public V2beta2HorizontalPodAutoscalerListBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2HorizontalPodAutoscalerList(), validationEnabled); } - public V2beta2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent fluent) { + + public V2beta2HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent fluent) { this(fluent, false); } - public V2beta2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2HorizontalPodAutoscalerList(), validationEnabled); } - public V2beta2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent fluent,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerList instance) { + + public V2beta2HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerList instance) { this(fluent, instance, false); } - public V2beta2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent fluent,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerList instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerList instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withApiVersion(instance.getApiVersion()); fluent.withItems(instance.getItems()); @@ -29,13 +56,18 @@ public V2beta2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.mo fluent.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerList instance) { - this(instance,false); + + public V2beta2HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerList instance) { + this(instance, false); } - public V2beta2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerList instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2HorizontalPodAutoscalerListBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerList instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -44,10 +76,12 @@ public V2beta2HorizontalPodAutoscalerListBuilder(io.kubernetes.client.openapi.mo this.withMetadata(instance.getMetadata()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerList build() { V2beta2HorizontalPodAutoscalerList buildable = new V2beta2HorizontalPodAutoscalerList(); buildable.setApiVersion(fluent.getApiVersion()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerList bu buildable.setMetadata(fluent.getMetadata()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2HorizontalPodAutoscalerListBuilder that = (V2beta2HorizontalPodAutoscalerListBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerListFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerListFluent.java index 82eabe2aba..52842b56ce 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerListFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerListFluent.java @@ -1,95 +1,187 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Integer; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.Collection; -import java.util.List; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2HorizontalPodAutoscalerListFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta2HorizontalPodAutoscalerListFluent< + A extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getApiVersion(); + public A withApiVersion(java.lang.String apiVersion); + public java.lang.Boolean hasApiVersion(); - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original); - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item); - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item); + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item); + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item); + public A addToItems(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler... items); - public A addAllToItems(java.util.Collection items); - public A removeFromItems(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler... items); - public A removeAllFromItems(java.util.Collection items); - public A removeMatchingFromItems(java.util.function.Predicate predicate); - + + public A addAllToItems( + java.util.Collection + items); + + public A removeFromItems( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler... items); + + public A removeAllFromItems( + java.util.Collection + items); + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder> + predicate); + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getItems(); - public java.util.List buildItems(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler buildItem(java.lang.Integer index); + public java.util.List + getItems(); + + public java.util.List + buildItems(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler buildItem( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler buildFirstItem(); + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler buildLastItem(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler buildMatchingItem(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate); - public A withItems(java.util.List items); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder> + predicate); + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder> + predicate); + + public A withItems( + java.util.List items); + public A withItems(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler... items); + public java.lang.Boolean hasItems(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested addNewItem(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested editItem(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested editFirstItem(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested editLastItem(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + addNewItem(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + editItem(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + editFirstItem(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + editLastItem(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder> + predicate); + public java.lang.String getKind(); + public A withKind(java.lang.String kind); + public java.lang.Boolean hasKind(); - - /** - * Method is deprecated. use withKind instead. - */ + + /** Method is deprecated. use withKind instead. */ @java.lang.Deprecated public A withNewKind(java.lang.String original); - + /** * This method has been deprecated, please use method buildMetadata instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1ListMeta getMetadata(); + public io.kubernetes.client.openapi.models.V1ListMeta buildMetadata(); + public A withMetadata(io.kubernetes.client.openapi.models.V1ListMeta metadata); + public java.lang.Boolean hasMetadata(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.MetadataNested withNewMetadata(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.MetadataNested editMetadata(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadata(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); - public interface ItemsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent>{ + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + withNewMetadata(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + editMetadata(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + editOrNewMetadata(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item); + + public interface ItemsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluent< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .ItemsNested< + N>> { public N and(); + public N endItem(); - } - public interface MetadataNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1ListMetaFluent>{ + + public interface MetadataNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1ListMetaFluent< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .MetadataNested< + N>> { public N and(); + public N endMetadata(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerListFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerListFluentImpl.java index 8969e59962..abb26ab98e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerListFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerListFluentImpl.java @@ -1,26 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V2beta2HorizontalPodAutoscalerListFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent{ - public V2beta2HorizontalPodAutoscalerListFluentImpl() { - } - public V2beta2HorizontalPodAutoscalerListFluentImpl(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerList instance) { + +/** Generated */ +public class V2beta2HorizontalPodAutoscalerListFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent { + public V2beta2HorizontalPodAutoscalerListFluentImpl() {} + + public V2beta2HorizontalPodAutoscalerListFluentImpl( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerList instance) { this.withApiVersion(instance.getApiVersion()); this.withItems(instance.getItems()); @@ -28,233 +31,453 @@ public V2beta2HorizontalPodAutoscalerListFluentImpl(io.kubernetes.client.openapi this.withKind(instance.getKind()); this.withMetadata(instance.getMetadata()); - } + private java.lang.String apiVersion; - private java.util.ArrayList items; + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder> + items; private java.lang.String kind; private io.kubernetes.client.openapi.models.V1ListMetaBuilder metadata; + public java.lang.String getApiVersion() { return this.apiVersion; } + public A withApiVersion(java.lang.String apiVersion) { - this.apiVersion=apiVersion; return (A) this; + this.apiVersion = apiVersion; + return (A) this; } + public java.lang.Boolean hasApiVersion() { return this.apiVersion != null; } - - /** - * Method is deprecated. use withApiVersion instead. - */ + + /** Method is deprecated. use withApiVersion instead. */ @java.lang.Deprecated public A withNewApiVersion(java.lang.String original) { - return (A)withApiVersion(new String(original)); + return (A) withApiVersion(new String(original)); } - public A addToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(item);_visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder);this.items.add(index >= 0 ? index : items.size(), builder); return (A)this; + + public A addToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder>(); + } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").add(index >= 0 ? index : _visitables.get("items").size(), builder); + this.items.add(index >= 0 ? index : items.size(), builder); + return (A) this; } - public A setToItems(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item) { - if (this.items == null) {this.items = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(item); - if (index < 0 || index >= _visitables.get("items").size()) { _visitables.get("items").add(builder); } else { _visitables.get("items").set(index, builder);} - if (index < 0 || index >= items.size()) { items.add(builder); } else { items.set(index, builder);} - return (A)this; + + public A setToItems( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder>(); + } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(item); + if (index < 0 || index >= _visitables.get("items").size()) { + _visitables.get("items").add(builder); + } else { + _visitables.get("items").set(index, builder); + } + if (index < 0 || index >= items.size()) { + items.add(builder); + } else { + items.set(index, builder); + } + return (A) this; } + public A addToItems(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler... items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A addAllToItems(java.util.Collection items) { - if (this.items == null) {this.items = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(item);_visitables.get("items").add(builder);this.items.add(builder);} return (A)this; + + public A addAllToItems( + java.util.Collection + items) { + if (this.items == null) { + this.items = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").add(builder); + this.items.add(builder); + } + return (A) this; } - public A removeFromItems(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler... items) { - for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeFromItems( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler... items) { + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeAllFromItems(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item : items) {io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(item);_visitables.get("items").remove(builder);if (this.items != null) {this.items.remove(builder);}} return (A)this; + + public A removeAllFromItems( + java.util.Collection + items) { + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item : items) { + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(item); + _visitables.get("items").remove(builder); + if (this.items != null) { + this.items.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromItems(java.util.function.Predicate predicate) { + + public A removeMatchingFromItems( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder> + predicate) { if (items == null) return (A) this; - final Iterator each = items.iterator(); + final Iterator each = + items.iterator(); final List visitables = _visitables.get("items"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildItems instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getItems() { + public java.util.List + getItems() { return items != null ? build(items) : null; } - public java.util.List buildItems() { + + public java.util.List + buildItems() { return items != null ? build(items) : null; } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler buildItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler buildItem( + java.lang.Integer index) { return this.items.get(index).build(); } + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler buildFirstItem() { return this.items.get(0).build(); } + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler buildLastItem() { return this.items.get(items.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler buildMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder item: items) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler buildMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder item : items) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingItem(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder item: items) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder item : items) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withItems(java.util.List items) { - if (this.items != null) { _visitables.get("items").removeAll(this.items);} - if (items != null) {this.items = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item : items){this.addToItems(item);}} else { this.items = null;} return (A) this; + + public A withItems( + java.util.List items) { + if (this.items != null) { + _visitables.get("items").removeAll(this.items); + } + if (items != null) { + this.items = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item : items) { + this.addToItems(item); + } + } else { + this.items = null; + } + return (A) this; } + public A withItems(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler... items) { - if (this.items != null) {this.items.clear();} - if (items != null) {for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item :items){ this.addToItems(item);}} return (A) this; + if (this.items != null) { + this.items.clear(); + } + if (items != null) { + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item : items) { + this.addToItems(item); + } + } + return (A) this; } + public java.lang.Boolean hasItems() { return items != null && !items.isEmpty(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested addNewItem() { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluentImpl.ItemsNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + addNewItem() { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluentImpl + .ItemsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested addNewItemLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluentImpl.ItemsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + addNewItemLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluentImpl + .ItemsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested setNewItemLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluentImpl.ItemsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + setNewItemLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluentImpl + .ItemsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested editItem(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + editItem(java.lang.Integer index) { if (items.size() <= index) throw new RuntimeException("Can't edit items. Index exceeds size."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested editFirstItem() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + editFirstItem() { if (items.size() == 0) throw new RuntimeException("Can't edit first items. The list is empty."); return setNewItemLike(0, buildItem(0)); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested editLastItem() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + editLastItem() { int index = items.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last items. The list is empty."); return setNewItemLike(index, buildItem(index)); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested editMatchingItem(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested + editMatchingItem( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder> + predicate) { int index = -1; - for (int i=0;i withNewMetadata() { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluentImpl.MetadataNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + withNewMetadata() { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluentImpl + .MetadataNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.MetadataNested withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluentImpl.MetadataNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + withNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluentImpl + .MetadataNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.MetadataNested editMetadata() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + editMetadata() { return withNewMetadataLike(getMetadata()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadata() { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + editOrNewMetadata() { + return withNewMetadataLike( + getMetadata() != null + ? getMetadata() + : new io.kubernetes.client.openapi.models.V1ListMetaBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.MetadataNested editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { - return withNewMetadataLike(getMetadata() != null ? getMetadata(): item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .MetadataNested< + A> + editOrNewMetadataLike(io.kubernetes.client.openapi.models.V1ListMeta item) { + return withNewMetadataLike(getMetadata() != null ? getMetadata() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2beta2HorizontalPodAutoscalerListFluentImpl that = (V2beta2HorizontalPodAutoscalerListFluentImpl) o; - if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false; - if (items != null ? !items.equals(that.items) :that.items != null) return false; - if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false; - if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false; + V2beta2HorizontalPodAutoscalerListFluentImpl that = + (V2beta2HorizontalPodAutoscalerListFluentImpl) o; + if (apiVersion != null ? !apiVersion.equals(that.apiVersion) : that.apiVersion != null) + return false; + if (items != null ? !items.equals(that.items) : that.items != null) return false; + if (kind != null ? !kind.equals(that.kind) : that.kind != null) return false; + if (metadata != null ? !metadata.equals(that.metadata) : that.metadata != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); + return java.util.Objects.hash(apiVersion, items, kind, metadata, super.hashCode()); } - public class ItemsNestedImpl extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested,io.kubernetes.client.fluent.Nested{ - ItemsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item) { + + public class ItemsNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.ItemsNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .ItemsNested< + N>, + io.kubernetes.client.fluent.Nested { + ItemsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscaler item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(this, item); } + ItemsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2beta2HorizontalPodAutoscalerListFluentImpl.this.setToItems(index,builder.build()); + return (N) + V2beta2HorizontalPodAutoscalerListFluentImpl.this.setToItems(index, builder.build()); } + public N endItem() { return and(); } - } - public class MetadataNestedImpl extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent.MetadataNested,io.kubernetes.client.fluent.Nested{ + + public class MetadataNestedImpl + extends io.kubernetes.client.openapi.models.V1ListMetaFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .MetadataNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerListFluent + .MetadataNested< + N>, + io.kubernetes.client.fluent.Nested { MetadataNestedImpl(io.kubernetes.client.openapi.models.V1ListMeta item) { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this, item); } + MetadataNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1ListMetaBuilder(this); } + io.kubernetes.client.openapi.models.V1ListMetaBuilder builder; + public N and() { return (N) V2beta2HorizontalPodAutoscalerListFluentImpl.this.withMetadata(builder.build()); } + public N endMetadata() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerSpecBuilder.java index f55d6af51e..4112fa868f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2HorizontalPodAutoscalerSpecBuilder extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2HorizontalPodAutoscalerSpecBuilder + extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecBuilder> { public V2beta2HorizontalPodAutoscalerSpecBuilder() { this(false); } + public V2beta2HorizontalPodAutoscalerSpecBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2HorizontalPodAutoscalerSpec(), validationEnabled); } - public V2beta2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent fluent) { + + public V2beta2HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent fluent) { this(fluent, false); } - public V2beta2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2HorizontalPodAutoscalerSpec(), validationEnabled); } - public V2beta2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent fluent,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec instance) { + + public V2beta2HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec instance) { this(fluent, instance, false); } - public V2beta2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent fluent,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withBehavior(instance.getBehavior()); fluent.withMaxReplicas(instance.getMaxReplicas()); @@ -31,13 +58,18 @@ public V2beta2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.mo fluent.withScaleTargetRef(instance.getScaleTargetRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec instance) { - this(instance,false); + + public V2beta2HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec instance) { + this(instance, false); } - public V2beta2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2HorizontalPodAutoscalerSpecBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withBehavior(instance.getBehavior()); this.withMaxReplicas(instance.getMaxReplicas()); @@ -48,10 +80,12 @@ public V2beta2HorizontalPodAutoscalerSpecBuilder(io.kubernetes.client.openapi.mo this.withScaleTargetRef(instance.getScaleTargetRef()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec build() { V2beta2HorizontalPodAutoscalerSpec buildable = new V2beta2HorizontalPodAutoscalerSpec(); buildable.setBehavior(fluent.getBehavior()); @@ -61,18 +95,23 @@ public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec bu buildable.setScaleTargetRef(fluent.getScaleTargetRef()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2HorizontalPodAutoscalerSpecBuilder that = (V2beta2HorizontalPodAutoscalerSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerSpecFluent.java index 73cadf6663..46f9cdfc5e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerSpecFluent.java @@ -1,103 +1,231 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.util.Collection; - - /** - * Generated - */ -public interface V2beta2HorizontalPodAutoscalerSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2beta2HorizontalPodAutoscalerSpecFluent< + A extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildBehavior instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior getBehavior(); + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior buildBehavior(); - public A withBehavior(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior behavior); + + public A withBehavior( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior behavior); + public java.lang.Boolean hasBehavior(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.BehaviorNested withNewBehavior(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.BehaviorNested withNewBehaviorLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.BehaviorNested editBehavior(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.BehaviorNested editOrNewBehavior(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.BehaviorNested editOrNewBehaviorLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + A> + withNewBehavior(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + A> + withNewBehaviorLike( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + A> + editBehavior(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + A> + editOrNewBehavior(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + A> + editOrNewBehaviorLike( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior item); + public java.lang.Integer getMaxReplicas(); + public A withMaxReplicas(java.lang.Integer maxReplicas); + public java.lang.Boolean hasMaxReplicas(); - public A addToMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2MetricSpec item); - public A setToMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2MetricSpec item); + + public A addToMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricSpec item); + + public A setToMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricSpec item); + public A addToMetrics(io.kubernetes.client.openapi.models.V2beta2MetricSpec... items); - public A addAllToMetrics(java.util.Collection items); + + public A addAllToMetrics( + java.util.Collection items); + public A removeFromMetrics(io.kubernetes.client.openapi.models.V2beta2MetricSpec... items); - public A removeAllFromMetrics(java.util.Collection items); - public A removeMatchingFromMetrics(java.util.function.Predicate predicate); - + + public A removeAllFromMetrics( + java.util.Collection items); + + public A removeMatchingFromMetrics( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildMetrics instead. + * * @return The buildable object. */ @java.lang.Deprecated public java.util.List getMetrics(); + public java.util.List buildMetrics(); + public io.kubernetes.client.openapi.models.V2beta2MetricSpec buildMetric(java.lang.Integer index); + public io.kubernetes.client.openapi.models.V2beta2MetricSpec buildFirstMetric(); + public io.kubernetes.client.openapi.models.V2beta2MetricSpec buildLastMetric(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpec buildMatchingMetric(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingMetric(java.util.function.Predicate predicate); - public A withMetrics(java.util.List metrics); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpec buildMatchingMetric( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingMetric( + java.util.function.Predicate + predicate); + + public A withMetrics( + java.util.List metrics); + public A withMetrics(io.kubernetes.client.openapi.models.V2beta2MetricSpec... metrics); + public java.lang.Boolean hasMetrics(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested addNewMetric(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested addNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricSpec item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested setNewMetricLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2MetricSpec item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested editMetric(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested editFirstMetric(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested editLastMetric(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested editMatchingMetric(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + addNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + addNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricSpec item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + setNewMetricLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricSpec item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editMetric(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editFirstMetric(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editLastMetric(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editMatchingMetric( + java.util.function.Predicate + predicate); + public java.lang.Integer getMinReplicas(); + public A withMinReplicas(java.lang.Integer minReplicas); + public java.lang.Boolean hasMinReplicas(); - + /** * This method has been deprecated, please use method buildScaleTargetRef instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference getScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference buildScaleTargetRef(); - public A withScaleTargetRef(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference scaleTargetRef); + + public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference + buildScaleTargetRef(); + + public A withScaleTargetRef( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference scaleTargetRef); + public java.lang.Boolean hasScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested withNewScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested withNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRef(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item); - public interface BehaviorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent>{ + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRef(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editScaleTargetRef(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRef(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item); + + public interface BehaviorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluent< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + N>> { public N and(); + public N endBehavior(); - } - public interface MetricsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent>{ + + public interface MetricsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .MetricsNested< + N>> { public N and(); + public N endMetric(); - } - public interface ScaleTargetRefNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent>{ + + public interface ScaleTargetRefNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + N>> { public N and(); + public N endScaleTargetRef(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerSpecFluentImpl.java index 8c8f746a28..13ead7b280 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerSpecFluentImpl.java @@ -1,25 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V2beta2HorizontalPodAutoscalerSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent{ - public V2beta2HorizontalPodAutoscalerSpecFluentImpl() { - } - public V2beta2HorizontalPodAutoscalerSpecFluentImpl(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec instance) { + +/** Generated */ +public class V2beta2HorizontalPodAutoscalerSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent { + public V2beta2HorizontalPodAutoscalerSpecFluentImpl() {} + + public V2beta2HorizontalPodAutoscalerSpecFluentImpl( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpec instance) { this.withBehavior(instance.getBehavior()); this.withMaxReplicas(instance.getMaxReplicas()); @@ -29,84 +33,198 @@ public V2beta2HorizontalPodAutoscalerSpecFluentImpl(io.kubernetes.client.openapi this.withMinReplicas(instance.getMinReplicas()); this.withScaleTargetRef(instance.getScaleTargetRef()); - } - private io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorBuilder behavior; + + private io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorBuilder + behavior; private java.lang.Integer maxReplicas; private java.util.ArrayList metrics; private java.lang.Integer minReplicas; - private io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder scaleTargetRef; - + private io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder + scaleTargetRef; + /** * This method has been deprecated, please use method buildBehavior instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior getBehavior() { - return this.behavior!=null ?this.behavior.build():null; + return this.behavior != null ? this.behavior.build() : null; } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior buildBehavior() { - return this.behavior!=null ?this.behavior.build():null; + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior + buildBehavior() { + return this.behavior != null ? this.behavior.build() : null; } - public A withBehavior(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior behavior) { + + public A withBehavior( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior behavior) { _visitables.get("behavior").remove(this.behavior); - if (behavior!=null){ this.behavior= new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorBuilder(behavior); _visitables.get("behavior").add(this.behavior);} return (A) this; + if (behavior != null) { + this.behavior = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorBuilder( + behavior); + _visitables.get("behavior").add(this.behavior); + } + return (A) this; } + public java.lang.Boolean hasBehavior() { return this.behavior != null; } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.BehaviorNested withNewBehavior() { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl.BehaviorNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + A> + withNewBehavior() { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl + .BehaviorNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.BehaviorNested withNewBehaviorLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl.BehaviorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + A> + withNewBehaviorLike( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl + .BehaviorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.BehaviorNested editBehavior() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + A> + editBehavior() { return withNewBehaviorLike(getBehavior()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.BehaviorNested editOrNewBehavior() { - return withNewBehaviorLike(getBehavior() != null ? getBehavior(): new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + A> + editOrNewBehavior() { + return withNewBehaviorLike( + getBehavior() != null + ? getBehavior() + : new io.kubernetes.client.openapi.models + .V2beta2HorizontalPodAutoscalerBehaviorBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.BehaviorNested editOrNewBehaviorLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior item) { - return withNewBehaviorLike(getBehavior() != null ? getBehavior(): item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + A> + editOrNewBehaviorLike( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior item) { + return withNewBehaviorLike(getBehavior() != null ? getBehavior() : item); } + public java.lang.Integer getMaxReplicas() { return this.maxReplicas; } + public A withMaxReplicas(java.lang.Integer maxReplicas) { - this.maxReplicas=maxReplicas; return (A) this; + this.maxReplicas = maxReplicas; + return (A) this; } + public java.lang.Boolean hasMaxReplicas() { return this.maxReplicas != null; } - public A addToMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2MetricSpec item) { - if (this.metrics == null) {this.metrics = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(item);_visitables.get("metrics").add(index >= 0 ? index : _visitables.get("metrics").size(), builder);this.metrics.add(index >= 0 ? index : metrics.size(), builder); return (A)this; + + public A addToMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricSpec item) { + if (this.metrics == null) { + this.metrics = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(item); + _visitables.get("metrics").add(index >= 0 ? index : _visitables.get("metrics").size(), builder); + this.metrics.add(index >= 0 ? index : metrics.size(), builder); + return (A) this; } - public A setToMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2MetricSpec item) { - if (this.metrics == null) {this.metrics = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(item); - if (index < 0 || index >= _visitables.get("metrics").size()) { _visitables.get("metrics").add(builder); } else { _visitables.get("metrics").set(index, builder);} - if (index < 0 || index >= metrics.size()) { metrics.add(builder); } else { metrics.set(index, builder);} - return (A)this; + + public A setToMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricSpec item) { + if (this.metrics == null) { + this.metrics = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(item); + if (index < 0 || index >= _visitables.get("metrics").size()) { + _visitables.get("metrics").add(builder); + } else { + _visitables.get("metrics").set(index, builder); + } + if (index < 0 || index >= metrics.size()) { + metrics.add(builder); + } else { + metrics.set(index, builder); + } + return (A) this; } + public A addToMetrics(io.kubernetes.client.openapi.models.V2beta2MetricSpec... items) { - if (this.metrics == null) {this.metrics = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta2MetricSpec item : items) {io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(item);_visitables.get("metrics").add(builder);this.metrics.add(builder);} return (A)this; + if (this.metrics == null) { + this.metrics = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2beta2MetricSpec item : items) { + io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(item); + _visitables.get("metrics").add(builder); + this.metrics.add(builder); + } + return (A) this; } - public A addAllToMetrics(java.util.Collection items) { - if (this.metrics == null) {this.metrics = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta2MetricSpec item : items) {io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(item);_visitables.get("metrics").add(builder);this.metrics.add(builder);} return (A)this; + + public A addAllToMetrics( + java.util.Collection items) { + if (this.metrics == null) { + this.metrics = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2beta2MetricSpec item : items) { + io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(item); + _visitables.get("metrics").add(builder); + this.metrics.add(builder); + } + return (A) this; } + public A removeFromMetrics(io.kubernetes.client.openapi.models.V2beta2MetricSpec... items) { - for (io.kubernetes.client.openapi.models.V2beta2MetricSpec item : items) {io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(item);_visitables.get("metrics").remove(builder);if (this.metrics != null) {this.metrics.remove(builder);}} return (A)this; + for (io.kubernetes.client.openapi.models.V2beta2MetricSpec item : items) { + io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(item); + _visitables.get("metrics").remove(builder); + if (this.metrics != null) { + this.metrics.remove(builder); + } + } + return (A) this; } - public A removeAllFromMetrics(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2beta2MetricSpec item : items) {io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder = new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(item);_visitables.get("metrics").remove(builder);if (this.metrics != null) {this.metrics.remove(builder);}} return (A)this; + + public A removeAllFromMetrics( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V2beta2MetricSpec item : items) { + io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(item); + _visitables.get("metrics").remove(builder); + if (this.metrics != null) { + this.metrics.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromMetrics(java.util.function.Predicate predicate) { + + public A removeMatchingFromMetrics( + java.util.function.Predicate + predicate) { if (metrics == null) return (A) this; - final Iterator each = metrics.iterator(); + final Iterator each = + metrics.iterator(); final List visitables = _visitables.get("metrics"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder = each.next(); @@ -115,183 +233,358 @@ public A removeMatchingFromMetrics(java.util.function.Predicate getMetrics() { return metrics != null ? build(metrics) : null; } + public java.util.List buildMetrics() { return metrics != null ? build(metrics) : null; } - public io.kubernetes.client.openapi.models.V2beta2MetricSpec buildMetric(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2beta2MetricSpec buildMetric( + java.lang.Integer index) { return this.metrics.get(index).build(); } + public io.kubernetes.client.openapi.models.V2beta2MetricSpec buildFirstMetric() { return this.metrics.get(0).build(); } + public io.kubernetes.client.openapi.models.V2beta2MetricSpec buildLastMetric() { return this.metrics.get(metrics.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpec buildMatchingMetric(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder item: metrics) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2beta2MetricSpec buildMatchingMetric( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder item : metrics) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingMetric(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder item: metrics) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingMetric( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder item : metrics) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withMetrics(java.util.List metrics) { - if (this.metrics != null) { _visitables.get("metrics").removeAll(this.metrics);} - if (metrics != null) {this.metrics = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2beta2MetricSpec item : metrics){this.addToMetrics(item);}} else { this.metrics = null;} return (A) this; + + public A withMetrics( + java.util.List metrics) { + if (this.metrics != null) { + _visitables.get("metrics").removeAll(this.metrics); + } + if (metrics != null) { + this.metrics = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2beta2MetricSpec item : metrics) { + this.addToMetrics(item); + } + } else { + this.metrics = null; + } + return (A) this; } + public A withMetrics(io.kubernetes.client.openapi.models.V2beta2MetricSpec... metrics) { - if (this.metrics != null) {this.metrics.clear();} - if (metrics != null) {for (io.kubernetes.client.openapi.models.V2beta2MetricSpec item :metrics){ this.addToMetrics(item);}} return (A) this; + if (this.metrics != null) { + this.metrics.clear(); + } + if (metrics != null) { + for (io.kubernetes.client.openapi.models.V2beta2MetricSpec item : metrics) { + this.addToMetrics(item); + } + } + return (A) this; } + public java.lang.Boolean hasMetrics() { return metrics != null && !metrics.isEmpty(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested addNewMetric() { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl.MetricsNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + addNewMetric() { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl + .MetricsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested addNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricSpec item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl.MetricsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + addNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricSpec item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl + .MetricsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested setNewMetricLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2MetricSpec item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl.MetricsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + setNewMetricLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricSpec item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl + .MetricsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested editMetric(java.lang.Integer index) { - if (metrics.size() <= index) throw new RuntimeException("Can't edit metrics. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editMetric(java.lang.Integer index) { + if (metrics.size() <= index) + throw new RuntimeException("Can't edit metrics. Index exceeds size."); return setNewMetricLike(index, buildMetric(index)); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested editFirstMetric() { - if (metrics.size() == 0) throw new RuntimeException("Can't edit first metrics. The list is empty."); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editFirstMetric() { + if (metrics.size() == 0) + throw new RuntimeException("Can't edit first metrics. The list is empty."); return setNewMetricLike(0, buildMetric(0)); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested editLastMetric() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editLastMetric() { int index = metrics.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last metrics. The list is empty."); return setNewMetricLike(index, buildMetric(index)); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested editMatchingMetric(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested< + A> + editMatchingMetric( + java.util.function.Predicate + predicate) { int index = -1; - for (int i=0;i withNewScaleTargetRef() { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl.ScaleTargetRefNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRef() { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl + .ScaleTargetRefNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested withNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl.ScaleTargetRefNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + withNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluentImpl + .ScaleTargetRefNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editScaleTargetRef() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editScaleTargetRef() { return withNewScaleTargetRefLike(getScaleTargetRef()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRef() { - return withNewScaleTargetRefLike(getScaleTargetRef() != null ? getScaleTargetRef(): new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRef() { + return withNewScaleTargetRefLike( + getScaleTargetRef() != null + ? getScaleTargetRef() + : new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested editOrNewScaleTargetRefLike(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { - return withNewScaleTargetRefLike(getScaleTargetRef() != null ? getScaleTargetRef(): item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + A> + editOrNewScaleTargetRefLike( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { + return withNewScaleTargetRefLike(getScaleTargetRef() != null ? getScaleTargetRef() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - V2beta2HorizontalPodAutoscalerSpecFluentImpl that = (V2beta2HorizontalPodAutoscalerSpecFluentImpl) o; - if (behavior != null ? !behavior.equals(that.behavior) :that.behavior != null) return false; - if (maxReplicas != null ? !maxReplicas.equals(that.maxReplicas) :that.maxReplicas != null) return false; - if (metrics != null ? !metrics.equals(that.metrics) :that.metrics != null) return false; - if (minReplicas != null ? !minReplicas.equals(that.minReplicas) :that.minReplicas != null) return false; - if (scaleTargetRef != null ? !scaleTargetRef.equals(that.scaleTargetRef) :that.scaleTargetRef != null) return false; + V2beta2HorizontalPodAutoscalerSpecFluentImpl that = + (V2beta2HorizontalPodAutoscalerSpecFluentImpl) o; + if (behavior != null ? !behavior.equals(that.behavior) : that.behavior != null) return false; + if (maxReplicas != null ? !maxReplicas.equals(that.maxReplicas) : that.maxReplicas != null) + return false; + if (metrics != null ? !metrics.equals(that.metrics) : that.metrics != null) return false; + if (minReplicas != null ? !minReplicas.equals(that.minReplicas) : that.minReplicas != null) + return false; + if (scaleTargetRef != null + ? !scaleTargetRef.equals(that.scaleTargetRef) + : that.scaleTargetRef != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(behavior, maxReplicas, metrics, minReplicas, scaleTargetRef, super.hashCode()); + return java.util.Objects.hash( + behavior, maxReplicas, metrics, minReplicas, scaleTargetRef, super.hashCode()); } - public class BehaviorNestedImpl extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.BehaviorNested,io.kubernetes.client.fluent.Nested{ - BehaviorNestedImpl(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorBuilder(this, item); + + public class BehaviorNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .BehaviorNested< + N>, + io.kubernetes.client.fluent.Nested { + BehaviorNestedImpl( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehavior item) { + this.builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorBuilder( + this, item); } + BehaviorNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorBuilder( + this); } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerBehaviorBuilder builder; + public N and() { return (N) V2beta2HorizontalPodAutoscalerSpecFluentImpl.this.withBehavior(builder.build()); } + public N endBehavior() { return and(); } - } - public class MetricsNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.MetricsNested,io.kubernetes.client.fluent.Nested{ - MetricsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2MetricSpec item) { + + public class MetricsNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .MetricsNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .MetricsNested< + N>, + io.kubernetes.client.fluent.Nested { + MetricsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricSpec item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(this, item); } + MetricsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2beta2HorizontalPodAutoscalerSpecFluentImpl.this.setToMetrics(index,builder.build()); + return (N) + V2beta2HorizontalPodAutoscalerSpecFluentImpl.this.setToMetrics(index, builder.build()); } + public N endMetric() { return and(); } - } - public class ScaleTargetRefNestedImpl extends io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent.ScaleTargetRefNested,io.kubernetes.client.fluent.Nested{ - ScaleTargetRefNestedImpl(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder(this, item); + + public class ScaleTargetRefNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerSpecFluent + .ScaleTargetRefNested< + N>, + io.kubernetes.client.fluent.Nested { + ScaleTargetRefNestedImpl( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { + this.builder = + new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder( + this, item); } + ScaleTargetRefNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder builder; + public N and() { - return (N) V2beta2HorizontalPodAutoscalerSpecFluentImpl.this.withScaleTargetRef(builder.build()); + return (N) + V2beta2HorizontalPodAutoscalerSpecFluentImpl.this.withScaleTargetRef(builder.build()); } + public N endScaleTargetRef() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerStatusBuilder.java index 8f742f4260..1fc146038d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2HorizontalPodAutoscalerStatusBuilder extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2HorizontalPodAutoscalerStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusBuilder> { public V2beta2HorizontalPodAutoscalerStatusBuilder() { this(false); } + public V2beta2HorizontalPodAutoscalerStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2HorizontalPodAutoscalerStatus(), validationEnabled); } - public V2beta2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent fluent) { + + public V2beta2HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent fluent) { this(fluent, false); } - public V2beta2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2HorizontalPodAutoscalerStatus(), validationEnabled); } - public V2beta2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus instance) { + + public V2beta2HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus instance) { this(fluent, instance, false); } - public V2beta2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withConditions(instance.getConditions()); fluent.withCurrentMetrics(instance.getCurrentMetrics()); @@ -33,13 +60,18 @@ public V2beta2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi. fluent.withObservedGeneration(instance.getObservedGeneration()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus instance) { - this(instance,false); + + public V2beta2HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus instance) { + this(instance, false); } - public V2beta2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2HorizontalPodAutoscalerStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withConditions(instance.getConditions()); this.withCurrentMetrics(instance.getCurrentMetrics()); @@ -52,10 +84,12 @@ public V2beta2HorizontalPodAutoscalerStatusBuilder(io.kubernetes.client.openapi. this.withObservedGeneration(instance.getObservedGeneration()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus build() { V2beta2HorizontalPodAutoscalerStatus buildable = new V2beta2HorizontalPodAutoscalerStatus(); buildable.setConditions(fluent.getConditions()); @@ -66,18 +100,24 @@ public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus buildable.setObservedGeneration(fluent.getObservedGeneration()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; - V2beta2HorizontalPodAutoscalerStatusBuilder that = (V2beta2HorizontalPodAutoscalerStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + V2beta2HorizontalPodAutoscalerStatusBuilder that = + (V2beta2HorizontalPodAutoscalerStatusBuilder) o; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerStatusFluent.java index 0e80455ff3..84ceac1a95 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerStatusFluent.java @@ -1,106 +1,272 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.lang.String; -import java.util.function.Predicate; -import java.lang.Deprecated; -import java.util.Iterator; -import java.util.List; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.lang.Long; -import java.util.Collection; - - /** - * Generated - */ -public interface V2beta2HorizontalPodAutoscalerStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item); - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item); - public A addToConditions(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition... items); - public A addAllToConditions(java.util.Collection items); - public A removeFromConditions(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition... items); - public A removeAllFromConditions(java.util.Collection items); - public A removeMatchingFromConditions(java.util.function.Predicate predicate); - +/** Generated */ +public interface V2beta2HorizontalPodAutoscalerStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item); + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item); + + public A addToConditions( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition... items); + + public A addAllToConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition> + items); + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition... items); + + public A removeAllFromConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition> + items); + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder> + predicate); + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions(); - public java.util.List buildConditions(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition buildCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition buildFirstCondition(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition buildLastCondition(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition buildMatchingCondition(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate); - public A withConditions(java.util.List conditions); - public A withConditions(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition... conditions); + public java.util.List + getConditions(); + + public java.util.List + buildConditions(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition buildCondition( + java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition + buildFirstCondition(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition + buildLastCondition(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V2beta2HorizontalPodAutoscalerConditionBuilder> + predicate); + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder> + predicate); + + public A withConditions( + java.util.List + conditions); + + public A withConditions( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition... conditions); + public java.lang.Boolean hasConditions(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested addNewCondition(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested editCondition(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested editFirstCondition(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested editLastCondition(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate); - public A addToCurrentMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2MetricStatus item); - public A setToCurrentMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2MetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + addNewCondition(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editFirstCondition(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editLastCondition(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V2beta2HorizontalPodAutoscalerConditionBuilder> + predicate); + + public A addToCurrentMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricStatus item); + + public A setToCurrentMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricStatus item); + public A addToCurrentMetrics(io.kubernetes.client.openapi.models.V2beta2MetricStatus... items); - public A addAllToCurrentMetrics(java.util.Collection items); - public A removeFromCurrentMetrics(io.kubernetes.client.openapi.models.V2beta2MetricStatus... items); - public A removeAllFromCurrentMetrics(java.util.Collection items); - public A removeMatchingFromCurrentMetrics(java.util.function.Predicate predicate); - + + public A addAllToCurrentMetrics( + java.util.Collection items); + + public A removeFromCurrentMetrics( + io.kubernetes.client.openapi.models.V2beta2MetricStatus... items); + + public A removeAllFromCurrentMetrics( + java.util.Collection items); + + public A removeMatchingFromCurrentMetrics( + java.util.function.Predicate + predicate); + /** * This method has been deprecated, please use method buildCurrentMetrics instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getCurrentMetrics(); - public java.util.List buildCurrentMetrics(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatus buildCurrentMetric(java.lang.Integer index); + public java.util.List + getCurrentMetrics(); + + public java.util.List + buildCurrentMetrics(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatus buildCurrentMetric( + java.lang.Integer index); + public io.kubernetes.client.openapi.models.V2beta2MetricStatus buildFirstCurrentMetric(); + public io.kubernetes.client.openapi.models.V2beta2MetricStatus buildLastCurrentMetric(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatus buildMatchingCurrentMetric(java.util.function.Predicate predicate); - public java.lang.Boolean hasMatchingCurrentMetric(java.util.function.Predicate predicate); - public A withCurrentMetrics(java.util.List currentMetrics); - public A withCurrentMetrics(io.kubernetes.client.openapi.models.V2beta2MetricStatus... currentMetrics); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatus buildMatchingCurrentMetric( + java.util.function.Predicate + predicate); + + public java.lang.Boolean hasMatchingCurrentMetric( + java.util.function.Predicate + predicate); + + public A withCurrentMetrics( + java.util.List currentMetrics); + + public A withCurrentMetrics( + io.kubernetes.client.openapi.models.V2beta2MetricStatus... currentMetrics); + public java.lang.Boolean hasCurrentMetrics(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested addNewCurrentMetric(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested addNewCurrentMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricStatus item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested setNewCurrentMetricLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2MetricStatus item); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editCurrentMetric(java.lang.Integer index); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editFirstCurrentMetric(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editLastCurrentMetric(); - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editMatchingCurrentMetric(java.util.function.Predicate predicate); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + addNewCurrentMetric(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + addNewCurrentMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + setNewCurrentMetricLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editCurrentMetric(java.lang.Integer index); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editFirstCurrentMetric(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editLastCurrentMetric(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editMatchingCurrentMetric( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder> + predicate); + public java.lang.Integer getCurrentReplicas(); + public A withCurrentReplicas(java.lang.Integer currentReplicas); + public java.lang.Boolean hasCurrentReplicas(); + public java.lang.Integer getDesiredReplicas(); + public A withDesiredReplicas(java.lang.Integer desiredReplicas); + public java.lang.Boolean hasDesiredReplicas(); + public java.time.OffsetDateTime getLastScaleTime(); + public A withLastScaleTime(java.time.OffsetDateTime lastScaleTime); + public java.lang.Boolean hasLastScaleTime(); + public java.lang.Long getObservedGeneration(); + public A withObservedGeneration(java.lang.Long observedGeneration); + public java.lang.Boolean hasObservedGeneration(); - public interface ConditionsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent>{ + + public interface ConditionsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluent< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + N>> { public N and(); + public N endCondition(); - } - public interface CurrentMetricsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent>{ + + public interface CurrentMetricsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + N>> { public N and(); + public N endCurrentMetric(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerStatusFluentImpl.java index 475f152dfd..f8beb18241 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2HorizontalPodAutoscalerStatusFluentImpl.java @@ -1,27 +1,29 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import io.kubernetes.client.fluent.Nested; -import java.util.ArrayList; -import java.util.function.Predicate; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import java.util.Iterator; import java.util.List; -import java.lang.Boolean; -import java.lang.Integer; -import java.time.OffsetDateTime; -import java.lang.Long; -import java.util.Collection; -import java.lang.Object; - - /** - * Generated - */ -public class V2beta2HorizontalPodAutoscalerStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent{ - public V2beta2HorizontalPodAutoscalerStatusFluentImpl() { - } - public V2beta2HorizontalPodAutoscalerStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus instance) { + +/** Generated */ +public class V2beta2HorizontalPodAutoscalerStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent { + public V2beta2HorizontalPodAutoscalerStatusFluentImpl() {} + + public V2beta2HorizontalPodAutoscalerStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatus instance) { this.withConditions(instance.getConditions()); this.withCurrentMetrics(instance.getCurrentMetrics()); @@ -33,148 +35,411 @@ public V2beta2HorizontalPodAutoscalerStatusFluentImpl(io.kubernetes.client.opena this.withLastScaleTime(instance.getLastScaleTime()); this.withObservedGeneration(instance.getObservedGeneration()); - } - private java.util.ArrayList conditions; - private java.util.ArrayList currentMetrics; + + private java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder> + conditions; + private java.util.ArrayList + currentMetrics; private java.lang.Integer currentReplicas; private java.lang.Integer desiredReplicas; private java.time.OffsetDateTime lastScaleTime; private java.lang.Long observedGeneration; - public A addToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").add(index >= 0 ? index : _visitables.get("conditions").size(), builder);this.conditions.add(index >= 0 ? index : conditions.size(), builder); return (A)this; + + public A addToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder( + item); + _visitables + .get("conditions") + .add(index >= 0 ? index : _visitables.get("conditions").size(), builder); + this.conditions.add(index >= 0 ? index : conditions.size(), builder); + return (A) this; } - public A setToConditions(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder(item); - if (index < 0 || index >= _visitables.get("conditions").size()) { _visitables.get("conditions").add(builder); } else { _visitables.get("conditions").set(index, builder);} - if (index < 0 || index >= conditions.size()) { conditions.add(builder); } else { conditions.set(index, builder);} - return (A)this; + + public A setToConditions( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder>(); + } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder( + item); + if (index < 0 || index >= _visitables.get("conditions").size()) { + _visitables.get("conditions").add(builder); + } else { + _visitables.get("conditions").set(index, builder); + } + if (index < 0 || index >= conditions.size()) { + conditions.add(builder); + } else { + conditions.set(index, builder); + } + return (A) this; } - public A addToConditions(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition... items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item : items) {io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addToConditions( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition... items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item : items) { + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder( + item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A addAllToConditions(java.util.Collection items) { - if (this.conditions == null) {this.conditions = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item : items) {io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").add(builder);this.conditions.add(builder);} return (A)this; + + public A addAllToConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition> + items) { + if (this.conditions == null) { + this.conditions = + new java.util.ArrayList< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder>(); + } + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item : items) { + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder( + item); + _visitables.get("conditions").add(builder); + this.conditions.add(builder); + } + return (A) this; } - public A removeFromConditions(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition... items) { - for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item : items) {io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeFromConditions( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition... items) { + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item : items) { + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder( + item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeAllFromConditions(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item : items) {io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder(item);_visitables.get("conditions").remove(builder);if (this.conditions != null) {this.conditions.remove(builder);}} return (A)this; + + public A removeAllFromConditions( + java.util.Collection< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition> + items) { + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item : items) { + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder( + item); + _visitables.get("conditions").remove(builder); + if (this.conditions != null) { + this.conditions.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromConditions(java.util.function.Predicate predicate) { + + public A removeMatchingFromConditions( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder> + predicate) { if (conditions == null) return (A) this; - final Iterator each = conditions.iterator(); + final Iterator< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder> + each = conditions.iterator(); final List visitables = _visitables.get("conditions"); while (each.hasNext()) { - io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = each.next(); + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder = + each.next(); if (predicate.test(builder)) { visitables.remove(builder); each.remove(); } } - return (A)this; + return (A) this; } - + /** * This method has been deprecated, please use method buildConditions instead. + * * @return The buildable object. */ @java.lang.Deprecated - public java.util.List getConditions() { + public java.util.List + getConditions() { return conditions != null ? build(conditions) : null; } - public java.util.List buildConditions() { + + public java.util.List + buildConditions() { return conditions != null ? build(conditions) : null; } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition buildCondition(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition buildCondition( + java.lang.Integer index) { return this.conditions.get(index).build(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition buildFirstCondition() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition + buildFirstCondition() { return this.conditions.get(0).build(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition buildLastCondition() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition + buildLastCondition() { return this.conditions.get(conditions.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition buildMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder item: conditions) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition + buildMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V2beta2HorizontalPodAutoscalerConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCondition(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder item: conditions) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder> + predicate) { + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder item : + conditions) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withConditions(java.util.List conditions) { - if (this.conditions != null) { _visitables.get("conditions").removeAll(this.conditions);} - if (conditions != null) {this.conditions = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item : conditions){this.addToConditions(item);}} else { this.conditions = null;} return (A) this; + + public A withConditions( + java.util.List + conditions) { + if (this.conditions != null) { + _visitables.get("conditions").removeAll(this.conditions); + } + if (conditions != null) { + this.conditions = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item : + conditions) { + this.addToConditions(item); + } + } else { + this.conditions = null; + } + return (A) this; } - public A withConditions(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition... conditions) { - if (this.conditions != null) {this.conditions.clear();} - if (conditions != null) {for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item :conditions){ this.addToConditions(item);}} return (A) this; + + public A withConditions( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition... conditions) { + if (this.conditions != null) { + this.conditions.clear(); + } + if (conditions != null) { + for (io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item : + conditions) { + this.addToConditions(item); + } + } + return (A) this; } + public java.lang.Boolean hasConditions() { return conditions != null && !conditions.isEmpty(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested addNewCondition() { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl.ConditionsNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + addNewCondition() { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl + .ConditionsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested addNewConditionLike(io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl.ConditionsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + addNewConditionLike( + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl + .ConditionsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested setNewConditionLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl.ConditionsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + setNewConditionLike( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl + .ConditionsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested editCondition(java.lang.Integer index) { - if (conditions.size() <= index) throw new RuntimeException("Can't edit conditions. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editCondition(java.lang.Integer index) { + if (conditions.size() <= index) + throw new RuntimeException("Can't edit conditions. Index exceeds size."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested editFirstCondition() { - if (conditions.size() == 0) throw new RuntimeException("Can't edit first conditions. The list is empty."); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editFirstCondition() { + if (conditions.size() == 0) + throw new RuntimeException("Can't edit first conditions. The list is empty."); return setNewConditionLike(0, buildCondition(0)); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested editLastCondition() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editLastCondition() { int index = conditions.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last conditions. The list is empty."); return setNewConditionLike(index, buildCondition(index)); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested editMatchingCondition(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + A> + editMatchingCondition( + java.util.function.Predicate< + io.kubernetes.client.openapi.models + .V2beta2HorizontalPodAutoscalerConditionBuilder> + predicate) { int index = -1; - for (int i=0;i();} - io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(item);_visitables.get("currentMetrics").add(index >= 0 ? index : _visitables.get("currentMetrics").size(), builder);this.currentMetrics.add(index >= 0 ? index : currentMetrics.size(), builder); return (A)this; + + public A addToCurrentMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricStatus item) { + if (this.currentMetrics == null) { + this.currentMetrics = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(item); + _visitables + .get("currentMetrics") + .add(index >= 0 ? index : _visitables.get("currentMetrics").size(), builder); + this.currentMetrics.add(index >= 0 ? index : currentMetrics.size(), builder); + return (A) this; } - public A setToCurrentMetrics(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2MetricStatus item) { - if (this.currentMetrics == null) {this.currentMetrics = new java.util.ArrayList();} - io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(item); - if (index < 0 || index >= _visitables.get("currentMetrics").size()) { _visitables.get("currentMetrics").add(builder); } else { _visitables.get("currentMetrics").set(index, builder);} - if (index < 0 || index >= currentMetrics.size()) { currentMetrics.add(builder); } else { currentMetrics.set(index, builder);} - return (A)this; + + public A setToCurrentMetrics( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricStatus item) { + if (this.currentMetrics == null) { + this.currentMetrics = + new java.util.ArrayList(); + } + io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(item); + if (index < 0 || index >= _visitables.get("currentMetrics").size()) { + _visitables.get("currentMetrics").add(builder); + } else { + _visitables.get("currentMetrics").set(index, builder); + } + if (index < 0 || index >= currentMetrics.size()) { + currentMetrics.add(builder); + } else { + currentMetrics.set(index, builder); + } + return (A) this; } + public A addToCurrentMetrics(io.kubernetes.client.openapi.models.V2beta2MetricStatus... items) { - if (this.currentMetrics == null) {this.currentMetrics = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta2MetricStatus item : items) {io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(item);_visitables.get("currentMetrics").add(builder);this.currentMetrics.add(builder);} return (A)this; + if (this.currentMetrics == null) { + this.currentMetrics = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2beta2MetricStatus item : items) { + io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(item); + _visitables.get("currentMetrics").add(builder); + this.currentMetrics.add(builder); + } + return (A) this; } - public A addAllToCurrentMetrics(java.util.Collection items) { - if (this.currentMetrics == null) {this.currentMetrics = new java.util.ArrayList();} - for (io.kubernetes.client.openapi.models.V2beta2MetricStatus item : items) {io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(item);_visitables.get("currentMetrics").add(builder);this.currentMetrics.add(builder);} return (A)this; + + public A addAllToCurrentMetrics( + java.util.Collection items) { + if (this.currentMetrics == null) { + this.currentMetrics = + new java.util.ArrayList(); + } + for (io.kubernetes.client.openapi.models.V2beta2MetricStatus item : items) { + io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(item); + _visitables.get("currentMetrics").add(builder); + this.currentMetrics.add(builder); + } + return (A) this; } - public A removeFromCurrentMetrics(io.kubernetes.client.openapi.models.V2beta2MetricStatus... items) { - for (io.kubernetes.client.openapi.models.V2beta2MetricStatus item : items) {io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(item);_visitables.get("currentMetrics").remove(builder);if (this.currentMetrics != null) {this.currentMetrics.remove(builder);}} return (A)this; + + public A removeFromCurrentMetrics( + io.kubernetes.client.openapi.models.V2beta2MetricStatus... items) { + for (io.kubernetes.client.openapi.models.V2beta2MetricStatus item : items) { + io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(item); + _visitables.get("currentMetrics").remove(builder); + if (this.currentMetrics != null) { + this.currentMetrics.remove(builder); + } + } + return (A) this; } - public A removeAllFromCurrentMetrics(java.util.Collection items) { - for (io.kubernetes.client.openapi.models.V2beta2MetricStatus item : items) {io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder = new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(item);_visitables.get("currentMetrics").remove(builder);if (this.currentMetrics != null) {this.currentMetrics.remove(builder);}} return (A)this; + + public A removeAllFromCurrentMetrics( + java.util.Collection items) { + for (io.kubernetes.client.openapi.models.V2beta2MetricStatus item : items) { + io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder = + new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(item); + _visitables.get("currentMetrics").remove(builder); + if (this.currentMetrics != null) { + this.currentMetrics.remove(builder); + } + } + return (A) this; } - public A removeMatchingFromCurrentMetrics(java.util.function.Predicate predicate) { + + public A removeMatchingFromCurrentMetrics( + java.util.function.Predicate + predicate) { if (currentMetrics == null) return (A) this; - final Iterator each = currentMetrics.iterator(); + final Iterator each = + currentMetrics.iterator(); final List visitables = _visitables.get("currentMetrics"); while (each.hasNext()) { io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder = each.next(); @@ -183,164 +448,322 @@ public A removeMatchingFromCurrentMetrics(java.util.function.Predicate getCurrentMetrics() { + public java.util.List + getCurrentMetrics() { return currentMetrics != null ? build(currentMetrics) : null; } - public java.util.List buildCurrentMetrics() { + + public java.util.List + buildCurrentMetrics() { return currentMetrics != null ? build(currentMetrics) : null; } - public io.kubernetes.client.openapi.models.V2beta2MetricStatus buildCurrentMetric(java.lang.Integer index) { + + public io.kubernetes.client.openapi.models.V2beta2MetricStatus buildCurrentMetric( + java.lang.Integer index) { return this.currentMetrics.get(index).build(); } + public io.kubernetes.client.openapi.models.V2beta2MetricStatus buildFirstCurrentMetric() { return this.currentMetrics.get(0).build(); } + public io.kubernetes.client.openapi.models.V2beta2MetricStatus buildLastCurrentMetric() { return this.currentMetrics.get(currentMetrics.size() - 1).build(); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatus buildMatchingCurrentMetric(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder item: currentMetrics) { if(predicate.test(item)){ return item.build();} } return null; + + public io.kubernetes.client.openapi.models.V2beta2MetricStatus buildMatchingCurrentMetric( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder item : currentMetrics) { + if (predicate.test(item)) { + return item.build(); + } + } + return null; } - public java.lang.Boolean hasMatchingCurrentMetric(java.util.function.Predicate predicate) { - for (io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder item: currentMetrics) { if(predicate.test(item)){ return true;} } return false; + + public java.lang.Boolean hasMatchingCurrentMetric( + java.util.function.Predicate + predicate) { + for (io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder item : currentMetrics) { + if (predicate.test(item)) { + return true; + } + } + return false; } - public A withCurrentMetrics(java.util.List currentMetrics) { - if (this.currentMetrics != null) { _visitables.get("currentMetrics").removeAll(this.currentMetrics);} - if (currentMetrics != null) {this.currentMetrics = new java.util.ArrayList(); for (io.kubernetes.client.openapi.models.V2beta2MetricStatus item : currentMetrics){this.addToCurrentMetrics(item);}} else { this.currentMetrics = null;} return (A) this; + + public A withCurrentMetrics( + java.util.List currentMetrics) { + if (this.currentMetrics != null) { + _visitables.get("currentMetrics").removeAll(this.currentMetrics); + } + if (currentMetrics != null) { + this.currentMetrics = new java.util.ArrayList(); + for (io.kubernetes.client.openapi.models.V2beta2MetricStatus item : currentMetrics) { + this.addToCurrentMetrics(item); + } + } else { + this.currentMetrics = null; + } + return (A) this; } - public A withCurrentMetrics(io.kubernetes.client.openapi.models.V2beta2MetricStatus... currentMetrics) { - if (this.currentMetrics != null) {this.currentMetrics.clear();} - if (currentMetrics != null) {for (io.kubernetes.client.openapi.models.V2beta2MetricStatus item :currentMetrics){ this.addToCurrentMetrics(item);}} return (A) this; + + public A withCurrentMetrics( + io.kubernetes.client.openapi.models.V2beta2MetricStatus... currentMetrics) { + if (this.currentMetrics != null) { + this.currentMetrics.clear(); + } + if (currentMetrics != null) { + for (io.kubernetes.client.openapi.models.V2beta2MetricStatus item : currentMetrics) { + this.addToCurrentMetrics(item); + } + } + return (A) this; } + public java.lang.Boolean hasCurrentMetrics() { return currentMetrics != null && !currentMetrics.isEmpty(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested addNewCurrentMetric() { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl.CurrentMetricsNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + addNewCurrentMetric() { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl + .CurrentMetricsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested addNewCurrentMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl.CurrentMetricsNestedImpl(-1, item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + addNewCurrentMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl + .CurrentMetricsNestedImpl(-1, item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested setNewCurrentMetricLike(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2MetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl.CurrentMetricsNestedImpl(index, item); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + setNewCurrentMetricLike( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluentImpl + .CurrentMetricsNestedImpl(index, item); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editCurrentMetric(java.lang.Integer index) { - if (currentMetrics.size() <= index) throw new RuntimeException("Can't edit currentMetrics. Index exceeds size."); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editCurrentMetric(java.lang.Integer index) { + if (currentMetrics.size() <= index) + throw new RuntimeException("Can't edit currentMetrics. Index exceeds size."); return setNewCurrentMetricLike(index, buildCurrentMetric(index)); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editFirstCurrentMetric() { - if (currentMetrics.size() == 0) throw new RuntimeException("Can't edit first currentMetrics. The list is empty."); + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editFirstCurrentMetric() { + if (currentMetrics.size() == 0) + throw new RuntimeException("Can't edit first currentMetrics. The list is empty."); return setNewCurrentMetricLike(0, buildCurrentMetric(0)); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editLastCurrentMetric() { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editLastCurrentMetric() { int index = currentMetrics.size() - 1; if (index < 0) throw new RuntimeException("Can't edit last currentMetrics. The list is empty."); return setNewCurrentMetricLike(index, buildCurrentMetric(index)); } - public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested editMatchingCurrentMetric(java.util.function.Predicate predicate) { + + public io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + A> + editMatchingCurrentMetric( + java.util.function.Predicate< + io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder> + predicate) { int index = -1; - for (int i=0;i extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.ConditionsNested,io.kubernetes.client.fluent.Nested{ - ConditionsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item) { + + public class ConditionsNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .ConditionsNested< + N>, + io.kubernetes.client.fluent.Nested { + ConditionsNestedImpl( + java.lang.Integer index, + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerCondition item) { this.index = index; - this.builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder( + this, item); } + ConditionsNestedImpl() { this.index = -1; - this.builder = new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder( + this); } + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerConditionBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2beta2HorizontalPodAutoscalerStatusFluentImpl.this.setToConditions(index,builder.build()); + return (N) + V2beta2HorizontalPodAutoscalerStatusFluentImpl.this.setToConditions( + index, builder.build()); } + public N endCondition() { return and(); } - } - public class CurrentMetricsNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent.CurrentMetricsNested,io.kubernetes.client.fluent.Nested{ - CurrentMetricsNestedImpl(java.lang.Integer index,io.kubernetes.client.openapi.models.V2beta2MetricStatus item) { + + public class CurrentMetricsNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2HorizontalPodAutoscalerStatusFluent + .CurrentMetricsNested< + N>, + io.kubernetes.client.fluent.Nested { + CurrentMetricsNestedImpl( + java.lang.Integer index, io.kubernetes.client.openapi.models.V2beta2MetricStatus item) { this.index = index; this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(this, item); } + CurrentMetricsNestedImpl() { this.index = -1; this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder builder; java.lang.Integer index; + public N and() { - return (N) V2beta2HorizontalPodAutoscalerStatusFluentImpl.this.setToCurrentMetrics(index,builder.build()); + return (N) + V2beta2HorizontalPodAutoscalerStatusFluentImpl.this.setToCurrentMetrics( + index, builder.build()); } + public N endCurrentMetric() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricIdentifierBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricIdentifierBuilder.java index 2efea503a2..be64b606c1 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricIdentifierBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricIdentifierBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2MetricIdentifierBuilder extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2MetricIdentifierBuilder + extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2MetricIdentifier, + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder> { public V2beta2MetricIdentifierBuilder() { this(false); } + public V2beta2MetricIdentifierBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2MetricIdentifier(), validationEnabled); } - public V2beta2MetricIdentifierBuilder(io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent fluent) { + + public V2beta2MetricIdentifierBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent fluent) { this(fluent, false); } - public V2beta2MetricIdentifierBuilder(io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2MetricIdentifierBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2MetricIdentifier(), validationEnabled); } - public V2beta2MetricIdentifierBuilder(io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent fluent,io.kubernetes.client.openapi.models.V2beta2MetricIdentifier instance) { + + public V2beta2MetricIdentifierBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent fluent, + io.kubernetes.client.openapi.models.V2beta2MetricIdentifier instance) { this(fluent, instance, false); } - public V2beta2MetricIdentifierBuilder(io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent fluent,io.kubernetes.client.openapi.models.V2beta2MetricIdentifier instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2MetricIdentifierBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent fluent, + io.kubernetes.client.openapi.models.V2beta2MetricIdentifier instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withSelector(instance.getSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2MetricIdentifierBuilder(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier instance) { - this(instance,false); + + public V2beta2MetricIdentifierBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricIdentifier instance) { + this(instance, false); } - public V2beta2MetricIdentifierBuilder(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2MetricIdentifierBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricIdentifier instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withSelector(instance.getSelector()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier build() { V2beta2MetricIdentifier buildable = new V2beta2MetricIdentifier(); buildable.setName(fluent.getName()); buildable.setSelector(fluent.getSelector()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2MetricIdentifierBuilder that = (V2beta2MetricIdentifierBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricIdentifierFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricIdentifierFluent.java index b0415d224c..ee2d8235ff 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricIdentifierFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricIdentifierFluent.java @@ -1,44 +1,66 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2MetricIdentifierFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta2MetricIdentifierFluent< + A extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector(); + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector(); + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector); + public java.lang.Boolean hasSelector(); - public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested withNewSelector(); - public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested editSelector(); - public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested editOrNewSelector(); - public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); - public interface SelectorNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V1LabelSelectorFluent>{ + + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested + withNewSelector(); + + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested + editSelector(); + + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested + editOrNewSelector(); + + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item); + + public interface SelectorNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V1LabelSelectorFluent< + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested> { public N and(); + public N endSelector(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricIdentifierFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricIdentifierFluentImpl.java index 8f603bd040..70aaec4b5e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricIdentifierFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricIdentifierFluentImpl.java @@ -1,103 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta2MetricIdentifierFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent { + public V2beta2MetricIdentifierFluentImpl() {} - /** - * Generated - */ -public class V2beta2MetricIdentifierFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent{ - public V2beta2MetricIdentifierFluentImpl() { - } - public V2beta2MetricIdentifierFluentImpl(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier instance) { + public V2beta2MetricIdentifierFluentImpl( + io.kubernetes.client.openapi.models.V2beta2MetricIdentifier instance) { this.withName(instance.getName()); this.withSelector(instance.getSelector()); - } + private java.lang.String name; private io.kubernetes.client.openapi.models.V1LabelSelectorBuilder selector; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } - + /** * This method has been deprecated, please use method buildSelector instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V1LabelSelector getSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public io.kubernetes.client.openapi.models.V1LabelSelector buildSelector() { - return this.selector!=null ?this.selector.build():null; + return this.selector != null ? this.selector.build() : null; } + public A withSelector(io.kubernetes.client.openapi.models.V1LabelSelector selector) { _visitables.get("selector").remove(this.selector); - if (selector!=null){ this.selector= new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); _visitables.get("selector").add(this.selector);} return (A) this; + if (selector != null) { + this.selector = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(selector); + _visitables.get("selector").add(this.selector); + } + return (A) this; } + public java.lang.Boolean hasSelector() { return this.selector != null; } - public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested withNewSelector() { - return new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl.SelectorNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested + withNewSelector() { + return new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl + .SelectorNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl.SelectorNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested + withNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl + .SelectorNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested editSelector() { + + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested + editSelector() { return withNewSelectorLike(getSelector()); } - public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested editOrNewSelector() { - return withNewSelectorLike(getSelector() != null ? getSelector(): new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested + editOrNewSelector() { + return withNewSelectorLike( + getSelector() != null + ? getSelector() + : new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { - return withNewSelectorLike(getSelector() != null ? getSelector(): item); + + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested + editOrNewSelectorLike(io.kubernetes.client.openapi.models.V1LabelSelector item) { + return withNewSelectorLike(getSelector() != null ? getSelector() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2MetricIdentifierFluentImpl that = (V2beta2MetricIdentifierFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (selector != null ? !selector.equals(that.selector) :that.selector != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (selector != null ? !selector.equals(that.selector) : that.selector != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, selector, super.hashCode()); + return java.util.Objects.hash(name, selector, super.hashCode()); } - public class SelectorNestedImpl extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested,io.kubernetes.client.fluent.Nested{ + + public class SelectorNestedImpl + extends io.kubernetes.client.openapi.models.V1LabelSelectorFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested> + implements io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent.SelectorNested< + N>, + io.kubernetes.client.fluent.Nested { SelectorNestedImpl(io.kubernetes.client.openapi.models.V1LabelSelector item) { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this, item); } + SelectorNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V1LabelSelectorBuilder(this); } + io.kubernetes.client.openapi.models.V1LabelSelectorBuilder builder; + public N and() { return (N) V2beta2MetricIdentifierFluentImpl.this.withSelector(builder.build()); } + public N endSelector() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricSpecBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricSpecBuilder.java index 0c998305eb..88aa23d003 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricSpecBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricSpecBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2MetricSpecBuilder extends io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2MetricSpecBuilder + extends io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2MetricSpec, + io.kubernetes.client.openapi.models.V2beta2MetricSpecBuilder> { public V2beta2MetricSpecBuilder() { this(false); } + public V2beta2MetricSpecBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2MetricSpec(), validationEnabled); } - public V2beta2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent fluent) { + + public V2beta2MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent fluent) { this(fluent, false); } - public V2beta2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2MetricSpec(), validationEnabled); } - public V2beta2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent fluent,io.kubernetes.client.openapi.models.V2beta2MetricSpec instance) { + + public V2beta2MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent fluent, + io.kubernetes.client.openapi.models.V2beta2MetricSpec instance) { this(fluent, instance, false); } - public V2beta2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent fluent,io.kubernetes.client.openapi.models.V2beta2MetricSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent fluent, + io.kubernetes.client.openapi.models.V2beta2MetricSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainerResource(instance.getContainerResource()); fluent.withExternal(instance.getExternal()); @@ -33,13 +60,17 @@ public V2beta2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta2Metri fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public V2beta2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta2MetricSpec instance) { - this(instance,false); + this(instance, false); } - public V2beta2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta2MetricSpec instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2MetricSpecBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricSpec instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainerResource(instance.getContainerResource()); this.withExternal(instance.getExternal()); @@ -52,10 +83,12 @@ public V2beta2MetricSpecBuilder(io.kubernetes.client.openapi.models.V2beta2Metri this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2MetricSpec build() { V2beta2MetricSpec buildable = new V2beta2MetricSpec(); buildable.setContainerResource(fluent.getContainerResource()); @@ -66,18 +99,23 @@ public io.kubernetes.client.openapi.models.V2beta2MetricSpec build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2MetricSpecBuilder that = (V2beta2MetricSpecBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricSpecFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricSpecFluent.java index bfb02b6d95..5aab8b64e0 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricSpecFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricSpecFluent.java @@ -1,124 +1,221 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; - - /** - * Generated - */ -public interface V2beta2MetricSpecFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2beta2MetricSpecFluent< + A extends io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildContainerResource instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource getContainerResource(); - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource buildContainerResource(); - public A withContainerResource(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource containerResource); + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource + getContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource + buildContainerResource(); + + public A withContainerResource( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource containerResource); + public java.lang.Boolean hasContainerResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested withNewContainerResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested withNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource item); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested editContainerResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested editOrNewContainerResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested editOrNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource item); - + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested + withNewContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested + withNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested + editContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested + editOrNewContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested + editOrNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource item); + /** * This method has been deprecated, please use method buildExternal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource getExternal(); + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource buildExternal(); + public A withExternal(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource external); + public java.lang.Boolean hasExternal(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested withNewExternal(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested withNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource item); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested editExternal(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested editOrNewExternal(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource item); - + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested + withNewExternal(); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested + withNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested + editExternal(); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested + editOrNewExternal(); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested + editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource item); + /** * This method has been deprecated, please use method buildObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource getObject(); + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource buildObject(); + public A withObject(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource _object); + public java.lang.Boolean hasObject(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested withNewObject(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested withNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested + withNewObject(); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested + withNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource item); + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested editObject(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested editOrNewObject(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource item); - + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested + editOrNewObject(); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested + editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource item); + /** * This method has been deprecated, please use method buildPods instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2PodsMetricSource getPods(); + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSource buildPods(); + public A withPods(io.kubernetes.client.openapi.models.V2beta2PodsMetricSource pods); + public java.lang.Boolean hasPods(); + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested withNewPods(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested withNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricSource item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested withNewPodsLike( + io.kubernetes.client.openapi.models.V2beta2PodsMetricSource item); + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested editPods(); + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested editOrNewPods(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricSource item); - + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested + editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricSource item); + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource getResource(); + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource buildResource(); + public A withResource(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource resource); + public java.lang.Boolean hasResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested withNewResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource item); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested editResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested editOrNewResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested + withNewResource(); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested + editResource(); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested + editOrNewResource(); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource item); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface ContainerResourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent>{ + + public interface ContainerResourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluent< + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested< + N>> { public N and(); + public N endContainerResource(); - } - public interface ExternalNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent>{ + + public interface ExternalNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluent< + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested> { public N and(); + public N endExternal(); - } - public interface ObjectNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent>{ + + public interface ObjectNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent< + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested> { public N and(); + public N endObject(); - } - public interface PodsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent>{ + + public interface PodsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent< + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested> { public N and(); + public N endPods(); - } - public interface ResourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent>{ + + public interface ResourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent< + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested> { public N and(); + public N endResource(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricSpecFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricSpecFluentImpl.java index d6ebe53b4d..80048daa8e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricSpecFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricSpecFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Object; +/** Generated */ +public class V2beta2MetricSpecFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent { + public V2beta2MetricSpecFluentImpl() {} - /** - * Generated - */ -public class V2beta2MetricSpecFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent{ - public V2beta2MetricSpecFluentImpl() { - } - public V2beta2MetricSpecFluentImpl(io.kubernetes.client.openapi.models.V2beta2MetricSpec instance) { + public V2beta2MetricSpecFluentImpl( + io.kubernetes.client.openapi.models.V2beta2MetricSpec instance) { this.withContainerResource(instance.getContainerResource()); this.withExternal(instance.getExternal()); @@ -25,295 +32,472 @@ public V2beta2MetricSpecFluentImpl(io.kubernetes.client.openapi.models.V2beta2Me this.withResource(instance.getResource()); this.withType(instance.getType()); - } - private io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceBuilder containerResource; + + private io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceBuilder + containerResource; private io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceBuilder external; private io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceBuilder _object; private io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceBuilder pods; private io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceBuilder resource; private java.lang.String type; - + /** * This method has been deprecated, please use method buildContainerResource instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource getContainerResource() { - return this.containerResource!=null ?this.containerResource.build():null; + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource + getContainerResource() { + return this.containerResource != null ? this.containerResource.build() : null; } - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource buildContainerResource() { - return this.containerResource!=null ?this.containerResource.build():null; + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource + buildContainerResource() { + return this.containerResource != null ? this.containerResource.build() : null; } - public A withContainerResource(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource containerResource) { + + public A withContainerResource( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource containerResource) { _visitables.get("containerResource").remove(this.containerResource); - if (containerResource!=null){ this.containerResource= new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceBuilder(containerResource); _visitables.get("containerResource").add(this.containerResource);} return (A) this; + if (containerResource != null) { + this.containerResource = + new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceBuilder( + containerResource); + _visitables.get("containerResource").add(this.containerResource); + } + return (A) this; } + public java.lang.Boolean hasContainerResource() { return this.containerResource != null; } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested withNewContainerResource() { - return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl.ContainerResourceNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested + withNewContainerResource() { + return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl + .ContainerResourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested withNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource item) { - return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl.ContainerResourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested + withNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource item) { + return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl + .ContainerResourceNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested editContainerResource() { + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested + editContainerResource() { return withNewContainerResourceLike(getContainerResource()); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested editOrNewContainerResource() { - return withNewContainerResourceLike(getContainerResource() != null ? getContainerResource(): new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested + editOrNewContainerResource() { + return withNewContainerResourceLike( + getContainerResource() != null + ? getContainerResource() + : new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested editOrNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource item) { - return withNewContainerResourceLike(getContainerResource() != null ? getContainerResource(): item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested + editOrNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource item) { + return withNewContainerResourceLike( + getContainerResource() != null ? getContainerResource() : item); } - + /** * This method has been deprecated, please use method buildExternal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource getExternal() { - return this.external!=null ?this.external.build():null; + return this.external != null ? this.external.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource buildExternal() { - return this.external!=null ?this.external.build():null; + return this.external != null ? this.external.build() : null; } + public A withExternal(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource external) { _visitables.get("external").remove(this.external); - if (external!=null){ this.external= new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceBuilder(external); _visitables.get("external").add(this.external);} return (A) this; + if (external != null) { + this.external = + new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceBuilder(external); + _visitables.get("external").add(this.external); + } + return (A) this; } + public java.lang.Boolean hasExternal() { return this.external != null; } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested withNewExternal() { + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested + withNewExternal() { return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl.ExternalNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested withNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource item) { - return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl.ExternalNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested + withNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource item) { + return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl.ExternalNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested editExternal() { + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested + editExternal() { return withNewExternalLike(getExternal()); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested editOrNewExternal() { - return withNewExternalLike(getExternal() != null ? getExternal(): new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested + editOrNewExternal() { + return withNewExternalLike( + getExternal() != null + ? getExternal() + : new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource item) { - return withNewExternalLike(getExternal() != null ? getExternal(): item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested + editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource item) { + return withNewExternalLike(getExternal() != null ? getExternal() : item); } - + /** * This method has been deprecated, please use method buildObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource getObject() { - return this._object!=null ?this._object.build():null; + return this._object != null ? this._object.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource buildObject() { - return this._object!=null ?this._object.build():null; + return this._object != null ? this._object.build() : null; } + public A withObject(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource _object) { _visitables.get("_object").remove(this._object); - if (_object!=null){ this._object= new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceBuilder(_object); _visitables.get("_object").add(this._object);} return (A) this; + if (_object != null) { + this._object = + new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceBuilder(_object); + _visitables.get("_object").add(this._object); + } + return (A) this; } + public java.lang.Boolean hasObject() { return this._object != null; } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested withNewObject() { + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested + withNewObject() { return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl.ObjectNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested withNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource item) { - return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl.ObjectNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested + withNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource item) { + return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl.ObjectNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested editObject() { return withNewObjectLike(getObject()); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested editOrNewObject() { - return withNewObjectLike(getObject() != null ? getObject(): new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested + editOrNewObject() { + return withNewObjectLike( + getObject() != null + ? getObject() + : new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource item) { - return withNewObjectLike(getObject() != null ? getObject(): item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested + editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource item) { + return withNewObjectLike(getObject() != null ? getObject() : item); } - + /** * This method has been deprecated, please use method buildPods instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2PodsMetricSource getPods() { - return this.pods!=null ?this.pods.build():null; + return this.pods != null ? this.pods.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSource buildPods() { - return this.pods!=null ?this.pods.build():null; + return this.pods != null ? this.pods.build() : null; } + public A withPods(io.kubernetes.client.openapi.models.V2beta2PodsMetricSource pods) { _visitables.get("pods").remove(this.pods); - if (pods!=null){ this.pods= new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceBuilder(pods); _visitables.get("pods").add(this.pods);} return (A) this; + if (pods != null) { + this.pods = new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceBuilder(pods); + _visitables.get("pods").add(this.pods); + } + return (A) this; } + public java.lang.Boolean hasPods() { return this.pods != null; } + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested withNewPods() { return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl.PodsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested withNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricSource item) { + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested withNewPodsLike( + io.kubernetes.client.openapi.models.V2beta2PodsMetricSource item) { return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl.PodsNestedImpl(item); } + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested editPods() { return withNewPodsLike(getPods()); } + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested editOrNewPods() { - return withNewPodsLike(getPods() != null ? getPods(): new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceBuilder().build()); + return withNewPodsLike( + getPods() != null + ? getPods() + : new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricSource item) { - return withNewPodsLike(getPods() != null ? getPods(): item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested + editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricSource item) { + return withNewPodsLike(getPods() != null ? getPods() : item); } - + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource getResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource buildResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public A withResource(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource resource) { _visitables.get("resource").remove(this.resource); - if (resource!=null){ this.resource= new io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceBuilder(resource); _visitables.get("resource").add(this.resource);} return (A) this; + if (resource != null) { + this.resource = + new io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceBuilder(resource); + _visitables.get("resource").add(this.resource); + } + return (A) this; } + public java.lang.Boolean hasResource() { return this.resource != null; } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested withNewResource() { + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested + withNewResource() { return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl.ResourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource item) { - return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl.ResourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource item) { + return new io.kubernetes.client.openapi.models.V2beta2MetricSpecFluentImpl.ResourceNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested editResource() { + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested + editResource() { return withNewResourceLike(getResource()); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested editOrNewResource() { - return withNewResourceLike(getResource() != null ? getResource(): new io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested + editOrNewResource() { + return withNewResourceLike( + getResource() != null + ? getResource() + : new io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource item) { - return withNewResourceLike(getResource() != null ? getResource(): item); + + public io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource item) { + return withNewResourceLike(getResource() != null ? getResource() : item); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2MetricSpecFluentImpl that = (V2beta2MetricSpecFluentImpl) o; - if (containerResource != null ? !containerResource.equals(that.containerResource) :that.containerResource != null) return false; - if (external != null ? !external.equals(that.external) :that.external != null) return false; - if (_object != null ? !_object.equals(that._object) :that._object != null) return false; - if (pods != null ? !pods.equals(that.pods) :that.pods != null) return false; - if (resource != null ? !resource.equals(that.resource) :that.resource != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (containerResource != null + ? !containerResource.equals(that.containerResource) + : that.containerResource != null) return false; + if (external != null ? !external.equals(that.external) : that.external != null) return false; + if (_object != null ? !_object.equals(that._object) : that._object != null) return false; + if (pods != null ? !pods.equals(that.pods) : that.pods != null) return false; + if (resource != null ? !resource.equals(that.resource) : that.resource != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(containerResource, external, _object, pods, resource, type, super.hashCode()); + return java.util.Objects.hash( + containerResource, external, _object, pods, resource, type, super.hashCode()); } - public class ContainerResourceNestedImpl extends io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested,io.kubernetes.client.fluent.Nested{ - ContainerResourceNestedImpl(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceBuilder(this, item); + + public class ContainerResourceNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ContainerResourceNested> + implements io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent + .ContainerResourceNested< + N>, + io.kubernetes.client.fluent.Nested { + ContainerResourceNestedImpl( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSource item) { + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceBuilder( + this, item); } + ContainerResourceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricSourceBuilder builder; + public N and() { return (N) V2beta2MetricSpecFluentImpl.this.withContainerResource(builder.build()); } + public N endContainerResource() { return and(); } - } - public class ExternalNestedImpl extends io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested,io.kubernetes.client.fluent.Nested{ + + public class ExternalNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested> + implements io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ExternalNested, + io.kubernetes.client.fluent.Nested { ExternalNestedImpl(io.kubernetes.client.openapi.models.V2beta2ExternalMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceBuilder(this, item); } + ExternalNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2ExternalMetricSourceBuilder builder; + public N and() { return (N) V2beta2MetricSpecFluentImpl.this.withExternal(builder.build()); } + public N endExternal() { return and(); } - } - public class ObjectNestedImpl extends io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested,io.kubernetes.client.fluent.Nested{ + + public class ObjectNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested> + implements io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ObjectNested, + io.kubernetes.client.fluent.Nested { ObjectNestedImpl(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceBuilder(this, item); } + ObjectNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceBuilder builder; + public N and() { return (N) V2beta2MetricSpecFluentImpl.this.withObject(builder.build()); } + public N endObject() { return and(); } - } - public class PodsNestedImpl extends io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested,io.kubernetes.client.fluent.Nested{ + + public class PodsNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested> + implements io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.PodsNested, + io.kubernetes.client.fluent.Nested { PodsNestedImpl(io.kubernetes.client.openapi.models.V2beta2PodsMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceBuilder(this, item); } + PodsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceBuilder builder; + public N and() { return (N) V2beta2MetricSpecFluentImpl.this.withPods(builder.build()); } + public N endPods() { return and(); } - } - public class ResourceNestedImpl extends io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested,io.kubernetes.client.fluent.Nested{ + + public class ResourceNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested> + implements io.kubernetes.client.openapi.models.V2beta2MetricSpecFluent.ResourceNested, + io.kubernetes.client.fluent.Nested { ResourceNestedImpl(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceBuilder(this, item); } + ResourceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceBuilder builder; + public N and() { return (N) V2beta2MetricSpecFluentImpl.this.withResource(builder.build()); } + public N endResource() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricStatusBuilder.java index 5144d8b589..bd8f39ef9b 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricStatusBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2MetricStatusBuilder extends io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2MetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2MetricStatus, + io.kubernetes.client.openapi.models.V2beta2MetricStatusBuilder> { public V2beta2MetricStatusBuilder() { this(false); } + public V2beta2MetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2MetricStatus(), validationEnabled); } - public V2beta2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent fluent) { + + public V2beta2MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent fluent) { this(fluent, false); } - public V2beta2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2MetricStatus(), validationEnabled); } - public V2beta2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2MetricStatus instance) { + + public V2beta2MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2MetricStatus instance) { this(fluent, instance, false); } - public V2beta2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2MetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2MetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withContainerResource(instance.getContainerResource()); fluent.withExternal(instance.getExternal()); @@ -33,13 +60,18 @@ public V2beta2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2Met fluent.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2MetricStatus instance) { - this(instance,false); + + public V2beta2MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricStatus instance) { + this(instance, false); } - public V2beta2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2MetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2MetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withContainerResource(instance.getContainerResource()); this.withExternal(instance.getExternal()); @@ -52,10 +84,12 @@ public V2beta2MetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2Met this.withType(instance.getType()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2MetricStatus build() { V2beta2MetricStatus buildable = new V2beta2MetricStatus(); buildable.setContainerResource(fluent.getContainerResource()); @@ -66,18 +100,23 @@ public io.kubernetes.client.openapi.models.V2beta2MetricStatus build() { buildable.setType(fluent.getType()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2MetricStatusBuilder that = (V2beta2MetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricStatusFluent.java index 66006f7c94..31bdb21285 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricStatusFluent.java @@ -1,124 +1,222 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; -import io.kubernetes.client.fluent.Fluent; - - /** - * Generated - */ -public interface V2beta2MetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2beta2MetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildContainerResource instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus getContainerResource(); - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus buildContainerResource(); - public A withContainerResource(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus containerResource); + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus + getContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus + buildContainerResource(); + + public A withContainerResource( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus containerResource); + public java.lang.Boolean hasContainerResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested withNewContainerResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested withNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus item); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested editContainerResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested editOrNewContainerResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested editOrNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus item); - + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested + withNewContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested + withNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested + editContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested + editOrNewContainerResource(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested + editOrNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus item); + /** * This method has been deprecated, please use method buildExternal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus getExternal(); + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus buildExternal(); + public A withExternal(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus external); + public java.lang.Boolean hasExternal(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested withNewExternal(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested withNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus item); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested editExternal(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested editOrNewExternal(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus item); - + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested + withNewExternal(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested + withNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested + editExternal(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested + editOrNewExternal(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested + editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus item); + /** * This method has been deprecated, please use method buildObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus getObject(); + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus buildObject(); + public A withObject(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus _object); + public java.lang.Boolean hasObject(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested withNewObject(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested withNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested + withNewObject(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested + withNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus item); + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested editObject(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested editOrNewObject(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus item); - + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested + editOrNewObject(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested + editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus item); + /** * This method has been deprecated, please use method buildPods instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus getPods(); + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus buildPods(); + public A withPods(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus pods); + public java.lang.Boolean hasPods(); + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested withNewPods(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested withNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested + withNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus item); + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested editPods(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested editOrNewPods(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus item); - + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested + editOrNewPods(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested + editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus item); + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus getResource(); + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus buildResource(); + public A withResource(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus resource); + public java.lang.Boolean hasResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested withNewResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus item); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested editResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested editOrNewResource(); - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested + withNewResource(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested + editResource(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested + editOrNewResource(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus item); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); - public interface ContainerResourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent>{ + + public interface ContainerResourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluent< + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested< + N>> { public N and(); + public N endContainerResource(); - } - public interface ExternalNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent>{ + + public interface ExternalNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluent< + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested> { public N and(); + public N endExternal(); - } - public interface ObjectNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent>{ + + public interface ObjectNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent< + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested> { public N and(); + public N endObject(); - } - public interface PodsNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent>{ + + public interface PodsNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent< + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested> { public N and(); + public N endPods(); - } - public interface ResourceNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent>{ + + public interface ResourceNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent< + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested> { public N and(); + public N endResource(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricStatusFluentImpl.java index 60566175b1..7084669da3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricStatusFluentImpl.java @@ -1,19 +1,26 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Boolean; -import java.lang.Object; +/** Generated */ +public class V2beta2MetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent { + public V2beta2MetricStatusFluentImpl() {} - /** - * Generated - */ -public class V2beta2MetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent{ - public V2beta2MetricStatusFluentImpl() { - } - public V2beta2MetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta2MetricStatus instance) { + public V2beta2MetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta2MetricStatus instance) { this.withContainerResource(instance.getContainerResource()); this.withExternal(instance.getExternal()); @@ -25,295 +32,477 @@ public V2beta2MetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta2 this.withResource(instance.getResource()); this.withType(instance.getType()); - } - private io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusBuilder containerResource; + + private io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusBuilder + containerResource; private io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusBuilder external; private io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusBuilder _object; private io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusBuilder pods; private io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusBuilder resource; private java.lang.String type; - + /** * This method has been deprecated, please use method buildContainerResource instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus getContainerResource() { - return this.containerResource!=null ?this.containerResource.build():null; + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus + getContainerResource() { + return this.containerResource != null ? this.containerResource.build() : null; } - public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus buildContainerResource() { - return this.containerResource!=null ?this.containerResource.build():null; + + public io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus + buildContainerResource() { + return this.containerResource != null ? this.containerResource.build() : null; } - public A withContainerResource(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus containerResource) { + + public A withContainerResource( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus containerResource) { _visitables.get("containerResource").remove(this.containerResource); - if (containerResource!=null){ this.containerResource= new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusBuilder(containerResource); _visitables.get("containerResource").add(this.containerResource);} return (A) this; + if (containerResource != null) { + this.containerResource = + new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusBuilder( + containerResource); + _visitables.get("containerResource").add(this.containerResource); + } + return (A) this; } + public java.lang.Boolean hasContainerResource() { return this.containerResource != null; } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested withNewContainerResource() { - return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.ContainerResourceNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested + withNewContainerResource() { + return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl + .ContainerResourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested withNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.ContainerResourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested + withNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl + .ContainerResourceNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested editContainerResource() { + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested + editContainerResource() { return withNewContainerResourceLike(getContainerResource()); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested editOrNewContainerResource() { - return withNewContainerResourceLike(getContainerResource() != null ? getContainerResource(): new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested + editOrNewContainerResource() { + return withNewContainerResourceLike( + getContainerResource() != null + ? getContainerResource() + : new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested editOrNewContainerResourceLike(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus item) { - return withNewContainerResourceLike(getContainerResource() != null ? getContainerResource(): item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested + editOrNewContainerResourceLike( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus item) { + return withNewContainerResourceLike( + getContainerResource() != null ? getContainerResource() : item); } - + /** * This method has been deprecated, please use method buildExternal instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus getExternal() { - return this.external!=null ?this.external.build():null; + return this.external != null ? this.external.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus buildExternal() { - return this.external!=null ?this.external.build():null; + return this.external != null ? this.external.build() : null; } + public A withExternal(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus external) { _visitables.get("external").remove(this.external); - if (external!=null){ this.external= new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusBuilder(external); _visitables.get("external").add(this.external);} return (A) this; + if (external != null) { + this.external = + new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusBuilder(external); + _visitables.get("external").add(this.external); + } + return (A) this; } + public java.lang.Boolean hasExternal() { return this.external != null; } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested withNewExternal() { - return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.ExternalNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested + withNewExternal() { + return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl + .ExternalNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested withNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.ExternalNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested + withNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.ExternalNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested editExternal() { + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested + editExternal() { return withNewExternalLike(getExternal()); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested editOrNewExternal() { - return withNewExternalLike(getExternal() != null ? getExternal(): new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested + editOrNewExternal() { + return withNewExternalLike( + getExternal() != null + ? getExternal() + : new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus item) { - return withNewExternalLike(getExternal() != null ? getExternal(): item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested + editOrNewExternalLike(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus item) { + return withNewExternalLike(getExternal() != null ? getExternal() : item); } - + /** * This method has been deprecated, please use method buildObject instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus getObject() { - return this._object!=null ?this._object.build():null; + return this._object != null ? this._object.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus buildObject() { - return this._object!=null ?this._object.build():null; + return this._object != null ? this._object.build() : null; } + public A withObject(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus _object) { _visitables.get("_object").remove(this._object); - if (_object!=null){ this._object= new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusBuilder(_object); _visitables.get("_object").add(this._object);} return (A) this; + if (_object != null) { + this._object = + new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusBuilder(_object); + _visitables.get("_object").add(this._object); + } + return (A) this; } + public java.lang.Boolean hasObject() { return this._object != null; } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested withNewObject() { + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested + withNewObject() { return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.ObjectNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested withNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.ObjectNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested + withNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.ObjectNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested editObject() { + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested + editObject() { return withNewObjectLike(getObject()); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested editOrNewObject() { - return withNewObjectLike(getObject() != null ? getObject(): new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested + editOrNewObject() { + return withNewObjectLike( + getObject() != null + ? getObject() + : new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus item) { - return withNewObjectLike(getObject() != null ? getObject(): item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested + editOrNewObjectLike(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus item) { + return withNewObjectLike(getObject() != null ? getObject() : item); } - + /** * This method has been deprecated, please use method buildPods instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus getPods() { - return this.pods!=null ?this.pods.build():null; + return this.pods != null ? this.pods.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus buildPods() { - return this.pods!=null ?this.pods.build():null; + return this.pods != null ? this.pods.build() : null; } + public A withPods(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus pods) { _visitables.get("pods").remove(this.pods); - if (pods!=null){ this.pods= new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusBuilder(pods); _visitables.get("pods").add(this.pods);} return (A) this; + if (pods != null) { + this.pods = new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusBuilder(pods); + _visitables.get("pods").add(this.pods); + } + return (A) this; } + public java.lang.Boolean hasPods() { return this.pods != null; } + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested withNewPods() { return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.PodsNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested withNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.PodsNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested + withNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.PodsNestedImpl( + item); } + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested editPods() { return withNewPodsLike(getPods()); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested editOrNewPods() { - return withNewPodsLike(getPods() != null ? getPods(): new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested + editOrNewPods() { + return withNewPodsLike( + getPods() != null + ? getPods() + : new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus item) { - return withNewPodsLike(getPods() != null ? getPods(): item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested + editOrNewPodsLike(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus item) { + return withNewPodsLike(getPods() != null ? getPods() : item); } - + /** * This method has been deprecated, please use method buildResource instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus getResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus buildResource() { - return this.resource!=null ?this.resource.build():null; + return this.resource != null ? this.resource.build() : null; } + public A withResource(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus resource) { _visitables.get("resource").remove(this.resource); - if (resource!=null){ this.resource= new io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusBuilder(resource); _visitables.get("resource").add(this.resource);} return (A) this; + if (resource != null) { + this.resource = + new io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusBuilder(resource); + _visitables.get("resource").add(this.resource); + } + return (A) this; } + public java.lang.Boolean hasResource() { return this.resource != null; } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested withNewResource() { - return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.ResourceNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested + withNewResource() { + return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl + .ResourceNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested withNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus item) { - return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.ResourceNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested + withNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus item) { + return new io.kubernetes.client.openapi.models.V2beta2MetricStatusFluentImpl.ResourceNestedImpl( + item); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested editResource() { + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested + editResource() { return withNewResourceLike(getResource()); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested editOrNewResource() { - return withNewResourceLike(getResource() != null ? getResource(): new io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested + editOrNewResource() { + return withNewResourceLike( + getResource() != null + ? getResource() + : new io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus item) { - return withNewResourceLike(getResource() != null ? getResource(): item); + + public io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested + editOrNewResourceLike(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus item) { + return withNewResourceLike(getResource() != null ? getResource() : item); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2MetricStatusFluentImpl that = (V2beta2MetricStatusFluentImpl) o; - if (containerResource != null ? !containerResource.equals(that.containerResource) :that.containerResource != null) return false; - if (external != null ? !external.equals(that.external) :that.external != null) return false; - if (_object != null ? !_object.equals(that._object) :that._object != null) return false; - if (pods != null ? !pods.equals(that.pods) :that.pods != null) return false; - if (resource != null ? !resource.equals(that.resource) :that.resource != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; + if (containerResource != null + ? !containerResource.equals(that.containerResource) + : that.containerResource != null) return false; + if (external != null ? !external.equals(that.external) : that.external != null) return false; + if (_object != null ? !_object.equals(that._object) : that._object != null) return false; + if (pods != null ? !pods.equals(that.pods) : that.pods != null) return false; + if (resource != null ? !resource.equals(that.resource) : that.resource != null) return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(containerResource, external, _object, pods, resource, type, super.hashCode()); + return java.util.Objects.hash( + containerResource, external, _object, pods, resource, type, super.hashCode()); } - public class ContainerResourceNestedImpl extends io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested,io.kubernetes.client.fluent.Nested{ - ContainerResourceNestedImpl(io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusBuilder(this, item); + + public class ContainerResourceNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ContainerResourceNested> + implements io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent + .ContainerResourceNested< + N>, + io.kubernetes.client.fluent.Nested { + ContainerResourceNestedImpl( + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatus item) { + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusBuilder( + this, item); } + ContainerResourceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2ContainerResourceMetricStatusBuilder builder; + public N and() { return (N) V2beta2MetricStatusFluentImpl.this.withContainerResource(builder.build()); } + public N endContainerResource() { return and(); } - } - public class ExternalNestedImpl extends io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested,io.kubernetes.client.fluent.Nested{ + + public class ExternalNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested> + implements io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ExternalNested, + io.kubernetes.client.fluent.Nested { ExternalNestedImpl(io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusBuilder(this, item); } + ExternalNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2ExternalMetricStatusBuilder builder; + public N and() { return (N) V2beta2MetricStatusFluentImpl.this.withExternal(builder.build()); } + public N endExternal() { return and(); } - } - public class ObjectNestedImpl extends io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested,io.kubernetes.client.fluent.Nested{ + + public class ObjectNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested> + implements io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ObjectNested, + io.kubernetes.client.fluent.Nested { ObjectNestedImpl(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusBuilder(this, item); } + ObjectNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusBuilder builder; + public N and() { return (N) V2beta2MetricStatusFluentImpl.this.withObject(builder.build()); } + public N endObject() { return and(); } - } - public class PodsNestedImpl extends io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested,io.kubernetes.client.fluent.Nested{ + + public class PodsNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested> + implements io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.PodsNested, + io.kubernetes.client.fluent.Nested { PodsNestedImpl(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusBuilder(this, item); } + PodsNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusBuilder builder; + public N and() { return (N) V2beta2MetricStatusFluentImpl.this.withPods(builder.build()); } + public N endPods() { return and(); } - } - public class ResourceNestedImpl extends io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested,io.kubernetes.client.fluent.Nested{ + + public class ResourceNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested> + implements io.kubernetes.client.openapi.models.V2beta2MetricStatusFluent.ResourceNested, + io.kubernetes.client.fluent.Nested { ResourceNestedImpl(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusBuilder(this, item); } + ResourceNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusBuilder builder; + public N and() { return (N) V2beta2MetricStatusFluentImpl.this.withResource(builder.build()); } + public N endResource() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricTargetBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricTargetBuilder.java index 2f3337cc1e..1a32ad625f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricTargetBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricTargetBuilder.java @@ -1,26 +1,53 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2MetricTargetBuilder extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2MetricTargetBuilder + extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2MetricTarget, + io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder> { public V2beta2MetricTargetBuilder() { this(false); } + public V2beta2MetricTargetBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2MetricTarget(), validationEnabled); } - public V2beta2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent fluent) { + + public V2beta2MetricTargetBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent fluent) { this(fluent, false); } - public V2beta2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2MetricTargetBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2MetricTarget(), validationEnabled); } - public V2beta2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent fluent,io.kubernetes.client.openapi.models.V2beta2MetricTarget instance) { + + public V2beta2MetricTargetBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent fluent, + io.kubernetes.client.openapi.models.V2beta2MetricTarget instance) { this(fluent, instance, false); } - public V2beta2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent fluent,io.kubernetes.client.openapi.models.V2beta2MetricTarget instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2MetricTargetBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent fluent, + io.kubernetes.client.openapi.models.V2beta2MetricTarget instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAverageUtilization(instance.getAverageUtilization()); fluent.withAverageValue(instance.getAverageValue()); @@ -29,13 +56,18 @@ public V2beta2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2beta2Met fluent.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2beta2MetricTarget instance) { - this(instance,false); + + public V2beta2MetricTargetBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricTarget instance) { + this(instance, false); } - public V2beta2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2beta2MetricTarget instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2MetricTargetBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricTarget instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAverageUtilization(instance.getAverageUtilization()); this.withAverageValue(instance.getAverageValue()); @@ -44,10 +76,12 @@ public V2beta2MetricTargetBuilder(io.kubernetes.client.openapi.models.V2beta2Met this.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2MetricTarget build() { V2beta2MetricTarget buildable = new V2beta2MetricTarget(); buildable.setAverageUtilization(fluent.getAverageUtilization()); @@ -56,18 +90,23 @@ public io.kubernetes.client.openapi.models.V2beta2MetricTarget build() { buildable.setValue(fluent.getValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2MetricTargetBuilder that = (V2beta2MetricTargetBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricTargetFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricTargetFluent.java index 67e2859e2b..5cfee94b4e 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricTargetFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricTargetFluent.java @@ -1,36 +1,50 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2MetricTargetFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta2MetricTargetFluent< + A extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getAverageUtilization(); + public A withAverageUtilization(java.lang.Integer averageUtilization); + public java.lang.Boolean hasAverageUtilization(); + public io.kubernetes.client.custom.Quantity getAverageValue(); + public A withAverageValue(io.kubernetes.client.custom.Quantity averageValue); + public java.lang.Boolean hasAverageValue(); + public A withNewAverageValue(java.lang.String value); + public java.lang.String getType(); + public A withType(java.lang.String type); + public java.lang.Boolean hasType(); - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original); + public io.kubernetes.client.custom.Quantity getValue(); + public A withValue(io.kubernetes.client.custom.Quantity value); + public java.lang.Boolean hasValue(); + public A withNewValue(java.lang.String value); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricTargetFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricTargetFluentImpl.java index 4f8ff0be33..27dd8964c7 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricTargetFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricTargetFluentImpl.java @@ -1,20 +1,28 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - /** - * Generated - */ -public class V2beta2MetricTargetFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent{ - public V2beta2MetricTargetFluentImpl() { - } - public V2beta2MetricTargetFluentImpl(io.kubernetes.client.openapi.models.V2beta2MetricTarget instance) { +/** Generated */ +public class V2beta2MetricTargetFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent { + public V2beta2MetricTargetFluentImpl() {} + + public V2beta2MetricTargetFluentImpl( + io.kubernetes.client.openapi.models.V2beta2MetricTarget instance) { this.withAverageUtilization(instance.getAverageUtilization()); this.withAverageValue(instance.getAverageValue()); @@ -22,74 +30,94 @@ public V2beta2MetricTargetFluentImpl(io.kubernetes.client.openapi.models.V2beta2 this.withType(instance.getType()); this.withValue(instance.getValue()); - } + private java.lang.Integer averageUtilization; private io.kubernetes.client.custom.Quantity averageValue; private java.lang.String type; private io.kubernetes.client.custom.Quantity value; + public java.lang.Integer getAverageUtilization() { return this.averageUtilization; } + public A withAverageUtilization(java.lang.Integer averageUtilization) { - this.averageUtilization=averageUtilization; return (A) this; + this.averageUtilization = averageUtilization; + return (A) this; } + public java.lang.Boolean hasAverageUtilization() { return this.averageUtilization != null; } + public io.kubernetes.client.custom.Quantity getAverageValue() { return this.averageValue; } + public A withAverageValue(io.kubernetes.client.custom.Quantity averageValue) { - this.averageValue=averageValue; return (A) this; + this.averageValue = averageValue; + return (A) this; } + public java.lang.Boolean hasAverageValue() { return this.averageValue != null; } + public A withNewAverageValue(java.lang.String value) { - return (A)withAverageValue(new Quantity(value)); + return (A) withAverageValue(new Quantity(value)); } + public java.lang.String getType() { return this.type; } + public A withType(java.lang.String type) { - this.type=type; return (A) this; + this.type = type; + return (A) this; } + public java.lang.Boolean hasType() { return this.type != null; } - - /** - * Method is deprecated. use withType instead. - */ + + /** Method is deprecated. use withType instead. */ @java.lang.Deprecated public A withNewType(java.lang.String original) { - return (A)withType(new String(original)); + return (A) withType(new String(original)); } + public io.kubernetes.client.custom.Quantity getValue() { return this.value; } + public A withValue(io.kubernetes.client.custom.Quantity value) { - this.value=value; return (A) this; + this.value = value; + return (A) this; } + public java.lang.Boolean hasValue() { return this.value != null; } + public A withNewValue(java.lang.String value) { - return (A)withValue(new Quantity(value)); + return (A) withValue(new Quantity(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2MetricTargetFluentImpl that = (V2beta2MetricTargetFluentImpl) o; - if (averageUtilization != null ? !averageUtilization.equals(that.averageUtilization) :that.averageUtilization != null) return false; - if (averageValue != null ? !averageValue.equals(that.averageValue) :that.averageValue != null) return false; - if (type != null ? !type.equals(that.type) :that.type != null) return false; - if (value != null ? !value.equals(that.value) :that.value != null) return false; + if (averageUtilization != null + ? !averageUtilization.equals(that.averageUtilization) + : that.averageUtilization != null) return false; + if (averageValue != null ? !averageValue.equals(that.averageValue) : that.averageValue != null) + return false; + if (type != null ? !type.equals(that.type) : that.type != null) return false; + if (value != null ? !value.equals(that.value) : that.value != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(averageUtilization, averageValue, type, value, super.hashCode()); + return java.util.Objects.hash(averageUtilization, averageValue, type, value, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricValueStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricValueStatusBuilder.java index e761149c0e..b7957a8839 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricValueStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricValueStatusBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2MetricValueStatusBuilder extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2MetricValueStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2MetricValueStatus, + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder> { public V2beta2MetricValueStatusBuilder() { this(false); } + public V2beta2MetricValueStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2MetricValueStatus(), validationEnabled); } - public V2beta2MetricValueStatusBuilder(io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent fluent) { + + public V2beta2MetricValueStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent fluent) { this(fluent, false); } - public V2beta2MetricValueStatusBuilder(io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2MetricValueStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2MetricValueStatus(), validationEnabled); } - public V2beta2MetricValueStatusBuilder(io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2MetricValueStatus instance) { + + public V2beta2MetricValueStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2MetricValueStatus instance) { this(fluent, instance, false); } - public V2beta2MetricValueStatusBuilder(io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2MetricValueStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2MetricValueStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2MetricValueStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withAverageUtilization(instance.getAverageUtilization()); fluent.withAverageValue(instance.getAverageValue()); fluent.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2MetricValueStatusBuilder(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus instance) { - this(instance,false); + + public V2beta2MetricValueStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricValueStatus instance) { + this(instance, false); } - public V2beta2MetricValueStatusBuilder(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2MetricValueStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2MetricValueStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withAverageUtilization(instance.getAverageUtilization()); this.withAverageValue(instance.getAverageValue()); this.withValue(instance.getValue()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus build() { V2beta2MetricValueStatus buildable = new V2beta2MetricValueStatus(); buildable.setAverageUtilization(fluent.getAverageUtilization()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus build() { buildable.setValue(fluent.getValue()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2MetricValueStatusBuilder that = (V2beta2MetricValueStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricValueStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricValueStatusFluent.java index ab179bb639..b06d695050 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricValueStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricValueStatusFluent.java @@ -1,26 +1,40 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.custom.Quantity; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2MetricValueStatusFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta2MetricValueStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.Integer getAverageUtilization(); + public A withAverageUtilization(java.lang.Integer averageUtilization); + public java.lang.Boolean hasAverageUtilization(); + public io.kubernetes.client.custom.Quantity getAverageValue(); + public A withAverageValue(io.kubernetes.client.custom.Quantity averageValue); + public java.lang.Boolean hasAverageValue(); + public A withNewAverageValue(java.lang.String value); + public io.kubernetes.client.custom.Quantity getValue(); + public A withValue(io.kubernetes.client.custom.Quantity value); + public java.lang.Boolean hasValue(); + public A withNewValue(java.lang.String value); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricValueStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricValueStatusFluentImpl.java index 0ffb0a835b..47080dcf71 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricValueStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2MetricValueStatusFluentImpl.java @@ -1,73 +1,100 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Integer; -import io.kubernetes.client.fluent.BaseFluent; import io.kubernetes.client.custom.Quantity; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public class V2beta2MetricValueStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent{ - public V2beta2MetricValueStatusFluentImpl() { - } - public V2beta2MetricValueStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus instance) { + +/** Generated */ +public class V2beta2MetricValueStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent { + public V2beta2MetricValueStatusFluentImpl() {} + + public V2beta2MetricValueStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta2MetricValueStatus instance) { this.withAverageUtilization(instance.getAverageUtilization()); this.withAverageValue(instance.getAverageValue()); this.withValue(instance.getValue()); - } + private java.lang.Integer averageUtilization; private io.kubernetes.client.custom.Quantity averageValue; private io.kubernetes.client.custom.Quantity value; + public java.lang.Integer getAverageUtilization() { return this.averageUtilization; } + public A withAverageUtilization(java.lang.Integer averageUtilization) { - this.averageUtilization=averageUtilization; return (A) this; + this.averageUtilization = averageUtilization; + return (A) this; } + public java.lang.Boolean hasAverageUtilization() { return this.averageUtilization != null; } + public io.kubernetes.client.custom.Quantity getAverageValue() { return this.averageValue; } + public A withAverageValue(io.kubernetes.client.custom.Quantity averageValue) { - this.averageValue=averageValue; return (A) this; + this.averageValue = averageValue; + return (A) this; } + public java.lang.Boolean hasAverageValue() { return this.averageValue != null; } + public A withNewAverageValue(java.lang.String value) { - return (A)withAverageValue(new Quantity(value)); + return (A) withAverageValue(new Quantity(value)); } + public io.kubernetes.client.custom.Quantity getValue() { return this.value; } + public A withValue(io.kubernetes.client.custom.Quantity value) { - this.value=value; return (A) this; + this.value = value; + return (A) this; } + public java.lang.Boolean hasValue() { return this.value != null; } + public A withNewValue(java.lang.String value) { - return (A)withValue(new Quantity(value)); + return (A) withValue(new Quantity(value)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2MetricValueStatusFluentImpl that = (V2beta2MetricValueStatusFluentImpl) o; - if (averageUtilization != null ? !averageUtilization.equals(that.averageUtilization) :that.averageUtilization != null) return false; - if (averageValue != null ? !averageValue.equals(that.averageValue) :that.averageValue != null) return false; - if (value != null ? !value.equals(that.value) :that.value != null) return false; + if (averageUtilization != null + ? !averageUtilization.equals(that.averageUtilization) + : that.averageUtilization != null) return false; + if (averageValue != null ? !averageValue.equals(that.averageValue) : that.averageValue != null) + return false; + if (value != null ? !value.equals(that.value) : that.value != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(averageUtilization, averageValue, value, super.hashCode()); + return java.util.Objects.hash(averageUtilization, averageValue, value, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricSourceBuilder.java index 2a0a435742..ff10f2780a 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricSourceBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2ObjectMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2ObjectMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource, + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceBuilder> { public V2beta2ObjectMetricSourceBuilder() { this(false); } + public V2beta2ObjectMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2ObjectMetricSource(), validationEnabled); } - public V2beta2ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent fluent) { + + public V2beta2ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent fluent) { this(fluent, false); } - public V2beta2ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2ObjectMetricSource(), validationEnabled); } - public V2beta2ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource instance) { + + public V2beta2ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource instance) { this(fluent, instance, false); } - public V2beta2ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withDescribedObject(instance.getDescribedObject()); fluent.withMetric(instance.getMetric()); fluent.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource instance) { - this(instance,false); + + public V2beta2ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource instance) { + this(instance, false); } - public V2beta2ObjectMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2ObjectMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withDescribedObject(instance.getDescribedObject()); this.withMetric(instance.getMetric()); this.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource build() { V2beta2ObjectMetricSource buildable = new V2beta2ObjectMetricSource(); buildable.setDescribedObject(fluent.getDescribedObject()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource build() { buildable.setTarget(fluent.getTarget()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2ObjectMetricSourceBuilder that = (V2beta2ObjectMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricSourceFluent.java index c14aa2c88e..a65e99d5a9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricSourceFluent.java @@ -1,75 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2ObjectMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2beta2ObjectMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildDescribedObject instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference getDescribedObject(); - public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference buildDescribedObject(); - public A withDescribedObject(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference describedObject); + public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference + getDescribedObject(); + + public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference + buildDescribedObject(); + + public A withDescribedObject( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference describedObject); + public java.lang.Boolean hasDescribedObject(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested withNewDescribedObject(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested withNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested editDescribedObject(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested editOrNewDescribedObject(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested editOrNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item); - + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested< + A> + withNewDescribedObject(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested< + A> + withNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested< + A> + editDescribedObject(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested< + A> + editOrNewDescribedObject(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested< + A> + editOrNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item); + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier getMetric(); + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier buildMetric(); + public A withMetric(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier metric); + public java.lang.Boolean hasMetric(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested withNewMetric(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested editMetric(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested editOrNewMetric(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); - + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested + withNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested + editMetric(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested + editOrNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricTarget getTarget(); + public io.kubernetes.client.openapi.models.V2beta2MetricTarget buildTarget(); + public A withTarget(io.kubernetes.client.openapi.models.V2beta2MetricTarget target); + public java.lang.Boolean hasTarget(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested withNewTarget(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested editTarget(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested editOrNewTarget(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); - public interface DescribedObjectNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent>{ + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested + withNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested + editTarget(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested + editOrNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); + + public interface DescribedObjectNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent + .DescribedObjectNested< + N>> { public N and(); + public N endDescribedObject(); - } - public interface MetricNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent>{ + + public interface MetricNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested> { public N and(); + public N endMetric(); - } - public interface TargetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent>{ + + public interface TargetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested> { public N and(); + public N endTarget(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricSourceFluentImpl.java index 2814252c20..a9bbe764db 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricSourceFluentImpl.java @@ -1,189 +1,317 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta2ObjectMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent { + public V2beta2ObjectMetricSourceFluentImpl() {} - /** - * Generated - */ -public class V2beta2ObjectMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent{ - public V2beta2ObjectMetricSourceFluentImpl() { - } - public V2beta2ObjectMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource instance) { + public V2beta2ObjectMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSource instance) { this.withDescribedObject(instance.getDescribedObject()); this.withMetric(instance.getMetric()); this.withTarget(instance.getTarget()); - } - private io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder describedObject; + + private io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder + describedObject; private io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder metric; private io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder target; - + /** * This method has been deprecated, please use method buildDescribedObject instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference getDescribedObject() { - return this.describedObject!=null ?this.describedObject.build():null; + public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference + getDescribedObject() { + return this.describedObject != null ? this.describedObject.build() : null; } - public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference buildDescribedObject() { - return this.describedObject!=null ?this.describedObject.build():null; + + public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference + buildDescribedObject() { + return this.describedObject != null ? this.describedObject.build() : null; } - public A withDescribedObject(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference describedObject) { + + public A withDescribedObject( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference describedObject) { _visitables.get("describedObject").remove(this.describedObject); - if (describedObject!=null){ this.describedObject= new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder(describedObject); _visitables.get("describedObject").add(this.describedObject);} return (A) this; + if (describedObject != null) { + this.describedObject = + new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder( + describedObject); + _visitables.get("describedObject").add(this.describedObject); + } + return (A) this; } + public java.lang.Boolean hasDescribedObject() { return this.describedObject != null; } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested withNewDescribedObject() { - return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl.DescribedObjectNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested< + A> + withNewDescribedObject() { + return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl + .DescribedObjectNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested withNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { - return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl.DescribedObjectNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested< + A> + withNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { + return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl + .DescribedObjectNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested editDescribedObject() { + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested< + A> + editDescribedObject() { return withNewDescribedObjectLike(getDescribedObject()); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested editOrNewDescribedObject() { - return withNewDescribedObjectLike(getDescribedObject() != null ? getDescribedObject(): new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested< + A> + editOrNewDescribedObject() { + return withNewDescribedObjectLike( + getDescribedObject() != null + ? getDescribedObject() + : new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested editOrNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { - return withNewDescribedObjectLike(getDescribedObject() != null ? getDescribedObject(): item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested< + A> + editOrNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { + return withNewDescribedObjectLike(getDescribedObject() != null ? getDescribedObject() : item); } - + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier getMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier buildMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public A withMetric(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier metric) { _visitables.get("metric").remove(this.metric); - if (metric!=null){ this.metric= new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(metric); _visitables.get("metric").add(this.metric);} return (A) this; + if (metric != null) { + this.metric = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(metric); + _visitables.get("metric").add(this.metric); + } + return (A) this; } + public java.lang.Boolean hasMetric() { return this.metric != null; } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested withNewMetric() { - return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl.MetricNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested + withNewMetric() { + return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl + .MetricNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl.MetricNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { + return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl + .MetricNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested editMetric() { + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested + editMetric() { return withNewMetricLike(getMetric()); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested editOrNewMetric() { - return withNewMetricLike(getMetric() != null ? getMetric(): new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested + editOrNewMetric() { + return withNewMetricLike( + getMetric() != null + ? getMetric() + : new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - return withNewMetricLike(getMetric() != null ? getMetric(): item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { + return withNewMetricLike(getMetric() != null ? getMetric() : item); } - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricTarget getTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricTarget buildTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public A withTarget(io.kubernetes.client.openapi.models.V2beta2MetricTarget target) { _visitables.get("target").remove(this.target); - if (target!=null){ this.target= new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(target); _visitables.get("target").add(this.target);} return (A) this; + if (target != null) { + this.target = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(target); + _visitables.get("target").add(this.target); + } + return (A) this; } + public java.lang.Boolean hasTarget() { return this.target != null; } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested withNewTarget() { - return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl.TargetNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested + withNewTarget() { + return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl + .TargetNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { - return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl.TargetNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { + return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluentImpl + .TargetNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested editTarget() { + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested + editTarget() { return withNewTargetLike(getTarget()); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested editOrNewTarget() { - return withNewTargetLike(getTarget() != null ? getTarget(): new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested + editOrNewTarget() { + return withNewTargetLike( + getTarget() != null + ? getTarget() + : new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { - return withNewTargetLike(getTarget() != null ? getTarget(): item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { + return withNewTargetLike(getTarget() != null ? getTarget() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2ObjectMetricSourceFluentImpl that = (V2beta2ObjectMetricSourceFluentImpl) o; - if (describedObject != null ? !describedObject.equals(that.describedObject) :that.describedObject != null) return false; - if (metric != null ? !metric.equals(that.metric) :that.metric != null) return false; - if (target != null ? !target.equals(that.target) :that.target != null) return false; + if (describedObject != null + ? !describedObject.equals(that.describedObject) + : that.describedObject != null) return false; + if (metric != null ? !metric.equals(that.metric) : that.metric != null) return false; + if (target != null ? !target.equals(that.target) : that.target != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(describedObject, metric, target, super.hashCode()); + return java.util.Objects.hash(describedObject, metric, target, super.hashCode()); } - public class DescribedObjectNestedImpl extends io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested,io.kubernetes.client.fluent.Nested{ - DescribedObjectNestedImpl(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder(this, item); + + public class DescribedObjectNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.DescribedObjectNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent + .DescribedObjectNested< + N>, + io.kubernetes.client.fluent.Nested { + DescribedObjectNestedImpl( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { + this.builder = + new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder( + this, item); } + DescribedObjectNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder builder; + public N and() { return (N) V2beta2ObjectMetricSourceFluentImpl.this.withDescribedObject(builder.build()); } + public N endDescribedObject() { return and(); } - } - public class MetricNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested,io.kubernetes.client.fluent.Nested{ + + public class MetricNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested> + implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.MetricNested< + N>, + io.kubernetes.client.fluent.Nested { MetricNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this, item); } + MetricNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder builder; + public N and() { return (N) V2beta2ObjectMetricSourceFluentImpl.this.withMetric(builder.build()); } + public N endMetric() { return and(); } - } - public class TargetNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested,io.kubernetes.client.fluent.Nested{ + + public class TargetNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested> + implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricSourceFluent.TargetNested< + N>, + io.kubernetes.client.fluent.Nested { TargetNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(this, item); } + TargetNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder builder; + public N and() { return (N) V2beta2ObjectMetricSourceFluentImpl.this.withTarget(builder.build()); } + public N endTarget() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricStatusBuilder.java index 9e128774a5..33f2a7f11f 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricStatusBuilder.java @@ -1,49 +1,83 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2ObjectMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2ObjectMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus, + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusBuilder> { public V2beta2ObjectMetricStatusBuilder() { this(false); } + public V2beta2ObjectMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2ObjectMetricStatus(), validationEnabled); } - public V2beta2ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent fluent) { + + public V2beta2ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent fluent) { this(fluent, false); } - public V2beta2ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2ObjectMetricStatus(), validationEnabled); } - public V2beta2ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus instance) { + + public V2beta2ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus instance) { this(fluent, instance, false); } - public V2beta2ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCurrent(instance.getCurrent()); fluent.withDescribedObject(instance.getDescribedObject()); fluent.withMetric(instance.getMetric()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus instance) { - this(instance,false); + + public V2beta2ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus instance) { + this(instance, false); } - public V2beta2ObjectMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2ObjectMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCurrent(instance.getCurrent()); this.withDescribedObject(instance.getDescribedObject()); this.withMetric(instance.getMetric()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus build() { V2beta2ObjectMetricStatus buildable = new V2beta2ObjectMetricStatus(); buildable.setCurrent(fluent.getCurrent()); @@ -51,18 +85,23 @@ public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus build() { buildable.setMetric(fluent.getMetric()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2ObjectMetricStatusBuilder that = (V2beta2ObjectMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricStatusFluent.java index c1c9391788..0ca1a1d5f4 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricStatusFluent.java @@ -1,75 +1,146 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2ObjectMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2beta2ObjectMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus getCurrent(); + public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus buildCurrent(); + public A withCurrent(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus current); + public java.lang.Boolean hasCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested withNewCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested editCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested editOrNewCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); - + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested + withNewCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested + editCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested + editOrNewCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); + /** * This method has been deprecated, please use method buildDescribedObject instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference getDescribedObject(); - public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference buildDescribedObject(); - public A withDescribedObject(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference describedObject); + public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference + getDescribedObject(); + + public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference + buildDescribedObject(); + + public A withDescribedObject( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference describedObject); + public java.lang.Boolean hasDescribedObject(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested withNewDescribedObject(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested withNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested editDescribedObject(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested editOrNewDescribedObject(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested editOrNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item); - + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested< + A> + withNewDescribedObject(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested< + A> + withNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested< + A> + editDescribedObject(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested< + A> + editOrNewDescribedObject(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested< + A> + editOrNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item); + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier getMetric(); + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier buildMetric(); + public A withMetric(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier metric); + public java.lang.Boolean hasMetric(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested withNewMetric(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested editMetric(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested editOrNewMetric(); - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); - public interface CurrentNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent>{ + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested + withNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested + editMetric(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested + editOrNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); + + public interface CurrentNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested< + N>> { public N and(); + public N endCurrent(); - } - public interface DescribedObjectNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent>{ + + public interface DescribedObjectNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluent< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent + .DescribedObjectNested< + N>> { public N and(); + public N endDescribedObject(); - } - public interface MetricNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent>{ + + public interface MetricNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested> { public N and(); + public N endMetric(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricStatusFluentImpl.java index b50b28c428..988154cd08 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ObjectMetricStatusFluentImpl.java @@ -1,189 +1,319 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta2ObjectMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent { + public V2beta2ObjectMetricStatusFluentImpl() {} - /** - * Generated - */ -public class V2beta2ObjectMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent{ - public V2beta2ObjectMetricStatusFluentImpl() { - } - public V2beta2ObjectMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus instance) { + public V2beta2ObjectMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatus instance) { this.withCurrent(instance.getCurrent()); this.withDescribedObject(instance.getDescribedObject()); this.withMetric(instance.getMetric()); - } + private io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder current; - private io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder describedObject; + private io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder + describedObject; private io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder metric; - + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus getCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus buildCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public A withCurrent(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus current) { _visitables.get("current").remove(this.current); - if (current!=null){ this.current= new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(current); _visitables.get("current").add(this.current);} return (A) this; + if (current != null) { + this.current = + new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(current); + _visitables.get("current").add(this.current); + } + return (A) this; } + public java.lang.Boolean hasCurrent() { return this.current != null; } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested withNewCurrent() { - return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl.CurrentNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested + withNewCurrent() { + return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl + .CurrentNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl.CurrentNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { + return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl + .CurrentNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested editCurrent() { + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested + editCurrent() { return withNewCurrentLike(getCurrent()); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested editOrNewCurrent() { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested + editOrNewCurrent() { + return withNewCurrentLike( + getCurrent() != null + ? getCurrent() + : new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { + return withNewCurrentLike(getCurrent() != null ? getCurrent() : item); } - + /** * This method has been deprecated, please use method buildDescribedObject instead. + * * @return The buildable object. */ @java.lang.Deprecated - public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference getDescribedObject() { - return this.describedObject!=null ?this.describedObject.build():null; + public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference + getDescribedObject() { + return this.describedObject != null ? this.describedObject.build() : null; } - public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference buildDescribedObject() { - return this.describedObject!=null ?this.describedObject.build():null; + + public io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference + buildDescribedObject() { + return this.describedObject != null ? this.describedObject.build() : null; } - public A withDescribedObject(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference describedObject) { + + public A withDescribedObject( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference describedObject) { _visitables.get("describedObject").remove(this.describedObject); - if (describedObject!=null){ this.describedObject= new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder(describedObject); _visitables.get("describedObject").add(this.describedObject);} return (A) this; + if (describedObject != null) { + this.describedObject = + new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder( + describedObject); + _visitables.get("describedObject").add(this.describedObject); + } + return (A) this; } + public java.lang.Boolean hasDescribedObject() { return this.describedObject != null; } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested withNewDescribedObject() { - return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl.DescribedObjectNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested< + A> + withNewDescribedObject() { + return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl + .DescribedObjectNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested withNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { - return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl.DescribedObjectNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested< + A> + withNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { + return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl + .DescribedObjectNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested editDescribedObject() { + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested< + A> + editDescribedObject() { return withNewDescribedObjectLike(getDescribedObject()); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested editOrNewDescribedObject() { - return withNewDescribedObjectLike(getDescribedObject() != null ? getDescribedObject(): new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested< + A> + editOrNewDescribedObject() { + return withNewDescribedObjectLike( + getDescribedObject() != null + ? getDescribedObject() + : new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder() + .build()); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested editOrNewDescribedObjectLike(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { - return withNewDescribedObjectLike(getDescribedObject() != null ? getDescribedObject(): item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested< + A> + editOrNewDescribedObjectLike( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { + return withNewDescribedObjectLike(getDescribedObject() != null ? getDescribedObject() : item); } - + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier getMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier buildMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public A withMetric(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier metric) { _visitables.get("metric").remove(this.metric); - if (metric!=null){ this.metric= new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(metric); _visitables.get("metric").add(this.metric);} return (A) this; + if (metric != null) { + this.metric = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(metric); + _visitables.get("metric").add(this.metric); + } + return (A) this; } + public java.lang.Boolean hasMetric() { return this.metric != null; } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested withNewMetric() { - return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl.MetricNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested + withNewMetric() { + return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl + .MetricNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl.MetricNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { + return new io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluentImpl + .MetricNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested editMetric() { + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested + editMetric() { return withNewMetricLike(getMetric()); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested editOrNewMetric() { - return withNewMetricLike(getMetric() != null ? getMetric(): new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested + editOrNewMetric() { + return withNewMetricLike( + getMetric() != null + ? getMetric() + : new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - return withNewMetricLike(getMetric() != null ? getMetric(): item); + + public io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { + return withNewMetricLike(getMetric() != null ? getMetric() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2ObjectMetricStatusFluentImpl that = (V2beta2ObjectMetricStatusFluentImpl) o; - if (current != null ? !current.equals(that.current) :that.current != null) return false; - if (describedObject != null ? !describedObject.equals(that.describedObject) :that.describedObject != null) return false; - if (metric != null ? !metric.equals(that.metric) :that.metric != null) return false; + if (current != null ? !current.equals(that.current) : that.current != null) return false; + if (describedObject != null + ? !describedObject.equals(that.describedObject) + : that.describedObject != null) return false; + if (metric != null ? !metric.equals(that.metric) : that.metric != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(current, describedObject, metric, super.hashCode()); + return java.util.Objects.hash(current, describedObject, metric, super.hashCode()); } - public class CurrentNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested,io.kubernetes.client.fluent.Nested{ + + public class CurrentNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested> + implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.CurrentNested< + N>, + io.kubernetes.client.fluent.Nested { CurrentNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this, item); } + CurrentNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder builder; + public N and() { return (N) V2beta2ObjectMetricStatusFluentImpl.this.withCurrent(builder.build()); } + public N endCurrent() { return and(); } - } - public class DescribedObjectNestedImpl extends io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested,io.kubernetes.client.fluent.Nested{ - DescribedObjectNestedImpl(io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder(this, item); + + public class DescribedObjectNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.DescribedObjectNested< + N>> + implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent + .DescribedObjectNested< + N>, + io.kubernetes.client.fluent.Nested { + DescribedObjectNestedImpl( + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReference item) { + this.builder = + new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder( + this, item); } + DescribedObjectNestedImpl() { - this.builder = new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder(this); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2CrossVersionObjectReferenceBuilder builder; + public N and() { return (N) V2beta2ObjectMetricStatusFluentImpl.this.withDescribedObject(builder.build()); } + public N endDescribedObject() { return and(); } - } - public class MetricNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested,io.kubernetes.client.fluent.Nested{ + + public class MetricNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested> + implements io.kubernetes.client.openapi.models.V2beta2ObjectMetricStatusFluent.MetricNested< + N>, + io.kubernetes.client.fluent.Nested { MetricNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this, item); } + MetricNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder builder; + public N and() { return (N) V2beta2ObjectMetricStatusFluentImpl.this.withMetric(builder.build()); } + public N endMetric() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricSourceBuilder.java index f8aa4f7cae..e8ff3a38f9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2PodsMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2PodsMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2PodsMetricSource, + io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceBuilder> { public V2beta2PodsMetricSourceBuilder() { this(false); } + public V2beta2PodsMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2PodsMetricSource(), validationEnabled); } - public V2beta2PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent fluent) { + + public V2beta2PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent fluent) { this(fluent, false); } - public V2beta2PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2PodsMetricSource(), validationEnabled); } - public V2beta2PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta2PodsMetricSource instance) { + + public V2beta2PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta2PodsMetricSource instance) { this(fluent, instance, false); } - public V2beta2PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta2PodsMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta2PodsMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withMetric(instance.getMetric()); fluent.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2PodsMetricSource instance) { - this(instance,false); + + public V2beta2PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2PodsMetricSource instance) { + this(instance, false); } - public V2beta2PodsMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2PodsMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2PodsMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2PodsMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withMetric(instance.getMetric()); this.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSource build() { V2beta2PodsMetricSource buildable = new V2beta2PodsMetricSource(); buildable.setMetric(fluent.getMetric()); buildable.setTarget(fluent.getTarget()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2PodsMetricSourceBuilder that = (V2beta2PodsMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricSourceFluent.java index 2cae250085..e5426945bf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricSourceFluent.java @@ -1,55 +1,95 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2PodsMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2beta2PodsMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier getMetric(); + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier buildMetric(); + public A withMetric(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier metric); + public java.lang.Boolean hasMetric(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested withNewMetric(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested editMetric(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested editOrNewMetric(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); - + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested + withNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested + editMetric(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested + editOrNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricTarget getTarget(); + public io.kubernetes.client.openapi.models.V2beta2MetricTarget buildTarget(); + public A withTarget(io.kubernetes.client.openapi.models.V2beta2MetricTarget target); + public java.lang.Boolean hasTarget(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested withNewTarget(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested editTarget(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested editOrNewTarget(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); - public interface MetricNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent>{ + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested + withNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested + editTarget(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested + editOrNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); + + public interface MetricNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent< + io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested> { public N and(); + public N endMetric(); - } - public interface TargetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent>{ + + public interface TargetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent< + io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested> { public N and(); + public N endTarget(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricSourceFluentImpl.java index 7ff949bbe5..9c68d5da00 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricSourceFluentImpl.java @@ -1,135 +1,207 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta2PodsMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent { + public V2beta2PodsMetricSourceFluentImpl() {} - /** - * Generated - */ -public class V2beta2PodsMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent{ - public V2beta2PodsMetricSourceFluentImpl() { - } - public V2beta2PodsMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2beta2PodsMetricSource instance) { + public V2beta2PodsMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2beta2PodsMetricSource instance) { this.withMetric(instance.getMetric()); this.withTarget(instance.getTarget()); - } + private io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder metric; private io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder target; - + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier getMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier buildMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public A withMetric(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier metric) { _visitables.get("metric").remove(this.metric); - if (metric!=null){ this.metric= new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(metric); _visitables.get("metric").add(this.metric);} return (A) this; + if (metric != null) { + this.metric = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(metric); + _visitables.get("metric").add(this.metric); + } + return (A) this; } + public java.lang.Boolean hasMetric() { return this.metric != null; } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested withNewMetric() { - return new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluentImpl.MetricNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested + withNewMetric() { + return new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluentImpl + .MetricNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - return new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluentImpl.MetricNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { + return new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluentImpl + .MetricNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested editMetric() { + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested + editMetric() { return withNewMetricLike(getMetric()); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested editOrNewMetric() { - return withNewMetricLike(getMetric() != null ? getMetric(): new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested + editOrNewMetric() { + return withNewMetricLike( + getMetric() != null + ? getMetric() + : new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - return withNewMetricLike(getMetric() != null ? getMetric(): item); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { + return withNewMetricLike(getMetric() != null ? getMetric() : item); } - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricTarget getTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricTarget buildTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public A withTarget(io.kubernetes.client.openapi.models.V2beta2MetricTarget target) { _visitables.get("target").remove(this.target); - if (target!=null){ this.target= new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(target); _visitables.get("target").add(this.target);} return (A) this; + if (target != null) { + this.target = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(target); + _visitables.get("target").add(this.target); + } + return (A) this; } + public java.lang.Boolean hasTarget() { return this.target != null; } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested withNewTarget() { - return new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluentImpl.TargetNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested + withNewTarget() { + return new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluentImpl + .TargetNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { - return new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluentImpl.TargetNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { + return new io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluentImpl + .TargetNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested editTarget() { + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested + editTarget() { return withNewTargetLike(getTarget()); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested editOrNewTarget() { - return withNewTargetLike(getTarget() != null ? getTarget(): new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested + editOrNewTarget() { + return withNewTargetLike( + getTarget() != null + ? getTarget() + : new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { - return withNewTargetLike(getTarget() != null ? getTarget(): item); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { + return withNewTargetLike(getTarget() != null ? getTarget() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2PodsMetricSourceFluentImpl that = (V2beta2PodsMetricSourceFluentImpl) o; - if (metric != null ? !metric.equals(that.metric) :that.metric != null) return false; - if (target != null ? !target.equals(that.target) :that.target != null) return false; + if (metric != null ? !metric.equals(that.metric) : that.metric != null) return false; + if (target != null ? !target.equals(that.target) : that.target != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(metric, target, super.hashCode()); + return java.util.Objects.hash(metric, target, super.hashCode()); } - public class MetricNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested,io.kubernetes.client.fluent.Nested{ + + public class MetricNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested> + implements io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.MetricNested, + io.kubernetes.client.fluent.Nested { MetricNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this, item); } + MetricNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder builder; + public N and() { return (N) V2beta2PodsMetricSourceFluentImpl.this.withMetric(builder.build()); } + public N endMetric() { return and(); } - } - public class TargetNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested,io.kubernetes.client.fluent.Nested{ + + public class TargetNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluentImpl< + io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested> + implements io.kubernetes.client.openapi.models.V2beta2PodsMetricSourceFluent.TargetNested, + io.kubernetes.client.fluent.Nested { TargetNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(this, item); } + TargetNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder builder; + public N and() { return (N) V2beta2PodsMetricSourceFluentImpl.this.withTarget(builder.build()); } + public N endTarget() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricStatusBuilder.java index a21232452a..7909a8fccf 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricStatusBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2PodsMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2PodsMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus, + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusBuilder> { public V2beta2PodsMetricStatusBuilder() { this(false); } + public V2beta2PodsMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2PodsMetricStatus(), validationEnabled); } - public V2beta2PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent fluent) { + + public V2beta2PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent fluent) { this(fluent, false); } - public V2beta2PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2PodsMetricStatus(), validationEnabled); } - public V2beta2PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus instance) { + + public V2beta2PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus instance) { this(fluent, instance, false); } - public V2beta2PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCurrent(instance.getCurrent()); fluent.withMetric(instance.getMetric()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus instance) { - this(instance,false); + + public V2beta2PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus instance) { + this(instance, false); } - public V2beta2PodsMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2PodsMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCurrent(instance.getCurrent()); this.withMetric(instance.getMetric()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus build() { V2beta2PodsMetricStatus buildable = new V2beta2PodsMetricStatus(); buildable.setCurrent(fluent.getCurrent()); buildable.setMetric(fluent.getMetric()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2PodsMetricStatusBuilder that = (V2beta2PodsMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricStatusFluent.java index 086e697314..539ce15314 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricStatusFluent.java @@ -1,55 +1,95 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2PodsMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2beta2PodsMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus getCurrent(); + public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus buildCurrent(); + public A withCurrent(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus current); + public java.lang.Boolean hasCurrent(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested withNewCurrent(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested editCurrent(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested editOrNewCurrent(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); - + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested + withNewCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested + editCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested + editOrNewCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier getMetric(); + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier buildMetric(); + public A withMetric(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier metric); + public java.lang.Boolean hasMetric(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested withNewMetric(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested editMetric(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested editOrNewMetric(); - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); - public interface CurrentNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent>{ + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested + withNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested + editMetric(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested + editOrNewMetric(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item); + + public interface CurrentNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent< + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested> { public N and(); + public N endCurrent(); - } - public interface MetricNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent>{ + + public interface MetricNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluent< + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested> { public N and(); + public N endMetric(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricStatusFluentImpl.java index bddf0a520a..189f2287b9 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2PodsMetricStatusFluentImpl.java @@ -1,135 +1,209 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta2PodsMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent { + public V2beta2PodsMetricStatusFluentImpl() {} - /** - * Generated - */ -public class V2beta2PodsMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent{ - public V2beta2PodsMetricStatusFluentImpl() { - } - public V2beta2PodsMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus instance) { + public V2beta2PodsMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatus instance) { this.withCurrent(instance.getCurrent()); this.withMetric(instance.getMetric()); - } + private io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder current; private io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder metric; - + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus getCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus buildCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public A withCurrent(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus current) { _visitables.get("current").remove(this.current); - if (current!=null){ this.current= new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(current); _visitables.get("current").add(this.current);} return (A) this; + if (current != null) { + this.current = + new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(current); + _visitables.get("current").add(this.current); + } + return (A) this; } + public java.lang.Boolean hasCurrent() { return this.current != null; } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested withNewCurrent() { - return new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluentImpl.CurrentNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested + withNewCurrent() { + return new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluentImpl + .CurrentNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - return new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluentImpl.CurrentNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { + return new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluentImpl + .CurrentNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested editCurrent() { + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested + editCurrent() { return withNewCurrentLike(getCurrent()); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested editOrNewCurrent() { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested + editOrNewCurrent() { + return withNewCurrentLike( + getCurrent() != null + ? getCurrent() + : new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): item); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { + return withNewCurrentLike(getCurrent() != null ? getCurrent() : item); } - + /** * This method has been deprecated, please use method buildMetric instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier getMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricIdentifier buildMetric() { - return this.metric!=null ?this.metric.build():null; + return this.metric != null ? this.metric.build() : null; } + public A withMetric(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier metric) { _visitables.get("metric").remove(this.metric); - if (metric!=null){ this.metric= new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(metric); _visitables.get("metric").add(this.metric);} return (A) this; + if (metric != null) { + this.metric = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(metric); + _visitables.get("metric").add(this.metric); + } + return (A) this; } + public java.lang.Boolean hasMetric() { return this.metric != null; } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested withNewMetric() { - return new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluentImpl.MetricNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested + withNewMetric() { + return new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluentImpl + .MetricNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - return new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluentImpl.MetricNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested + withNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { + return new io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluentImpl + .MetricNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested editMetric() { + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested + editMetric() { return withNewMetricLike(getMetric()); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested editOrNewMetric() { - return withNewMetricLike(getMetric() != null ? getMetric(): new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested + editOrNewMetric() { + return withNewMetricLike( + getMetric() != null + ? getMetric() + : new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - return withNewMetricLike(getMetric() != null ? getMetric(): item); + + public io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested + editOrNewMetricLike(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { + return withNewMetricLike(getMetric() != null ? getMetric() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2PodsMetricStatusFluentImpl that = (V2beta2PodsMetricStatusFluentImpl) o; - if (current != null ? !current.equals(that.current) :that.current != null) return false; - if (metric != null ? !metric.equals(that.metric) :that.metric != null) return false; + if (current != null ? !current.equals(that.current) : that.current != null) return false; + if (metric != null ? !metric.equals(that.metric) : that.metric != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(current, metric, super.hashCode()); + return java.util.Objects.hash(current, metric, super.hashCode()); } - public class CurrentNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested,io.kubernetes.client.fluent.Nested{ + + public class CurrentNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested> + implements io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.CurrentNested, + io.kubernetes.client.fluent.Nested { CurrentNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this, item); } + CurrentNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder builder; + public N and() { return (N) V2beta2PodsMetricStatusFluentImpl.this.withCurrent(builder.build()); } + public N endCurrent() { return and(); } - } - public class MetricNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested,io.kubernetes.client.fluent.Nested{ + + public class MetricNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricIdentifierFluentImpl< + io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested> + implements io.kubernetes.client.openapi.models.V2beta2PodsMetricStatusFluent.MetricNested, + io.kubernetes.client.fluent.Nested { MetricNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricIdentifier item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this, item); } + MetricNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricIdentifierBuilder builder; + public N and() { return (N) V2beta2PodsMetricStatusFluentImpl.this.withMetric(builder.build()); } + public N endMetric() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricSourceBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricSourceBuilder.java index e3221620d1..3657f4ff6d 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricSourceBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricSourceBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2ResourceMetricSourceBuilder extends io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2ResourceMetricSourceBuilder + extends io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource, + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceBuilder> { public V2beta2ResourceMetricSourceBuilder() { this(false); } + public V2beta2ResourceMetricSourceBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2ResourceMetricSource(), validationEnabled); } - public V2beta2ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent fluent) { + + public V2beta2ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent fluent) { this(fluent, false); } - public V2beta2ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2ResourceMetricSource(), validationEnabled); } - public V2beta2ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource instance) { + + public V2beta2ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource instance) { this(fluent, instance, false); } - public V2beta2ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent fluent,io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withName(instance.getName()); fluent.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource instance) { - this(instance,false); + + public V2beta2ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource instance) { + this(instance, false); } - public V2beta2ResourceMetricSourceBuilder(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2ResourceMetricSourceBuilder( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withName(instance.getName()); this.withTarget(instance.getTarget()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource build() { V2beta2ResourceMetricSource buildable = new V2beta2ResourceMetricSource(); buildable.setName(fluent.getName()); buildable.setTarget(fluent.getTarget()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2ResourceMetricSourceBuilder that = (V2beta2ResourceMetricSourceBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricSourceFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricSourceFluent.java index d01bd518a1..a1117b5bc5 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricSourceFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricSourceFluent.java @@ -1,44 +1,67 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2ResourceMetricSourceFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface V2beta2ResourceMetricSourceFluent< + A extends io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricTarget getTarget(); + public io.kubernetes.client.openapi.models.V2beta2MetricTarget buildTarget(); + public A withTarget(io.kubernetes.client.openapi.models.V2beta2MetricTarget target); + public java.lang.Boolean hasTarget(); - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested withNewTarget(); - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested editTarget(); - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested editOrNewTarget(); - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); - public interface TargetNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent>{ + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested + withNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested + editTarget(); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested + editOrNewTarget(); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item); + + public interface TargetNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricTargetFluent< + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested< + N>> { public N and(); + public N endTarget(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricSourceFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricSourceFluentImpl.java index 768594c8bc..eb1e06633c 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricSourceFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricSourceFluentImpl.java @@ -1,103 +1,145 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta2ResourceMetricSourceFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent { + public V2beta2ResourceMetricSourceFluentImpl() {} - /** - * Generated - */ -public class V2beta2ResourceMetricSourceFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent{ - public V2beta2ResourceMetricSourceFluentImpl() { - } - public V2beta2ResourceMetricSourceFluentImpl(io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource instance) { + public V2beta2ResourceMetricSourceFluentImpl( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSource instance) { this.withName(instance.getName()); this.withTarget(instance.getTarget()); - } + private java.lang.String name; private io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder target; + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } - + /** * This method has been deprecated, please use method buildTarget instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricTarget getTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricTarget buildTarget() { - return this.target!=null ?this.target.build():null; + return this.target != null ? this.target.build() : null; } + public A withTarget(io.kubernetes.client.openapi.models.V2beta2MetricTarget target) { _visitables.get("target").remove(this.target); - if (target!=null){ this.target= new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(target); _visitables.get("target").add(this.target);} return (A) this; + if (target != null) { + this.target = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(target); + _visitables.get("target").add(this.target); + } + return (A) this; } + public java.lang.Boolean hasTarget() { return this.target != null; } - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested withNewTarget() { - return new io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluentImpl.TargetNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested + withNewTarget() { + return new io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluentImpl + .TargetNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { - return new io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluentImpl.TargetNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested + withNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { + return new io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluentImpl + .TargetNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested editTarget() { + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested + editTarget() { return withNewTargetLike(getTarget()); } - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested editOrNewTarget() { - return withNewTargetLike(getTarget() != null ? getTarget(): new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested + editOrNewTarget() { + return withNewTargetLike( + getTarget() != null + ? getTarget() + : new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { - return withNewTargetLike(getTarget() != null ? getTarget(): item); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested + editOrNewTargetLike(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { + return withNewTargetLike(getTarget() != null ? getTarget() : item); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2ResourceMetricSourceFluentImpl that = (V2beta2ResourceMetricSourceFluentImpl) o; - if (name != null ? !name.equals(that.name) :that.name != null) return false; - if (target != null ? !target.equals(that.target) :that.target != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; + if (target != null ? !target.equals(that.target) : that.target != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(name, target, super.hashCode()); + return java.util.Objects.hash(name, target, super.hashCode()); } - public class TargetNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested,io.kubernetes.client.fluent.Nested{ + + public class TargetNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricTargetFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested> + implements io.kubernetes.client.openapi.models.V2beta2ResourceMetricSourceFluent.TargetNested< + N>, + io.kubernetes.client.fluent.Nested { TargetNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricTarget item) { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(this, item); } + TargetNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricTargetBuilder builder; + public N and() { return (N) V2beta2ResourceMetricSourceFluentImpl.this.withTarget(builder.build()); } + public N endTarget() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricStatusBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricStatusBuilder.java index 713f64795f..c1f4c780d3 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricStatusBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricStatusBuilder.java @@ -1,63 +1,102 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class V2beta2ResourceMetricStatusBuilder extends io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class V2beta2ResourceMetricStatusBuilder + extends io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus, + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusBuilder> { public V2beta2ResourceMetricStatusBuilder() { this(false); } + public V2beta2ResourceMetricStatusBuilder(java.lang.Boolean validationEnabled) { this(new V2beta2ResourceMetricStatus(), validationEnabled); } - public V2beta2ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent fluent) { + + public V2beta2ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent fluent) { this(fluent, false); } - public V2beta2ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent fluent,java.lang.Boolean validationEnabled) { + + public V2beta2ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new V2beta2ResourceMetricStatus(), validationEnabled); } - public V2beta2ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus instance) { + + public V2beta2ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus instance) { this(fluent, instance, false); } - public V2beta2ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent fluent,io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public V2beta2ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent fluent, + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withCurrent(instance.getCurrent()); fluent.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } - public V2beta2ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus instance) { - this(instance,false); + + public V2beta2ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus instance) { + this(instance, false); } - public V2beta2ResourceMetricStatusBuilder(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public V2beta2ResourceMetricStatusBuilder( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withCurrent(instance.getCurrent()); this.withName(instance.getName()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus build() { V2beta2ResourceMetricStatus buildable = new V2beta2ResourceMetricStatus(); buildable.setCurrent(fluent.getCurrent()); buildable.setName(fluent.getName()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; V2beta2ResourceMetricStatusBuilder that = (V2beta2ResourceMetricStatusBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricStatusFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricStatusFluent.java index 0b6e3196cb..aa2489bc82 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricStatusFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricStatusFluent.java @@ -1,44 +1,68 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface V2beta2ResourceMetricStatusFluent> extends io.kubernetes.client.fluent.Fluent{ - +/** Generated */ +public interface V2beta2ResourceMetricStatusFluent< + A extends io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent> + extends io.kubernetes.client.fluent.Fluent { + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus getCurrent(); + public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus buildCurrent(); + public A withCurrent(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus current); + public java.lang.Boolean hasCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested withNewCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested editCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested editOrNewCurrent(); - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested + withNewCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested + editCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested + editOrNewCurrent(); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item); + public java.lang.String getName(); + public A withName(java.lang.String name); + public java.lang.Boolean hasName(); - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original); - public interface CurrentNested extends io.kubernetes.client.fluent.Nested,io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent>{ + + public interface CurrentNested + extends io.kubernetes.client.fluent.Nested, + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluent< + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested< + N>> { public N and(); + public N endCurrent(); - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricStatusFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricStatusFluentImpl.java index 6fa910eac5..be9f69a976 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricStatusFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/V2beta2ResourceMetricStatusFluentImpl.java @@ -1,103 +1,148 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.Nested; -import java.lang.String; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.Boolean; +/** Generated */ +public class V2beta2ResourceMetricStatusFluentImpl< + A extends io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent { + public V2beta2ResourceMetricStatusFluentImpl() {} - /** - * Generated - */ -public class V2beta2ResourceMetricStatusFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent{ - public V2beta2ResourceMetricStatusFluentImpl() { - } - public V2beta2ResourceMetricStatusFluentImpl(io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus instance) { + public V2beta2ResourceMetricStatusFluentImpl( + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatus instance) { this.withCurrent(instance.getCurrent()); this.withName(instance.getName()); - } + private io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder current; private java.lang.String name; - + /** * This method has been deprecated, please use method buildCurrent instead. + * * @return The buildable object. */ @java.lang.Deprecated public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus getCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public io.kubernetes.client.openapi.models.V2beta2MetricValueStatus buildCurrent() { - return this.current!=null ?this.current.build():null; + return this.current != null ? this.current.build() : null; } + public A withCurrent(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus current) { _visitables.get("current").remove(this.current); - if (current!=null){ this.current= new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(current); _visitables.get("current").add(this.current);} return (A) this; + if (current != null) { + this.current = + new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(current); + _visitables.get("current").add(this.current); + } + return (A) this; } + public java.lang.Boolean hasCurrent() { return this.current != null; } - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested withNewCurrent() { - return new io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluentImpl.CurrentNestedImpl(); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested + withNewCurrent() { + return new io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluentImpl + .CurrentNestedImpl(); } - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - return new io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluentImpl.CurrentNestedImpl(item); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested + withNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { + return new io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluentImpl + .CurrentNestedImpl(item); } - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested editCurrent() { + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested + editCurrent() { return withNewCurrentLike(getCurrent()); } - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested editOrNewCurrent() { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder().build()); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested + editOrNewCurrent() { + return withNewCurrentLike( + getCurrent() != null + ? getCurrent() + : new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder().build()); } - public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - return withNewCurrentLike(getCurrent() != null ? getCurrent(): item); + + public io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested + editOrNewCurrentLike(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { + return withNewCurrentLike(getCurrent() != null ? getCurrent() : item); } + public java.lang.String getName() { return this.name; } + public A withName(java.lang.String name) { - this.name=name; return (A) this; + this.name = name; + return (A) this; } + public java.lang.Boolean hasName() { return this.name != null; } - - /** - * Method is deprecated. use withName instead. - */ + + /** Method is deprecated. use withName instead. */ @java.lang.Deprecated public A withNewName(java.lang.String original) { - return (A)withName(new String(original)); + return (A) withName(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; V2beta2ResourceMetricStatusFluentImpl that = (V2beta2ResourceMetricStatusFluentImpl) o; - if (current != null ? !current.equals(that.current) :that.current != null) return false; - if (name != null ? !name.equals(that.name) :that.name != null) return false; + if (current != null ? !current.equals(that.current) : that.current != null) return false; + if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(current, name, super.hashCode()); + return java.util.Objects.hash(current, name, super.hashCode()); } - public class CurrentNestedImpl extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluentImpl> implements io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested,io.kubernetes.client.fluent.Nested{ + + public class CurrentNestedImpl + extends io.kubernetes.client.openapi.models.V2beta2MetricValueStatusFluentImpl< + io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent.CurrentNested> + implements io.kubernetes.client.openapi.models.V2beta2ResourceMetricStatusFluent + .CurrentNested< + N>, + io.kubernetes.client.fluent.Nested { CurrentNestedImpl(io.kubernetes.client.openapi.models.V2beta2MetricValueStatus item) { - this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this, item); + this.builder = + new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this, item); } + CurrentNestedImpl() { this.builder = new io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder(this); } + io.kubernetes.client.openapi.models.V2beta2MetricValueStatusBuilder builder; + public N and() { return (N) V2beta2ResourceMetricStatusFluentImpl.this.withCurrent(builder.build()); } + public N endCurrent() { return and(); } - } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/VersionInfoBuilder.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/VersionInfoBuilder.java index e295a6b16d..48ac1bd508 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/VersionInfoBuilder.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/VersionInfoBuilder.java @@ -1,26 +1,52 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import io.kubernetes.client.fluent.VisitableBuilder; -import java.lang.Object; -import java.lang.Boolean; -public class VersionInfoBuilder extends io.kubernetes.client.openapi.models.VersionInfoFluentImpl implements io.kubernetes.client.fluent.VisitableBuilder{ +public class VersionInfoBuilder + extends io.kubernetes.client.openapi.models.VersionInfoFluentImpl< + io.kubernetes.client.openapi.models.VersionInfoBuilder> + implements io.kubernetes.client.fluent.VisitableBuilder< + io.kubernetes.client.openapi.models.VersionInfo, + io.kubernetes.client.openapi.models.VersionInfoBuilder> { public VersionInfoBuilder() { this(false); } + public VersionInfoBuilder(java.lang.Boolean validationEnabled) { this(new VersionInfo(), validationEnabled); } + public VersionInfoBuilder(io.kubernetes.client.openapi.models.VersionInfoFluent fluent) { this(fluent, false); } - public VersionInfoBuilder(io.kubernetes.client.openapi.models.VersionInfoFluent fluent,java.lang.Boolean validationEnabled) { + + public VersionInfoBuilder( + io.kubernetes.client.openapi.models.VersionInfoFluent fluent, + java.lang.Boolean validationEnabled) { this(fluent, new VersionInfo(), validationEnabled); } - public VersionInfoBuilder(io.kubernetes.client.openapi.models.VersionInfoFluent fluent,io.kubernetes.client.openapi.models.VersionInfo instance) { + + public VersionInfoBuilder( + io.kubernetes.client.openapi.models.VersionInfoFluent fluent, + io.kubernetes.client.openapi.models.VersionInfo instance) { this(fluent, instance, false); } - public VersionInfoBuilder(io.kubernetes.client.openapi.models.VersionInfoFluent fluent,io.kubernetes.client.openapi.models.VersionInfo instance,java.lang.Boolean validationEnabled) { - this.fluent = fluent; + + public VersionInfoBuilder( + io.kubernetes.client.openapi.models.VersionInfoFluent fluent, + io.kubernetes.client.openapi.models.VersionInfo instance, + java.lang.Boolean validationEnabled) { + this.fluent = fluent; fluent.withBuildDate(instance.getBuildDate()); fluent.withCompiler(instance.getCompiler()); @@ -39,13 +65,17 @@ public VersionInfoBuilder(io.kubernetes.client.openapi.models.VersionInfoFluent< fluent.withPlatform(instance.getPlatform()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + public VersionInfoBuilder(io.kubernetes.client.openapi.models.VersionInfo instance) { - this(instance,false); + this(instance, false); } - public VersionInfoBuilder(io.kubernetes.client.openapi.models.VersionInfo instance,java.lang.Boolean validationEnabled) { - this.fluent = this; + + public VersionInfoBuilder( + io.kubernetes.client.openapi.models.VersionInfo instance, + java.lang.Boolean validationEnabled) { + this.fluent = this; this.withBuildDate(instance.getBuildDate()); this.withCompiler(instance.getCompiler()); @@ -64,10 +94,12 @@ public VersionInfoBuilder(io.kubernetes.client.openapi.models.VersionInfo instan this.withPlatform(instance.getPlatform()); - this.validationEnabled = validationEnabled; + this.validationEnabled = validationEnabled; } + io.kubernetes.client.openapi.models.VersionInfoFluent fluent; java.lang.Boolean validationEnabled; + public io.kubernetes.client.openapi.models.VersionInfo build() { VersionInfo buildable = new VersionInfo(); buildable.setBuildDate(fluent.getBuildDate()); @@ -81,18 +113,23 @@ public io.kubernetes.client.openapi.models.VersionInfo build() { buildable.setPlatform(fluent.getPlatform()); return buildable; } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; if (!super.equals(o)) return false; VersionInfoBuilder that = (VersionInfoBuilder) o; - if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false; + if (fluent != null && fluent != this + ? !fluent.equals(that.fluent) + : that.fluent != null && fluent != this) return false; - if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false; + if (validationEnabled != null + ? !validationEnabled.equals(that.validationEnabled) + : that.validationEnabled != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); + return java.util.Objects.hash(fluent, validationEnabled, super.hashCode()); } - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/VersionInfoFluent.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/VersionInfoFluent.java index e58da36ae0..e691e263ec 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/VersionInfoFluent.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/VersionInfoFluent.java @@ -1,95 +1,108 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import com.google.gson.annotations.SerializedName; -import io.kubernetes.client.fluent.Fluent; -import java.lang.String; -import java.lang.Boolean; - - /** - * Generated - */ -public interface VersionInfoFluent> extends io.kubernetes.client.fluent.Fluent{ +/** Generated */ +public interface VersionInfoFluent< + A extends io.kubernetes.client.openapi.models.VersionInfoFluent> + extends io.kubernetes.client.fluent.Fluent { public java.lang.String getBuildDate(); + public A withBuildDate(java.lang.String buildDate); + public java.lang.Boolean hasBuildDate(); - - /** - * Method is deprecated. use withBuildDate instead. - */ + + /** Method is deprecated. use withBuildDate instead. */ @java.lang.Deprecated public A withNewBuildDate(java.lang.String original); + public java.lang.String getCompiler(); + public A withCompiler(java.lang.String compiler); + public java.lang.Boolean hasCompiler(); - - /** - * Method is deprecated. use withCompiler instead. - */ + + /** Method is deprecated. use withCompiler instead. */ @java.lang.Deprecated public A withNewCompiler(java.lang.String original); + public java.lang.String getGitCommit(); + public A withGitCommit(java.lang.String gitCommit); + public java.lang.Boolean hasGitCommit(); - - /** - * Method is deprecated. use withGitCommit instead. - */ + + /** Method is deprecated. use withGitCommit instead. */ @java.lang.Deprecated public A withNewGitCommit(java.lang.String original); + public java.lang.String getGitTreeState(); + public A withGitTreeState(java.lang.String gitTreeState); + public java.lang.Boolean hasGitTreeState(); - - /** - * Method is deprecated. use withGitTreeState instead. - */ + + /** Method is deprecated. use withGitTreeState instead. */ @java.lang.Deprecated public A withNewGitTreeState(java.lang.String original); + public java.lang.String getGitVersion(); + public A withGitVersion(java.lang.String gitVersion); + public java.lang.Boolean hasGitVersion(); - - /** - * Method is deprecated. use withGitVersion instead. - */ + + /** Method is deprecated. use withGitVersion instead. */ @java.lang.Deprecated public A withNewGitVersion(java.lang.String original); + public java.lang.String getGoVersion(); + public A withGoVersion(java.lang.String goVersion); + public java.lang.Boolean hasGoVersion(); - - /** - * Method is deprecated. use withGoVersion instead. - */ + + /** Method is deprecated. use withGoVersion instead. */ @java.lang.Deprecated public A withNewGoVersion(java.lang.String original); + public java.lang.String getMajor(); + public A withMajor(java.lang.String major); + public java.lang.Boolean hasMajor(); - - /** - * Method is deprecated. use withMajor instead. - */ + + /** Method is deprecated. use withMajor instead. */ @java.lang.Deprecated public A withNewMajor(java.lang.String original); + public java.lang.String getMinor(); + public A withMinor(java.lang.String minor); + public java.lang.Boolean hasMinor(); - - /** - * Method is deprecated. use withMinor instead. - */ + + /** Method is deprecated. use withMinor instead. */ @java.lang.Deprecated public A withNewMinor(java.lang.String original); + public java.lang.String getPlatform(); + public A withPlatform(java.lang.String platform); + public java.lang.Boolean hasPlatform(); - - /** - * Method is deprecated. use withPlatform instead. - */ + + /** Method is deprecated. use withPlatform instead. */ @java.lang.Deprecated public A withNewPlatform(java.lang.String original); - -} \ No newline at end of file +} diff --git a/fluent/src/main/java/io/kubernetes/client/openapi/models/VersionInfoFluentImpl.java b/fluent/src/main/java/io/kubernetes/client/openapi/models/VersionInfoFluentImpl.java index 33f15ef4c3..8f765e3f77 100644 --- a/fluent/src/main/java/io/kubernetes/client/openapi/models/VersionInfoFluentImpl.java +++ b/fluent/src/main/java/io/kubernetes/client/openapi/models/VersionInfoFluentImpl.java @@ -1,17 +1,24 @@ +/* +Copyright 2022 The Kubernetes Authors. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at +http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ package io.kubernetes.client.openapi.models; -import java.lang.Deprecated; -import io.kubernetes.client.fluent.BaseFluent; -import java.lang.Object; -import java.lang.String; -import java.lang.Boolean; +/** Generated */ +public class VersionInfoFluentImpl< + A extends io.kubernetes.client.openapi.models.VersionInfoFluent> + extends io.kubernetes.client.fluent.BaseFluent + implements io.kubernetes.client.openapi.models.VersionInfoFluent { + public VersionInfoFluentImpl() {} - /** - * Generated - */ -public class VersionInfoFluentImpl> extends io.kubernetes.client.fluent.BaseFluent implements io.kubernetes.client.openapi.models.VersionInfoFluent{ - public VersionInfoFluentImpl() { - } public VersionInfoFluentImpl(io.kubernetes.client.openapi.models.VersionInfo instance) { this.withBuildDate(instance.getBuildDate()); @@ -30,8 +37,8 @@ public VersionInfoFluentImpl(io.kubernetes.client.openapi.models.VersionInfo ins this.withMinor(instance.getMinor()); this.withPlatform(instance.getPlatform()); - } + private java.lang.String buildDate; private java.lang.String compiler; private java.lang.String gitCommit; @@ -41,176 +48,210 @@ public VersionInfoFluentImpl(io.kubernetes.client.openapi.models.VersionInfo ins private java.lang.String major; private java.lang.String minor; private java.lang.String platform; + public java.lang.String getBuildDate() { return this.buildDate; } + public A withBuildDate(java.lang.String buildDate) { - this.buildDate=buildDate; return (A) this; + this.buildDate = buildDate; + return (A) this; } + public java.lang.Boolean hasBuildDate() { return this.buildDate != null; } - - /** - * Method is deprecated. use withBuildDate instead. - */ + + /** Method is deprecated. use withBuildDate instead. */ @java.lang.Deprecated public A withNewBuildDate(java.lang.String original) { - return (A)withBuildDate(new String(original)); + return (A) withBuildDate(new String(original)); } + public java.lang.String getCompiler() { return this.compiler; } + public A withCompiler(java.lang.String compiler) { - this.compiler=compiler; return (A) this; + this.compiler = compiler; + return (A) this; } + public java.lang.Boolean hasCompiler() { return this.compiler != null; } - - /** - * Method is deprecated. use withCompiler instead. - */ + + /** Method is deprecated. use withCompiler instead. */ @java.lang.Deprecated public A withNewCompiler(java.lang.String original) { - return (A)withCompiler(new String(original)); + return (A) withCompiler(new String(original)); } + public java.lang.String getGitCommit() { return this.gitCommit; } + public A withGitCommit(java.lang.String gitCommit) { - this.gitCommit=gitCommit; return (A) this; + this.gitCommit = gitCommit; + return (A) this; } + public java.lang.Boolean hasGitCommit() { return this.gitCommit != null; } - - /** - * Method is deprecated. use withGitCommit instead. - */ + + /** Method is deprecated. use withGitCommit instead. */ @java.lang.Deprecated public A withNewGitCommit(java.lang.String original) { - return (A)withGitCommit(new String(original)); + return (A) withGitCommit(new String(original)); } + public java.lang.String getGitTreeState() { return this.gitTreeState; } + public A withGitTreeState(java.lang.String gitTreeState) { - this.gitTreeState=gitTreeState; return (A) this; + this.gitTreeState = gitTreeState; + return (A) this; } + public java.lang.Boolean hasGitTreeState() { return this.gitTreeState != null; } - - /** - * Method is deprecated. use withGitTreeState instead. - */ + + /** Method is deprecated. use withGitTreeState instead. */ @java.lang.Deprecated public A withNewGitTreeState(java.lang.String original) { - return (A)withGitTreeState(new String(original)); + return (A) withGitTreeState(new String(original)); } + public java.lang.String getGitVersion() { return this.gitVersion; } + public A withGitVersion(java.lang.String gitVersion) { - this.gitVersion=gitVersion; return (A) this; + this.gitVersion = gitVersion; + return (A) this; } + public java.lang.Boolean hasGitVersion() { return this.gitVersion != null; } - - /** - * Method is deprecated. use withGitVersion instead. - */ + + /** Method is deprecated. use withGitVersion instead. */ @java.lang.Deprecated public A withNewGitVersion(java.lang.String original) { - return (A)withGitVersion(new String(original)); + return (A) withGitVersion(new String(original)); } + public java.lang.String getGoVersion() { return this.goVersion; } + public A withGoVersion(java.lang.String goVersion) { - this.goVersion=goVersion; return (A) this; + this.goVersion = goVersion; + return (A) this; } + public java.lang.Boolean hasGoVersion() { return this.goVersion != null; } - - /** - * Method is deprecated. use withGoVersion instead. - */ + + /** Method is deprecated. use withGoVersion instead. */ @java.lang.Deprecated public A withNewGoVersion(java.lang.String original) { - return (A)withGoVersion(new String(original)); + return (A) withGoVersion(new String(original)); } + public java.lang.String getMajor() { return this.major; } + public A withMajor(java.lang.String major) { - this.major=major; return (A) this; + this.major = major; + return (A) this; } + public java.lang.Boolean hasMajor() { return this.major != null; } - - /** - * Method is deprecated. use withMajor instead. - */ + + /** Method is deprecated. use withMajor instead. */ @java.lang.Deprecated public A withNewMajor(java.lang.String original) { - return (A)withMajor(new String(original)); + return (A) withMajor(new String(original)); } + public java.lang.String getMinor() { return this.minor; } + public A withMinor(java.lang.String minor) { - this.minor=minor; return (A) this; + this.minor = minor; + return (A) this; } + public java.lang.Boolean hasMinor() { return this.minor != null; } - - /** - * Method is deprecated. use withMinor instead. - */ + + /** Method is deprecated. use withMinor instead. */ @java.lang.Deprecated public A withNewMinor(java.lang.String original) { - return (A)withMinor(new String(original)); + return (A) withMinor(new String(original)); } + public java.lang.String getPlatform() { return this.platform; } + public A withPlatform(java.lang.String platform) { - this.platform=platform; return (A) this; + this.platform = platform; + return (A) this; } + public java.lang.Boolean hasPlatform() { return this.platform != null; } - - /** - * Method is deprecated. use withPlatform instead. - */ + + /** Method is deprecated. use withPlatform instead. */ @java.lang.Deprecated public A withNewPlatform(java.lang.String original) { - return (A)withPlatform(new String(original)); + return (A) withPlatform(new String(original)); } + public boolean equals(java.lang.Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; VersionInfoFluentImpl that = (VersionInfoFluentImpl) o; - if (buildDate != null ? !buildDate.equals(that.buildDate) :that.buildDate != null) return false; - if (compiler != null ? !compiler.equals(that.compiler) :that.compiler != null) return false; - if (gitCommit != null ? !gitCommit.equals(that.gitCommit) :that.gitCommit != null) return false; - if (gitTreeState != null ? !gitTreeState.equals(that.gitTreeState) :that.gitTreeState != null) return false; - if (gitVersion != null ? !gitVersion.equals(that.gitVersion) :that.gitVersion != null) return false; - if (goVersion != null ? !goVersion.equals(that.goVersion) :that.goVersion != null) return false; - if (major != null ? !major.equals(that.major) :that.major != null) return false; - if (minor != null ? !minor.equals(that.minor) :that.minor != null) return false; - if (platform != null ? !platform.equals(that.platform) :that.platform != null) return false; + if (buildDate != null ? !buildDate.equals(that.buildDate) : that.buildDate != null) + return false; + if (compiler != null ? !compiler.equals(that.compiler) : that.compiler != null) return false; + if (gitCommit != null ? !gitCommit.equals(that.gitCommit) : that.gitCommit != null) + return false; + if (gitTreeState != null ? !gitTreeState.equals(that.gitTreeState) : that.gitTreeState != null) + return false; + if (gitVersion != null ? !gitVersion.equals(that.gitVersion) : that.gitVersion != null) + return false; + if (goVersion != null ? !goVersion.equals(that.goVersion) : that.goVersion != null) + return false; + if (major != null ? !major.equals(that.major) : that.major != null) return false; + if (minor != null ? !minor.equals(that.minor) : that.minor != null) return false; + if (platform != null ? !platform.equals(that.platform) : that.platform != null) return false; return true; } + public int hashCode() { - return java.util.Objects.hash(buildDate, compiler, gitCommit, gitTreeState, gitVersion, goVersion, major, minor, platform, super.hashCode()); - } - -} \ No newline at end of file + return java.util.Objects.hash( + buildDate, + compiler, + gitCommit, + gitTreeState, + gitVersion, + goVersion, + major, + minor, + platform, + super.hashCode()); + } +} diff --git a/pom.xml b/pom.xml index c1ada61636..beeee612ba 100644 --- a/pom.xml +++ b/pom.xml @@ -435,7 +435,7 @@ com.diffplug.spotless spotless-maven-plugin - 2.17.2 + 2.20.0